:root {
  color-scheme: dark;
  --bg: #06101f;
  --surface: #0d1f3a;
  --text: #e2eaff;
  --muted: rgba(180, 200, 240, 0.68);
  --yellow: #fefc40;
  --border: rgba(58, 87, 146, 0.34);
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: #020713;
}

body.app-body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(58, 87, 146, 0.22), transparent 34%),
    radial-gradient(circle at bottom right, rgba(254, 252, 64, 0.045), transparent 28%),
    #020713;
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overscroll-behavior: none;
}

a {
  color: var(--yellow);
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.sr-only,
[hidden] {
  display: none !important;
}

.is-hidden,
[data-auth-only].is-hidden {
  display: none !important;
}

.app-shell {
  position: relative;
  width: 100%;
  min-height: 100vh;
  padding-bottom: 104px;
  overflow-x: hidden;
}

.nav-wrap {
  position: sticky;
  top: 0;
  z-index: 30;
  width: min(920px, calc(100% - 20px));
  margin: 0 auto;
  padding: 10px 0;
  background: transparent;
}

.nav {
  width: 100%;
  padding: 12px;
  border-radius: 20px;
  background: rgba(6, 16, 31, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.nav-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  grid-template-areas: "context logo actions" "links links links";
  align-items: center;
  gap: 0 10px;
  min-height: 42px;
}

.logo {
  grid-area: logo;
  justify-self: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  min-height: 50px;
  color: var(--text);
  text-decoration: none;
  font-size: 1.03rem;
  font-weight: 900;
  letter-spacing: -0.045em;
  line-height: 1;
  white-space: nowrap;
}

.logo span {
  color: var(--yellow);
}

.logo-img {
  display: block;
  width: auto;
  max-width: 66px;
  height: 48px;
  max-height: 48px;
  object-fit: contain;
}

@media (max-width: 430px) {
  .logo {
    min-width: 50px;
    min-height: 46px;
  }

  .logo-img {
    max-width: 60px;
    height: 44px;
    max-height: 44px;
  }
}

.context-mini {
  grid-area: context;
  justify-self: start;
  position: relative;
  display: grid;
  gap: 2px;
  width: auto;
  min-width: 0;
  min-height: 38px;
  padding: 6px 31px 6px 12px;
  border: 1px solid rgba(254, 252, 64, 0.16);
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.025));
  color: var(--muted);
  line-height: 1.05;
  text-align: left;
  white-space: nowrap;
  opacity: 0.98;
  cursor: pointer;
}

.context-mini:hover,
.context-mini:focus-visible {
  border-color: rgba(254, 252, 64, 0.32);
  background: rgba(254, 252, 64, 0.06);
  outline: none;
}

.context-mini .context-league {
  display: block;
  max-width: 118px;
  overflow: hidden;
  color: var(--text);
  font-size: 0.68rem;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.context-mini .context-roster {
  display: block;
  max-width: 118px;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.58rem;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.context-mini::after {
  content: "›";
  position: absolute;
  top: 50%;
  right: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.12);
  color: var(--yellow);
  font-size: 0.92rem;
  font-weight: 900;
  line-height: 1;
  transform: translateY(-52%);
}

.actions {
  grid-area: actions;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
}

.toggle {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(254, 252, 64, 0.22);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--yellow);
}

.toggle i,
.toggle i::before,
.toggle i::after {
  display: block;
  width: 16px;
  height: 2px;
  background: var(--yellow);
  content: "";
}

.toggle i::before {
  transform: translateY(-5px);
}

.toggle i::after {
  transform: translateY(3px);
}

.links {
  grid-area: links;
  display: none;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.nav.open .links {
  display: grid;
}

.links a {
  padding: 13px 14px;
  border: 1px solid rgba(254, 252, 64, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--yellow);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.links a.active {
  color: #06101f;
  background: var(--yellow);
}

.screen {
  display: grid;
  gap: 16px;
  width: min(920px, calc(100% - 20px));
  margin: 0 auto 26px;
}

.app-message {
  display: none;
  padding: 11px 13px;
  border: 1px solid rgba(254, 252, 64, 0.14);
  border-radius: 16px;
  background: rgba(254, 252, 64, 0.07);
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.35;
}

.app-message.show {
  display: block;
}

.app-message.error {
  border-color: rgba(255, 111, 111, 0.25);
  background: rgba(255, 111, 111, 0.08);
}

.card,
.hero,
.player-section {
  padding: 18px;
  border-radius: 22px;
  background: rgba(13, 31, 58, 0.9);
  border: 1px solid var(--border);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 21px 16px 18px;
  background:
    radial-gradient(circle at top right, rgba(254, 252, 64, 0.18), transparent 34%),
    linear-gradient(135deg, rgba(18, 40, 74, 0.98), rgba(13, 31, 58, 0.94));
  border-color: rgba(254, 252, 64, 0.14);
  text-align: center;
}

.hero::before {
  content: "";
  position: absolute;
  top: -42px;
  right: -30px;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.09);
  filter: blur(9px);
  pointer-events: none;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero-title {
  max-width: 320px;
  margin: 0 auto 13px;
  color: var(--text);
  font-size: clamp(2.32rem, 11vw, 3.16rem);
  line-height: 0.92;
  font-weight: 900;
  letter-spacing: -0.058em;
  text-transform: uppercase;
  text-align: center;
}

.hero-title span {
  display: block;
  color: var(--yellow);
}

.hero-text {
  max-width: 328px;
  margin: 0 auto 14px;
  color: var(--text);
  font-size: 0.9rem;
  line-height: 1.5;
  text-align: center;
}

.hero-badges {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  gap: 8px;
  align-items: stretch;
}

.hero-badge {
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.045);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
}

.hero-badge--small {
  display: grid;
  align-content: center;
  justify-items: center;
  padding: 10px;
  text-align: center;
}

.hero-badge--small span,
.hero-badge--big span {
  display: block;
  color: var(--muted);
  font-weight: 900;
  letter-spacing: 0.08em;
  line-height: 1.05;
  text-transform: uppercase;
}

.hero-badge--small span {
  margin-bottom: 6px;
  font-size: 0.62rem;
}

.hero-badge--small strong {
  color: var(--yellow);
  font-size: 1.05rem;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.hero-badge--big {
  display: grid;
  align-content: center;
  justify-items: center;
  padding: 12px;
  border-color: rgba(254, 252, 64, 0.23);
  background: linear-gradient(135deg, rgba(254, 252, 64, 0.10), rgba(255, 255, 255, 0.045));
  text-align: center;
}

.hero-badge--big span {
  margin-bottom: 8px;
  font-size: 0.66rem;
}

.hero-badge--big strong {
  display: block;
  color: var(--yellow);
  font-size: 1.66rem;
  font-weight: 900;
  letter-spacing: -0.045em;
  line-height: 0.95;
  white-space: nowrap;
}

.create-form {
  display: grid;
  gap: 16px;
}

.section-heading,
.player-section legend {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 0;
  margin: 0 0 14px;
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.1;
  text-transform: none;
}

.section-heading::before,
.player-section legend::before {
  content: "";
  flex: 0 0 8px;
  width: 8px;
  height: 24px;
  border-radius: 999px;
  background: var(--yellow);
  box-shadow: 0 0 0 4px rgba(254, 252, 64, 0.08);
}

.form-label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
}

input[type="text"],
input[type="email"],
input[type="password"] {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  outline: none;
}

input:focus {
  border-color: rgba(254, 252, 64, 0.48);
  box-shadow: 0 0 0 4px rgba(254, 252, 64, 0.08);
}

.listone-wrap {
  position: relative;
  display: grid;
  gap: 16px;
  border-radius: 22px;
}

.listone-head {
  display: grid;
  gap: 3px;
  padding: 2px 4px 0;
}

.listone-head span {
  color: var(--yellow);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.10em;
  line-height: 1;
  text-transform: uppercase;
}

.listone-head strong {
  color: var(--text);
  font-size: 1.16rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.player-section {
  position: relative;
  margin: 0;
  padding-top: 14px;
}

.state-line {
  display: none;
  margin: -4px 0 10px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.state-line.show {
  display: block;
}

.players-table,
.players-table tbody {
  display: block;
  width: 100%;
  border: 0;
}

.players-table tbody {
  display: grid;
  gap: 10px;
}

.players-table tr {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 74px 64px;
  align-items: center;
  gap: 8px;
  min-height: 66px;
  padding: 11px 10px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(17, 39, 72, 0.72);
}

.players-table tr.selected {
  border-color: rgba(254, 252, 64, 0.44);
  background: rgba(254, 252, 64, 0.08);
}

.players-table tr.locked {
  opacity: 0.4;
}

.players-table td {
  min-width: 0;
  color: var(--muted);
  font-size: 0.82rem;
}

.team-cell {
  display: none;
}

.players-table-head {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 74px 64px;
  align-items: center;
  gap: 8px;
  padding: 0 10px 8px;
  color: var(--muted);
  font-size: 0.56rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
}

.players-table-head span:nth-child(3) {
  display: none;
}

.players-table-head span:nth-child(4),
.players-table-head span:nth-child(5) {
  justify-self: end;
}

.stat-cell {
  display: grid;
  justify-items: end;
  min-width: 0;
  color: var(--yellow);
  font-size: 0.86rem;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.stat-cell strong {
  color: var(--yellow);
  font-size: 0.86rem;
  font-weight: 900;
}

.stat-cell--media strong {
  color: var(--text);
  font-size: 0.72rem;
}

.quota-wrap {
  display: inline-grid;
  grid-template-columns: auto 17px;
  grid-template-rows: auto auto;
  align-items: center;
  justify-content: end;
  column-gap: 5px;
  min-width: 0;
  padding: 5px 6px;
  border: 1px solid rgba(254, 252, 64, 0.12);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
  white-space: nowrap;
}

.quota-wrap strong {
  grid-column: 1;
  grid-row: 1;
  color: var(--yellow);
  line-height: 0.95;
}

.quota-initial {
  grid-column: 1;
  grid-row: 2;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.5rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  line-height: 1;
}

.quota-trend {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 17px;
  height: 17px;
  border: 1px solid rgba(254, 252, 64, 0.14);
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.075);
  color: var(--yellow);
  font-size: 0.62rem;
  font-weight: 900;
  line-height: 1;
}

.quota-trend--up,
.quota-trend--down {
  color: var(--yellow);
}

.quota-trend--same {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
  font-size: 0.62rem;
}

.player-name {
  display: -webkit-box;
  max-width: 100%;
  overflow: hidden;
  color: var(--text);
  font-size: 0.84rem;
  font-weight: 900;
  line-height: 1.14;
  white-space: normal;
  word-break: normal;
  overflow-wrap: anywhere;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.player-team {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.56rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.check {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  cursor: pointer;
}

.check input {
  position: absolute;
  inset: 0;
  z-index: 2;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.check span[aria-hidden="true"] {
  position: relative;
  display: block;
  width: 32px;
  height: 32px;
  border: 1px solid rgba(58, 87, 146, 0.72);
  border-radius: 999px;
  background: radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.16), transparent 35%), rgba(255, 255, 255, 0.045);
}

.check span[aria-hidden="true"]::before,
.check span[aria-hidden="true"]::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  background: var(--muted);
  border-radius: 999px;
}

.check span[aria-hidden="true"]::before {
  width: 12px;
  height: 2px;
}

.check span[aria-hidden="true"]::after {
  width: 2px;
  height: 12px;
}

.check input:checked + span[aria-hidden="true"] {
  border-color: var(--yellow);
  background: linear-gradient(135deg, rgba(254, 252, 64, 0.98), rgba(202, 238, 35, 0.92));
  box-shadow: 0 0 0 4px rgba(254, 252, 64, 0.13), inset 0 -8px 14px rgba(6, 16, 31, 0.12);
}

.check input:checked + span[aria-hidden="true"]::before {
  width: 13px;
  height: 3px;
  background: #06101f;
  transform: translate(3px, -1px) rotate(-45deg);
}

.check input:checked + span[aria-hidden="true"]::after {
  width: 7px;
  height: 3px;
  background: #06101f;
  transform: translate(-5px, 3px) rotate(45deg);
}

.check input:disabled + span[aria-hidden="true"] {
  opacity: 0.35;
  cursor: not-allowed;
}

.roster-summary {
  display: none;
}

.roster-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.roster-summary-grid div {
  padding: 10px;
  border: 1px solid rgba(44, 74, 126, 0.88);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.roster-summary-grid span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.roster-summary-grid strong {
  color: var(--yellow);
  font-size: 0.92rem;
  font-weight: 900;
}

.context-drawer-backdrop,
.auth-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: none;
  background: rgba(0, 0, 0, 0.46);
  backdrop-filter: blur(5px);
}

.context-drawer-backdrop.open {
  display: block;
}

.context-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 75;
  width: min(310px, 86%);
  padding: 18px;
  background: linear-gradient(180deg, rgba(13, 31, 58, 0.99), rgba(6, 16, 31, 0.99));
  border-right: 1px solid rgba(254, 252, 64, 0.12);
  box-shadow: 24px 0 70px rgba(0, 0, 0, 0.48);
  transform: translateX(-105%);
  transition: transform 0.22s ease;
}

.context-drawer.open {
  transform: translateX(0);
}

.context-drawer-head,
.auth-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.context-drawer-title,
.auth-modal-title {
  margin: 0 0 6px;
  color: var(--text);
  font-size: 1.32rem;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.context-drawer-subtitle,
.auth-modal-subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.4;
}

.context-drawer-close,
.auth-close {
  flex: 0 0 38px;
  width: 38px;
  min-height: 38px;
  height: 38px;
  padding: 0;
  border-radius: 12px;
  font-size: 20px;
  line-height: 1;
}

.context-group {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.context-group-label,
.eyebrow {
  color: var(--yellow);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.context-option {
  display: grid;
  gap: 4px;
  width: 100%;
  min-height: 58px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(58, 87, 146, 0.42);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-align: left;
  text-decoration: none;
}

.context-option.active {
  border-color: rgba(254, 252, 64, 0.35);
  background: rgba(254, 252, 64, 0.09);
}

.context-option strong {
  font-size: 0.92rem;
  line-height: 1.1;
}

.context-option span {
  color: var(--muted);
  font-size: 0.74rem;
  line-height: 1.25;
}

.locked-list-overlay {
  position: absolute;
  inset: 0;
  z-index: 12;
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 14px 14px 18px;
  border-radius: 22px;
  background: rgba(6, 16, 31, 0.48);
  backdrop-filter: blur(3px);
  box-shadow: inset 0 0 0 1px rgba(254, 252, 64, 0.08), 0 18px 55px rgba(0, 0, 0, 0.18);
}

.locked-list-overlay.open {
  display: flex;
}

.locked-list-card {
  width: min(100%, 340px);
  padding: 14px 16px;
  border: 1px solid rgba(254, 252, 64, 0.22);
  border-radius: 18px;
  background: rgba(13, 31, 58, 0.92);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.34);
  text-align: center;
}

.locked-list-card strong {
  display: block;
  margin-bottom: 8px;
  color: var(--yellow);
  font-size: 1rem;
  font-weight: 900;
}

.locked-list-card p {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.45;
}

.locked-list-card button {
  width: auto;
  min-width: 168px;
  min-height: 42px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--yellow);
  color: #06101f;
  border-color: transparent;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.auth-backdrop {
  z-index: 80;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.56);
}

.auth-backdrop.open {
  display: flex;
}

.auth-modal {
  width: min(100%, 336px);
  max-height: calc(100vh - 36px);
  overflow-y: auto;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(13, 31, 58, 0.98), rgba(6, 16, 31, 0.98));
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.52);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
}

.auth-tab {
  min-height: 38px;
  border-radius: 12px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 0.8rem;
}

.auth-tab.active {
  background: var(--yellow);
  color: #000;
}

.auth-panel {
  display: none;
  gap: 10px;
}

.auth-panel.active {
  display: grid;
}

.auth-panel button {
  min-height: 46px;
  background: var(--yellow);
  color: #000;
  border-color: transparent;
}

.auth-note {
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.45;
  text-align: center;
}

.bottom-bar,
.bottom-bar * {
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-style: normal;
  font-variant-numeric: tabular-nums;
}

.bottom-bar {
  position: fixed;
  left: max(10px, calc((100vw - 390px) / 2 + 10px));
  right: max(10px, calc((100vw - 390px) / 2 + 10px));
  bottom: 10px;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 370px;
  margin: 0 auto;
  padding: 10px;
  border: 1px solid rgba(44, 74, 126, 0.92);
  border-radius: 20px;
  background: rgba(9, 19, 37, 0.97);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.metrics {
  flex: 1 1 auto;
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.metric {
  min-width: 0;
  min-height: 48px;
  padding: 7px 8px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(44, 74, 126, 0.88);
  overflow: hidden;
}

.metric span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 8px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.metric strong {
  display: flex;
  align-items: baseline;
  gap: 1px;
  overflow: hidden;
  color: var(--yellow);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric strong b,
.metric strong span,
#total,
#requiredTotal {
  color: inherit;
  font: inherit;
  font-weight: 900;
  line-height: inherit;
  margin: 0;
  padding: 0;
}

.bottom-bar button {
  flex: 0 0 112px;
  width: 112px;
  min-height: 48px;
  padding: 0 8px;
  border-radius: 16px;
  border: 1px solid rgba(44, 74, 126, 0.88);
  background: rgba(5, 18, 38, 0.96);
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
}

.bottom-bar button.login-mode,
.bottom-bar button.attivo,
.bottom-bar button.selector-mode,
.bottom-bar button.preorder-mode {
  background: var(--yellow);
  color: #000;
  border-color: transparent;
  opacity: 1;
}

@media (min-width: 900px) {
  .nav-wrap {
    width: min(920px, calc(100% - 48px));
    padding: 18px 0 10px;
  }

  .nav {
    padding: 14px 18px;
    border-radius: 22px;
  }

  .nav-main {
    gap: 0 18px;
    min-height: 46px;
  }

  .logo {
    font-size: 1.2rem;
  }

  .context-mini {
    min-height: 40px;
    padding: 7px 34px 7px 14px;
    border-radius: 999px;
  }

  .context-mini .context-league {
    max-width: 210px;
    font-size: 0.76rem;
  }

  .context-mini .context-roster {
    max-width: 210px;
    font-size: 0.64rem;
  }

  .context-mini::after {
    right: 9px;
    width: 17px;
    height: 17px;
  }

  .links {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    border-top: 1px solid rgba(254, 252, 64, 0.10);
  }

  .links a {
    width: 100%;
    padding: 12px 14px;
    border-radius: 14px;
    font-size: 0.72rem;
    text-align: center;
    white-space: nowrap;
  }

  .screen {
    width: min(920px, calc(100% - 48px));
    gap: 20px;
    margin-bottom: 120px;
  }

  .hero {
    padding: 32px;
    border-radius: 28px;
  }

  .hero-title {
    max-width: 620px;
    margin-bottom: 18px;
    font-size: clamp(3.4rem, 5vw, 5.1rem);
  }

  .hero-text {
    max-width: 680px;
    margin-bottom: 22px;
    font-size: 1rem;
    line-height: 1.62;
  }

  .hero-badges {
    width: min(420px, 100%);
    margin: 0 auto;
    grid-template-columns: 0.8fr 1.2fr;
  }

  .hero-badge--small,
  .hero-badge--big {
    min-height: 78px;
  }

  .hero-badge--big strong {
    font-size: 2rem;
  }

  .create-form {
    gap: 20px;
  }

  .team-card,
  .player-section,
  .roster-summary {
    padding: 24px;
    border-radius: 28px;
  }

  .listone-wrap {
    gap: 20px;
    border-radius: 28px;
  }

  .listone-head {
    padding: 4px 6px 0;
  }

  .listone-head span {
    font-size: 0.74rem;
  }

  .listone-head strong {
    font-size: 1.34rem;
  }

  .locked-list-overlay {
    align-items: flex-start;
    padding-top: 22px;
    border-radius: 28px;
  }

  .section-heading,
  .player-section legend {
    margin-bottom: 18px;
    font-size: 1.24rem;
  }

  input[type="text"],
  input[type="email"],
  input[type="password"] {
    min-height: 54px;
    border-radius: 16px;
  }

  .players-table-head {
    grid-template-columns: 54px minmax(220px, 1fr) 170px 130px 130px;
    gap: 14px;
    padding: 0 18px 10px;
    font-size: 0.66rem;
  }

  .players-table-head span:nth-child(3) {
    display: block;
  }

  .players-table-head span:nth-child(4),
  .players-table-head span:nth-child(5) {
    justify-self: end;
  }

  .players-table,
  .players-table tbody {
    display: table;
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
  }

  .players-table tbody {
    display: table-row-group;
  }

  .players-table tr {
    display: table-row;
    min-height: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  .players-table td {
    display: table-cell;
    padding: 15px 18px;
    border-top: 1px solid rgba(58, 87, 146, 0.34);
    border-bottom: 1px solid rgba(58, 87, 146, 0.34);
    background: rgba(17, 39, 72, 0.72);
    vertical-align: middle;
  }

  .players-table td:first-child {
    width: 54px;
    border-left: 1px solid rgba(58, 87, 146, 0.34);
    border-radius: 16px 0 0 16px;
  }

  .players-table td:last-child {
    border-right: 1px solid rgba(58, 87, 146, 0.34);
    border-radius: 0 16px 16px 0;
  }

  .players-table tr.selected td {
    border-color: rgba(254, 252, 64, 0.44);
    background: rgba(254, 252, 64, 0.08);
  }

  .players-table tr.locked {
    opacity: 0.45;
  }

  .team-cell {
    display: table-cell;
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 800;
  }

  .stat-cell {
    display: table-cell;
    text-align: right;
  }

  .stat-cell strong {
    font-size: 0.94rem;
  }

  .stat-cell--media strong {
    font-size: 0.88rem;
  }

  .quota-wrap {
    grid-template-columns: auto 20px;
    column-gap: 7px;
    padding: 6px 8px;
    border-radius: 13px;
  }

  .quota-initial {
    font-size: 0.6rem;
  }

  .quota-trend {
    width: 20px;
    height: 20px;
    font-size: 0.68rem;
  }

  .player-name {
    display: block;
    font-size: 0.96rem;
    line-height: 1.2;
    overflow: visible;
    -webkit-line-clamp: initial;
  }

  .player-team {
    display: none;
  }

  .check {
    width: 36px;
    height: 36px;
  }

  .check span[aria-hidden="true"] {
    width: 34px;
    height: 34px;
  }

  .bottom-bar {
    left: 50%;
    right: auto;
    bottom: 18px;
    width: min(520px, calc(100% - 48px));
    max-width: 520px;
    transform: translateX(-50%);
    border-radius: 24px;
  }

  .metric {
    min-height: 54px;
  }

  .metric span {
    font-size: 9px;
  }

  .metric strong {
    font-size: 15px;
  }

  .bottom-bar button {
    flex-basis: 140px;
    width: 140px;
    min-height: 54px;
    border-radius: 18px;
    font-size: 0.86rem;
  }

  .auth-modal {
    width: min(440px, calc(100% - 48px));
  }
}


/* Dynamic tournament integration */
[hidden] {
  display: none !important;
}

.app-message.show:not([hidden]) {
  display: block;
}

.tournament-list,
.roster-list {
  display: grid;
  gap: 8px;
}

.drawer-loading {
  margin: 0;
  padding: 12px;
  border: 1px solid rgba(58, 87, 146, 0.34);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.35;
}

.context-option.disabled,
.tournament-option.disabled {
  opacity: 0.58;
}

.context-option.disabled strong,
.tournament-option.disabled strong {
  color: var(--muted);
}

.loading-row {
  display: block;
  width: 100%;
  min-height: auto;
  padding: 0;
  border: 0;
  background: transparent;
}

.loading-row td {
  display: block;
  width: 100%;
  padding: 16px;
  border: 1px solid rgba(58, 87, 146, 0.34);
  border-radius: 16px;
  background: rgba(17, 39, 72, 0.72);
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 800;
  text-align: center;
}

.bottom-bar button.preorder-mode,
.bottom-bar button.selector-mode {
  background: var(--yellow);
  color: #000;
  border-color: transparent;
  opacity: 1;
}

@media (min-width: 900px) {
  .loading-row {
    display: table-row;
  }

  .loading-row td {
    display: table-cell;
    text-align: center;
    border: 1px solid rgba(58, 87, 146, 0.34);
    border-radius: 16px;
  }
}


/* Account + registration + WhatsApp consent */
.auth-field {
  display: grid;
  gap: 6px;
}

.auth-field label {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.auth-grid {
  display: grid;
  gap: 10px;
}

.phone-confirm-box {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(58, 87, 146, 0.42);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.035);
}

.phone-confirm-box[data-state="ready"] {
  border-color: rgba(254, 252, 64, 0.30);
  background: rgba(254, 252, 64, 0.06);
}

.phone-confirm-box[data-state="confirmed"] {
  border-color: rgba(254, 252, 64, 0.44);
  background: rgba(254, 252, 64, 0.10);
}

.phone-confirm-box[data-state="error"] {
  border-color: rgba(255, 111, 111, 0.34);
  background: rgba(255, 111, 111, 0.08);
}

.phone-confirm-title {
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 900;
}

.phone-confirm-box p {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.4;
}

.phone-confirm-question {
  color: var(--yellow) !important;
  font-weight: 900;
}

.phone-confirm-actions {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 8px;
}

.phone-confirm-actions button {
  min-height: 38px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  line-height: 1.1;
}

.button-light {
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
}

.button-yellow {
  background: var(--yellow);
  border-color: transparent;
  color: #06101f;
}

.consent-box {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border: 1px solid rgba(254, 252, 64, 0.16);
  border-radius: 16px;
  background: rgba(254, 252, 64, 0.055);
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.42;
  cursor: pointer;
}

.consent-box input {
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: var(--yellow);
}

.consent-note {
  margin: -2px 0 0;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.42;
}

.auth-message {
  padding: 10px 12px;
  border-radius: 14px;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.38;
}

.auth-message.success {
  border: 1px solid rgba(254, 252, 64, 0.20);
  background: rgba(254, 252, 64, 0.07);
  color: var(--text);
}

.auth-message.error {
  border: 1px solid rgba(255, 111, 111, 0.30);
  background: rgba(255, 111, 111, 0.08);
  color: var(--text);
}

.auth-message[hidden] {
  display: none !important;
}

.app-message[hidden] {
  display: none !important;
}

.app-message.show:not([hidden]) {
  display: block;
}

@media (min-width: 620px) {
  .auth-grid {
    grid-template-columns: 1fr 1fr;
  }
}


/* Compact registration v14 */
.auth-modal {
  width: min(100%, 352px);
}

.auth-panel[data-auth-panel="register"] {
  gap: 9px;
}

.phone-mini-status {
  padding: 8px 10px;
  border: 1px solid rgba(254, 252, 64, 0.16);
  border-radius: 12px;
  background: rgba(254, 252, 64, 0.055);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1.3;
}

.phone-mini-status.confirmed {
  color: var(--yellow);
  border-color: rgba(254, 252, 64, 0.32);
  background: rgba(254, 252, 64, 0.08);
}

.phone-mini-status.error {
  color: var(--text);
  border-color: rgba(255, 111, 111, 0.30);
  background: rgba(255, 111, 111, 0.08);
}

.consent-box--compact {
  grid-template-columns: 22px minmax(0, 1fr) 28px;
  align-items: center;
  padding: 10px 11px;
  font-size: 0.76rem;
}

.consent-info {
  width: 26px !important;
  min-width: 26px;
  min-height: 26px !important;
  height: 26px;
  padding: 0 !important;
  border-radius: 999px !important;
  border: 1px solid rgba(254, 252, 64, 0.28) !important;
  background: rgba(254, 252, 64, 0.10) !important;
  color: var(--yellow) !important;
  font-size: 0.78rem !important;
  font-weight: 900 !important;
  line-height: 1 !important;
}

.auth-panel button[disabled] {
  opacity: 0.68;
  cursor: wait;
}

@media (max-width: 430px) {
  .auth-modal {
    width: min(100%, 342px);
    padding: 18px;
  }

  .auth-modal-title {
    font-size: 1.22rem;
  }

  .auth-modal-subtitle {
    font-size: 0.80rem;
  }

  .auth-field label {
    font-size: 0.66rem;
  }

  .auth-panel[data-auth-panel="register"] input {
    min-height: 44px;
  }
}


/* Compact registration v15 */
.auth-modal {
  width: min(100%, 352px);
}

.auth-panel[data-auth-panel="register"] {
  gap: 10px;
}

.auth-field input[type="text"],
.auth-field input[type="email"],
.auth-field input[type="password"],
.auth-field input[type="tel"] {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  outline: none;
  font: inherit;
}

.auth-field input:focus {
  border-color: rgba(254, 252, 64, 0.48);
  box-shadow: 0 0 0 4px rgba(254, 252, 64, 0.08);
}

.consent-box--compact {
  grid-template-columns: 22px minmax(0, 1fr) 28px;
  align-items: center;
  padding: 10px 11px;
  font-size: 0.76rem;
}

.consent-info {
  width: 26px !important;
  min-width: 26px;
  min-height: 26px !important;
  height: 26px;
  padding: 0 !important;
  border-radius: 999px !important;
  border: 1px solid rgba(254, 252, 64, 0.28) !important;
  background: rgba(254, 252, 64, 0.10) !important;
  color: var(--yellow) !important;
  font-size: 0.78rem !important;
  font-weight: 900 !important;
  line-height: 1 !important;
}

.auth-panel button[disabled] {
  opacity: 0.68;
  cursor: wait;
}

@media (max-width: 430px) {
  .auth-modal {
    width: min(100%, 342px);
    padding: 18px;
  }

  .auth-panel[data-auth-panel="register"] input {
    min-height: 46px;
  }
}


/* Menu logout */
.links .menu-logout {
  width: 100%;
  min-height: auto;
  padding: 13px 14px;
  border: 1px solid rgba(254,252,64,.12);
  border-radius: 14px;
  background: rgba(255,255,255,.035);
  color: var(--yellow);
  font: inherit;
  font-size: .78rem;
  font-weight: 900;
  letter-spacing: .08em;
  line-height: 1;
  text-align: left;
  text-transform: uppercase;
  text-decoration: none;
  box-shadow: none;
}

.links .menu-logout:hover,
.links .menu-logout:focus-visible {
  border-color: rgba(254,252,64,.32);
  background: rgba(254,252,64,.07);
  outline: none;
}

.links .menu-logout:disabled {
  opacity: .6;
  cursor: wait;
}

@media (min-width: 900px) {
  .links .menu-logout {
    text-align: center;
    white-space: nowrap;
    font-size: .72rem;
    padding: 12px 14px;
  }
}


/* Result / status popups */
.app-result-backdrop {
  z-index: 96;
}

.app-result-modal {
  display: grid;
  gap: 14px;
}

.app-result-modal .auth-modal-head {
  margin-bottom: 0;
}

.popup-primary-action,
.account-status-action {
  width: 100%;
  min-height: 46px;
  margin: 0;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 16px;
  background: var(--yellow);
  color: #06101f;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 900;
  line-height: 1;
  text-align: center;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.popup-primary-action:hover,
.popup-primary-action:focus-visible,
.account-status-action:hover,
.account-status-action:focus-visible {
  background: var(--yellow);
  color: #06101f;
  outline: none;
  box-shadow: 0 0 0 4px rgba(254, 252, 64, 0.10), 0 10px 24px rgba(0, 0, 0, 0.18);
}

.popup-primary-action:disabled,
.account-status-action:disabled {
  opacity: 0.68;
  cursor: wait;
}

.popup-status-message {
  margin: 0;
}

.auth-message.popup-status-message:not([hidden]) {
  display: block;
}


/* Password visibility toggle */
.password-input-wrap {
  position: relative;
  width: 100%;
}

.password-input-wrap input {
  padding-right: 52px !important;
}

.auth-panel button.password-toggle,
.password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px !important;
  min-width: 36px;
  min-height: 36px !important;
  height: 36px;
  padding: 0 !important;
  border: 1px solid rgba(254, 252, 64, 0.18) !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.045) !important;
  color: var(--yellow) !important;
  box-shadow: none !important;
  transform: translateY(-50%);
}

.password-toggle:hover,
.password-toggle:focus-visible {
  border-color: rgba(254, 252, 64, 0.38) !important;
  background: rgba(254, 252, 64, 0.09) !important;
  outline: none;
}

.password-toggle::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  display: none;
  width: 23px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform: translate(-50%, -50%) rotate(-42deg);
  box-shadow: 0 0 0 2px rgba(6, 16, 31, 0.92);
}

.password-toggle.visible::after {
  display: block;
}

.password-eye-svg {
  display: block;
  width: 20px;
  height: 20px;
  fill: currentColor;
}



/* Le mie rose */
.my-roses-auth,
.my-roses-empty,
.my-roses-loading {
  display: grid;
  gap: 12px;
}

.my-roses-auth[hidden],
.my-roses-empty[hidden],
.my-roses-loading[hidden],
.my-roses-list[hidden] {
  display: none !important;
}

.my-roses-auth h2,
.my-roses-empty h2 {
  margin: 0;
  color: var(--text);
  font-size: 1.28rem;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.my-roses-auth p,
.my-roses-empty p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.45;
}

.my-roses-actions,
.my-rose-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.my-roses-primary,
.my-roses-secondary,
.my-rose-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid rgba(254, 252, 64, 0.18);
  border-radius: 14px;
  background: rgba(254, 252, 64, 0.1);
  color: var(--yellow);
  font-size: 0.82rem;
  font-weight: 900;
  line-height: 1;
  text-decoration: none;
}

.my-roses-primary,
.my-rose-link.primary {
  border-color: rgba(254, 252, 64, 0.72);
  background: var(--yellow);
  color: #06101f;
}

.my-roses-secondary {
  background: rgba(255, 255, 255, 0.045);
  color: var(--text);
}

.my-roses-list {
  display: grid;
  gap: 12px;
}

.my-rose-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  border: 1px solid rgba(58, 87, 146, 0.44);
  border-radius: 22px;
  background:
    radial-gradient(circle at top right, rgba(254, 252, 64, 0.08), transparent 34%),
    rgba(13, 31, 58, 0.92);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.16);
}

.my-rose-card.is-pending {
  border-color: rgba(254, 252, 64, 0.24);
}

.my-rose-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.my-rose-kicker {
  display: block;
  max-width: 190px;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 900;
  line-height: 1.1;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.my-rose-top h2 {
  margin: 4px 0 0;
  color: var(--text);
  font-size: 1.22rem;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.035em;
}

.my-rose-status {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(254, 252, 64, 0.18);
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.08);
  color: var(--yellow);
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
}

.my-rose-status.active {
  border-color: rgba(133, 228, 148, 0.28);
  background: rgba(133, 228, 148, 0.1);
  color: #a8f0b4;
}

.my-rose-status.pending {
  border-color: rgba(254, 252, 64, 0.28);
}

.my-rose-status.locked {
  border-color: rgba(255, 139, 139, 0.24);
  background: rgba(255, 139, 139, 0.08);
  color: #ffb3b3;
}

.my-rose-meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.my-rose-meta div {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(44, 74, 126, 0.76);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
}

.my-rose-meta span,
.my-rose-details span {
  display: block;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 900;
  line-height: 1.2;
  text-transform: uppercase;
}

.my-rose-meta strong {
  display: block;
  margin-top: 5px;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.1;
  font-weight: 900;
}

.my-rose-details {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.my-rose-details span {
  min-height: 26px;
  padding: 6px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.my-rose-link.disabled,
.my-rose-link[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}

.my-rose-actions button.my-rose-link {
  font-family: inherit;
}

@media (min-width: 720px) {
  .my-rose-meta {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .my-rose-kicker {
    max-width: 360px;
  }
}


/* Titolo pagina semplice */
.page-title {
  display: grid;
  gap: 6px;
  padding: 4px 2px 0;
}

.page-title h1 {
  margin: 0;
  color: var(--text);
  font-size: clamp(1.72rem, 7vw, 2.28rem);
  line-height: 0.95;
  font-weight: 900;
  letter-spacing: -0.045em;
}

.my-roses-title {
  margin-top: 4px;
}


/* Le mie rose - rifinitura v56 */
.my-roses-dashboard {
  display: grid;
  gap: 12px;
}

.my-rose-status-wrap {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.my-rose-status-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  min-width: 26px;
  height: 26px;
  min-height: 26px;
  padding: 0;
  border: 1px solid rgba(254, 252, 64, 0.36);
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.1);
  color: var(--yellow);
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1;
}

.my-rose-expanded[hidden] {
  display: none !important;
}

.my-rose-expanded {
  display: grid;
  gap: 12px;
  margin-top: 2px;
}

.my-rose-player-section {
  display: grid;
  gap: 8px;
}

.my-rose-player-section h3 {
  margin: 0;
  color: var(--yellow);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.my-rose-players-table {
  border-spacing: 0 7px;
}

.my-rose-players-table tr.is-inactive td {
  opacity: 0.68;
}

.my-rose-player-flag {
  display: inline-flex !important;
  margin-left: 6px;
  color: #ffb3b3 !important;
  font-size: 0.62rem !important;
  font-weight: 900 !important;
  text-transform: uppercase;
}

.my-rose-details {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.my-rose-details span {
  min-height: 26px;
  padding: 6px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.my-rose-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.my-rose-actions button.my-rose-link {
  font-family: inherit;
  cursor: pointer;
}

@media (min-width: 720px) {
  .my-rose-meta {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}


/* Le mie rose - dettaglio allineato al listone v57 */
.my-rose-expanded {
  display: grid;
  gap: 14px;
}

.my-rose-player-section {
  margin: 0;
  padding: 14px;
}

.my-rose-player-section legend {
  padding: 0;
}

.my-rose-role-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  min-height: 28px;
  border: 1px solid rgba(254, 252, 64, 0.25);
  border-radius: 10px;
  background: rgba(254, 252, 64, 0.08);
  color: var(--yellow);
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1;
}

.my-rose-players-table .player-team .my-rose-player-flag {
  display: inline-flex !important;
  margin-left: 6px;
  color: #ffb3b3 !important;
  font-size: 0.62rem !important;
  font-weight: 900 !important;
  text-transform: uppercase;
}

.my-rose-players-table tr.is-inactive {
  opacity: 0.72;
}

.my-rose-players-table tr.is-inactive td {
  border-color: rgba(255, 139, 139, 0.16);
}


/* Le mie rose v58 */
.my-roses-top-action {
  display: grid;
  margin: 0 0 12px;
}

.my-roses-big-create {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 58px;
  padding: 0 18px;
  border: 1px solid rgba(254, 252, 64, 0.82);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(254, 252, 64, 1), rgba(219, 245, 39, 0.96));
  color: #06101f;
  text-decoration: none;
  font-size: 1.02rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  box-shadow: 0 18px 34px rgba(254, 252, 64, 0.12);
}

.my-rose-card.is-focused {
  border-color: rgba(254, 252, 64, 0.78);
  box-shadow: 0 0 0 4px rgba(254, 252, 64, 0.13), 0 18px 40px rgba(0, 0, 0, 0.2);
}

.my-rose-players-table tr,
.my-rose-player-section .players-table-head {
  grid-template-columns: 30px minmax(0, 1fr) 66px 58px;
  gap: 7px;
}

.my-rose-players-table .player-name {
  display: block;
  overflow: visible;
  font-size: 0.82rem;
  line-height: 1.12;
  white-space: normal;
  -webkit-line-clamp: unset;
  -webkit-box-orient: initial;
  overflow-wrap: normal;
  word-break: normal;
}

.my-rose-players-table .player-team {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  line-height: 1.18;
}

.my-rose-players-table .quota-wrap {
  padding: 5px;
}

@media (min-width: 720px) {
  .my-rose-players-table tr,
  .my-rose-player-section .players-table-head {
    grid-template-columns: 36px minmax(180px, 1fr) 120px 90px 78px;
  }

  .my-rose-player-section .team-cell,
  .my-rose-player-section .players-table-head span:nth-child(3) {
    display: block;
  }
}


/* Le mie rose - card slim v59 */
.my-roses-top-action {
  margin-bottom: 10px;
}

.my-roses-big-create {
  min-height: 50px;
  border-radius: 17px;
  font-size: 0.96rem;
}

.my-rose-card {
  gap: 10px;
  padding: 12px;
  border-radius: 18px;
}

.my-rose-top {
  gap: 8px;
}

.my-rose-kicker {
  max-width: 240px;
  font-size: 0.6rem;
  line-height: 1;
  letter-spacing: 0.05em;
}

.my-rose-top h2 {
  margin-top: 3px;
  font-size: 1.08rem;
  line-height: 1.02;
}

.my-rose-status {
  min-height: 25px;
  padding: 0 8px;
  font-size: 0.6rem;
}

.my-rose-status-info {
  width: 24px;
  min-width: 24px;
  height: 24px;
  min-height: 24px;
  font-size: 0.72rem;
}

.my-rose-meta {
  gap: 7px;
}

.my-rose-meta div {
  padding: 8px 9px;
  border-radius: 12px;
}

.my-rose-meta span,
.my-rose-details span {
  font-size: 0.58rem;
}

.my-rose-meta strong {
  margin-top: 4px;
  font-size: 0.82rem;
}

.my-rose-details {
  gap: 6px;
}

.my-rose-details span {
  min-height: 23px;
  padding: 5px 8px;
  font-size: 0.58rem;
}

.my-rose-actions {
  gap: 7px;
}

.my-rose-link {
  min-height: 36px;
  padding: 0 11px;
  border-radius: 12px;
  font-size: 0.74rem;
}

.my-rose-player-section {
  padding: 10px;
  border-radius: 15px;
}

.my-rose-player-section legend {
  font-size: 0.66rem;
}

.my-rose-players-table tr {
  min-height: 58px;
  padding: 8px;
  border-radius: 14px;
}

.my-rose-players-table .player-name {
  font-size: 0.78rem;
  line-height: 1.12;
}

.my-rose-players-table .player-team {
  font-size: 0.52rem;
}

.my-rose-role-badge {
  min-width: 24px;
  min-height: 24px;
  border-radius: 8px;
  font-size: 0.66rem;
}

@media (min-width: 720px) {
  .my-rose-card {
    padding: 14px;
  }

  .my-rose-meta {
    grid-template-columns: 1.1fr 1.1fr 0.9fr 0.9fr;
  }
}


/* Le mie rose - click card v60 */
.my-rose-card {
  cursor: pointer;
}

.my-rose-card .my-rose-status-info,
.my-rose-card .my-rose-link {
  cursor: pointer;
}

.my-rose-card-hint {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 24px;
  padding: 0 9px;
  border: 1px solid rgba(254, 252, 64, 0.14);
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.06);
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
}

.my-rose-card.is-expanded .my-rose-card-hint {
  color: var(--yellow);
  border-color: rgba(254, 252, 64, 0.28);
  background: rgba(254, 252, 64, 0.1);
}


/* Le mie rose v61 */
.my-rose-card-hint {
  display: none !important;
}


/* Allineamento listone per dettagli rosa v65 */
@media (min-width: 900px) {
  .my-rose-player-section .players-table-head {
    display: grid;
    grid-template-columns: 54px minmax(220px, 1fr) 170px 130px 130px !important;
    align-items: center;
    gap: 14px;
    padding: 0 18px 10px;
    font-size: 0.66rem;
  }

  .my-rose-player-section .players-table-head span:nth-child(3) {
    display: block !important;
  }

  .my-rose-player-section .players-table-head span:nth-child(4),
  .my-rose-player-section .players-table-head span:nth-child(5) {
    justify-self: end;
  }

  .my-rose-player-section .players-table,
  .my-rose-player-section .players-table tbody {
    display: table !important;
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
  }

  .my-rose-player-section .players-table tbody {
    display: table-row-group !important;
  }

  .my-rose-player-section .players-table tr {
    display: table-row !important;
    min-height: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
  }

  .my-rose-player-section .players-table td {
    display: table-cell !important;
    padding: 15px 18px !important;
    border-top: 1px solid rgba(58, 87, 146, 0.34);
    border-bottom: 1px solid rgba(58, 87, 146, 0.34);
    background: rgba(17, 39, 72, 0.72);
    vertical-align: middle;
  }

  .my-rose-player-section .players-table td:first-child {
    width: 54px;
    border-left: 1px solid rgba(58, 87, 146, 0.34);
    border-radius: 16px 0 0 16px;
  }

  .my-rose-player-section .players-table td:last-child {
    border-right: 1px solid rgba(58, 87, 146, 0.34);
    border-radius: 0 16px 16px 0;
  }

  .my-rose-player-section .team-cell {
    display: table-cell !important;
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 800;
  }

  .my-rose-player-section .stat-cell {
    display: table-cell !important;
    text-align: right;
  }

  .my-rose-player-section .stat-cell strong {
    font-size: 0.94rem;
  }

  .my-rose-player-section .stat-cell--media strong {
    font-size: 0.88rem;
  }

  .my-rose-player-section .quota-wrap {
    grid-template-columns: auto 20px;
    column-gap: 7px;
    padding: 6px 8px;
    border-radius: 13px;
  }

  .my-rose-player-section .quota-initial {
    font-size: 0.6rem;
  }

  .my-rose-player-section .quota-trend {
    width: 20px;
    height: 20px;
    font-size: 0.68rem;
  }

  .my-rose-player-section .player-name {
    display: block !important;
    overflow: visible !important;
    color: var(--text);
    font-size: 0.96rem !important;
    font-weight: 900;
    line-height: 1.2 !important;
    white-space: normal;
    word-break: normal;
    overflow-wrap: anywhere;
    -webkit-line-clamp: initial !important;
    -webkit-box-orient: initial !important;
  }

  .my-rose-player-section .player-team {
    display: none !important;
  }

  .my-rose-role-badge {
    min-width: 34px !important;
    min-height: 34px !important;
    border-radius: 999px;
    font-size: 0.72rem;
  }
}


/* Completa procedura */
.app-body[data-view="completa-procedura"] .screen {
  width: min(460px, calc(100% - 32px));
  min-height: calc(100vh - 106px);
  margin-bottom: 0;
  padding-bottom: 132px;
  justify-content: center;
}

.app-body[data-view="completa-procedura"] .bottom-bar {
  display: none;
}

.completion-page {
  display: grid;
  gap: 18px;
  width: 100%;
}

.completion-brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 54px;
  color: var(--text);
  font-size: 20px;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.completion-brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--yellow), #ffdc70);
  color: #071425;
  font-size: 13px;
  font-weight: 950;
}

.completion-card {
  padding: 22px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(20,39,65,.96), rgba(13,28,50,.96));
  box-shadow: 0 18px 60px rgba(0,0,0,.30);
}

.completion-status {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  margin-bottom: 18px;
  padding: 0 11px;
  border: 1px solid rgba(254,252,64,.22);
  border-radius: 999px;
  background: rgba(254,252,64,.13);
  color: var(--yellow);
  font-size: 12px;
  font-weight: 850;
}

.completion-title {
  margin: 0;
  color: var(--text);
  font-size: 32px;
  line-height: .98;
  font-weight: 950;
  letter-spacing: -0.06em;
}

.completion-subtitle {
  margin: 12px 0 22px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.4;
}

.completion-data-list {
  display: grid;
  gap: 10px;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.completion-data-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 54px;
  padding: 12px 13px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 17px;
  background: rgba(255,255,255,.045);
}

.completion-data-row span {
  flex: 0 0 auto;
  color: rgba(180,200,240,.78);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.completion-data-row strong {
  min-width: 0;
  overflow: hidden;
  color: var(--text);
  font-size: 15px;
  font-weight: 850;
  letter-spacing: -0.02em;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.completion-note {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 14px;
  border: 1px solid rgba(254,252,64,.17);
  border-radius: 18px;
  background: rgba(254,252,64,.095);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.completion-note-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 26px;
  height: 26px;
  border-radius: 10px;
  background: var(--yellow);
  color: #071425;
  font-weight: 950;
}

.completion-bottom {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 42;
  display: grid;
  gap: 12px;
  width: min(100%, 460px);
  padding: 14px 16px 18px;
  background: linear-gradient(180deg, rgba(5,12,24,0), rgba(5,12,24,.92) 24%, rgba(5,12,24,.98));
  transform: translateX(-50%);
}

.completion-primary,
.completion-secondary {
  width: 100%;
  min-height: 52px;
  border-radius: 19px;
  font-size: 15px;
  font-weight: 950;
  letter-spacing: -0.025em;
}

.completion-primary {
  border: 0;
  background: linear-gradient(135deg, var(--yellow), #ffdc70);
  color: #071425;
  box-shadow: 0 12px 35px rgba(254,252,64,.16);
}

.completion-primary:disabled {
  opacity: .58;
}

.completion-secondary {
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.055);
  color: var(--muted);
}

.completion-support-link {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}

.completion-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 96;
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 14px;
  background: rgba(3,8,16,.68);
  backdrop-filter: blur(8px);
}

.completion-modal-backdrop.is-open {
  display: flex;
}

.completion-modal {
  display: grid;
  gap: 14px;
  width: min(100%, 460px);
  padding: 20px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 28px;
  background: #101f35;
  box-shadow: 0 24px 90px rgba(0,0,0,.48);
}

.completion-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.completion-modal-title {
  margin: 0;
  color: var(--text);
  font-size: 25px;
  line-height: 1.03;
  font-weight: 950;
  letter-spacing: -0.055em;
}

.completion-modal-text {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.completion-modal-close {
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  min-height: 38px;
  padding: 0;
  border-radius: 12px;
}

.completion-modal-actions {
  display: grid;
  gap: 10px;
}

.completion-modal-message {
  padding: 10px 12px;
  border: 1px solid rgba(254,252,64,.20);
  border-radius: 14px;
  background: rgba(254,252,64,.07);
  color: var(--text);
  font-size: .78rem;
  font-weight: 800;
  line-height: 1.38;
}

.completion-modal-message.error {
  border-color: rgba(255,111,111,.30);
  background: rgba(255,111,111,.08);
}

@media (min-width: 720px) {
  .app-body[data-view="completa-procedura"] .screen {
    padding-top: 20px;
    padding-bottom: 132px;
  }

  .completion-modal-backdrop {
    align-items: center;
  }
}


/* Completa procedura standalone v76 */
.app-shell--completion {
  padding-bottom: 0;
}

.app-body[data-view="completa-procedura"] .screen {
  min-height: 100vh;
  padding-top: 18px;
}

@media (min-width: 720px) {
  .app-body[data-view="completa-procedura"] .screen {
    min-height: 100vh;
    padding-top: 32px;
  }
}


/* Completa procedura logo v77 */
.completion-brand {
  min-height: 62px;
}

.completion-logo {
  display: block;
  width: auto;
  height: 54px;
  max-width: 86px;
  object-fit: contain;
}

@media (min-width: 720px) {
  .completion-brand {
    min-height: 70px;
    margin-bottom: 2px;
  }

  .completion-logo {
    height: 62px;
    max-width: 96px;
  }
}


/* Schiera formazione */
body.app-body[data-view="schiera-formazione"] .app-shell {
  padding-bottom: 146px;
}

body.app-body[data-view="schiera-formazione"] .screen {
  width: min(1180px, calc(100% - 20px));
}

.lineup-page {
  width: 100%;
}

.lineup-loading,
.lineup-access,
.lineup-empty {
  margin-bottom: 14px;
}

.lineup-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  align-items: start;
}

.lineup-card {
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(20, 39, 65, 0.96), rgba(13, 28, 50, 0.96));
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.22);
  padding: 16px;
  margin-bottom: 0;
}

.lineup-team-row,
.lineup-head-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.lineup-team-row h2,
.lineup-card h2 {
  margin: 0;
  color: var(--text);
  font-size: 18px;
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.lineup-status-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.lineup-status-btn {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 900;
}

.lineup-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex: 0 0 auto;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.04);
}

.lineup-status-dot.is-green {
  background: #34d399;
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.12);
}

.lineup-status-dot.is-red {
  background: #fb7185;
  box-shadow: 0 0 0 4px rgba(251, 113, 133, 0.12);
}

.lineup-status-detail {
  display: block;
  max-width: 210px;
  padding: 0 3px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  line-height: 1.25;
  text-align: right;
  opacity: 0.86;
}

.lineup-field {
  position: relative;
  width: 100%;
  max-width: 282px;
  height: 350px;
  margin: 0 auto 0;
  border: 2px solid rgba(255, 255, 255, 0.72);
  border-radius: 23px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 50%, transparent 50% 100%),
    repeating-linear-gradient(180deg, #14703a 0 40px, #0e5e31 40px 80px);
  box-shadow: inset 0 0 34px rgba(0, 0, 0, 0.34), 0 18px 50px rgba(0, 0, 0, 0.28);
  overflow: hidden;
}

.lineup-field::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 2px;
  background: rgba(255, 255, 255, 0.72);
  transform: translateY(-50%);
}

.lineup-field::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 60px;
  height: 60px;
  border: 2px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  transform: translate(-50%, -50%);
}

.lineup-area {
  position: absolute;
  left: 50%;
  width: 58%;
  height: 50px;
  border: 2px solid rgba(255, 255, 255, 0.72);
  transform: translateX(-50%);
}

.lineup-area.top {
  top: 0;
  border-top: 0;
  border-radius: 0 0 18px 18px;
}

.lineup-area.bottom {
  bottom: 0;
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
}

.lineup-formation-row {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 4;
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 0 10px;
}

.lineup-formation-row.portiere {
  top: 16px;
}

.lineup-formation-row.movimento {
  top: 122px;
}

.lineup-formation-row.attacco {
  bottom: 16px;
}

.lineup-field-player {
  width: 86px;
  display: grid;
  justify-items: center;
  text-align: center;
  background: transparent;
  border: 0;
  padding: 0;
  position: relative;
  color: inherit;
}

.lineup-jersey {
  position: relative;
  width: 66px;
  height: 66px;
  display: grid;
  place-items: center;
  background: transparent;
  border: 0;
  box-shadow: none;
  isolation: isolate;
  transform: translateY(-1px);
  color: #ffd94f;
}

.lineup-jersey::before {
  content: "";
  position: absolute;
  inset: 14px 12px 10px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.08) 34%, transparent 72%);
  filter: blur(2px);
  opacity: 0.7;
  z-index: 0;
}

.lineup-jersey.is-gk {
  color: #74ccff;
}

.lineup-jersey svg {
  position: relative;
  z-index: 1;
  width: 60px;
  height: 60px;
  color: currentColor;
  fill: currentColor;
  stroke: rgba(255, 255, 255, 0.22);
  stroke-width: 0.55;
  stroke-linejoin: round;
  display: block;
  filter: drop-shadow(0 10px 12px rgba(0, 0, 0, 0.24)) drop-shadow(0 2px 0 rgba(255, 255, 255, 0.08));
}

.lineup-jersey-logo {
  position: absolute;
  left: 50%;
  top: 53%;
  transform: translate(-50%, -50%);
  z-index: 2;
  width: 22px;
  height: 22px;
  padding: 3px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(226, 234, 255, 0.18);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.14), inset 0 0 0 1px rgba(255, 255, 255, 0.18);
  pointer-events: none;
  overflow: hidden;
}

.lineup-jersey-logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}


.lineup-captain-badge {
  position: absolute;
  left: 12px;
  top: -3px;
  z-index: 6;
  width: 24px;
  height: 24px;
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--yellow);
  color: #06101f;
  font-size: 11px;
  font-weight: 950;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.22);
}

.lineup-player-name {
  max-width: 88px;
  margin-top: 5px;
  color: var(--text);
  font-size: 11px;
  line-height: 1.08;
  font-weight: 950;
  text-align: center;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.lineup-player-team {
  max-width: 88px;
  margin-top: 3px;
  color: rgba(226, 234, 255, 0.72);
  font-size: 9px;
  font-weight: 800;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lineup-counter {
  height: 30px;
  padding: 0 11px;
  border: 1px solid rgba(254, 252, 64, 0.18);
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.08);
  color: var(--yellow);
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 950;
}

.lineup-captain-card {
  padding: 12px 13px;
  border: 1px solid rgba(254, 252, 64, 0.13);
  border-radius: 17px;
  background: rgba(254, 252, 64, 0.055);
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.lineup-captain-card span {
  color: rgba(180, 200, 240, 0.68);
  font-size: 10px;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: block;
  margin-bottom: 4px;
}

.lineup-captain-card strong {
  font-size: 14px;
  color: var(--yellow);
}

.lineup-captain-card button {
  height: 34px;
  border: 1px solid rgba(254, 252, 64, 0.18);
  border-radius: 13px;
  background: rgba(254, 252, 64, 0.10);
  color: var(--yellow);
  font-size: 12px;
  font-weight: 950;
  padding: 0 11px;
}

.lineup-bench-list {
  display: grid;
  gap: 8px;
}

.lineup-bench-slot {
  min-height: 62px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(58, 87, 146, 0.34);
  border-radius: 16px;
  background: rgba(17, 39, 72, 0.72);
  width: 100%;
}

.lineup-bench-slot.is-p {
  border-left: 4px solid #7dd3fc;
}

.lineup-bench-info {
  min-width: 0;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 1px 9px;
  align-items: center;
}

.lineup-role {
  grid-row: span 2;
  width: 28px;
  height: 28px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(254, 252, 64, 0.12);
  color: var(--yellow);
  font-size: 11px;
  font-weight: 950;
}

.lineup-role.is-p {
  background: rgba(125, 211, 252, 0.13);
  color: #7dd3fc;
}

.lineup-bench-info strong {
  min-width: 0;
  font-size: 13px;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lineup-bench-info small {
  min-width: 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lineup-bench-actions {
  display: flex;
  gap: 5px;
  align-items: center;
}

.lineup-drag-handle {
  width: 32px;
  height: 32px;
  border: 1px dashed rgba(255, 255, 255, 0.16);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.04);
  color: rgba(226, 234, 255, 0.74);
  display: grid;
  place-items: center;
  font-size: 14px;
  font-weight: 950;
  line-height: 1;
  touch-action: none;
  user-select: none;
  cursor: grab;
}

.lineup-drag-handle:active {
  cursor: grabbing;
}

.lineup-bench-list.is-drag-active .lineup-bench-slot {
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease, opacity 0.16s ease;
}

.lineup-bench-slot.is-dragging {
  opacity: 0.62;
  transform: scale(0.985);
}

.lineup-bench-slot.is-drop-target {
  border-color: rgba(254, 252, 64, 0.34);
  background: rgba(254, 252, 64, 0.08);
}

.lineup-mini-btn {
  min-width: 32px;
  height: 32px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--text);
  font-size: 11px;
  font-weight: 950;
}

.lineup-swap-backdrop[hidden],
.lineup-swap-panel[hidden] {
  display: none !important;
}

.lineup-swap-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(3, 10, 19, 0.44);
  backdrop-filter: blur(3px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s ease;
  z-index: 44;
}

.lineup-swap-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}

.lineup-swap-panel {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translate(-50%, calc(100% + 24px));
  width: min(100%, 1180px);
  padding: 14px 14px 22px;
  border-radius: 26px 26px 0 0;
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-bottom: 0;
  background: linear-gradient(180deg, rgba(14, 29, 52, 0.98), rgba(8, 18, 33, 0.99));
  box-shadow: 0 -16px 44px rgba(0, 0, 0, 0.34);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.28s ease, opacity 0.28s ease;
  z-index: 50;
}

.lineup-swap-panel.is-open {
  transform: translate(-50%, 0);
  opacity: 1;
  pointer-events: auto;
}

.lineup-swap-panel-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 10px;
}

.lineup-swap-panel-head strong {
  display: block;
  font-size: 14px;
  letter-spacing: -0.02em;
}

.lineup-swap-panel-head small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.lineup-swap-close {
  min-width: 32px;
  height: 32px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font-size: 16px;
  font-weight: 900;
}

.lineup-swap-list {
  display: grid;
  gap: 8px;
  max-height: min(42vh, 340px);
  overflow-y: auto;
  padding-right: 2px;
}

.lineup-swap-item {
  width: 100%;
  min-height: 58px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  text-align: left;
}

.lineup-swap-item.is-selected {
  border-color: rgba(254, 252, 64, 0.22);
  background: rgba(254, 252, 64, 0.08);
}

.lineup-swap-item:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.lineup-swap-item .left {
  min-width: 0;
}

.lineup-swap-item strong {
  display: block;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lineup-swap-item small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lineup-swap-badge {
  flex: 0 0 auto;
  min-width: 28px;
  height: 28px;
  padding: 0 8px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(254, 252, 64, 0.12);
  color: var(--yellow);
  font-size: 11px;
  font-weight: 950;
}

.lineup-swap-badge.is-p {
  background: rgba(125, 211, 252, 0.13);
  color: #7dd3fc;
}

.lineup-bottom-bar,
.lineup-bottom-bar * {
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  font-style: normal;
  font-variant-numeric: tabular-nums;
}

.lineup-bottom-bar {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(100%, 1180px);
  padding: 12px 14px 18px;
  background: linear-gradient(180deg, rgba(5, 12, 24, 0), rgba(5, 12, 24, 0.92) 24%, rgba(5, 12, 24, 0.98));
  backdrop-filter: blur(12px);
  z-index: 40;
}

.lineup-bottom-card {
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 24px;
  background: rgba(12, 26, 48, 0.94);
  box-shadow: 0 -12px 45px rgba(0, 0, 0, 0.26);
  padding: 10px;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 0.78fr) minmax(96px, 1fr);
  gap: 8px;
  align-items: stretch;
}

.lineup-bottom-stat {
  min-width: 0;
  padding: 8px 10px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.lineup-bottom-stat small {
  display: block;
  color: rgba(180, 200, 240, 0.68);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.lineup-bottom-stat strong {
  display: block;
  font-size: 13px;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lineup-bottom-stat.timer strong {
  color: var(--yellow);
  font-size: 14px;
  letter-spacing: -0.03em;
}

.lineup-bottom-stat.compact {
  align-items: center;
  text-align: center;
  padding-left: 8px;
  padding-right: 8px;
}

.lineup-save {
  width: 100%;
  height: 100%;
  min-height: 56px;
  padding: 0 14px;
  border: 0;
  border-radius: 18px;
  background: linear-gradient(135deg, var(--yellow), #f4c72c);
  color: #071425;
  font-size: 14px;
  font-weight: 950;
  letter-spacing: -0.02em;
  box-shadow: 0 10px 28px rgba(254, 252, 64, 0.18);
  white-space: nowrap;
}

.lineup-save:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

@media (min-width: 900px) {
  body.app-body[data-view="schiera-formazione"] .screen {
    width: min(1180px, calc(100% - 48px));
  }

  body.app-body[data-view="schiera-formazione"] .nav-wrap {
    width: min(1180px, calc(100% - 48px));
  }
}

@media (min-width: 980px) {
  body.app-body[data-view="schiera-formazione"] .app-shell {
    padding-bottom: 116px;
  }

  .lineup-grid {
    grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
    gap: 18px;
  }

  .lineup-card {
    padding: 20px;
  }

  .lineup-team-row h2,
  .lineup-card h2 {
    font-size: 22px;
  }

  .lineup-field {
    max-width: 374px;
    height: 462px;
  }

  .lineup-field::after {
    width: 78px;
    height: 78px;
  }

  .lineup-area {
    height: 68px;
  }

  .lineup-formation-row {
    gap: 18px;
    padding: 0 18px;
  }

  .lineup-formation-row.portiere {
    top: 28px;
  }

  .lineup-formation-row.movimento {
    top: 178px;
  }

  .lineup-formation-row.attacco {
    bottom: 28px;
  }

  .lineup-field-player {
    width: 108px;
  }

  .lineup-jersey {
    width: 78px;
    height: 78px;
  }

  .lineup-jersey svg {
    width: 70px;
    height: 70px;
  }

  .lineup-player-name {
    max-width: 108px;
    font-size: 12px;
  }

  .lineup-player-team {
    max-width: 108px;
    font-size: 10px;
  }

  .lineup-swap-panel {
    width: min(620px, calc(100% - 48px));
  }

  .lineup-bottom-bar {
    padding: 14px 22px 22px;
  }

  .lineup-bottom-card {
    grid-template-columns: minmax(0, 1.6fr) minmax(0, 0.7fr) minmax(132px, 0.9fr);
  }

  .lineup-bottom-stat.timer strong {
    font-size: 15px;
  }
}

@media (max-width: 390px) {
  .lineup-field {
    max-width: 260px;
    height: 332px;
  }

  .lineup-field-player {
    width: 82px;
  }

  .lineup-jersey {
    width: 60px;
    height: 60px;
  }

  .lineup-jersey svg {
    width: 56px;
    height: 56px;
  }

  .lineup-player-name {
    max-width: 84px;
    font-size: 10px;
  }

  .lineup-player-team {
    max-width: 84px;
  }

  .lineup-formation-row.portiere {
    top: 14px;
  }

  .lineup-formation-row.movimento {
    top: 116px;
  }

  .lineup-formation-row.attacco {
    bottom: 14px;
  }

  .lineup-bottom-card {
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.72fr) minmax(88px, 0.9fr);
    gap: 6px;
  }

  .lineup-bottom-stat {
    padding: 8px 8px;
  }

  .lineup-bottom-stat small {
    font-size: 9px;
  }

  .lineup-bottom-stat strong {
    font-size: 12px;
  }

  .lineup-bottom-stat.timer strong {
    font-size: 13px;
  }

  .lineup-save {
    min-height: 54px;
    font-size: 13px;
    padding: 0 10px;
  }
}


/* Recupero password */
.app-body[data-view="recupera-password"] .screen {
  width: min(460px, calc(100% - 32px));
  min-height: 100vh;
  margin-bottom: 0;
  padding-top: 18px;
  padding-bottom: 28px;
  justify-content: center;
}

.password-reset-page {
  align-content: center;
}

.password-reset-card h1 {
  margin: 0;
  color: var(--text);
  font-size: 31px;
  line-height: 1;
  font-weight: 950;
  letter-spacing: -0.055em;
}

.password-reset-form {
  margin: 0;
}

.password-reset-field {
  display: grid;
  gap: 8px;
}

.password-reset-field span,
.auth-inline-help {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.35;
}

.password-reset-field input {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(255, 255, 255, 0.095);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--text);
  font: inherit;
  font-weight: 800;
  outline: none;
  padding: 0 13px;
}

.password-reset-field input:focus {
  border-color: rgba(254, 252, 64, 0.38);
  box-shadow: 0 0 0 4px rgba(254, 252, 64, 0.08);
}

.completion-main-button {
  width: 100%;
  min-height: 52px;
  border: 0;
  border-radius: 19px;
  background: linear-gradient(135deg, var(--yellow), #ffdc70);
  color: #071425;
  font-size: 15px;
  font-weight: 950;
  letter-spacing: -0.025em;
  box-shadow: 0 12px 35px rgba(254,252,64,.16);
}

.completion-main-button:disabled {
  opacity: .62;
  cursor: wait;
}

.completion-secondary-link {
  display: block;
  margin-top: 16px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 850;
  text-align: center;
  text-decoration: none;
}

.completion-message {
  padding: 10px 12px;
  border: 1px solid rgba(254, 252, 64, 0.20);
  border-radius: 14px;
  background: rgba(254, 252, 64, 0.07);
  color: var(--text);
  font-size: .78rem;
  font-weight: 800;
  line-height: 1.38;
}

.completion-message.error {
  border-color: rgba(255, 111, 111, 0.30);
  background: rgba(255, 111, 111, 0.08);
}

.completion-message[hidden] {
  display: none !important;
}

.auth-link-button,
.auth-secondary-button {
  width: 100%;
  min-height: 40px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 900;
}

.auth-link-button {
  border: 1px solid rgba(254, 252, 64, 0.18) !important;
  background: rgba(254, 252, 64, 0.07) !important;
  color: var(--yellow) !important;
}

.auth-secondary-button {
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  background: rgba(255, 255, 255, 0.045) !important;
  color: var(--muted) !important;
}

.auth-inline-help {
  margin: -2px 0 0;
}

@media (min-width: 720px) {
  .app-body[data-view="recupera-password"] .screen {
    padding-top: 32px;
  }
}


/* Regolamento Fantacalcio */
.rules-page {
  display: grid;
  gap: 16px;
  padding: 4px 0 28px;
}

.rules-hero,
.rules-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(58, 87, 146, 0.34);
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(58, 87, 146, 0.24), transparent 36%),
    rgba(6, 16, 31, 0.86);
  box-shadow: var(--shadow);
}

.rules-hero {
  display: grid;
  gap: 10px;
  justify-items: center;
  padding: 28px 18px 26px;
  text-align: center;
}

.rules-hero-logo-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 82px;
  height: 82px;
  border: 1px solid rgba(254, 252, 64, 0.18);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.035);
}

.rules-hero-logo {
  display: block;
  width: auto;
  max-width: 62px;
  max-height: 62px;
  object-fit: contain;
}

.rules-kicker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 5px 14px;
  border: 1px solid rgba(254, 252, 64, 0.24);
  border-radius: 999px;
  background: rgba(254, 252, 64, 0.08);
  color: var(--yellow);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.rules-hero h1 {
  margin: 0;
  color: var(--text);
  font-size: clamp(2rem, 8vw, 3.25rem);
  font-weight: 950;
  line-height: 0.96;
  letter-spacing: -0.065em;
  text-transform: uppercase;
}

.rules-hero h1 span {
  color: var(--yellow);
}

.rules-hero p {
  max-width: 520px;
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
}

.rules-card {
  display: grid;
  gap: 13px;
  padding: 20px 16px;
}

.rules-card::after {
  content: "";
  position: absolute;
  right: -46px;
  bottom: -60px;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(254, 252, 64, 0.055), transparent 70%);
  pointer-events: none;
}

.rules-number {
  position: absolute;
  top: -12px;
  right: 14px;
  color: rgba(254, 252, 64, 0.045);
  font-size: 5.4rem;
  font-weight: 950;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}

.rules-card h2 {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 4px 0 0;
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 950;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}

.rules-card h2::before {
  content: "";
  width: 5px;
  height: 22px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--yellow);
}

.rules-card p {
  position: relative;
  z-index: 1;
  margin: 0;
  color: var(--muted);
  font-size: 0.93rem;
  line-height: 1.58;
}

.rules-card strong {
  color: var(--text);
}

.rules-tile {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 13px 13px;
  border: 1px solid rgba(58, 87, 146, 0.32);
  border-left: 4px solid rgba(58, 87, 146, 0.9);
  border-radius: 16px;
  background: rgba(58, 87, 146, 0.13);
  color: var(--text);
  font-size: 0.91rem;
  line-height: 1.48;
}

.rules-tile--highlight {
  border-left-color: var(--yellow);
  background: rgba(254, 252, 64, 0.055);
}

.rules-tile--danger {
  border-left-color: #ef4444;
  background: rgba(239, 68, 68, 0.075);
}

.rules-tile-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 31px;
  min-width: 31px;
  height: 31px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.055);
  font-size: 1.05rem;
}

.rules-note {
  color: var(--yellow) !important;
  font-size: 0.88rem !important;
  font-style: italic;
}

.rules-table-wrap {
  position: relative;
  z-index: 1;
  overflow: hidden;
  border: 1px solid rgba(58, 87, 146, 0.32);
  border-radius: 16px;
  background: rgba(3, 10, 22, 0.36);
}

.rules-table {
  width: 100%;
  border-collapse: collapse;
}

.rules-table tr {
  border-bottom: 1px solid rgba(58, 87, 146, 0.18);
}

.rules-table tr:last-child {
  border-bottom: 0;
}

.rules-table td {
  padding: 10px 12px;
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 800;
}

.rules-table td:last-child {
  width: 76px;
  text-align: right;
}

.rules-badge {
  display: inline-flex;
  min-width: 52px;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 950;
}

.rules-badge--bonus {
  background: rgba(16, 185, 129, 0.16);
  color: #34d399;
}

.rules-badge--malus {
  background: rgba(239, 68, 68, 0.16);
  color: #f87171;
}

.rules-list {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.rules-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.rules-list-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  min-width: 24px;
  height: 24px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--yellow);
  font-weight: 950;
}

.rules-good {
  color: #34d399 !important;
}

.rules-bad {
  color: #f87171 !important;
}

@media (min-width: 760px) {
  .rules-page {
    gap: 18px;
  }

  .rules-hero {
    padding: 36px 24px 34px;
  }

  .rules-card {
    padding: 24px 22px;
  }

  .rules-card h2 {
    font-size: 1.16rem;
  }

  .rules-card p,
  .rules-tile,
  .rules-list li {
    font-size: 0.98rem;
  }
}
