/* ===================================================================
   Aspirants NEET Academy
   Palette taken from the logo: royal blue figures, gold caduceus/book.
   =================================================================== */

:root {
  --blue-900: #062f5e;
  --blue-800: #0a417f;
  --blue-700: #0d52a0;
  --blue-600: #1263bd;
  --blue-500: #2b7fd8;
  --blue-100: #e3eefb;
  --blue-050: #f2f7fd;

  --gold-700: #8a6216;
  --gold-600: #a8791f;
  --gold-500: #c08f2a;
  --gold-400: #dCAA43;
  --gold-100: #faf0d8;

  --ink-900: #10182a;
  --ink-700: #33405c;
  --ink-500: #5c6883;
  --ink-300: #93a0b8;
  --line: #e3e8f0;
  --surface: #ffffff;
  --surface-2: #f6f8fc;

  --ok: #12805c;
  --ok-bg: #e6f6ef;
  --bad: #b4232b;
  --bad-bg: #fdeced;
  --warn: #9a6a05;
  --warn-bg: #fdf3dd;

  --radius: 14px;
  --radius-sm: 9px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 42, .06), 0 1px 3px rgba(16, 24, 42, .05);
  --shadow: 0 4px 12px rgba(16, 24, 42, .07), 0 12px 28px rgba(16, 24, 42, .06);
  --shadow-lg: 0 18px 45px rgba(6, 47, 94, .16);

  --container: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Segoe UI", Inter, system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-700);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--ink-900);
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: -.015em;
  margin: 0 0 .6rem;
}

h1 { font-size: clamp(1.95rem, 4vw, 2.85rem); }
h2 { font-size: clamp(1.55rem, 2.9vw, 2.15rem); }
h3 { font-size: clamp(1.18rem, 1.9vw, 1.4rem); }

p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }

a { color: var(--blue-700); text-decoration: none; }
a:hover { color: var(--blue-600); text-decoration: underline; }

img { max-width: 100%; height: auto; }

.container-x {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 20px;
}

/* ------------------------------------------------------------- UTILITIES */

.eyebrow {
  display: inline-block;
  font-size: .74rem;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--gold-600);
  margin-bottom: .7rem;
}

.eyebrow-light { color: var(--gold-400); }

.section { padding: clamp(2.4rem, 4.2vw, 3.9rem) 0; }
.section-tight { padding: clamp(1.7rem, 2.9vw, 2.5rem) 0; }
.section-alt { background: var(--surface-2); }
.section-blue {
  background: linear-gradient(160deg, var(--blue-800) 0%, var(--blue-900) 100%);
  color: #dbe6f5;
}
.section-blue h1, .section-blue h2, .section-blue h3 { color: #fff; }

.section-head { max-width: 760px; margin: 0 auto clamp(1.5rem, 2.6vw, 2.1rem); text-align: center; }
.section-head.left { margin-inline: 0; text-align: left; }
.section-head p { color: var(--ink-500); font-size: 1.08rem; }
.section-blue .section-head p { color: #b9cbe4; }

.lead { font-size: 1.14rem; color: var(--ink-500); }

.text-gold { color: var(--gold-600); }
.text-muted-2 { color: var(--ink-500); }

.rule {
  width: 64px; height: 4px; border-radius: 4px;
  background: linear-gradient(90deg, var(--blue-700), var(--gold-500));
  margin: 0 auto 1.1rem;
}
.section-head.left .rule { margin-inline: 0; }

/* --------------------------------------------------------------- BUTTONS */

.btn-x {
  --btn-bg: var(--blue-700);
  --btn-fg: #fff;
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  padding: .78rem 1.55rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-weight: 650;
  font-size: .97rem;
  line-height: 1.2;
  cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
  text-decoration: none;
}
.btn-x:hover {
  color: var(--btn-fg);
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(13, 82, 160, .28);
}
.btn-x:focus-visible { outline: 3px solid var(--gold-400); outline-offset: 2px; }

.btn-gold { --btn-bg: linear-gradient(135deg, var(--gold-500), var(--gold-600)); }
.btn-gold:hover { box-shadow: 0 8px 20px rgba(168, 121, 31, .34); }

.btn-outline {
  --btn-bg: transparent;
  --btn-fg: var(--blue-700);
  border-color: var(--blue-700);
}
.btn-outline:hover { background: var(--blue-700); --btn-fg: #fff; }

.btn-ghost-light {
  --btn-bg: rgba(255, 255, 255, .1);
  --btn-fg: #fff;
  border-color: rgba(255, 255, 255, .45);
  backdrop-filter: blur(3px);
}
.btn-ghost-light:hover { background: #fff; --btn-fg: var(--blue-800); }

.btn-sm { padding: .5rem 1.05rem; font-size: .87rem; }
.btn-lg { padding: .95rem 2rem; font-size: 1.05rem; }
.btn-block { width: 100%; justify-content: center; }

/* ---------------------------------------------------------------- HEADER */

.topbar {
  background: var(--blue-900);
  color: #b9cbe4;
  font-size: .88rem;
  padding: .45rem 0;
}
.topbar a { color: #dbe6f5; }
.topbar-inner { display: flex; flex-wrap: wrap; gap: 1.2rem; align-items: center; justify-content: space-between; }
.topbar-links { display: flex; gap: 1.1rem; align-items: center; flex-wrap: wrap; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 1030;
  background: rgba(255, 255, 255, .94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
  min-height: 74px;
}
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; flex: none; }
.brand:hover { text-decoration: none; }
.brand img { height: 52px; width: auto; flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.12; }
.brand-name { font-weight: 800; color: var(--blue-800); font-size: 1.04rem; letter-spacing: -.01em; white-space: nowrap; }
.brand-tag { font-size: .67rem; letter-spacing: .15em; text-transform: uppercase; color: var(--gold-600); font-weight: 700; white-space: nowrap; }

/* Between the nav breakpoint and a comfortable desktop width the full nav and
   the wordmark cannot both fit, so the logo stands alone. */
@media (min-width: 992px) and (max-width: 1199px) {
  .brand-text { display: none; }
}

.nav-x { display: flex; align-items: center; gap: .2rem; }
.nav-x a {
  padding: .5rem .82rem;
  border-radius: 999px;
  color: var(--ink-700);
  font-weight: 600;
  font-size: .94rem;
  text-decoration: none;
  white-space: nowrap;
}
.nav-x a:hover { background: var(--blue-050); color: var(--blue-700); text-decoration: none; }
.nav-x a.active { background: var(--blue-100); color: var(--blue-800); }

.header-actions { display: flex; align-items: center; gap: .55rem; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  width: 42px; height: 42px;
  font-size: 1.35rem;
  color: var(--blue-800);
  cursor: pointer;
}

@media (max-width: 991px) {
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .header-collapse {
    display: none;
    width: 100%;
    padding: .8rem 0 1.1rem;
    border-top: 1px solid var(--line);
  }
  .header-collapse.open { display: block; }
  .header-inner { flex-wrap: wrap; }
  .nav-x { flex-direction: column; align-items: stretch; gap: .1rem; }
  .nav-x a { padding: .7rem .85rem; }
  .header-actions { margin-top: .8rem; flex-direction: column; align-items: stretch; }
  .header-actions .btn-x { justify-content: center; }
}
@media (min-width: 992px) {
  .header-collapse { display: flex !important; align-items: center; gap: 1.2rem; }
}

/* ------------------------------------------------------------------ HERO */

.hero {
  position: relative;
  color: #e8f0fa;
  background:
    radial-gradient(1100px 480px at 82% -12%, rgba(192, 143, 42, .30), transparent 62%),
    radial-gradient(800px 420px at 6% 108%, rgba(43, 127, 216, .34), transparent 60%),
    linear-gradient(152deg, #0a417f 0%, #062f5e 58%, #041f40 100%);
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 56px 56px;
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  padding: clamp(2.6rem, 5vw, 4.4rem) 0;
}
.hero h1 { color: #fff; margin-bottom: 1rem; }
.hero .hero-sub { font-size: clamp(1.05rem, 1.9vw, 1.3rem); color: var(--gold-400); font-weight: 600; margin-bottom: 1.2rem; }
.hero p { color: #c3d4e9; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }

.hero-badges { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1.5rem; }
.hero-badge {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .4rem .9rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, .09);
  border: 1px solid rgba(255, 255, 255, .18);
  font-size: .88rem;
  color: #dbe6f5;
}
.hero-badge i { color: var(--gold-400); }

.hero-art {
  background: rgba(255, 255, 255, .96);
  border-radius: var(--radius-lg);
  padding: 1.7rem;
  box-shadow: var(--shadow-lg);
  text-align: center;
}
.hero-art img { max-height: 260px; }
.hero-art .flow-caption {
  margin-top: 1.3rem;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .11em;
  text-transform: uppercase;
  color: var(--blue-800);
}

@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-art { order: -1; padding: 1.5rem; }
  .hero-art img { max-height: 190px; }
}

/* ----------------------------------------------------------------- CARDS */

.grid { display: grid; gap: 1.15rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }

.card-x {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}
.card-x:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--blue-100); }
.card-x h3 { font-size: 1.16rem; margin-bottom: .4rem; }
.card-x p { color: var(--ink-500); font-size: 1rem; margin-bottom: 0; }

.card-icon {
  width: 46px; height: 46px;
  border-radius: 14px;
  display: grid; place-items: center;
  font-size: 1.45rem;
  margin-bottom: .8rem;
  background: linear-gradient(135deg, var(--blue-100), var(--blue-050));
  color: var(--blue-700);
  flex: none;
}
.card-x:nth-child(3n+2) .card-icon { background: linear-gradient(135deg, var(--gold-100), #fdf8ec); color: var(--gold-600); }

.card-link { margin-top: auto; padding-top: 1rem; font-weight: 650; font-size: .93rem; }

/* Stat strip */
.stat-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stat-cell { background: var(--surface); padding: 1.2rem 1.15rem; }
.stat-cell i { font-size: 1.5rem; color: var(--gold-600); }
.stat-cell h4 { margin: .55rem 0 .25rem; font-size: 1.06rem; color: var(--ink-900); }
.stat-cell p { font-size: .95rem; color: var(--ink-500); margin: 0; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.15rem; counter-reset: step; }
.step {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2.1rem 1.25rem 1.3rem;
  box-shadow: var(--shadow-sm);
}
.step::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  position: absolute;
  top: -18px; left: 1.5rem;
  width: 44px; height: 44px;
  border-radius: 12px;
  display: grid; place-items: center;
  font-weight: 800; font-size: .95rem;
  color: #fff;
  background: linear-gradient(135deg, var(--blue-700), var(--blue-800));
  box-shadow: 0 6px 14px rgba(13, 82, 160, .3);
}
.step h3 { font-size: 1.13rem; margin-bottom: .35rem; }
.step p { color: var(--ink-500); font-size: 1rem; margin: 0; }

/* Flow chain */
.flow { display: flex; flex-wrap: wrap; justify-content: center; gap: .55rem; align-items: center; }
.flow-node {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .68rem 1.25rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  font-weight: 650;
  color: var(--blue-800);
}
.flow-node i { color: var(--gold-600); }
.flow-arrow { color: var(--ink-300); font-size: 1.15rem; }

/* Split */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.8rem, 3.6vw, 3rem); align-items: center; }
.split.reverse .split-media { order: -1; }
@media (max-width: 880px) {
  .split { grid-template-columns: 1fr; }
  .split.reverse .split-media { order: 0; }
}
.split-media .mini-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 460px) { .split-media .mini-grid { grid-template-columns: 1fr; } }

.mini-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold-500);
  border-radius: var(--radius-sm);
  padding: 1.15rem 1.2rem;
  box-shadow: var(--shadow-sm);
}
.mini-card h4 { font-size: .9rem; letter-spacing: .07em; text-transform: uppercase; color: var(--blue-800); margin-bottom: .3rem; }
.mini-card p { font-size: .96rem; color: var(--ink-500); margin: 0; }

.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .7rem; }
.check-list li { display: flex; gap: .7rem; align-items: flex-start; }
.check-list i { color: var(--ok); margin-top: .22rem; flex: none; }

/* CTA band */
.cta-band {
  background: linear-gradient(135deg, var(--blue-800), var(--blue-900) 55%, #04213f);
  color: #dbe6f5;
  border-radius: var(--radius-lg);
  padding: clamp(2.3rem, 5vw, 3.6rem);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-band::before {
  content: "";
  position: absolute; inset: auto -10% -60% auto;
  width: 460px; height: 460px; border-radius: 50%;
  background: radial-gradient(circle, rgba(192,143,42,.28), transparent 68%);
}
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { color: #fff; }
.cta-band p { color: #c3d4e9; max-width: 620px; margin-inline: auto; }
.cta-actions { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center; margin-top: 1.7rem; }

/* Accordion */
.acc-item { border: 1px solid var(--line); border-radius: var(--radius-sm); margin-bottom: .75rem; background: var(--surface); overflow: hidden; }
.acc-head {
  width: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.1rem 1.3rem;
  background: none; border: 0;
  font-weight: 650; font-size: 1rem; color: var(--ink-900);
  text-align: left; cursor: pointer;
}
.acc-head:hover { background: var(--blue-050); }
.acc-head i { color: var(--blue-700); transition: transform .2s ease; flex: none; }
.acc-item.open .acc-head i { transform: rotate(180deg); }
.acc-body { display: none; padding: 0 1.3rem 1.25rem; color: var(--ink-500); }
.acc-item.open .acc-body { display: block; }

/* Team */
.team-card { text-align: center; }
.team-avatar {
  width: 104px; height: 104px; border-radius: 50%;
  margin: 0 auto 1rem;
  display: grid; place-items: center;
  font-size: 2.1rem; font-weight: 800; color: #fff;
  background: linear-gradient(135deg, var(--blue-600), var(--blue-800));
  overflow: hidden;
}
.team-avatar img { width: 100%; height: 100%; object-fit: cover; }
.team-role { color: var(--gold-600); font-weight: 700; font-size: .87rem; letter-spacing: .05em; text-transform: uppercase; }

/* Plans */
.plan-card { position: relative; display: flex; flex-direction: column; }
.plan-card.popular { border-color: var(--gold-500); box-shadow: 0 12px 34px rgba(168, 121, 31, .18); }
.plan-flag {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
  color: #fff; font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  padding: .3rem .95rem; border-radius: 999px; white-space: nowrap;
}
.plan-price { font-size: 2.35rem; font-weight: 800; color: var(--blue-800); line-height: 1; }
.plan-strike { text-decoration: line-through; color: var(--ink-300); font-size: 1.05rem; font-weight: 600; margin-left: .5rem; }
.plan-period { color: var(--ink-500); font-size: .92rem; }

/* Testimonials */
.quote-card { border-left: 4px solid var(--gold-500); }
.quote-card .stars { color: var(--gold-500); letter-spacing: .1em; }

/* ------------------------------------------------------------ TEST CARDS */

.test-card { display: flex; flex-direction: column; }
.test-meta { display: flex; flex-wrap: wrap; gap: .45rem; margin-bottom: .85rem; }
.chip {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .26rem .7rem; border-radius: 999px;
  font-size: .76rem; font-weight: 700; letter-spacing: .02em;
  background: var(--blue-050); color: var(--blue-800); border: 1px solid var(--blue-100);
}
.chip-gold { background: var(--gold-100); color: var(--gold-700); border-color: #f0e0bb; }
.chip-ok { background: var(--ok-bg); color: var(--ok); border-color: #c9ecdd; }
.chip-bad { background: var(--bad-bg); color: var(--bad); border-color: #f6d2d4; }
.chip-warn { background: var(--warn-bg); color: var(--warn); border-color: #f2e2ba; }

.test-facts { display: flex; flex-wrap: wrap; gap: 1.1rem; margin: 1rem 0; padding-top: .95rem; border-top: 1px dashed var(--line); font-size: .92rem; color: var(--ink-500); }
.test-facts span { display: inline-flex; align-items: center; gap: .35rem; }
.test-facts i { color: var(--blue-600); }

/* --------------------------------------------------------- FORMS / PANELS */

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: clamp(1.4rem, 3vw, 2.2rem);
}
.panel-head { border-bottom: 1px solid var(--line); padding-bottom: .85rem; margin-bottom: 1.2rem; }
.panel-head h2, .panel-head h3 { margin-bottom: .25rem; }
.panel-head p { color: var(--ink-500); font-size: 1rem; margin: 0; }

.form-label { font-weight: 650; font-size: .94rem; color: var(--ink-900); margin-bottom: .35rem; }
.form-label .req { color: var(--bad); margin-left: .15rem; }
.form-control, .form-select {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: .68rem .9rem;
  font-size: .97rem;
  color: var(--ink-900);
  background-color: #fff;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.form-control:focus, .form-select:focus {
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px rgba(43, 127, 216, .16);
  outline: none;
}
.form-control::placeholder { color: var(--ink-300); }
.form-hint { font-size: .88rem; color: var(--ink-500); margin-top: .3rem; }
.text-danger, .field-validation-error { color: var(--bad); font-size: .85rem; }
.input-validation-error { border-color: var(--bad) !important; }
.validation-summary-errors {
  background: var(--bad-bg); border: 1px solid #f6d2d4; color: var(--bad);
  border-radius: var(--radius-sm); padding: .85rem 1.1rem; margin-bottom: 1.2rem; font-size: .92rem;
}
.validation-summary-errors ul { margin: 0; padding-left: 1.1rem; }
.validation-summary-valid { display: none; }

.alert-x {
  display: flex; gap: .7rem; align-items: flex-start;
  padding: .95rem 1.2rem; border-radius: var(--radius-sm);
  border: 1px solid transparent; margin-bottom: 1.4rem; font-size: .94rem;
}
.alert-ok { background: var(--ok-bg); border-color: #c9ecdd; color: #0b5f45; }
.alert-bad { background: var(--bad-bg); border-color: #f6d2d4; color: #8d1b22; }
.alert-info { background: var(--blue-050); border-color: var(--blue-100); color: var(--blue-800); }
.alert-warn { background: var(--warn-bg); border-color: #f2e2ba; color: #7a5404; }
.alert-x i { font-size: 1.1rem; margin-top: .1rem; flex: none; }

.auth-wrap { display: grid; grid-template-columns: .95fr 1.05fr; min-height: calc(100vh - 74px); }
.auth-aside {
  background: linear-gradient(160deg, var(--blue-800), var(--blue-900));
  color: #c3d4e9;
  padding: clamp(2.4rem, 5vw, 4rem);
  display: flex; flex-direction: column; justify-content: center;
}
.auth-aside h2 { color: #fff; }
.auth-main { padding: clamp(2rem, 5vw, 3.6rem) clamp(1.2rem, 5vw, 3.6rem); display: flex; align-items: center; }
.auth-card { width: 100%; max-width: 560px; margin-inline: auto; }

/* Declared after .auth-aside so it actually wins: on a narrow screen the sales
   panel would push the form below the fold, so the form gets the whole page. */
@media (max-width: 900px) {
  .auth-wrap { grid-template-columns: 1fr; min-height: 0; }
  .auth-aside { display: none; }
}

/* ------------------------------------------------------------- TEST TAKING */

.exam-bar {
  position: sticky; top: 0; z-index: 1040;
  background: var(--blue-900); color: #dbe6f5;
  padding: .75rem 0;
  box-shadow: 0 2px 12px rgba(6, 47, 94, .25);
}
.exam-bar-inner { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; }
.exam-title { font-weight: 700; color: #fff; font-size: 1rem; margin: 0; }
.timer {
  display: inline-flex; align-items: center; gap: .5rem;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.2);
  border-radius: 999px; padding: .4rem 1rem;
  font-variant-numeric: tabular-nums; font-weight: 800; font-size: 1.05rem; color: #fff;
}
.timer.warning { background: rgba(220, 170, 67, .2); border-color: var(--gold-400); color: var(--gold-400); }
.timer.danger { background: rgba(220, 80, 80, .22); border-color: #f08c8c; color: #ffc9c9; animation: pulse 1s infinite; }
@keyframes pulse { 50% { opacity: .55; } }

.exam-layout { display: grid; grid-template-columns: 1fr 280px; gap: 1.6rem; align-items: start; }
@media (max-width: 940px) { .exam-layout { grid-template-columns: 1fr; } .exam-side { order: -1; } }

.q-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; margin-bottom: 1.2rem; box-shadow: var(--shadow-sm); scroll-margin-top: 90px; }
.q-num { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 30px; padding: 0 .5rem; border-radius: 8px; background: var(--blue-100); color: var(--blue-800); font-weight: 800; font-size: .85rem; margin-right: .6rem; }
.q-text { font-size: 1.05rem; color: var(--ink-900); font-weight: 600; margin-bottom: 1.1rem; }

.opt {
  display: flex; gap: .8rem; align-items: flex-start;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: .85rem 1.05rem; margin-bottom: .6rem;
  cursor: pointer; transition: all .15s ease; background: var(--surface);
}
.opt:hover { border-color: var(--blue-500); background: var(--blue-050); }
.opt input { margin-top: .28rem; flex: none; accent-color: var(--blue-700); width: 17px; height: 17px; }
.opt.selected { border-color: var(--blue-600); background: var(--blue-050); box-shadow: inset 0 0 0 1px var(--blue-600); }
.opt-letter { font-weight: 800; color: var(--blue-700); flex: none; }
.opt.correct { border-color: var(--ok); background: var(--ok-bg); }
.opt.wrong { border-color: var(--bad); background: var(--bad-bg); }

.exam-side .panel { position: sticky; top: 88px; }
.palette { display: grid; grid-template-columns: repeat(auto-fill, minmax(42px, 1fr)); gap: .45rem; }
.palette a {
  display: grid; place-items: center;
  aspect-ratio: 1; border-radius: 9px;
  border: 1px solid var(--line); background: var(--surface);
  font-weight: 700; font-size: .87rem; color: var(--ink-700); text-decoration: none;
}
.palette a:hover { border-color: var(--blue-500); text-decoration: none; }
.palette a.answered { background: var(--ok); border-color: var(--ok); color: #fff; }
.palette-key { display: flex; flex-wrap: wrap; gap: .9rem; font-size: .82rem; color: var(--ink-500); margin-top: 1rem; }
.palette-key span { display: inline-flex; align-items: center; gap: .35rem; }
.key-dot { width: 12px; height: 12px; border-radius: 4px; border: 1px solid var(--line); display: inline-block; }
.key-dot.answered { background: var(--ok); border-color: var(--ok); }

/* Result */
.score-ring {
  width: 168px; height: 168px; border-radius: 50%;
  display: grid; place-items: center; margin: 0 auto 1.2rem;
  background: conic-gradient(var(--ring-color, var(--blue-700)) calc(var(--pct, 0) * 1%), var(--line) 0);
}
.score-ring-inner {
  width: 132px; height: 132px; border-radius: 50%; background: var(--surface);
  display: grid; place-items: center; text-align: center; line-height: 1.15;
}
.score-ring-inner strong { font-size: 2rem; color: var(--ink-900); display: block; }
.score-ring-inner small { color: var(--ink-500); font-size: .8rem; }

.metric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 1rem; }
.metric { text-align: center; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 1.05rem .8rem; background: var(--surface); }
.metric strong { display: block; font-size: 1.65rem; color: var(--ink-900); line-height: 1.1; }
.metric small { color: var(--ink-500); font-size: .82rem; }

/* --------------------------------------------------------------- TABLES */

.table-x { width: 100%; border-collapse: collapse; font-size: .97rem; }
.table-x th {
  text-align: left; padding: .8rem 1rem;
  background: var(--surface-2);
  color: var(--ink-500);
  font-size: .78rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.table-x td { padding: .85rem 1rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table-x tbody tr:hover { background: var(--blue-050); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }

.empty-state { text-align: center; padding: 2.2rem 1.3rem; color: var(--ink-500); }
.empty-state i { font-size: 2.6rem; color: var(--ink-300); display: block; margin-bottom: .9rem; }

/* ---------------------------------------------------------------- FOOTER */

.site-footer { background: var(--blue-900); color: #9fb6d2; padding-top: clamp(2.2rem, 3.6vw, 3rem); margin-top: 0; }
.site-footer h5 { color: #fff; font-size: .82rem; letter-spacing: .13em; text-transform: uppercase; margin-bottom: 1.1rem; font-weight: 800; }
.site-footer a { color: #9fb6d2; }
.site-footer a:hover { color: var(--gold-400); text-decoration: none; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1.3fr; gap: clamp(1.5rem, 3.2vw, 2.6rem); padding-bottom: 1.9rem; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-brand img { height: 62px; background: #fff; border-radius: 12px; padding: 7px 10px; }
.footer-links { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; font-size: .97rem; }
.footer-contact { list-style: none; padding: 0; margin: 0; display: grid; gap: .75rem; font-size: .97rem; }
.footer-contact li { display: flex; gap: .65rem; align-items: flex-start; }
.footer-contact i { color: var(--gold-400); margin-top: .2rem; flex: none; }
.social-row { display: flex; gap: .55rem; margin-top: 1.2rem; }
.social-row a {
  width: 38px; height: 38px; border-radius: 10px;
  display: grid; place-items: center;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14);
  color: #dbe6f5; font-size: 1rem;
}
.social-row a:hover { background: var(--gold-500); border-color: var(--gold-500); color: #fff; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.11);
  padding: 1.2rem 0;
  display: flex; flex-wrap: wrap; gap: .8rem; justify-content: space-between;
  font-size: .86rem;
}

.wa-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 1050;
  width: 54px; height: 54px; border-radius: 50%;
  display: grid; place-items: center;
  background: #25d366; color: #fff; font-size: 1.6rem;
  box-shadow: 0 6px 20px rgba(37, 211, 102, .42);
}
.wa-float:hover { color: #fff; transform: scale(1.06); }

/* ----------------------------------------------------------------- ADMIN */

.admin-shell { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
@media (max-width: 900px) { .admin-shell { grid-template-columns: 1fr; } .admin-side { position: static !important; height: auto !important; } }

.admin-side {
  background: var(--blue-900); color: #9fb6d2;
  padding: 1.2rem 0;
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.admin-brand { display: flex; align-items: center; gap: .6rem; padding: 0 1.2rem 1.1rem; border-bottom: 1px solid rgba(255,255,255,.1); margin-bottom: 1rem; }
.admin-brand img { height: 38px; background: #fff; border-radius: 8px; padding: 4px 6px; }
.admin-brand span { color: #fff; font-weight: 800; font-size: .95rem; line-height: 1.2; }
.admin-nav { display: grid; gap: .12rem; padding: 0 .7rem; }
.admin-nav-label { font-size: .68rem; letter-spacing: .13em; text-transform: uppercase; color: #6b86a8; padding: 1rem .6rem .35rem; font-weight: 800; }
.admin-nav a {
  display: flex; align-items: center; gap: .65rem;
  padding: .58rem .7rem; border-radius: 9px;
  color: #c3d4e9; font-size: .92rem; font-weight: 550; text-decoration: none;
}
.admin-nav a:hover { background: rgba(255,255,255,.08); color: #fff; text-decoration: none; }
.admin-nav a.active { background: var(--blue-700); color: #fff; }
.admin-nav i { width: 18px; text-align: center; flex: none; }

.admin-main { background: var(--surface-2); min-width: 0; }
.admin-topbar {
  background: var(--surface); border-bottom: 1px solid var(--line);
  padding: .9rem clamp(1rem, 3vw, 2rem);
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between;
  position: sticky; top: 0; z-index: 20;
}
.admin-topbar h1 { font-size: 1.28rem; margin: 0; }
.admin-body { padding: clamp(1.1rem, 3vw, 2rem); }

.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(175px, 1fr)); gap: 1.1rem; }
.kpi {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.3rem; box-shadow: var(--shadow-sm);
  display: flex; gap: 1rem; align-items: center;
}
.kpi-icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 1.25rem; background: var(--blue-100); color: var(--blue-700); flex: none; }
.kpi strong { display: block; font-size: 1.75rem; line-height: 1.1; color: var(--ink-900); }
.kpi small { color: var(--ink-500); font-size: .83rem; }

.toolbar { display: flex; flex-wrap: wrap; gap: .7rem; align-items: center; justify-content: space-between; margin-bottom: 1.3rem; }
.toolbar-group { display: flex; flex-wrap: wrap; gap: .55rem; align-items: center; }

.badge-x { display: inline-flex; align-items: center; gap: .3rem; padding: .2rem .6rem; border-radius: 6px; font-size: .76rem; font-weight: 700; }
.badge-on { background: var(--ok-bg); color: var(--ok); }
.badge-off { background: #eef1f6; color: var(--ink-500); }

.row-actions { display: flex; gap: .35rem; flex-wrap: wrap; }
.icon-btn {
  width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line);
  background: var(--surface); color: var(--ink-700);
  display: inline-grid; place-items: center; cursor: pointer; font-size: .92rem; text-decoration: none;
}
.icon-btn:hover { background: var(--blue-050); border-color: var(--blue-500); color: var(--blue-700); text-decoration: none; }
.icon-btn.danger:hover { background: var(--bad-bg); border-color: var(--bad); color: var(--bad); }

.mb-x { margin-bottom: 1.2rem; }
.mt-x { margin-top: 1.2rem; }

@media print {
  .site-header, .site-footer, .topbar, .wa-float, .no-print, .exam-side { display: none !important; }
  body { background: #fff; }
}

/* ===================================================================
   MOTION
   One rule governs everything below: motion is decorative, never the
   only way something is conveyed, and it is all switched off for a
   visitor who has asked for reduced motion (the block at the very end
   of this file). Every animation here is transform/opacity only, so it
   runs on the compositor and costs no layout work.
   =================================================================== */

/* Sections rise into place once, as they are scrolled to. The class is
   added by site.js; without JavaScript the element simply stays visible,
   which is why the hidden state is applied by .js-reveal and not here. */
.js-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
}
.js-reveal [data-reveal].is-revealed {
  opacity: 1;
  transform: none;
  transition: opacity .55s ease, transform .55s cubic-bezier(.22, .7, .3, 1);
  transition-delay: var(--reveal-delay, 0ms);
}

@keyframes drift-y { 50% { transform: translateY(-16px); } }
@keyframes drift-tilt { 50% { transform: translateY(-12px) rotate(7deg); } }
@keyframes spin-slow { to { transform: rotate(360deg); } }
@keyframes trace {
  0%   { stroke-dashoffset: 300; opacity: 0; }
  12%  { opacity: 1; }
  70%  { stroke-dashoffset: 0;   opacity: 1; }
  100% { stroke-dashoffset: 0;   opacity: 0; }
}
@keyframes ring-pulse {
  0%   { transform: scale(.75); opacity: .55; }
  70%  { transform: scale(1.5); opacity: 0; }
  100% { transform: scale(1.5); opacity: 0; }
}

/* -------------------------------------------------------- HERO MOTIFS */

.hero-motifs {
  position: absolute; inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.hero-motifs .motif { position: absolute; display: block; color: #fff; }
.hero-motifs .motif svg { width: 100%; height: 100%; display: block; }

.motif-atom {
  width: 190px; height: 190px;
  top: 8%; right: 30%;
  opacity: .1;
  animation: spin-slow 46s linear infinite;
}
.motif-dna {
  width: 74px; height: 148px;
  bottom: 6%; left: 4%;
  opacity: .13;
  color: var(--gold-400);
  animation: drift-y 9s ease-in-out infinite;
}
.motif-flask {
  width: 96px; height: 96px;
  top: 14%; left: 46%;
  opacity: .09;
  animation: drift-tilt 12s ease-in-out infinite;
}
@media (max-width: 900px) {
  /* The art panel moves above the copy on a phone; the motifs would sit
     behind it and only add weight, so they come out entirely. */
  .hero-motifs { display: none; }
}

/* ------------------------------------------------------- NEET / JEE PILLS */

.exam-pills {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: .6rem;
  margin-bottom: 1.1rem;
}
.exam-pill {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .5rem 1.05rem .5rem .85rem;
  border-radius: 999px;
  border: 1px solid transparent;
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.exam-pill:hover { text-decoration: none; transform: translateY(-2px); }
.exam-pill i { font-size: 1.25rem; }
.exam-pill span { display: flex; flex-direction: column; line-height: 1.05; text-align: left; }
.exam-pill strong { font-size: 1.22rem; font-weight: 800; letter-spacing: .04em; }
.exam-pill small { font-size: .68rem; letter-spacing: .15em; text-transform: uppercase; font-weight: 700; opacity: .82; }

.exam-pill-neet {
  background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
  color: #fff;
  box-shadow: 0 6px 18px rgba(168, 121, 31, .38);
}
.exam-pill-neet:hover { color: #fff; box-shadow: 0 10px 26px rgba(168, 121, 31, .5); }

.exam-pill-jee {
  background: rgba(255, 255, 255, .1);
  border-color: rgba(255, 255, 255, .34);
  color: #fff;
}
.exam-pill-jee:hover { color: var(--blue-900); background: #fff; box-shadow: 0 10px 26px rgba(6, 47, 94, .34); }

.exam-pill-join { color: #8fa8c6; font-weight: 700; font-size: 1.05rem; }

/* ------------------------------------------------------ EXAM FOCUS BAND */

.exam-focus { background: var(--surface-2); border-block: 1px solid var(--line); }
.exam-focus-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.15rem; }
@media (max-width: 820px) { .exam-focus-grid { grid-template-columns: 1fr; } }

.exam-panel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.5rem;
  color: #fff;
  isolation: isolate;
  transition: transform .2s ease, box-shadow .2s ease;
}
.exam-panel:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.exam-panel-neet { background: linear-gradient(145deg, #0a417f, #062f5e 70%); }
.exam-panel-jee  { background: linear-gradient(145deg, #8a6216, #5e410c 72%); }

.exam-panel-top { display: flex; align-items: center; gap: .85rem; margin-bottom: .7rem; }
.exam-panel-top h3 { color: #fff; margin: 0; font-size: 1.75rem; letter-spacing: .05em; font-weight: 800; }
.exam-panel-icon {
  width: 48px; height: 48px; flex: none;
  border-radius: 14px;
  display: grid; place-items: center;
  font-size: 1.4rem;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .22);
}
.exam-panel p { color: #cfdcec; font-size: 1rem; margin-bottom: .95rem; }
.exam-panel-jee p { color: #ecdec0; }

.exam-panel-link {
  display: inline-flex; align-items: center; gap: .4rem;
  color: #fff; font-weight: 700; font-size: .95rem;
  border-bottom: 2px solid rgba(255, 255, 255, .35);
  padding-bottom: .15rem;
}
.exam-panel-link:hover { color: #fff; text-decoration: none; border-bottom-color: #fff; }
.exam-panel-link i { transition: transform .18s ease; }
.exam-panel-link:hover i { transform: translateX(4px); }

/* The quiet pulse in the corner - a pulse-oximeter ring on the medical
   panel, and the same shape reading as a signal on the engineering one. */
.exam-panel-pulse {
  position: absolute; top: -46px; right: -46px;
  width: 170px; height: 170px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .3);
  z-index: -1;
  animation: ring-pulse 4.5s ease-out infinite;
}
.exam-panel-jee .exam-panel-pulse { animation-delay: 1.6s; }

/* ------------------------------------------------------- FEATURE MOSAIC */

.mosaic {
  display: grid;
  grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr);
  gap: clamp(1.8rem, 4vw, 3.4rem);
  align-items: start;
}
@media (max-width: 940px) { .mosaic { grid-template-columns: 1fr; gap: 1.6rem; } }

.mosaic-aside-inner { position: sticky; top: 92px; }
@media (max-width: 940px) { .mosaic-aside-inner { position: static; } }
.mosaic-aside h2 { margin-bottom: .55rem; }
.mosaic-aside .lead { margin-bottom: .9rem; }

.mosaic-ecg { color: var(--blue-600); opacity: .8; margin: 1.2rem 0 .2rem; }
.mosaic-ecg svg { width: 100%; height: 40px; display: block; }
.mosaic-ecg path {
  stroke-dasharray: 300;
  animation: trace 4.5s ease-in-out infinite;
}

.mosaic-list {
  list-style: none;
  margin: 0; padding: 0;
  display: grid;
  gap: .55rem;
}
.mosaic-item {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: start;
  gap: .9rem;
  padding: .95rem 1.1rem;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid transparent;
  position: relative;
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}
/* The accent rail that grows on hover, instead of a card lifting off the page. */
.mosaic-item::before {
  content: "";
  position: absolute; left: 0; top: 14%;
  width: 3px; height: 0;
  border-radius: 0 3px 3px 0;
  background: linear-gradient(180deg, var(--blue-600), var(--gold-500));
  transition: height .25s ease;
}
.mosaic-item:hover {
  background: var(--surface);
  border-color: var(--line);
  transform: translateX(4px);
  box-shadow: var(--shadow-sm);
}
.mosaic-item:hover::before { height: 72%; }
.section-alt .mosaic-item { background: transparent; }
.section-alt .mosaic-item:hover { background: var(--surface); }

.mosaic-index {
  font-size: 1.5rem; font-weight: 800; line-height: 1;
  color: var(--blue-100);
  font-variant-numeric: tabular-nums;
  padding-top: .1rem;
  transition: color .2s ease;
}
.mosaic-item:hover .mosaic-index { color: var(--gold-400); }

.mosaic-icon {
  width: 38px; height: 38px; flex: none;
  border-radius: 11px;
  display: grid; place-items: center;
  font-size: 1.1rem;
  background: var(--blue-050);
  color: var(--blue-700);
  transition: background .2s ease, color .2s ease;
}
.mosaic-item:hover .mosaic-icon { background: var(--blue-700); color: #fff; }

.mosaic-body { display: block; min-width: 0; }
.mosaic-body strong { display: block; color: var(--ink-900); font-size: 1.06rem; margin-bottom: .15rem; }
.mosaic-body > span { color: var(--ink-500); font-size: .98rem; }

@media (max-width: 520px) {
  .mosaic-item { grid-template-columns: auto 1fr; gap: .7rem; padding: .85rem .9rem; }
  .mosaic-index { display: none; }
}

/* ---------------------------------------------------------------- TEAM */

.team-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 1.15rem; }

.team-profile {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.team-profile:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--blue-100);
}

.team-photo {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: linear-gradient(150deg, var(--blue-700), var(--blue-900));
  display: grid; place-items: center;
}
.team-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.team-profile:hover .team-photo img { transform: scale(1.07); }

.team-monogram {
  font-size: 3rem; font-weight: 800; letter-spacing: .04em;
  color: rgba(255, 255, 255, .92);
}

/* The wash that comes up over the photo on hover and carries the bio with it. */
.team-photo-veil {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(6, 47, 94, 0) 28%, rgba(6, 47, 94, .93) 100%);
  opacity: 0;
  transition: opacity .28s ease;
}
.team-profile:hover .team-photo-veil { opacity: 1; }

.team-bio {
  position: absolute;
  left: 1rem; right: 1rem; bottom: .9rem;
  margin: 0;
  color: #e8f0fa;
  font-size: .9rem;
  line-height: 1.45;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .28s ease, transform .28s ease;
}
.team-profile:hover .team-bio { opacity: 1; transform: none; }

.team-meta { padding: .95rem 1.05rem 1.1rem; text-align: center; }
.team-meta h3 { font-size: 1.1rem; margin-bottom: .2rem; }
.team-role {
  color: var(--gold-600); font-weight: 700;
  font-size: .84rem; letter-spacing: .06em; text-transform: uppercase;
}
.team-qual {
  margin-top: .35rem;
  font-size: .89rem; color: var(--ink-500);
  display: inline-flex; align-items: center; gap: .3rem;
}
.team-qual i { color: var(--blue-600); }

/* A finger tap has no hover, so on a touch screen the bio is simply shown. */
@media (hover: none) {
  .team-photo-veil { opacity: 1; }
  .team-bio { opacity: 1; transform: none; }
}

/* --------------------------------------------------------- FILTER NOTE */

.filter-note {
  display: flex; flex-wrap: wrap; gap: .8rem;
  align-items: center; justify-content: space-between;
  padding: .75rem 1.1rem;
  border: 1px solid var(--blue-100);
  background: var(--blue-050);
  border-radius: var(--radius-sm);
  color: var(--blue-800);
  font-size: .95rem;
}
.filter-note i { color: var(--blue-600); }


/* ===================================================================
   LOGO LOADER
   Shown on every page load. The hide is driven by the CSS animation
   below, not by JavaScript: whatever happens to the script, the
   overlay is gone by ~1.5s. site.js adds .is-done to cut that short
   once the page has genuinely finished loading.
   =================================================================== */

.page-loader {
  position: fixed;
  inset: 0;
  z-index: 3000;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 1.1rem;
  background: linear-gradient(160deg, #ffffff 0%, var(--blue-050) 100%);
  animation: loader-out .45s ease 1.15s forwards;
}
/* Once the page has loaded the overlay is on its way out, so it must stop
   swallowing clicks immediately rather than at the end of the fade. The three
   inner animations are infinite, so they are stopped here too: left running
   behind a hidden overlay they would keep the compositor busy for the whole
   life of the page. site.js also removes the element once it has faded. */
.page-loader.is-done { animation-delay: 0s; animation-duration: .35s; pointer-events: none; }
.page-loader.is-done .page-loader-ring,
.page-loader.is-done .page-loader-logo,
.page-loader.is-done .page-loader-bar i { animation: none; }

@keyframes loader-out {
  to { opacity: 0; visibility: hidden; }
}

/* The logo is a wide wordmark, not a square mark, so the ring is sized around
   it as a halo rather than cropping it into a small circle. */
.page-loader-inner {
  position: relative;
  width: 230px; height: 230px;
  display: grid; place-items: center;
}
.page-loader-logo {
  width: 168px;
  height: auto;
  max-height: 132px;
  object-fit: contain;
  animation: loader-breathe 1.8s ease-in-out infinite;
}
.page-loader-ring {
  position: absolute; inset: 0;
  border-radius: 50%;
  border: 3px solid var(--blue-100);
  border-top-color: var(--gold-500);
  border-right-color: var(--blue-600);
  animation: loader-spin 1.1s linear infinite;
}
@keyframes loader-spin { to { transform: rotate(360deg); } }
@keyframes loader-breathe { 50% { transform: scale(1.05); } }

@media (max-width: 420px) {
  .page-loader-inner { width: 190px; height: 190px; }
  .page-loader-logo { width: 136px; max-height: 106px; }
}

.page-loader-bar {
  display: block;
  width: 150px; height: 3px;
  border-radius: 3px;
  background: var(--blue-100);
  overflow: hidden;
}
.page-loader-bar i {
  display: block;
  width: 42%; height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--blue-600), var(--gold-500));
  animation: loader-slide 1.05s ease-in-out infinite;
}
@keyframes loader-slide {
  0%   { transform: translateX(-105%); }
  100% { transform: translateX(250%); }
}

/* Printing a page should never print the overlay. */
@media print { .page-loader { display: none !important; } }

/* ===================================================================
   TEXT CAPTCHA
   =================================================================== */

.captcha-box {
  border: 1px solid var(--blue-100);
  background: var(--blue-050);
  border-radius: var(--radius-sm);
  padding: .9rem 1rem 1rem;
}
.captcha-q {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .55rem;
  margin-bottom: .7rem;
  font-size: 1.08rem;
  font-weight: 700;
  color: var(--blue-900);
  line-height: 1.4;
}
.captcha-q > i { color: var(--blue-600); font-size: 1.15rem; flex: none; }
.captcha-q > span { flex: 1 1 auto; min-width: 0; }

.captcha-new {
  flex: none;
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .3rem .7rem;
  border: 1px solid var(--blue-100);
  background: var(--surface);
  border-radius: 999px;
  color: var(--blue-700);
  font-size: .8rem; font-weight: 650;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.captcha-new:hover { background: var(--blue-700); border-color: var(--blue-700); color: #fff; }
.captcha-new:disabled { opacity: .55; cursor: default; }
.captcha-new i { transition: transform .3s ease; }
.captcha-new:hover i { transform: rotate(120deg); }

.captcha-input { background: var(--surface); font-weight: 650; }

@media (max-width: 460px) {
  .captcha-q { font-size: 1.02rem; }
  .captcha-new span { display: none; }
}

/* ===================================================================
   REGISTRATION SUCCESS
   =================================================================== */

.reg-success {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 1.5rem 1.2rem 1.35rem;
  border-radius: var(--radius);
  border: 1px solid #c9ecdd;
  background: linear-gradient(165deg, #f2fbf7 0%, var(--ok-bg) 100%);
}
.reg-success h3 { color: #0b5f45; margin-bottom: .3rem; font-size: 1.3rem; }
.reg-success p { color: #2c6a58; font-size: .97rem; margin-bottom: .3rem; }

.reg-success-name {
  font-weight: 700 !important;
  color: #0b5f45 !important;
  font-size: 1.05rem !important;
}
/* The label sits on its own line so the address below it gets the full width
   and is never broken across lines mid-address. */
.reg-success-user {
  display: block;
  margin-top: .8rem !important;
  padding: .55rem .9rem;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid #c9ecdd;
  color: var(--ink-700) !important;
  text-align: center;
}
.reg-success-user-label {
  display: block;
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-500);
  margin-bottom: .15rem;
}
.reg-success-user-label i { color: var(--ok); }
.reg-success-user strong {
  display: block;
  font-size: .95rem;
  color: var(--ink-900);
  overflow-wrap: break-word;
}

.reg-success-tick {
  display: block;
  width: 58px; height: 58px;
  margin: 0 auto .7rem;
  color: var(--ok);
  position: relative; z-index: 1;
}
.reg-success-tick svg { width: 100%; height: 100%; display: block; }
/* Both strokes draw themselves once, then simply stay drawn. */
.reg-success-tick circle {
  stroke-dasharray: 152;
  stroke-dashoffset: 152;
  animation: tick-draw .5s ease-out forwards;
}
.reg-success-tick path {
  stroke-dasharray: 40;
  stroke-dashoffset: 40;
  animation: tick-draw .35s ease-out .45s forwards;
}
@keyframes tick-draw { to { stroke-dashoffset: 0; } }

/* A single soft ring that expands out from behind the tick on arrival. */
.reg-success-burst {
  position: absolute;
  top: 2.1rem; left: 50%;
  width: 58px; height: 58px;
  margin-left: -29px;
  border-radius: 50%;
  border: 2px solid var(--ok);
  opacity: .5;
  animation: burst-out 1.1s ease-out .35s forwards;
}
@keyframes burst-out {
  to { transform: scale(3.6); opacity: 0; }
}

/* ===================================================================
   ADMIN: TEAM PHOTO PICKER
   =================================================================== */

.photo-picker {
  display: grid;
  grid-template-columns: 132px 1fr;
  gap: 1.1rem;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 1rem;
  background: var(--surface-2);
}
@media (max-width: 600px) { .photo-picker { grid-template-columns: 1fr; } }

.photo-picker-current {
  width: 132px; height: 132px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface);
}
.photo-picker-grid { display: flex; flex-wrap: wrap; gap: .5rem; }

.photo-chip {
  width: 60px; height: 60px;
  padding: 0;
  border: 2px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  cursor: pointer;
  overflow: hidden;
  transition: border-color .15s ease, transform .15s ease;
}
.photo-chip img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-chip:hover { border-color: var(--blue-500); transform: translateY(-2px); }
.photo-chip.selected { border-color: var(--blue-700); box-shadow: 0 0 0 3px var(--blue-100); }

#photoPathLabel code {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: .1rem .35rem;
  color: var(--ink-700);
  overflow-wrap: anywhere;
}
/* ===================================================================
   REDUCED MOTION
   Last in the file so it wins. Everything above degrades to its final
   resting state: nothing moves, nothing is hidden.
   =================================================================== */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }

  .js-reveal [data-reveal] { opacity: 1; transform: none; }
  .mosaic-ecg path { stroke-dasharray: none; }
}
