/* ============================================================
   FSM — Bible College
   Design system inspired by apple.com
   Helvetica throughout · clean · minimal · smooth
   ============================================================ */

:root {
  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --ink: #1d1d1f;
  --ink-2: #6e6e73;
  --ink-3: #86868b;
  --bg: #ffffff;
  --bg-soft: #f5f5f7;
  --hairline: #d2d2d7;
  --blue: #0071e3;
  --blue-hover: #0077ed;
  --link: #06c;
  --green: #34c759;
  --red: #ff3b30;
  --orange: #ff9500;
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --nav-h: 48px;
  --ease: cubic-bezier(0.28, 0.11, 0.32, 1);
  --shadow-card: 0 8px 30px rgba(0, 0, 0, 0.06);
  --shadow-pop: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.47;
  font-size: 17px;
  letter-spacing: -0.022em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, video { display: block; max-width: 100%; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: var(--font); cursor: pointer; }
input, select, textarea { font-family: var(--font); font-size: 17px; color: var(--ink); }
::selection { background: rgba(0, 113, 227, 0.2); }

/* ---------- Page fade-in ---------- */
@keyframes pageIn { from { opacity: 0; } to { opacity: 1; } }
body { animation: pageIn 0.5s var(--ease) both; }

/* ---------- Global nav (Apple-style blur bar) ---------- */
.nav {
  position: sticky; top: 0; z-index: 1000;
  height: var(--nav-h);
  background: rgba(251, 251, 253, 0.8);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  transition: background 0.4s var(--ease);
}
.nav.nav-dark {
  background: rgba(22, 22, 23, 0.8);
  border-bottom-color: rgba(255, 255, 255, 0.1);
}
.nav-inner {
  max-width: 1024px; margin: 0 auto; height: 100%;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 22px;
}
.nav-logo {
  font-size: 21px; font-weight: 700; letter-spacing: -0.02em;
  color: var(--ink); text-decoration: none;
}
.nav-dark .nav-logo { color: #f5f5f7; }
.nav-logo:hover { text-decoration: none; }
.nav-logo .dot { color: var(--blue); }
.nav-links { display: flex; align-items: center; gap: 34px; list-style: none; }
.nav-links a {
  font-size: 13px; color: rgba(0, 0, 0, 0.8); letter-spacing: -0.01em;
  transition: color 0.3s var(--ease), opacity 0.3s var(--ease);
}
.nav-dark .nav-links a { color: rgba(255, 255, 255, 0.8); }
.nav-links a:hover { color: var(--ink); text-decoration: none; }
.nav-dark .nav-links a:hover { color: #fff; }
.nav-links a.active { color: var(--blue); }
.nav-cta {
  font-size: 13px; background: var(--blue); color: #fff !important;
  padding: 5px 14px; border-radius: 980px;
  transition: background 0.3s var(--ease);
}
.nav-cta:hover { background: var(--blue-hover); text-decoration: none !important; }

/* Mobile nav */
.nav-burger {
  display: none; background: none; border: 0; width: 40px; height: 40px;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
}
.nav-burger span {
  display: block; width: 18px; height: 1.5px; background: var(--ink);
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}
.nav-dark .nav-burger span { background: #f5f5f7; }
.nav.open .nav-burger span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav.open .nav-burger span:nth-child(2) { opacity: 0; }
.nav.open .nav-burger span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

@media (max-width: 768px) {
  .nav-burger { display: flex; }
  .nav-links {
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 0;
    background: rgba(251, 251, 253, 0.94);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    max-height: 0; overflow: hidden;
    transition: max-height 0.45s var(--ease);
  }
  .nav-dark .nav-links { background: rgba(22, 22, 23, 0.94); }
  .nav.open .nav-links { max-height: 320px; }
  .nav-links li { width: 100%; }
  .nav-links a { display: block; padding: 15px 22px; font-size: 15px; }
  .nav-links .nav-cta { display: inline-block; margin: 12px 22px 18px; padding: 7px 16px; }
}

/* ---------- Buttons & links ---------- */
.btn {
  display: inline-block; border: 0; border-radius: 980px;
  background: var(--blue); color: #fff; text-decoration: none;
  font-size: 17px; letter-spacing: -0.022em;
  padding: 12px 24px;
  transition: background 0.3s var(--ease), transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.btn:hover { background: var(--blue-hover); text-decoration: none; transform: scale(1.02); }
.btn:active { transform: scale(0.98); }
.btn.btn-lg { font-size: 19px; padding: 15px 31px; }
.btn.btn-sm { font-size: 14px; padding: 8px 16px; }
.btn.btn-ghost {
  background: transparent; color: var(--blue); border: 1px solid var(--blue);
}
.btn.btn-ghost:hover { background: var(--blue); color: #fff; }
.btn.btn-light { background: #fff; color: var(--ink); }
.btn.btn-light:hover { background: #f0f0f2; }
.btn.btn-danger { background: var(--red); }
.btn.btn-danger:hover { background: #ff453a; }
.btn:disabled { opacity: 0.4; cursor: default; transform: none; }

.link-arrow { font-size: inherit; color: var(--link); white-space: nowrap; }
.link-arrow::after {
  content: "›"; display: inline-block; margin-left: 6px;
  transition: transform 0.3s var(--ease);
}
.link-arrow:hover::after { transform: translateX(3px); }

/* ---------- Typography ---------- */
.eyebrow {
  font-size: 14px; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--blue);
}
.display {
  font-size: clamp(48px, 9vw, 96px); font-weight: 700;
  letter-spacing: -0.015em; line-height: 1.05;
}
.headline {
  font-size: clamp(32px, 5.5vw, 56px); font-weight: 700;
  letter-spacing: -0.015em; line-height: 1.08;
}
.subhead {
  font-size: clamp(19px, 2.6vw, 28px); font-weight: 400;
  letter-spacing: 0.004em; line-height: 1.3; color: var(--ink-2);
}
.body-lg { font-size: 21px; line-height: 1.42; letter-spacing: 0.011em; }
.muted { color: var(--ink-2); }
.small { font-size: 13px; }

/* ---------- Layout ---------- */
.wrap { max-width: 1024px; margin: 0 auto; padding: 0 22px; }
.wrap-wide { max-width: 1440px; margin: 0 auto; padding: 0 22px; }
.section { padding: 110px 0; }
.section-tight { padding: 70px 0; }
.section-dark { background: #000; color: #f5f5f7; }
.section-dark .subhead { color: #a1a1a6; }
.section-soft { background: var(--bg-soft); }
.center { text-align: center; }

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0; transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.reveal.in { opacity: 1; transform: none; }
.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.16s; }
.reveal-d3 { transition-delay: 0.24s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { animation-duration: 0.001s !important; animation-iteration-count: 1 !important; }
}

/* ---------- Hero ---------- */
.hero { padding: 130px 0 120px; text-align: center; overflow: hidden; }
.hero .eyebrow { margin-bottom: 14px; }
.hero .display { margin-bottom: 14px; }
.hero .subhead { max-width: 640px; margin: 0 auto 28px; }
.hero-links { display: flex; gap: 34px; justify-content: center; font-size: 21px; flex-wrap: wrap; }
.hero-dark { background: #000; color: #f5f5f7; }
.hero-dark .subhead { color: #a1a1a6; }
@keyframes heroRise {
  from { opacity: 0; transform: translateY(34px); }
  to { opacity: 1; transform: none; }
}
.hero > .wrap > * { animation: heroRise 1s var(--ease) both; }
.hero > .wrap > *:nth-child(2) { animation-delay: 0.1s; }
.hero > .wrap > *:nth-child(3) { animation-delay: 0.2s; }
.hero > .wrap > *:nth-child(4) { animation-delay: 0.3s; }

/* ---------- Animated blue period after FSM ---------- */
.blue-dot { color: var(--blue); animation: blueShades 6s ease-in-out infinite; }
@keyframes blueShades {
  0%   { color: #0071e3; }
  20%  { color: #0a84ff; }
  40%  { color: #40a9ff; }
  60%  { color: #5ac8fa; }
  80%  { color: #64d2ff; }
  100% { color: #0071e3; }
}
@media (prefers-reduced-motion: reduce) { .blue-dot { animation: none; } }

/* ---------- Featured video ---------- */
.video-frame {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  background: #000; box-shadow: var(--shadow-pop); aspect-ratio: 16 / 9;
}
.video-frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #000; }

/* Section with a live video background behind the player */
.video-hero { position: relative; overflow: hidden; }
.video-hero .bgvid {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; z-index: 0;
}
/* dark veil so the eyebrow + player stay the focus */
.video-hero::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,0.65) 0%, rgba(0,0,0,0.38) 45%, rgba(0,0,0,0.65) 100%);
}
.video-hero > .wrap { position: relative; z-index: 2; }
.video-hero .video-frame { box-shadow: 0 30px 80px rgba(0, 0, 0, 0.65); }
@media (prefers-reduced-motion: reduce) { .video-hero .bgvid { display: none; } }

/* Gradient shimmer text — blue accent (used for "FSM opens August 2027") */
.gradient-text {
  background: linear-gradient(100deg, #0071e3, #5ac8fa, #0071e3);
  background-size: 250% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: shimmer 7s linear infinite;
}
@keyframes shimmer { to { background-position: 250% 0; } }

/* ---------- Bento / cards ---------- */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card {
  background: #fff; border-radius: var(--radius-md);
  padding: 36px 30px; box-shadow: var(--shadow-card);
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.card:hover { transform: translateY(-5px); box-shadow: 0 16px 44px rgba(0, 0, 0, 0.1); }
.card h3 { font-size: 24px; font-weight: 600; letter-spacing: -0.01em; margin: 18px 0 8px; }
.card p { color: var(--ink-2); font-size: 16px; }
.card .icon {
  width: 52px; height: 52px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #1d1d1f, #48484a); color: #fff;
}
.card .icon svg { width: 26px; height: 26px; }
.card-dark { background: #1d1d1f; color: #f5f5f7; }
.card-dark p { color: #a1a1a6; }

/* Big feature tiles */
.tile {
  border-radius: var(--radius-lg); overflow: hidden; position: relative;
  padding: 64px 48px; min-height: 420px;
  display: flex; flex-direction: column; justify-content: flex-start;
  transition: transform 0.6s var(--ease);
}
.tile:hover { transform: scale(1.01); }
.tile h3 { font-size: clamp(28px, 4vw, 40px); font-weight: 700; letter-spacing: -0.015em; margin-bottom: 10px; }
.tile p { font-size: 19px; max-width: 430px; }
.tile .link-arrow { margin-top: 18px; font-size: 19px; }
@media (max-width: 620px) { .tile { padding: 44px 28px; min-height: 340px; } }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; }
@media (max-width: 768px) { .stats { grid-template-columns: repeat(2, 1fr); } }
.stat b { display: block; font-size: clamp(40px, 6vw, 64px); font-weight: 700; letter-spacing: -0.02em; }
.stat span { color: var(--ink-2); font-size: 15px; }
.section-dark .stat span { color: #a1a1a6; }

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-soft); border-top: 1px solid var(--hairline);
  padding: 34px 0 44px; font-size: 12px; color: var(--ink-2);
}
.footer .cols {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
  padding-bottom: 24px; border-bottom: 1px solid var(--hairline); margin-bottom: 18px;
}
@media (max-width: 620px) { .footer .cols { grid-template-columns: repeat(2, 1fr); } }
.footer h4 { font-size: 12px; color: var(--ink); margin-bottom: 10px; }
.footer ul { list-style: none; }
.footer li { margin-bottom: 8px; }
.footer a { color: var(--ink-2); }
.footer a:hover { color: var(--ink); text-decoration: underline; }
.footer .fine { line-height: 1.6; }

/* ============================================================
   FORMS (Apply · Login · Admin)
   ============================================================ */
.form-card {
  background: #fff; border-radius: var(--radius-md);
  box-shadow: var(--shadow-card); padding: 44px;
}
@media (max-width: 620px) { .form-card { padding: 28px 20px; } }
.field { margin-bottom: 22px; }
.field label {
  display: block; font-size: 14px; font-weight: 600; margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.field .hint { font-weight: 400; color: var(--ink-3); font-size: 12px; margin-left: 6px; }
.input, .field input[type="text"], .field input[type="email"], .field input[type="tel"],
.field input[type="date"], .field input[type="password"], .field input[type="number"],
.field input[type="url"], .field select, .field textarea {
  width: 100%; padding: 13px 16px; font-size: 17px;
  border: 1px solid var(--hairline); border-radius: var(--radius-sm);
  background: #fff; outline: none; appearance: none; -webkit-appearance: none;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%236e6e73' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
  padding-right: 40px;
}
.field textarea { min-height: 130px; resize: vertical; line-height: 1.5; }
.field input:focus, .field select:focus, .field textarea:focus, .input:focus {
  border-color: var(--blue); box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.15);
}
.field input.invalid, .field select.invalid, .field textarea.invalid {
  border-color: var(--red); box-shadow: 0 0 0 4px rgba(255, 59, 48, 0.12);
}
.field .err { display: none; color: var(--red); font-size: 12.5px; margin-top: 6px; }
.field.show-err .err { display: block; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 620px) { .form-row { grid-template-columns: 1fr; } }
.checkline { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--ink-2); }
.checkline input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--blue); flex: none; }

/* Form section headers */
.form-section-title {
  font-size: 21px; font-weight: 700; letter-spacing: -0.01em;
  margin: 38px 0 20px; padding-top: 30px; border-top: 1px solid var(--bg-soft);
}
.form-section-title:first-child { margin-top: 0; padding-top: 0; border-top: 0; }

/* Sub-heading inside a section (e.g. "Pastoral reference") */
.form-sub {
  font-size: 14px; font-weight: 600; letter-spacing: 0.02em;
  text-transform: uppercase; color: var(--ink-3);
  margin: 26px 0 14px;
}

/* Three-across row (city / state / zip) */
.form-row-3 { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 18px; }
@media (max-width: 620px) { .form-row-3 { grid-template-columns: 1fr; } }

/* Application progress indicator */
.apply-progress { margin-bottom: 20px; }
.apply-progress-bar {
  height: 4px; background: rgba(0, 0, 0, 0.08);
  border-radius: 3px; overflow: hidden;
}
.apply-progress-bar i {
  display: block; height: 100%; width: 0;
  background: var(--blue); border-radius: 3px;
  transition: width 0.45s var(--ease);
}
.apply-progress p { margin-top: 8px; color: var(--ink-3); text-align: right; }

/* Success state */
.success-wrap { text-align: center; padding: 40px 0 10px; }
.success-check {
  width: 96px; height: 96px; margin: 0 auto 26px; border-radius: 50%;
  background: var(--green); display: flex; align-items: center; justify-content: center;
  animation: popIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.4) both;
}
.success-check svg { width: 44px; height: 44px; stroke: #fff; }
.success-check svg path {
  stroke-dasharray: 60; stroke-dashoffset: 60;
  animation: draw 0.5s 0.35s var(--ease) forwards;
}
@keyframes popIn { from { transform: scale(0.3); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ============================================================
   LOGIN
   ============================================================ */
.auth-page {
  min-height: calc(100vh - var(--nav-h)); display: flex;
  align-items: center; justify-content: center; padding: 60px 22px;
  background: var(--bg-soft);
}
.auth-card {
  width: 100%; max-width: 440px; background: #fff;
  border-radius: var(--radius-lg); padding: 48px 40px;
  box-shadow: var(--shadow-card);
  animation: heroRise 0.8s var(--ease) both;
}
@media (max-width: 480px) { .auth-card { padding: 36px 24px; } }
.auth-card h1 { font-size: 30px; font-weight: 700; letter-spacing: -0.015em; margin-bottom: 6px; }
.auth-card .sub { color: var(--ink-2); font-size: 15px; margin-bottom: 30px; }
.auth-error {
  display: none; background: rgba(255, 59, 48, 0.08); color: #d70015;
  border: 1px solid rgba(255, 59, 48, 0.25); border-radius: var(--radius-sm);
  padding: 11px 14px; font-size: 14px; margin-bottom: 18px;
}
.auth-error.show { display: block; animation: shake 0.4s var(--ease); }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); } 75% { transform: translateX(6px); }
}
.demo-box {
  margin-top: 26px; border-top: 1px solid var(--bg-soft); padding-top: 18px;
  font-size: 13px; color: var(--ink-2);
}
.demo-box summary { cursor: pointer; font-weight: 600; color: var(--ink-2); }
.demo-box code {
  font-family: "SF Mono", ui-monospace, Menlo, monospace; font-size: 12px;
  background: var(--bg-soft); padding: 2px 7px; border-radius: 6px;
}
.demo-box table { width: 100%; border-collapse: collapse; margin-top: 10px; }
.demo-box td { padding: 5px 4px; border-bottom: 1px solid var(--bg-soft); }

/* ============================================================
   PORTAL
   ============================================================ */
.portal-body { background: var(--bg-soft); min-height: 100vh; }
.portal-layout { display: flex; min-height: calc(100vh - var(--nav-h)); }

.side {
  width: 250px; flex: none; padding: 28px 14px;
  border-right: 1px solid rgba(0, 0, 0, 0.07);
  background: rgba(255, 255, 255, 0.6);
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
}
.side .who { padding: 4px 14px 18px; border-bottom: 1px solid var(--bg-soft); margin-bottom: 14px; }
.side .who b { display: block; font-size: 15px; letter-spacing: -0.01em; }
.side .who span { font-size: 12.5px; color: var(--ink-3); }
.side .who .role-chip {
  display: inline-block; margin-top: 8px; font-size: 11px; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase;
  background: rgba(0, 113, 227, 0.1); color: var(--blue);
  padding: 3px 9px; border-radius: 980px;
}
.side nav { display: flex; flex-direction: column; gap: 2px; }
.side nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: 10px;
  color: var(--ink); font-size: 14.5px; letter-spacing: -0.01em;
  transition: background 0.25s var(--ease);
}
.side nav a:hover { background: rgba(0, 0, 0, 0.045); text-decoration: none; }
.side nav a.active { background: var(--blue); color: #fff; }
.side nav a.active svg { stroke: #fff; }
.side nav a svg { width: 18px; height: 18px; stroke: var(--ink-2); flex: none; }
.side nav .sep { height: 1px; background: var(--bg-soft); margin: 12px 8px; }
.side .signout { color: var(--red); }
.side .signout svg { stroke: var(--red); }

.portal-main { flex: 1; padding: 44px 44px 80px; min-width: 0; }
@media (max-width: 900px) {
  .portal-layout { flex-direction: column; }
  .side {
    width: 100%; display: flex; align-items: center; gap: 8px;
    padding: 10px 14px; overflow-x: auto;
    border-right: 0; border-bottom: 1px solid rgba(0, 0, 0, 0.07);
  }
  .side .who { display: none; }
  .side nav { flex-direction: row; }
  .side nav a { white-space: nowrap; padding: 8px 12px; }
  .side nav .sep { display: none; }
  .portal-main { padding: 28px 20px 60px; }
}

.portal-title { font-size: clamp(28px, 4vw, 40px); font-weight: 700; letter-spacing: -0.015em; }
.portal-sub { color: var(--ink-2); margin: 6px 0 30px; font-size: 16px; }

/* Panel = white card in portal */
.panel {
  background: #fff; border-radius: var(--radius-md);
  box-shadow: var(--shadow-card); padding: 28px;
  margin-bottom: 22px;
}
.panel h2 { font-size: 21px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 16px; }
.panel-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }

/* Summary stat cards */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 16px; margin-bottom: 22px; }
.kpi {
  background: #fff; border-radius: var(--radius-md); padding: 22px 24px;
  box-shadow: var(--shadow-card);
}
.kpi b { display: block; font-size: 34px; font-weight: 700; letter-spacing: -0.02em; }
.kpi span { font-size: 13px; color: var(--ink-2); }
.kpi.accent { background: linear-gradient(135deg, #0071e3, #3f9bff); color: #fff; }
.kpi.accent span { color: rgba(255, 255, 255, 0.75); }

/* Tables */
.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 14.5px; }
table.data th {
  text-align: left; font-size: 12px; font-weight: 600; letter-spacing: 0.05em;
  text-transform: uppercase; color: var(--ink-3);
  padding: 10px 14px; border-bottom: 1px solid var(--bg-soft);
}
table.data td { padding: 14px; border-bottom: 1px solid var(--bg-soft); vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr { transition: background 0.2s var(--ease); }
table.data tbody tr:hover { background: #fafafa; }

/* Chips / badges */
.chip {
  display: inline-block; font-size: 12px; font-weight: 600;
  padding: 4px 11px; border-radius: 980px; letter-spacing: 0;
}
.chip-blue { background: rgba(0, 113, 227, 0.1); color: var(--blue); }
.chip-green { background: rgba(52, 199, 89, 0.14); color: #1d8a3e; }
.chip-orange { background: rgba(255, 149, 0, 0.14); color: #c26a00; }
.chip-red { background: rgba(255, 59, 48, 0.1); color: #d70015; }
.chip-gray { background: rgba(0, 0, 0, 0.06); color: var(--ink-2); }

/* Grade ring */
.grade-pill {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 44px; height: 30px; padding: 0 10px; border-radius: 980px;
  font-weight: 700; font-size: 14px;
}
.g-a { background: rgba(52, 199, 89, 0.15); color: #1d8a3e; }
.g-b { background: rgba(0, 113, 227, 0.12); color: var(--blue); }
.g-c { background: rgba(255, 149, 0, 0.15); color: #c26a00; }
.g-d, .g-f { background: rgba(255, 59, 48, 0.12); color: #d70015; }
.g-na { background: rgba(0, 0, 0, 0.05); color: var(--ink-3); }

/* Progress bar */
.bar { height: 6px; background: var(--bg-soft); border-radius: 4px; overflow: hidden; }
.bar i {
  display: block; height: 100%; border-radius: 4px;
  background: linear-gradient(90deg, #0071e3, #55b0ff);
  transition: width 1s var(--ease);
}

/* ---------- Year bar (admin: which cohort am I working with?) ---------- */
.year-bar {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  background: #fff; border-radius: 16px; padding: 14px 18px;
  box-shadow: var(--shadow-card); margin-bottom: 22px;
  border-left: 4px solid var(--blue);
  transition: border-color 0.3s var(--ease);
}
body.is-year2 .year-bar { border-left-color: #9f7aff; }
body.is-all   .year-bar { border-left-color: var(--ink); }
.year-label {
  font-size: 12px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ink-3);
}
.year-pills {
  display: flex; gap: 6px; background: rgba(0, 0, 0, 0.05);
  border-radius: 980px; padding: 4px; flex-wrap: wrap;
}
.year-pills button {
  border: 0; background: transparent; border-radius: 980px;
  font-size: 14px; font-weight: 500; padding: 8px 16px; color: var(--ink);
  display: flex; align-items: center; gap: 7px;
  transition: background 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.year-pills button i {
  font-style: normal; font-size: 11px; font-weight: 600;
  background: rgba(0, 0, 0, 0.08); color: var(--ink-2);
  padding: 2px 7px; border-radius: 980px;
}
.year-pills button.active {
  background: #fff; font-weight: 600; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
.year-pills button.active i { background: var(--blue); color: #fff; }
body.is-year2 .year-pills button.active i { background: #9f7aff; }
body.is-all   .year-pills button.active i { background: var(--ink); }
.year-note { font-size: 13.5px; color: var(--ink-2); margin-left: auto; }
.year-note b { color: var(--ink); }
@media (max-width: 760px) { .year-note { margin-left: 0; width: 100%; } }

/* Segmented control (admin tabs) */
.seg {
  display: inline-flex; background: rgba(0, 0, 0, 0.05);
  border-radius: 980px; padding: 3px; gap: 2px; flex-wrap: wrap;
}
.seg button {
  border: 0; background: transparent; border-radius: 980px;
  font-size: 13.5px; font-weight: 500; padding: 8px 18px; color: var(--ink);
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.seg button.active { background: #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12); font-weight: 600; }

/* Empty state */
.empty { text-align: center; padding: 54px 20px; color: var(--ink-3); }
.empty .glyph { font-size: 40px; margin-bottom: 12px; }
.empty b { display: block; color: var(--ink-2); font-size: 16px; margin-bottom: 4px; }

/* Toast */
.toast {
  position: fixed; bottom: 30px; left: 50%; transform: translateX(-50%) translateY(80px);
  background: rgba(29, 29, 31, 0.92); color: #fff;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  padding: 13px 22px; border-radius: 980px; font-size: 14.5px;
  opacity: 0; pointer-events: none; z-index: 2000;
  transition: transform 0.45s var(--ease), opacity 0.45s var(--ease);
  box-shadow: var(--shadow-pop); max-width: 90vw; text-align: center;
}
.toast.show { transform: translateX(-50%) translateY(0); opacity: 1; }

/* Modal */
.modal-back {
  position: fixed; inset: 0; background: rgba(0, 0, 0, 0.4);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  display: none; align-items: center; justify-content: center; z-index: 1500; padding: 20px;
}
.modal-back.show { display: flex; animation: pageIn 0.3s var(--ease); }
.modal {
  background: #fff; border-radius: var(--radius-lg); width: 100%; max-width: 560px;
  max-height: 86vh; overflow-y: auto; padding: 36px;
  animation: popIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.2) both;
}
@media (max-width: 560px) { .modal { padding: 26px 20px; } }
.modal h3 { font-size: 24px; font-weight: 700; letter-spacing: -0.015em; margin-bottom: 22px; }
.modal .modal-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 26px; }

/* Student checklist in admin */
.pick-list {
  border: 1px solid var(--hairline); border-radius: var(--radius-sm);
  max-height: 200px; overflow-y: auto;
}
.pick-list label {
  display: flex; gap: 10px; align-items: center; padding: 11px 14px;
  border-bottom: 1px solid var(--bg-soft); font-size: 14.5px; cursor: pointer;
  transition: background 0.2s;
}
.pick-list label:hover { background: #fafafa; }
.pick-list label:last-child { border-bottom: 0; }
.pick-list input { accent-color: var(--blue); width: 16px; height: 16px; }

/* Inline grade input */
.grade-input {
  width: 76px; padding: 8px 10px; text-align: center;
  border: 1px solid var(--hairline); border-radius: 10px; font-size: 14.5px;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.grade-input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.15); }

/* ============================================================
   LIVESTREAM
   ============================================================ */
.live-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--red); color: #fff; font-size: 12px; font-weight: 700;
  letter-spacing: 0.1em; padding: 6px 14px; border-radius: 980px;
}
.live-badge i {
  width: 8px; height: 8px; border-radius: 50%; background: #fff;
  animation: blink 1.4s ease-in-out infinite;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
.player-shell {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  background: #000; box-shadow: var(--shadow-pop); aspect-ratio: 16 / 9;
}
.player-shell iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.offline-state {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 12px; color: #a1a1a6;
  background:
    radial-gradient(ellipse 70% 60% at 50% 40%, rgba(0, 113, 227, 0.16), transparent 70%),
    #000;
  text-align: center; padding: 24px;
}
.offline-state .pulse-dot {
  width: 60px; height: 60px; border-radius: 50%;
  background: rgba(0, 113, 227, 0.18);
  display: flex; align-items: center; justify-content: center;
  animation: breathe 3s ease-in-out infinite;
}
.offline-state .pulse-dot::after {
  content: ""; width: 22px; height: 22px; border-radius: 50%; background: var(--blue);
}
@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.12); } }
.offline-state h3 { color: #f5f5f7; font-size: 24px; font-weight: 700; }

/* ============================================================
   CAMPUS MAP (Home) — dark, premium, understated
   ============================================================ */
.map-section {
  background: #000; color: #f5f5f7; padding: 120px 0 130px; overflow: hidden;
}
.map-kicker { text-align: center; margin-bottom: 54px; }
.map-kicker .coming {
  font-size: clamp(40px, 7vw, 76px); font-weight: 700; letter-spacing: -0.015em;
  line-height: 1.18; padding-bottom: 0.12em;
}
.map-kicker .subhead { max-width: 560px; margin: 16px auto 0; }

/* ============================================================
   COUNTDOWN — Apple-style: huge ultra-light numerals
   ============================================================ */
.countdown {
  display: flex; justify-content: center; align-items: flex-start;
  gap: clamp(10px, 3vw, 34px); margin-top: 16px;
}
.cd-unit { text-align: center; min-width: 0; }
.cd-unit b {
  display: block;
  font-size: clamp(52px, 12vw, 148px);
  font-weight: 200;                          /* Helvetica Neue UltraLight */
  line-height: 1; color: #f5f5f7; letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums; font-feature-settings: "tnum";
}
/* iOS-style tick when a digit changes */
.cd-unit b.tick { animation: cdTick 0.4s var(--ease); }
@keyframes cdTick {
  from { opacity: 0.25; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}
.cd-unit span {
  display: block; margin-top: clamp(10px, 2vw, 18px);
  font-size: clamp(9px, 1.4vw, 12px); font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase; color: #6e6e73;
}
.cd-sep {
  font-size: clamp(40px, 9vw, 112px); font-weight: 100;
  line-height: 1.06; color: #3a3a3c; user-select: none;
}
.cd-date {
  text-align: center; margin-top: clamp(26px, 4vw, 44px);
  font-size: 15px; color: #86868b; letter-spacing: 0.01em;
}
@media (max-width: 560px) { .cd-sep { display: none; } .countdown { gap: 16px; } }

/* ---------- Utility ---------- */
.mt-0 { margin-top: 0 !important; } .mt-1 { margin-top: 10px; } .mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 34px; } .mt-4 { margin-top: 54px; }
.mb-1 { margin-bottom: 10px; } .mb-2 { margin-bottom: 20px; } .mb-3 { margin-bottom: 34px; }
.hidden { display: none !important; }
.flex { display: flex; } .aic { align-items: center; } .jcb { justify-content: space-between; }
.gap-1 { gap: 10px; } .gap-2 { gap: 20px; }
