/* ==========================================================================
   SL•LIGN 2.0 - Apple Keynote & Scroll-Cinema Design System
   ========================================================================== */

:root {
  --bg-black: #000000;
  --bg-elevated: #0b0b0e;
  --bg-card-dark: #111116;
  --bg-light: #f5f5f7;
  --bg-white: #ffffff;
  --ink-light: #f5f5f7;
  --ink-muted-dark: #a1a1a6;
  --ink-dark: #1d1d1f;
  --ink-muted-light: #6e6e73;
  --line-dark: rgba(255, 255, 255, 0.12);
  --line-light: rgba(0, 0, 0, 0.08);
  --prism: linear-gradient(90deg, #74b2ff 0%, #a58bff 28%, #f472b6 54%, #f4c678 78%, #6ee7b7 100%);
  --prism-soft: linear-gradient(90deg, #8ec5ff 0%, #b8a1ff 30%, #f58ec0 58%, #f6d58f 80%, #86efac 100%);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-pill: 980px;
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  --font-text: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  --nav-h: 52px;
}

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

html {
  background: var(--bg-black);
  color: var(--ink-light);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html.lenis,
html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}

.lenis.lenis-stopped {
  overflow: hidden;
}

body {
  margin: 0;
  font-family: var(--font-text);
  font-size: 16px;
  line-height: 1.5;
  background: var(--bg-black);
  color: var(--ink-light);
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font: inherit;
}

.ap-shell {
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
}

@media (max-width: 640px) {
  .ap-shell {
    width: calc(100% - 28px);
  }
}

/* === 1. Apple Glass Navigation Bar (52px) === */
.ap-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 120;
  height: var(--nav-h);
  background: rgba(10, 10, 12, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
  transition: background-color 0.25s ease, border-color 0.25s ease;
}

.ap-header.is-light {
  background: rgba(251, 251, 253, 0.80);
  border-bottom-color: rgba(0, 0, 0, 0.08);
  color: var(--ink-dark);
}

.ap-header-inner {
  width: min(1220px, calc(100% - 32px));
  height: 100%;
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.ap-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.ap-brand-logo {
  display: block;
  width: 98px;
  height: 22px;
  background-image: url("/assets/sllign-logo-light.svg");
  background-repeat: no-repeat;
  background-position: left center;
  background-size: contain;
}

.ap-header.is-light .ap-brand-logo {
  background-image: url("/assets/sllign-logo-dark.svg");
}

.ap-nav {
  display: none;
  align-items: center;
  gap: 26px;
}

@media (min-width: 960px) {
  .ap-nav {
    display: flex;
  }
}

.ap-nav a {
  font-size: 13px;
  font-weight: 450;
  letter-spacing: -0.01em;
  color: rgba(245, 245, 247, 0.80);
  transition: color 0.16s ease;
  white-space: nowrap;
}

.ap-nav a:hover,
.ap-nav a.active {
  color: #ffffff;
}

.ap-header.is-light .ap-nav a {
  color: rgba(29, 29, 31, 0.72);
}

.ap-header.is-light .ap-nav a:hover,
.ap-header.is-light .ap-nav a.active {
  color: #000000;
}

.ap-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ap-lang-btn {
  height: 28px;
  padding: 0 10px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: #f5f5f7;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background-color 0.16s ease, border-color 0.16s ease;
}

.ap-lang-btn:hover {
  background: rgba(255, 255, 255, 0.14);
}

.ap-header.is-light .ap-lang-btn {
  border-color: rgba(0, 0, 0, 0.14);
  background: rgba(0, 0, 0, 0.04);
  color: var(--ink-dark);
}

.ap-nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  padding: 0 14px;
  border-radius: var(--radius-pill);
  background: #ffffff;
  color: #000000;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  transition: transform 0.16s ease, opacity 0.16s ease;
}

.ap-nav-cta:hover {
  opacity: 0.9;
}

.ap-header.is-light .ap-nav-cta {
  background: #000000;
  color: #ffffff;
}

.ap-burger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

@media (min-width: 960px) {
  .ap-burger {
    display: none;
  }
}

/* Mobile drawer */
.ap-drawer-bg {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 150;
  background: rgba(0, 0, 0, 0.64);
  backdrop-filter: blur(8px);
}

.ap-drawer-bg.open {
  display: block;
}

.ap-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 160;
  width: min(320px, 86vw);
  background: #0b0b0e;
  border-left: 1px solid rgba(255, 255, 255, 0.12);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transform: translateX(100%);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

.ap-drawer.open {
  transform: translateX(0);
}

.ap-drawer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
  margin-bottom: 8px;
}

.ap-drawer-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
  cursor: pointer;
}

.ap-drawer a {
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 550;
  color: #f5f5f7;
}

.ap-drawer a:hover,
.ap-drawer a.active {
  background: rgba(255, 255, 255, 0.10);
}

/* === 2. Apple Buttons === */
.ap-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 24px;
  border-radius: var(--radius-pill);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, opacity 0.18s ease;
  white-space: nowrap;
}

.ap-btn:active {
  transform: scale(0.98);
}

.ap-btn-white {
  background: #ffffff;
  color: #000000;
}

.ap-btn-white:hover {
  background: #e8e8ed;
}

.ap-btn-glass {
  background: rgba(255, 255, 255, 0.10);
  border-color: rgba(255, 255, 255, 0.24);
  color: #ffffff;
  backdrop-filter: blur(12px);
}

.ap-btn-glass:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.42);
}

.ap-btn-dark {
  background: #1d1d1f;
  color: #ffffff;
}

.ap-btn-dark:hover {
  background: #000000;
}

.ap-btn-outline-dark {
  background: transparent;
  border-color: rgba(0, 0, 0, 0.20);
  color: #1d1d1f;
}

.ap-btn-outline-dark:hover {
  background: rgba(0, 0, 0, 0.05);
}

/* === 3. ACT I - Full-Bleed Apple AirPods Pro 3 Hero (100vw x 100svh, Zero Frames) === */
.ap-hero {
  position: relative;
  min-height: 100svh;
  padding-top: var(--nav-h);
  background: #000000;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
}

.ap-hero-stage {
  position: absolute;
  inset: 0;
  z-index: 1;
  background-color: #000000;
  background-image: image-set(
    url("/assets/hero-crystal-poster.webp") type("image/webp"),
    url("/assets/hero-crystal-poster.jpg") type("image/jpeg")
  );
  background-size: contain;
  background-position: center 26%;
  background-repeat: no-repeat;
  will-change: transform, opacity;
}

.ap-hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center 26%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.ap-hero-video.is-ready {
  opacity: 1;
}

.ap-hero-vignette {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.45) 0%,
    rgba(0, 0, 0, 0.0) 18%,
    rgba(0, 0, 0, 0.0) 58%,
    rgba(0, 0, 0, 0.78) 82%,
    rgba(0, 0, 0, 0.96) 100%
  );
}

.ap-pause-btn {
  position: absolute;
  top: calc(var(--nav-h) + 18px);
  right: 22px;
  z-index: 6;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(24, 24, 28, 0.62);
  backdrop-filter: blur(12px);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 11px;
  letter-spacing: 1px;
  transition: background-color 0.16s ease, border-color 0.16s ease;
}

.ap-pause-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.42);
}

.ap-hero-bar {
  position: relative;
  z-index: 4;
  width: min(1320px, calc(100% - 48px));
  margin-inline: auto;
  padding-bottom: clamp(70px, 9vh, 102px);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  will-change: transform, opacity;
}

.ap-hero-left {
  max-width: 780px;
}

.ap-hero-product {
  display: inline-block;
  font-family: var(--font-display);
  font-size: clamp(19px, 1.9vw, 25px);
  font-weight: 650;
  letter-spacing: -0.02em;
  color: rgba(245, 245, 247, 0.92);
  margin-bottom: 10px;
}

.ap-hero-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(40px, 5.6vw, 80px);
  font-weight: 700;
  line-height: 1.03;
  letter-spacing: -0.042em;
  color: #ffffff;
  text-shadow: 0 12px 42px rgba(0, 0, 0, 0.78);
}

.ap-prism-text {
  background: var(--prism-soft);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.ap-hero-sub {
  margin: 16px 0 0;
  max-width: 640px;
  font-size: clamp(16px, 1.5vw, 19.5px);
  line-height: 1.46;
  font-weight: 450;
  color: rgba(245, 245, 247, 0.80);
}

/* Signature AirPods Pro 3 Bottom-Right Price + CTA Capsule */
.ap-price-capsule {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 6px 6px 6px 20px;
  border-radius: var(--radius-pill);
  background: rgba(28, 28, 32, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  flex-shrink: 0;
  margin-bottom: 4px;
}

.ap-price-capsule-val {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
}

.ap-price-capsule-val small {
  font-size: 12.5px;
  font-weight: 450;
  color: rgba(245, 245, 247, 0.68);
  margin-left: 3px;
}

.ap-price-capsule-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  padding: 0 20px;
  border-radius: var(--radius-pill);
  background: #0071e3;
  color: #ffffff;
  font-size: 14.5px;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 0.16s ease, transform 0.16s ease;
}

.ap-price-capsule-btn:hover {
  background: #0077ed;
}

.ap-hero-links-row {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 14px;
  font-weight: 550;
}

.ap-hero-links-row a {
  color: #2997ff;
  transition: opacity 0.15s ease;
}

.ap-hero-links-row a:hover {
  text-decoration: underline;
}

@media (max-width: 900px) {
  .ap-hero {
    min-height: 0;
    height: auto;
    max-height: none;
    justify-content: flex-start;
  }
  .ap-hero-stage {
    position: relative;
    inset: auto;
    width: 100%;
    height: auto;
    aspect-ratio: 800 / 560;
    max-height: 420px;
    background-image: image-set(
      url("/assets/hero-crystal-poster-mob.webp") type("image/webp"),
      url("/assets/hero-crystal-poster-mob.jpg") type("image/jpeg")
    );
    background-size: contain;
    background-position: center center;
  }
  .ap-hero-video {
    object-fit: contain;
    object-position: center center;
  }
  .ap-hero-vignette {
    display: none;
  }
  .ap-hero-bar {
    width: calc(100% - 28px);
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    margin-top: -10px;
    padding-bottom: 30px;
  }
  .ap-hero-product {
    font-size: 16px;
    margin-bottom: 4px;
  }
  .ap-hero-title {
    font-size: 32px;
  }
  .ap-hero-sub {
    font-size: 14px;
    margin-top: 8px;
  }
  .ap-price-capsule {
    padding: 5px 5px 5px 16px;
    gap: 12px;
  }
  .ap-price-capsule-btn {
    height: 36px;
    padding: 0 16px;
    font-size: 14px;
  }
  .ap-pause-btn {
    right: 14px;
    top: calc(var(--nav-h) + 12px);
  }
}

/* === 4. Clean Apple One-Shot Features & Sole 1:1 3D Scroll-Scrub Showcase === */
.ap-feature-band,
.ap-story {
  position: relative;
  background: #000000;
  color: #f5f5f7;
  overflow-x: clip;
}

.ap-cad-track {
  position: relative;
  background: #000000;
  color: #f5f5f7;
}

.ap-feature-band {
  padding: clamp(32px, 4.5vh, 56px) 0;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ap-feature-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.24fr) minmax(0, 0.86fr);
  gap: clamp(32px, 4.5vw, 72px);
  align-items: center;
}

.ap-feature-media {
  position: relative;
  width: 100%;
  aspect-ratio: 5 / 4;
  max-height: min(76svh, 680px);
  background-color: #000000;
  background-size: contain;
  background-position: center center;
  background-repeat: no-repeat;
  overflow: hidden;
}

.ap-media-case {
  background-image: url("/assets/scene-case-5x4-poster.webp");
}

@media (min-width: 901px) {
  .ap-feature-media::after,
  .ap-cad-stage::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 2;
    box-shadow: inset 0 0 28px 14px #000000;
  }
}

.ap-oneshot-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.ap-macro-frame .ap-oneshot-video {
  object-fit: cover;
}

.ap-oneshot-video.is-ready {
  opacity: 1;
}

.ap-replay-btn {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 5;
  padding: 8px 15px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(20, 20, 26, 0.74);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  color: #f5f5f7;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(4px);
  transition: opacity 0.28s ease, transform 0.28s ease, background-color 0.16s ease, border-color 0.16s ease;
}

.ap-replay-btn.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.ap-replay-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.42);
}

.ap-feature-copy h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(32px, 3.7vw, 52px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.038em;
  color: #ffffff;
}

.ap-nw {
  white-space: nowrap;
}

.has-video {
  background-image: none !important;
}

.ap-scrub-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}

/* Tight, Zero-Gap 1:1 3D Scroll-Scrub Sections (No 100svh sticky voids on tall 1080p/1440p screens!) */
.ap-cad-track {
  position: relative;
  height: auto;
  padding: clamp(40px, 5vh, 68px) 0;
  background: #000000;
  color: #f5f5f7;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  overflow-x: clip;
}

.ap-cad-track--case {
  height: auto;
}

.ap-cad-pin {
  position: relative;
  top: auto;
  height: auto;
  width: 100%;
  display: block;
  overflow: visible;
  background: #000000;
}

.ap-cad-track .ap-shell {
  width: min(1260px, calc(100% - 40px));
}

.ap-cad-visual-col {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.ap-cad-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 5 / 4;
  max-height: 620px;
  background-color: #000000;
  background-image: url("/assets/seq-cad-120/f_001.webp");
  background-size: contain;
  background-position: center center;
  background-repeat: no-repeat;
  pointer-events: none;
}

.ap-cad-stage--case {
  background-image: url("/assets/seq-case-3d/f_001.webp?v=32");
}

.ap-cad-meter {
  width: 100%;
  max-width: 480px;
  margin-top: 12px;
}

.ap-cad-meter-labels {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: rgba(245, 245, 247, 0.40);
  margin-bottom: 8px;
}

.ap-cad-meter-labels span {
  transition: color 0.18s ease;
}

.ap-cad-meter-labels span.is-active {
  color: #ffffff;
}

.ap-cad-meter-track {
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.14);
  overflow: hidden;
}

.ap-cad-meter-fill {
  height: 100%;
  width: 100%;
  background: var(--prism-soft);
  transform-origin: left center;
  transform: scaleX(0.02);
  will-change: transform;
}

/* Signature Apple Two-Tone Typography */
.ap-two-tone {
  margin: 16px 0 0;
  font-family: var(--font-display);
  font-size: clamp(18px, 1.55vw, 22px);
  line-height: 1.4;
  font-weight: 550;
  letter-spacing: -0.018em;
  color: rgba(245, 245, 247, 0.62);
}

.ap-two-tone strong {
  color: #ffffff;
  font-weight: 680;
}

.ap-pin-specs {
  margin-top: 24px;
  display: grid;
  gap: 14px;
}

.ap-pin-spec {
  padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.ap-pin-spec strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(24px, 2.2vw, 32px);
  font-weight: 700;
  letter-spacing: -0.028em;
  color: #ffffff;
  line-height: 1.12;
}

.ap-pin-spec span {
  display: block;
  margin-top: 4px;
  font-size: 14.5px;
  line-height: 1.4;
  color: rgba(245, 245, 247, 0.72);
}

/* ACT I.4: Clean One-Shot Macro Feature (Zero Sticky, Tight Rhythm) */
.ap-story--macro {
  padding: clamp(32px, 4.5vh, 52px) 0 clamp(44px, 5.5vh, 72px);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ap-story-intro {
  text-align: center;
  max-width: 900px;
  padding: 0 0 clamp(18px, 2.2vw, 28px);
}

.ap-story-intro h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(34px, 4.8vw, 64px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.04em;
  color: #ffffff;
}

.ap-story-lead {
  margin: 16px auto 0;
  max-width: 680px;
  font-size: clamp(16.5px, 1.55vw, 20px);
  line-height: 1.48;
  color: rgba(245, 245, 247, 0.72);
}

.ap-beat-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 12px;
  color: rgba(245, 245, 247, 0.74);
}

.ap-beat-kicker::before {
  content: "";
  width: 18px;
  height: 1.5px;
  border-radius: 2px;
  background: var(--prism-soft);
  flex-shrink: 0;
}

.ap-macro-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 620px;
  border-radius: 26px;
  overflow: hidden;
  background-color: #000000;
  background-image: url("/assets/scene-macro-poster.webp");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.ap-macro-specs {
  width: 100%;
  margin-top: 34px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.ap-macro-card {
  padding: 18px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
}

.ap-macro-card strong {
  display: block;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.ap-macro-card p {
  margin: 8px 0 0;
  font-size: 15.5px;
  line-height: 1.5;
  color: rgba(245, 245, 247, 0.68);
}

/* Mobile & Tablet Clean Compact Layout */
@media (max-width: 900px) {
  .ap-feature-band {
    padding: 36px 0 40px;
  }
  .ap-feature-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .ap-feature-media {
    max-height: 360px;
  }
  .ap-feature-copy h2 {
    font-size: clamp(26px, 7vw, 36px);
  }
  .ap-two-tone {
    margin-top: 10px;
    font-size: 15.5px;
    line-height: 1.4;
  }
  .ap-pin-specs {
    margin-top: 16px;
    gap: 10px;
  }
  .ap-pin-spec {
    padding-top: 9px;
  }
  .ap-pin-spec strong {
    font-size: 21px;
  }
  .ap-pin-spec span {
    font-size: 13px;
  }

  /* Compact zero-gap 3D scrub blocks on mobile */
  .ap-cad-track {
    height: auto;
    padding: 32px 0 38px;
  }
  .ap-cad-pin {
    position: relative;
    top: auto;
    height: auto;
    max-height: none;
    padding-top: 0;
  }
  .ap-feature-grid--cad {
    gap: 16px;
  }
  .ap-cad-stage {
    aspect-ratio: 5 / 4;
    height: auto;
    max-height: 330px;
  }
  .ap-cad-meter {
    margin-top: 8px;
    max-width: 100%;
  }
  .ap-cad-meter-labels {
    font-size: 11.5px;
    margin-bottom: 6px;
  }
  .ap-feature-grid--cad .ap-beat-kicker {
    margin-bottom: 8px;
    font-size: 11.5px;
  }
  .ap-feature-grid--cad .ap-feature-copy h2 {
    font-size: 27px;
    line-height: 1.08;
  }
  .ap-feature-grid--cad .ap-two-tone {
    margin-top: 10px;
    font-size: 15px;
    line-height: 1.4;
  }
  .ap-feature-grid--cad .ap-pin-specs {
    margin-top: 14px;
    gap: 10px;
  }
  .ap-feature-grid--cad .ap-pin-spec {
    padding-top: 9px;
  }
  .ap-feature-grid--cad .ap-pin-spec strong {
    font-size: 21px;
  }
  .ap-feature-grid--cad .ap-pin-spec span {
    font-size: 13px;
    margin-top: 3px;
  }

  .ap-story--macro {
    padding: 40px 0 44px;
  }
  .ap-story-intro {
    padding: 0 0 18px;
  }
  .ap-story-intro h2 {
    font-size: clamp(28px, 7.6vw, 40px);
  }
  .ap-story-lead {
    margin-top: 10px;
    font-size: 15px;
  }
  .ap-macro-frame {
    border-radius: 18px;
  }
  .ap-macro-specs {
    margin-top: 22px;
    gap: 18px;
  }
  .ap-replay-btn {
    right: 10px;
    bottom: 10px;
    padding: 6px 12px;
    font-size: 12px;
  }
}

@media (max-width: 720px) {
  .ap-macro-specs {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* === 4B. Apple Highlights Swipe Carousel (Peek Next Card + Pill Progress + Play/Pause) === */
.ap-highlights-band {
  background: var(--bg-light);
  color: var(--ink-dark);
  padding: clamp(52px, 6vw, 84px) 0 clamp(24px, 3vw, 40px);
  overflow-x: clip;
}

.ap-highlights-head {
  margin-bottom: clamp(24px, 3vw, 38px);
}

.ap-highlights-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(32px, 4.6vw, 58px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.038em;
  color: var(--ink-dark);
}

.ap-car-viewport {
  position: relative;
  width: 100%;
}

.ap-car-track {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  padding-inline: max(24px, calc((100vw - 1220px) / 2));
  padding-bottom: 12px;
  scrollbar-width: none;
  outline: none;
}

.ap-car-track::-webkit-scrollbar {
  display: none;
}

.ap-car-slide {
  flex: 0 0 min(760px, 66vw);
  min-height: 600px;
  border-radius: 28px;
  overflow: hidden;
  scroll-snap-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease;
}

.ap-car-slide--light {
  background: #ffffff;
  color: #1d1d1f;
  box-shadow: 0 12px 36px -22px rgba(0, 0, 0, 0.14);
}

.ap-car-slide--dark {
  background: #000000;
  color: #ffffff;
  box-shadow: 0 18px 46px -24px rgba(0, 0, 0, 0.45);
}

.ap-car-top {
  padding: clamp(24px, 2.8vw, 34px) clamp(22px, 3vw, 40px) 12px;
  text-align: center;
  position: relative;
  z-index: 2;
}

.ap-car-top h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(26px, 2.9vw, 40px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.032em;
}

.ap-car-top p {
  margin: 10px auto 0;
  max-width: 480px;
  font-size: clamp(15.5px, 1.45vw, 19px);
  line-height: 1.38;
  color: #6e6e73;
}

.ap-car-slide--dark .ap-car-top p {
  color: rgba(245, 245, 247, 0.74);
}

.ap-car-actions {
  margin-top: 18px;
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.ap-car-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 20px;
  border-radius: var(--radius-pill);
  font-size: 14.5px;
  font-weight: 550;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background-color 0.16s ease, color 0.16s ease, border-color 0.16s ease, transform 0.14s ease;
  white-space: nowrap;
}

.ap-car-btn:active {
  transform: scale(0.97);
}

.ap-car-btn--outline {
  background: transparent;
  border-color: #0071e3;
  color: #0071e3;
}

.ap-car-btn--outline:hover {
  background: rgba(0, 113, 227, 0.08);
}

.ap-car-btn--outline-dark {
  background: transparent;
  border-color: #2997ff;
  color: #2997ff;
}

.ap-car-btn--outline-dark:hover {
  background: rgba(41, 151, 255, 0.14);
}

.ap-car-btn--blue {
  background: #0071e3;
  color: #ffffff;
}

.ap-car-btn--blue:hover {
  background: #0077ed;
}

.ap-car-photo {
  flex: 1;
  min-height: 410px;
  width: 100%;
  background-size: contain;
  background-position: center bottom;
  background-repeat: no-repeat;
  cursor: pointer;
  position: relative;
}

.ap-car-slide--light .ap-car-photo::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 36px;
  background: linear-gradient(180deg, #ffffff 0%, rgba(255, 255, 255, 0) 100%);
  pointer-events: none;
}

.ap-car-slide--dark .ap-car-photo::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 24px;
  background: linear-gradient(180deg, #000000 0%, rgba(0, 0, 0, 0) 100%);
  pointer-events: none;
}

.ap-car-p1 {
  flex: 0 0 auto;
  width: min(410px, calc(100% - 36px));
  min-height: 0;
  aspect-ratio: 1280 / 1248;
  margin: 4px auto 22px;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background-color: #0b0b0e;
  background-size: contain;
  background-position: center center;
  background-image: image-set(url("/assets/brand-package-set.webp") type("image/webp"), url("/assets/brand-package-set.jpg") type("image/jpeg"));
}
.ap-car-p1::before {
  display: none;
}
.ap-car-p2 {
  background-color: #000000;
  background-size: contain;
  background-position: center bottom;
  background-image: image-set(url("/assets/brand-macro-prism.webp") type("image/webp"), url("/assets/brand-macro-prism.jpg") type("image/jpeg"));
}
.ap-car-p3 {
  background-color: #000000;
  background-size: contain;
  background-position: center bottom;
  background-image: image-set(url("/assets/brand-polishing.webp") type("image/webp"), url("/assets/brand-polishing.jpg") type("image/jpeg"));
}
.ap-car-p3::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 24px 10px #000000;
}
.ap-car-p4 {
  background-color: #000000;
  background-size: contain;
  background-position: center bottom;
  background-image: image-set(url("/assets/brand-water.webp") type("image/webp"), url("/assets/brand-water.jpg") type("image/jpeg"));
}
.ap-car-p5 {
  background-color: #eaedeb;
  background-size: cover;
  background-position: center center;
  background-image: image-set(url("/assets/insta-scanning.webp") type("image/webp"), url("/assets/insta-scanning.jpg") type("image/jpeg"));
}

/* Apple Signature Pill Controls + Play/Pause */
.ap-car-controls {
  margin-top: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.ap-car-pill {
  height: 48px;
  padding: 0 20px;
  border-radius: var(--radius-pill);
  background: rgba(210, 210, 215, 0.68);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.ap-car-dot {
  position: relative;
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-pill);
  background: rgba(0, 0, 0, 0.28);
  cursor: pointer;
  overflow: hidden;
  transition: width 0.32s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.2s ease;
}

.ap-car-dot:hover {
  background: rgba(0, 0, 0, 0.45);
}

.ap-car-dot.is-active {
  width: 42px;
  background: rgba(0, 0, 0, 0.16);
}

.ap-car-dot-bar {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-pill);
  background: #1d1d1f;
  transform-origin: left center;
  transform: scaleX(0);
}

.ap-car-dot.is-active .ap-car-dot-bar {
  transform: scaleX(1);
}

.ap-car-pill.is-playing .ap-car-dot.is-active .ap-car-dot-bar {
  animation: apCarFill 5s linear forwards;
}

@keyframes apCarFill {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

.ap-car-play,
.ap-car-arrow {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 0;
  background: rgba(210, 210, 215, 0.68);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #1d1d1f;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.16s ease, transform 0.14s ease, opacity 0.16s ease;
}

.ap-car-play:hover,
.ap-car-arrow:hover {
  background: rgba(196, 196, 202, 0.85);
}

.ap-car-play:active,
.ap-car-arrow:active {
  transform: scale(0.95);
}

.ap-car-play .ap-ic-play { display: block; }
.ap-car-play .ap-ic-pause { display: none; }
.ap-car-play.is-playing .ap-ic-play { display: none; }
.ap-car-play.is-playing .ap-ic-pause { display: block; }

@media (max-width: 720px) {
  .ap-highlights-band {
    padding: 36px 0 18px;
  }
  .ap-highlights-head {
    margin-bottom: 18px;
  }
  .ap-highlights-head h2 {
    font-size: 29px;
  }
  .ap-car-track {
    gap: 14px;
    padding-inline: 20px;
  }
  .ap-car-slide {
    flex: 0 0 calc(100vw - 56px);
    min-height: 490px;
    border-radius: 26px;
  }
  .ap-car-top {
    padding: 24px 18px 12px;
  }
  .ap-car-top h3 {
    font-size: 27px;
  }
  .ap-car-top p {
    font-size: 15px;
  }
  .ap-car-btn {
    height: 36px;
    padding: 0 16px;
    font-size: 13.5px;
  }
  .ap-car-photo {
    min-height: 295px;
  }
  .ap-car-p1 {
    width: min(300px, calc(100% - 28px));
    margin: 2px auto 18px;
  }
  .ap-car-p5 {
    background-size: contain;
  }
  .ap-car-arrow {
    display: none;
  }
  .ap-car-pill {
    height: 44px;
    padding: 0 16px;
  }
  .ap-car-play {
    width: 44px;
    height: 44px;
  }
}

/* === 5. ACT II - Apple Light Shift (#f5f5f7) & Bento Grid === */
.ap-light-band {
  background: var(--bg-light);
  color: var(--ink-dark);
  padding-block: clamp(44px, 4.5vw, 68px);
}

.ap-band-head {
  max-width: 820px;
  margin-bottom: clamp(24px, 2.8vw, 36px);
}

.ap-band-kicker {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-muted-light);
  margin-bottom: 10px;
}

.ap-band-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(32px, 4.6vw, 60px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.038em;
  color: var(--ink-dark);
}

.ap-band-head p {
  margin: 16px 0 0;
  font-size: clamp(16px, 1.55vw, 20px);
  line-height: 1.48;
  color: var(--ink-muted-light);
  max-width: 660px;
}

/* Bento Grid */
.ap-bento {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 20px;
}

.ap-card {
  border-radius: var(--radius-xl);
  padding: clamp(24px, 3vw, 38px);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease;
}

.ap-card--white {
  background: var(--bg-white);
  color: var(--ink-dark);
  box-shadow: 0 2px 18px rgba(0, 0, 0, 0.04);
}

.ap-card--dark {
  background: #09090c;
  color: #ffffff;
}

.ap-span-8 { grid-column: span 8; }
.ap-span-7 { grid-column: span 7; }
.ap-span-6 { grid-column: span 6; }
.ap-span-5 { grid-column: span 5; }
.ap-span-4 { grid-column: span 4; }
.ap-span-12 { grid-column: span 12; }

@media (max-width: 960px) {
  .ap-span-8, .ap-span-7, .ap-span-6, .ap-span-5, .ap-span-4 {
    grid-column: span 12;
  }
}

.ap-card-label {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-muted-light);
  margin-bottom: 10px;
}

.ap-card--dark .ap-card-label {
  color: #a1a1a6;
}

.ap-card h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 2.4vw, 34px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.ap-card p {
  margin: 12px 0 0;
  font-size: 15.5px;
  line-height: 1.55;
  color: var(--ink-muted-light);
}

.ap-card--dark p {
  color: rgba(245, 245, 247, 0.76);
}

.ap-big-num {
  font-family: var(--font-display);
  font-size: clamp(56px, 6.2vw, 84px);
  font-weight: 700;
  line-height: 0.96;
  letter-spacing: -0.05em;
  margin: 12px 0 14px;
}

.ap-country-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.ap-country-tags span {
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: var(--bg-light);
  color: var(--ink-dark);
  font-size: 13px;
  font-weight: 550;
}

/* Mentorship Hero Photo inside Bento */
.ap-card-photo-stage {
  margin-top: 22px;
  border-radius: 18px;
  aspect-ratio: 16 / 9;
  width: 100%;
  background-color: #141419;
  background-size: cover;
  background-position: center;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.10);
  transition: transform 0.25s ease;
}

.ap-card-photo-stage:hover {
  transform: scale(1.012);
}

.ap-photo-mentor {
  background-image: image-set(
    url("/assets/insta-mentorship.webp") type("image/webp"),
    url("/assets/insta-mentorship.jpg") type("image/jpeg")
  );
}

/* Interactive 3D CAD Stage inside Bento */
.ap-cad-box {
  margin-top: 18px;
  border-radius: 18px;
  background: #0a0a0e;
  padding: 18px;
  color: #ffffff;
}

.ap-cad-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.06em;
  color: #a1a1a6;
  margin-bottom: 10px;
}

.ap-cad-svg {
  width: 100%;
  max-height: 220px;
  display: block;
}

.ap-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.16);
  outline: none;
  cursor: pointer;
}

.ap-range--light {
  background: rgba(0, 0, 0, 0.12);
}

.ap-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid #000000;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.28);
  cursor: pointer;
}

/* DICOM Preview Card */
.ap-dicom-mock {
  margin-top: 20px;
  border-radius: 16px;
  background: #14141a;
  border: 1px solid rgba(255, 255, 255, 0.10);
  padding: 16px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.ap-dicom-tile {
  border-radius: 10px;
  background: #07090e;
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px;
}

.ap-dicom-tile strong {
  display: block;
  font-size: 12.5px;
  color: #ffffff;
}

.ap-dicom-tile span {
  display: block;
  margin-top: 4px;
  font-size: 11.5px;
  color: #86868b;
}

/* 4-Photo Real Brand Gallery inside Bento */
.ap-brand-grid {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

@media (max-width: 900px) {
  .ap-brand-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .ap-brand-grid {
    grid-template-columns: 1fr;
  }
}

.ap-brand-tile {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: #121217;
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.ap-brand-tile:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.34);
}

.ap-brand-img {
  width: 100%;
  aspect-ratio: 4 / 3;
  background-color: #070709;
  background-size: cover;
  background-position: center;
}

.ap-b-pack { background-image: image-set(url("/assets/brand-package-set.webp") type("image/webp"), url("/assets/brand-package-set.jpg") type("image/jpeg")); }
.ap-b-polish { background-image: image-set(url("/assets/brand-polishing.webp") type("image/webp"), url("/assets/brand-polishing.jpg") type("image/jpeg")); }
.ap-b-prism { background-image: image-set(url("/assets/brand-macro-prism.webp") type("image/webp"), url("/assets/brand-macro-prism.jpg") type("image/jpeg")); }
.ap-b-water { background-image: image-set(url("/assets/brand-water.webp") type("image/webp"), url("/assets/brand-water.jpg") type("image/jpeg")); }

.ap-brand-cap {
  padding: 13px 15px 15px;
}

.ap-brand-cap strong {
  display: block;
  font-size: 14px;
  font-weight: 650;
  color: #ffffff;
}

.ap-brand-cap span {
  display: block;
  margin-top: 3px;
  font-size: 12.5px;
  color: #a1a1a6;
}

/* === 6. ACT III - Apple Spec Calculator & Partner Form === */
.ap-calc-band {
  background: var(--bg-white);
  color: var(--ink-dark);
  padding-block: clamp(44px, 4.5vw, 68px);
  border-top: 1px solid var(--line-light);
}

.ap-calc-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  gap: 24px;
  align-items: stretch;
}

@media (max-width: 960px) {
  .ap-calc-grid {
    grid-template-columns: 1fr;
  }
}

.ap-calc-panel {
  background: var(--bg-light);
  border-radius: var(--radius-xl);
  padding: clamp(24px, 3vw, 36px);
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.ap-seg-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ap-seg-btn {
  padding: 9px 15px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: #ffffff;
  color: var(--ink-dark);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}

.ap-seg-btn.active {
  background: #1d1d1f;
  border-color: #1d1d1f;
  color: #ffffff;
}

.ap-slider-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ap-slider-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}

.ap-slider-head label {
  font-size: 14px;
  font-weight: 550;
  color: var(--ink-muted-light);
}

.ap-slider-head strong {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--ink-dark);
}

.ap-calc-result {
  background: #09090c;
  color: #ffffff;
  border-radius: var(--radius-xl);
  padding: clamp(26px, 3vw, 38px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
}

.ap-profit-val {
  font-family: var(--font-display);
  font-size: clamp(38px, 4.4vw, 56px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.04em;
  background: var(--prism-soft);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.ap-res-rows {
  display: grid;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.ap-res-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14.5px;
  color: rgba(245, 245, 247, 0.72);
}

.ap-res-row strong {
  color: #ffffff;
  font-weight: 650;
}

/* Connect / Lead Form Section */
.ap-connect-band {
  background: var(--bg-light);
  color: var(--ink-dark);
  padding-block: clamp(44px, 4.5vw, 68px);
}

.ap-connect-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 28px;
  align-items: start;
}

@media (max-width: 960px) {
  .ap-connect-grid {
    grid-template-columns: 1fr;
  }
}

.ap-form-card {
  background: #ffffff;
  border-radius: var(--radius-xl);
  padding: clamp(24px, 3vw, 38px);
  box-shadow: 0 12px 40px -20px rgba(0, 0, 0, 0.12);
}

.ap-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

@media (max-width: 600px) {
  .ap-form-grid {
    grid-template-columns: 1fr;
  }
}

.ap-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.ap-field--full {
  grid-column: 1 / -1;
}

.ap-field label {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-muted-light);
}

.ap-field input,
.ap-field select,
.ap-field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.14);
  background: #fbfbfd;
  color: var(--ink-dark);
  font-size: 15px;
  outline: none;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.ap-field input:focus,
.ap-field select:focus,
.ap-field textarea:focus {
  border-color: #000000;
  background: #ffffff;
}

.ap-form-status {
  margin-top: 12px;
  font-size: 14px;
  font-weight: 550;
  min-height: 20px;
}

.ap-form-status.ok { color: #059669; }
.ap-form-status.err { color: #dc2626; }

/* === 7. Minimalist Apple Dark Footer + Legal === */
.ap-footer {
  background: #000000;
  color: #a1a1a6;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
  padding: 40px 0 32px;
}

.ap-footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
}

@media (max-width: 860px) {
  .ap-footer-top {
    grid-template-columns: 1fr;
  }
}

.ap-footer-logo {
  display: block;
  width: 126px;
  height: 28px;
  background-image: url("/assets/sllign-logo-light.svg");
  background-repeat: no-repeat;
  background-size: contain;
  margin-bottom: 14px;
}

.ap-footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 14px;
}

.ap-footer-links a:hover {
  color: #ffffff;
}

.ap-legal-bar {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  font-size: 12.5px;
  line-height: 1.55;
  color: #86868b;
}

.ap-rzn-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.ap-rzn-emblem {
  width: 68px;
  height: 76px;
  flex-shrink: 0;
  border-radius: 10px;
  background-color: #ffffff;
  background-image: url("/assets/roszdravnadzor.webp");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  background-origin: content-box;
  padding: 7px;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

/* === 8. Reveal Animations === */
.ap-reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1), transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
}

.ap-reveal.in {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .ap-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .ap-hero-video {
    display: none;
  }
}

/* === 9. Clean VK-Style Lightbox === */
.sl-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 240;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(12px);
  align-items: center;
  justify-content: center;
  padding: 18px;
}

.sl-lightbox.open {
  display: flex;
}

.sl-lightbox-close {
  position: fixed;
  top: 18px;
  right: 22px;
  z-index: 250;
  width: 42px;
  height: 42px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.82);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sl-lightbox-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 92vw;
}

.sl-lightbox-frame {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.72);
}

.sl-lightbox-photo {
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}

.sl-lightbox-nav {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 68px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.82);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sl-lightbox-prev { left: 0; }
.sl-lightbox-next { right: 0; }

.sl-lightbox-caption {
  margin-top: 12px;
  font-size: 14px;
  color: rgba(245, 245, 247, 0.86);
  text-align: center;
}

/* === 10. Floating Apple Glass AI Coordinator === */
.ai-trigger {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 140;
  height: 50px;
  padding: 0 18px 0 8px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.20);
  background: rgba(18, 18, 22, 0.82);
  backdrop-filter: saturate(180%) blur(18px);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.42);
  transition: transform 0.18s ease, border-color 0.18s ease;
}

.ai-trigger:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.40);
}

@media (max-width: 768px) {
  .ai-trigger {
    right: 12px;
    bottom: 12px;
    width: 46px;
    height: 46px;
    padding: 0;
    justify-content: center;
  }
  .ai-trigger > span:last-child {
    display: none;
  }
}

.ai-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background-color: #0b0b0e;
  background-image: url("/assets/sllign-mark.svg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 24px 24px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  position: relative;
}

.ai-dot {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #22c55e;
  border: 2px solid #0b0b0e;
}

.ai-window {
  display: none;
  position: fixed;
  right: 20px;
  bottom: 82px;
  z-index: 170;
  width: min(390px, calc(100vw - 24px));
  height: min(560px, calc(100svh - 110px));
  border-radius: 22px;
  background: #0d0d11;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.68);
  flex-direction: column;
  overflow: hidden;
  color: #f5f5f7;
}

.ai-window.open {
  display: flex;
}

.ai-win-head {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ai-messages {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ai-bubble {
  max-width: 86%;
  padding: 10px 13px;
  border-radius: 16px;
  font-size: 13.8px;
  line-height: 1.48;
  white-space: pre-wrap;
}

.ai-bubble--bot {
  align-self: flex-start;
  background: #1a1a22;
  color: #f5f5f7;
}

.ai-bubble--user {
  align-self: flex-end;
  background: #ffffff;
  color: #000000;
}

.ai-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.ai-chip {
  padding: 7px 11px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: #f5f5f7;
  font-size: 12px;
  cursor: pointer;
}

.ai-chip:hover {
  background: rgba(255, 255, 255, 0.14);
}

.ai-form {
  padding: 10px 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
  display: flex;
  gap: 8px;
}

.ai-input {
  flex: 1;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: #16161c;
  color: #ffffff;
  padding: 10px 14px;
  font-size: 14px;
  outline: none;
}

.ai-send {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 0;
  background: #ffffff;
  color: #000000;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
  transition: transform 0.14s ease, background-color 0.14s ease;
}

.ai-send:hover {
  background: #e8e8ed;
  transform: scale(1.04);
}

.ai-send:active {
  transform: scale(0.95);
}

/* === 11. Doctor DICOM Cabinet (/cabinet) Compatibility Styles === */
.cab-page {
  padding-top: calc(var(--nav-h) + 32px);
  padding-bottom: 64px;
  min-height: 100svh;
  background: #0b0b0e;
  color: #f5f5f7;
}

.cab-card {
  background: #14141a;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  padding: 24px;
}

.cab-workspace-grid {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

@media (max-width: 980px) {
  .cab-workspace-grid {
    grid-template-columns: 1fr;
  }
}

.cab-login-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 640px) {
  .cab-login-grid {
    grid-template-columns: 1fr;
  }
}

.cab-case-btn {
  width: 100%;
  text-align: left;
  padding: 13px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background: #1b1b22;
  color: #f5f5f7;
  cursor: pointer;
  margin-bottom: 8px;
}

.cab-case-btn.active {
  border-color: #ffffff;
  background: #23232e;
}

.mpr-grid-4 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  background: #05070b;
  border-radius: 14px;
  padding: 10px;
}

@media (max-width: 640px) {
  .mpr-grid-4 {
    grid-template-columns: 1fr;
  }
}

.mpr-pane {
  position: relative;
  background: #0a0f18;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  overflow: hidden;
}

.mpr-pane-head {
  position: absolute;
  top: 7px;
  left: 9px;
  right: 9px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 700;
  color: #e4e4ec;
  pointer-events: none;
}

.mpr-canvas {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
}

.single-dcm-stage {
  background: #05070b;
  border-radius: 14px;
  padding: 14px;
  text-align: center;
}

.single-dcm-canvas {
  max-width: 100%;
  height: auto;
  max-height: 440px;
  border-radius: 8px;
}

.cab-wl-controls {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 640px) {
  .cab-wl-controls {
    grid-template-columns: 1fr;
  }
}

.cab-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 12px;
  font-weight: 600;
}

.cab-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.cab-tab-btn {
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: transparent;
  color: #d4d4dc;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.cab-tab-btn.active {
  background: #ffffff;
  color: #000000;
  border-color: #ffffff;
}

.cab-input {
  width: 100%;
  padding: 11px 13px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: #0d0d12;
  color: #ffffff;
  font-size: 14px;
}

/* === 12. Tight Responsive Rhythm Overrides (Always Last in Cascade) === */
@media (max-width: 960px) {
  .ap-light-band,
  .ap-calc-band,
  .ap-connect-band {
    padding-block: 32px 36px;
  }
  .ap-band-head {
    margin-bottom: 20px;
  }
  .ap-bento {
    gap: 14px;
  }
  .ap-calc-grid,
  .ap-connect-grid {
    gap: 16px;
  }
  .ap-stat-row {
    margin-top: 20px;
  }
}

@media (max-width: 640px) {
  .ap-hero-stage {
    max-height: 300px;
  }
  .ap-hero-bar {
    padding-bottom: 24px;
  }
  .ap-light-band,
  .ap-calc-band,
  .ap-connect-band {
    padding-block: 24px 28px;
  }
  .ap-band-head {
    margin-bottom: 16px;
  }
  .ap-band-head h2 {
    font-size: 27px;
  }
  .ap-band-head p {
    margin-top: 8px;
    font-size: 14.8px;
  }
  .ap-bento {
    gap: 12px;
  }
  .ap-card,
  .ap-calc-panel,
  .ap-calc-result,
  .ap-form-card {
    padding: 18px 16px;
    border-radius: 22px;
  }
  .ap-calc-grid,
  .ap-connect-grid {
    gap: 14px;
  }
  .ap-footer {
    padding: 28px 0 24px;
  }
  .ap-footer-top {
    gap: 18px;
    padding-bottom: 18px;
  }
}
