/* Roomy website — palette mirrors the iOS app (blue #2F6BFF / mint #14B88F) */
:root {
  --accent-primary: #2F6BFF;
  --accent-secondary: #14B88F;
  --bg-primary: #F5F7FB;
  --bg-surface: #FFFFFF;
  --bg-elevated: #EEF2FA;
  --text-primary: #0E1525;
  --text-secondary: #5A6478;
  --border: rgba(14, 21, 37, 0.08);
  --nav-bg: rgba(245, 247, 251, 0.72);
  --shadow: 0 20px 50px -20px rgba(31, 60, 140, 0.28);
  --radius: 20px;
  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', Arial, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --accent-primary: #5B8CFF;
    --accent-secondary: #2FD3A8;
    --bg-primary: #0B0F17;
    --bg-surface: #141A26;
    --bg-elevated: #1B2232;
    --text-primary: #F2F5FB;
    --text-secondary: #9AA4B8;
    --border: rgba(255, 255, 255, 0.08);
    --nav-bg: rgba(11, 15, 23, 0.7);
    --shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.7);
  }
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body {
  font-family: var(--font);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--accent-primary); outline-offset: 3px; border-radius: 6px; }
.container { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--bg-surface); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }

/* Navbar — frosted glass */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: var(--nav-bg);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav .container { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.1rem; color: var(--text-primary); }
.brand:hover { text-decoration: none; }
.brand-mark { width: 30px; height: 30px; background: url("/app-icon.png") center / contain no-repeat; }
.nav-links { display: flex; align-items: center; gap: 22px; list-style: none; font-size: .95rem; }
.nav-links a { color: var(--text-secondary); }
.nav-links a:hover { color: var(--text-primary); text-decoration: none; }
@media (max-width: 600px) { .nav-links .hide-sm { display: none; } .nav-links { gap: 16px; } }

/* Hero */
.hero { padding: 72px 0 56px; overflow: hidden; }
.hero .container { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; }
.hero .container > * { min-width: 0; }
@media (max-width: 860px) { .hero .container { grid-template-columns: 1fr; text-align: center; } .hero-cta { justify-content: center; } }
.eyebrow { display: inline-block; font-size: .8rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--accent-secondary); margin-bottom: 14px; }
h1, .h1-like { font-size: clamp(2.3rem, 5.5vw, 3.6rem); line-height: 1.08; letter-spacing: -0.025em; font-weight: 800; }
h1 .grad, .h1-like .grad { background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { margin-top: 18px; font-size: 1.15rem; color: var(--text-secondary); max-width: 34em; }
@media (max-width: 860px) { .lead { margin-left: auto; margin-right: auto; } }
.hero-cta { margin-top: 28px; display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.price-note { font-size: .9rem; color: var(--text-secondary); }

/* App Store badge (placeholder until approval) */
.appstore-badge { display: inline-flex; align-items: center; gap: 10px; background: #000; color: #fff; border-radius: 12px; padding: 9px 18px 9px 14px; border: 1px solid rgba(255,255,255,.18); line-height: 1.1; }
.appstore-badge:hover { text-decoration: none; }
.appstore-badge svg { width: 26px; height: 26px; fill: #fff; }
.appstore-badge small { display: block; font-size: .68rem; letter-spacing: .02em; }
.appstore-badge strong { display: block; font-size: 1.2rem; font-weight: 600; letter-spacing: -.01em; }
.appstore-badge[data-appstore-pending] { opacity: .55; cursor: not-allowed; pointer-events: none; }
.pending-label { font-size: .8rem; color: var(--text-secondary); }

/* CSS-only front-screen mockup
   TODO: replace with real screenshots from the iPhone Duo front screen once available. */
.mockup { display: flex; justify-content: center; }
.device {
  width: min(300px, 78vw); aspect-ratio: 9 / 16;
  border-radius: 44px; padding: 12px;
  background: linear-gradient(160deg, #2a2f3a, #10131a);
  box-shadow: var(--shadow), inset 0 0 0 2px rgba(255,255,255,.08);
}
.screen {
  height: 100%; border-radius: 34px; overflow: hidden; position: relative;
  background: var(--bg-surface); display: flex;
}
.sidebar {
  width: 22%; background: var(--bg-elevated); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; align-items: center; gap: 14px; padding-top: 40px;
}
.sidebar i { display: block; width: 22px; height: 22px; border-radius: 7px; background: var(--border); }
.sidebar i:first-child { background: var(--accent-primary); opacity: .85; }
.page { flex: 1; position: relative; padding: 36px 0 0; }
.page-inner {
  margin: 0 auto; width: 58%; padding: 0 10px;
  animation: widen 5s ease-in-out infinite alternate;
}
.page-bar { height: 22px; border-radius: 6px; background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary)); margin-bottom: 14px; animation: barhide 5s ease-in-out infinite alternate; }
.page-img { height: 70px; border-radius: 8px; background: var(--bg-elevated); margin-bottom: 12px; }
.page-line { height: 7px; border-radius: 4px; background: var(--border); margin-bottom: 8px; }
.page-line.s { width: 70%; }
.gap-hint { position: absolute; top: 36px; bottom: 0; width: 18%; border: 2px dashed var(--accent-secondary); border-radius: 10px; opacity: 0; animation: gap 5s ease-in-out infinite alternate; }
.gap-hint.l { left: 4px; } .gap-hint.r { right: 4px; }
@keyframes widen { 0%, 30% { width: 58%; } 70%, 100% { width: 100%; } }
@keyframes barhide { 0%, 40% { opacity: 1; transform: none; } 80%, 100% { opacity: .35; transform: translateY(-4px); } }
@keyframes gap { 0%, 20% { opacity: .9; } 55%, 100% { opacity: 0; } }
.mockup-caption { text-align: center; font-size: .82rem; color: var(--text-secondary); margin-top: 14px; }

/* Sections */
section { padding: 64px 0; }
.section-title { font-size: clamp(1.7rem, 3.5vw, 2.3rem); letter-spacing: -0.02em; line-height: 1.15; font-weight: 750; text-align: center; }
.section-sub { text-align: center; color: var(--text-secondary); max-width: 40em; margin: 12px auto 0; }
.grid { display: grid; gap: 18px; margin-top: 40px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card {
  background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px; transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--accent-primary) 35%, transparent); }
.card h3 { font-size: 1.12rem; margin: 14px 0 6px; letter-spacing: -0.01em; }
.card p { color: var(--text-secondary); font-size: .97rem; }
.icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--accent-primary) 14%, transparent); color: var(--accent-primary); }
.icon.mint { background: color-mix(in srgb, var(--accent-secondary) 16%, transparent); color: var(--accent-secondary); }
.icon svg { width: 24px; height: 24px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.option-num { font-size: .78rem; font-weight: 700; color: var(--accent-primary); letter-spacing: .05em; text-transform: uppercase; }

.steps { counter-reset: step; list-style: none; max-width: 640px; margin: 36px auto 0; display: grid; gap: 14px; }
.steps li { counter-increment: step; background: var(--bg-surface); border: 1px solid var(--border); border-radius: 16px; padding: 16px 18px 16px 62px; position: relative; color: var(--text-secondary); }
.steps li strong { color: var(--text-primary); }
.steps li::before { content: counter(step); position: absolute; left: 16px; top: 14px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary)); }

.privacy-callout {
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent-primary) 12%, var(--bg-surface)), color-mix(in srgb, var(--accent-secondary) 12%, var(--bg-surface)));
  border: 1px solid var(--border); border-radius: 28px; padding: 44px 28px; text-align: center;
}
.privacy-callout p { color: var(--text-secondary); max-width: 38em; margin: 12px auto 0; }
.pills { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 22px; list-style: none; }
.pills li { background: var(--bg-surface); border: 1px solid var(--border); border-radius: 999px; padding: 6px 14px; font-size: .9rem; font-weight: 500; }

.download { text-align: center; }
.download .hero-cta { justify-content: center; }
.note { font-size: .88rem; color: var(--text-secondary); margin-top: 16px; text-align: center; }

/* Legal / content pages */
.content { padding: 56px 0 72px; }
.content .container { max-width: 780px; }
.content h1 { font-size: clamp(2rem, 4.5vw, 2.6rem); margin-bottom: 8px; }
.content h2 { font-size: 1.3rem; margin: 34px 0 10px; letter-spacing: -0.01em; }
.content h3 { font-size: 1.05rem; margin: 22px 0 6px; }
.content p, .content li { color: var(--text-secondary); margin-bottom: 10px; }
.content ul { padding-left: 22px; }
.content address { font-style: normal; color: var(--text-secondary); margin-bottom: 10px; }
.meta { color: var(--text-secondary); font-size: .9rem; }

.lang-toggle { display: inline-flex; background: var(--bg-elevated); border-radius: 999px; padding: 4px; margin: 18px 0 8px; border: 1px solid var(--border); }
.lang-toggle button { border: 0; background: transparent; color: var(--text-secondary); font: inherit; font-weight: 600; font-size: .9rem; padding: 6px 16px; border-radius: 999px; cursor: pointer; }
.lang-toggle button[aria-pressed="true"] { background: var(--bg-surface); color: var(--text-primary); box-shadow: 0 1px 4px rgba(0,0,0,.12); }
[data-lang-section][hidden] { display: none; }

.contact-card { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; text-align: center; margin: 28px 0; }
.contact-card .btn { display: inline-block; margin-top: 14px; background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary)); color: #fff; font-weight: 600; padding: 12px 24px; border-radius: 12px; }
.contact-card .btn:hover { text-decoration: none; filter: brightness(1.05); }

details { background: var(--bg-surface); border: 1px solid var(--border); border-radius: 14px; padding: 4px 18px; margin-bottom: 10px; }
details summary { cursor: pointer; font-weight: 600; padding: 12px 0; color: var(--text-primary); list-style-position: outside; }
details p { padding-bottom: 8px; }

/* Footer */
footer { border-top: 1px solid var(--border); padding: 32px 0 40px; font-size: .9rem; color: var(--text-secondary); }
footer .container { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; }
footer nav ul { display: flex; gap: 18px; list-style: none; flex-wrap: wrap; }
footer a { color: var(--text-secondary); }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.visible { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }
.h1-sub { display: block; font-size: .45em; font-weight: 500; color: var(--text-secondary); letter-spacing: 0; margin-top: 4px; }

/* Hero screenshots */
.shots { display: flex; justify-content: center; gap: 16px; }
.shots img { width: min(46%, 260px); height: auto; border-radius: 28px; border: 1px solid color-mix(in srgb, var(--text-primary) 10%, transparent); box-shadow: 0 24px 48px -20px rgba(20, 40, 110, .35); background: var(--bg-surface); }
.shots figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 10px; width: min(46%, 260px); }
.shots figure img { width: 100%; }
.shots figcaption { font-size: .85rem; font-weight: 600; color: var(--text-secondary); }
.shots figure.after figcaption { color: var(--accent-secondary); }
.shots figure.after img { outline: 3px solid var(--accent-secondary); outline-offset: 3px; }
