/* ─────────────────────────────────────────────────────────────
   BIMspection — marketing site
   Palette and wordmark geometry are lifted from the app, not
   re-invented. See brand/README.md and frontend/src/App.css.

   Two golds and they are NOT interchangeable:
     #C9A227  screen / dark grounds
     #8C6D1F  print / light grounds
   Gold is reserved for primary actions and active states, so the
   one glowing thing on the page is the thing worth pressing.
   ───────────────────────────────────────────────────────────── */

:root {
  --gold:       #C9A227;
  --gold-deep:  #8C6D1F;
  --gold-dim:   #7A6320;
  --warm-black: #100E0A;
  --ink:        #17140E;
  --ink-2:      #1F1B13;
  --line:       #2E2819;
  --chalk:      #F4EFE2;
  --muted:      #CFC8B6;
  --muted-2:    #8F8873;
  --paper:      #FBF8F1;

  /* Severity colours carry MEANING, not identity. They match the
     FCI swatches in the app and must not be re-themed. */
  --fci-darkgreen:  #1f7a3d;
  --fci-lightgreen: #63c163;
  --fci-yellow:     #ffdd00;
  --fci-orange:     #f08c22;
  --fci-red:        #d63b2f;

  --max: 1180px;
  --radius: 10px;
  --font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--warm-black);
  color: var(--chalk);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* ── Wordmark ──────────────────────────────────────────────────
 * The letters are the typeface's own — including the DOTLESS ı —
 * and only the glass is overlaid, so the word cannot drift out of
 * alignment with itself.
 *
 * Constants measured off the rendered face, not estimated:
 *   stem centre       0.1525em from the letter box's left edge
 *                     (NOT 50% — letter-spacing folds into the box)
 *   tittle underside  aligned by UNDERSIDE, not centre: the ring is
 *                     bigger than the dot it replaces, so matching
 *                     centres drops it onto the stem.
 *
 * line-height: 1 on .wordmark-i is load-bearing.
 * ───────────────────────────────────────────────────────────── */
.wordmark {
  display: inline-block;
  font-weight: 800;
  letter-spacing: -0.035em;
  white-space: nowrap;
}
.wordmark-i {
  position: relative;
  display: inline-block;
  line-height: 1;
}
.wordmark-i > svg {
  --d: 0.24em;
  position: absolute;
  overflow: visible;        /* the handle reaches past the viewBox */
  color: var(--gold);
  width:  calc(1.6 * var(--d));
  height: calc(1.5 * var(--d));
  left:   calc(0.1525em - 0.5 * var(--d));
  top:    calc(0.374em - 1.5 * var(--d));
}

/* ── Header / nav ───────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(16, 14, 10, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 66px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  color: var(--chalk);
  flex-shrink: 0;
}
.brand:hover { text-decoration: none; }
.brand svg.brand-icon { color: var(--gold); flex-shrink: 0; }

.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a {
  color: var(--muted);
  padding: 8px 14px;
  border-radius: 7px;
  font-size: 15px;
  font-weight: 500;
}
.nav a:hover { color: var(--chalk); background: var(--ink-2); text-decoration: none; }
.nav a[aria-current="page"] { color: var(--gold); }

/* The one nav item that is an action rather than a destination. Gold is
   reserved for exactly that, so it gets the fill and nothing else does. */
.nav a.nav-cta {
  background: var(--gold);
  color: #1a1508;
  font-weight: 600;
  margin-left: 6px;
  padding: 8px 16px;
}
.nav a.nav-cta:hover { background: #dbb232; color: #1a1508; }
.nav a.nav-cta[aria-current="page"] { color: #1a1508; }

/* ── Pricing ────────────────────────────────────────────────── */
.price-card {
  display: grid;
  grid-template-columns: minmax(0, 260px) minmax(0, 1fr);
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--ink-2);
}
.price-figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 42px 24px;
  text-align: center;
  background: rgba(201, 162, 39, .07);
  border-right: 1px solid var(--line);
}
.price-amount {
  font-size: clamp(2.6rem, 6vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--gold);
  line-height: 1;
}
.price-unit {
  font-size: 13px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted-2);
  line-height: 1.5;
}
.price-body { padding: 34px 32px; }
.price-body h3 { margin-bottom: 14px; }
.price-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

.ticks { list-style: none; margin: 0; padding: 0; }
.ticks li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 15px;
}
.ticks li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .48em;
  width: 9px;
  height: 5px;
  border-left: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
  transform: rotate(-45deg);
}

.nav-toggle {
  display: none;
  margin-left: auto;
  background: var(--ink-2);
  border: 1px solid var(--line);
  color: var(--chalk);
  width: 40px; height: 38px;
  border-radius: 8px;
  align-items: center; justify-content: center;
  cursor: pointer;
  font-size: 17px;
  padding: 0;
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background .15s, border-color .15s, color .15s;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--gold); color: #1a1508; border-color: var(--gold); }
.btn-primary:hover { background: #dbb232; }
.btn-ghost { background: transparent; color: var(--chalk); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--gold-dim); background: var(--ink-2); }

/* ── Hero ───────────────────────────────────────────────────── */
.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
/* The flyer bleeds its photo off the page edge, which works on a fixed
   sheet and does not on the web: a percentage-width panel crops the
   inspector to whatever the viewport leaves, and on a widescreen that is
   an arbitrary slice. The photo stays a fixed-width card beside the copy
   instead, over the fence backdrop. */
.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url("img/hero-garage-dark.jpg?v=45a9857df0");
  background-size: cover;
  /* Tall portrait source whose top third is near-black; sitting low in
     the frame catches the lit deck rather than an empty ceiling. */
  background-position: center 78%;
  opacity: .92;
  /* Genuinely underexposed — without the lift the concrete disappears
     behind the scrim entirely. */
  filter: brightness(1.5) contrast(1.04);
}
/* Ramps across rather than down: copy sits left, so the right side keeps
   most of the photograph. The vertical pass only seats the band against
   the header and the section below. */
.hero-scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(100deg,
      rgba(16,14,10,.95) 0%,
      rgba(16,14,10,.88) 34%,
      rgba(16,14,10,.55) 68%,
      rgba(16,14,10,.34) 100%),
    linear-gradient(180deg,
      rgba(16,14,10,.72) 0%,
      rgba(16,14,10,0) 26%,
      rgba(16,14,10,0) 72%,
      rgba(16,14,10,.85) 100%);
}
/* Text left, a SMALL inspector photo right, both over the background
   photograph. The image column is a fixed narrow width on purpose: a
   fractional column steals width from the copy, which pushes the
   headline onto a third line and makes the whole band taller. Keeping
   the text column at its original width keeps the hero its original
   height. */
.hero-grid {
  position: relative;
  display: grid;
  /* Fixed image column, fractional text column. The photo keeps one size
     at every viewport width instead of growing with the screen, which is
     what made the full-bleed version look wrong on a widescreen. */
  grid-template-columns: minmax(0, 1fr) 560px;
  gap: 44px;
  align-items: center;
  padding: 100px 0 92px;
}

.hero-inner {
  position: relative;
  max-width: 720px;
}

/* At 560px the photo would squeeze the copy onto a third line and
   re-inflate the band, so the headline steps down once they share a row. */
.hero-grid h1 { font-size: clamp(2.1rem, 4.1vw, 2.95rem); }
.hero-grid .lede { max-width: 52ch; }

.hero-media img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid rgba(201, 162, 39, .28);
  box-shadow: 0 18px 40px rgba(0, 0, 0, .6);
}
.eyebrow {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
  border-radius: 999px;
  padding: 5px 13px;
  margin-bottom: 22px;
}
h1 {
  font-size: clamp(2.1rem, 5.2vw, 3.5rem);
  line-height: 1.08;
  letter-spacing: -0.022em;
  margin: 0 0 20px;
  font-weight: 800;
}
.lede {
  font-size: clamp(1.05rem, 2vw, 1.24rem);
  color: var(--muted);
  margin: 0 0 32px;
  max-width: 62ch;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-note {
  margin-top: 26px;
  font-size: 14px;
  color: var(--muted-2);
}

/* ── Sections ───────────────────────────────────────────────── */
section { padding: 86px 0; }
.section-alt { background: var(--ink); border-block: 1px solid var(--line); }

.section-head { max-width: 660px; margin-bottom: 48px; }
.section-head.center { margin-inline: auto; text-align: center; }
h2 {
  font-size: clamp(1.65rem, 3.4vw, 2.3rem);
  line-height: 1.18;
  letter-spacing: -0.018em;
  margin: 0 0 14px;
  font-weight: 800;
  /* Where a heading must wrap, split it evenly rather than dropping a
     single orphaned word onto the second line. Ignored by browsers that
     do not support it, which simply get today's behaviour. */
  text-wrap: balance;
}
h3 { font-size: 1.12rem; margin: 0 0 8px; font-weight: 700; letter-spacing: -0.01em; }
.section-head p { color: var(--muted); font-size: 1.05rem; margin: 0; }

/* ── Grids / cards ──────────────────────────────────────────── */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }

.card {
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px;
}
.card p { color: var(--muted); margin: 0; font-size: 15px; }
.card .step-n {
  display: inline-flex;
  align-items: center; justify-content: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(201,162,39,.13);
  border: 1px solid var(--gold-dim);
  color: var(--gold);
  font-weight: 700; font-size: 14px;
  margin-bottom: 14px;
}

/* ── Split feature rows ─────────────────────────────────────── */
.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 48px;
  align-items: center;
}
.split + .split { margin-top: 76px; }
.split-text p { color: var(--muted); }
.split-media img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  width: 100%;
}

/* Photographs here are portrait; at full height they tower over the text
   column and leave a crater above the heading. Cap and crop. Scoped to a
   direct child so the landscape screenshots inside .figure are untouched. */
.split-media > img {
  max-height: 560px;
  object-fit: cover;
  object-position: center 58%;
}

/* Product shots are exports and UI captures on light grounds — they are
   deliberately bright against the page. A warm hairline plus a soft lift
   stops them reading as holes punched in the background. */
.figure { margin: 0; }
.figure img {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid rgba(201, 162, 39, .22);
  box-shadow: 0 14px 34px rgba(0, 0, 0, .5);
  background: var(--paper);
}
.figure figcaption {
  margin-top: 12px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--muted-2);
}

/* The composite export is the strongest thing on the page; a 50/50 split
   shrinks it past the point where the beam and the note are readable. */
.showcase { margin: 0 0 76px; }
.showcase figcaption {
  max-width: 62ch;
  margin-inline: auto;
  text-align: center;
  font-size: 14px;
}

/* The model views in the product shots are blurred so the client's building
   cannot be identified. Say so under the image: unlabelled, the blur reads as
   a rendering fault in the software we are selling. */
.fig-note {
  display: block;
  margin-top: 6px;
  font-size: 12.5px;
  letter-spacing: .03em;
  color: var(--muted-2);
}

/* ── Numbered steps with their own photo ────────────────────────
 * Each step carries the shot of that step, so the sequence is visible
 * before a word is read. An <ol> because the order is the content.
 * ───────────────────────────────────────────────────────────── */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}
.step img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  margin-bottom: 16px;
}
/* The step card's note sits at the foot of the card, so it needs a little more
   air above it than a note tucked straight under a figure. */
.step .fig-note { margin-top: 10px; }

.step-num {
  display: block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .14em;
  color: var(--gold);
  padding-bottom: 9px;
  margin-bottom: 11px;
  border-bottom: 1px solid var(--line);
}
.step h3 { margin-bottom: 7px; }
.step p { color: var(--muted); font-size: 15px; margin: 0; }

/* ── Before/after pair ──────────────────────────────────────────
 * Two shots of the SAME observation at different stages. An <ol> because
 * the order carries meaning: the app capture happens before the export,
 * and a reader who takes them as two unrelated screenshots has missed
 * the point of the section.
 * ───────────────────────────────────────────────────────────── */
.pair {
  list-style: none;
  margin: 0 0 42px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
  gap: 28px;
  align-items: start;
  counter-reset: none;
}
.pair > li { margin: 0; }
/* The two sources are 1.87 and 1.78 wide, which lands their captions on
   different baselines and makes the pair look accidental. Forcing a
   common ratio costs a few percent off the taller one and buys captions
   that line up. */
.pair figure { position: relative; }
.pair figure img { aspect-ratio: 16 / 9; object-fit: cover; }

/* The shots carry no captions, so the order lives in a badge on the
   image itself. Without it the two read as unrelated screenshots rather
   than one observation before and after export. */
.pair-step {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(16, 14, 10, .82);
  border: 1px solid var(--gold-dim);
  color: var(--gold);
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  backdrop-filter: blur(3px);
}

/* Slot for a product screenshot that does not exist yet. Sized to the
   shot it expects so the layout does not jump when the image lands. */
.shot {
  position: relative;
  border: 1px dashed var(--gold-dim);
  border-radius: var(--radius);
  background: var(--ink-2);
  aspect-ratio: 16 / 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-align: center;
  padding: 24px;
  color: var(--muted-2);
  font-size: 14px;
}
.shot strong { color: var(--gold); font-size: 14px; letter-spacing: .04em; text-transform: uppercase; }

/* ── Severity legend ────────────────────────────────────────── */
.swatches { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.swatch {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; color: var(--muted);
  background: var(--warm-black);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 13px 5px 8px;
}
.swatch i { width: 11px; height: 11px; border-radius: 50%; display: block; }

/* ── Callout ────────────────────────────────────────────────── */
.callout {
  border-left: 3px solid var(--gold);
  background: var(--ink-2);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 24px;
  color: var(--muted);
  font-size: 15px;
}
.callout strong { color: var(--chalk); }

/* ── CTA band ───────────────────────────────────────────────── */
.cta-band {
  position: relative;
  overflow: hidden;
  border-block: 1px solid var(--line);
  text-align: center;
}
.cta-band .bg {
  position: absolute; inset: 0;
  background: url("img/condition-spalling.jpg?v=cee73a0170") center/cover;
  opacity: .18;
  filter: grayscale(.3);
}
.cta-band .scrim {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(16,14,10,.9), rgba(16,14,10,.94));
}
.cta-band .wrap { position: relative; padding: 84px 24px; }

/* ── Footer ─────────────────────────────────────────────────── */
.site-footer {
  background: var(--ink);
  border-top: 1px solid var(--line);
  padding: 46px 0 34px;
  font-size: 14px;
  color: var(--muted-2);
}
.footer-row {
  display: flex; flex-wrap: wrap; gap: 30px;
  justify-content: space-between; align-items: flex-start;
  margin-bottom: 28px;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 22px; }
.footer-links a { color: var(--muted); }
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 20px;
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between;
}
.site-footer a:hover { color: var(--gold); }

/* ── About page ─────────────────────────────────────────────── */
.about-grid {
  display: grid;
  grid-template-columns: minmax(240px, 320px) 1fr;
  gap: 52px;
  align-items: start;
}
/* Portrait above, credentials beneath, in one narrow column. */
.about-person { max-width: 440px; }

/* The source is 720x900 now, so this is displayed at half its pixels and
   stays sharp on a retina screen. The old 180px cap existed only because
   the first headshot was 360px and soft. */
.portrait {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  width: 100%;
  max-width: 230px;
  /* Load-bearing. The <img> carries height="360" as an attribute, which
     lands in the cascade as a presentational hint and makes the height
     definite -- and aspect-ratio is ignored the moment height is
     definite, so without this the portrait renders 180 wide by 360 tall.
     Every other image here escapes it by setting height: auto. */
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: var(--ink-2);
  margin-bottom: 18px;
}

.person-name {
  margin: 0 0 22px;
  font-size: 1.22rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--chalk);
}
.creds { list-style: none; padding: 0; margin: 18px 0 0; }
.creds li {
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 15px;
}
.creds li:last-child { border-bottom: 0; }
.creds b { color: var(--chalk); font-weight: 600; }

.prose p { color: var(--muted); }
.prose h2 { margin-top: 44px; }
.prose h2:first-child { margin-top: 0; }

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 820px) {
  .nav {
    display: none;
    position: absolute;
    top: 66px; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--ink);
    border-bottom: 1px solid var(--line);
    padding: 8px;
  }
  .nav.open { display: flex; }
  .nav a { padding: 13px 16px; border-radius: 8px; }
  .nav-toggle { display: inline-flex; }
  .site-header .wrap { position: relative; }

  /* One column, and the photo steps aside: the hero already carries a
     background photograph, and stacking a second pushes the button below
     the fold on a phone. */
  .hero-grid { grid-template-columns: 1fr; padding: 76px 0 68px; }
  .hero-media { display: none; }

  /* Stack the price card; a 260px figure column beside body copy is
     unreadable once the row is narrower than about 560px. */
  .price-card { grid-template-columns: 1fr; }
  .price-figure {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    flex-direction: row;
    gap: 14px;
    padding: 26px 24px;
  }
  .price-unit { text-align: left; }
  .price-body { padding: 26px 24px; }

  /* In the drawer the CTA is just another row — a gold pill spanning the
     full width shouts louder than it needs to. */
  .nav a.nav-cta { margin-left: 0; margin-top: 6px; text-align: center; }
  section { padding: 64px 0; }
  .split + .split { margin-top: 52px; }

  /* Smaller on a phone, not larger. This rule used to read
     `.portrait { max-width: 320px }`, left over from the two-column About
     layout where the portrait filled its column -- and because it sits in
     a media query it quietly beat the 180px set above it, so the headshot
     grew as the screen shrank. */
  .portrait { max-width: 175px; }
}

/* Users who ask for less motion get less motion. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* ── Licence portal ────────────────────────────────────────────
   Sign in, register, and the signed-in downloads page. */

.portal { max-width: 470px; }
.portal-wide { max-width: 820px; }

.field { display: block; margin-bottom: 16px; }

.field > span {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
}

.field input {
  width: 100%;
  padding: 11px 13px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--warm-black);
  color: var(--chalk);
  font-family: inherit;
  font-size: 15px;
}

.field input:focus {
  outline: none;
  border-color: var(--gold);
}

.field small {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted-2);
}

.field-key input {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.form-note {
  margin-top: 20px;
  font-size: 14px;
  color: var(--muted-2);
  text-align: center;
}

.form-note button {
  background: none;
  border: 0;
  padding: 0;
  color: var(--gold);
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
}

/* Feedback. Assertive colours, deliberately outside the brand ramp because
   they carry meaning rather than identity - same rule as the FCI swatches. */
.flash {
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 14.5px;
  line-height: 1.5;
  margin-bottom: 18px;
  border: 1px solid;
}

.flash-error { background: rgba(214, 59, 47, .10); border-color: rgba(214, 59, 47, .45); color: #f0b3ad; }
.flash-ok    { background: rgba(99, 193, 99, .10); border-color: rgba(99, 193, 99, .40); color: #b6e2b6; }

.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-block { width: 100%; }

/* Signed-in account summary */
.licence-card {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 18px 26px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ink);
  margin-bottom: 28px;
}

.licence-item .k {
  display: block;
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted-2);
  margin-bottom: 4px;
}

.licence-item .v {
  font-size: 15.5px;
  color: var(--chalk);
  word-break: break-word;
}

.licence-item .v code {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 14.5px;
  color: var(--gold);
}

.release-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 12px;
}

.release-meta { font-size: 13.5px; color: var(--muted-2); margin-top: 4px; }

.release-hash {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 11.5px;
  color: var(--muted-2);
  word-break: break-all;
  margin-top: 6px;
}

.account-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 22px;
}

.account-bar .who { font-size: 14.5px; color: var(--muted); }

/* ── Admin licence panel ───────────────────────────────────────
 * Only ever rendered for role=admin. Built from the same row the releases
 * list uses, so the one page a signed-in admin looks at does not grow a
 * second visual language for the half of it only they can see.
 * ───────────────────────────────────────────────────────────── */
.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0 18px;
}

.admin-row { align-items: flex-start; }

/* Every row's text block claims the same slack, so the controls wrap at one
   width for all of them. Left to size themselves, a row with a short org name
   keeps its controls on the first line while the row above has dropped them to
   a second, and the list reads as ragged rather than tabular. */
.admin-row > div:first-child { flex: 1 1 340px; }

.admin-key {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 14px;
  letter-spacing: .5px;
  color: var(--gold);
  margin-top: 7px;
}

/* Bottom-aligned: the controls carry labels of their own, and aligning on
   the boxes rather than the labels keeps the row reading as one line. */
.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
}

.admin-cell { display: block; }

.admin-cell > span {
  display: block;
  font-size: 11.5px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted-2);
  margin-bottom: 4px;
}

.admin-input {
  width: 94px;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--warm-black);
  color: var(--chalk);
  font-family: inherit;
  font-size: 14px;
}

select.admin-input { width: 124px; }
.admin-input:focus { outline: none; border-color: var(--gold); }
.admin-save { padding: 9px 16px; font-size: 14px; }

.admin-issued {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.admin-issued code {
  font-family: ui-monospace, "Cascadia Mono", Consolas, monospace;
  font-size: 16px;
  letter-spacing: 1px;
}

.admin-issued .btn { padding: 6px 12px; font-size: 13.5px; }
