/* Church TAK website
   Brand colors come from the approved shield: navy field, gold cross and trim,
   burgundy banner, cream lettering. Product mockups use the app's own tokens
   (web/src/styles/tokens.css) so they look like the real thing. */

@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 500 900;
  font-stretch: 100% 125%;
  font-display: swap;
  src: url('../fonts/archivo-var-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Atkinson Hyperlegible Next';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('../fonts/atkinson-next-var-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'B612 Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/b612-mono-400-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'B612 Mono';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/b612-mono-700-latin.woff2') format('woff2');
}

/* ---------- Tokens ---------- */
:root {
  --font-display: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Atkinson Hyperlegible Next', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --font-mono: 'B612 Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --font-ui: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;

  /* brand (fixed in both themes) */
  --navy: #001b40;
  --navy-2: #072652;
  --navy-3: #0f3266;
  --navy-line: rgb(217 164 65 / 22%);
  --gold: #d9a441;
  --gold-2: #e8bb61;
  --burgundy: #4a0a12;
  --cream: #fcedd0;
  --on-navy: #f4f1ea;
  --on-navy-2: rgb(244 241 234 / 78%);
  --on-navy-3: rgb(244 241 234 / 58%);

  /* page (light) */
  --bg: #f3f5f8;
  --bg-2: #e9eef4;
  --surface: #ffffff;
  --line: #d5dce6;
  --line-strong: #b9c3d0;
  --text: #0c1a30;
  --text-2: #3a4a61;
  --text-3: #58677c;
  --link: #164a8c;
  --gold-ink: #7a5310;
  --focus: #164a8c;
  --shadow: 0 1px 2px rgb(12 26 48 / 6%), 0 8px 24px rgb(12 26 48 / 8%);
  --shadow-lg: 0 2px 6px rgb(0 10 30 / 18%), 0 30px 60px rgb(0 10 30 / 35%);

  /* product UI (app tokens, light) */
  --ui-bg: #f5f6f8;
  --ui-surface: #ffffff;
  --ui-surface-2: #f0f2f5;
  --ui-line: #dfe3e8;
  --ui-line-strong: #c3c9d2;
  --ui-text: #202a35;
  --ui-text-2: #4e5968;
  --ui-text-3: #6b7582;
  --ui-accent: #245f9e;
  --ui-on-accent: #ffffff;
  --ui-accent-soft: #e8eff8;
  --ui-accent-text: #1f5690;
  --ui-danger: #b4232a;
  --ui-danger-soft: #fbeaea;
  --ui-danger-text: #a01f26;
  --ui-warning: #9a6700;
  --ui-warning-soft: #fcf3dc;
  --ui-warning-text: #7d5400;
  --ui-success: #23744b;
  --ui-success-soft: #e5f3ea;
  --ui-success-text: #1d6440;

  --radius: 10px;
  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 32px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --bg: #09101b;
    --bg-2: #0d1624;
    --surface: #111b2b;
    --line: #223149;
    --line-strong: #33455f;
    --text: #e9eef6;
    --text-2: #b5c0d0;
    --text-3: #8e9bb0;
    --link: #92c2f5;
    --gold-ink: #e3b65a;
    --focus: #e3b65a;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 10px 30px rgb(0 0 0 / 35%);

    --ui-bg: #14181d;
    --ui-surface: #1c2229;
    --ui-surface-2: #232b34;
    --ui-line: #2f3944;
    --ui-line-strong: #43505e;
    --ui-text: #edf1f5;
    --ui-text-2: #b7c0cb;
    --ui-text-3: #8f9aa7;
    --ui-accent: #75b8f4;
    --ui-on-accent: #0c1a28;
    --ui-accent-soft: #1c3247;
    --ui-accent-text: #8cc4f6;
    --ui-danger: #e5484d;
    --ui-danger-soft: #3a1d20;
    --ui-danger-text: #ff8f91;
    --ui-warning: #e0a82e;
    --ui-warning-soft: #372b12;
    --ui-warning-text: #f2c565;
    --ui-success: #3fb67a;
    --ui-success-soft: #16301f;
    --ui-success-text: #6fd29f;
    color-scheme: dark;
  }
}
:root[data-theme='dark'] {
  --bg: #09101b;
  --bg-2: #0d1624;
  --surface: #111b2b;
  --line: #223149;
  --line-strong: #33455f;
  --text: #e9eef6;
  --text-2: #b5c0d0;
  --text-3: #8e9bb0;
  --link: #92c2f5;
  --gold-ink: #e3b65a;
  --focus: #e3b65a;
  --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 10px 30px rgb(0 0 0 / 35%);

  --ui-bg: #14181d;
  --ui-surface: #1c2229;
  --ui-surface-2: #232b34;
  --ui-line: #2f3944;
  --ui-line-strong: #43505e;
  --ui-text: #edf1f5;
  --ui-text-2: #b7c0cb;
  --ui-text-3: #8f9aa7;
  --ui-accent: #75b8f4;
  --ui-on-accent: #0c1a28;
  --ui-accent-soft: #1c3247;
  --ui-accent-text: #8cc4f6;
  --ui-danger: #e5484d;
  --ui-danger-soft: #3a1d20;
  --ui-danger-text: #ff8f91;
  --ui-warning: #e0a82e;
  --ui-warning-soft: #372b12;
  --ui-warning-text: #f2c565;
  --ui-success: #3fb67a;
  --ui-success-soft: #16301f;
  --ui-success-text: #6fd29f;
  color-scheme: dark;
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img,
svg {
  max-width: 100%;
}
img {
  height: auto;
  display: block;
}
figure {
  margin: 0;
}
a {
  color: var(--link);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}
a:hover {
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}
h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-stretch: 112%;
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.012em;
  margin: 0;
  text-wrap: balance;
}
p {
  margin: 0;
  text-wrap: pretty;
}
ul {
  margin: 0;
  padding: 0;
}
.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  background: var(--gold);
  color: var(--navy);
  padding: 10px 14px;
  border-radius: 6px;
  font-weight: 700;
  text-decoration: none;
}
.skip:focus {
  top: 12px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.eyebrow {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-ink);
  margin: 0;
}
.field .eyebrow {
  color: var(--gold);
}

/* ---------- Buttons ---------- */
.btn {
  --b-bg: var(--navy);
  --b-fg: var(--on-navy);
  --b-line: var(--navy);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  min-height: 48px;
  padding: 0.7em 1.25em;
  border-radius: 8px;
  border: 1.5px solid var(--b-line);
  background: var(--b-bg);
  color: var(--b-fg);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.1;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease,
    transform 0.15s ease;
}
.btn:hover {
  transform: translateY(-1px);
}
.btn:active {
  transform: translateY(0);
}
.btn svg {
  width: 1.1em;
  height: 1.1em;
  flex: none;
}
.btn-gold {
  --b-bg: var(--gold);
  --b-fg: var(--navy);
  --b-line: var(--gold);
}
.btn-gold:hover {
  --b-bg: var(--gold-2);
  --b-line: var(--gold-2);
}
.btn-line {
  --b-bg: transparent;
  --b-fg: var(--on-navy);
  --b-line: rgb(244 241 234 / 38%);
}
.btn-line:hover {
  --b-line: var(--on-navy);
}
.btn-navy:hover {
  --b-bg: var(--navy-3);
  --b-line: var(--navy-3);
}
:root[data-theme='dark'] .btn-navy {
  --b-bg: var(--gold);
  --b-fg: var(--navy);
  --b-line: var(--gold);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .btn-navy {
    --b-bg: var(--gold);
    --b-fg: var(--navy);
    --b-line: var(--gold);
  }
}
.btn-small {
  min-height: 40px;
  padding: 0.5em 0.95em;
  font-size: 0.95rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 50;
  background: rgb(0 27 64 / 94%);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--navy-line);
  color: var(--on-navy);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 68px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  flex: none;
}
.brand img {
  width: 34px;
  height: 38px;
}
.brand-word {
  display: grid;
  line-height: 0.9;
  font-family: var(--font-display);
}
.brand-church {
  font-stretch: 125%;
  font-weight: 700;
  font-size: 0.62rem;
  letter-spacing: 0.34em;
  color: var(--gold);
}
.brand-tak {
  font-stretch: 125%;
  font-weight: 900;
  font-size: 1.32rem;
  letter-spacing: 0.04em;
  color: var(--cream);
}
.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.nav a:not(.btn) {
  color: var(--on-navy-2);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.97rem;
  padding: 8px 12px;
  border-radius: 6px;
}
.nav a:not(.btn):hover {
  color: var(--on-navy);
  background: rgb(255 255 255 / 7%);
}
.nav .nav-signin {
  margin-left: 8px;
}
.nav .btn {
  margin-left: 8px;
}
.menu {
  display: none;
  margin-left: auto;
  position: relative;
}
.menu summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  border: 1.5px solid rgb(244 241 234 / 30%);
  cursor: pointer;
  color: var(--on-navy);
}
.menu summary::-webkit-details-marker {
  display: none;
}
.menu summary svg {
  width: 22px;
  height: 22px;
}
.menu[open] summary {
  background: rgb(255 255 255 / 8%);
}
.menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  width: min(88vw, 300px);
  background: var(--navy-2);
  border: 1px solid var(--navy-line);
  border-radius: 12px;
  padding: 10px;
  box-shadow: var(--shadow-lg);
  display: grid;
  gap: 2px;
}
.menu-panel a:not(.btn) {
  color: var(--on-navy);
  text-decoration: none;
  font-weight: 600;
  padding: 12px 12px;
  border-radius: 8px;
}
.menu-panel a:not(.btn):hover {
  background: rgb(255 255 255 / 7%);
}
.menu-panel .btn {
  margin-top: 6px;
}
@media (max-width: 940px) {
  .nav {
    display: none;
  }
  .menu {
    display: block;
  }
}

/* ---------- Navy field sections ---------- */
.field {
  position: relative;
  background-color: var(--navy);
  background-image:
    radial-gradient(120% 90% at 85% 10%, rgb(15 50 102 / 55%) 0%, transparent 60%),
    url('../img/topo.svg');
  background-size:
    100% 100%,
    cover;
  background-position:
    center,
    center top;
  background-repeat: no-repeat; /* one continuous contour map, no tile seams on tall phones or wide screens */
  color: var(--on-navy);
  isolation: isolate;
}
.field a:not(.btn) {
  color: var(--gold-2);
}

/* ---------- Hero ---------- */
.hero {
  padding-block: clamp(44px, 6vw, 84px) clamp(64px, 8vw, 110px);
  overflow: hidden;
}
.hero-top {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(24px, 5vw, 72px);
  align-items: end;
  margin-bottom: clamp(40px, 6vw, 72px);
}
.hero-copy {
  display: grid;
  gap: 20px;
}
.hero h1 {
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 0.98;
  color: var(--cream);
}
.hero h1 .line2 {
  display: block;
  color: var(--gold);
}
.hero-side {
  display: grid;
  gap: 22px;
  padding-bottom: 6px;
}
.hero .lede {
  font-size: clamp(1.08rem, 1.5vw, 1.22rem);
  line-height: 1.55;
  color: var(--on-navy-2);
  max-width: 34em;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--on-navy-3);
}
.hero-facts li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.hero-facts li::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  opacity: 0.8;
}
.hero-visual {
  position: relative;
  width: 86%;
  padding-bottom: 4%;
}
.hero-caption {
  margin-top: clamp(28px, 4vw, 44px);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--on-navy-3);
}
@media (max-width: 960px) {
  .hero-top {
    grid-template-columns: minmax(0, 1fr);
  }
  .hero-visual {
    width: 92%;
  }
}
@media (max-width: 560px) {
  .hero-visual {
    width: 100%;
    padding-bottom: 34%;
  }
}

/* ---------- Device frames ---------- */
.wall {
  container-type: inline-size;
  position: relative;
  border-radius: 14px;
  padding: 1.1%;
  background: linear-gradient(160deg, #262b35, #0d1016 60%);
  box-shadow:
    0 0 0 1px rgb(255 255 255 / 6%),
    var(--shadow-lg);
}
.wall::after {
  /* the stand, a little bit of the real room */
  content: '';
  position: absolute;
  left: 44%;
  right: 44%;
  bottom: -5.5%;
  height: 5.5%;
  background: linear-gradient(#1a1e26, #0b0e13);
  border-radius: 0 0 6px 6px;
}
/* A current iPhone Pro: titanium edge, thin black border, Dynamic Island, home indicator
   and side buttons. Inside the phone, cqw is 1% of the phone's width. */
.phone {
  container-type: inline-size;
  position: relative;
  isolation: isolate; /* keeps the island and home indicator under cards that overlap the phone */
  width: 100%;
  aspect-ratio: 100 / 208.6;
  border-radius: 16.4% / 7.86%;
  background: linear-gradient(145deg, #75777c 0%, #3a3c40 16%, #1d1e21 42%, #2c2d31 64%, #5b5d62 86%, #2a2b2f 100%);
  box-shadow:
    inset 0 0 0 1px rgb(255 255 255 / 18%),
    0 34px 60px -30px rgb(4 18 38 / 55%),
    0 14px 26px -14px rgb(4 18 38 / 38%);
}
.phone-screen {
  position: absolute;
  inset: 3.3cqw;
  border-radius: 13.1cqw;
  overflow: hidden;
  background: var(--ui-bg);
  box-shadow: 0 0 0 2.15cqw #050506;
}
/* Dynamic Island */
.phone-screen::before {
  content: '';
  position: absolute;
  z-index: 30;
  top: 2.55cqw;
  left: 50%;
  width: 29.6cqw;
  height: 8.7cqw;
  margin-left: -14.8cqw;
  border-radius: 999px;
  background: #000;
}
/* home indicator */
.phone-screen::after {
  content: '';
  position: absolute;
  z-index: 30;
  bottom: 1.9cqw;
  left: 50%;
  width: 31.5cqw;
  height: 1.2cqw;
  margin-left: -15.75cqw;
  border-radius: 999px;
  background: var(--ui-text);
  opacity: 0.9;
}
/* side buttons: action and volume on the left, side button on the right */
.phone::before,
.phone::after,
.phone .hw::before,
.phone .hw::after {
  content: '';
  position: absolute;
  width: 1.3%;
  background: linear-gradient(90deg, #26272a, #6d6f74 45%, #2b2c30);
}
.phone::before,
.phone::after,
.phone .hw::before {
  left: -0.95%;
  border-radius: 2px 0 0 2px;
}
.phone::before {
  top: 17.6%;
  height: 4.4%;
}
.phone::after {
  top: 25.4%;
  height: 7.4%;
}
.phone .hw::before {
  top: 34.6%;
  height: 7.4%;
}
.phone .hw::after {
  right: -0.95%;
  top: 27.2%;
  height: 11.4%;
  border-radius: 0 2px 2px 0;
}
.phone .hw {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.hero .phone-slot {
  position: absolute;
  width: 21%;
  right: -18%;
  bottom: -13%;
  z-index: 2;
}
@media (max-width: 960px) {
  .hero .phone-slot {
    width: 26%;
    right: -9%;
  }
}
@media (max-width: 560px) {
  .hero .phone-slot {
    width: 36%;
    right: 0;
    bottom: 0;
  }
}

/* ---------- Mock UI: shared ---------- */
.ui {
  font-family: var(--font-ui);
  color: var(--ui-text);
  line-height: 1.25;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  user-select: none;
}
.ui * {
  box-sizing: border-box;
}
.ui .pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  border-radius: 999px;
  padding: 0.18em 0.6em;
  font-weight: 650;
  font-size: 0.78em;
  white-space: nowrap;
}
.ui .pill.open {
  background: var(--ui-danger-soft);
  color: var(--ui-danger-text);
}
.ui .pill.warn {
  background: var(--ui-warning-soft);
  color: var(--ui-warning-text);
}
.ui .pill.ok {
  background: var(--ui-success-soft);
  color: var(--ui-success-text);
}
.ui .pill.live {
  background: var(--ui-success-soft);
  color: var(--ui-success-text);
  letter-spacing: 0.06em;
  font-size: 0.7em;
}
.ui .pill.live::before,
.ui .dot::before {
  content: '';
  width: 0.5em;
  height: 0.5em;
  border-radius: 50%;
  background: currentColor;
}
.ui .dot {
  display: inline-flex;
  align-items: center;
}
.ui .dot.red::before {
  background: var(--ui-danger);
}
.ui .dot.amber::before {
  background: var(--ui-warning);
}
.ui .dot.green::before {
  background: var(--ui-success);
}
.ui .ubtn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45em;
  border-radius: 0.55em;
  font-weight: 650;
  background: var(--ui-accent);
  color: var(--ui-on-accent);
  white-space: nowrap;
}
.ui .ubtn svg,
.ui .ico {
  width: 1.1em;
  height: 1.1em;
  flex: none;
}
.ui .ubtn.danger {
  background: var(--ui-danger);
  color: #fff;
}
.ui .ubtn.quiet {
  background: var(--ui-surface);
  color: var(--ui-text);
  border: 1px solid var(--ui-line-strong);
}
.ui .ubtn.help {
  background: transparent;
  color: var(--ui-danger-text);
  border: 1.5px solid var(--ui-danger);
}

/* ---------- Mock UI: phone app ---------- */
.app {
  position: absolute;
  inset: 0;
  font-size: 4.3cqw;
  display: flex;
  flex-direction: column;
  background: var(--ui-bg);
}
/* iOS status bar: time and system glyphs on either side of the Dynamic Island */
.app-status {
  display: grid;
  grid-template-columns: 1fr 31cqw 1fr;
  align-items: center;
  height: 14cqw;
  flex: none;
  background: var(--ui-surface);
  color: var(--ui-text);
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', system-ui, 'Segoe UI', Roboto, sans-serif;
}
.app-status .time {
  justify-self: center;
  padding-left: 1.4cqw;
  font-size: 4.1cqw;
  font-weight: 600;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
.app-status .sys {
  grid-column: 3;
  justify-self: center;
  width: 17.4cqw;
  height: 3.1cqw;
  margin-right: 1.2cqw;
}
.app-body.tight {
  gap: 0.6em;
}
.app-top {
  display: flex;
  align-items: center;
  gap: 0.6em;
  padding: 0.5em 0.9em 0.6em;
  background: var(--ui-surface);
  border-bottom: 1px solid var(--ui-line);
}
.app-top img {
  width: 1.7em;
  height: auto;
}
.app-top .church {
  font-weight: 700;
  font-size: 0.95em;
  line-height: 1.1;
  flex: 1;
  min-width: 0;
}
.app-top .ubtn.help {
  font-size: 0.8em;
  padding: 0.45em 0.7em;
}
.app-top .avatar {
  width: 1.9em;
  height: 1.9em;
  border-radius: 50%;
  background: var(--ui-surface-2);
  color: var(--ui-text-2);
  display: grid;
  place-items: center;
  font-size: 0.7em;
  font-weight: 700;
}
.app-body {
  flex: 1;
  overflow: hidden;
  padding: 0.9em 0.85em;
  display: flex;
  flex-direction: column;
  gap: 0.75em;
}
/* like a real scrolling screen: content keeps its size and runs under the tab bar */
.app-body > * {
  flex-shrink: 0;
}
.app-title {
  display: grid;
  gap: 0.2em;
}
.app-title .row {
  display: flex;
  align-items: center;
  gap: 0.5em;
}
.app-title strong {
  font-size: 1.3em;
  font-weight: 750;
  letter-spacing: -0.01em;
}
.app-title .meta {
  color: var(--ui-text-2);
  font-size: 0.8em;
}
.card {
  background: var(--ui-surface);
  border: 1px solid var(--ui-line);
  border-radius: 0.75em;
  overflow: hidden;
}
.card-pad {
  padding: 0.85em 0.9em;
  display: grid;
  gap: 0.45em;
}
.card .kicker {
  font-size: 0.66em;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ui-text-3);
  font-weight: 700;
}
.card .big {
  font-size: 1.25em;
  font-weight: 750;
}
.card .place {
  display: flex;
  align-items: center;
  gap: 0.35em;
  color: var(--ui-accent-text);
  font-size: 0.85em;
}
.card .note {
  color: var(--ui-text-2);
  font-size: 0.82em;
}
.card .ubtn {
  padding: 0.75em;
  font-size: 0.95em;
  margin-top: 0.2em;
}
.card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.7em 0.9em;
  border-bottom: 1px solid var(--ui-line);
  font-weight: 700;
  font-size: 0.9em;
}
.card-head span {
  color: var(--ui-text-3);
  font-weight: 500;
  font-size: 0.9em;
}
.rows {
  display: grid;
}
.rows > div {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.55em;
  padding: 0.6em 0.9em;
  border-top: 1px solid var(--ui-line);
}
.rows > div:first-child {
  border-top: 0;
}
.rows b {
  display: block;
  font-size: 0.86em;
  font-weight: 650;
}
.rows small {
  display: block;
  color: var(--ui-text-2);
  font-size: 0.72em;
  margin-top: 0.1em;
}
.rows .ubtn {
  font-size: 0.72em;
  padding: 0.5em 0.8em;
}
.app-tabs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: var(--ui-surface);
  border-top: 1px solid var(--ui-line);
  padding: 0.55em 0.3em 2.9em; /* room for the home indicator */
  font-size: 0.6em;
  color: var(--ui-text-3);
  text-align: center;
}
.app-tabs span {
  display: grid;
  justify-items: center;
  gap: 0.25em;
  position: relative;
}
.app-tabs svg {
  width: 2em;
  height: 2em;
}
.app-tabs .on {
  color: var(--ui-accent-text);
  font-weight: 700;
}
.app-tabs .badge {
  position: absolute;
  top: -0.3em;
  left: 58%;
  background: var(--ui-danger);
  color: #fff;
  border-radius: 999px;
  min-width: 1.6em;
  height: 1.6em;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.85em;
  font-style: normal;
  line-height: 1;
}
.toast {
  display: flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.65em 0.8em;
  border-radius: 0.7em;
  background: var(--ui-success-soft);
  color: var(--ui-success-text);
  font-weight: 650;
  font-size: 0.82em;
}

/* Help composer bits */
.call911 {
  display: flex;
  align-items: center;
  gap: 0.5em;
  background: var(--ui-danger-soft);
  color: var(--ui-danger-text);
  border-radius: 0.6em;
  padding: 0.55em 0.55em 0.55em 0.75em;
  font-weight: 650;
  font-size: 0.82em;
}
.call911 .c {
  margin-left: auto;
  border: 1px solid var(--ui-danger);
  border-radius: 0.5em;
  padding: 0.35em 0.6em;
  background: var(--ui-surface);
}
.seg {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5em;
}
.seg > span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  padding: 0.75em 0.4em;
  border-radius: 0.6em;
  border: 1px solid var(--ui-line-strong);
  background: var(--ui-surface);
  font-weight: 650;
  font-size: 0.9em;
}
.seg > span.on {
  background: var(--ui-danger);
  border-color: var(--ui-danger);
  color: #fff;
}
.q {
  font-weight: 700;
  font-size: 0.85em;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4em;
}
.chips span {
  border: 1px solid var(--ui-line-strong);
  border-radius: 999px;
  padding: 0.4em 0.75em;
  font-size: 0.8em;
  font-weight: 600;
  background: var(--ui-surface);
}
.chips span.on {
  border-color: var(--ui-accent);
  background: var(--ui-accent-soft);
  color: var(--ui-accent-text);
}
.where {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5em;
}
.where > span {
  display: grid;
  gap: 0.1em;
  padding: 0.55em 0.65em;
  border: 1px solid var(--ui-line-strong);
  border-radius: 0.6em;
  background: var(--ui-surface);
  font-size: 0.78em;
}
.where > span.on {
  border: 2px solid var(--ui-accent);
  background: var(--ui-accent-soft);
}
.where b {
  font-size: 1.05em;
}
.where small {
  color: var(--ui-text-2);
}
.sendbar {
  padding: 0.2em 0.85em 1.75em; /* room for the home indicator */
}
.textbox {
  border: 1px solid var(--ui-line-strong);
  border-radius: 0.6em;
  background: var(--ui-surface);
  padding: 0.6em 0.7em;
  font-size: 0.82em;
  min-height: 3.6em;
}
.addphoto {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  color: var(--ui-accent-text);
  font-weight: 650;
  font-size: 0.8em;
}
.sendbar .ubtn {
  padding: 0.85em;
  font-size: 1em;
}

/* ---------- Mock UI: Command Center (always dark, like the wall screen) ---------- */
.cc {
  --c-bg: #11151b;
  --c-panel: #171c24;
  --c-panel-2: #1d2430;
  --c-line: #2a3340;
  --c-text: #eef2f6;
  --c-text-2: #aeb8c5;
  --c-text-3: #7f8a98;
  --c-red: #e5484d;
  --c-amber: #e0a82e;
  --c-green: #3fb67a;
  --c-blue: #6fb0ee;
  font-size: 1.62cqw;
  aspect-ratio: 16 / 9.4;
  width: 100%;
  border-radius: 0.6em;
  overflow: hidden;
  background: var(--c-bg);
  color: var(--c-text);
  display: grid;
  grid-template-rows: auto 1fr;
}
.cc-top {
  display: flex;
  align-items: center;
  gap: 0.9em;
  padding: 0.7em 1em;
  border-bottom: 1px solid var(--c-line);
}
.cc-top img {
  width: 1.9em;
}
.cc-top .who {
  display: grid;
  line-height: 1.15;
}
.cc-top .who b {
  font-size: 1.05em;
}
.cc-top .who small {
  font-size: 0.62em;
  letter-spacing: 0.14em;
  color: var(--c-text-2);
  font-weight: 700;
}
.cc-top .now {
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 0.7em;
}
.cc-top .now .live {
  color: var(--c-green);
  font-weight: 800;
  font-size: 0.72em;
  letter-spacing: 0.08em;
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
}
.cc-top .now .live::before {
  content: '';
  width: 0.55em;
  height: 0.55em;
  border-radius: 50%;
  background: currentColor;
}
.cc-top .now div {
  display: grid;
  line-height: 1.15;
}
.cc-top .now b {
  font-size: 1.05em;
}
.cc-top .now small {
  color: var(--c-text-2);
  font-size: 0.72em;
}
.cc-top .clock {
  font-weight: 800;
  font-size: 1.55em;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.cc-top .clock small {
  font-size: 0.5em;
  color: var(--c-text-2);
  font-weight: 600;
  margin-left: 0.2em;
}
.cc-top .em {
  border: 1px solid var(--c-line);
  border-radius: 0.4em;
  padding: 0.35em 0.6em;
  color: var(--c-red);
  font-weight: 700;
  font-size: 0.72em;
  display: inline-flex;
  gap: 0.35em;
  align-items: center;
}
.cc-top .em svg {
  width: 1.1em;
  height: 1.1em;
}
.cc-main {
  display: grid;
  grid-template-columns: 1fr 36%;
  min-height: 0;
}
.cc-map {
  position: relative;
  min-height: 0;
  border-right: 1px solid var(--c-line);
}
.cc-map svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.cc-side {
  padding: 0.8em;
  display: flex;
  flex-direction: column;
  gap: 0.7em;
  min-height: 0;
}
.cc-side h5 {
  margin: 0;
  font-family: var(--font-ui);
  font-size: 0.66em;
  letter-spacing: 0.14em;
  color: var(--c-text-2);
  display: flex;
  align-items: center;
  gap: 0.5em;
}
.cc-side h5 .n {
  background: var(--c-red);
  color: #fff;
  border-radius: 999px;
  min-width: 1.6em;
  height: 1.6em;
  display: grid;
  place-items: center;
  letter-spacing: 0;
}
.cc-help {
  border: 1px solid #6b5418;
  border-radius: 0.5em;
  background: var(--c-panel);
  overflow: hidden;
}
.cc-help .state {
  display: flex;
  justify-content: space-between;
  background: #3a2f12;
  color: #f2c565;
  font-weight: 750;
  font-size: 0.8em;
  padding: 0.5em 0.75em;
}
.cc-help dl {
  margin: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.45em 0.9em;
  padding: 0.65em 0.75em 0.55em;
}
.cc-help dt {
  font-size: 0.56em;
  letter-spacing: 0.12em;
  color: var(--c-text-3);
  font-weight: 800;
  padding-top: 0.4em;
}
.cc-help dd {
  margin: 0;
  font-size: 0.82em;
  line-height: 1.25;
}
.cc-help dd b {
  font-size: 1.08em;
}
.cc-help dd small {
  display: block;
  color: var(--c-text-2);
  font-size: 0.82em;
}
.cc-help dd small.inline {
  display: inline;
}
.cc-help .urgent {
  display: inline-block;
  background: var(--c-red);
  color: #fff;
  border-radius: 0.3em;
  font-size: 0.62em;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 0.15em 0.4em;
  vertical-align: 0.2em;
  margin-left: 0.3em;
}
.cc-help .chain {
  display: flex;
  flex-wrap: wrap;
  gap: 0.2em 0.8em;
  border-top: 1px solid var(--c-line);
  padding: 0.5em 0.75em;
  font-size: 0.6em;
  color: var(--c-text-2);
}
.cc-help .chain span {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
}
.cc-help .chain span::before {
  content: '';
  width: 0.6em;
  height: 0.6em;
  border-radius: 50%;
  background: var(--c-green);
}
.cc-help .chain span.cur {
  color: var(--c-text);
  font-weight: 700;
}
.cc-help .chain span.cur::before {
  background: transparent;
  border: 2px solid var(--c-amber);
}
.cc-help .chain span.next::before {
  background: transparent;
  border: 1px solid var(--c-text-3);
}
.cc-pos {
  margin-top: auto;
  border: 1px solid var(--c-line);
  border-radius: 0.5em;
  background: var(--c-panel);
  padding: 0.6em 0.7em;
  display: grid;
  gap: 0.5em;
}
.cc-pos .tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.35em;
}
.cc-pos .tiles div {
  border-radius: 0.35em;
  padding: 0.35em 0.5em;
  display: grid;
  line-height: 1.05;
}
.cc-pos .tiles b {
  font-size: 1.6em;
  font-weight: 800;
}
.cc-pos .tiles small {
  font-size: 0.52em;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.cc-pos .t1 {
  background: #16301f;
  color: #6fd29f;
}
.cc-pos .t2 {
  background: #372b12;
  color: #f2c565;
}
.cc-pos .t3 {
  background: #22262d;
  color: var(--c-text-2);
}
.cc-pos ul {
  list-style: none;
  display: grid;
  gap: 0.25em;
  font-size: 0.66em;
}
.cc-pos li {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.5em;
  align-items: center;
}
.cc-pos li::before {
  content: '';
  width: 0.65em;
  height: 0.65em;
  border-radius: 50%;
  background: var(--c-green);
}
.cc-pos li.w::before {
  background: var(--c-amber);
}
.cc-pos li em {
  font-style: normal;
  color: var(--c-green);
  font-weight: 700;
}
.cc-pos li.w em {
  color: var(--c-amber);
}

/* ---------- Content sections ---------- */
.section {
  padding-block: clamp(64px, 9vw, 120px);
}
.section + .section {
  padding-top: 0;
}
.section-head {
  display: grid;
  gap: 16px;
  max-width: 760px;
  margin-bottom: clamp(36px, 5vw, 56px);
}
.section-head h2 {
  font-size: clamp(1.95rem, 3.6vw, 3rem);
}
.section-head p:not(.eyebrow) {
  font-size: 1.15rem;
  color: var(--text-2);
  max-width: 40em;
}
.field .section-head p:not(.eyebrow) {
  color: var(--on-navy-2);
}
.field .section-head h2 {
  color: var(--cream);
}

/* Problem strip */
.pains {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.pain {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 26px 24px 28px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.pain .was {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.5;
  color: var(--text-3);
  padding-bottom: 14px;
  border-bottom: 1px dashed var(--line-strong);
}
.pain h3 {
  font-size: 1.3rem;
  font-stretch: 106%;
}
.pain p {
  color: var(--text-2);
}
@media (max-width: 880px) {
  .pains {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Feature rows */
.feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(32px, 6vw, 88px);
  align-items: center;
}
.feature + .feature {
  margin-top: clamp(72px, 10vw, 128px);
}
.feature.flip .feature-copy {
  order: 2;
}
.feature-copy {
  display: grid;
  gap: 18px;
  max-width: 520px;
}
.feature-copy h2 {
  font-size: clamp(1.9rem, 3.3vw, 2.75rem);
}
.feature-copy > p:not(.eyebrow) {
  font-size: 1.12rem;
  color: var(--text-2);
}
.ticks {
  list-style: none;
  display: grid;
  gap: 10px;
  margin-top: 4px;
}
.ticks li {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 10px;
  align-items: start;
}
.ticks li::before {
  content: '';
  width: 18px;
  height: 18px;
  margin-top: 4px;
  border-radius: 50%;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3.2 3.2L15 7' fill='none' stroke='%23001b40' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
      center / 14px no-repeat,
    var(--gold);
}
.feature-visual {
  position: relative;
  display: flex;
  justify-content: center;
}
.stage {
  position: relative;
  width: 100%;
  border-radius: 18px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  padding: clamp(22px, 4vw, 44px);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(16px, 3vw, 28px);
  overflow: hidden;
}
.stage::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../img/topo.svg') center / cover no-repeat;
  opacity: 0.55;
  filter: grayscale(1) contrast(1.2);
  mix-blend-mode: multiply;
  pointer-events: none;
}
:root[data-theme='dark'] .stage::before {
  mix-blend-mode: screen;
  opacity: 0.35;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .stage::before {
    mix-blend-mode: screen;
    opacity: 0.35;
  }
}
.stage > * {
  position: relative;
}
.stage .phone {
  width: min(300px, 62%);
  flex: none;
}
.stage .phone.small {
  width: min(262px, 46%);
}
@media (max-width: 560px) {
  .stage {
    padding: 18px 14px;
  }
}
@media (max-width: 900px) {
  .feature {
    grid-template-columns: minmax(0, 1fr);
  }
  .feature.flip .feature-copy {
    order: 0;
  }
}

/* Coverage mock (desktop card) */
.desk {
  container-type: inline-size;
  width: 100%;
  max-width: 620px;
}
.coverage {
  font-size: 2.35cqw;
  background: var(--ui-bg);
  border: 1px solid var(--ui-line);
  border-radius: 0.9em;
  box-shadow: var(--shadow);
  padding: 1.2em;
  display: grid;
  gap: 0.9em;
}
.coverage .tabs {
  display: flex;
  gap: 1.3em;
  border-bottom: 1px solid var(--ui-line);
  font-size: 0.82em;
  color: var(--ui-text-2);
  font-weight: 600;
}
.coverage .tabs span {
  padding-bottom: 0.55em;
}
.coverage .tabs .on {
  color: var(--ui-text);
  border-bottom: 2px solid var(--ui-accent);
}
.coverage .tiles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.55em;
}
.coverage .tiles div {
  background: var(--ui-surface);
  border: 1px solid var(--ui-line);
  border-radius: 0.55em;
  padding: 0.55em 0.7em;
  display: grid;
  gap: 0.1em;
}
.coverage .tiles b {
  font-size: 1.5em;
  font-weight: 800;
  line-height: 1;
}
.coverage .tiles small {
  font-size: 0.72em;
  color: var(--ui-text-2);
}
.coverage .tiles .r b {
  color: var(--ui-danger-text);
}
.coverage .tiles .a b {
  color: var(--ui-warning-text);
}
.coverage .day {
  font-weight: 700;
  font-size: 0.85em;
}
.coverage .svc {
  background: var(--ui-surface);
  border: 1px solid var(--ui-line);
  border-radius: 0.6em;
  overflow: hidden;
}
.coverage .svc-head {
  display: flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.6em 0.8em;
  background: var(--ui-surface-2);
  font-size: 0.85em;
}
.coverage .svc-head i {
  width: 0.7em;
  height: 0.7em;
  border-radius: 0.15em;
  background: #2f6fb5;
}
.coverage .svc-head span {
  color: var(--ui-text-2);
}
.coverage .svc-head em {
  margin-left: auto;
  font-style: normal;
  color: var(--ui-text-3);
  font-size: 0.9em;
}
.coverage .line {
  display: grid;
  grid-template-columns: 1.25fr 1.3fr 0.9fr 0.85fr;
  align-items: center;
  gap: 0.6em;
  padding: 0.55em 0.8em;
  border-top: 1px solid var(--ui-line);
  font-size: 0.82em;
}
.coverage .line b {
  display: block;
  font-weight: 650;
}
.coverage .line small {
  color: var(--ui-text-2);
  font-size: 0.86em;
}
.coverage .line .person {
  display: flex;
  align-items: center;
  gap: 0.45em;
  color: var(--ui-text-2);
}
.coverage .line .person i {
  width: 1.8em;
  height: 1.8em;
  border-radius: 50%;
  background: var(--ui-surface-2);
  font-style: normal;
  font-size: 0.72em;
  font-weight: 700;
  display: grid;
  place-items: center;
  color: var(--ui-text-2);
  flex: none;
}
.coverage .line .ubtn {
  font-size: 0.86em;
  padding: 0.45em 0.6em;
  justify-self: end;
}
.coverage .line .ubtn.ghost {
  background: transparent;
  color: var(--ui-accent-text);
}
.coverage .line.flag {
  box-shadow: inset 3px 0 0 var(--ui-warning);
}
.coverage .line .pill {
  justify-self: start;
}
@container (max-width: 460px) {
  .coverage {
    font-size: 3.3cqw;
    padding: 0.9em;
  }
  .coverage .tabs,
  .coverage .line .person {
    display: none;
  }
  .coverage .tiles {
    grid-template-columns: repeat(2, 1fr);
  }
  .coverage .line {
    grid-template-columns: 1.4fr 1fr 0.9fr;
  }
}

/* Five Ws card (light, the leader's view) */
.fivew {
  container-type: inline-size;
  width: min(360px, 100%);
  flex: none;
}
.fivew-card {
  font-size: 4.2cqw;
  background: var(--ui-surface);
  border: 1px solid var(--ui-line);
  border-radius: 0.8em;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.fivew-card .state {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65em 0.9em;
  background: var(--ui-warning-soft);
  color: var(--ui-warning-text);
  font-weight: 750;
  font-size: 0.85em;
}
.fivew-card dl {
  margin: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.6em 1em;
  padding: 0.9em;
}
.fivew-card dt {
  font-size: 0.62em;
  letter-spacing: 0.12em;
  font-weight: 800;
  color: var(--ui-text-3);
  padding-top: 0.45em;
}
.fivew-card dd {
  margin: 0;
  font-size: 0.86em;
}
.fivew-card dd b {
  font-size: 1.08em;
}
.fivew-card dd small {
  display: block;
  color: var(--ui-text-2);
  font-size: 0.85em;
}
.fivew-card .urgent {
  display: inline-block;
  background: var(--ui-danger);
  color: #fff;
  border-radius: 0.3em;
  font-size: 0.66em;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 0.15em 0.45em;
  margin-left: 0.35em;
  vertical-align: 0.15em;
}
.fivew-card .chain {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3em 0.9em;
  border-top: 1px solid var(--ui-line);
  padding: 0.65em 0.9em;
  font-size: 0.68em;
  color: var(--ui-text-2);
}
.fivew-card .chain span {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
}
.fivew-card .chain span::before {
  content: '';
  width: 0.65em;
  height: 0.65em;
  border-radius: 50%;
  background: var(--ui-success);
}
.fivew-card .chain .cur {
  font-weight: 700;
  color: var(--ui-text);
}
.fivew-card .chain .cur::before {
  background: transparent;
  border: 2px solid var(--ui-warning);
}
.fivew-card .chain .next::before {
  background: transparent;
  border: 1px solid var(--ui-text-3);
}
.help-stage {
  align-items: center;
  gap: 0;
}
.help-stage .phone.small {
  width: min(250px, 50%);
}
.help-stage .fivew {
  width: min(330px, 62%);
  margin-left: -12%;
  z-index: 2;
  margin-top: 18%;
}
@media (max-width: 560px) {
  .help-stage {
    flex-direction: column;
  }
  .help-stage .phone.small {
    width: min(250px, 74%);
  }
  .help-stage .fivew {
    width: min(330px, 94%);
    margin: -34% 0 0;
  }
}

/* Emergency */
.emergency-stage {
  flex-direction: column;
  align-items: stretch;
}
.em-shot {
  container-type: inline-size;
  width: 100%;
}
.em-app {
  font-size: 2.2cqw;
  border-radius: 0.8em;
  overflow: hidden;
  border: 1px solid var(--ui-line);
  background: var(--ui-bg);
  box-shadow: var(--shadow);
}
.em-banner {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.2em 1em;
  align-items: center;
  padding: 1.1em 1.3em;
  color: #fff;
  background: linear-gradient(100deg, #c42b33 0%, #a91d25 55%, #8b141b 100%);
  overflow: hidden;
}
.em-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 20%, rgb(255 255 255 / 14%) 45%, transparent 70%);
  transform: translateX(-100%);
  animation: sweep 3.2s ease-in-out infinite;
  pointer-events: none;
}
.em-icon {
  position: relative;
  width: 3.4em;
  height: 3.4em;
  border-radius: 50%;
  background: #fff;
  color: #b4232a;
  display: grid;
  place-items: center;
  grid-row: span 3;
}
.em-icon svg {
  width: 1.7em;
  height: 1.7em;
}
.em-icon::before,
.em-icon::after {
  content: '';
  position: absolute;
  inset: -0.35em;
  border-radius: 50%;
  border: 2px solid rgb(255 255 255 / 70%);
  animation: ring 1.8s ease-out infinite;
}
.em-icon::after {
  animation-delay: 0.9s;
}
.em-banner strong {
  font-family: var(--font-ui);
  font-size: 1.7em;
  font-weight: 850;
  letter-spacing: 0.02em;
  line-height: 1;
}
.em-banner .by {
  font-size: 0.9em;
  opacity: 0.92;
}
.em-banner .msg {
  font-weight: 650;
  font-size: 1.05em;
}
.em-actions {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6em;
  margin-top: 0.7em;
}
.em-actions span {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  border-radius: 0.5em;
  padding: 0.55em 0.9em;
  font-weight: 700;
  font-size: 0.9em;
}
.em-actions .proc {
  background: #fff;
  color: #a01f26;
}
.em-actions .clear {
  border: 1.5px solid rgb(255 255 255 / 75%);
}
.em-actions svg {
  width: 1.1em;
  height: 1.1em;
}
.em-under {
  padding: 1em 1.3em 1.3em;
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 0.8em;
  opacity: 0.55;
}
.em-under .card {
  font-size: 0.85em;
}
.em-under .ghostline {
  height: 0.7em;
  border-radius: 0.3em;
  background: var(--ui-surface-2);
  margin: 0.55em 0.9em;
}
.em-under .ghostline.s {
  width: 55%;
}
.lock-note {
  container-type: inline-size;
  width: min(420px, 100%);
  align-self: flex-end;
  margin-top: -8px;
}
.lock-card {
  font-size: 4.1cqw;
  font-family: var(--font-ui);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.2em 0.75em;
  align-items: start;
  padding: 0.85em 1em;
  border-radius: 1.1em;
  color: #16181d;
  background: rgb(246 247 250 / 92%);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border: 1px solid rgb(0 0 0 / 6%);
  box-shadow: var(--shadow);
}
.lock-card img {
  width: 2.3em;
  height: 2.3em;
  border-radius: 0.55em;
  grid-row: span 2;
}
.lock-card b {
  font-size: 0.95em;
}
.lock-card time {
  font-size: 0.78em;
  color: #6b7280;
}
.lock-card p {
  grid-column: 2 / -1;
  font-size: 0.9em;
  line-height: 1.3;
}
.lock-card .ts {
  display: block;
  font-size: 0.72em;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #b4232a;
  text-transform: uppercase;
}
@keyframes ring {
  0% {
    transform: scale(0.85);
    opacity: 0.9;
  }
  100% {
    transform: scale(1.55);
    opacity: 0;
  }
}
@keyframes sweep {
  0%,
  35% {
    transform: translateX(-100%);
  }
  75%,
  100% {
    transform: translateX(100%);
  }
}

/* Trio (messages, maps, checklists) */
.trio {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.trio article {
  display: grid;
  gap: 12px;
  align-content: start;
  padding: 28px 26px 30px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}
.trio .icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--navy);
  color: var(--gold);
}
.trio .icon svg {
  width: 24px;
  height: 24px;
}
.trio h3 {
  font-size: 1.3rem;
  font-stretch: 106%;
}
.trio p {
  color: var(--text-2);
}
.trio .small {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: var(--text-3);
  line-height: 1.55;
}
@media (max-width: 900px) {
  .trio {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- TAK ---------- */
.tak {
  padding-block: clamp(72px, 10vw, 128px);
  background-position:
    center,
    30% 40%;
}
.tak-flow {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1.1fr);
  align-items: center;
  gap: 14px;
  margin-bottom: clamp(40px, 6vw, 64px);
}
.node {
  border: 1px solid var(--navy-line);
  background: rgb(7 38 82 / 72%);
  border-radius: 12px;
  padding: 18px 18px 20px;
  display: grid;
  gap: 6px;
}
.node .label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--gold);
  text-transform: uppercase;
}
.node b {
  font-family: var(--font-display);
  font-stretch: 108%;
  font-size: 1.15rem;
  color: var(--cream);
  line-height: 1.15;
}
.node p {
  color: var(--on-navy-2);
  font-size: 0.95rem;
  line-height: 1.45;
}
.node.core {
  border-color: rgb(217 164 65 / 55%);
  background: rgb(15 50 102 / 80%);
}
.node-stack {
  display: grid;
  gap: 12px;
}
.link {
  display: grid;
  justify-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--on-navy-3);
  text-align: center;
}
.link svg {
  width: 56px;
  height: 14px;
  color: var(--gold);
}
@media (max-width: 1000px) {
  .tak-flow {
    grid-template-columns: minmax(0, 1fr);
    max-width: 520px;
  }
  .link svg {
    transform: rotate(90deg);
    width: 40px;
    height: 14px;
    margin-block: 10px;
  }
}
.tak-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--navy-line);
  border: 1px solid var(--navy-line);
  border-radius: 12px;
  overflow: hidden;
}
.tak-grid article {
  background: var(--navy);
  padding: 26px 24px 28px;
  display: grid;
  gap: 10px;
  align-content: start;
}
.tak-grid h3 {
  font-size: 1.12rem;
  font-stretch: 106%;
  color: var(--cream);
  display: flex;
  align-items: center;
  gap: 10px;
}
.tak-grid h3 svg {
  width: 22px;
  height: 22px;
  color: var(--gold);
  flex: none;
}
.tak-grid p {
  color: var(--on-navy-2);
  font-size: 0.98rem;
}
.tak-grid .tag {
  justify-self: start;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid rgb(217 164 65 / 45%);
  border-radius: 4px;
  padding: 2px 6px;
}
.tak-note {
  margin-top: 28px;
  font-size: 0.9rem;
  color: var(--on-navy-3);
  max-width: 60em;
}
@media (max-width: 960px) {
  .tak-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 620px) {
  .tak-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Trust ---------- */
.trust {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
}
.trust article {
  display: grid;
  grid-template-columns: 40px 1fr;
  align-content: start;
  gap: 6px 16px;
  padding: 28px 24px 30px 0;
  border-bottom: 1px solid var(--line);
}
.trust article svg {
  width: 28px;
  height: 28px;
  color: var(--gold-ink);
  grid-row: span 2;
  margin-top: 2px;
}
.trust h3 {
  font-size: 1.12rem;
  font-stretch: 106%;
}
.trust p {
  color: var(--text-2);
  font-size: 1rem;
}
@media (max-width: 960px) {
  .trust {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 620px) {
  .trust {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Steps ---------- */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: step;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}
.steps li {
  counter-increment: step;
  display: grid;
  gap: 10px;
  align-content: start;
  padding-top: 18px;
  border-top: 3px solid var(--navy);
}
:root[data-theme='dark'] .steps li {
  border-top-color: var(--gold);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .steps li {
    border-top-color: var(--gold);
  }
}
.steps li::before {
  content: counter(step, decimal-leading-zero);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  color: var(--gold-ink);
}
.steps h3 {
  font-size: 1.2rem;
  font-stretch: 106%;
}
.steps p {
  color: var(--text-2);
  font-size: 1rem;
}
@media (max-width: 900px) {
  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    row-gap: 32px;
  }
}
@media (max-width: 520px) {
  .steps {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Pricing ---------- */
.founding {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  padding: 14px 18px;
  border-radius: 10px;
  background: var(--burgundy);
  color: var(--cream);
  margin-bottom: 20px;
}
.founding b {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}
.founding span {
  font-weight: 600;
}
.plans {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.plan {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 18px;
  padding: 28px 26px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.plan.featured {
  border: 2px solid var(--navy);
  box-shadow: var(--shadow);
}
:root[data-theme='dark'] .plan.featured {
  border-color: var(--gold);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) .plan.featured {
    border-color: var(--gold);
  }
}
.plan-size {
  display: grid;
  gap: 2px;
}
.plan-size h3 {
  font-size: 1.45rem;
}
.plan-size small {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-3);
}
.price {
  display: flex;
  align-items: baseline;
  gap: 6px;
}
.price b {
  font-family: var(--font-display);
  font-stretch: 112%;
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1;
}
.price span {
  color: var(--text-2);
}
.addons {
  list-style: none;
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
  align-content: start;
}
.addons li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.97rem;
  color: var(--text-2);
}
.addons li b {
  color: var(--text);
  white-space: nowrap;
  font-family: var(--font-display);
  font-stretch: 104%;
  font-weight: 700;
}
.plan .btn {
  width: 100%;
}
.plan-wide {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 32px;
  padding: 24px 26px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.plan-wide div {
  display: grid;
  gap: 4px;
  max-width: 44em;
}
.plan-wide h3 {
  font-size: 1.3rem;
}
.plan-wide p {
  color: var(--text-2);
}
.includes {
  margin-top: 36px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 16px 32px;
}
.includes h3 {
  font-size: 1.1rem;
  font-stretch: 106%;
}
.includes ul {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 24px;
}
.includes li {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 8px;
  color: var(--text-2);
  font-size: 0.98rem;
}
.includes li::before {
  content: '';
  width: 14px;
  height: 14px;
  margin-top: 5px;
  border-radius: 3px;
  background: var(--gold);
}
.fine {
  margin-top: 22px;
  font-size: 0.9rem;
  color: var(--text-3);
}
@media (max-width: 960px) {
  .plans {
    grid-template-columns: minmax(0, 1fr);
    max-width: 520px;
  }
  .includes {
    grid-template-columns: minmax(0, 1fr);
  }
  .includes ul {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 520px) {
  .includes ul {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- FAQ ---------- */
.faq {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr);
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
}
.faq .section-head {
  position: sticky;
  top: 100px;
}
.qa {
  border-top: 1px solid var(--line);
}
.qa details {
  border-bottom: 1px solid var(--line);
}
.qa summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 2px;
  font-family: var(--font-display);
  font-stretch: 106%;
  font-weight: 700;
  font-size: 1.14rem;
  line-height: 1.3;
}
.qa summary::-webkit-details-marker {
  display: none;
}
.qa summary::after {
  content: '';
  flex: none;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 5v14M5 12h14' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'/%3E%3C/svg%3E")
    center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 5v14M5 12h14' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'/%3E%3C/svg%3E")
    center / contain no-repeat;
  transition: transform 0.2s ease;
  color: var(--gold-ink);
}
.qa details[open] summary::after {
  transform: rotate(45deg);
}
.qa details > div {
  padding: 0 2px 22px;
  color: var(--text-2);
  max-width: 44em;
  display: grid;
  gap: 10px;
}
@media (max-width: 900px) {
  .faq {
    grid-template-columns: minmax(0, 1fr);
  }
  .faq .section-head {
    position: static;
  }
}

/* ---------- Demo / contact ---------- */
.cta {
  padding-block: clamp(72px, 10vw, 128px);
}
.cta .wrap {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.cta-copy {
  display: grid;
  gap: 18px;
}
.cta-copy h2 {
  font-size: clamp(2rem, 3.8vw, 3.1rem);
  color: var(--cream);
}
.cta-copy > p:not(.eyebrow) {
  color: var(--on-navy-2);
  font-size: 1.12rem;
}
.contact-lines {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  font-size: 1rem;
}
.contact-lines span {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--on-navy-3);
  display: block;
}
.form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  padding: clamp(22px, 3vw, 32px);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-lg);
}
.form .full {
  grid-column: 1 / -1;
}
.form label {
  display: grid;
  gap: 6px;
  align-content: start;
  font-weight: 700;
  font-size: 0.95rem;
}
.form .lbl {
  display: block;
}
.field .form a:not(.btn) {
  color: var(--link);
}
.form label .opt {
  font-weight: 400;
  color: var(--text-3);
}
.form input,
.form select,
.form textarea {
  width: 100%;
  font: inherit;
  font-weight: 400;
  font-size: 1rem;
  color: var(--text);
  background: var(--bg);
  border: 1.5px solid var(--line-strong);
  border-radius: 8px;
  padding: 11px 12px;
  min-height: 48px;
}
.form textarea {
  min-height: 110px;
  resize: vertical;
}
.form input:focus,
.form select:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--focus);
  box-shadow: 0 0 0 3px rgb(22 74 140 / 20%);
}
.form .hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.form-foot {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
}
.form-foot small {
  color: var(--text-3);
  font-size: 0.86rem;
  max-width: 32em;
}
.form-status {
  grid-column: 1 / -1;
  border-radius: 8px;
  padding: 12px 14px;
  font-weight: 600;
}
.form-status.ok {
  background: var(--ui-success-soft);
  color: var(--ui-success-text);
}
.form-status.err {
  background: var(--ui-warning-soft);
  color: var(--ui-warning-text);
}
.form-status a {
  color: inherit;
}
@media (max-width: 960px) {
  .cta .wrap {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 560px) {
  .form {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- Footer ---------- */
.site-footer {
  background: #060d18;
  color: var(--on-navy-2);
  padding-block: 56px 40px;
  font-size: 0.95rem;
}
.foot {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 0.7fr));
  gap: 32px;
}
.foot .brand img {
  width: 40px;
  height: 45px;
}
.foot p {
  margin-top: 14px;
  max-width: 30em;
}
.foot h4 {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
}
.foot ul {
  list-style: none;
  display: grid;
  gap: 8px;
}
.foot a {
  color: var(--on-navy);
  text-decoration: none;
}
.foot a:hover {
  text-decoration: underline;
}
.legal {
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid rgb(255 255 255 / 10%);
  display: grid;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--on-navy-3);
}
.legal p {
  max-width: 78em;
}
@media (max-width: 860px) {
  .foot {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .foot > div:first-child {
    grid-column: 1 / -1;
  }
}

/* ---------- Document pages (privacy, support) ---------- */
.doc-hero {
  padding-block: clamp(44px, 6vw, 72px);
}
.doc-hero h1 {
  font-size: clamp(2.2rem, 4.6vw, 3.4rem);
  color: var(--cream);
}
.doc-hero p:not(.eyebrow) {
  color: var(--on-navy-2);
  margin-top: 12px;
  font-size: 1.1rem;
  max-width: 40em;
}
.doc {
  padding-block: clamp(40px, 6vw, 72px);
}
.doc .wrap {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: start;
}
.toc {
  position: sticky;
  top: 100px;
  display: grid;
  gap: 4px;
  font-size: 0.95rem;
}
.toc b {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 6px;
}
.toc a {
  color: var(--text-2);
  text-decoration: none;
  padding: 3px 0;
}
.toc a:hover {
  color: var(--link);
}
.prose {
  max-width: 44em;
  display: grid;
  gap: 16px;
}
.prose h2 {
  font-size: 1.55rem;
  margin-top: 26px;
  scroll-margin-top: 90px;
}
.prose h3 {
  font-size: 1.15rem;
  font-stretch: 106%;
  margin-top: 8px;
}
.prose ul {
  padding-left: 1.2em;
  display: grid;
  gap: 8px;
}
.prose li::marker {
  color: var(--gold-ink);
}
.prose p,
.prose li {
  color: var(--text-2);
}
.prose strong {
  color: var(--text);
}
.callout {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 16px 18px;
  display: grid;
  gap: 6px;
}
.callout.red {
  border-color: var(--ui-danger);
  background: var(--ui-danger-soft);
}
.callout.red p,
.callout.red strong {
  color: var(--ui-danger-text);
}
.support-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.support-grid article {
  display: grid;
  gap: 8px;
  align-content: start;
  padding: 22px 22px 24px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.support-grid h2 {
  font-size: 1.2rem;
  margin: 0;
}
.support-grid p {
  color: var(--text-2);
}
@media (max-width: 860px) {
  .doc .wrap {
    grid-template-columns: minmax(0, 1fr);
  }
  .toc {
    position: static;
  }
  .support-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* 404 */
.lost {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding-block: 80px;
}
.lost .wrap {
  display: grid;
  gap: 18px;
  justify-items: center;
}
.lost h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  color: var(--cream);
}
.lost p {
  color: var(--on-navy-2);
  max-width: 32em;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* ---------- Map artwork (inline SVG) ---------- */
.grid-sheet text {
  font-family: var(--font-display);
  font-weight: 800;
}
.grid-sheet .gs-grid,
.grid-sheet .gs-code,
.grid-sheet .gs-post,
.grid-sheet .gs-door,
.grid-sheet .gs-scale {
  font-family: var(--font-mono);
  font-weight: 700;
}
.grid-sheet .gs-grid {
  font-size: 14px;
}
.grid-sheet .gs-code {
  font-size: 10px;
  letter-spacing: 0.08em;
}
.grid-sheet .gs-post {
  font-size: 8.5px;
}
.grid-sheet .gs-door {
  font-size: 11px;
}
.grid-sheet .gs-scale {
  font-size: 10px;
}
.grid-sheet .gs-bldg {
  font-size: 13.5px;
  letter-spacing: 0.02em;
}
.grid-sheet .gs-area {
  font-size: 15px;
  letter-spacing: 0.05em;
}
.grid-sheet .gs-area-s {
  font-size: 11px;
  letter-spacing: 0.05em;
}
.grid-sheet .gs-road {
  font-size: 12px;
  letter-spacing: 0.16em;
}
.grid-sheet .gs-hex {
  font-size: 11px;
}
.grid-sheet .gs-tag {
  font-size: 10px;
  letter-spacing: 0.08em;
}
.grid-sheet .gs-north {
  font-size: 14px;
}
.cc-map text {
  font-family: var(--font-ui);
  font-weight: 700;
}
.cc-map .cc-bldg {
  font-size: 13px;
  fill: #eef2f6;
}
.cc-map .cc-p {
  font-size: 12px;
  fill: #0c1a28;
}
.cc-map .cc-lot {
  font-size: 12px;
  fill: #c9d2dd;
}
.cc-map .cc-green {
  font-size: 11px;
  font-weight: 600;
  fill: #9fdcbc;
}
.cc-map .cc-bang {
  font-size: 17px;
  font-weight: 900;
  fill: #fff;
}
.cc-map .cc-callout {
  font-size: 13px;
  fill: #fff;
}
.cc-map .cc-callout-sub {
  font-size: 11px;
  font-weight: 500;
  fill: #c9b1b3;
}
.cc-map .cc-grid {
  font-family: var(--font-mono);
  font-size: 12px;
  fill: #d9a441;
}

/* ---------- Campus mapping section ---------- */
.mapping-head {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(24px, 5vw, 64px);
  align-items: end;
  margin-bottom: clamp(28px, 4vw, 44px);
}
.mapping-head .section-head {
  margin-bottom: 0;
}
.mapping-head .ticks {
  padding-bottom: 6px;
}
.sheet-wrap {
  margin: 0;
  display: grid;
  gap: 14px;
}
/* The sample sheet: HTML header and legend around the map SVG, like a printed sheet.
   On phones the whole map fits the width and the legend drops below it. */
.gsheet {
  --gs-navy: #102c49;
  container-type: inline-size;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #f7f4ed;
  box-shadow: var(--shadow);
  padding: 16px 24px 22px;
  color: var(--gs-navy);
}
.gsheet p {
  margin: 0;
}
.gsheet-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 11px;
  margin-bottom: 18px;
  border-bottom: 3px solid #d9a441;
}
.gsheet-head img {
  width: 40px;
  height: auto;
  flex: none;
}
.gsheet-name,
.gsheet-meta {
  display: grid;
  gap: 2px;
}
.gsheet-name {
  flex: 1;
}
.gsheet-meta {
  justify-items: end;
  text-align: right;
}
.gsheet-kicker {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13px;
  font-stretch: 112%;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.2;
}
.gsheet-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 26px;
  font-stretch: 108%;
  text-transform: uppercase;
  line-height: 1.05;
}
.gsheet-small {
  font-size: 12.5px;
  color: #43566a;
}
.gsheet-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 236px;
  gap: 24px;
  align-items: start;
}
.gsheet-map svg {
  display: block;
  width: 100%;
  height: auto;
}
.gsheet-side {
  display: grid;
  gap: 18px;
  font-size: 14px;
  line-height: 1.25;
}
.gsheet-group + .gsheet-group {
  padding-top: 16px;
  border-top: 1px solid #d3cbb9;
}
.gsheet-group .gsheet-kicker {
  margin-bottom: 10px;
}
.gsheet-keys,
.gsheet-posts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 9px;
}
.gsheet-keys li {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}
.gsheet-icon {
  width: 24px;
  height: 24px;
}
.gsheet-keys b {
  display: block;
  font-weight: 700;
}
.gsheet-keys small {
  display: block;
  font-size: 12px;
  color: #566a7e;
}
.gsheet-posts {
  gap: 5px;
  font-weight: 700;
}
.gsheet-posts li {
  display: flex;
  gap: 10px;
}
.gsheet-mono {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 12px;
  padding-top: 0.15em;
}
.gsheet-notes {
  font-size: 12.5px;
  color: #43566a;
  display: grid;
  align-content: start;
  gap: 10px;
}
.gsheet-rev {
  color: #8a7f69;
}
.gsheet-hint {
  display: none;
}
/* narrow sheet: the sheet name and sheet number stack instead of squeezing */
@container (max-width: 700px) {
  .gsheet-head {
    flex-wrap: wrap;
    gap: 8px 10px;
  }
  .gsheet-meta {
    flex-basis: 100%;
    justify-items: start;
    text-align: left;
  }
}
@media (max-width: 860px) {
  .gsheet-body {
    grid-template-columns: minmax(0, 1fr);
  }
  .gsheet-side {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    grid-template-rows: auto 1fr;
    column-gap: 22px;
  }
  .gsheet-group + .gsheet-group {
    padding-top: 0;
    border-top: 0;
  }
  .gsheet-side > .gsheet-group:first-child {
    grid-row: span 2;
  }
}
@media (max-width: 560px) {
  .gsheet {
    padding: 12px 10px 16px;
    border-radius: 12px;
  }
  .gsheet-head {
    margin-bottom: 12px;
  }
  .gsheet-head img {
    width: 32px;
  }
  .gsheet-title {
    font-size: 21px;
  }
  .gsheet-body {
    gap: 18px;
  }
  .gsheet-side {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    gap: 16px;
    padding: 0 4px;
  }
  .gsheet-side > .gsheet-group:first-child {
    grid-row: auto;
  }
  .gsheet-keys {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px 12px;
  }
  .gsheet-group + .gsheet-group {
    padding-top: 14px;
    border-top: 1px solid #d3cbb9;
  }
  .gsheet .gsheet-hint {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 700;
    color: #43566a;
    text-align: center;
  }
}
.sheet-wrap figcaption {
  font-size: 0.92rem;
  color: var(--text-3);
  max-width: 60em;
}
@media (max-width: 900px) {
  .mapping-head {
    grid-template-columns: minmax(0, 1fr);
  }
}
