/* Roomier — site styles. Dark, glass, spacious. Mirrors the app's design tokens (lib/theme.ts). */

:root {
  --ink: #0f1115;
  --ink-2: #14171d;
  --ink-3: #1b1f27;
  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.62);
  --faint: rgba(255, 255, 255, 0.4);
  --line: rgba(255, 255, 255, 0.14);
  --line-strong: rgba(255, 255, 255, 0.24);
  --glass: rgba(255, 255, 255, 0.06);
  --glass-2: rgba(255, 255, 255, 0.1);
  --amber: #ffb15c;
  --teal: #5ad7c8;
  --coral: #ff6b5e;
  --green: #4fd68a;
  --blue: #6cb8ff;
  --radius: 26px;
  --radius-sm: 18px;
  --display: "Bricolage Grotesque", "Avenir Next", "Helvetica Neue", sans-serif;
  --body: "Instrument Sans", "Avenir Next", "Helvetica Neue", sans-serif;
  --max: 1160px;
  --gutter: clamp(20px, 5vw, 48px);
}

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

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Atmosphere: two soft bokeh glows echoing the icon, a vignette and a grain layer. */
.atmosphere {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(52vw 52vw at 8% 0%, rgba(255, 177, 92, 0.22), transparent 60%),
    radial-gradient(48vw 48vw at 100% 18%, rgba(90, 215, 200, 0.16), transparent 60%),
    radial-gradient(60vw 40vw at 50% 100%, rgba(255, 107, 94, 0.08), transparent 60%),
    var(--ink);
}
.atmosphere::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.14;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.5 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 4px; }
img { max-width: 100%; display: block; }

.wrap { width: min(var(--max), 100% - var(--gutter) * 2); margin-inline: auto; }

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 14px 0;
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  background: linear-gradient(rgba(15, 17, 21, 0.72), rgba(15, 17, 21, 0.4));
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 26px;
  letter-spacing: -0.04em;
  line-height: 1;
}
.wordmark img { width: 30px; height: 30px; border-radius: 8px; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4); }
.wordmark:hover { text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 22px; font-weight: 500; color: var(--muted); font-size: 15px; }
.nav-links a:hover { color: var(--text); }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--glass-2);
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); }
@media (max-width: 720px) { .nav-links .hide-sm, .nav .pill { display: none; } .nav-links { gap: 18px; } .wordmark { font-size: 24px; } }

/* ---------- Hero ---------- */
.hero { padding: clamp(56px, 9vw, 120px) 0 clamp(40px, 6vw, 80px); }
.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(44px, 7.2vw, 92px);
  line-height: 0.96;
  letter-spacing: -0.045em;
  margin: 0 0 24px;
  font-variation-settings: "opsz" 96;
}
h1 .soft { color: var(--muted); font-weight: 600; }
.lede { font-size: clamp(18px, 1.6vw, 21px); color: var(--muted); max-width: 34ch; margin: 0 0 32px; }
.lede strong { color: var(--text); font-weight: 600; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 16px;
  line-height: 1;
  border: 1px solid var(--line-strong);
  background: var(--glass-2);
  transition: transform 0.18s ease, background 0.18s ease;
}
.btn:hover { text-decoration: none; background: rgba(255, 255, 255, 0.16); transform: translateY(-1px); }
.btn.primary { background: var(--text); color: var(--ink); border-color: var(--text); }
.btn.primary:hover { background: #f2f2f2; }
.btn.soon { cursor: default; }
.btn.soon:hover { transform: none; }
.btn svg { width: 18px; height: 18px; }
.trust { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--faint); font-size: 14px; font-weight: 500; }
.trust span::before { content: "•"; color: var(--green); margin-right: 8px; }

/* Phone stage */
.stage { position: relative; display: grid; place-items: center; min-height: 420px; }
.phone {
  position: relative;
  width: min(340px, 78vw);
  aspect-ratio: 1206 / 2622;
  border-radius: clamp(38px, 12%, 54px);
  padding: 9px;
  background: linear-gradient(160deg, #3a3f49, #0c0e12 45%, #2a2e36);
  box-shadow:
    0 40px 90px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(255, 255, 255, 0.08),
    inset 0 0 0 1px rgba(255, 255, 255, 0.08);
  transform: rotate(-4deg);
}
.phone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: clamp(30px, 10%, 46px);
  background: #000;
}
.phone.flat { transform: none; }
.phone.small { width: min(260px, 70vw); padding: 7px; }
.float {
  position: absolute;
  padding: 12px 16px;
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: rgba(20, 23, 29, 0.72);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  font-weight: 600;
  font-size: 14px;
  line-height: 1.2;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: floaty 6s ease-in-out infinite;
}
.float small { display: block; color: var(--muted); font-weight: 500; font-size: 12px; margin-top: 3px; }
.float .ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--text); color: var(--ink); font-size: 15px; }
.float.a { top: 10%; left: -6%; animation-delay: -1s; }
.float.b { bottom: 24%; right: -8%; animation-delay: -3s; }
.float.c { bottom: 5%; left: 0; animation-delay: -5s; }
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .stage { min-height: 0; margin-top: 12px; }
  .float.a { left: 0; }
  .float.b { right: 0; }
}

/* Storage bar demo */
.bar {
  margin-top: 36px;
  padding: 16px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--glass);
  max-width: 440px;
}
.bar .row { display: flex; justify-content: space-between; font-weight: 600; font-size: 15px; }
.bar .row span:last-child { color: var(--muted); font-weight: 500; }
.bar .track { height: 8px; border-radius: 999px; background: rgba(255, 255, 255, 0.12); margin: 12px 0 10px; overflow: hidden; }
.bar .fill { height: 100%; width: 92%; border-radius: 999px; background: linear-gradient(90deg, #fff, #d9dde6); animation: shrink 2.6s cubic-bezier(0.2, 0.8, 0.2, 1) 0.9s forwards; }
.bar .legend { display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--muted); font-size: 13px; font-weight: 500; }
.bar .legend span { white-space: nowrap; }
.bar .legend b { color: var(--text); font-weight: 600; }

/* ---------- Sections ---------- */
section { padding: clamp(48px, 7vw, 104px) 0; }
h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(32px, 4.4vw, 54px);
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin: 0 0 14px;
}
.sub { color: var(--muted); font-size: clamp(17px, 1.4vw, 19px); max-width: 52ch; margin: 0 0 40px; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.step {
  position: relative;
  padding: 26px 24px 0;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, var(--glass-2), var(--glass));
  overflow: hidden;
  min-height: 560px;
  display: flex;
  flex-direction: column;
}
.step .n { font-family: var(--display); font-weight: 700; font-size: 13px; letter-spacing: 0.08em; color: var(--faint); margin-bottom: 10px; }
.step h3 { font-family: var(--display); font-size: 24px; letter-spacing: -0.025em; margin: 0 0 8px; line-height: 1.1; }
.step p { color: var(--muted); margin: 0 0 22px; font-size: 15.5px; }
.step .shot { margin-top: auto; margin-inline: auto; width: 78%; border-radius: 28px 28px 0 0; overflow: hidden; border: 1px solid var(--line-strong); border-bottom: 0; box-shadow: 0 -20px 50px rgba(0, 0, 0, 0.35); }
.step .shot img { width: 100%; aspect-ratio: 1206 / 1900; object-fit: cover; object-position: top; }
@media (max-width: 900px) { .steps { grid-template-columns: 1fr; } .step { min-height: 0; } .step .shot { width: 70%; } .step .shot img { aspect-ratio: 1206 / 1400; } }

/* Feature grid */
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.card {
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--glass);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}
.card:hover { border-color: var(--line-strong); background: var(--glass-2); transform: translateY(-2px); }
.card .ic {
  width: 44px; height: 44px; border-radius: 14px;
  display: grid; place-items: center;
  background: var(--text); color: var(--ink);
  margin-bottom: 18px;
}
.card .ic svg { width: 22px; height: 22px; }
.card h3 { font-family: var(--display); font-size: 21px; letter-spacing: -0.02em; margin: 0 0 6px; }
.card p { color: var(--muted); margin: 0; font-size: 15.5px; }
.card .tag { display: inline-block; margin-top: 14px; padding: 4px 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.12); font-size: 12px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.card.wide { grid-column: span 2; display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; }
.card.wide .phone { width: 150px; padding: 5px; border-radius: 26px; }
.card.wide .phone img { border-radius: 21px; }
@media (max-width: 900px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .card.wide { grid-column: span 2; } }
@media (max-width: 600px) { .grid { grid-template-columns: 1fr; } .card.wide { grid-column: span 1; grid-template-columns: 1fr; } .card.wide .phone { display: none; } }

/* Privacy band */
.band {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(135deg, rgba(90, 215, 200, 0.12), rgba(255, 177, 92, 0.08) 60%, var(--glass));
  padding: clamp(28px, 4vw, 52px);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 32px;
  align-items: center;
}
.band h2 { margin-bottom: 12px; }
.band p { color: var(--muted); margin: 0 0 20px; }
.facts { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.facts li { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 16px; background: rgba(15, 17, 21, 0.45); border: 1px solid var(--line); font-weight: 500; }
.facts li svg { flex: none; width: 20px; height: 20px; color: var(--green); margin-top: 2px; }
.facts li span { color: var(--text); }
.facts li small { display: block; color: var(--muted); font-weight: 400; margin-top: 2px; }
@media (max-width: 900px) { .band { grid-template-columns: 1fr; } }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.plan {
  position: relative;
  padding: 26px 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--glass);
  display: flex;
  flex-direction: column;
}
.plan.best { border-color: rgba(255, 255, 255, 0.6); background: linear-gradient(180deg, rgba(255, 255, 255, 0.14), var(--glass)); }
.plan .badge { position: absolute; top: -12px; right: 20px; padding: 5px 11px; border-radius: 999px; background: var(--text); color: var(--ink); font-size: 12px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
.plan .name { font-family: var(--display); font-weight: 700; font-size: 20px; letter-spacing: -0.02em; }
.plan .price { font-family: var(--display); font-weight: 800; font-size: 44px; letter-spacing: -0.04em; line-height: 1; margin: 14px 0 4px; }
.plan .price small { font-size: 16px; font-weight: 600; color: var(--muted); letter-spacing: 0; margin-left: 4px; }
.plan .per { color: var(--muted); font-size: 14px; margin-bottom: 18px; min-height: 20px; }
.plan ul { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 8px; color: var(--muted); font-size: 15px; }
.plan ul li::before { content: "✓"; color: var(--green); font-weight: 700; margin-right: 10px; }
.plan .foot { margin-top: auto; color: var(--faint); font-size: 13px; }
.free {
  margin-top: 16px;
  padding: 18px 22px;
  border-radius: var(--radius-sm);
  border: 1px dashed var(--line-strong);
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  align-items: baseline;
}
.free b { color: var(--text); font-weight: 700; }
.fine { color: var(--faint); font-size: 13.5px; margin-top: 18px; max-width: 70ch; }
@media (max-width: 900px) { .plans { grid-template-columns: 1fr; } }

/* FAQ */
.faq { display: grid; gap: 10px; max-width: 820px; }
details { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--glass); padding: 0 20px; }
details[open] { background: var(--glass-2); }
summary { cursor: pointer; list-style: none; padding: 18px 0; font-weight: 600; font-size: 17px; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-family: var(--display); font-size: 24px; color: var(--muted); line-height: 1; transition: transform 0.2s ease; }
details[open] summary::after { transform: rotate(45deg); }
details p { margin: 0 0 18px; color: var(--muted); }

/* Footer */
footer { padding: 40px 0 56px; border-top: 1px solid rgba(255, 255, 255, 0.08); color: var(--faint); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px 24px; align-items: center; }
footer nav { display: flex; flex-wrap: wrap; gap: 18px; }
footer a { color: var(--muted); }
footer a:hover { color: var(--text); }

/* ---------- Legal pages ---------- */
.legal { padding: clamp(40px, 6vw, 80px) 0 80px; }
.legal .wrap { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 48px; align-items: start; }
.toc { position: sticky; top: 90px; display: grid; gap: 8px; font-size: 14px; color: var(--muted); }
.toc a { padding: 6px 10px; border-radius: 10px; }
.toc a:hover { background: var(--glass-2); color: var(--text); text-decoration: none; }
.doc { max-width: 72ch; }
.doc h1 { font-size: clamp(36px, 5vw, 60px); margin-bottom: 8px; }
.doc .meta { color: var(--faint); font-size: 14px; margin-bottom: 36px; }
.doc h2 { font-size: 26px; margin: 44px 0 12px; letter-spacing: -0.02em; scroll-margin-top: 90px; }
.doc h3 { font-family: var(--display); font-size: 19px; margin: 26px 0 8px; letter-spacing: -0.015em; }
.doc p, .doc li { color: rgba(255, 255, 255, 0.78); }
.doc ul { padding-left: 22px; }
.doc li { margin: 6px 0; }
.doc .callout { border: 1px solid var(--line-strong); background: var(--glass-2); border-radius: var(--radius-sm); padding: 18px 20px; margin: 24px 0; }
.doc .callout p { margin: 0; color: var(--text); }
.doc table { width: 100%; border-collapse: collapse; font-size: 15px; margin: 16px 0; }
.doc th, .doc td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.doc th { color: var(--muted); font-weight: 600; font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; }
.doc a { color: var(--text); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--faint); }
@media (max-width: 900px) { .legal .wrap { grid-template-columns: 1fr; } .toc { position: static; display: flex; flex-wrap: wrap; } }

/* ---------- Motion ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes shrink { to { width: 38%; } }
.rise { animation: rise 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.rise.d1 { animation-delay: 0.08s; }
.rise.d2 { animation-delay: 0.18s; }
.rise.d3 { animation-delay: 0.3s; }
.rise.d4 { animation-delay: 0.42s; }
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .rise, .float, .bar .fill { animation: none !important; }
  .bar .fill { width: 38%; }
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
