/* Church Flow storefront. The app's Hymn Board world (DESIGN.md): dark rails, white numeral plates with
   cable-colored edges, uppercase Archivo condensed headings, IBM Plex Mono data. The hero is booth black in both
   themes; the page below follows the visitor's light or dark setting. */
:root {
  --booth: #0F1419; --booth-card: #151C23; --booth-line: #2A3540; --booth-ink: #E4EAEE; --booth-ink2: #9AA5AF;
  --ground: #F1F3F5; --row: #FFFFFF; --rail: #16202A; --rail-ink: #E4EAEE;
  --ink: #16202A; --ink2: #5B6670; --hair: #DCE1E6;
  --plate: #FFFFFF; --plate-ink: #0F1419;
  --analog: #1F7A68; --giga: #3459B5; --dante: #D32F2F;
  /* Cable colors as drawn on booth black, from the brand guide's dark-background column. */
  --analog-d: #3DB59A; --giga-d: #6EA0F5; --dante-d: #F26D6D;
  --display: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --body: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --gutter: max(20px, env(safe-area-inset-left, 0px));
  --gutter-r: max(20px, env(safe-area-inset-right, 0px));
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --ground: #0F1419; --row: #151C23; --rail: #1B2530; --ink: #E4EAEE; --ink2: #9AA5AF; --hair: #253039;
    --analog: #3DB59A; --giga: #6EA0F5; --dante: #F26D6D; color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--ground); color: var(--ink); font: 17px/1.6 var(--body); }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--giga); }
:focus-visible { outline: 2px solid var(--giga-d); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--giga-d); color: var(--plate-ink); }
.wrap { max-width: 1240px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter-r); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: var(--gutter); top: 12px; z-index: 10; background: var(--plate); color: var(--plate-ink); padding: 8px 12px; border-radius: 4px; }

/* Plates: the app's white numeral plates. A left edge in a cable color names the system. */
.plate { display: inline-flex; align-items: center; gap: .35em; background: var(--plate); color: var(--plate-ink); font: 600 .8rem/1 var(--mono); letter-spacing: .02em; padding: .34em .6em .4em .75em; border: 1px solid rgba(15,20,25,.35); border-radius: 3px; box-shadow: inset 0 -2px 0 rgba(15,20,25,.12); white-space: nowrap; position: relative; font-variant-numeric: tabular-nums; }
.plate[data-edge]::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; border-radius: 3px 0 0 3px; background: var(--edge); }
.plate[data-edge="audio"] { --edge: var(--analog-d); } .plate[data-edge="video"] { --edge: var(--giga-d); }
.plate[data-edge="network"] { --edge: var(--dante-d); } .plate[data-edge="lighting"] { --edge: #16202A; }
.light .plate[data-edge="audio"] { --edge: #1F7A68; } .light .plate[data-edge="video"] { --edge: #3459B5; }
.light .plate[data-edge="network"] { --edge: #D32F2F; }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 1.3rem; border-radius: 6px; font: 700 1rem/1 var(--body); text-decoration: none; background: var(--plate); color: var(--plate-ink); border: 1px solid rgba(15,20,25,.3); box-shadow: inset 0 -2px 0 rgba(15,20,25,.14); transition: transform .15s ease-out; }
@media (hover: hover) { .btn:hover { transform: translateY(-1px); } }
.btn:active { transform: translateY(0); box-shadow: none; }
.btn.solid { background: var(--rail); color: var(--rail-ink); border-color: var(--rail); box-shadow: inset 0 -2px 0 rgba(0,0,0,.35); }

/* ---------- Hero: the booth ---------- */
.hero { background: var(--booth); color: var(--booth-ink); padding-top: env(safe-area-inset-top, 0px); overflow: hidden; }
.nav { display: flex; align-items: center; gap: 1.6rem; min-height: 76px; }
.nav ul { display: flex; gap: 1.5rem; list-style: none; margin: 0 0 0 1rem; padding: 0; }
.nav ul a { color: var(--booth-ink2); text-decoration: none; font-weight: 500; font-size: .95rem; }
@media (hover: hover) { .nav ul a:hover { color: var(--booth-ink); } }
.nav .btn { margin-left: auto; min-height: 42px; }
.hero-copy { padding-block: clamp(2.5rem, 7vw, 4.5rem) 2rem; max-width: 52rem; }
h1 { margin: 0; font: 900 clamp(3.1rem, 9vw, 6rem)/.9 var(--display); font-stretch: 64%; text-transform: uppercase; letter-spacing: .005em; text-wrap: balance; }
.lede { margin: 1.2rem 0 0; font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--booth-ink2); max-width: 34em; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem; margin-top: 1.8rem; }
.price-note { font: 500 .9rem/1.4 var(--mono); color: var(--booth-ink2); }

/* The traced path: three cables from the left edge connect real devices. Cards sit on the cables. */
.path { display: grid; grid-template-columns: minmax(40px, 1fr) auto minmax(60px, 1.2fr) auto minmax(60px, 1.2fr) auto; align-items: center; margin-top: 1.5rem; padding-bottom: 3.5rem; }
.cables { height: 22px; display: grid; gap: 4px; align-content: center; position: relative; }
.cables i { display: block; height: 4px; border-radius: 2px; }
.cables i:nth-child(1) { background: var(--analog-d); } .cables i:nth-child(2) { background: var(--giga-d); } .cables i:nth-child(3) { background: var(--dante-d); }
/* The first run reaches back to the window's edge, however wide the window is (the hero clips the overflow). */
.cables.from-edge i { position: relative; }
.cables.from-edge i::before { content: ""; position: absolute; right: 100%; top: 0; width: 100vw; height: 100%; background: inherit; }
.cables .tag { position: absolute; left: 50%; top: -1.9rem; transform: translateX(-50%); font: 600 .7rem/1 var(--mono); letter-spacing: .06em; color: var(--booth-ink2); white-space: nowrap; }
.device { background: var(--booth-card); border: 1px solid var(--booth-line); border-radius: 10px; padding: .9rem 1rem; min-width: 0; width: clamp(170px, 18vw, 230px); }
.device b { display: block; margin-top: .55rem; font: 800 1.2rem/1.1 var(--display); font-stretch: 74%; }
.device span.where { display: block; margin-top: .25rem; font: 500 .8rem/1.3 var(--mono); color: var(--booth-ink2); }
.trace { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; background: #1B2530; border-radius: 8px; padding: .8rem 1rem; margin-bottom: 2.5rem; font: 600 .8rem/1.3 var(--mono); color: var(--booth-ink2); letter-spacing: .04em; }
.trace b { color: var(--booth-ink); font: 800 1.05rem/1 var(--display); font-stretch: 72%; letter-spacing: .06em; }

/* ---------- The page: sections hang off the cables ---------- */
.run { position: relative; }
.run::before { content: ""; position: absolute; top: 0; bottom: 0; left: calc(var(--gutter) + 18px); width: 18px;
  background: linear-gradient(90deg, var(--analog) 0 3px, transparent 3px 7px, var(--giga) 7px 10px, transparent 10px 14px, var(--dante) 14px 17px, transparent 17px); }
.section { position: relative; padding-left: 72px; padding-block: clamp(3rem, 7vw, 5rem) 0; }
.section::before { content: ""; position: absolute; left: calc(18px + 2px); top: calc(clamp(3rem, 7vw, 5rem) + 1.05rem); width: 14px; height: 14px; border-radius: 50%; background: var(--row); border: 2px solid var(--ink); }
.section::after { content: ""; position: absolute; left: 36px; top: calc(clamp(3rem, 7vw, 5rem) + 1.5rem); width: 36px; height: 2px; background: var(--ink); }
.rail { display: flex; align-items: center; justify-content: space-between; gap: 1rem; background: var(--rail); color: var(--rail-ink); padding: .8rem 1.1rem; border-radius: 6px; }
.rail h2 { margin: 0; font: 800 clamp(1.25rem, 2.6vw, 1.6rem)/1.1 var(--display); font-stretch: 70%; letter-spacing: .07em; text-transform: uppercase; text-wrap: balance; }
.sec-body { display: grid; gap: 1.6rem; padding-top: 1.6rem; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(1.5rem, 4vw, 3.5rem); align-items: start; }
.prose { display: grid; gap: .9rem; max-width: 36em; }
.prose p { margin: 0; }
.prose .big { font: 800 clamp(1.6rem, 3.4vw, 2.3rem)/1.05 var(--display); font-stretch: 72%; text-transform: uppercase; letter-spacing: .01em; color: var(--ink); text-wrap: balance; }
.muted { color: var(--ink2); }
.facts { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; }
.facts li { display: grid; grid-template-columns: auto 1fr; gap: .75rem; align-items: baseline; }
.label { font: 600 .75rem/1.3 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--ink2); }


/* Steps: files in, gear out. A real sequence, so it is numbered. */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; counter-reset: step; }
.steps li { background: var(--row); border: 1px solid var(--hair); border-radius: 10px; padding: 1.2rem; display: grid; gap: .6rem; align-content: start; }
.steps h3 { margin: 0; font: 800 1.15rem/1.1 var(--display); font-stretch: 72%; text-transform: uppercase; letter-spacing: .05em; }
.steps p { margin: 0; color: var(--ink2); font-size: .95rem; }
.steps .plates { display: flex; flex-wrap: wrap; gap: .4rem; }


.figures { display: flex; flex-wrap: wrap; gap: .5rem; }

/* Price */
.amount { display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; }
.amount strong { font: 900 clamp(3.5rem, 8vw, 5rem)/.9 var(--display); font-stretch: 66%; }
.amount span { font: 500 .95rem/1.3 var(--mono); color: var(--ink2); }
.included { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.included li { display: flex; gap: .6rem; align-items: baseline; }
/* A small square in Analog green marks what's included; an outline marks what's coming. */
.included li::before { content: ""; flex: none; width: 9px; height: 9px; border-radius: 2px; background: var(--analog); transform: translateY(-1px); }
.included li.soon::before { background: transparent; border: 1.5px solid var(--ink2); }

/* Pilot */
.pilot { display: grid; gap: 1rem; background: #16202A; color: #E4EAEE; border-radius: 12px; padding: clamp(1.4rem, 4vw, 2.4rem); }
.pilot .big { font: 900 clamp(2rem, 5vw, 3.2rem)/.95 var(--display); font-stretch: 66%; text-transform: uppercase; margin: 0; text-wrap: balance; }
.pilot p { margin: 0; color: #C9D2D9; max-width: 40em; }
.email { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; }
.email code { font: 600 1.05rem/1 var(--mono); background: #fff; color: #0F1419; padding: .7rem .9rem; border-radius: 4px; user-select: all; }
.email button { min-height: 44px; padding: 0 1rem; border-radius: 6px; border: 1px solid #3A4753; background: transparent; color: #E4EAEE; font: 600 .95rem/1 var(--body); cursor: pointer; }
@media (hover: hover) { .email button:hover { border-color: #E4EAEE; } }

footer { padding-block: 4rem 3rem; color: var(--ink2); font-size: .9rem; }
footer .row { display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; justify-content: space-between; border-top: 1px solid var(--hair); padding-top: 1.5rem; }
footer img { height: 22px; width: auto; }
footer a { color: var(--ink2); }

/* Privacy page */
.doc { max-width: 46rem; padding-block: 3rem 2rem; }
.doc h1 { font-size: clamp(2.4rem, 7vw, 3.6rem); }
.doc h2 { font: 800 1.2rem/1.2 var(--display); font-stretch: 72%; text-transform: uppercase; letter-spacing: .06em; margin: 2rem 0 .4rem; }
.doc p { margin: .4rem 0 0; }

/* ---------- Narrow screens ---------- */
@media (max-width: 1040px) {
  .split, .price { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .nav ul { display: none; }
  /* The path turns vertical: devices stack, the cables run down between them. */
  .path { grid-template-columns: 1fr; justify-items: start; padding-left: 8px; }
  .path .cables { width: 22px; height: 44px; grid-auto-flow: column; grid-template-columns: repeat(3, 4px); gap: 4px; margin-left: 24px; }
  .path .cables i { width: 4px; height: 44px; }
  .path .cables.from-edge { margin-left: 24px; }
  .path .cables.from-edge i::before { display: none; }
  .path .cables .tag { left: 40px; top: 50%; transform: translateY(-50%); }
  .device { width: min(100%, 300px); }
  .run::before { left: calc(var(--gutter) + 2px); }
  .section { padding-left: 34px; }
  .section::before { left: 2px; }
  .section::after { left: 18px; width: 16px; }
  .board .item { grid-template-columns: 5.6rem minmax(0, 1fr) auto; gap: .6rem; padding: .7rem .8rem; }
}

/* On the dark page the rail-colored button sinks into its panel, so it turns to a white plate. */
@media (prefers-color-scheme: dark) {
  .btn.solid { background: var(--plate); color: var(--plate-ink); border-color: rgba(15,20,25,.3); box-shadow: inset 0 -2px 0 rgba(15,20,25,.14); }
}

/* ---------- Plans ---------- */
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.plan { background: var(--row); border: 1px solid var(--hair); border-radius: 12px; padding: clamp(1.3rem, 3vw, 1.8rem); display: grid; gap: .9rem; align-content: start; }
.plan.pro { border: 2px solid var(--giga); }
.plan h3 { margin: 0; font: 800 1.5rem/1 var(--display); font-stretch: 70%; letter-spacing: .08em; text-transform: uppercase; }
.plan p { margin: 0; }
.plan .figures { list-style: none; margin: 0; padding: 0; }
.extra { font: 500 .85rem/1.5 var(--mono); color: var(--ink2); }
.fine { margin: 0; padding-left: 1.1rem; color: var(--ink2); font-size: .95rem; display: grid; gap: .35rem; max-width: 52em; }

@media (max-width: 1040px) { .plans { grid-template-columns: 1fr; } }

/* ---------- The tour: sections on the left, the phone docked beside them ---------- */
.sec-body.prose { max-width: 40em; }
.steps { grid-template-columns: 1fr; }
.try-note { margin: 0; padding-top: 1rem; border-top: 1px solid var(--hair); font-size: .95rem; color: var(--ink2); }
.dock { padding: 2.5rem 0 0 72px; }
.dock-inner { display: grid; justify-items: center; gap: .8rem; }
.dock-hint { margin: 0; max-width: 24em; min-height: 2.8em; text-align: center; font-size: .9rem; color: var(--ink2); }
.follow { display: none; align-items: center; gap: .5rem; min-height: 36px; padding: 0 .9rem; border-radius: 18px; border: 1px solid var(--hair); background: var(--row); color: var(--ink); font: 600 .82rem/1 var(--body); cursor: pointer; }
.follow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid var(--ink2); }
.follow[aria-pressed="true"]::before { border-color: var(--analog); background: var(--analog); }
@media (hover: hover) { .follow:hover { border-color: var(--ink2); } }
@media (min-width: 1100px) and (min-height: 720px) and (hover: hover) {
  .dock-run { --pw: min(372px, calc((100svh - 120px) * 372 / 780)); display: grid; grid-template-columns: minmax(0, 1fr) var(--pw); column-gap: clamp(2.5rem, 5vw, 5rem); }
  .dock-run > .section { grid-column: 1; min-height: 78svh; }
  .dock { grid-column: 2; grid-row: 1 / span 6; padding: clamp(3rem, 7vw, 5rem) 0 0; }
  /* The phone plus its hint and toggle, centred in the window. */
  .dock-inner { position: sticky; top: max(16px, calc((100svh - var(--pw) * 780 / 372 - 104px) / 2)); }
  .dock .iphone { width: var(--pw); }
  .follow { display: inline-flex; }
}
@media (max-width: 860px) { .dock { padding-left: 34px; } }

.iphone { position: relative; width: min(372px, 100%); aspect-ratio: 372 / 780; padding: 12px; border-radius: 60px; background: #0C1014;
  box-shadow: inset 0 0 0 1.5px #2E3740, inset 0 0 0 5px #0C1014, inset 0 0 0 6px #232B33, 0 40px 70px -30px rgba(8, 12, 16, .55); }
.iphone-island { position: absolute; z-index: 3; top: 23px; left: 50%; width: 31%; height: 30px; transform: translateX(-50%); border-radius: 20px; background: #000; }
.iphone-screen { position: relative; height: 100%; border-radius: 48px; overflow: hidden; background: #F1F3F5; isolation: isolate; }
.cf-noscript { margin: 0; padding: 45% 2rem 0; text-align: center; color: #5B6670; }

/* The app's light theme, whatever the page's theme: it's a picture of the phone. */
.cf { --g: #F1F3F5; --w: #FFFFFF; --rail: #16202A; --ink: #0F1419; --ink2: #5B6670; --hair: #E1E5E9; --tint: #0A6CFF; --red: #C62828;
  --analog: #1F7A68; --giga: #3459B5; --dante: #D32F2F; --vid: #3459B5; --lx: #16202A; --gen: #8A949C;
  position: absolute; inset: 0; display: flex; flex-direction: column; color: var(--ink); font: 15px/1.3 var(--body); -webkit-font-smoothing: antialiased; }
:where(.cf) button:active { background-color: rgba(15, 20, 25, .06); }
:where(.cf) button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; text-align: left; -webkit-tap-highlight-color: transparent; }
.cf :focus-visible { outline: 2px solid var(--tint); outline-offset: 2px; }
.cf svg { flex: none; }
.cf-status { flex: none; height: 54px; display: flex; justify-content: space-between; align-items: flex-end; padding: 0 30px 8px 40px; font: 600 15px/1 var(--body); background: var(--g); }
.cf.is-dark .cf-status { background: var(--rail); color: #fff; }
.cf-status-icons { display: flex; gap: 5px; align-items: center; }
.cf-status-icons svg { height: 11px; width: auto; fill: currentColor; }
.cf-status-icons svg:last-child { height: 12px; }
.cf-view { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding-bottom: 96px; scrollbar-width: none; }
.cf-view::-webkit-scrollbar { display: none; }
.cf.has-sheet .cf-view { padding-bottom: 300px; }
.cf-push { animation: cf-in .32s cubic-bezier(.22, 1, .36, 1); }
.cf-pop { animation: cf-back .28s cubic-bezier(.22, 1, .36, 1); }
.cf-fade { animation: cf-swap .22s cubic-bezier(.22, 1, .36, 1); }
@keyframes cf-swap { from { transform: translateY(6px); opacity: 0; } }
@keyframes cf-in { from { transform: translateX(28%); opacity: 0; } }
@keyframes cf-back { from { transform: translateX(-14%); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .cf-push, .cf-pop, .cf-fade { animation: none; } }

/* Bars and headers */
.cf-bar { position: sticky; top: 0; z-index: 2; display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; gap: 8px; padding: 6px 16px 10px; background: var(--g); }
.cf-bar h3 { margin: 0; grid-column: 2; text-align: center; font: 700 16px/1.2 var(--body); }
.cf-bar-root h3 { font: 800 17px/1.2 var(--display); font-stretch: 80%; }
.cf-round { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, .85); box-shadow: 0 1px 3px rgba(15, 20, 25, .12), inset 0 0 0 1px rgba(15, 20, 25, .06); }
.cf-round svg { width: 20px; height: 20px; fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.cf-pad { padding: 2px 16px 16px; }
.cf-stack { display: grid; gap: 18px; }
.cf-title { margin: 14px 0 0; font: 800 22px/1 var(--display); font-stretch: 72%; text-transform: uppercase; letter-spacing: .02em; }
.cf-sub, .cf-note { margin: 4px 0 0; font-size: 12.5px; color: var(--ink2); }
.cf-note { margin: 0 0 10px; font: 600 11px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; }

/* Plates: white, mono, with the system's color on the leading edge, as in the app. */
.cf-plate { display: inline-flex; align-items: center; justify-content: center; min-width: 68px; height: 24px; padding: 0 7px 0 10px; position: relative; background: #fff; color: var(--ink); border: 1px solid rgba(15, 20, 25, .55); border-radius: 3px; font: 500 12.5px/1 var(--mono); letter-spacing: .02em; white-space: nowrap; font-variant-numeric: tabular-nums; }
.cf-plate[data-sys]::before { content: ""; position: absolute; left: -1px; top: -1px; bottom: -1px; width: 5px; border-radius: 3px 0 0 3px; background: var(--edge); }
.cf-plate[data-sys="audio"] { --edge: var(--analog); } .cf-plate[data-sys="video"] { --edge: var(--vid); } .cf-plate[data-sys="network"] { --edge: var(--dante); }
.cf-plate[data-sys="lighting"] { --edge: var(--lx); } .cf-plate[data-sys="general"] { --edge: var(--gen); }
.cf-count { min-width: 0; height: 22px; padding: 0 6px; font-weight: 600; }
.cf-red { color: var(--red); font-style: normal; font-weight: 600; }

/* Signal flow board */
.cf-board { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 22px 40px; padding: 6px 12px 10px; }
.cf-wires { position: absolute; z-index: 2; inset: 0; width: 100%; pointer-events: none; overflow: visible; }
.cf-wire { fill: none; stroke: var(--k); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cf-port { fill: #fff; stroke: var(--k); stroke-width: 2; }
.cf-wire[data-kind="dante"], .cf-port[data-kind="dante"] { --k: var(--dante); } .cf-wire[data-kind="analog"], .cf-port[data-kind="analog"] { --k: var(--analog); }
.cf-wire[data-kind="giga"], .cf-port[data-kind="giga"] { --k: var(--giga); } .cf-wire[data-kind="video"], .cf-port[data-kind="video"] { --k: #16202A; }
.cf-dev.linked { border-color: #5B6670; }
.cf-room { position: relative; display: grid; gap: 6px; align-content: start; padding: 8px; border: 1.5px solid #9AA5AF; border-radius: 6px; background: rgba(255, 255, 255, .5); }
.cf-room h4 { margin: 0 0 2px; font: 800 12px/1 var(--display); font-stretch: 76%; letter-spacing: .08em; text-transform: uppercase; }
.cf-dev { position: relative; z-index: 1; display: grid; gap: 4px; padding: 6px; border-radius: 5px; background: var(--w); border: 1px solid var(--hair); transition: background-color .15s ease-out, border-color .15s ease-out; }
.cf-dev .cf-plate { justify-self: start; min-width: 0; height: 20px; font-size: 11px; }
.cf-dev b { font: 800 13px/1.1 var(--display); font-stretch: 80%; overflow-wrap: anywhere; }
@media (hover: hover) { .cf-dev:hover { border-color: #9AA5AF; } }
.cf-dev[aria-pressed="true"] { background: var(--rail); border-color: var(--rail); color: #fff; }

/* Bottom sheet: what's selected on the board or the plan */
.cf-sheet { position: absolute; left: 8px; right: 8px; bottom: 84px; z-index: 4; max-height: 212px; display: flex; flex-direction: column; border-radius: 22px; background: #fff;
  box-shadow: 0 10px 30px -8px rgba(15, 20, 25, .3), inset 0 0 0 1px rgba(15, 20, 25, .06); }
.cf-sheet[hidden] { display: none; }
.cf-sheet-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 14px 10px; border-bottom: 1px solid var(--hair); }
.cf-sheet-head > div { display: grid; grid-template-columns: auto 1fr; column-gap: 8px; row-gap: 3px; align-items: center; }
.cf-sheet-head b { font: 800 16px/1.1 var(--display); font-stretch: 78%; }
.cf-sheet-head small { grid-column: 1 / -1; font-size: 12px; color: var(--ink2); }
.cf-pill { flex: none; height: 32px; padding: 0 14px; border-radius: 16px; background: var(--tint) !important; color: #fff !important; font-weight: 600 !important; font-size: 14px !important; }
.cf-runs { list-style: none; margin: 0; padding: 4px 0; max-height: 161px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
.cf-runs::-webkit-scrollbar { display: none; }
.cf-runs button { width: 100%; display: grid; grid-template-columns: auto 1fr 14px; gap: 10px; align-items: center; padding: 8px 14px; min-height: 46px; }
@media (hover: hover) { .cf-runs button:hover { background: var(--g); } }
.cf-run-text { display: grid; gap: 2px; min-width: 0; }
.cf-run-text b { font-weight: 600; font-size: 13.5px; }
.cf-run-text small, .cf-cables small { font: 500 11.5px/1.2 var(--mono); color: var(--ink2); display: block; }
.cf svg[viewBox="0 0 24 24"] { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cf-runs svg, .cf-row > svg, .cf-plan-card > svg { color: #A4ADB5; }
.cf-cable { display: inline-flex; align-items: center; height: 22px; padding: 0 7px; border-radius: 3px; font: 600 11.5px/1 var(--mono); color: #fff; white-space: nowrap; background: var(--k); }
.cf-cable[data-kind="dante"] { --k: var(--dante); } .cf-cable[data-kind="analog"] { --k: var(--analog); } .cf-cable[data-kind="giga"] { --k: var(--giga); } .cf-cable[data-kind="video"] { --k: #16202A; }

/* Tab bar: the floating bar from the app */
.cf-tabs { position: absolute; z-index: 5; left: 10px; right: 10px; bottom: 14px; height: 62px; display: grid; grid-template-columns: repeat(4, 1fr); padding: 4px; border-radius: 31px;
  background: rgba(250, 251, 252, .92); -webkit-backdrop-filter: blur(16px) saturate(1.4); backdrop-filter: blur(16px) saturate(1.4); box-shadow: 0 8px 24px -10px rgba(15, 20, 25, .35), inset 0 0 0 1px rgba(15, 20, 25, .07); }
.cf-tabs button { display: grid; place-items: center; align-content: center; gap: 3px; border-radius: 27px; color: var(--ink); text-align: center; transition: background-color .2s ease-out; }
.cf-tabs button svg { width: 24px !important; height: 24px !important; stroke-width: 1.9 !important; }
.cf-tabs button span { font-size: 11px; font-weight: 600; }
.cf-tabs button[aria-current="page"] { color: var(--tint); background: rgba(15, 20, 25, .07); }

/* Racks */
.cf-seg { display: grid; grid-template-columns: repeat(3, 1fr); padding: 3px; border-radius: 10px; background: #E3E7EB; }
.cf-seg button { height: 30px; border-radius: 8px; text-align: center; font-size: 13px; font-weight: 600; transition: background-color .15s ease-out; }
.cf-seg button[aria-pressed="true"] { background: #fff; box-shadow: 0 1px 3px rgba(15, 20, 25, .15); }
.cf-rack-head { display: flex; justify-content: space-between; align-items: baseline; margin: 14px 0 6px; font-size: 14px; }
.cf-rack-head span { font: 500 12px/1 var(--mono); color: var(--ink2); }
.cf-rack { display: grid; gap: 2px; padding: 4px; border: 3px solid #5B6670; border-radius: 5px; background: #D8DDE2; }
.cf-rack > * { height: calc(var(--h) * 22px + (var(--h) - 1) * 2px); display: flex; align-items: center; gap: 8px; padding: 0 8px; border-radius: 2px; font-size: 12.5px; }
.cf-u { width: 34px; font: 500 11px/1 var(--mono); color: var(--ink2); }
.cf-open { align-items: flex-start !important; padding-top: 4px !important; color: var(--ink2); background: repeating-linear-gradient(135deg, #EEF1F3 0 5px, #E2E6EA 5px 6px); }
.cf-unit { width: 100%; background: #fff !important; border: 1px solid #5B6670 !important; transition: border-color .15s ease-out; }
@media (hover: hover) { .cf-unit:hover { border-color: var(--tint) !important; } }
.cf-unit-name { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; font-weight: 600; }
/* Long model names stay on one line in a 1U row and end in an ellipsis; the full name is still read out. */
.cf-unit-name > span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cf-unit-name::before { flex: none; }
.cf-unit-name::before { content: ""; width: 4px; height: 14px; border-radius: 1px; background: var(--edge); }
.cf-unit-name[data-sys="audio"] { --edge: var(--analog); } .cf-unit-name[data-sys="video"] { --edge: var(--vid); } .cf-unit-name[data-sys="network"] { --edge: var(--dante); } .cf-unit-name[data-sys="general"] { --edge: var(--gen); }
.cf-unit-code { font: 500 11px/1 var(--mono); color: var(--ink2); }
.cf-unit-name em { font-style: normal; font-weight: 500; color: var(--ink2); }
/* A tall unit (an 8U MixRack) keeps its label on its top row, like a faceplate. */
.cf-unit:not([style*="--h:1;"]):not([style$="--h:1"]) { align-items: flex-start !important; padding-top: 4px !important; }

/* Floor plan */
.cf-plan { position: relative; }
.cf-plan svg { display: block; width: 100%; height: auto; }
.cf-plan-wall { fill: #fff; stroke: #5B6670; stroke-width: 3; }
.cf-plan-stage { fill: #E6EAEE; stroke: #9AA5AF; stroke-width: 1.5; }
.cf-plan-seat { stroke: #C9D0D6; stroke-width: 7; stroke-linecap: round; }
.cf-plan-booth { fill: #E6EAEE; stroke: #9AA5AF; stroke-width: 1.5; }
.cf-plan-label { font: 800 11px var(--display); font-stretch: 76%; letter-spacing: .1em; fill: var(--ink2); text-anchor: middle; }
.cf-pocket { position: absolute; width: 34px; height: 34px; transform: translate(-50%, -50%); display: grid; place-items: center; text-align: center !important; border-radius: 6px; background: #fff !important;
  border: 2px solid var(--rail) !important; font: 600 12px/1 var(--mono) !important; transition: background-color .15s ease-out; }
.cf-pocket[aria-pressed="true"] { background: var(--rail) !important; color: #fff !important; }

/* Assets */
.cf-dark { position: sticky; top: 0; z-index: 2; padding: 4px 16px 12px; background: var(--rail); color: #fff; }
.cf-search { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px; border-radius: 19px; background: rgba(255, 255, 255, .12); color: #C9D2D9; }
.cf-search svg { width: 17px !important; height: 17px !important; }
.cf-search input { flex: 1; min-width: 0; height: 100%; border: 0; background: none; color: #fff; font: 15px var(--body); outline: none; }
.cf-search input::placeholder { color: #9AA5AF; }
.cf-search input::-webkit-search-cancel-button { filter: invert(1); }
.cf-search:focus-within { box-shadow: 0 0 0 2px var(--tint); }
.cf-dark-title { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; }
.cf-dark-title h3 { margin: 0; font: 900 30px/1 var(--display); font-stretch: 66%; text-transform: uppercase; letter-spacing: .02em; }
.cf-plan-card { width: 100%; display: flex; align-items: center; gap: 10px; padding: 14px 16px; margin-bottom: 18px; background: #fff !important; border-bottom: 1px solid var(--hair) !important; }
.cf-plan-card > span { flex: 1; display: grid; gap: 7px; }
.cf-plan-card b { font: 800 15px/1 var(--display); font-stretch: 78%; text-transform: uppercase; letter-spacing: .04em; }
.cf-chips { display: flex; align-items: center; gap: 5px; }
.cf-chips .cf-plate { min-width: 0; height: 21px; font-size: 11.5px; padding: 0 5px; }
.cf-chips em { font-style: normal; font-weight: 600; margin-right: 6px; }
.cf-plan-card small { font: 500 11.5px/1 var(--mono); color: var(--ink2); }
.cf-rail { display: flex; justify-content: space-between; align-items: center; padding: 8px 16px; background: var(--rail); color: #fff; font: 800 15px/1 var(--display); font-stretch: 74%; letter-spacing: .08em; text-transform: uppercase; }
.cf-loc { padding: 16px 16px 6px; font: 500 11.5px/1 var(--mono); letter-spacing: .08em; color: var(--ink2); text-transform: uppercase; }
.cf-row { width: 100%; display: grid; grid-template-columns: auto 1fr auto 14px; gap: 10px; align-items: center; min-height: 56px; padding: 8px 12px 8px 16px; background: #fff !important; border-bottom: 1px solid var(--hair) !important; transition: background-color .12s ease-out; }
@media (hover: hover) { .cf-row:hover { background: #F7F9FA !important; } }
.cf-row-name { display: grid; gap: 2px; min-width: 0; }
.cf-row-name b { font: 800 14.5px/1.1 var(--display); font-stretch: 80%; }
.cf-row-name small { font: 500 11.5px/1.2 var(--mono); color: var(--ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cf-row-fig { text-align: right; font: 600 11.5px/1.3 var(--mono); }
.cf-row-fig em { display: block; font-style: normal; color: var(--giga); font-size: 11px; letter-spacing: .03em; }
.cf-empty { padding: 32px 20px; text-align: center; color: var(--ink2); }

/* One asset, replacement: grouped cards */
.cf-card { margin: 0; padding: 0; background: #fff; border-radius: 16px; overflow: hidden; }
.cf-hero-card { display: grid; justify-items: start; gap: 8px; padding: 16px; }
.cf-hero-card .cf-plate { height: 30px; font-size: 16px; min-width: 96px; }
.cf-hero-card h4 { margin: 0; font: 800 24px/1.05 var(--display); font-stretch: 70%; }
.cf-imported { display: inline-flex; align-items: center; gap: 6px; font: 600 11px/1 var(--mono); color: var(--giga); letter-spacing: .04em; }
.cf-group h5 { margin: 0 0 6px 16px; font: 600 15px/1.2 var(--body); color: var(--ink2); }
dl.cf-card > div { display: flex; justify-content: space-between; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--hair); font-size: 15px; }
dl.cf-card > div:first-child { border-top: 0; }
dl.cf-card dd { margin: 0; color: var(--ink2); text-align: right; }
dl.cf-card dd.cf-red { color: var(--red); }
.cf-link { width: 100%; display: flex !important; align-items: center; gap: 10px; padding: 14px 16px !important; color: var(--tint) !important; font-size: 15px; }
.cf-link svg { width: 20px !important; height: 20px !important; }
.cf-cables { list-style: none; }
.cf-cables li { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: center; padding: 10px 14px; border-top: 1px solid var(--hair); font-size: 13.5px; font-weight: 600; }
.cf-cables li:first-child { border-top: 0; }
.cf-chart { display: flex; align-items: stretch; gap: 4px; height: 190px; padding: 14px 10px 8px; }
.cf-chart button { flex: 1; display: grid; grid-template-rows: 1fr auto; gap: 6px; border-radius: 6px; padding: 0 1px; transition: background-color .15s ease-out; }
.cf-chart button[aria-pressed="true"] { background: #EDF3FF; }
.cf-col { align-self: end; height: calc(var(--v) * 100%); min-height: 3px; border-radius: 3px 3px 0 0; background: var(--tint); transition: filter .15s ease-out; }
.cf-col-red { background: var(--red); }
@media (hover: hover) { .cf-chart button:hover .cf-col { filter: brightness(1.1); } }
.cf-bar-label { font: 500 11px/1 var(--mono); color: var(--ink2); text-align: center; }
.cf-chart button[aria-pressed="true"] .cf-bar-label { color: var(--ink); font-weight: 600; }
.cf-due .cf-row:last-child { border-bottom: 0 !important; }


/* Import review */
.cf-dark-tools { display: flex; justify-content: flex-end; margin: -2px 0 8px; }
.cf-round-dark { width: 36px !important; height: 36px !important; background: rgba(255, 255, 255, .12) !important; box-shadow: none !important; }
.cf-round-dark svg { stroke: #fff !important; width: 18px !important; height: 18px !important; stroke-width: 1.8 !important; }
.cf-files > div { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--hair); }
.cf-files > div:first-child { border-top: 0; }
.cf-files svg { width: 22px !important; height: 22px !important; color: var(--tint); stroke-width: 1.7 !important; }
.cf-files span { display: grid; gap: 2px; }
.cf-files b { font-weight: 600; font-size: 14.5px; }
.cf-files small { font: 500 11.5px/1.2 var(--mono); color: var(--ink2); }
.cf-read { margin: -8px 4px 0; font: 500 11.5px/1.3 var(--mono); color: var(--ink2); }
.cf-pick { width: 100%; display: grid; grid-template-columns: 22px auto 1fr; gap: 10px; align-items: center; min-height: 54px; padding: 8px 14px; border-top: 1px solid var(--hair) !important; }
.cf-pick:first-child { border-top: 0 !important; }
.cf-check { width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid #A4ADB5; display: grid; place-items: center; transition: background-color .15s ease-out, border-color .15s ease-out; }
.cf-pick[aria-pressed="true"] .cf-check { background: var(--tint); border-color: var(--tint);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12.5 4 4 8-9'/%3E%3C/svg%3E"); background-size: 14px; background-position: center; background-repeat: no-repeat; }
.cf-pick[aria-pressed="false"] .cf-row-name, .cf-pick[aria-pressed="false"] .cf-plate { opacity: .45; }
.cf-import-bar { position: sticky; bottom: 80px; padding: 12px 16px 0; background: linear-gradient(rgba(241, 243, 245, 0), var(--g) 30%); }
.cf-add { width: 100%; height: 48px; border-radius: 24px; background: var(--tint) !important; color: #fff !important; text-align: center !important; font-weight: 600 !important; font-size: 15px !important; }
.cf-add:disabled { opacity: .4; cursor: default; }

/* ---------- Phones and tablets ---------- */
.nowrap { white-space: nowrap; }
.nav .btn { white-space: nowrap; }
.iphone-open { display: none; }
.demo-full { position: fixed; inset: 0; width: 100%; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: #F1F3F5; overflow: hidden; }
.demo-full::backdrop { background: #0F1419; }
.demo-slot { position: absolute; inset: 0; }
html.demo-open { overflow: hidden; }
.demo-close { position: absolute; z-index: 10; top: calc(env(safe-area-inset-top, 0px) + 8px); right: max(12px, env(safe-area-inset-right, 0px)); min-height: 40px; padding: 0 16px; border: 0; border-radius: 20px;
  background: #16202A; color: #fff; font: 600 15px/1 var(--body); cursor: pointer; }
/* In full screen the real phone's own status bar stands in for the drawn one. */
.demo-full .iphone-screen { height: 100%; border-radius: 0; }
.demo-full .cf-status { height: calc(env(safe-area-inset-top, 0px) + 56px); padding: 0; color: transparent; }
.demo-full .cf-status * { visibility: hidden; }
.demo-full .cf-tabs { bottom: calc(10px + env(safe-area-inset-bottom, 0px)); }
.demo-full .cf-sheet { bottom: calc(80px + env(safe-area-inset-bottom, 0px)); }
.demo-full .cf-view { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }

@media (max-width: 700px), (pointer: coarse) {
  /* The drawn phone is a preview: a tap opens the live demo full screen, so a swipe on it scrolls the page. */
  .iphone-open { position: absolute; z-index: 4; inset: 12px; display: flex; align-items: flex-end; justify-content: center; padding: 0 0 46%; border: 0; border-radius: 48px; background: none; cursor: pointer; }
  .iphone-open span { padding: 12px 20px; border-radius: 24px; background: #16202A; color: #fff; font: 600 15px/1 var(--body); box-shadow: 0 10px 24px -8px rgba(15, 20, 25, .5); }
  .dock .cf-view { overflow: hidden; }
  .dock .cf-sheet { display: none; }
  .dock-hint { display: none; }
}
@media (pointer: coarse) {
  .cf-search input { font-size: 16px; }
  .cf-rack > * { height: calc(var(--h) * 36px + (var(--h) - 1) * 2px); }
  .cf-seg button { height: 38px; }
  .cf-pill { height: 38px; }
  .cf-pocket { width: 42px; height: 42px; }
}
@media (max-width: 860px) {
  .nav ul { display: flex; margin: 0 0 0 auto; gap: 0; }
  .nav ul li:not(.keep) { display: none; }
  .nav .btn { margin-left: 1rem; padding: 0 1rem; }
  .hero-copy { padding-block: 2rem 1.25rem; }
  h1 { font-size: clamp(3.1rem, 13vw, 4.2rem); }
  .device { width: 100%; padding: .7rem .85rem; }
  .device b { font-size: 1.05rem; }
  .path .cables, .path .cables i { height: 30px; }
  .path { padding-bottom: 2rem; }
  footer .row { flex-direction: column; align-items: flex-start; gap: .75rem; }
}
@media (max-width: 480px) {
  .email { display: grid; }
  .email code, .email button, .email .btn { width: 100%; text-align: center; justify-content: center; }
  .email code { font-size: .95rem; }
  .pilot { padding: 1.25rem; }
  .plan { padding: 1.15rem; }
  .extra { font-size: .8rem; line-height: 1.45; }
  .amount strong { font-size: 3rem; }
}

/* Review fixes: full-screen demo on phones */
.demo-full .cf-import-bar { bottom: calc(80px + env(safe-area-inset-bottom, 0px)); }
.demo-full:has(.cf.is-dark) .demo-close { background: rgba(255, 255, 255, .16); }
.demo-full .cf { left: env(safe-area-inset-left, 0px); right: env(safe-area-inset-right, 0px); }
.demo-full .cf-status { height: calc(env(safe-area-inset-top, 0px) + 52px); }
.cf-tabs button span { white-space: nowrap; }
@media (max-width: 400px) { .cf-tabs button span { font-size: 10px; } }
@media (max-width: 700px), (pointer: coarse) { .iphone-open { padding-bottom: 28%; } }
@media (max-width: 860px) {
  .device { width: min(100%, 340px); }
  .sec-body.prose { max-width: 36em; }
}

/* Review fixes: demo polish */
.cf-sheet.cf-bar-only { background: none; box-shadow: none; max-height: none; }
.cf.has-sheet:has(.cf-bar-only) .cf-view { padding-bottom: 150px; }
.cf-runs { -webkit-mask-image: linear-gradient(#000 calc(100% - 18px), transparent); mask-image: linear-gradient(#000 calc(100% - 18px), transparent); }
.cf-row .cf-plate, .cf-pick .cf-plate { width: 80px; }
.cf-cable { min-width: 58px; justify-content: center; }
.cf-chart { gap: 2px; padding-inline: 6px; }
.cf-col-v { font: 600 9.5px/1 var(--mono); color: var(--ink2); text-align: center; white-space: nowrap; letter-spacing: -.02em; }
/* Each year is a column: its value, then the bar (to scale, 130px tallest), then the year. */
.cf-chart button { display: flex; flex-direction: column; justify-content: flex-end; align-items: stretch; gap: 3px; }
.cf-chart .cf-col { align-self: stretch; height: calc(var(--v) * 130px); min-height: 0; flex: none; }

footer .legal { margin: 1.25rem 0 0; max-width: 60em; font-size: .8rem; line-height: 1.5; color: var(--ink2); }

/* Wordmark: the three-line mark and the name set in the heading face. */
.logo { display: inline-flex; align-items: center; gap: .55rem; text-decoration: none; color: inherit; }
.logo img { height: 26px; width: auto; }
.wordmark { font: 800 1.35rem/1 var(--display); font-stretch: 70%; letter-spacing: .05em; color: var(--booth-ink); }
.logo-foot img { height: 20px; }
.logo-foot .wordmark { font-size: 1.05rem; color: var(--ink); }
