/* === F1 2026 GLOBAL STYLES === */
:root{
  --bg0:#070A12;
  --bg1:#0A1022;
  --bg2:#0d1528;
  --txt:rgba(255,255,255,.92);
  --muted:rgba(255,255,255,.68);
  --acc:#FF2E63;
  --acc2:#3CEFFF;
  --mclaren:#FF8000;
  --ferrari:#DC0000;
  --redbull:#3671C6;
  --mercedes:#27F4D2;
  --border:rgba(255,255,255,.14);
  --shadow: 0 18px 50px rgba(0,0,0,.55);
  --r:20px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
html,body{height:100%; margin:0; padding:0;}
body{
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji","Segoe UI Emoji";
  color:var(--txt);
  background: var(--bg0);
  overflow-x:hidden;
}

/* === GLOBAL NAV === */
.global-nav{
  position:fixed;
  top:0;
  left:0;
  right:0;
  z-index:1000;
  backdrop-filter: blur(20px);
  background: rgba(7,10,18,.75);
  border-bottom:1px solid var(--border);
  padding:14px 28px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:20px;
  flex-wrap:wrap;
}
.nav-left{
  display:flex;
  align-items:center;
  gap:16px;
  flex-wrap:wrap;
}
.nav-brand{
  display:flex;
  align-items:center;
  gap:12px;
  font-size:20px;
  font-weight:800;
  letter-spacing:-0.5px;
  text-decoration:none;
  color:var(--txt);
}
.nav-brand:hover{opacity:.9}
.nav-brand img, .nav-brand svg{height:32px; width:auto;}
.nav-selectors{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}

/* Custom Select Dropdown */
.custom-select{
  position:relative;
  min-width:130px;
}
.custom-select-trigger{
  display:flex;
  align-items:center;
  gap:8px;
  font-size:12px;
  font-weight:600;
  padding:8px 32px 8px 12px;
  border-radius:8px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.06);
  color:var(--txt);
  cursor:pointer;
  transition: border-color .2s, background .2s, box-shadow .2s;
  position:relative;
}
.custom-select-trigger::after{
  content:'';
  position:absolute;
  right:10px;
  top:50%;
  transform:translateY(-50%);
  width:0;
  height:0;
  border-left:4px solid transparent;
  border-right:4px solid transparent;
  border-top:5px solid var(--muted);
  transition: transform .2s;
}
.custom-select.open .custom-select-trigger::after{
  transform:translateY(-50%) rotate(180deg);
}
.custom-select-trigger:hover{
  border-color:var(--acc2);
  background: rgba(255,255,255,.08);
}
.custom-select.open .custom-select-trigger{
  border-color:var(--acc2);
  box-shadow: 0 0 0 2px rgba(60,239,255,.2);
}
.custom-select-options{
  position:absolute;
  top:calc(100% + 6px);
  left:0;
  min-width:100%;
  background: rgba(15,20,35,.98);
  border:1px solid var(--border);
  border-radius:10px;
  padding:6px;
  opacity:0;
  visibility:hidden;
  transform:translateY(-8px);
  transition: opacity .2s, transform .2s, visibility .2s;
  z-index:1001;
  backdrop-filter: blur(20px);
  box-shadow: 0 12px 40px rgba(0,0,0,.5);
}
.custom-select.open .custom-select-options{
  opacity:1;
  visibility:visible;
  transform:translateY(0);
}
.custom-select-option{
  display:flex;
  align-items:center;
  gap:10px;
  padding:10px 12px;
  font-size:12px;
  font-weight:500;
  color:var(--muted);
  border-radius:6px;
  cursor:pointer;
  transition: background .15s, color .15s;
  white-space:nowrap;
}
.custom-select-option:hover{
  background: rgba(255,255,255,.08);
  color:var(--txt);
}
.custom-select-option.selected{
  color:var(--txt);
}
.custom-select-option.selected::before{
  content:'✓';
  color:var(--acc2);
  font-weight:700;
  font-size:11px;
}
.custom-select-option.disabled{
  opacity:.4;
  cursor:not-allowed;
}
.custom-select-option.disabled:hover{
  background:transparent;
  color:var(--muted);
}
.nav-links{
  display:flex;
  gap:4px;
  flex-wrap:wrap;
}
.nav-links a{
  font-size:13px;
  font-weight:500;
  padding:10px 16px;
  border-radius:10px;
  color:var(--muted);
  text-decoration:none;
  border:1px solid transparent;
  transition: all .15s ease;
}
.nav-links a:hover,.nav-links a.active{
  color:var(--txt);
  background:rgba(255,255,255,.1);
  border-color:var(--border);
}

/* === HERO SECTION === */
.hero{
  position:relative;
  min-height:100vh;
  display:flex;
  flex-direction:column;
  overflow:hidden;
}
.hero-bg{
  position:absolute;
  inset:0;
  background: 
    radial-gradient(ellipse 1200px 800px at 30% 20%, rgba(255,128,0,.2), transparent 60%),
    radial-gradient(ellipse 1000px 600px at 70% 80%, rgba(255,46,99,.15), transparent 60%),
    radial-gradient(ellipse 800px 500px at 90% 30%, rgba(60,239,255,.1), transparent 60%),
    linear-gradient(180deg, var(--bg0), var(--bg1));
  z-index:0;
}
.hero-content{
  position:relative;
  z-index:2;
  display:grid;
  grid-template-columns: 1fr 1.2fr;
  gap:40px;
  padding:120px 40px 60px;
  max-width:1600px;
  margin:0 auto;
  width:100%;
  min-height:100vh;
  align-items:center;
}
@media(max-width:1024px){
  .hero-content{grid-template-columns:1fr; padding:100px 24px 40px; text-align:center;}
}
.hero-text{
  display:flex;
  flex-direction:column;
  gap:24px;
}
.hero-badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:10px 16px;
  border-radius:999px;
  background: linear-gradient(135deg, rgba(255,128,0,.2), rgba(255,128,0,.05));
  border:1px solid rgba(255,128,0,.3);
  font-size:13px;
  font-weight:600;
  color:var(--mclaren);
  width:fit-content;
}
@media(max-width:1024px){.hero-badge{margin:0 auto;}}
.hero-badge svg{width:18px; height:18px;}
.hero-title{
  font-size:clamp(42px, 6vw, 80px);
  font-weight:900;
  letter-spacing:-2px;
  line-height:1;
  margin:0;
}
.hero-title .gradient{
  background: linear-gradient(135deg, var(--mclaren), #FFD700);
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
  background-clip:text;
}
.hero-subtitle{
  font-size:clamp(18px, 2.5vw, 24px);
  color:var(--muted);
  line-height:1.5;
  max-width:500px;
  margin:0;
}
@media(max-width:1024px){.hero-subtitle{margin:0 auto;}}
.hero-stats{
  display:flex;
  gap:24px;
  margin-top:16px;
}
@media(max-width:1024px){.hero-stats{justify-content:center;}}
.stat{
  text-align:left;
  padding:16px 20px;
  border-radius:16px;
  background: rgba(255,255,255,.04);
  border:1px solid var(--border);
}
@media(max-width:1024px){.stat{text-align:center;}}
.stat-value{
  font-size:32px;
  font-weight:800;
  background: linear-gradient(135deg, var(--acc), var(--acc2));
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
  background-clip:text;
}
.stat-label{font-size:12px; color:var(--muted); margin-top:2px;}
.hero-cta{
  display:flex;
  gap:12px;
  margin-top:8px;
}
@media(max-width:1024px){.hero-cta{justify-content:center; flex-wrap:wrap;}}
.btn{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:14px 24px;
  font-size:14px;
  font-weight:600;
  border-radius:14px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.08);
  color:var(--txt);
  text-decoration:none;
  cursor:pointer;
  transition: all .15s ease;
}
.btn:hover{transform:translateY(-2px); background:rgba(255,255,255,.12);}
.btn.primary{
  background: linear-gradient(135deg, var(--mclaren), #e67300);
  border-color: var(--mclaren);
  box-shadow: 0 8px 30px rgba(255,128,0,.3);
}
.btn.primary:hover{box-shadow: 0 12px 40px rgba(255,128,0,.4);}
.btn.outline{background:transparent; border-color:rgba(255,255,255,.3);}

/* === 3D STAGE === */
.hero-3d{
  position:relative;
  height:600px;
  border-radius:30px;
  overflow:hidden;
  background: radial-gradient(ellipse at center, rgba(255,128,0,.08), transparent 70%);
}
@media(max-width:1024px){.hero-3d{height:400px; margin-top:20px;}}
.hero-3d canvas{width:100%!important; height:100%!important; display:block;}
.hero-3d-overlay{
  position:absolute;
  bottom:20px;
  left:20px;
  right:20px;
  display:flex;
  justify-content:space-between;
  align-items:flex-end;
  pointer-events:none;
}
.car-info{
  padding:16px 20px;
  border-radius:16px;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(10px);
  border:1px solid var(--border);
}
.car-info h3{font-size:18px; font-weight:700; margin:0;}
.car-info p{font-size:12px; color:var(--muted); margin:4px 0 0 0;}
.controls-hint{
  display:flex;
  gap:8px;
}
.controls-hint span{
  padding:8px 12px;
  border-radius:8px;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(10px);
  border:1px solid var(--border);
  font-size:11px;
  color:var(--muted);
}

/* === SECTIONS === */
.section{
  padding:100px 40px;
  max-width:1400px;
  margin:0 auto;
}
@media(max-width:768px){.section{padding:60px 20px;}}
.section-header{
  text-align:center;
  margin-bottom:60px;
}
.section-label{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:12px;
  font-weight:600;
  text-transform:uppercase;
  letter-spacing:1px;
  color:var(--acc);
  margin-bottom:16px;
}
.section-title{
  font-size:clamp(32px, 5vw, 52px);
  font-weight:800;
  letter-spacing:-1px;
  margin:0;
  line-height:1.1;
}
.section-subtitle{
  font-size:18px;
  color:var(--muted);
  margin:16px auto 0;
  max-width:600px;
  line-height:1.6;
}

/* === FEATURE CARDS === */
.features-grid{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap:24px;
}
.feature-card{
  position:relative;
  padding:32px;
  border-radius:24px;
  background: linear-gradient(135deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border:1px solid var(--border);
  overflow:hidden;
  transition: transform .2s, box-shadow .2s;
}
.feature-card:hover{
  transform:translateY(-4px);
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
}
.feature-card::before{
  content:'';
  position:absolute;
  top:0;
  left:0;
  right:0;
  height:3px;
  background: linear-gradient(90deg, var(--acc), var(--acc2));
  opacity:0;
  transition: opacity .2s;
}
.feature-card:hover::before{opacity:1;}
.feature-icon{
  width:56px;
  height:56px;
  border-radius:16px;
  background: linear-gradient(135deg, rgba(255,46,99,.2), rgba(60,239,255,.1));
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:28px;
  margin-bottom:20px;
}
.feature-title{
  font-size:22px;
  font-weight:700;
  margin:0 0 12px 0;
}
.feature-text{
  font-size:14px;
  color:var(--muted);
  line-height:1.7;
  margin:0;
}

/* === PAGE LINKS === */
.page-links{
  display:grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap:20px;
  margin-top:40px;
}
.page-link{
  display:flex;
  align-items:center;
  gap:20px;
  padding:24px 28px;
  border-radius:20px;
  background: linear-gradient(135deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border:1px solid var(--border);
  text-decoration:none;
  color:var(--txt);
  transition: all .2s ease;
}
.page-link:hover{
  transform:translateY(-3px);
  border-color:var(--acc);
  box-shadow: 0 12px 40px rgba(255,46,99,.15);
}
.page-link-icon{
  width:60px;
  height:60px;
  border-radius:16px;
  background: linear-gradient(135deg, rgba(255,46,99,.15), rgba(60,239,255,.1));
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:28px;
  flex-shrink:0;
}
.page-link-content h3{
  font-size:18px;
  font-weight:700;
  margin:0 0 4px 0;
}
.page-link-content p{
  font-size:13px;
  color:var(--muted);
  margin:0;
}
.page-link-arrow{
  margin-left:auto;
  font-size:20px;
  color:var(--muted);
  transition: transform .2s, color .2s;
}
.page-link:hover .page-link-arrow{
  transform:translateX(4px);
  color:var(--acc);
}

/* === CALENDAR GRID === */
.calendar-grid{
  display:grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap:16px;
}
.race-card{
  position:relative;
  padding:24px;
  border-radius:20px;
  border:1px solid var(--border);
  background: linear-gradient(135deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  transition: all .15s ease;
  overflow:hidden;
}
.race-card:hover{
  transform: translateY(-3px);
  border-color: var(--acc);
  box-shadow: 0 12px 40px rgba(255,46,99,.12);
}
.race-card.sprint::after{
  content:'SPRINT';
  position:absolute;
  top:16px;
  right:16px;
  font-size:10px;
  font-weight:700;
  padding:5px 10px;
  border-radius:8px;
  background: linear-gradient(135deg, var(--acc), var(--acc2));
  color:#000;
}
.race-card.testing{
  border-color: rgba(60,239,255,.25);
  background: linear-gradient(135deg, rgba(60,239,255,.06), rgba(60,239,255,.02));
}
.race-card.testing::after{
  content:'TEST';
  position:absolute;
  top:16px;
  right:16px;
  font-size:10px;
  font-weight:700;
  padding:5px 10px;
  border-radius:8px;
  background: var(--acc2);
  color:#000;
}
.race-round{
  font-size:11px;
  font-weight:700;
  color:var(--acc);
  text-transform:uppercase;
  letter-spacing:.8px;
  margin-bottom:8px;
}
.race-flag{font-size:32px; margin-bottom:8px;}
.race-name{
  font-size:22px;
  font-weight:700;
  margin:0 0 6px 0;
  letter-spacing:-0.3px;
}
.race-gp{
  font-size:12px;
  color:var(--muted);
  margin:0 0 12px 0;
  line-height:1.4;
}
.race-date{
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-size:14px;
  font-weight:600;
  padding:8px 14px;
  border-radius:10px;
  background: rgba(255,255,255,.06);
  border:1px solid var(--border);
}
.race-time{
  margin-top:12px;
  font-size:12px;
  color:var(--muted);
  display:flex;
  flex-direction:column;
  gap:3px;
}

/* === TEAMS GRID === */
.teams-grid{
  display:grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap:24px;
}
.team-card{
  padding:28px;
  border-radius:24px;
  border:1px solid var(--border);
  background: linear-gradient(135deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  transition: all .2s ease;
}
.team-card:hover{
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
}
.team-header{
  display:flex;
  align-items:center;
  gap:16px;
  margin-bottom:20px;
}
.team-color{
  width:6px;
  height:52px;
  border-radius:3px;
  flex-shrink:0;
}
.team-name{
  font-size:24px;
  font-weight:700;
  margin:0;
  letter-spacing:-0.3px;
}
.team-engine{
  font-size:13px;
  color:var(--muted);
  margin:3px 0 0 0;
}
.team-drivers{
  display:flex;
  gap:14px;
  flex-wrap:wrap;
}
.driver{
  flex:1;
  min-width:130px;
  padding:18px;
  border-radius:16px;
  background: rgba(0,0,0,.3);
  border:1px solid rgba(255,255,255,.08);
  text-align:center;
}
.driver-number{
  font-size:32px;
  font-weight:800;
  background: linear-gradient(135deg, var(--acc), var(--acc2));
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
  background-clip:text;
}
.driver-name{
  font-size:15px;
  font-weight:600;
  margin-top:6px;
}
.driver-country{font-size:22px; margin-top:6px;}

/* === REGS GRID === */
.regs-grid{
  display:grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap:24px;
}
.reg-card{
  border-radius:24px;
  border:1px solid var(--border);
  background: linear-gradient(135deg, rgba(255,255,255,.04), rgba(255,255,255,.01));
  overflow:hidden;
  transition: all .2s ease;
}
.reg-card:hover{
  transform: translateY(-4px);
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
}
.reg-img{
  width:100%;
  height:200px;
  object-fit:cover;
  border-bottom:1px solid var(--border);
}
.reg-content{padding:24px;}
.reg-title{
  font-size:20px;
  font-weight:700;
  margin:0 0 10px 0;
}
.reg-text{
  font-size:14px;
  color:var(--muted);
  line-height:1.7;
  margin:0;
}

/* === INFO GRID === */
.info-grid{
  display:grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap:16px;
}
.info-card{
  padding:24px;
  border-radius:18px;
  background: linear-gradient(135deg, rgba(255,46,99,.08), rgba(60,239,255,.04));
  border:1px solid var(--border);
  text-align:center;
}
.info-value{
  font-size:40px;
  font-weight:800;
  background: linear-gradient(135deg, var(--acc), var(--acc2));
  -webkit-background-clip:text;
  -webkit-text-fill-color:transparent;
  background-clip:text;
}
.info-label{
  font-size:13px;
  color:var(--muted);
  margin-top:4px;
}

/* === FOOTER === */
footer{
  padding:60px 40px;
  text-align:center;
  border-top:1px solid var(--border);
  background: var(--bg2);
}
footer p{
  color:var(--muted);
  font-size:14px;
  margin:8px 0;
}
footer a{color:var(--acc); text-decoration:none;}
footer a:hover{text-decoration:underline;}

/* === BACKGROUNDS === */
.bg-gradient{
  background: 
    radial-gradient(ellipse 1000px 600px at 20% 30%, rgba(255,46,99,.1), transparent 60%),
    radial-gradient(ellipse 800px 500px at 80% 70%, rgba(60,239,255,.08), transparent 60%),
    linear-gradient(180deg, var(--bg0), var(--bg1));
}
.bg-alt{
  background: linear-gradient(180deg, var(--bg1), var(--bg2));
}

/* === MOBILE MENU TOGGLE === */
.mobile-menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  padding: 8px;
  background: transparent;
  border: none;
  color: var(--txt);
  cursor: pointer;
  border-radius: 8px;
  transition: background 0.2s;
}
.mobile-menu-toggle:hover {
  background: rgba(255,255,255,0.1);
}
.mobile-menu-toggle svg {
  width: 100%;
  height: 100%;
}

@media (max-width: 900px) {
  .mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .global-nav .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg1);
    border-bottom: 1px solid var(--border);
    padding: 16px;
    gap: 8px;
  }
  .global-nav.mobile-open .nav-links {
    display: flex;
  }
  .global-nav .nav-selectors {
    display: none;
  }
  .global-nav.mobile-open .nav-selectors {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }
}

/* === UTILS === */
.text-center{text-align:center;}
.mt-4{margin-top:40px;}
.mb-4{margin-bottom:40px;}
