/* ============================================================
   PRIMENESS — /apps (Primeness Deck and the apps inside it)
   Loads after styles.css + service.css and reuses their tokens and
   primitives (.container, .btn, .eyebrow, .sv-*). Dark only: volt
   lime is only ever used on black.
   ============================================================ */

body.ap { background: var(--bg); }

/* reveals (assets/js/apps.js adds .is-in; no JS = everything shown) */
html:not(.js) .ap [data-reveal] { opacity: 1; transform: none; }

/* ---------- hero ---------- */
.ap-hero { position: relative; overflow: hidden; padding-block: clamp(44px, 8vh, 96px) clamp(40px, 6vh, 72px); border-bottom: 1px solid var(--line); }
.ap-hero .sv-hero__veil { background: linear-gradient(180deg, rgba(10,10,11,.88) 0%, rgba(10,10,11,.72) 50%, rgba(10,10,11,.96) 100%); }
.ap-hero__inner { position: relative; z-index: 2; }
.ap-hero__top { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(24px, 4vw, 64px); align-items: end; }
.ap-title { font: 700 clamp(36px, 6vw, 76px)/1.02 var(--font-display); letter-spacing: -.03em; color: var(--white); }
.ap-title .ap-kick { display: flex; width: fit-content; max-width: 100%; margin-bottom: 20px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 100px;
  font: 600 12px/1.35 var(--font-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--ink); background: rgba(255,255,255,.02); }
.ap-title .ap-kick::before { content: ""; flex: none; width: 8px; height: 8px; margin: 3px 10px 0 0; border-radius: 50%; background: var(--volt); box-shadow: 0 0 10px var(--volt-glow); }
.ap-title .ap-line { display: block; }
.ap-lead { max-width: 56ch; color: #c9c9cf; font-size: clamp(16.5px, 1.6vw, 19px); line-height: 1.65; }
.ap-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.ap-pills li { padding: 8px 13px; border: 1px solid var(--line); border-radius: 100px; font: 500 12px/1.3 var(--font-mono); letter-spacing: .04em; color: var(--muted); background: rgba(10,10,11,.6); }
.ap-pills li::before { content: "●"; margin-right: 8px; color: var(--volt); font-size: 9px; vertical-align: 1px; }
.ap-hero .sv-cta { margin-top: 26px; }
.ap-cap { margin-top: 16px; font: 500 12px/1.4 var(--font-mono); color: var(--faint); }

.ap-stage { position: relative; margin-top: clamp(32px, 5vw, 60px); padding-bottom: clamp(16px, 3vw, 36px); }
.ap-stage .ap-laptop { width: 78%; }
.ap-stage .ap-phone { position: absolute; right: 2%; bottom: 0; width: 21%; }
@media (max-width: 900px) { .ap-hero__top { grid-template-columns: 1fr; align-items: start; } }
@media (max-width: 600px) {
  .ap-stage .ap-laptop { width: 100%; }
  .ap-stage .ap-phone { position: relative; right: auto; width: min(64vw, 260px); margin: -18% 0 0 auto; }
}

/* app index chips */
.ap-index { display: flex; flex-wrap: wrap; gap: 10px; margin-top: clamp(28px, 4vw, 44px); }
.ap-index a, .ap-index span { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--bg-2); font: 600 14.5px/1.2 var(--font-display); color: var(--white); transition: border-color .25s, background .25s; }
.ap-index a:hover { border-color: var(--volt); background: #17171b; }
.ap-index img { width: 34px; height: 34px; border-radius: 9px; }
.ap-index .is-soon { color: var(--muted); border-style: dashed; padding-left: 14px; }
.ap-index .is-soon em { font: 600 10.5px/1 var(--font-mono); letter-spacing: .14em; color: var(--volt); }

/* ---------- device frames ---------- */
.ap-phone { position: relative; padding: 2.2%; border-radius: 15% / 7%; background: #050506; border: 1px solid #34343a;
  box-shadow: 0 34px 70px -26px rgba(0,0,0,.95), 0 0 0 1px rgba(255,255,255,.06) inset; }
.ap-phone img { display: block; width: 100%; height: auto; aspect-ratio: 1170 / 2532; object-fit: cover; object-position: top; border-radius: 13% / 6%; background: #0a0a0b; }
.ap-laptop__screen { padding: 1.4% 1.4% 1.6%; border-radius: 14px 14px 4px 4px; background: #050506; border: 1px solid #2e2e34;
  box-shadow: 0 40px 90px -40px rgba(0,0,0,.95), 0 0 0 1px rgba(255,255,255,.03) inset, 0 0 70px -30px rgba(191,255,0,.30); }
.ap-laptop__screen img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; object-position: top left; background: #0a0a0b; }
.ap-laptop__base { height: clamp(8px, 1.2vw, 14px); margin: 0 -6%; border-radius: 2px 2px 14px 14px / 2px 2px 100% 100%;
  background: linear-gradient(180deg, #34343a 0%, #1b1b1f 55%, #0c0c0e 100%); border: 1px solid #2c2c32; border-top-color: #45454c; }

/* ---------- one section per app ---------- */
.ap-app { padding-block: clamp(56px, 8vw, 104px); border-bottom: 1px solid var(--line); scroll-margin-top: 70px; }
.ap-app--alt { background: var(--bg-1); }
.ap-app__grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.ap-app--flip .ap-app__copy { order: 2; }
.ap-app__head { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.ap-app__icon { flex: none; width: 64px; height: 64px; border-radius: 16px; box-shadow: 0 0 0 1px rgba(191,255,0,.18), 0 16px 36px -16px rgba(191,255,0,.35); }
.ap-app__head .eyebrow { margin: 0; }
.ap-app__copy .sv-h2 { margin-bottom: 14px; }
.ap-app__copy > p { color: #c9c9cf; line-height: 1.7; max-width: 56ch; }
.ap-points { display: grid; gap: 10px; margin-top: 22px; }
.ap-points li { position: relative; padding: 14px 16px 14px 42px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg-2); color: var(--ink); font-size: 15.5px; line-height: 1.55; }
.ap-points li::before { content: ""; position: absolute; left: 17px; top: 21px; width: 8px; height: 8px; border: 1.5px solid var(--volt); transform: rotate(45deg); }
.ap-note { margin-top: 14px; font: 500 12.5px/1.5 var(--font-mono); color: var(--muted); }
.ap-app__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

/* media: a laptop with a phone over it, or two/three phones */
.ap-media { position: relative; }
.ap-media--desk { padding-bottom: 8%; }
.ap-media--desk .ap-laptop { width: 88%; }
.ap-media--desk .ap-phone { position: absolute; right: 0; bottom: 0; width: 25%; }
.ap-media--duo { display: flex; justify-content: center; align-items: flex-start; gap: 5%; }
.ap-media--duo .ap-phone { width: 42%; max-width: 280px; }
.ap-media--duo .ap-phone:nth-child(2) { margin-top: 12%; }
.ap-media--trio { display: flex; justify-content: center; align-items: flex-start; gap: 4%; }
.ap-media--trio .ap-phone { width: 31%; max-width: 230px; }
.ap-media--trio .ap-phone:nth-child(2) { margin-top: 10%; }
.ap-media--trio .ap-phone:nth-child(3) { margin-top: 20%; }
.ap-media figcaption { margin-top: 14px; text-align: center; font: 500 12px/1.4 var(--font-mono); color: var(--faint); }
@media (max-width: 900px) {
  .ap-app__grid { grid-template-columns: 1fr; }
  .ap-app--flip .ap-app__copy { order: 0; }
}
@media (max-width: 560px) {
  .ap-media--trio .ap-phone:nth-child(3) { display: none; }
  .ap-media--trio .ap-phone { width: 46%; }
  .ap-media--desk .ap-laptop { width: 100%; }
  .ap-media--desk .ap-phone { width: 30%; right: -2%; }
}

/* coming soon */
.ap-soon { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 24px; padding: 22px 24px; border: 1px dashed rgba(255,255,255,.16); border-radius: 16px;
  background: repeating-linear-gradient(135deg, rgba(255,255,255,.015) 0 10px, transparent 10px 20px); }
.ap-soon__glyph { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 14px; border: 1px solid var(--line); color: var(--muted); background: #0c0c0e; }
.ap-soon h3 { font: 600 20px/1.2 var(--font-display); color: #d9d9de; }
.ap-soon p { margin-top: 4px; color: var(--muted); font-size: 15px; }
.ap-soon__tag { margin-left: auto; padding: 7px 12px; border: 1px solid rgba(191,255,0,.5); border-radius: 100px; font: 700 11px/1 var(--font-mono); letter-spacing: .16em; color: var(--volt); }
.ap-soonsec { padding-block: clamp(28px, 4vw, 44px); border-bottom: 1px solid var(--line); }

/* built for the field */
.ap-field { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 28px; }
.ap-field li { padding: 22px 20px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg-2); }
.ap-field svg { width: 30px; height: 30px; color: var(--volt); margin-bottom: 14px; }
.ap-field h3 { font: 600 17.5px/1.25 var(--font-display); color: var(--white); }
.ap-field p { margin-top: 6px; color: var(--muted); font-size: 15px; line-height: 1.55; }
@media (max-width: 980px) { .ap-field { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .ap-field { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
  .ap [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* ===== SITE-1022 review fixes (10/22/2026) ===== */
/* the laptop base stays inside the screen width on phones */
@media (max-width: 600px) { .ap-laptop__base { margin-inline: -2.5%; } }
.svc-strip__h--next { margin-left: 14px; }

/* GETDECK_V1 (10/22): download button + clean mobile layout */
.ap-get-hint { margin-top: 12px; font: 13px/1.5 var(--font-mono); color: var(--muted); max-width: 46ch; }
.ap-get-hint b { color: var(--white); font-weight: 600; }
@media (max-width: 640px) {
  .sv-cta, .ap-app__cta { display: grid; grid-template-columns: 1fr; gap: 10px; }
  .sv-cta .btn, .ap-app__cta .btn { width: 100%; justify-content: center; min-height: 54px; }
  .ap-index { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .ap-index a, .ap-index span { display: flex; width: 100%; min-height: 58px; padding: 8px 10px 8px 8px; font-size: 14px; line-height: 1.2; }
  .ap-index a:first-child { grid-column: 1 / -1; border-color: var(--volt); background: #121309; }
  .ap-index .is-soon { justify-content: center; }
  .ap-index img { flex: 0 0 34px; }
}
@media (max-width: 640px) {
  .ap-pills { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .ap-pills li { min-width: 0; justify-content: center; text-align: center; font-size: 11px; letter-spacing: .02em; padding: 9px 8px; white-space: normal; line-height: 1.3; }
  .ap-hero__top > div, .sv-cta, .ap-index { min-width: 0; }
  .ap-index { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
