:root {
  /* ============================================================
     DARK PREMIUM — "illuminated technical manuscript".
     A warm ink-navy ground (NOT pure black, NOT the cold
     near-black+neon cliche), gilded Art Nouveau ornament as
     structure, and two desaturated heritage accents lifted from
     the original blue #1D4E89 + amber #B5730B so they hold AA on
     dark. No red/green pairing anywhere (colorblind-safe).
     ============================================================ */

  /* Layered dark grounds — elevation reads as a LIGHTER surface,
     not just a shadow (dark-UI best practice). */
  --ground:    #0F1720;      /* base ink-navy, warm-leaning */
  --ground-2:  #16202C;      /* alternating raised band */
  --surface:   #1B2733;      /* elevated card */
  --surface-2: #22303E;      /* card inner / hover lift */

  /* Text on dark — light neutrals for body (AA+), never gold. */
  --ink-hi:   #EFF3F8;       /* headings / high emphasis */
  --ink:      #CAD4DF;       /* body */
  --ink-soft: #97A6B6;       /* captions, muted */

  /* Heritage accents (desaturated for dark, AA-safe). */
  --gild:      #D9A441;      /* brass/gold — accents + large text ONLY */
  --gild-deep: #A97B2C;      /* gilding shadow tone for ornament */
  --gild-glow: rgba(217,164,65,.28);
  --azure:     #7EA9DB;      /* blue #1D4E89 lifted — links, large accent */
  --azure-soft: rgba(126,169,219,.16);

  --border:        rgba(217,164,65,.22);   /* thin gilt hairline */
  --border-cool:   rgba(160,180,200,.14);  /* neutral card edge */

  --s-1: .5rem;  --s-2: .75rem; --s-3: 1rem;  --s-4: 1.5rem;
  --s-5: 2rem;   --s-6: 3rem;   --s-7: 5rem;

  --radius: 14px;
  --radius-sm: 9px;

  /* Depth on dark = deep shadow BELOW + faint gilt inner rim ABOVE. */
  --lift:  0 1px 0 rgba(255,255,255,.04) inset,
           0 18px 40px -18px rgba(0,0,0,.7),
           0 2px 8px rgba(0,0,0,.4);
  --lift-hover: 0 1px 0 rgba(217,164,65,.18) inset,
           0 26px 56px -20px rgba(0,0,0,.78),
           0 0 0 1px var(--border);

  --mono: ui-monospace, "Cascadia Code", "SF Mono", "Segoe UI Mono", Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  position: relative;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* Warm ink-navy ground with a faint gilt bloom up top and a cool
     depth pool at the base — layered, never flat black. */
  background:
    radial-gradient(60rem 30rem at 50% -6rem, rgba(217,164,65,.10) 0%, rgba(217,164,65,0) 62%),
    radial-gradient(70rem 40rem at 50% 120%, #101d2b 0%, rgba(16,29,43,0) 60%),
    linear-gradient(180deg, #0F1720 0%, #0C1219 100%);
  background-attachment: fixed;
}

/* ============================================================
   ART NOUVEAU ORNAMENT — re-inked in GOLD as gilding.
   The corner sprays are structure: they frame the reading field
   from the top-left and bottom-right like an illuminated page.
   A soft gild-glow filter makes the gold read as leafed metal,
   not flat line. (No JS, data-URI SVG only.)
   ============================================================ */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background-repeat: no-repeat;
  background-position: left top, right bottom;
  background-size: 30rem 30rem, 30rem 30rem;
  opacity: .9;
  filter: drop-shadow(0 0 6px var(--gild-glow));
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 300'%3E%3Cg fill='none' stroke-linecap='round'%3E%3Cpath d='M-10 60 C60 40 90 120 70 175 C55 215 95 250 150 245' stroke='%23D9A441' stroke-width='5' opacity='.55'/%3E%3Cpath d='M-10 20 C90 30 150 90 150 190 C150 230 185 255 235 250' stroke='%23A97B2C' stroke-width='3.5' opacity='.5'/%3E%3Cpath d='M70 175 C40 150 5 160 -5 130' stroke='%23D9A441' stroke-width='4' opacity='.5'/%3E%3Cpath d='M150 245 C150 200 180 175 225 180' stroke='%23D9A441' stroke-width='4' opacity='.5'/%3E%3Cg stroke='%23D9A441' stroke-width='3.5' opacity='.62'%3E%3Cpath d='M70 175 C55 160 55 135 78 130 C100 126 108 150 92 165 C82 175 74 178 70 175 Z'/%3E%3Cpath d='M150 245 C140 228 148 205 172 208 C193 210 193 235 174 242 C163 246 154 250 150 245 Z'/%3E%3C/g%3E%3Cg stroke='%23A97B2C' stroke-width='3' opacity='.55'%3E%3Cpath d='M40 95 C25 88 12 96 18 112 C24 126 44 122 48 108'/%3E%3Cpath d='M115 200 C100 194 88 204 96 218 C104 230 122 224 124 210'/%3E%3C/g%3E%3Ccircle cx='83' cy='147' r='7' fill='%23D9A441' opacity='.7'/%3E%3Ccircle cx='173' cy='225' r='7' fill='%23D9A441' opacity='.7'/%3E%3C/g%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 300'%3E%3Cg fill='none' stroke-linecap='round' transform='rotate(180 150 150)'%3E%3Cpath d='M-10 60 C60 40 90 120 70 175 C55 215 95 250 150 245' stroke='%23D9A441' stroke-width='5' opacity='.55'/%3E%3Cpath d='M-10 20 C90 30 150 90 150 190 C150 230 185 255 235 250' stroke='%23A97B2C' stroke-width='3.5' opacity='.5'/%3E%3Cpath d='M70 175 C40 150 5 160 -5 130' stroke='%23D9A441' stroke-width='4' opacity='.5'/%3E%3Cpath d='M150 245 C150 200 180 175 225 180' stroke='%23D9A441' stroke-width='4' opacity='.5'/%3E%3Cg stroke='%23D9A441' stroke-width='3.5' opacity='.62'%3E%3Cpath d='M70 175 C55 160 55 135 78 130 C100 126 108 150 92 165 C82 175 74 178 70 175 Z'/%3E%3Cpath d='M150 245 C140 228 148 205 172 208 C193 210 193 235 174 242 C163 246 154 250 150 245 Z'/%3E%3C/g%3E%3Cg stroke='%23A97B2C' stroke-width='3' opacity='.55'%3E%3Cpath d='M40 95 C25 88 12 96 18 112 C24 126 44 122 48 108'/%3E%3Cpath d='M115 200 C100 194 88 204 96 218 C104 230 122 224 124 210'/%3E%3C/g%3E%3Ccircle cx='83' cy='147' r='7' fill='%23D9A441' opacity='.7'/%3E%3Ccircle cx='173' cy='225' r='7' fill='%23D9A441' opacity='.7'/%3E%3C/g%3E%3C/svg%3E");
}

/* Mobile: no room for full corner sprays outside the column —
   shrink them so gilding frames without crowding text. */
@media (max-width: 60rem) {
  body::before { background-size: 12rem 12rem, 12rem 12rem; opacity: .8; }
}

.wrap {
  max-width: 44rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}

a { color: var(--azure); }

section { padding: var(--s-7) 0; }
@media (max-width: 40rem) { section { padding: var(--s-6) 0; } }

/* Alternating rhythm: raised ink band, edged top and bottom with a
   thin gilt hairline so the seam reads as an illuminated register. */
#archive, .how {
  background: var(--ground-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
/* Sections on the base ground still get an illuminated top seam so
   every register is framed — no untreated gaps between bands. */
.services, .contact { border-top: 1px solid var(--border); }

/* ---- Type scale ---- */
h1 {
  font-family: var(--sans);
  font-size: clamp(2.5rem, 7vw, 3.6rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -.025em;
  color: var(--ink-hi);
  margin: 0 0 var(--s-3);
}
h2 {
  font-size: clamp(1.55rem, 3.6vw, 2rem);
  font-weight: 750;
  line-height: 1.16;
  letter-spacing: -.015em;
  color: var(--ink-hi);
  margin: 0 0 var(--s-3);
}
h3 {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -.005em;
  color: var(--ink-hi);
  margin: 0 0 var(--s-1);
}

p { margin: 0 0 var(--s-3); }

/* ---- Signature: the mono utility eyebrow, sprung from a gilt
   ornamental node. The engineering register (mono, wide-tracked,
   uppercase) sits against the craft register (heavy display) in
   every section head — the whole brief's tension in two lines. ---- */
.eyebrow {
  display: flex;
  align-items: center;
  gap: .7rem;
  font-family: var(--mono);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gild);
  margin: 0 0 var(--s-3);
}
/* Ornamental spring node: a gilt lozenge + flourish stroke, the
   point the section's rule grows from — ornament as structure. */
.eyebrow::before {
  content: "";
  flex: none;
  width: 10px; height: 10px;
  background: var(--gild);
  transform: rotate(45deg);
  box-shadow: 0 0 8px var(--gild-glow);
}
.eyebrow::after {
  content: "";
  width: 2.5rem;
  height: 1px;
  background: linear-gradient(90deg, var(--gild), rgba(217,164,65,0));
}

.sub { color: var(--ink); }

/* ---- Buttons: gilt-edged dark chips (primary) — NOT a neon fill.
   Gold rim + faint warm wash reads as a struck medal, colorblind-safe. ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  background:
    linear-gradient(180deg, rgba(217,164,65,.16), rgba(217,164,65,.06));
  color: var(--gild);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 22px;
  min-height: 44px;
  font-weight: 650;
  font-size: .98rem;
  letter-spacing: .01em;
  transition: background .16s ease, border-color .16s ease,
              transform .12s ease, box-shadow .16s ease, color .16s ease;
}
.btn:hover, .btn:focus-visible {
  background: linear-gradient(180deg, rgba(217,164,65,.28), rgba(217,164,65,.12));
  border-color: var(--gild);
  color: #F4DFAE;
  transform: translateY(-1px);
  box-shadow: 0 0 0 1px var(--border), 0 8px 22px -8px rgba(217,164,65,.4);
}
.btn:focus-visible { outline: 2px solid var(--azure); outline-offset: 3px; }

/* ---- Hero: the thesis, framed by a glowing gilded Mucha arch. ---- */
.hero {
  position: relative;
  overflow: hidden;
  padding-top: clamp(4.5rem, 11vw, 7rem);
  padding-bottom: var(--s-7);
  background: radial-gradient(56rem 24rem at 50% -4rem, rgba(217,164,65,.12) 0%, rgba(217,164,65,0) 66%);
  border-bottom: 1px solid var(--border);
}
/* Gilded whiplash-vine arch springing from both top corners and
   meeting at a blossom overhead — re-inked gold with a leaf glow. */
.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: min(72rem, 110%);
  height: 17rem;
  z-index: 0;
  pointer-events: none;
  background-repeat: no-repeat;
  background-position: center top;
  background-size: 100% 100%;
  filter: drop-shadow(0 0 8px var(--gild-glow));
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 700 220' preserveAspectRatio='none'%3E%3Cg fill='none' stroke-linecap='round'%3E%3Cpath d='M30 220 C30 110 130 30 350 30 C570 30 670 110 670 220' stroke='%23D9A441' stroke-width='4.5' opacity='.6'/%3E%3Cpath d='M60 220 C60 130 160 66 350 66 C540 66 640 130 640 220' stroke='%23A97B2C' stroke-width='2.5' opacity='.45'/%3E%3Cg stroke='%23D9A441' stroke-width='3.5' opacity='.66'%3E%3Cpath d='M350 30 C332 10 300 14 300 38 C300 58 330 62 348 46'/%3E%3Cpath d='M350 30 C368 10 400 14 400 38 C400 58 370 62 352 46'/%3E%3C/g%3E%3Ccircle cx='350' cy='40' r='7' fill='%23D9A441' opacity='.72'/%3E%3Cg stroke='%23D9A441' stroke-width='3.5' opacity='.55'%3E%3Cpath d='M30 220 C10 190 4 150 34 132 C56 120 76 138 66 158'/%3E%3Cpath d='M670 220 C690 190 696 150 666 132 C644 120 624 138 634 158'/%3E%3C/g%3E%3Ccircle cx='40' cy='150' r='6' fill='%23D9A441' opacity='.68'/%3E%3Ccircle cx='660' cy='150' r='6' fill='%23D9A441' opacity='.68'/%3E%3C/g%3E%3C/svg%3E");
}
.hero .wrap { position: relative; z-index: 1; }
@media (max-width: 60rem) {
  .hero::before { height: 10rem; width: 118%; opacity: .9; }
}
.hero .lead {
  font-family: var(--mono);
  font-size: clamp(1rem, 2.3vw, 1.18rem);
  font-weight: 500;
  letter-spacing: .01em;
  color: var(--gild);
  margin: 0 0 var(--s-4);
}
.hero .sub {
  max-width: 40rem;
  font-size: 1.06rem;
  color: var(--ink);
}
.hero .btn { margin-top: var(--s-2); }

/* ---- Cards: elevated dark surfaces (lighter than ground = depth),
   deep shadow + gilt inner rim, gold top-hairline. ---- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--s-4);
  max-width: 58rem;
  margin: var(--s-5) auto 0;
}
.card {
  position: relative;
  background: linear-gradient(180deg, var(--surface) 0%, var(--ground) 140%);
  border: 1px solid var(--border-cool);
  border-radius: var(--radius);
  box-shadow: var(--lift);
  padding: var(--s-4);
  display: flex;
  flex-direction: column;
  transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
.card:hover {
  box-shadow: var(--lift-hover);
  transform: translateY(-3px);
  border-color: var(--border);
}

/* Flagship: a gilt top rule reads as the leading, illuminated piece. */
.flagship .card {
  border-top: none;
}
.flagship .card::before {
  content: "";
  position: absolute;
  top: 0; left: var(--s-4); right: var(--s-4);
  height: 2px;
  background: linear-gradient(90deg, rgba(217,164,65,0), var(--gild), rgba(217,164,65,0));
  box-shadow: 0 0 8px var(--gild-glow);
}
.flagship { padding-bottom: var(--s-6); }

.card img,
.card .media {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-sm);
  display: block;
  margin-bottom: var(--s-3);
  background: var(--ground);
  border: 1px solid var(--border-cool);
}
/* Real screenshot: keep its own aspect, framed dark. */
.card img.media {
  aspect-ratio: auto;
  object-fit: contain;
  padding: var(--s-2);
  background:
    radial-gradient(30rem 12rem at 50% 0, rgba(126,169,219,.08), rgba(126,169,219,0) 70%),
    var(--ground);
}
.card h2 { font-size: 1.42rem; }
.card .case { flex: 1; color: var(--ink); }
.card .btn { align-self: flex-start; margin-top: var(--s-3); }
.card .line { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-3); }
.card .line .btn { margin-top: 0; }

/* Framed empty-state slot (kept for reuse; brightness + glyph, no color meaning). */
.coming-soon {
  width: 100%;
  aspect-ratio: 16 / 10;
  border: 2px dashed var(--border-cool);
  border-radius: var(--radius-sm);
  background:
    repeating-linear-gradient(45deg, rgba(255,255,255,.02) 0 10px, transparent 10px 20px),
    var(--ground);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: var(--s-2);
  color: var(--ink-soft);
  font-size: .95rem; font-weight: 600;
  margin-bottom: var(--s-3);
}
.coming-soon .glyph {
  width: 52px; height: 52px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: var(--surface);
  display: flex; align-items: center; justify-content: center;
}
.coming-soon .glyph svg { display: block; }

/* Footnote: a gilt-marginned aside, in the mono/craft register. */
.footnote {
  color: var(--ink-soft);
  font-family: var(--mono);
  font-size: .84rem;
  line-height: 1.7;
  font-style: normal;
  max-width: 42rem;
  margin: var(--s-5) auto 0;
  padding-left: var(--s-3);
  border-left: 2px solid var(--border);
}

/* Status pill (kept for reuse): brightness + diamond glyph + text, no color meaning. */
.pill {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  align-self: flex-start;
  background: rgba(217,164,65,.12);
  color: var(--gild);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px 13px;
  font-family: var(--mono);
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin: 0 0 var(--s-2);
}

/* ---- Services grid ---- */
.svc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: var(--s-4);
  max-width: 58rem;
  margin: var(--s-5) auto 0;
}
.svc {
  background: var(--surface);
  border: 1px solid var(--border-cool);
  border-radius: var(--radius);
  box-shadow: var(--lift);
  padding: var(--s-4);
  transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
.svc:hover {
  box-shadow: var(--lift-hover);
  transform: translateY(-3px);
  border-color: var(--border);
}
.svc h3 { color: var(--ink-hi); }
.svc p { margin: 0; color: var(--ink); font-size: .98rem; }

/* ---- How I work: gilt lozenge markers spring each line. ---- */
.how ul { padding-left: 0; list-style: none; margin: var(--s-4) 0 0; }
.how li {
  position: relative;
  padding-left: 2rem;
  margin-bottom: var(--s-3);
  color: var(--ink);
}
.how li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .58em;
  width: .62rem;
  height: .62rem;
  background: var(--gild);
  transform: rotate(45deg);
  box-shadow: 0 0 6px var(--gild-glow);
}
.how li strong { color: var(--ink-hi); }

/* ---- Contact ---- */
.contact h2 { max-width: 40rem; }
.contact .btn { margin: var(--s-3) 0; }
.contact .line { color: var(--ink-soft); font-family: var(--mono); font-size: .88rem; }
.contact .line a { color: var(--azure); text-decoration: none; }
.contact .line a:hover { text-decoration: underline; }

footer {
  border-top: 1px solid var(--border);
  padding: var(--s-5) 0;
  color: var(--ink-soft);
  font-family: var(--mono);
  font-size: .82rem;
  letter-spacing: .04em;
}

/* ---- Motion: static by default for anyone who asks. The gild-glow
   is a static filter (no animation), so nothing needs gating beyond
   killing scroll-smoothing + hover transforms. ---- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
  .btn:hover, .card:hover, .svc:hover { transform: none; }
}
