/* PAIA product-facing style layer. Loaded after styles.css. */

::selection { background: #dfe7da; color: #1f241f; }
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid #647b58;
  outline-offset: 3px;
  border-radius: 6px;
}

.nav a[aria-current="page"] { color: var(--ink); font-weight: 620; }
.story-visual figcaption,
.product-shot figcaption,
.case-note,
footer { color: #687267; }

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px 20px;
  margin-top: 4px;
}
.hero-actions .beta-button { min-height: 44px; padding-inline: 17px; }
.hero-actions .text-link { font-size: 14.5px; }
.availability-line {
  margin: -18px 0 28px;
  color: #687267;
  font-size: 12.5px;
  font-weight: 540;
  letter-spacing: .025em;
}

.closing { padding-top: 104px; padding-bottom: 112px; }
.closing-copy > p:last-of-type { color: #4f594e !important; }

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  align-items: start;
  width: min(var(--max), calc(100% - 64px));
  margin: 0 auto;
  padding: 28px 0 42px;
  color: #687267;
  font-size: 12.5px;
}
.footer-brand { display: grid; gap: 5px; line-height: 1.45; }
.footer-brand strong { color: #465144; font-weight: 680; letter-spacing: .02em; }
.footer-brand small { color: #687267; font-size: 11.5px; }
.footer-links {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  line-height: 1.45;
}
.footer-links a:hover { color: #455143; }
.footer-meta { color: #687267; }

.product-about-hero h1,
.principles-hero h1,
.legal-hero h1,
.beta-hero h1,
.status-hero h1 { max-width: 820px; }
.product-about-copy { max-width: 760px; }
.product-about-copy h2 { max-width: 700px; }
.product-about-copy .body-copy { max-width: 650px; }
.project-section { padding-top: 72px; }
.project-section .project-meta { max-width: 560px; }
.project-label {
  display: inline-block;
  margin-bottom: 18px;
  color: var(--accent);
  font-size: 11.5px;
  font-weight: 650;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.lang-copy-en { display: none; }
html[data-language="en"] .lang-copy-zh { display: none; }
html[data-language="en"] .lang-copy-en { display: inline; }

.principles-list-wrap { max-width: 900px; }
.principles-list-wrap .decision-list { margin-top: 12px; }

.legal-layout {
  display: grid;
  grid-template-columns: minmax(0, 760px) 1fr;
  gap: 64px;
  align-items: start;
}
.legal-copy { max-width: 760px; }
.legal-copy h2 {
  margin-top: 42px;
  margin-bottom: 12px;
  font-size: clamp(24px, 2.4vw, 32px);
}
.legal-copy h2:first-child { margin-top: 0; }
.legal-copy p,
.legal-copy li { color: #535d52; font-size: 16px; }
.legal-copy ul { margin: 12px 0 0; padding-left: 20px; }
.legal-meta {
  position: sticky;
  top: 96px;
  padding: 18px 0 0;
  border-top: 1px solid var(--line);
  color: #687267;
  font-size: 13px;
  line-height: 1.7;
}
.legal-meta a { color: #53684b; font-weight: 600; }

.beta-layout {
  display: grid;
  grid-template-columns: minmax(0, 700px) minmax(220px, 1fr);
  gap: 72px;
  align-items: start;
}
.beta-form { display: grid; gap: 24px; max-width: 700px; }
.form-field { display: grid; gap: 9px; }
.form-field label { color: #354034; font-size: 14px; font-weight: 620; }
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  border: 1px solid #d6ddd2;
  border-radius: 12px;
  background: #fbfcf9;
  color: #20251f;
  font: inherit;
  font-size: 15.5px;
  line-height: 1.5;
}
.form-field input,
.form-field select { min-height: 50px; padding: 0 14px; }
.form-field textarea { min-height: 132px; padding: 13px 14px; resize: vertical; }
.form-field input::placeholder,
.form-field textarea::placeholder { color: #7b8579; }
.beta-submit { width: fit-content; min-height: 48px; border: 0; cursor: pointer; }
.beta-privacy-note {
  max-width: 620px;
  margin: -4px 0 0;
  color: #687267;
  font-size: 12.5px;
  line-height: 1.65;
}
.beta-aside {
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: #687267;
  font-size: 13.5px;
}
.beta-aside strong { display: block; margin-bottom: 8px; color: #445142; }
.beta-aside p { margin-bottom: 14px; font-size: 13.5px; }
.beta-submit[aria-busy="true"] { opacity: .68; cursor: progress; pointer-events: none; }
.beta-form-status { min-height: 22px; margin: 0; color: #687267; font-size: 13px; }
.beta-form-status.is-error { color: #8d4138; }
.beta-inline-success { padding: 34px 0 12px; border-top: 1px solid var(--line); }
.beta-inline-success .eyebrow { margin-bottom: 18px; }
.beta-inline-success h2 { margin-bottom: 14px; }
.beta-inline-success p { max-width: 560px; margin-bottom: 24px; }
.beta-inline-success .text-link { font-size: 14px; }

.status-hero {
  min-height: calc(100vh - 160px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.status-hero .hero-cn { max-width: 660px; }

/* Persistent conversion stays quiet: capability without spectacle. */
.header-beta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid #cfd8cb;
  border-radius: 999px;
  background: #eef2eb;
  color: #3f503a !important;
  font-size: 12.5px;
  font-weight: 650;
  white-space: nowrap;
  transition: background .18s ease, border-color .18s ease;
}
.header-beta:hover { background: #e8ede5; border-color: #c2cec0; }

.product-section .detail-shot { overflow: hidden; }
.detail-shot img { transform-origin: center; }
.context-detail-shot img { background: #fbfcf9; }
.mobile-product-shot { display: none; }

/* Thought Library: AI appears as a derived layer; the source never disappears. */
.thought-scroll-story {
  position: relative;
  min-height: 104vh;
  margin-top: 2px;
}
.thought-scroll-story .thought-transform {
  position: sticky;
  top: clamp(82px, 11vh, 112px);
  overflow: hidden;
  z-index: 2;
  background: #f8faf6;
  border-color: rgba(205,216,201,.95);
  box-shadow: 0 14px 40px rgba(36,45,34,.055);
}
.thought-scroll-story .thought-transform-head,
.thought-scroll-story .thought-transform-caption,
.thought-scroll-story .thought-transform-flare,
.thought-scroll-story .thought-transform::before { display: none !important; }
.thought-scroll-story .thought-transform-canvas {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  border-radius: 19px;
  background: #fbfcf9;
  isolation: isolate;
}
.thought-scroll-story .thought-layer {
  position: absolute;
  inset: 0;
  margin: 0;
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
  background-color: #fbfcf9;
  transition: none !important;
  will-change: opacity, transform, filter;
}
.thought-scroll-story .thought-layer img {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  overflow: hidden !important;
}
.thought-scroll-story .thought-layer-faithful {
  z-index: 1;
  background-image: url('assets/screenshots/thought-reading.svg?v=9');
  opacity: var(--faithful-opacity, 1) !important;
  transform: scale(var(--faithful-scale, 1)) !important;
  filter: blur(var(--faithful-blur, 0px)) !important;
}
.thought-scroll-story .thought-layer-ai {
  z-index: 2;
  background-image: url('assets/screenshots/ai-organized.svg?v=9');
  opacity: var(--ai-opacity, 0) !important;
  transform: translateY(var(--ai-y, 6px)) scale(1) !important;
  filter: blur(var(--ai-blur, 2.5px)) !important;
}

/* Mobile navigation preserves the information architecture without competing with Join beta. */
.mobile-menu-button {
  display: none;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #d7ddd3;
  border-radius: 10px;
  background: #f8f9f6;
  color: #4f5a4d;
  cursor: pointer;
}
.mobile-menu-button span {
  display: block;
  width: 14px;
  height: 1px;
  margin: 3px auto;
  background: currentColor;
}
.mobile-menu-panel {
  display: none;
  position: fixed;
  z-index: 19;
  top: 62px;
  left: 12px;
  right: 12px;
  padding: 10px;
  border: 1px solid #d9dfd5;
  border-radius: 16px;
  background: rgba(251,252,249,.98);
  box-shadow: 0 14px 38px rgba(36,45,34,.09);
  backdrop-filter: blur(10px);
}
.mobile-menu-panel.is-open { display: grid; }
.mobile-menu-panel a {
  padding: 12px 13px;
  border-radius: 10px;
  color: #4e594c;
  font-size: 14px;
}
.mobile-menu-panel a:hover { background: #eef2eb; color: #283226; }

@media (max-width: 900px) {
  .nav { gap: 10px; }
  .header-beta { min-height: 32px; padding: 0 11px; }
  .site-footer { width: calc(100% - 40px); }
  .legal-layout,
  .beta-layout { grid-template-columns: 1fr; gap: 28px; }
  .legal-meta { position: static; }
}

@media (max-width: 620px) {
  .site-header { padding-left: 16px; padding-right: 16px; }
  .nav { gap: 8px; align-items: center; font-size: 12.5px; }
  .nav .nav-product,
  .nav .nav-principles,
  .nav .nav-privacy,
  .nav .nav-about { display: none !important; }
  .header-beta { display: inline-flex !important; }
  .mobile-menu-button { display: inline-block; }
  .lang-switch { padding-inline: 8px; }

  .hero-actions { align-items: flex-start; flex-direction: column; gap: 14px; }
  .availability-line { margin-top: -14px; margin-bottom: 24px; }

  .product-section .detail-shot {
    aspect-ratio: auto;
    height: auto;
    border: 1px solid #d7ddd3;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(36,45,34,.05);
  }
  .product-section .detail-shot .desktop-product-shot { display: none; }
  .product-section .detail-shot .mobile-product-shot {
    width: 100%;
    max-width: 100%;
    height: auto;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    transform: none;
  }
  html[data-language="zh"] .mobile-product-shot-zh { display: block; }
  html[data-language="en"] .mobile-product-shot-en { display: block; }

  .thought-scroll-story { min-height: auto; }
  .thought-scroll-story .thought-transform { position: relative; top: auto; box-shadow: 0 12px 34px rgba(36,45,34,.05); }
  .thought-scroll-story .thought-transform-caption { display: flex !important; }
  .thought-scroll-story .thought-transform-canvas { aspect-ratio: 720 / 980; }
  .thought-scroll-story .thought-layer { background-size: contain; }
  html[data-language="zh"] .thought-scroll-story .thought-layer-faithful { background-image: url('assets/screenshots/thought-reading-mobile.svg?v=1'); }
  html[data-language="zh"] .thought-scroll-story .thought-layer-ai { background-image: url('assets/screenshots/ai-organized-mobile.svg?v=1'); }
  html[data-language="en"] .thought-scroll-story .thought-layer-faithful { background-image: url('assets/screenshots/thought-reading-mobile-en.svg?v=1'); }
  html[data-language="en"] .thought-scroll-story .thought-layer-ai { background-image: url('assets/screenshots/ai-organized-mobile-en.svg?v=1'); }
  .thought-scroll-story .thought-layer-faithful,
  .thought-scroll-story .thought-layer-ai { transition: opacity .36s ease, transform .36s ease, filter .36s ease !important; }
  .thought-scroll-story .thought-transform:not(.ai-active) .thought-layer-faithful { opacity: 1 !important; filter: none !important; transform: none !important; }
  .thought-scroll-story .thought-transform:not(.ai-active) .thought-layer-ai { opacity: 0 !important; transform: translateY(6px) !important; filter: blur(2px) !important; }
  .thought-scroll-story .thought-transform.ai-active .thought-layer-faithful { opacity: .38 !important; transform: scale(.995) !important; filter: blur(.5px) !important; }
  .thought-scroll-story .thought-transform.ai-active .thought-layer-ai { opacity: 1 !important; transform: none !important; filter: none !important; }

  .site-footer {
    grid-template-columns: 1fr;
    gap: 18px;
    width: calc(100% - 30px);
    padding-bottom: 34px;
  }
  .footer-links { justify-content: flex-start; gap: 8px 14px; }
  .closing { padding-top: 78px; padding-bottom: 82px; }
  .status-hero { min-height: calc(100vh - 128px); }
}

/* Navigation is intentionally sparse on desktop; complete IA stays in the menu/footer. */
.site-header .nav-privacy,
.site-header .nav-about { display: none !important; }

@media (max-width: 900px) {
  .site-header { padding-left: 18px; padding-right: 18px; }
  .site-header .nav .nav-product,
  .site-header .nav .nav-demo,
  .site-header .nav .nav-principles,
  .site-header .nav .nav-privacy,
  .site-header .nav .nav-about { display: none !important; }
  .mobile-menu-button { display: inline-block; }
  .lang-switch { padding-inline: 8px; }
}
