/* Facet (facet.aircoded.app)
   Palette drawn from the app's dark UI and the Lugano-lake artwork:
   ink, mist teal, warm sand. Display face: Bricolage Grotesque (self-hosted). */

:root {
  --ink: #0a0d12;
  --ink-2: #0e1219;
  --raised: #131924;
  --line: rgba(233, 237, 242, 0.09);
  --text: #e9edf2;
  --muted: #98a2b0;
  --teal: #7fd0c4;
  --teal-dim: #4f9d93;
  --sand: #ddbc9b;
  --display: "Bricolage Grotesque", -apple-system, "SF Pro Display", sans-serif;
  --body: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace;
  --wide: 1120px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  background: var(--ink);
  color: var(--text);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; height: auto; }

a { color: var(--teal); text-decoration: none; }
a:hover { color: var(--text); }
:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap { max-width: var(--wide); margin: 0 auto; padding: 0 24px; }

h1, h2, h3 { font-family: var(--display); font-weight: 640; letter-spacing: -0.015em; }

.eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--teal);
}

section { padding: 96px 0; }
.section-head { max-width: 640px; margin-bottom: 56px; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); margin: 14px 0 12px; }
.section-head p { color: var(--muted); }

/* ---------------------------------------------------------------- nav */

.nav {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 10;
  padding: 22px 0;
}
.nav .wrap { display: flex; align-items: center; gap: 28px; }
.wordmark {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--display);
  font-size: 1.25rem; font-weight: 700;
  color: var(--text); letter-spacing: -0.01em;
}
.wordmark img { width: 28px; height: 28px; border-radius: 7px; }
.nav-links { margin-left: auto; display: flex; gap: 26px; }
.nav-links a {
  color: var(--muted);
  font-size: 0.92rem;
}
.nav-links a:hover { color: var(--text); }

/* --------------------------------------------------------------- hero */

.hero {
  position: relative;
  padding: 170px 0 0;
  overflow: hidden;
  background: var(--ink);
}
.hero-bg,
.hero::before,
.hero::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.hero-bg {
  width: 100%; height: 100%;
  object-fit: cover;
  transform: scale(1.06);
  filter: brightness(0.42) saturate(1.15) blur(3px);
}
/* the reeded-glass signature: faint vertical flutes over the artwork */
.hero::before {
  content: "";
  background:
    repeating-linear-gradient(90deg,
      rgba(255, 255, 255, 0.055) 0 1px,
      rgba(255, 255, 255, 0.012) 1px 5px,
      rgba(0, 0, 0, 0.10) 5px 13px,
      rgba(255, 255, 255, 0.012) 13px 17px);
  mix-blend-mode: screen;
}
.hero::after {
  content: "";
  background: linear-gradient(180deg,
    rgba(10, 13, 18, 0.15) 0%,
    rgba(10, 13, 18, 0) 35%,
    var(--ink) 96%);
}
.hero .wrap { position: relative; z-index: 2; text-align: center; }
.hero h1 {
  font-size: clamp(2.5rem, 6.4vw, 4.4rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.028em;
  margin: 20px auto 22px;
  max-width: 15ch;
}
.hero .lede {
  color: var(--muted);
  font-size: clamp(1.02rem, 1.5vw, 1.18rem);
  max-width: 56ch;
  margin: 0 auto 36px;
}
.hero .lede strong { color: var(--text); font-weight: 500; }

.cta-row {
  display: flex; align-items: center; justify-content: center;
  gap: 22px; flex-wrap: wrap;
  margin-bottom: 84px;
}
.badge-appstore {
  display: inline-flex; align-items: center; gap: 11px;
  padding: 13px 22px;
  border-radius: 999px;
  background: var(--text);
  color: var(--ink);
  font-weight: 600;
  font-size: 0.98rem;
  line-height: 1.2;
  transition: transform 0.15s ease;
}
.badge-appstore:hover { color: var(--ink); transform: translateY(-1px); }
.badge-appstore svg { width: 19px; height: 19px; flex: none; }
.badge-appstore small {
  display: block; font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.04em; text-transform: uppercase; opacity: 0.6;
}
.cta-secondary { color: var(--text); font-size: 0.98rem; }
.cta-secondary span { color: var(--teal); }

.hero-shot { position: relative; z-index: 2; }
.hero-shot img {
  width: min(1040px, 100%);
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.55);
}
.hero-shot figcaption {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--muted);
  text-align: center;
  padding: 18px 0 0;
}

/* ------------------------------------------------------------ effects */

.effects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 22px;
}
.effect-card {
  background: var(--raised);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
}
.effect-card img {
  aspect-ratio: 16 / 10;
  width: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.effect-card:hover img { transform: scale(1.03); }
@media (prefers-reduced-motion: reduce) {
  .effect-card img, .effect-card:hover img { transition: none; transform: none; }
}
.effect-card .body { padding: 18px 20px 16px; }
.effect-card h3 { font-size: 1.12rem; margin-bottom: 6px; }
.effect-card p { color: var(--muted); font-size: 0.92rem; line-height: 1.5; }
.effect-card .params {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--teal-dim);
  border-top: 1px solid var(--line);
  padding: 12px 20px;
}
.effects-note {
  margin-top: 26px;
  color: var(--muted);
  font-size: 0.95rem;
}
.effects-note strong { color: var(--text); font-weight: 500; }

/* ----------------------------------------------------------- compare */

.compare {
  position: relative;
  max-width: 980px;
  margin: 0 auto;
  aspect-ratio: 16 / 10;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--line);
  touch-action: none;
  --pos: 50%;
}
.compare img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  user-select: none;
  -webkit-user-drag: none;
}
.compare .after { clip-path: inset(0 0 0 var(--pos)); }
.compare .divider {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--pos);
  width: 2px;
  background: rgba(233, 237, 242, 0.85);
  transform: translateX(-1px);
  pointer-events: none;
}
.compare .divider::after {
  content: "⇤⇥";
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 46px; height: 46px;
  border-radius: 50%;
  background: rgba(10, 13, 18, 0.8);
  border: 1px solid rgba(233, 237, 242, 0.5);
  backdrop-filter: blur(6px);
  color: var(--text);
  font-size: 0.9rem;
  display: grid; place-items: center;
  letter-spacing: -0.05em;
}
.compare .tag {
  position: absolute;
  bottom: 14px;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(10, 13, 18, 0.65);
  backdrop-filter: blur(6px);
  pointer-events: none;
}
.compare .tag.before { left: 14px; }
.compare .tag.after-tag { right: 14px; color: var(--teal); }
.compare input[type="range"] {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: 0;
  cursor: ew-resize;
  margin: 0;
}
.compare-caption {
  text-align: center;
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 18px;
}

/* -------------------------------------------------------------- steps */

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 40px;
}
.step .num {
  font-family: var(--display);
  font-size: 2.6rem;
  font-weight: 250;
  color: var(--teal);
  line-height: 1;
}
.step h3 { font-size: 1.15rem; margin: 16px 0 8px; }
.step p { color: var(--muted); font-size: 0.95rem; }

/* ---------------------------------------------------------- platforms */

.platforms {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 22px;
}
.plat-card {
  background: var(--raised);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 26px;
  overflow: hidden;
}
.plat-card h3 { font-size: 1.15rem; margin-bottom: 6px; }
.plat-card p { color: var(--muted); font-size: 0.92rem; margin-bottom: 22px; }
.plat-card img { border-radius: 8px; border: 1px solid var(--line); }
.plat-mac { display: flex; flex-direction: column; }
.plat-mac img { width: 100%; margin-top: auto; }
.plat-phone { display: flex; flex-direction: column; }
.plat-phone img {
  width: min(240px, 70%);
  margin: auto auto 0;
  border-radius: 24px;
}
.plat-ipad { grid-column: 1 / -1; }
.plat-ipad img { width: min(760px, 100%); margin: 0 auto; }
.plat-chips {
  margin-top: 26px;
  display: flex; flex-wrap: wrap; gap: 10px;
}
.plat-chips span {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 14px;
}

/* ------------------------------------------------------------- photos */

.photos { background: var(--ink-2); }
.photo-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.photo-grid a {
  position: relative;
  display: block;
  aspect-ratio: 3 / 2;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
}
.photo-grid img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.photo-grid a:hover img { transform: scale(1.04); }
@media (prefers-reduced-motion: reduce) {
  .photo-grid img, .photo-grid a:hover img { transition: none; transform: none; }
}
.photo-grid figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 26px 12px 9px;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  color: var(--text);
  background: linear-gradient(180deg, transparent, rgba(10, 13, 18, 0.75));
  opacity: 0;
  transition: opacity 0.25s ease;
}
.photo-grid a:hover figcaption,
.photo-grid a:focus-visible figcaption { opacity: 1; }

.pack-row {
  margin-top: 34px;
  display: flex; align-items: center; gap: 20px; flex-wrap: wrap;
}
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 24px;
  border-radius: 999px;
  border: 1px solid var(--teal-dim);
  color: var(--teal);
  font-weight: 600;
  font-size: 0.95rem;
  transition: background 0.15s ease, color 0.15s ease;
}
.btn:hover { background: var(--teal); color: var(--ink); }
.license-note { color: var(--muted); font-size: 0.88rem; max-width: 46ch; }
.license-note a { color: var(--sand); }

/* ----------------------------------------------------------- lightbox */

.lightbox {
  position: fixed; inset: 0;
  z-index: 50;
  background: rgba(6, 8, 11, 0.92);
  backdrop-filter: blur(10px);
  display: none;
  place-items: center;
  padding: 4vh 4vw;
}
.lightbox.open { display: grid; }
.lightbox img {
  max-width: 100%;
  max-height: 82vh;
  border-radius: 10px;
}
.lightbox .lb-bar {
  margin-top: 16px;
  display: flex; align-items: center; gap: 22px;
  font-family: var(--mono); font-size: 0.78rem;
  color: var(--muted);
}
.lightbox .lb-bar a { color: var(--teal); }
.lightbox .lb-close {
  position: absolute; top: 20px; right: 26px;
  font-size: 1.6rem; line-height: 1;
  background: none; border: none;
  color: var(--muted); cursor: pointer;
  padding: 8px;
}
.lightbox .lb-close:hover { color: var(--text); }

/* ----------------------------------------------------- privacy strip */

.privacy-strip { text-align: center; }
.privacy-strip h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin: 14px 0 16px; }
.privacy-strip p { color: var(--muted); max-width: 52ch; margin: 0 auto 22px; }

/* -------------------------------------------------------------- footer */

footer {
  border-top: 1px solid var(--line);
  padding: 44px 0 60px;
  color: var(--muted);
  font-size: 0.9rem;
}
footer .wrap {
  display: flex; align-items: center; gap: 24px; flex-wrap: wrap;
}
footer .foot-links { margin-left: auto; display: flex; gap: 22px; }
footer a { color: var(--muted); }
footer a:hover { color: var(--text); }

/* ------------------------------------------------------- inner pages */

.page { padding: 150px 0 90px; max-width: 720px; }
.page h1 { font-size: clamp(2rem, 4.6vw, 2.8rem); margin: 14px 0 10px; }
.page .updated { font-family: var(--mono); font-size: 0.75rem; color: var(--muted); }
.page h2 { font-size: 1.3rem; margin: 42px 0 12px; }
.page p, .page li { color: var(--muted); }
.page p { margin: 14px 0; }
.page ul { margin: 14px 0 14px 22px; }
.page li { margin: 8px 0; }
.page strong { color: var(--text); font-weight: 600; }
.page .card {
  background: var(--raised);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 24px;
  margin: 26px 0;
}
.page .card p { margin: 6px 0; }

/* --------------------------------------------------------- reveal anim */

/* hidden state only when JS is running (html.js), so content is never lost */
.js .reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
}

/* ------------------------------------------------------------- mobile */

@media (max-width: 900px) {
  section { padding: 72px 0; }
  .platforms { grid-template-columns: 1fr; }
  .photo-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 600px) {
  .nav-links a:not(.nav-keep) { display: none; }
  .hero { padding-top: 130px; }
  .hero .lede { font-size: 1rem; }
  .cta-row { margin-bottom: 60px; }
  .photo-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .plat-card { padding: 20px; }
  footer .wrap { flex-direction: column; align-items: flex-start; gap: 14px; }
  footer .foot-links { margin-left: 0; }
}
