.page-home {
  --home-charcoal: rgba(240, 244, 248, 0.08);
  --home-charcoal-strong: rgba(240, 244, 248, 0.18);
  --home-card-bg: rgba(11, 30, 59, 0.72);
  --home-card-bg-light: rgba(255, 255, 255, 0.92);
  --home-line: rgba(255, 107, 53, 0.55);
  --home-grid-size: 28px;
  overflow-x: hidden;
}

/* ========= HERO ========= */
.page-home .home-hero {
  position: relative;
  min-height: calc(100vh - var(--header-h));
  display: flex;
  align-items: center;
  padding: 64px 0 56px;
  background: var(--c-primary);
  isolation: isolate;
}

.page-home .home-hero__media {
  position: absolute;
  inset: 0;
  z-index: -2;
  overflow: hidden;
}

.page-home .home-hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  display: block;
  filter: saturate(0.7) contrast(1.1);
  animation: home-hero-zoom 32s ease-in-out infinite alternate;
}

@keyframes home-hero-zoom {
  from { transform: scale(1); }
  to { transform: scale(1.08); }
}

.page-home .home-hero__grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(to right, var(--home-charcoal) 1px, transparent 1px),
    linear-gradient(to bottom, var(--home-charcoal) 1px, transparent 1px);
  background-size: var(--home-grid-size) var(--home-grid-size);
  mask-image: linear-gradient(to bottom, rgba(0,0,0,0.9), rgba(0,0,0,0.35));
}

.page-home .home-hero__scan {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(120deg, rgba(11, 30, 59, 0.88) 0%, rgba(11, 30, 59, 0.55) 45%, rgba(11, 30, 59, 0.9) 100%);
}

.page-home .home-hero__inner {
  position: relative;
  z-index: 1;
}

.page-home .home-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-data);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  color: var(--c-teal);
  text-transform: uppercase;
  margin-bottom: 24px;
  border: 1px solid var(--c-border-strong);
  background: rgba(11, 30, 59, 0.5);
  padding: 8px 12px;
  backdrop-filter: blur(4px);
}

.page-home .home-hero__eyebrow-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-accent);
  box-shadow: 0 0 0 4px rgba(255, 107, 53, 0.2);
  animation: home-pulse 1.8s infinite;
}

@keyframes home-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 107, 53, 0.4); }
  50% { box-shadow: 0 0 0 6px rgba(255, 107, 53, 0); }
}

.page-home .home-hero__title {
  font-family: var(--font-heading);
  font-weight: 400;
  line-height: 1.06;
  letter-spacing: 0.01em;
  color: var(--c-text-on-dark);
  font-size: clamp(2.6rem, 9vw, 5.4rem);
  max-width: 780px;
  margin-bottom: 24px;
  text-shadow: 0 4px 32px rgba(0, 0, 0, 0.5);
}

.page-home .home-hero__desc {
  color: rgba(240, 244, 248, 0.86);
  font-size: 0.95rem;
  line-height: 1.9;
  max-width: 680px;
  margin-bottom: 28px;
}

.page-home .home-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 44px;
}

.page-home .home-hero__nav {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  max-width: 900px;
}

.page-home .home-hero__card {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 14px;
  padding: 18px 18px 16px;
  background: var(--home-card-bg);
  border: 1px solid var(--c-border-strong);
  border-left: 3px solid var(--c-accent);
  box-shadow: var(--shadow-card);
  transition: transform 0.22s ease, background 0.22s ease, border-color 0.22s ease;
  text-decoration: none;
}

.page-home .home-hero__card:hover,
.page-home .home-hero__card:focus-visible {
  transform: translateX(6px);
  background: rgba(255, 107, 53, 0.12);
  border-color: var(--c-accent);
}

.page-home .home-hero__card-no {
  grid-row: 1 / 3;
  font-family: var(--font-data);
  font-size: 0.78rem;
  color: var(--c-gold);
  margin-top: 4px;
}

.page-home .home-hero__card-name {
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--c-text-on-dark);
}

.page-home .home-hero__card-note {
  font-size: 0.82rem;
  color: var(--c-muted);
  margin-top: 3px;
}

/* ========= SECTION HEAD ========= */
.page-home .section-head {
  margin-bottom: 36px;
}

.page-home .section-index {
  font-family: var(--font-data);
  font-size: 0.78rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--c-accent);
  margin-bottom: 10px;
}

.page-home .section-title {
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: clamp(1.9rem, 4vw, 3.1rem);
  line-height: 1.1;
  margin-bottom: 12px;
}

.page-home .section-desc {
  font-size: 0.93rem;
  line-height: 1.8;
  max-width: 640px;
}

.page-home .section-bg-teal .section-desc,
.page-home .section-bg-indigo .section-desc,
.page-home .section-bg-burgundy .section-desc,
.page-home .section-bg-dark .section-desc {
  color: rgba(240, 244, 248, 0.78);
}

.page-home .section-bg-light .section-title {
  color: var(--c-primary);
}

.page-home .section-bg-light .section-desc {
  color: #40536b;
}

/* ========= SCHEDULE ========= */
.page-home .home-schedule__head {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  align-items: end;
}

.page-home .home-schedule__badge {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border: 1px solid var(--c-border-strong);
  box-shadow: var(--shadow-card);
}

.page-home .home-schedule__timeline {
  position: relative;
  padding-top: 42px;
}

.page-home .home-schedule__track {
  display: none;
}

.page-home .home-schedule__cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 6px;
}

.page-home .home-match {
  position: relative;
  background: rgba(4, 20, 38, 0.72);
  border: 1px solid var(--c-border-strong);
  padding: 20px 18px 18px;
  scroll-snap-align: start;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.page-home .home-match::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 22px;
  height: 22px;
  background: linear-gradient(135deg, transparent 50%, rgba(255, 107, 53, 0.55) 50%);
}

.page-home .home-match:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-strong);
}

.page-home .home-match__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.page-home .home-match__id {
  font-family: var(--font-data);
  font-size: 0.72rem;
  color: var(--c-muted);
  letter-spacing: 0.08em;
}

.page-home .home-match__meta {
  font-family: var(--font-data);
  font-size: 0.75rem;
  color: var(--c-teal);
  letter-spacing: 0.1em;
  margin-bottom: 6px;
}

.page-home .home-match__teams {
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.5;
  color: var(--c-text-on-dark);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.page-home .home-match__time {
  font-size: 0.82rem;
  color: var(--c-muted);
  margin-bottom: 14px;
}

.page-home .home-match .score {
  display: inline-block;
  font-family: var(--font-data);
  font-weight: 700;
  color: var(--c-gold);
  font-size: 1.2rem;
  min-width: 22px;
  text-align: center;
  transition: transform 0.3s ease, color 0.3s ease;
}

.page-home .home-match .score:hover {
  transform: rotateX(360deg) scale(1.15);
  color: var(--c-accent);
}

.page-home .home-match .score-sep {
  color: var(--c-muted);
  margin: 0 2px;
}

/* ========= EXPERT ========= */
.page-home .home-expert__layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: start;
}

.page-home .home-expert__tabs {
  min-width: 0;
}

.page-home .home-expert__input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.page-home .home-expert__nav {
  display: flex;
  border: 1px solid var(--c-border-strong);
  border-bottom: none;
  background: rgba(255, 255, 255, 0.04);
}

.page-home .home-expert__label {
  flex: 1;
  text-align: center;
  padding: 14px 8px;
  font-weight: 600;
  font-size: 0.86rem;
  color: rgba(240, 244, 248, 0.7);
  background: transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  border-bottom: 3px solid transparent;
}

.page-home .home-expert__label:hover {
  color: var(--c-text-on-dark);
  background: rgba(255, 255, 255, 0.06);
}

.page-home .home-expert__input#exp-tab-1:checked ~ .home-expert__nav label[for="exp-tab-1"],
.page-home .home-expert__input#exp-tab-2:checked ~ .home-expert__nav label[for="exp-tab-2"],
.page-home .home-expert__input#exp-tab-3:checked ~ .home-expert__nav label[for="exp-tab-3"] {
  color: var(--c-accent);
  border-bottom-color: var(--c-accent);
  background: rgba(255, 107, 53, 0.08);
}

.page-home .home-expert__panels {
  border: 1px solid var(--c-border-strong);
  background: rgba(11, 30, 59, 0.4);
  min-height: 280px;
}

.page-home .home-expert__panel {
  display: none;
  padding: 24px 20px 28px;
}

.page-home .home-expert__input#exp-tab-1:checked ~ .home-expert__panels .home-expert__panel:nth-child(1),
.page-home .home-expert__input#exp-tab-2:checked ~ .home-expert__panels .home-expert__panel:nth-child(2),
.page-home .home-expert__input#exp-tab-3:checked ~ .home-expert__panels .home-expert__panel:nth-child(3) {
  display: block;
}

.page-home .home-expert__panel-title {
  font-size: 1.2rem;
  line-height: 1.4;
  margin: 12px 0 14px;
  color: var(--c-text-on-dark);
}

.page-home .home-expert__panel-list {
  list-style: none;
  padding: 0;
  margin: 0 0 18px;
  border-top: 1px dashed var(--c-border-strong);
}

.page-home .home-expert__panel-list li {
  position: relative;
  padding: 12px 0 12px 22px;
  border-bottom: 1px dashed var(--c-border-strong);
  font-size: 0.88rem;
  line-height: 1.6;
  color: rgba(240, 244, 248, 0.84);
}

.page-home .home-expert__panel-list li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 19px;
  width: 7px;
  height: 7px;
  background: var(--c-teal);
  transform: rotate(45deg);
}

.page-home .home-expert__figure {
  margin: 0;
  border: 1px solid var(--c-border-strong);
  background: rgba(11, 30, 59, 0.5);
  box-shadow: var(--shadow-card);
}

.page-home .home-expert__figure img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  aspect-ratio: 1 / 1;
}

/* ========= LEAGUE ========= */
.page-home .home-league__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.page-home .home-league__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.page-home .home-league__more {
  margin-bottom: 4px;
}

.page-home .home-league__table-card,
.page-home .home-league__card {
  background: var(--home-card-bg-light);
  border: 1px solid #d7dee8;
  box-shadow: 0 4px 18px rgba(11, 30, 59, 0.08);
}

.page-home .home-league__card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 18px;
  border-bottom: 1px solid #e4e9f0;
}

.page-home .home-league__card-head h3 {
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--c-primary);
  margin: 0;
}

.page-home .home-league__table-wrap {
  overflow-x: auto;
}

.page-home .home-league__table {
  width: 100%;
  min-width: 360px;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.page-home .home-league__table th {
  text-align: left;
  padding: 12px 14px;
  background: #f0f3f8;
  color: var(--c-primary);
  font-weight: 600;
  border-bottom: 2px solid #d7dee8;
  white-space: nowrap;
}

.page-home .home-league__table td {
  padding: 12px 14px;
  border-bottom: 1px solid #edf0f5;
  color: #33465d;
  white-space: nowrap;
}

.page-home .home-league__table tbody tr {
  transition: background 0.2s ease;
}

.page-home .home-league__table tbody tr:hover {
  background: rgba(255, 107, 53, 0.07);
}

.page-home .home-league__table tbody tr:last-child td {
  border-bottom: none;
}

.page-home .home-league__rank--first {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  background: var(--c-gold);
  color: var(--c-primary);
  font-weight: 800;
  font-family: var(--font-data);
}

.page-home .home-league__card-list {
  list-style: none;
  padding: 8px 18px 12px;
  margin: 0;
}

.page-home .home-league__card-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px dashed #e4e9f0;
  font-size: 0.88rem;
  color: #33465d;
}

.page-home .home-league__card-list li:last-child {
  border-bottom: none;
}

.page-home .home-league__card-list b {
  font-family: var(--font-data);
  color: var(--c-primary);
}

.page-home .home-league__card-tag {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  font-family: var(--font-data);
  font-size: 0.68rem;
  font-weight: 700;
  border: 1px solid;
}

.page-home .home-league__card-tag--yellow {
  background: #fff4b0;
  color: #7a6200;
  border-color: #e3cd5d;
}

.page-home .home-league__card-tag--red {
  background: #f5b3b8;
  color: #7b1e26;
  border-color: #d67a82;
}

/* ========= REPORTS ========= */
.page-home .home-reports__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.page-home .home-reports__list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.page-home .home-reports__item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--c-border-strong);
  border-left: 4px solid var(--c-accent);
  transition: background 0.2s ease, transform 0.2s ease;
  position: relative;
}

.page-home .home-reports__item:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateX(4px);
}

.page-home .home-reports__score {
  grid-column: 1;
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-data);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--c-gold);
  background: rgba(11, 30, 59, 0.55);
  border: 1px solid var(--c-border-strong);
  padding: 8px 10px;
  align-self: start;
}

.page-home .home-reports__body {
  grid-column: 2;
}

.page-home .home-reports__title {
  font-size: 1.06rem;
  font-weight: 700;
  color: var(--c-text-on-dark);
  margin: 0 0 6px;
}

.page-home .home-reports__summary {
  font-size: 0.85rem;
  line-height: 1.65;
  color: rgba(240, 244, 248, 0.76);
  margin: 0 0 8px;
}

.page-home .home-reports__link {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--c-teal);
  text-decoration: none;
}

.page-home .home-reports__link:hover {
  color: var(--c-accent);
  text-decoration: underline;
}

.page-home .home-reports__item .tag {
  position: absolute;
  top: 18px;
  right: 18px;
}

/* ========= DATA ========= */
.page-home .home-data__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: 28px;
}

.page-home .home-data__card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--c-border-strong);
  border-top: 3px solid var(--c-teal);
  text-decoration: none;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.page-home .home-data__card:hover {
  transform: translateY(-5px);
  border-color: var(--c-accent);
  box-shadow: var(--shadow-card);
}

.page-home .home-data__card-no {
  font-family: var(--font-data);
  font-size: 0.78rem;
  color: var(--c-accent);
  letter-spacing: 0.12em;
}

.page-home .home-data__card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--c-text-on-dark);
  margin: 0;
}

.page-home .home-data__card-text {
  font-size: 0.86rem;
  line-height: 1.7;
  color: rgba(240, 244, 248, 0.74);
  margin: 0;
}

.page-home .home-data__card-link {
  margin-top: auto;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--c-gold);
}

.page-home .home-data__figure {
  margin: 0;
  border: 1px solid var(--c-border-strong);
  overflow: hidden;
}

.page-home .home-data__figure img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 420px;
}

/* ========= MEDIA QUERIES ========= */
@media (min-width: 600px) {
  .page-home .home-hero__nav {
    grid-template-columns: repeat(3, 1fr);
  }

  .page-home .home-hero__card {
    grid-template-columns: 1fr;
    row-gap: 6px;
  }

  .page-home .home-hero__card-no {
    grid-row: auto;
  }

  .page-home .home-schedule__cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .page-home .home-reports__item {
    grid-template-columns: auto 1fr;
  }
}

@media (min-width: 992px) {
  .page-home .home-hero {
    padding: 80px 0 72px;
  }

  .page-home .home-hero__title {
    max-width: 860px;
  }

  .page-home .home-hero__nav {
    gap: 18px;
  }

  .page-home .home-schedule__head {
    grid-template-columns: 1fr 160px;
  }

  .page-home .home-schedule__badge {
    width: 140px;
    height: 140px;
    justify-self: end;
  }

  .page-home .home-schedule__track {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    opacity: 0.45;
  }

  .page-home .home-schedule__cards {
    grid-template-columns: repeat(4, 1fr);
    overflow: visible;
  }

  .page-home .home-expert__layout {
    grid-template-columns: minmax(0, 1fr) 400px;
    gap: 36px;
  }

  .page-home .home-expert__figure {
    position: sticky;
    top: calc(var(--header-h) + 24px);
  }

  .page-home .home-league__grid {
    grid-template-columns: minmax(0, 1fr) 300px;
    align-items: start;
  }

  .page-home .home-league__table {
    min-width: 0;
  }

  .page-home .home-reports__list {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .page-home .home-data__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-home .home-hero__media img,
  .page-home .home-hero__eyebrow-dot,
  .page-home .home-match .score {
    animation: none;
    transition: none;
  }

  .page-home .home-hero__card,
  .page-home .home-match,
  .page-home .home-data__card,
  .page-home .home-reports__item {
    transition: none;
  }
}
