/* =========================================================
   TaleemIQ marketing site — design tokens
   ========================================================= */
:root {
  --paper: #f5f1e4;
  --paper-raised: #fbf8ef;
  --ink: #17231d;
  --ink-soft: #2c3a32;
  --emerald: #0f5c46;
  --emerald-deep: #0a3f32;
  --emerald-tint: #e3ece7;
  --gold: #b8892b;
  --gold-soft: #d9ac4f;
  --sage: #5f6f65;
  --rule: rgba(23, 35, 29, 0.14);
  --shadow: rgba(23, 35, 29, 0.10);

  --font-display: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
  --font-body: -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Cascadia Code", "SF Mono", "Consolas", "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #10180f;
    --paper-raised: #16211a;
    --ink: #ede7d6;
    --ink-soft: #c7cdc4;
    --emerald: #4fa886;
    --emerald-deep: #2f7a5f;
    --emerald-tint: #1a2b23;
    --gold: #d9ac4f;
    --gold-soft: #e8c579;
    --sage: #93a099;
    --rule: rgba(237, 231, 214, 0.16);
    --shadow: rgba(0, 0, 0, 0.35);
  }
}
:root[data-theme="dark"] {
  --paper: #10180f;
  --paper-raised: #16211a;
  --ink: #ede7d6;
  --ink-soft: #c7cdc4;
  --emerald: #4fa886;
  --emerald-deep: #2f7a5f;
  --emerald-tint: #1a2b23;
  --gold: #d9ac4f;
  --gold-soft: #e8c579;
  --sage: #93a099;
  --rule: rgba(237, 231, 214, 0.16);
  --shadow: rgba(0, 0, 0, 0.35);
}
:root[data-theme="light"] {
  --paper: #f5f1e4;
  --paper-raised: #fbf8ef;
  --ink: #17231d;
  --ink-soft: #2c3a32;
  --emerald: #0f5c46;
  --emerald-deep: #0a3f32;
  --emerald-tint: #e3ece7;
  --gold: #b8892b;
  --gold-soft: #d9ac4f;
  --sage: #5f6f65;
  --rule: rgba(23, 35, 29, 0.14);
  --shadow: rgba(23, 35, 29, 0.10);
}

/* =========================================================
   Base
   ========================================================= */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
}

a { color: inherit; }
p { margin: 0; }
.tabular { font-variant-numeric: tabular-nums; }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--emerald); color: var(--paper-raised);
  padding: 0.6em 1em; z-index: 100;
}
.skip-link:focus { left: 1em; top: 1em; }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

.wrap { max-width: 1320px; margin: 0 auto; padding: 0 clamp(1.5rem, 4vw, 4rem); }

.eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  color: var(--emerald);
  font-weight: 600;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  text-wrap: balance;
  margin: 0;
  color: var(--ink);
}

/* =========================================================
   Nav
   ========================================================= */
header.site {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--rule);
}
.nav-row { display: flex; align-items: center; justify-content: space-between; padding: 1.1rem 0; gap: 1.5rem; }
.wordmark {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  display: flex; align-items: baseline; gap: 0.4rem;
}
.wordmark .dot { color: var(--gold); }
nav.links { display: flex; align-items: center; gap: 1.6rem; font-size: 0.92rem; }
nav.links a.textlink {
  text-decoration: none;
  position: relative;
  padding-bottom: 2px;
  background-image: linear-gradient(var(--emerald), var(--emerald));
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 0% 1.5px;
  transition: background-size 0.25s ease;
}
nav.links a.textlink:hover, nav.links a.textlink:focus-visible { background-size: 100% 1.5px; }
@media (max-width: 720px) { nav.links .hide-narrow { display: none; } }

.btn {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none;
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.65rem 1.15rem;
  border-radius: 3px;
  border: 1px solid var(--emerald-deep);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-primary { background: var(--emerald); color: var(--paper-raised); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 16px var(--shadow); }
.btn-ghost { background: transparent; border-color: var(--rule); color: var(--ink); }
.btn-ghost:hover { border-color: var(--emerald); }
.btn-contrast { background: var(--gold); border-color: var(--gold); color: #17231d; }
.btn-contrast:hover { background: var(--gold-soft); border-color: var(--gold-soft); transform: translateY(-1px); box-shadow: 0 6px 16px var(--shadow); }

/* =========================================================
   Hero
   ========================================================= */
.hero {
  padding: 4.5rem 0 4rem;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 3rem;
  align-items: center;
}
@media (max-width: 880px) { .hero { grid-template-columns: 1fr; padding: 3rem 0 2.5rem; } }

.hero h1 { font-size: clamp(2.1rem, 4.2vw, 3.4rem); line-height: 1.12; margin-top: 0.9rem; }
.hero h1 em { font-style: italic; color: var(--emerald); }
.hero .definition { margin-top: 1.2rem; max-width: 46ch; font-size: 1.05rem; font-weight: 600; color: var(--ink); }
.hero .lede { margin-top: 0.9rem; max-width: 46ch; font-size: 1.02rem; color: var(--ink-soft); }
.hero .cta-row { margin-top: 2rem; display: flex; gap: 1rem; flex-wrap: wrap; }

.register-card {
  background: var(--paper-raised);
  border: 1px solid var(--rule);
  border-radius: 4px;
  box-shadow: 0 18px 40px var(--shadow);
  overflow: hidden;
}
.register-card .card-head {
  background: var(--emerald-deep);
  color: var(--paper-raised);
  padding: 0.9rem 1.2rem;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: flex; justify-content: space-between;
}
.register-card table { width: 100%; border-collapse: collapse; font-family: var(--font-mono); font-size: 0.86rem; }
.register-card th {
  text-align: left; font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--sage); padding: 0.7rem 1.2rem 0.4rem; font-weight: 600;
}
.register-card td { padding: 0.55rem 1.2rem; border-top: 1px solid var(--rule); }
.register-card .status-in { color: var(--emerald); }
.register-card .status-out { color: var(--sage); }
.register-card .status-late { color: var(--gold); }
.register-card .foot {
  padding: 0.8rem 1.2rem 1rem; font-size: 0.74rem; color: var(--sage);
  border-top: 1px solid var(--rule); font-family: var(--font-mono);
}

/* Screenshot placeholders */
.screens-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.6rem; }
@media (max-width: 880px) { .screens-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .screens-grid { grid-template-columns: 1fr; } }
.screen-card { margin: 0; border: 1px solid var(--rule); border-radius: 4px; overflow: hidden; background: var(--paper-raised); }
.screen-card .chrome { display: flex; gap: 0.35rem; padding: 0.55rem 0.7rem; border-bottom: 1px solid var(--rule); }
.screen-card .chrome span { width: 7px; height: 7px; border-radius: 50%; background: var(--rule); }
.screen-placeholder {
  aspect-ratio: 4 / 3;
  display: flex; align-items: center; justify-content: center;
  background-image: repeating-linear-gradient(135deg, transparent 0 10px, var(--rule) 10px 11px);
  color: var(--sage);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.screen-card figcaption { padding: 0.9rem 1.1rem 1.1rem; }
.screen-card figcaption h3 { font-size: 0.98rem; }
.screen-card figcaption p { margin-top: 0.3rem; font-size: 0.86rem; color: var(--ink-soft); }

/* Roster sub-features */
.roster-sub {
  list-style: none;
  margin: 0.7rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}
.roster-sub li {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--sage);
}
.roster-sub li::before { content: "· "; color: var(--gold); }

/* How it works */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem; }
@media (max-width: 880px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }
.step { border-top: 3px solid var(--emerald); padding-top: 1.1rem; }
.step .no { display: block; font-family: var(--font-mono); color: var(--gold); font-size: 1.05rem; margin-bottom: 0.4rem; }
.step h3 { font-size: 1.02rem; }
.step p { margin-top: 0.5rem; font-size: 0.92rem; color: var(--ink-soft); }

/* Why TaleemIQ comparison table */
.compare-wrap { overflow-x: auto; }
.compare-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 0.92rem;
}
.compare-table th, .compare-table td { padding: 0.85rem 1rem; text-align: left; border-bottom: 1px solid var(--rule); }
.compare-table thead th {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--sage);
  font-weight: 600;
  border-bottom: 2px solid var(--rule);
}
.compare-table tbody th {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}
.compare-table tbody td:last-child { color: var(--emerald); font-weight: 600; }
.compare-table tbody td { color: var(--ink-soft); }

/* Security detail list */
.security-detail { margin-top: 2rem; padding-top: 2rem; border-top: 1px solid var(--rule); }
.security-detail h3 { font-size: 1.05rem; }
.security-detail ul { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.8rem 2rem; }
@media (max-width: 640px) { .security-detail ul { grid-template-columns: 1fr; } }
.security-detail li {
  padding-left: 1.2rem;
  position: relative;
  font-size: 0.94rem;
  color: var(--ink-soft);
}
.security-detail li::before { content: "—"; position: absolute; left: 0; color: var(--gold); }

/* FAQ */
.faq-list { max-width: 72ch; }
.faq-item { border-bottom: 1px solid var(--rule); padding: 1.1rem 0; }
.faq-item summary {
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-family: var(--font-mono);
  color: var(--gold);
  font-size: 1.2rem;
  flex: none;
}
.faq-item[open] summary::after { content: "−"; }
.faq-item p { margin-top: 0.8rem; max-width: 62ch; color: var(--ink-soft); font-size: 0.96rem; }

/* =========================================================
   Section scaffolding
   ========================================================= */
section { padding: 4rem 0; border-top: 1px solid var(--rule); }
section.no-rule { border-top: none; }
.section-head { max-width: 60ch; margin-bottom: 2.4rem; }
.section-head h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); margin-top: 0.6rem; }
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }

/* Statement */
.statement { padding: 3rem 0 4rem; }
.statement .rule { width: 42px; height: 3px; background: var(--gold); margin-bottom: 1.4rem; }
.statement p {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.15rem);
  line-height: 1.35;
  max-width: 22ch;
  text-wrap: balance;
}
.statement p .not { color: var(--sage); }
.statement p .yes { color: var(--emerald); font-style: italic; }

/* Manifesto pull-quote */
.manifesto { max-width: 66ch; }
.manifesto blockquote {
  margin: 0;
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.3rem, 2.6vw, 1.75rem);
  line-height: 1.5;
  color: var(--ink);
  border-left: 3px solid var(--gold);
  padding-left: 1.3rem;
}
.manifesto cite {
  display: block; margin-top: 1.1rem; font-style: normal; font-family: var(--font-mono);
  font-size: 0.76rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--sage);
}

/* Ecosystem diagram */
.ecosystem { display: flex; flex-direction: column; align-items: center; }
.eco-node {
  background: var(--paper-raised);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 1.1rem 1.4rem;
  text-align: center;
}
.eco-node h3 { font-size: 1rem; }
.eco-node p { margin-top: 0.35rem; font-size: 0.86rem; color: var(--ink-soft); }
.eco-cloud {
  background: var(--emerald-deep);
  border-color: var(--emerald-deep);
  color: var(--paper-raised);
  padding: 1rem 2.2rem;
}
.eco-cloud .eyebrow { color: var(--gold-soft); }
.eco-cloud h3 { color: var(--paper-raised); font-size: 1.15rem; }
.eco-branch {
  position: relative;
  margin-top: 2.25rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  width: 100%;
  max-width: 760px;
}
.eco-branch::before {
  content: "";
  position: absolute;
  top: -2rem; left: 50%;
  width: 1px; height: 2rem;
  background: var(--rule);
}
.eco-branch .eco-node { position: relative; }
.eco-branch .eco-node::before {
  content: "";
  position: absolute;
  top: -2rem; left: 50%;
  width: 1px; height: 2rem;
  background: var(--rule);
}
@media (max-width: 720px) {
  .eco-branch { grid-template-columns: 1fr; max-width: 360px; }
  .eco-branch .eco-node::before { display: none; }
}

/* Hardware-agnostic grid */
.hw-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
@media (max-width: 720px) { .hw-grid { grid-template-columns: 1fr; } }
.hw-item {
  border-top: 2px solid var(--gold);
  padding-top: 1rem;
}
.hw-item h3 { font-size: 1.02rem; }
.hw-item p { margin-top: 0.5rem; font-size: 0.92rem; color: var(--ink-soft); }

/* The Register (modules) */
.roster { border-top: 1px solid var(--rule); }
.roster-row {
  display: grid;
  grid-template-columns: 3.2rem 1fr;
  gap: 1.5rem;
  padding: 1.3rem 0;
  border-bottom: 1px solid var(--rule);
  align-items: baseline;
}
@media (max-width: 560px) { .roster-row { grid-template-columns: 2.4rem 1fr; } }
.roster-row .no { font-family: var(--font-mono); color: var(--gold); font-size: 0.95rem; }
.roster-row h3 { font-size: 1.15rem; }
.roster-row .roster-desc { margin-top: 0.35rem; color: var(--ink-soft); font-size: 0.96rem; }
.roster-row.journey-row .roster-desc { margin-top: 0.35rem; }

/* Trust principles */
.principles {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border: 1px solid var(--rule);
  border-radius: 4px;
  overflow: hidden;
}
@media (max-width: 640px) { .principles { grid-template-columns: 1fr; } }
.principle { padding: 1.6rem 1.8rem; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.principle:nth-child(2n) { border-right: none; }
.principle h3 { font-size: 1.02rem; display: flex; align-items: center; gap: 0.6rem; }
.principle h3::before { content: ""; width: 7px; height: 7px; background: var(--emerald); border-radius: 50%; flex: none; }
.principle p { margin-top: 0.5rem; color: var(--ink-soft); font-size: 0.94rem; }

/* Stakeholders */
.roles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem; }
@media (max-width: 880px) { .roles { grid-template-columns: repeat(2, 1fr); } }
.role .eyebrow { display: block; margin-bottom: 0.5rem; }
.role h3 { font-size: 1.05rem; }
.role p { margin-top: 0.4rem; font-size: 0.9rem; color: var(--ink-soft); }
.roles-note {
  margin-top: 1.8rem; padding-top: 1.2rem; border-top: 1px solid var(--rule);
  font-family: var(--font-mono); font-size: 0.8rem; color: var(--sage);
}

/* Status band */
.status-band {
  background: var(--emerald-tint);
  border: 1px solid var(--rule);
  border-radius: 4px;
  padding: 2rem 2.2rem;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2rem;
  align-items: center;
}
@media (max-width: 720px) { .status-band { grid-template-columns: 1fr; } }
.status-band .pulse {
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--emerald);
  animation: pulse 2.4s ease-out infinite;
  justify-self: start;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--emerald) 45%, transparent); }
  70% { box-shadow: 0 0 0 12px color-mix(in srgb, var(--emerald) 0%, transparent); }
  100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--emerald) 0%, transparent); }
}
.status-band-inner { display: flex; align-items: center; gap: 1rem; }

/* Closing / signature */
.signoff { text-align: left; }
.signoff h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); max-width: 20ch; }
.signoff .cta-row { margin-top: 1.8rem; display: flex; gap: 1rem; flex-wrap: wrap; }

.pilot-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem 1.6rem;
  margin-top: 1.8rem;
  max-width: 640px;
}
@media (max-width: 640px) { .pilot-form { grid-template-columns: 1fr; } }
.pilot-form input {
  font-family: var(--font-body);
  font-size: 0.98rem;
  color: var(--ink);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--rule);
  padding: 0.55rem 0.1rem;
  width: 100%;
}
.pilot-form input::placeholder { color: var(--sage); }
.pilot-form input:focus { border-bottom-color: var(--emerald); outline: none; }
.pilot-form button { grid-column: 1 / -1; justify-self: start; margin-top: 0.3rem; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* Footer */
footer { border-top: 1px solid var(--rule); padding: 3rem 0 2.4rem; font-size: 0.88rem; color: var(--sage); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(4, 1fr);
  gap: 2rem;
  padding-bottom: 2.2rem;
}
@media (max-width: 880px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-brand .wordmark { font-size: 1.15rem; text-decoration: none; }
.footer-motto { margin-top: 0.9rem; font-family: var(--font-display); font-style: italic; color: var(--ink-soft); max-width: 30ch; }
.footer-col { display: flex; flex-direction: column; gap: 0.6rem; }
.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  margin-bottom: 0.2rem;
}
.footer-col a { text-decoration: none; }
.footer-col a:hover { color: var(--emerald); }
.copyright { padding-top: 1.6rem; border-top: 1px solid var(--rule); }
