/* =====================================================================
   Print & Apparel Co. — polish layer (loads after base.css + pages.css)
   One idea: "studio plate". Light lives in the product, dark lives in the room.
   ===================================================================== */
:root{
  --ease:cubic-bezier(.2,.7,.2,1);
  --plate-hi:#f4f2ee;   /* lit centre of a product plate  */
  --plate-lo:#c9c4ba;   /* falloff at the edges           */
}

/* ---------- 1. typography: tighter display, calmer body ---------- */
h1,h2,h3{ letter-spacing:-.012em; }
.hero h1{ letter-spacing:-.02em; line-height:.98; }
.hero p.lede{ color:#B9D0D8; font-size:1.12rem; line-height:1.6; }
.sec-head h2, .phead h1{ letter-spacing:-.018em; }
.sec-head p, .phead p{ line-height:1.65; }
body{ font-feature-settings:"kern","liga","tnum" 0; text-rendering:optimizeLegibility; }
.pp, .hat-price b, .pdp-price, .stat .v{ font-variant-numeric:tabular-nums; }

/* ---------- 2. product imagery: replace flat white boxes with a lit studio plate ---------- */
.pcard .sp, .ctile .sp, .scard .sp, .cbtn .sp, .stage .sp, .pdp-view .sp, .mini .sp{
  isolation:isolate; background-color:#fff;
}
.pcard .sp::after, .ctile .sp::after, .scard .sp::after, .cbtn .sp::after,
.stage .sp::after, .pdp-view .sp::after, .mini .sp::after{
  content:""; position:absolute; inset:0; pointer-events:none; z-index:1;
  background:radial-gradient(75% 70% at 50% 42%, var(--plate-hi) 0%, #e3dfd8 55%, var(--plate-lo) 100%);
  mix-blend-mode:multiply;
}
/* the old scan-line on the builder stage lives on .stage::after; keep the sprite one separate */
.stage .sp::after{ animation:none; height:auto; top:0; }
.pcard:hover .sp, .ctile:hover .sp{ transform:scale(1.025); }
.pcard .sp, .ctile .sp{ transition:transform .5s var(--ease); overflow:hidden; }
.pcard, .ctile{ overflow:hidden; }

/* depth under cards */
.pcard, .ctile, .scard{ box-shadow:0 1px 0 rgba(255,255,255,.03) inset, 0 12px 28px -18px rgba(0,0,0,.9); }
.pcard:hover, .ctile:hover{ box-shadow:0 0 0 1px var(--cyan), 0 18px 36px -16px rgba(18,232,251,.28); }
.pcard .pp{ color:#7FF3FF; }

/* a sold-out lead product is a dead end on the home page: soften it */
.pcard .sold{ background:rgba(0,0,0,.78); backdrop-filter:blur(4px); }

/* ---------- 3. hero: atmosphere and a calmer rhythm ---------- */
#rain{ opacity:.3; }  /* glyphs were landing behind the headline and fighting it */
.hero{ padding-block:72px 28px; background:
    radial-gradient(60% 55% at 85% 35%, rgba(18,232,251,.16), transparent 70%),
    radial-gradient(45% 45% at 8% 20%, rgba(243,12,254,.14), transparent 70%),
    linear-gradient(to bottom, transparent 70%, var(--bg) 100%); }
.kicker{ text-transform:uppercase; }
.hero-meta{ margin-top:30px; }
.hero-meta a{ border-bottom:1px solid transparent; transition:border-color .2s, color .2s; }
.hero-meta a:hover{ border-color:var(--cyan); }
.hud-logo{ animation:hudfloat 7s ease-in-out infinite; }
@keyframes hudfloat{ 0%,100%{ transform:translate(-50%,-50%) translateY(0); } 50%{ transform:translate(-50%,-50%) translateY(-5px); } }

/* ---------- 4. consistent panel behaviour ---------- */
.panel{ transition:filter .3s var(--ease); }
.panel:hover{ filter:drop-shadow(0 0 18px rgba(18,232,251,.14)); }
.console{ align-items:stretch; }
.console > .panel{ display:flex; flex-direction:column; }
.console .term-body{ flex:1; min-height:0; }
.mod{ transition:border-color .2s, background .2s, transform .25s var(--ease); }

/* feeds: show exactly 10 lines, never a clipped half-line */
.code{ height:calc(15.5em + 28px); }

/* ---------- 5. stats: one layout for all four tiles ---------- */
.stat{ position:relative; min-height:150px; justify-content:flex-end; }
.stat .gauge{ position:absolute; top:18px; right:18px; width:58px; height:58px; margin:0; }
.gauge .fg{ transition:stroke-dasharray 1.2s var(--ease); }
.stat .v{ letter-spacing:-.01em; }

/* ---------- 6. buttons: tactile, consistent ---------- */
.btn{ transition:box-shadow .2s var(--ease), transform .2s var(--ease), background .2s, color .2s; }
.btn:active{ transform:translateY(0) scale(.985); box-shadow:none; }
.btn-hot{ background-size:140% 100%; background-position:0 0; transition:background-position .5s var(--ease), box-shadow .2s var(--ease), transform .2s var(--ease); }
.btn-hot:hover{ background-position:100% 0; }
.nav-cta{ font-size:.8rem; padding:11px 18px; }

/* ---------- 7. navigation: scroll progress + condensed bar ---------- */
header.topnav{ transition:background .3s, box-shadow .3s; }
header.topnav.scrolled{ background:rgba(5,6,10,.92); box-shadow:0 10px 30px -20px rgba(0,0,0,.9); }
header.topnav.scrolled .nav-inner{ height:58px; }
.nav-inner{ transition:height .3s var(--ease); }
#progress{ position:absolute; left:0; bottom:-1px; height:2px; width:100%; transform-origin:0 50%; transform:scaleX(0);
  background:linear-gradient(90deg,var(--cyan),var(--violet),var(--magenta)); pointer-events:none; }

/* ---------- 8. motion: reveal + route entrance (js/polish.js adds the classes) ---------- */
.rv{ opacity:0; translate:0 18px;
  transition:opacity .7s var(--ease) var(--d,0s), translate .7s var(--ease) var(--d,0s), border-color .15s, transform .15s, filter .3s; }
.rv.in{ opacity:1; translate:0 0; }
main#app.page-in > *{ animation:pgin .5s var(--ease) both; }
@keyframes pgin{ from{ opacity:0; transform:translateY(10px); } to{ opacity:1; transform:none; } }

/* ---------- 9. phones ---------- */
@media (max-width:700px){
  .hero{ padding-block:44px 16px; }
  .hero-cta{ flex-direction:column; align-items:stretch; }
  .hero-cta .btn{ justify-content:center; width:100%; }
  .kicker{ font-size:.68rem; letter-spacing:.1em; }
  /* three stacked feeds is 600px of scrolling before any content: keep the best one */
  .telemetry .panel:nth-child(n+2){ display:none; }
  .stat{ min-height:128px; }
  section{ padding-block:60px; }
  .term-body{ padding:18px; }
}
@media (max-width:900px){
  .console > .panel{ display:block; }
}

/* ---------- 10. accessibility: respect reduced motion in every new layer ---------- */
@media (prefers-reduced-motion:reduce){
  .rv{ opacity:1; translate:none; transition:none; }
  main#app.page-in > *{ animation:none; }
  .hud-logo{ animation:none; }
  .pcard .sp, .ctile .sp{ transition:none; }
  #progress{ display:none; }
}

/* Review watermark (set in js/config.js) */
.watermark{position:fixed;inset:0;pointer-events:none;z-index:90;opacity:.08;background-repeat:repeat;background-position:center;transition:opacity 2s ease}
.watermark.off{opacity:0;transition:none}

/* TM mark: transparent, no frame */
.hud-logo{width:46%;border-radius:0;box-shadow:none;filter:drop-shadow(0 0 14px rgba(18,232,251,.45)) drop-shadow(0 0 28px rgba(243,12,254,.3))}
.brand-mark{width:40px;height:40px;background:transparent;box-shadow:none;border-radius:50%}
.brand-mark img{object-fit:contain}
