/* CV LABS site — Floodlit Night system (shared with the Tuesday Record Book) */

:root {
  --navy-0: #080c15;   /* page ground */
  --navy-1: #0f1420;   /* panels */
  --navy-2: #151c29;   /* cards */
  --line:   #26304a;
  --line-soft: #1c2436;
  --ink:    #e8eef7;
  --muted:  #8b95a8;
  --ice:    #7be6ff;
  --ice-deep: #41c9ee;
  --gold:   #f9c64e;
  --gold-deep: #f0a726;
  --brand-blue: #2f6bff;
  --brand-cyan: #5ce0e6;
  --maxw: 1120px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--navy-0);
  color: var(--ink);
  font-family: 'TRB Barlow', 'Barlow Semi Condensed', system-ui, sans-serif;
  font-weight: 500;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* floodlight wash + grain, fixed behind everything */
.floodlights {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(1200px 640px at 18% -8%, rgba(123, 230, 255, 0.10), transparent 62%),
    radial-gradient(1000px 560px at 82% -12%, rgba(47, 107, 255, 0.12), transparent 60%),
    radial-gradient(900px 900px at 50% 118%, rgba(249, 198, 78, 0.05), transparent 55%);
}
.grain {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.6'/%3E%3C/svg%3E");
}

.page { position: relative; z-index: 1; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }

/* ---------- header ---------- */
.site-header { padding: 26px 0 0; }
.site-header .wrap { display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand img { height: 40px; width: auto; display: block; }
.site-nav { margin-left: auto; display: flex; align-items: center; gap: 26px; }
.site-nav a {
  color: var(--muted); text-decoration: none; font-weight: 600;
  font-size: 15px; letter-spacing: 0.02em; transition: color 0.15s;
}
.site-nav a:hover { color: var(--ice); }
.site-nav .signin {
  color: var(--ink); border: 1px solid var(--line); border-radius: 8px;
  padding: 8px 16px; transition: border-color 0.15s, color 0.15s;
}
.site-nav .signin:hover { border-color: var(--ice-deep); color: var(--ice); }

/* ---------- hero ---------- */
.hero { padding: 108px 0 96px; }
.eyebrow {
  font-family: 'TRB Six Caps', sans-serif; font-size: 21px; letter-spacing: 0.34em;
  color: var(--ice-deep); text-transform: uppercase; margin-bottom: 22px;
}
.hero h1 {
  font-family: 'TRB Anton', sans-serif; font-weight: 400;
  font-size: clamp(52px, 7.2vw, 92px); line-height: 1.02;
  letter-spacing: 0.01em; text-transform: uppercase; max-width: 900px;
}
.hero h1 .lit { color: var(--ice); }
.hero .lede {
  margin-top: 28px; max-width: 620px; font-size: 19px; color: var(--muted);
}
.hero .cta-row { margin-top: 40px; display: flex; gap: 16px; flex-wrap: wrap; }

.btn {
  display: inline-block; text-decoration: none; font-weight: 700; font-size: 16px;
  letter-spacing: 0.02em; border-radius: 10px; padding: 14px 26px;
  transition: transform 0.12s, box-shadow 0.12s, border-color 0.15s, color 0.15s;
}
.btn-primary {
  color: #06121f;
  background: linear-gradient(120deg, var(--brand-cyan), var(--brand-blue) 82%);
  box-shadow: 0 6px 26px rgba(47, 107, 255, 0.32);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 30px rgba(47, 107, 255, 0.42); }
.btn-ghost { color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--ice-deep); color: var(--ice); }
.btn-gold {
  color: #140e02;
  background: linear-gradient(120deg, var(--gold), var(--gold-deep) 85%);
  box-shadow: 0 6px 26px rgba(240, 167, 38, 0.28);
}
.btn-gold:hover { transform: translateY(-1px); box-shadow: 0 8px 30px rgba(240, 167, 38, 0.38); }

/* ---------- sections ---------- */
.section { padding: 84px 0; }
.section-head {
  font-family: 'TRB Anton', sans-serif; font-weight: 400; text-transform: uppercase;
  font-size: clamp(30px, 3.6vw, 44px); letter-spacing: 0.02em; margin-bottom: 40px;
}

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card {
  background: var(--navy-2); border: 1px solid var(--line-soft); border-radius: 14px;
  padding: 30px 28px;
}
.card svg { display: block; margin-bottom: 20px; }
.card h3 { font-size: 19px; font-weight: 700; letter-spacing: 0.01em; margin-bottom: 10px; }
.card p { color: var(--muted); font-size: 16px; }

/* ---------- record book doorway ---------- */
.bookplate {
  background: linear-gradient(180deg, #0a0d13, #0d1018);
  border: 1px solid rgba(249, 198, 78, 0.28); border-radius: 16px;
  padding: 64px 40px; text-align: center;
  position: relative; overflow: hidden;
}
.bookplate::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(640px 300px at 50% 0%, rgba(249, 198, 78, 0.09), transparent 70%);
}
.bookplate .plate-kicker {
  font-family: 'TRB Six Caps', sans-serif; font-size: 19px; letter-spacing: 0.4em;
  color: var(--gold-deep); text-transform: uppercase;
}
.bookplate h2 {
  font-family: 'TRB Cinzel', serif; font-weight: 800;
  font-size: clamp(30px, 4.4vw, 52px); line-height: 1.12; margin: 18px auto 0;
  max-width: 720px;
  background: linear-gradient(178deg, #fce9b8 12%, var(--gold) 38%, #b07f1c 62%, var(--gold) 88%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.plate-rule {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  margin: 26px 0; color: rgba(249, 198, 78, 0.7); font-size: 13px;
}
.plate-rule::before, .plate-rule::after {
  content: ""; height: 1px; width: 120px;
  background: linear-gradient(90deg, transparent, rgba(249, 198, 78, 0.45));
}
.plate-rule::after { transform: scaleX(-1); }
.bookplate .plate-copy { max-width: 560px; margin: 0 auto 34px; color: var(--muted); }
.bookplate .plate-note { margin-top: 18px; font-size: 14px; color: #6d7688; }

/* ---------- contact ---------- */
.contact-strip {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  background: var(--navy-1); border: 1px solid var(--line-soft); border-radius: 14px;
  padding: 36px 40px; flex-wrap: wrap;
}
.contact-strip h2 {
  font-family: 'TRB Anton', sans-serif; font-weight: 400; text-transform: uppercase;
  font-size: 26px; letter-spacing: 0.02em;
}
.contact-strip p { color: var(--muted); margin-top: 6px; }
.contact-strip a.mail {
  font-family: 'TRB Barlow', sans-serif; font-weight: 700; font-size: 19px;
  color: var(--ice); text-decoration: none;
}
.contact-strip a.mail:hover { color: #fff; }

/* ---------- prose pages (privacy, 404) ---------- */
.prose { max-width: 760px; padding: 72px 0 40px; }
.prose h1 {
  font-family: 'TRB Anton', sans-serif; font-weight: 400; text-transform: uppercase;
  font-size: clamp(36px, 5vw, 56px); margin-bottom: 30px;
}
.prose h2 { font-size: 21px; font-weight: 700; margin: 38px 0 12px; }
.prose p, .prose li { color: var(--muted); margin-bottom: 14px; }
.prose ul { padding-left: 22px; }
.prose a { color: var(--ice); text-decoration: none; }
.prose a:hover { text-decoration: underline; }
.prose .updated { font-size: 14px; color: #6d7688; margin-bottom: 34px; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line-soft); margin-top: 40px; padding: 36px 0 48px; }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.site-footer p { color: #6d7688; font-size: 14px; max-width: 640px; }
.site-footer nav { display: flex; gap: 22px; }
.site-footer nav a { color: var(--muted); font-size: 14px; font-weight: 600; text-decoration: none; }
.site-footer nav a:hover { color: var(--ice); }

/* ---------- entrance gate v2 ---------- */
html, body { overflow-x: hidden; -webkit-text-size-adjust: 100%; }

.glow {
  position: fixed; z-index: 0; pointer-events: none;
  width: 62vmax; height: 62vmax; border-radius: 50%;
  filter: blur(10px);
}
.g1 {
  top: -34vmax; left: -18vmax;
  background: radial-gradient(circle, rgba(123, 230, 255, 0.075), transparent 62%);
  animation: drift1 34s ease-in-out infinite alternate;
}
.g2 {
  bottom: -36vmax; right: -20vmax;
  background: radial-gradient(circle, rgba(47, 107, 255, 0.085), transparent 62%);
  animation: drift2 44s ease-in-out infinite alternate;
}
@keyframes drift1 { from { transform: translate(0, 0); } to { transform: translate(7vmax, 5vmax); } }
@keyframes drift2 { from { transform: translate(0, 0); } to { transform: translate(-6vmax, -6vmax); } }

.pitchviz {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  width: 100%; height: 100%;
  animation: vizIn 2.2s ease-out both;
}
.pitchviz .track { animation: trackFloat 7s ease-in-out infinite alternate; }
.pitchviz .ball { animation: ballGlow 3.4s ease-in-out infinite alternate; }
@keyframes vizIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes trackFloat { from { transform: translate(0, 0); } to { transform: translate(-5px, 4px); } }
@keyframes ballGlow { from { opacity: 0.32; } to { opacity: 0.62; } }

.gate {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: clamp(34px, 5.5vh, 52px);
  padding: max(40px, env(safe-area-inset-top)) 20px 84px;
}

.hero-title { text-align: center; }
.t-game {
  font-family: 'TRB Anton', sans-serif; font-weight: 400;
  font-size: clamp(64px, 14vw, 132px); line-height: 0.98;
  letter-spacing: 0.015em; text-transform: uppercase;
  color: var(--ink);
  text-shadow: 0 0 60px rgba(123, 230, 255, 0.16);
  animation: riseIn 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
.t-rule {
  display: flex; align-items: center; justify-content: center; gap: 16px;
  margin: clamp(16px, 2.6vh, 24px) 0;
  animation: ruleIn 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) 0.25s both;
}
.t-rule::before, .t-rule::after {
  content: ""; height: 1px; width: clamp(64px, 11vw, 120px);
  background: linear-gradient(90deg, transparent, rgba(249, 198, 78, 0.55));
}
.t-rule::after { transform: scaleX(-1); }
.t-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: linear-gradient(140deg, #fce9b8, var(--gold-deep));
  box-shadow: 0 0 14px rgba(249, 198, 78, 0.55);
}
.t-decoded {
  font-family: 'TRB Cinzel', serif; font-weight: 800; text-transform: uppercase;
  font-size: clamp(19px, 4.4vw, 31px);
  letter-spacing: 0.52em; text-indent: 0.52em;
  background: linear-gradient(178deg, #fce9b8 12%, var(--gold) 38%, #b07f1c 62%, var(--gold) 88%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: trackIn 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) 0.4s both;
}
@keyframes riseIn { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes ruleIn { from { opacity: 0; transform: scaleX(0.4); } to { opacity: 1; transform: none; } }
@keyframes trackIn {
  from { opacity: 0; letter-spacing: 0.85em; text-indent: 0.85em; }
  to { opacity: 1; letter-spacing: 0.52em; text-indent: 0.52em; }
}

.gate-card {
  width: min(94vw, 420px);
  background: linear-gradient(180deg, rgba(15, 19, 28, 0.82), rgba(9, 12, 18, 0.88));
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border: 1px solid rgba(123, 230, 255, 0.13);
  border-radius: 20px;
  padding: 26px 26px 22px;
  text-align: center;
  box-shadow: 0 34px 90px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(232, 238, 247, 0.05);
  animation: riseIn 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) 0.55s both;
}
.gate-card.shake { animation: shake 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97); }
@keyframes shake {
  10%, 90% { transform: translateX(-1px); }
  20%, 80% { transform: translateX(2px); }
  30%, 50%, 70% { transform: translateX(-4px); }
  40%, 60% { transform: translateX(4px); }
}

.tabs {
  position: relative; display: flex;
  background: rgba(8, 11, 17, 0.85);
  border: 1px solid var(--line-soft);
  border-radius: 13px; padding: 4px;
  margin-bottom: 20px;
}
.tab-ind {
  position: absolute; top: 4px; left: 4px;
  width: calc(50% - 4px); height: calc(100% - 8px);
  border-radius: 10px;
  background: linear-gradient(120deg, var(--brand-cyan), var(--brand-blue) 85%);
  box-shadow: 0 4px 16px rgba(47, 107, 255, 0.35);
  transition: transform 0.28s cubic-bezier(0.3, 0.8, 0.3, 1);
}
.tab {
  position: relative; z-index: 1; flex: 1;
  background: none; border: none; cursor: pointer;
  padding: 11px 0;
  font-family: 'TRB Barlow', sans-serif; font-weight: 700; font-size: 14.5px;
  letter-spacing: 0.035em;
  color: var(--muted); transition: color 0.2s;
}
.tab.active { color: #06121f; }
.tab:not(.active):hover { color: var(--ink); }

.panes { position: relative; }
.pane { display: none; }
.pane.active { display: block; animation: paneIn 0.25s ease-out; }
@keyframes paneIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.code-input {
  display: block; width: 100%;
  background: rgba(10, 13, 20, 0.9); color: var(--ink);
  border: 1px solid var(--line); border-radius: 13px;
  padding: 16px 18px;
  font-family: 'TRB Mono', ui-monospace, monospace; font-weight: 600;
  font-size: 21px; letter-spacing: 0.42em; text-indent: 0.42em; text-align: center;
  transition: border-color 0.18s, box-shadow 0.18s;
}
.code-input::placeholder { color: #46506444; letter-spacing: 0.42em; }
.code-input:focus, .admin-input:focus {
  outline: none; border-color: var(--ice-deep);
  box-shadow: 0 0 0 3px rgba(65, 201, 238, 0.16);
}

.admin-input {
  display: block; width: 100%; margin-bottom: 12px;
  background: rgba(10, 13, 20, 0.9); color: var(--ink);
  border: 1px solid var(--line); border-radius: 13px;
  padding: 14px 18px; font-family: 'TRB Barlow', sans-serif;
  font-weight: 500; font-size: 16px;
  transition: border-color 0.18s, box-shadow 0.18s;
}
.admin-input::placeholder { color: #5a6478; }

.enter-btn {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  width: 100%; margin-top: 13px;
  border: none; cursor: pointer; border-radius: 13px;
  padding: 15px 0;
  font-family: 'TRB Barlow', sans-serif; font-weight: 700; font-size: 16.5px;
  letter-spacing: 0.03em; color: #06121f;
  background: linear-gradient(120deg, var(--brand-cyan), var(--brand-blue) 82%);
  box-shadow: 0 8px 26px rgba(47, 107, 255, 0.32);
  transition: transform 0.12s, box-shadow 0.12s, filter 0.12s;
}
.enter-btn:hover { transform: translateY(-1px); box-shadow: 0 10px 30px rgba(47, 107, 255, 0.44); filter: brightness(1.05); }
.enter-btn:active { transform: translateY(0); }

.gate-hint { margin-top: 14px; font-size: 13.5px; color: #6d7688; }
.gate-error { min-height: 20px; margin-top: 10px; font-size: 14px; color: #ff8a84; }

.gate-alt {
  display: inline-block; margin-top: 16px;
  background: none; border: none; cursor: pointer;
  color: #6d7688; font-family: 'TRB Barlow', sans-serif; font-weight: 600;
  font-size: 13.5px; letter-spacing: 0.03em; text-decoration: none;
  transition: color 0.15s;
}
.gate-alt:hover { color: var(--ice); }

.gate-open { padding: 10px 0 6px; }
.gate-open .gate-welcome { color: var(--muted); margin-bottom: 18px; }
.gate-open .btn { display: block; }

.gate-more {
  position: absolute; bottom: max(22px, env(safe-area-inset-bottom)); left: 50%;
  color: #4b5568; transition: color 0.15s;
  animation: floatCue 2.6s ease-in-out infinite;
}
@keyframes floatCue {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 5px); }
}
.gate-more:hover { color: var(--ice); }

@media (prefers-reduced-motion: reduce) {
  .glow, .pitchviz, .pitchviz .track, .pitchviz .ball,
  .t-game, .t-rule, .t-decoded, .gate-card, .gate-more { animation: none; }
}

@media (max-width: 640px) {
  .gate { gap: 36px; }
  .gate-card { padding: 22px 18px 18px; }
  .code-input { font-size: 19px; }
}

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .cards { grid-template-columns: 1fr; }
  .hero { padding: 72px 0 64px; }
  .section { padding: 60px 0; }
}
@media (max-width: 640px) {
  .site-nav a:not(.signin) { display: none; }
  .brand img { height: 32px; }
  .contact-strip { padding: 28px 24px; }
  .bookplate { padding: 48px 22px; }
  .wrap { padding: 0 20px; }
}
