:root {
  --navy: #10254a;
  --navy-deep: #09182f;
  --blue: #153e70;
  --gold: #efb51d;
  --gold-pale: #f6d875;
  --cream: #f3efe5;
  --paper: #fffdf8;
  --ink: #171c28;
  --muted: #70788a;
  --line: #d9d4c7;
  --red: #d5493f;
  --green: #177454;
  --serif: "Bodoni Moda", Georgia, serif;
  --sans: "DM Sans", sans-serif;
  --shadow: 0 18px 50px rgba(9, 24, 47, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--cream); font-family: var(--sans); min-height: 100vh; }
body::before { content: ""; position: fixed; inset: 0; pointer-events: none; opacity: .16; z-index: 20; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 120 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.12'/%3E%3C/svg%3E"); }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 100; background: var(--gold); color: var(--navy); padding: .8rem 1rem; font-weight: 700; }
.skip-link:focus { top: 1rem; }

.score-ribbon { height: 35px; background: var(--navy-deep); color: #eaf0fa; display: grid; grid-template-columns: auto 1fr auto; gap: 1.25rem; align-items: center; padding: 0 clamp(1rem, 5vw, 5rem); font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; }
.ribbon-kicker { color: var(--gold); font-weight: 700; white-space: nowrap; }
.ribbon-kicker i { width: 7px; height: 7px; border-radius: 50%; background: var(--red); display: inline-block; margin-right: 7px; box-shadow: 0 0 0 5px rgba(213,73,63,.14); animation: pulse 1.8s infinite; }
.ticker { overflow: hidden; white-space: nowrap; opacity: .84; }
.ticker span { display: inline-block; animation: tickerIn .5s ease both; }
#clock { opacity: .58; white-space: nowrap; }

.site-header { height: 92px; display: flex; align-items: center; padding: 0 clamp(1rem, 5vw, 5rem); background: rgba(243,239,229,.94); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 15; backdrop-filter: blur(16px); }
.brand { display: flex; align-items: center; gap: .8rem; text-decoration: none; min-width: 255px; }
.brand img { width: 58px; height: 58px; border-radius: 50%; box-shadow: 0 7px 20px rgba(9,24,47,.18); }
.brand span { display: flex; flex-direction: column; }
.brand b { color: var(--navy); font-family: var(--serif); font-size: 1.25rem; line-height: 1; }
.brand small { color: var(--muted); font-size: .59rem; text-transform: uppercase; letter-spacing: .17em; margin-top: 7px; }
.desktop-nav { flex: 1; display: flex; justify-content: center; gap: .15rem; }
.desktop-nav button { border: 0; background: transparent; color: var(--muted); font-size: .78rem; font-weight: 700; padding: 2.2rem .95rem 2rem; cursor: pointer; position: relative; }
.desktop-nav button::after { content: ""; height: 3px; background: var(--gold); position: absolute; left: 50%; right: 50%; bottom: 0; transition: .25s ease; }
.desktop-nav button:hover, .desktop-nav button.active { color: var(--navy); }
.desktop-nav button.active::after { left: .9rem; right: .9rem; }
.listen-button { text-decoration: none; background: var(--navy); color: white; padding: .8rem 1rem; border-radius: 2px; font-size: .75rem; font-weight: 700; white-space: nowrap; }
.listen-button span { color: var(--gold); margin-left: .4rem; }

main { min-height: 74vh; }
.view { animation: reveal .55s cubic-bezier(.2,.8,.2,1) both; }
.wrap { width: min(1180px, calc(100% - 2rem)); margin: 0 auto; }
.eyebrow { text-transform: uppercase; color: var(--gold); font-weight: 800; letter-spacing: .16em; font-size: .67rem; }
.display { font-family: var(--serif); color: var(--navy); line-height: .98; letter-spacing: -.035em; }

.hero { min-height: 585px; color: white; background: var(--navy); position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0,1.15fr) minmax(360px,.85fr); }
.hero::before { content: ""; position: absolute; width: 640px; height: 640px; right: -180px; top: -280px; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; box-shadow: 0 0 0 80px rgba(255,255,255,.025), 0 0 0 160px rgba(255,255,255,.018); }
.hero::after { content: ""; position: absolute; left: 46%; top: -10%; bottom: -15%; width: 2px; background: rgba(255,255,255,.12); transform: rotate(18deg); }
.hero-copy { padding: clamp(4rem, 8vw, 8rem) clamp(2rem, 7vw, 7rem); align-self: center; position: relative; z-index: 2; }
.hero h1 { font-family: var(--serif); font-size: clamp(4rem, 8vw, 7.6rem); line-height: .82; letter-spacing: -.055em; margin: 1.2rem 0 1.8rem; max-width: 720px; }
.hero h1 em { color: var(--gold); font-style: italic; font-weight: 600; }
.hero p { max-width: 570px; color: #c9d3e5; font-size: 1.05rem; line-height: 1.7; }
.hero-actions { display: flex; align-items: center; gap: 1rem; margin-top: 2.2rem; }
.primary-action, .secondary-action { border: 0; cursor: pointer; text-decoration: none; padding: 1rem 1.25rem; font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; font-weight: 800; }
.primary-action { background: var(--gold); color: var(--navy); }
.secondary-action { background: transparent; color: white; border-bottom: 1px solid rgba(255,255,255,.5); }
.hero-desk { position: relative; z-index: 2; align-self: end; padding: 3rem clamp(2rem,5vw,5rem) 4rem 1rem; }
.desk-card { background: var(--paper); color: var(--ink); padding: 1.4rem; box-shadow: 0 28px 80px rgba(0,0,0,.28); transform: rotate(-1.4deg); }
.desk-head { display: flex; justify-content: space-between; border-bottom: 3px double var(--line); padding-bottom: .75rem; margin-bottom: .65rem; }
.desk-head b { color: var(--navy); font-family: var(--serif); font-size: 1.35rem; }
.live-label { color: var(--red); font-size: .65rem; font-weight: 800; letter-spacing: .13em; }
.desk-match { padding: .85rem 0; border-bottom: 1px solid var(--line); }
.desk-match:last-child { border: 0; }
.desk-meta { display: flex; justify-content: space-between; color: var(--muted); font-size: .66rem; text-transform: uppercase; margin-bottom: .6rem; }
.desk-player { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: .4rem; padding: .24rem 0; font-weight: 700; }
.desk-player small { color: var(--muted); font-size: .62rem; }
.desk-player strong { font-family: var(--serif); font-size: 1.1rem; color: var(--navy); }

.home-grid { display: grid; grid-template-columns: 1.22fr .78fr; gap: 2rem; padding: 5rem 0; }
.section-title { font-family: var(--serif); font-size: clamp(2.5rem, 5vw, 4.6rem); line-height: .95; margin: .5rem 0 1.4rem; color: var(--navy); letter-spacing: -.04em; }
.instagram-board { background: var(--navy-deep); color: white; min-height: 460px; padding: 2rem; position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; }
.instagram-board::after { content: "FTB"; position: absolute; right: -1rem; bottom: -4rem; font-family: var(--serif); font-size: 15rem; color: rgba(255,255,255,.035); }
.instagram-board h3 { font-family: var(--serif); font-size: 3rem; margin: .3rem 0; position: relative; z-index: 1; }
.instagram-board p { color: #aebbd1; max-width: 470px; line-height: 1.65; position: relative; z-index: 1; }
.ig-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: .75rem; position: relative; z-index: 1; }
.ig-tile { aspect-ratio: .78; padding: 1rem; display: flex; flex-direction: column; justify-content: flex-end; background: linear-gradient(145deg, #34557a, #10254a); border: 1px solid rgba(255,255,255,.12); transition: transform .25s ease; }
.ig-tile:nth-child(2) { background: linear-gradient(145deg, #d6a91e, #8c5713); transform: translateY(-1.2rem); }
.ig-tile:nth-child(3) { background: linear-gradient(145deg, #8e2332, #231629); }
.ig-tile:hover { transform: translateY(-5px) rotate(.5deg); }
.ig-tile b { font-family: var(--serif); font-size: 1.25rem; line-height: 1.05; }
.ig-tile small { opacity: .7; margin-top: .4rem; }
.dispatches { display: grid; gap: .8rem; }
.dispatch { display: grid; grid-template-columns: 80px 1fr; background: var(--paper); border-top: 3px solid var(--navy); padding: 1rem; transition: transform .2s; }
.dispatch:hover { transform: translateX(5px); }
.dispatch .number { font-family: var(--serif); font-size: 3rem; color: var(--gold); line-height: 1; }
.dispatch h4 { margin: 0; font-family: var(--serif); color: var(--navy); font-size: 1.25rem; }
.dispatch p { color: var(--muted); font-size: .8rem; line-height: 1.5; }

.page-hero { background: var(--navy); color: white; padding: 4.5rem 0 3.5rem; position: relative; overflow: hidden; }
.page-hero::after { content: ""; position: absolute; width: 320px; height: 320px; border: 55px solid rgba(255,255,255,.035); border-radius: 50%; right: 8%; top: -190px; }
.page-hero h1 { font-family: var(--serif); font-size: clamp(3.4rem, 7vw, 6.5rem); line-height: .9; margin: .5rem 0 .8rem; letter-spacing: -.05em; }
.page-hero p { color: #bdc9dc; max-width: 650px; line-height: 1.6; }
.toolbar { background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 92px; z-index: 10; }
.toolbar-inner { width: min(1180px, calc(100% - 2rem)); margin: auto; padding: 1rem 0; display: flex; gap: .65rem; align-items: center; flex-wrap: wrap; }
.chip { border: 1px solid var(--line); background: transparent; color: var(--navy); padding: .62rem .85rem; border-radius: 999px; cursor: pointer; font-size: .72rem; font-weight: 700; }
.chip.active { background: var(--navy); border-color: var(--navy); color: white; }
.chip.gold.active { background: var(--gold); border-color: var(--gold); color: var(--navy); }
.toolbar .search { margin-left: auto; min-width: 240px; }
.search, .select { background: var(--cream); border: 1px solid var(--line); padding: .7rem .85rem; color: var(--ink); outline: none; }
.search:focus, .select:focus { border-color: var(--navy); box-shadow: 0 0 0 3px rgba(16,37,74,.08); }

.data-area { padding: 2.5rem 0 5rem; }
.data-summary { display: flex; justify-content: space-between; align-items: end; margin-bottom: 1.2rem; }
.data-summary h2 { font-family: var(--serif); color: var(--navy); font-size: 2.3rem; margin: 0; }
.data-summary p { margin: .25rem 0 0; color: var(--muted); font-size: .8rem; }
.refresh { border: 0; background: transparent; color: var(--navy); font-weight: 800; cursor: pointer; padding: .5rem; }
.match-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1rem; }
.match-card { background: var(--paper); border: 1px solid var(--line); border-left: 5px solid var(--gold); padding: 1rem 1.15rem; box-shadow: 0 4px 0 rgba(16,37,74,.03); }
.match-card.live { border-left-color: var(--red); }
.match-card.final { border-left-color: var(--navy); }
.match-top { display: flex; align-items: center; gap: .6rem; border-bottom: 1px solid var(--line); padding-bottom: .65rem; margin-bottom: .55rem; }
.status { font-size: .6rem; font-weight: 900; letter-spacing: .12em; color: var(--navy); background: var(--cream); padding: .32rem .44rem; }
.live .status { background: #fee6e4; color: var(--red); }
.match-tour { color: var(--muted); font-size: .66rem; text-transform: uppercase; font-weight: 700; }
.match-meta { margin-left: auto; color: var(--muted); font-size: .63rem; max-width: 45%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-row { display: grid; grid-template-columns: 48px minmax(0,1fr) auto auto; gap: .5rem; align-items: center; min-height: 44px; }
.player-code { font-size: .66rem; font-weight: 800; color: var(--muted); }
.player-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player-name small { display: block; color: var(--muted); font-size: .61rem; font-weight: 500; margin-top: 2px; }
.serve-ball { width: 18px; height: 18px; background: var(--gold); color: var(--navy); border-radius: 50%; display: grid; place-items: center; font-size: .55rem; }
.sets { display: flex; gap: .55rem; color: var(--navy); font-family: var(--serif); font-weight: 800; }
.favourite { border: 0; background: transparent; color: #a6a3a0; cursor: pointer; font-size: 1.1rem; }
.favourite.saved { color: var(--gold); }

.ranking-shell { background: var(--paper); border: 1px solid var(--line); }
.ranking-header, .ranking-row { display: grid; grid-template-columns: 72px minmax(240px,1fr) 130px 120px; align-items: center; }
.ranking-header { background: var(--navy); color: white; padding: .75rem 1rem; font-size: .61rem; letter-spacing: .12em; text-transform: uppercase; }
.ranking-row { padding: .8rem 1rem; border-bottom: 1px solid var(--line); transition: background .2s; }
.ranking-row:hover { background: #f8f4e9; }
.rank-num { font-family: var(--serif); font-size: 1.55rem; color: var(--navy); }
.rank-player { display: flex; align-items: center; gap: .85rem; min-width: 0; }
.avatar { width: 43px; height: 43px; flex: 0 0 auto; background: var(--navy); color: var(--gold); border-radius: 50%; display: grid; place-items: center; font-family: var(--serif); font-weight: 800; }
.rank-player b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-country, .rank-points { color: var(--muted); font-size: .78rem; }
.rank-points { color: var(--navy); font-weight: 800; }
.load-more { display: block; margin: 1.5rem auto 0; background: var(--gold); color: var(--navy); border: 0; padding: .85rem 1.2rem; font-weight: 800; cursor: pointer; }

.podcast-layout { padding: 4rem 0 5rem; display: grid; grid-template-columns: .68fr 1.32fr; gap: 3rem; }
.podcast-note { position: sticky; top: 130px; align-self: start; }
.podcast-note h2 { font-family: var(--serif); font-size: 4rem; line-height: .9; color: var(--navy); margin: .6rem 0 1rem; }
.podcast-note p { color: var(--muted); line-height: 1.7; }
.spotify-frame { border: 0; border-radius: 12px; width: 100%; height: 620px; background: var(--navy); box-shadow: var(--shadow); }
.community-layout { padding: 4rem 0 5rem; display: grid; grid-template-columns: 1fr 1.6fr; gap: 2rem; }
.room-list { display: grid; gap: .7rem; }
.room { background: var(--paper); border: 1px solid var(--line); padding: 1rem; display: flex; gap: .8rem; align-items: center; }
.room i { width: 42px; height: 42px; display: grid; place-items: center; background: var(--navy); color: var(--gold); font-style: normal; font-family: var(--serif); }
.room b { color: var(--navy); }
.room small { display: block; color: var(--muted); margin-top: .2rem; }
.conversation { background: var(--paper); border: 1px solid var(--line); min-height: 520px; display: flex; flex-direction: column; }
.conversation-head { background: var(--navy); color: white; padding: 1rem 1.2rem; }
.messages { padding: 1.2rem; display: grid; gap: .8rem; flex: 1; }
.message { max-width: 82%; background: var(--cream); padding: .85rem 1rem; border-radius: 0 12px 12px 12px; font-size: .83rem; line-height: 1.5; }
.message.me { margin-left: auto; background: var(--navy); color: white; border-radius: 12px 0 12px 12px; }
.message b { display: block; font-size: .65rem; color: var(--gold); margin-bottom: .25rem; }
.compose-box { border-top: 1px solid var(--line); display: flex; padding: .8rem; gap: .5rem; }
.compose-box input { flex: 1; border: 1px solid var(--line); padding: .8rem; min-width: 0; }
.compose-box button { background: var(--gold); border: 0; color: var(--navy); font-weight: 800; padding: 0 1rem; cursor: pointer; }

.state-card { grid-column: 1/-1; background: var(--paper); border: 1px solid var(--line); padding: 3rem; text-align: center; }
.state-card h3 { font-family: var(--serif); color: var(--navy); font-size: 2rem; margin: 0 0 .5rem; }
.state-card p { color: var(--muted); }
.skeleton { background: linear-gradient(90deg,#e7e2d6 25%,#f6f2e8 50%,#e7e2d6 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; height: 145px; }

footer { background: var(--navy-deep); color: #b9c4d7; padding: 3rem clamp(1rem,5vw,5rem); display: grid; grid-template-columns: 1fr 1fr auto; align-items: center; gap: 1.5rem; }
.footer-mark { display: flex; align-items: center; gap: .7rem; color: white; font-family: var(--serif); font-size: 1.25rem; }
.footer-mark img { width: 42px; height: 42px; border-radius: 50%; }
footer p { font-family: var(--serif); font-style: italic; text-align: center; }
footer div a { margin-left: 1.2rem; font-size: .75rem; color: var(--gold); }
footer small { grid-column: 1/-1; opacity: .5; border-top: 1px solid rgba(255,255,255,.1); padding-top: 1rem; }
.mobile-nav { display: none; }
#toast { position: fixed; right: 1.2rem; bottom: 1.2rem; z-index: 30; background: var(--navy); color: white; padding: .8rem 1rem; transform: translateY(150%); transition: .3s; box-shadow: var(--shadow); font-size: .8rem; }
#toast.show { transform: translateY(0); }

@keyframes reveal { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes tickerIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgba(213,73,63,0); } }
@keyframes shimmer { to { background-position: -200% 0; } }

@media (max-width: 900px) {
  .desktop-nav, .listen-button { display: none; }
  .site-header { height: 76px; }
  .brand img { width: 48px; height: 48px; }
  .hero { grid-template-columns: 1fr; }
  .hero-copy { padding: 4.5rem 1.4rem 2rem; }
  .hero h1 { font-size: clamp(4.2rem, 18vw, 6.7rem); }
  .hero-desk { padding: 1rem 1.4rem 4rem; }
  .hero::after { display: none; }
  .home-grid, .podcast-layout, .community-layout { grid-template-columns: 1fr; }
  .podcast-note { position: static; }
  .match-grid { grid-template-columns: 1fr; }
  .toolbar { top: 76px; }
  .toolbar .search { width: 100%; margin-left: 0; }
  footer { grid-template-columns: 1fr; text-align: left; padding-bottom: 7rem; }
  footer p { text-align: left; }
  footer div a { margin: 0 1.2rem 0 0; }
  .mobile-nav { display: grid; grid-template-columns: repeat(5,1fr); position: fixed; z-index: 18; bottom: 0; left: 0; right: 0; height: 68px; background: var(--navy-deep); padding-bottom: env(safe-area-inset-bottom); }
  .mobile-nav button { border: 0; background: transparent; color: #9da9bd; font-size: .58rem; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; }
  .mobile-nav button span { font-size: 1.15rem; }
  .mobile-nav button.active { color: var(--gold); }
  #toast { bottom: 5.2rem; }
}

@media (max-width: 620px) {
  .score-ribbon { grid-template-columns: auto 1fr; padding: 0 .8rem; }
  #clock { display: none; }
  .brand b { font-size: 1.08rem; }
  .brand small { font-size: .52rem; }
  .ig-grid { grid-template-columns: repeat(3, 180px); overflow-x: auto; padding-top: 1rem; }
  .instagram-board { padding: 1.25rem; }
  .page-hero { padding: 3.2rem 0 2.7rem; }
  .ranking-header { display: none; }
  .ranking-row { grid-template-columns: 45px 1fr auto; padding: .75rem; }
  .rank-country { display: none; }
  .rank-player { gap: .55rem; }
  .avatar { width: 36px; height: 36px; }
  .player-row { grid-template-columns: 39px minmax(0,1fr) auto auto; }
  .match-meta { display: none; }
  .community-layout { padding-top: 2rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}
