.cal-week,
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}
.cal-week {
  margin-top: 14px;
  text-align: center;
  color: #f1cd72;
  font-weight: 800;
}
.cal-day {
  min-height: 64px;
  padding: 5px 2px;
  background: #0c283b;
  border: 1px solid #29485b;
  border-radius: 7px;
  color: #fff;
  text-align: left;
  overflow: hidden;
}
.cal-day strong {
  display: block;
  font-size: 13px;
}
.cal-day small {
  display: block;
  font-size: 8px;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #c7dbea;
}
.cal-day.has-games {
  border-color: #c69e4a;
  background: #164336;
}
.cal-day.empty {
  background: transparent;
  border: 0;
}
.cal-match {
  padding: 13px 8px;
  border-bottom: 1px solid #355269;
}
.cal-match .row {
  margin: 7px 0;
  gap: 5px;
}
.cal-match .row b {
  flex: 1;
  font-size: 12px;
}
.cal-match .score {
  min-width: 65px;
}
.cal-match .btn {
  margin-top: 5px;
}
@media (min-width: 600px) {
  .cal-day {
    min-height: 100px;
  }
  .cal-day small {
    font-size: 11px;
  }
}

:root {
  font-family:
    system-ui,
    -apple-system,
    Segoe UI,
    sans-serif;
  color: #eaf1ff;
  background: #071222;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
}
.app {
  max-width: 1100px;
  margin: auto;
  min-height: 100vh;
  padding: 18px 15px 95px;
}
.head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.brand {
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.3px;
}
.muted {
  color: #9aadc7;
  font-size: 13px;
}
.gold {
  color: #e8bd67;
}
.pill {
  border: 1px solid #3a536d;
  background: #1a2d45;
  color: #eaf1ff;
  border-radius: 100px;
  padding: 8px 11px;
}
.tabs,
.chips {
  display: flex;
  gap: 7px;
  overflow: auto;
  padding: 12px 0;
}
.tabs button,
.chips button {
  white-space: nowrap;
  border: 1px solid #2b4560;
  background: #12263e;
  color: #d6e4f6;
  padding: 10px 13px;
  border-radius: 12px;
}
.tabs button.active,
.chips button.active {
  background: #1c7852;
  border-color: #36b67e;
  color: white;
}
.panel {
  background: #11233a;
  border: 1px solid #29425c;
  border-radius: 17px;
  padding: 16px;
  margin: 13px 0;
}
.hero {
  background: linear-gradient(120deg, #173c3d, #102541 65%, #192b4b);
  padding: 22px;
  border-radius: 20px;
  border: 1px solid #355c61;
}
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 15px 0;
}
.stat {
  background: #192f47;
  padding: 13px 6px;
  text-align: center;
  border-radius: 13px;
}
.stat b {
  display: block;
  font-size: 23px;
  color: #e8bd67;
}
.stat small {
  color: #b8c8db;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
}
.tile {
  background: #172d46;
  border: 1px solid #2a4967;
  border-radius: 14px;
  padding: 15px;
}
.tile b {
  display: block;
  margin-bottom: 6px;
}
.tile p {
  font-size: 13px;
  color: #a8bbd0;
  margin: 0;
}
.btn {
  background: #21845d;
  color: white;
  border: 0;
  border-radius: 11px;
  padding: 11px 14px;
  font-weight: 700;
}
.btn.alt {
  background: #2b435e;
}
.btn.danger {
  background: #8b3c4a;
}
.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
input,
select,
textarea {
  background: #091b30;
  border: 1px solid #38546f;
  border-radius: 10px;
  color: #fff;
  padding: 11px;
  width: 100%;
  margin: 5px 0 12px;
}
label {
  font-size: 13px;
  color: #bdcde0;
}
h2 {
  font-size: 20px;
  margin: 16px 0 8px;
}
h3 {
  font-size: 16px;
  margin: 12px 0;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
th,
td {
  padding: 10px 5px;
  border-bottom: 1px solid #2a3d55;
  text-align: left;
}
th {
  color: #9cb2cd;
  font-size: 11px;
}
td.num,
th.num {
  text-align: center;
}
.match {
  display: grid;
  grid-template-columns: 1fr 64px 1fr;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid #2a3d55;
  padding: 11px 0;
  font-size: 13px;
}
.score {
  text-align: center;
  background: #223b52;
  border-radius: 8px;
  padding: 9px 3px;
  font-weight: 800;
}
.right {
  text-align: right;
}
.notice {
  border-left: 3px solid #e8bd67;
  padding: 11px;
  background: #21314a;
  border-radius: 7px;
  color: #d9e6f4;
  font-size: 13px;
}
.badge {
  display: inline-block;
  font-size: 11px;
  border-radius: 30px;
  padding: 4px 8px;
  background: #254e48;
  color: #b4f1cf;
}
.nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #0c1c30;
  border-top: 1px solid #2a4562;
  display: flex;
  justify-content: center;
  gap: 2px;
  padding: 8px max(10px, env(safe-area-inset-right)) calc(9px + env(safe-area-inset-bottom));
  z-index: 5;
}
.nav button {
  color: #b5c8df;
  background: transparent;
  border: 0;
  padding: 7px 10px;
  font-size: 11px;
}
.nav button.active {
  color: #e8bd67;
}
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
}
.stack {
  display: grid;
  gap: 8px;
}
.scroll {
  overflow: auto;
}
.exercise {
  border-bottom: 1px solid #31465e;
  padding: 12px 0;
}
.exercise button {
  margin-left: 5px;
}
.field {
  position: relative;
  max-width: 370px;
  aspect-ratio: 0.75;
  background: repeating-linear-gradient(0deg, #166d40 0 45px, #207e4b 45px 90px);
  border: 3px solid white;
  border-radius: 6px;
  margin: auto;
}
.field:before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  border-top: 2px solid #ffffffaa;
}
.field:after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 80px;
  height: 80px;
  border: 2px solid #ffffffaa;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}
.player {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 32px;
  height: 32px;
  background: #0d294e;
  border: 2px solid #e8bd67;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 800;
  z-index: 2;
}
.small {
  font-size: 12px;
}
.hidden {
  display: none;
}
@media (min-width: 800px) {
  .app {
    padding-bottom: 30px;
  }
  .nav {
    position: static;
    max-width: 1100px;
    margin: 0 auto;
    border-radius: 15px;
  }
  .nav button {
    font-size: 14px;
  }
}

/* EDICIÓN ESTADIO NOCTURNO · REFERENCIA VISUAL APORTADA POR EL USUARIO */
:root {
  font-family:
    Inter,
    system-ui,
    -apple-system,
    Segoe UI,
    sans-serif;
  color: #f7f9ff;
  background: #061322;
  --gold: #ffd36a;
  --navy: #061a2d;
  --edge: #335269;
}
body {
  background: radial-gradient(ellipse at 50% -8%, #14446a 0%, #061322 52%, #040c18 100%);
  min-height: 100vh;
}
.app {
  max-width: 1100px;
  padding: 0 13px 106px;
  position: relative;
}
.app:before {
  content: '';
  position: fixed;
  pointer-events: none;
  inset: 0 0 auto;
  height: 260px;
  background: radial-gradient(ellipse at 12% 15%, #a5e9ff48, transparent 14%),
    radial-gradient(ellipse at 90% 17%, #a5e9ff45, transparent 14%),
    linear-gradient(180deg, #09213a99, #07162500);
  z-index: -1;
}
.head {
  position: relative;
  min-height: 176px;
  display: flex;
  align-items: flex-start;
  padding: 20px 4px 12px;
  border-bottom: 2px solid #c99d3e;
  background: radial-gradient(ellipse at 50% 110%, #217b34aa, transparent 46%);
  gap: 8px;
}
.head:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 22px;
  background: repeating-linear-gradient(100deg, #23773c 0 40px, #1b6834 40px 80px);
  opacity: 0.65;
  z-index: -1;
}
.brandbox {
  flex: 1;
  text-align: center;
  min-width: 0;
}
.brandmark {
  font-size: 35px;
  line-height: 1;
  filter: drop-shadow(0 2px 8px #000);
}
.brand {
  display: inline-block;
  border: 2px solid #e7bb5e;
  transform: skew(-6deg);
  padding: 8px 12px;
  background: #071e31;
  font-size: clamp(16px, 4vw, 24px);
  font-weight: 950;
  letter-spacing: 0.4px;
  box-shadow: 0 5px 16px #0008;
  color: #fff;
  text-shadow: 0 2px 2px #000;
}
.brand .gold {
  color: #ffda76;
}
.league-sub {
  margin-top: 10px;
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 2px;
}
.muted {
  color: #bac9d9;
}
.head .muted {
  font-weight: 600;
  color: #f0f4fa;
  margin-top: 6px;
}
.head-side {
  width: 40px;
  flex: 0 0 40px;
  display: grid;
  place-items: center;
}
.head-side button {
  background: #0a2439;
  border: 1px solid #36546a;
  color: #f5cf72;
  border-radius: 12px;
  font-size: 19px;
  width: 38px;
  height: 38px;
}
.head #roleBtn {
  position: absolute;
  right: 2px;
  top: 20px;
  max-width: 116px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
  padding: 8px 6px;
  border: 1px solid #3b5872;
  background: #0c2439e8;
  color: #fff;
}
.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  padding: 13px 2px 7px;
}
.tabs button {
  border-radius: 0;
  background: #0b2235;
  color: #eaf0f8;
  font-size: 15px;
  font-weight: 800;
  padding: 12px 8px;
  border: 1px solid #47616c;
}
.tabs button:first-child {
  border-radius: 12px 0 0 12px;
}
.tabs button:last-child {
  border-radius: 0 12px 12px 0;
}
.tabs button.active,
.chips button.active {
  background: linear-gradient(180deg, #ffe59b, #d6a132);
  color: #1e1a0c;
  border-color: #ffd978;
  box-shadow: inset 0 1px #fff8;
}
.hero {
  background: linear-gradient(180deg, #071b2eeb 0%, #0b2c3edc 58%, #12632d88 100%);
  border: 1px solid #5d7c73;
  border-radius: 16px;
  padding: 20px 16px;
  box-shadow: 0 6px 18px #0007;
  position: relative;
  overflow: hidden;
}
.hero:after {
  content: '';
  position: absolute;
  inset: auto 0 0;
  height: 18px;
  background: repeating-linear-gradient(100deg, #237c39 0 35px, #1b6430 35px 70px);
  opacity: 0.6;
  pointer-events: none;
}
.hero h2 {
  color: #fff;
  text-shadow: 0 2px 5px #000;
  font-size: 22px;
}
.hero p {
  color: #e5edf7;
}
.panel {
  background: linear-gradient(155deg, #132d42, #091b2b 75%);
  border: 1px solid #38566a;
  border-radius: 14px;
  padding: 14px;
  margin: 12px 0;
  box-shadow: 0 5px 15px #0005;
}
.panel h2,
.panel h3 {
  color: #fff;
}
.stat {
  background: linear-gradient(180deg, #173d4b, #0c2638);
  border: 1px solid #3a5d66;
  border-radius: 12px;
}
.stat b {
  color: #ffcf60;
}
.tile {
  background: linear-gradient(145deg, #123950, #091f32);
  border: 1px solid #416076;
  box-shadow:
    inset 0 1px #ffffff0d,
    0 3px 9px #0004;
}
.tile b {
  color: #fff;
}
.tile p {
  color: #c4d1df;
}
.grid .tile:nth-child(4n + 1) {
  border-top: 3px solid #26a96a;
}
.grid .tile:nth-child(4n + 2) {
  border-top: 3px solid #e0ad45;
}
.grid .tile:nth-child(4n + 3) {
  border-top: 3px solid #8268c7;
}
.grid .tile:nth-child(4n) {
  border-top: 3px solid #419ac9;
}
.btn {
  background: linear-gradient(180deg, #e9bd60, #c28d2e);
  color: #111b25;
  box-shadow: 0 2px 8px #0005;
  border: 1px solid #f8d87e;
}
.btn.alt {
  background: #1a4660;
  color: #fff;
  border-color: #46677a;
}
.btn.danger {
  background: #913c47;
  color: #fff;
  border-color: #bd6871;
}
.pill {
  background: #102d41;
  border-color: #4b697c;
}
.score {
  background: linear-gradient(180deg, #22862c, #125f25);
  border: 1px solid #42a24b;
  color: #fff;
  font-size: 16px;
  box-shadow: 0 2px 8px #0005;
}
.match {
  grid-template-columns: minmax(0, 1fr) 70px minmax(0, 1fr);
  background: linear-gradient(135deg, #17374a, #0b2438);
  border: 1px solid #37596c;
  border-radius: 11px;
  padding: 12px 9px;
  margin: 7px 0;
  min-height: 65px;
  font-weight: 650;
}
.notice {
  background: #142e40;
  border-color: #f4c15d;
}
.badge {
  background: #1d7339;
  color: #eaffed;
  font-weight: 800;
}
table {
  font-size: 12px;
}
th {
  background: #091e31;
  color: #f6d477;
  position: sticky;
  top: 0;
}
td {
  border-color: #2c4b5c;
}
tbody tr:nth-child(odd) {
  background: #102e3d;
}
tbody tr:nth-child(even) {
  background: #0b2132;
}
td.num:last-child {
  color: #f7d56b;
  font-weight: 900;
}
.nav {
  background: linear-gradient(180deg, #0b263d, #051424);
  border-top: 2px solid #4a6376;
  justify-content: space-around;
  gap: 0;
  padding: 5px 5px calc(7px + env(safe-area-inset-bottom));
  box-shadow: 0 -5px 22px #0008;
  overflow-x: auto;
}
.nav button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 61px;
  flex: 1;
  padding: 6px 3px;
  font-size: 10px;
  white-space: nowrap;
  gap: 4px;
}
.nav button .nav-icon {
  font-size: 21px;
  line-height: 1.1;
}
.nav button.active {
  color: #ffd46c;
  font-weight: 900;
}
.nav button.active .nav-icon {
  filter: drop-shadow(0 0 5px #e4ac42);
}
input,
select,
textarea {
  background: #061b2b;
  border-color: #426175;
  color: #fff;
}
.chips button {
  background: #123348;
  color: #edf4fa;
  border-color: #3b5b70;
}
.field {
  box-shadow: 0 8px 22px #0009;
  border-color: #e9f4f2;
}
.player {
  box-shadow: 0 2px 6px #000a;
}
@media (min-width: 800px) {
  .app {
    padding-bottom: 35px;
  }
  .head {
    min-height: 190px;
  }
  .nav {
    position: sticky;
    bottom: 0;
    max-width: 1100px;
    margin: auto;
    border-radius: 16px 16px 0 0;
  }
  .nav button {
    font-size: 12px;
  }
}
:root {
  --gold: #e8bd67;
  --midnight: #071526;
}
body {
  background: radial-gradient(ellipse at 50% -10%, #174653 0, #071526 56%);
  color: #eff5fb;
}
.app {
  max-width: 1160px;
}
.hero.pro-hero {
  background: linear-gradient(125deg, #143e49, #0a1b35 70%);
  border: 1px solid #a58249;
  box-shadow: 0 15px 35px #0004;
}
.pro-hero h2 {
  font-size: clamp(26px, 4vw, 38px);
  letter-spacing: -0.03em;
  margin: 8px 0;
}
.eyebrow {
  color: #e9c577;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
}
.panel {
  box-shadow: 0 12px 28px #0003;
  border-color: #36526b;
}
.panel h2 {
  font-size: 19px;
  color: #f4d18a;
}
.club-crest {
  height: 26px;
  width: 26px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 5px;
  background: #e9eef0;
  padding: 2px;
}
.club-crest.large {
  height: 76px;
  width: 76px;
  padding: 6px;
  border-radius: 16px;
}
.club-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  text-align: left;
}
.club-label span {
  overflow-wrap: anywhere;
}
.pro-table {
  min-width: 580px;
  font-size: 13px;
}
.pro-table td,
.pro-table th {
  text-align: center;
  padding: 11px 6px;
}
.pro-table td:nth-child(2),
.pro-table th:nth-child(2) {
  text-align: left;
  min-width: 160px;
}
.pro-table tr:hover {
  background: #1c3b50;
}
.pro-table .leader {
  background: #153d37;
}
.position {
  display: inline-flex;
  width: 23px;
  height: 23px;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  background: #243d54;
  font-weight: 800;
}
.leader .position {
  background: #2c9569;
}
.points {
  color: #f1d18c;
  font-size: 16px;
}
.pro-match {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 72px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 14px 3px;
  border-bottom: 1px solid #2b4760;
}
.pro-match .away .club-label {
  flex-direction: row-reverse;
  text-align: right;
}
.pro-match .score {
  background: #1d4b4b;
  color: #f8d98e;
  font-size: 17px;
}
.club-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(155px, 1fr));
  gap: 12px;
}
.club-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
  padding: 20px 10px;
  background: linear-gradient(160deg, #193a4b, #0b2036);
  border: 1px solid #3c5969;
  border-radius: 16px;
}
.club-tile strong {
  font-size: 14px;
}
.club-tile span {
  font-size: 12px;
  color: #b7cbdc;
}
.nav button {
  min-width: 68px;
}
.nav button.active {
  background: #1b3e48;
  border-radius: 12px;
}
@media (max-width: 440px) {
  .pro-match {
    gap: 5px;
    font-size: 11px;
  }
  .pro-match .score {
    font-size: 15px;
  }
  .club-crest {
    width: 22px;
    height: 22px;
  }
  .club-label {
    gap: 4px;
  }
  .pro-table {
    font-size: 12px;
  }
}
.club-grid {
  grid-template-columns: 1fr;
  gap: 8px;
}
.club-tile {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  column-gap: 12px;
  text-align: left;
  min-height: 68px;
  padding: 10px 12px;
  border-radius: 13px;
}
.club-tile .club-crest.large {
  grid-row: 1/3;
  width: 46px;
  height: 46px;
  padding: 2px;
  background: transparent;
  border-radius: 0;
}
.club-tile strong {
  font-size: 14px;
  line-height: 1.25;
}
.club-tile > span {
  font-size: 12px;
}
.club-crest {
  background: transparent;
  border-radius: 0;
  padding: 0;
  object-fit: contain;
}
.cal-match .club-label {
  font-size: 12px;
  gap: 5px;
}
.cal-match .club-crest {
  width: 23px;
  height: 23px;
}
.cal-match .row {
  gap: 6px;
}
.cal-match .row > b {
  min-width: 0;
  flex: 1;
}
.cal-match .score,
.cal-match .badge {
  flex-shrink: 0;
}
@media (min-width: 650px) {
  .club-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 420px) {
  .pro-table {
    font-size: 11px;
  }
  .pro-table td,
  .pro-table th {
    padding: 8px 4px;
  }
}
#appMenuOverlay {
  position: fixed;
  inset: 0;
  background: #000a;
  z-index: 99990;
  display: none;
}
#appMenuOverlay.open {
  display: block;
}
#appMenuDrawer {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: min(85vw, 340px);
  background: linear-gradient(155deg, #102e43, #071a2d);
  border-right: 2px solid #d8b35b;
  box-shadow: 8px 0 35px #0008;
  padding: 20px 16px;
  overflow: auto;
  color: #fff;
  box-sizing: border-box;
}
#appMenuDrawer h2 {
  color: #e9c36c;
  font-size: 20px;
  margin: 12px 0 6px;
}
#appMenuDrawer p {
  font-size: 13px;
  color: #b5c9d7;
  line-height: 1.45;
}
#appMenuDrawer button {
  display: block;
  width: 100%;
  margin: 8px 0;
  padding: 13px 12px;
  background: #193a51;
  border: 1px solid #45677d;
  border-radius: 12px;
  text-align: left;
  color: #fff;
  font-size: 15px;
}
#appMenuDrawer button:focus-visible {
  outline: 3px solid #e9c36c;
}
#appMenuDrawer .menu-close {
  width: auto;
  float: right;
  background: #2d4a5e;
}
#appMenuDrawer .menu-note {
  border-top: 1px solid #38566a;
  padding-top: 12px;
  margin-top: 18px;
}
body.menu-open {
  overflow: hidden;
}
.club-crest {
  object-fit: contain;
  object-position: center;
  box-sizing: border-box;
  flex-shrink: 0;
}
.club-tile .club-crest.large {
  width: 64px;
  height: 64px;
  padding: 3px;
  object-fit: contain;
}
.club-tile {
  min-width: 0;
}
.club-label > span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.club-crest,
.club-crest.large,
.club-tile .club-crest.large {
  background: transparent !important;
  object-fit: contain !important;
  object-position: center;
  padding: 0 !important;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.club-tile {
  display: grid !important;
  grid-template-columns: 64px minmax(0, 1fr) !important;
  grid-template-rows: auto !important;
  gap: 14px !important;
  align-items: center;
  min-height: 86px;
}
.club-tile .club-crest.large {
  grid-row: auto;
  width: 64px !important;
  height: 64px !important;
}
.club-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.club-info strong,
.club-info span {
  display: block;
  overflow-wrap: anywhere;
  white-space: normal;
}
.club-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 600px) {
  .club-grid {
    grid-template-columns: 1fr;
  }
}
.account-return {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}
.account-return a,
.menu-account {
  display: block;
  padding: 10px 14px;
  border: 1px solid #c5a55a;
  border-radius: 9px;
  background: #18394d;
  color: #f4d18a;
  text-decoration: none;
  font-weight: 700;
}
.menu-account {
  margin: 10px 0;
}
.head-side button {
  position: relative;
  z-index: 2;
}
.promotion td:first-child {
  border-left: 4px solid #38c878;
}
.relegation td:first-child {
  border-left: 4px solid #ef6464;
}
.account-direct {
  display: block;
  text-align: center;
  padding: 10px;
  color: #f1d38c;
  font-weight: 700;
}
html {
  scroll-padding-top: calc(12px + env(safe-area-inset-top));
  scroll-padding-bottom: calc(90px + env(safe-area-inset-bottom));
}
body {
  padding-top: env(safe-area-inset-top);
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}
button,
a {
  touch-action: manipulation;
}
@media (max-width: 700px) {
  button {
    min-height: 44px;
  }
}
@media (max-width: 700px) {
  .account-return {
    display: none !important;
  }
  .head button {
    min-width: 44px;
    min-height: 48px;
  }
  .nav {
    position: fixed !important;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: none;
    border-radius: 0;
    padding: 6px max(5px, env(safe-area-inset-right)) calc(8px + env(safe-area-inset-bottom))
      max(5px, env(safe-area-inset-left));
    justify-content: flex-start;
    overflow-x: auto;
  }
  .nav button {
    flex: 1 0 60px;
    min-height: 58px;
  }
  .app {
    padding-bottom: calc(105px + env(safe-area-inset-bottom));
  }
  #appMenuOverlay {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
  }
}
#appMenuDrawer {
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
}
#appMenuDrawer .menu-close {
  position: sticky;
  top: 0;
  z-index: 2;
}
#appMenuDrawer .menu-secondary {
  font-size: 13px;
  font-weight: 500;
  border-color: #45677d;
  color: #b5c9d7;
}
.sync-retry {
  margin: 0 0 12px;
  min-height: 40px;
}
.sync-retry:focus-visible {
  outline: 3px solid #e9c36c;
}
.standings-mobile {
  display: none;
}
@media (max-width: 760px) {
  .standings-desktop {
    display: none;
  }
  .standings-mobile {
    display: grid;
    gap: 8px;
  }
  .standing-card {
    background: #102e3d;
    border: 1px solid #38566a;
    border-radius: 9px;
    padding: 9px;
    min-width: 0;
  }
  .standing-card.promotion {
    border-left: 4px solid #32b87b;
  }
  .standing-card.relegation {
    border-left: 4px solid #ff646b;
  }
  .standing-card.leader {
    background: #153d37;
  }
  .standing-top {
    display: flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
    font-size: 13px;
  }
  .standing-top .club-label {
    min-width: 0;
    white-space: normal;
  }
  .standing-points {
    margin-left: auto;
    white-space: nowrap;
    color: #ffcf60;
    font-size: 15px;
  }
  .standing-stats {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 2px;
    margin-top: 8px;
    border-top: 1px solid #38566a;
    padding-top: 6px;
    text-align: center;
  }
  .standing-stats small,
  .standing-stats b {
    display: block;
    font-size: 11px;
  }
  .standing-stats small {
    color: #b7cbd8;
  }
  .standing-stats b {
    font-size: 13px;
    margin-top: 3px;
  }
}
button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible {
  outline: 3px solid #f3d37c;
  outline-offset: 2px;
}
button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #e9c46a;
  outline-offset: 3px;
}
button:disabled {
  cursor: not-allowed;
}
input,
select,
textarea {
  max-width: 100%;
  box-sizing: border-box;
}
@media (max-width: 600px) {
  input,
  select,
  textarea {
    font-size: 16px !important;
  }
  button {
    min-height: 44px;
  }
  a {
    overflow-wrap: anywhere;
  }
}
.fixture-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 7px;
  align-items: center;
  margin: 10px 0;
}
.fixture-club {
  min-width: 0;
}
.fixture-grid .club-label {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: flex-start;
  font-weight: 700;
  font-size: clamp(11px, 3.2vw, 15px);
  line-height: 1.2;
  text-align: left;
}
.fixture-grid .club-crest {
  width: 30px !important;
  height: 30px !important;
  flex: 0 0 30px;
}
.fixture-grid .fixture-away .club-label {
  justify-content: flex-end;
  flex-direction: row-reverse;
  text-align: right;
}
.fixture-grid .club-label span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.fixture-grid .match-pending {
  background: #263e50;
  color: #e4edf3;
  font-size: 11px;
  padding: 6px 7px;
  white-space: nowrap;
}
.fixture-grid .score {
  white-space: nowrap;
}
.team-link {
  width: 100%;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.team-hero {
  display: flex;
  gap: 16px;
  align-items: center;
}
.team-hero h2 {
  margin: 5px 0;
}
.team-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.team-form {
  display: flex;
  gap: 7px;
}
.form-chip {
  border-radius: 6px;
  padding: 7px 11px;
  font-weight: 800;
}
.form-chip.win {
  background: #17613b;
}
.form-chip.draw {
  background: #596273;
}
.form-chip.loss {
  background: #8b3441;
}
@media (max-width: 350px) {
  .fixture-grid .club-crest {
    width: 24px !important;
    height: 24px !important;
    flex-basis: 24px;
  }
  .fixture-grid {
    gap: 4px;
  }
}
#content .sync-retry,
#backTeams {
  margin: 0 12px 12px 0;
  max-width: 100%;
  vertical-align: middle;
}
@media (max-width: 380px) {
  #content .sync-retry,
  #backTeams {
    display: block;
    width: 100%;
    margin-right: 0;
  }
}
.fixture-grid .club-label {
  display: flex;
  align-items: center;
  gap: 7px;
  justify-content: flex-start;
  min-width: 0;
}
.fixture-grid .fixture-away .club-label {
  justify-content: flex-end;
  flex-direction: row-reverse;
}
.fixture-grid .club-crest {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  object-fit: contain;
}
.fixture-grid .club-label span {
  overflow-wrap: anywhere;
  min-width: 0;
}
/* 4.39: goleadores y tarjetas */
table.stats439 {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92em;
}
table.stats439 th,
table.stats439 td {
  padding: 7px 4px;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
table.stats439 td:first-child,
table.stats439 th:first-child {
  width: 1.6em;
  opacity: 0.7;
}
.stats439-club {
  display: flex;
  align-items: center;
  gap: 6px;
}
.stats439-club .club-crest {
  width: 20px;
  height: 20px;
}
/* 4.39: calendario, mapa y compartir */
.match-actions439 {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.match-actions439 .btn {
  font-size: 0.85em;
  padding: 6px 10px;
  text-decoration: none;
}
.share439 {
  margin: 10px 0;
}
