/* ============================================================================
   MINDPHASE — product pages
   ============================================================================

   The app's own look, not the studio's: the same rule that keeps /spora in
   Spora's voice. Graphite ground, paper ink, hairlines, light type, one
   letterspaced wordmark. No fills, no gradients inside anything — only the
   faint pool of light the app puts behind its objects.

   Every page under /mindphase links this and nothing else.
   ========================================================================= */

:root {
  --ground:   #0f0f10;
  --lift:     #1a1a1c;
  --ink:      #f2f0ec;
  --ink-soft: #c9c5be;
  --dim:      #8a867f;
  --faint:    #5c5954;
  --line:     rgba(242, 240, 236, 0.12);
  --line-hi:  rgba(242, 240, 236, 0.26);

  /* The four phase palettes, used only as small marks. */
  --restless:    #7fa8e0;
  --irritated:   #e08757;
  --overwhelmed: #9a8dd8;
  --wired:       #7fbf98;

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background-color: var(--ground);
  background-image: radial-gradient(ellipse 90% 55% at 50% 18%, var(--lift), transparent 70%);
  background-repeat: no-repeat;
  color: var(--ink);
  font: 300 17px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection { background: var(--ink); color: var(--ground); }
a { color: inherit; text-decoration-color: var(--faint); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
img, video { max-width: 100%; display: block; }

.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding-inline: 16px; }
@media (min-width: 720px) { .wrap { padding-inline: 40px; } }
section { padding-block: clamp(4.5rem, 11vw, 8rem); }

/* Type -------------------------------------------------------------------- */

.wordmark {
  margin: 0;
  font-weight: 300;
  font-size: clamp(0.95rem, 2.6vw, 1.15rem);
  letter-spacing: 0.72em;
  margin-right: -0.72em;           /* tracking hangs off the end otherwise */
  color: var(--ink-soft);
}
.tagline {
  margin: 1.4rem 0 0;
  font-weight: 200;
  font-size: clamp(2.6rem, 9vw, 5.2rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
}
.lede {
  margin: 1.4rem auto 0;
  max-width: 34ch;
  color: var(--ink-soft);
  font-size: clamp(1.05rem, 2.4vw, 1.25rem);
}
.eyebrow {
  margin: 0 0 2rem;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--dim);
}
h2 {
  margin: 0 0 1rem;
  font-weight: 200;
  font-size: clamp(1.9rem, 5vw, 2.9rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
}
p { margin: 0 0 1rem; }
.muted { color: var(--dim); }

/* Language switch, same place as on the studio's pages --------------------- */

.lang {
  position: fixed; top: 14px; right: 14px; z-index: 20;
  display: flex; gap: 2px; padding: 3px;
  border: 1px solid var(--line); border-radius: 999px;
  background: rgba(15, 15, 16, 0.8);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.lang button {
  border: 0; background: transparent; color: var(--dim);
  font: 400 11px/1 var(--font); letter-spacing: 0.18em;
  padding: 7px 11px; border-radius: 999px; cursor: pointer;
}
.lang button:hover { color: var(--ink); }
.lang button.active { background: var(--ink); color: var(--ground); }

.back {
  display: inline-block; font-size: 0.8rem; letter-spacing: 0.06em;
  color: var(--dim); text-decoration: none;
}
.back:hover { color: var(--ink); }

/* Hero -------------------------------------------------------------------- */

.hero { text-align: center; padding-top: clamp(4rem, 12vh, 7rem); }
.badge {
  display: inline-flex; align-items: center; gap: 0.6rem;
  margin-top: 2rem; padding: 0.5rem 0.95rem;
  border: 1px solid var(--line); border-radius: 999px;
  font-size: 0.78rem; letter-spacing: 0.08em; color: var(--ink-soft);
}
.badge i { width: 6px; height: 6px; border-radius: 50%; background: var(--wired); }

/* The phone is drawn the way the app draws: a hairline, nothing filled. */
.phone {
  width: min(250px, 62vw);
  border: 1px solid var(--line-hi);
  border-radius: 34px;
  overflow: hidden;
  background: var(--ground);
}
.phone img, .phone video { width: 100%; height: auto; }

.fan {
  display: flex; justify-content: center; align-items: center;
  margin-top: clamp(3rem, 8vw, 4.5rem);
}
.fan .phone { flex: none; transition: transform 0.6s var(--ease), opacity 0.6s var(--ease); }
.fan .phone.side { width: min(210px, 44vw); opacity: 0.55; }
.fan .phone.left  { transform: translateX(28%) rotate(-6deg); }
.fan .phone.right { transform: translateX(-28%) rotate(6deg); }
.fan .phone.mid { position: relative; z-index: 2; }
.fan:hover .phone.side { opacity: 0.75; }
@media (max-width: 560px) { .fan .phone.side { display: none; } }

/* Three statements -------------------------------------------------------- */

.trio { display: grid; gap: 2.4rem; }
@media (min-width: 820px) { .trio { grid-template-columns: repeat(3, 1fr); gap: 3rem; } }
.trio div { border-top: 1px solid var(--line); padding-top: 1.4rem; }
.trio h3 { margin: 0 0 0.6rem; font-weight: 300; font-size: 1.35rem; }
.trio p { margin: 0; color: var(--dim); }

/* The library ------------------------------------------------------------- */

.objects { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.objects li {
  display: grid; grid-template-columns: 1fr; gap: 0.2rem 2rem;
  padding: 1.25rem 0; border-bottom: 1px solid var(--line);
}
@media (min-width: 720px) {
  .objects li { grid-template-columns: 11rem 9rem 1fr auto; align-items: baseline; }
}
.objects .verb { font-weight: 200; font-size: 1.9rem; line-height: 1.1; }
.objects .object {
  font-size: 0.7rem; letter-spacing: 0.3em; text-transform: uppercase; color: var(--dim);
}
.objects .note { color: var(--ink-soft); }
.objects .tag {
  justify-self: start;
  font-size: 0.68rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--wired); border: 1px solid rgba(127, 191, 152, 0.4);
  border-radius: 999px; padding: 0.2rem 0.6rem;
}

/* Alternating rows: a screen and what it is ------------------------------ */

.row { display: grid; gap: 2.4rem; align-items: center; justify-items: center; }
.row + .row { margin-top: clamp(4rem, 10vw, 7rem); }
.row .copy { max-width: 36ch; }
@media (min-width: 820px) {
  .row { grid-template-columns: 1fr 1fr; justify-items: start; }
  .row .phone { justify-self: center; }
  .row.flip .copy { order: 2; }
}
.row .kicker {
  display: block; margin-bottom: 0.9rem;
  font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.08em; color: var(--dim);
}
.row h3 { margin: 0 0 0.8rem; font-weight: 200; font-size: clamp(1.7rem, 4vw, 2.4rem); line-height: 1.15; }
.row p { color: var(--dim); }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 0.55rem; vertical-align: 0.12em; }

/* Specs: the readout bar, as the app has it ------------------------------ */

.readout {
  display: grid; grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
@media (min-width: 820px) { .readout { grid-template-columns: repeat(4, 1fr); } }
.readout div { padding: 1.6rem 0.4rem; text-align: center; }
.readout b {
  display: block; font-family: var(--mono); font-weight: 400;
  font-size: clamp(1.3rem, 3.4vw, 1.75rem); color: var(--ink);
}
.readout span {
  display: block; margin-top: 0.35rem;
  font-size: 0.66rem; letter-spacing: 0.3em; text-transform: uppercase; color: var(--dim);
}

/* Tiles to the documents ------------------------------------------------- */

.tiles { display: grid; gap: 1rem; }
@media (min-width: 720px) { .tiles { grid-template-columns: 1fr 1fr; } }
.tile {
  display: block; padding: 1.5rem 1.6rem; text-decoration: none;
  border: 1px solid var(--line); border-radius: 18px;
  transition: border-color 0.3s var(--ease);
}
.tile:hover { border-color: var(--line-hi); }
.tile b { display: block; font-weight: 400; font-size: 1.15rem; margin-bottom: 0.3rem; }
.tile span { color: var(--dim); font-size: 0.95rem; }

/* Long-form pages (support, privacy) ------------------------------------- */

.doc { max-width: 640px; margin: 0 auto; padding: clamp(3.5rem, 9vh, 5rem) 16px 5rem; }
.doc h1 { margin: 2.2rem 0 0.4rem; font-weight: 200; font-size: clamp(2.2rem, 7vw, 3.2rem); line-height: 1.1; }
.doc .date { color: var(--faint); font-size: 0.85rem; margin: 0 0 2.6rem; }
.doc h2 {
  margin: 2.8rem 0 0.8rem; font-weight: 400; font-size: 0.74rem;
  letter-spacing: 0.3em; text-transform: uppercase; color: var(--dim);
}
.doc p, .doc li { color: var(--ink-soft); }
.doc ul { padding-left: 1.2rem; }
.doc li { margin-bottom: 0.5rem; }
.doc strong { color: var(--ink); font-weight: 500; }
.headline {
  margin: 0 0 1rem; padding: 1.4rem 1.5rem;
  border: 1px solid var(--line-hi); border-radius: 18px;
  font-size: 1.15rem; font-weight: 300; color: var(--ink);
}
.qa { border-top: 1px solid var(--line); padding: 1.3rem 0; }
.qa b { display: block; font-weight: 400; color: var(--ink); margin-bottom: 0.35rem; }
.qa p { margin: 0; }
.contact {
  display: inline-block; margin-top: 0.4rem;
  font-weight: 200; font-size: clamp(1.4rem, 5vw, 2rem);
  text-decoration: none; border-bottom: 1px solid var(--line-hi); padding-bottom: 0.2rem;
}
.contact:hover { border-bottom-color: var(--ink); }

/* Footer ------------------------------------------------------------------ */

footer.site { border-top: 1px solid var(--line); padding: 1.8rem 0 3rem; font-size: 0.85rem; color: var(--dim); }
footer.site .wrap { display: flex; flex-wrap: wrap; gap: 0.8rem 2rem; justify-content: space-between; }
footer.site a { color: var(--dim); text-decoration: none; }
footer.site a:hover { color: var(--ink); }

/* Reveal: enabled only once the script has run, so nothing is ever left hidden. */
.js-reveal .reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.js-reveal .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js-reveal .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
