/* Roomr — public website
   Matches the app's purple-gradient identity. No JS, no dependencies. */

:root {
  --bg: #fafafe;
  --bg-soft: #f3f1fb;
  --surface: #ffffff;
  --surface-elev: #ffffff;
  --text: #14121d;
  --text-soft: #5a5468;
  --text-muted: #8a8499;
  --border: #ebe7f3;
  --border-strong: #ddd6ec;

  --brand-1: #a78bfa;
  --brand-2: #7c5cff;
  --brand-3: #5d3ee8;
  --brand-soft: rgba(124, 92, 255, 0.10);
  --brand-glow: rgba(124, 92, 255, 0.35);

  --accent-pink: #ff7eb0;

  --radius-sm: 12px;
  --radius: 18px;
  --radius-lg: 28px;

  --shadow-sm: 0 2px 12px rgba(40, 28, 80, 0.06);
  --shadow-md: 0 8px 28px rgba(40, 28, 80, 0.10);
  --shadow-glow: 0 20px 60px rgba(124, 92, 255, 0.35);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0a14;
    --bg-soft: #14121f;
    --surface: #181626;
    --surface-elev: #1f1c30;
    --text: #f5f3fb;
    --text-soft: #b9b3cb;
    --text-muted: #7c7591;
    --border: #2a2640;
    --border-strong: #36314e;

    --brand-1: #b9a4ff;
    --brand-2: #9b82ff;
    --brand-3: #c5b3ff;
    --brand-soft: rgba(155, 130, 255, 0.16);
    --brand-glow: rgba(155, 130, 255, 0.45);

    --shadow-sm: 0 2px 12px rgba(0, 0, 0, 0.40);
    --shadow-md: 0 12px 40px rgba(0, 0, 0, 0.55);
    --shadow-glow: 0 24px 80px rgba(124, 92, 255, 0.55);
  }
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a {
  color: var(--brand-2);
  text-decoration: none;
  transition: color 120ms ease;
}
a:hover { color: var(--brand-3); }

img, svg { max-width: 100%; display: block; }

/* ─── Layout ─────────────────────────────────────────────────────────── */

.container {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-narrow {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ─── Header ─────────────────────────────────────────────────────────── */

header.site-header {
  padding: 24px 0;
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(250, 250, 254, 0.75);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease;
}
@media (prefers-color-scheme: dark) {
  header.site-header {
    background: rgba(11, 10, 20, 0.75);
  }
}
header.site-header.scrolled {
  border-bottom-color: var(--border);
}

.site-header .nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  font-weight: 700;
  letter-spacing: -0.01em;
  font-size: 19px;
}
.brand:hover { color: var(--text); }
.brand-mark {
  width: 32px; height: 32px;
  border-radius: 9px;
  box-shadow: 0 4px 12px var(--brand-glow);
}

nav.top-links {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  font-size: 15px;
}
nav.top-links a {
  color: var(--text-soft);
  font-weight: 500;
}
nav.top-links a:hover { color: var(--text); }

main {
  padding: 64px 0 96px;
}

footer.site-footer {
  border-top: 1px solid var(--border);
  padding: 36px 0;
  margin-top: 64px;
  color: var(--text-muted);
  font-size: 14px;
}
.site-footer .footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.site-footer a { color: var(--text-muted); }
.site-footer a:hover { color: var(--text-soft); }

/* ─── Hero (index) ───────────────────────────────────────────────────── */

.hero {
  position: relative;
  text-align: center;
  padding: 32px 0 40px;
}

.hero::before {
  content: "";
  position: absolute;
  top: -60px; left: 50%;
  transform: translateX(-50%);
  width: 520px; height: 520px;
  background: radial-gradient(circle at center, var(--brand-glow) 0%, transparent 65%);
  filter: blur(60px);
  z-index: -1;
  opacity: 0.7;
  pointer-events: none;
}

.hero-mark {
  width: 112px;
  height: 112px;
  border-radius: 26px;
  margin: 0 auto 28px;
  box-shadow: var(--shadow-glow);
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.hero h1 {
  font-size: clamp(36px, 6.5vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin: 0 0 18px;
  font-weight: 800;
  background: linear-gradient(120deg, var(--text) 0%, var(--brand-2) 60%, var(--accent-pink) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p.lead {
  font-size: clamp(17px, 2.2vw, 20px);
  color: var(--text-soft);
  max-width: 600px;
  margin: 0 auto 32px;
  line-height: 1.5;
}

.cta-row {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 16px;
  border: 0;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease, background 150ms ease, color 150ms ease;
  letter-spacing: -0.01em;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  color: #fff;
  box-shadow: 0 8px 24px var(--brand-glow);
}
.btn-primary:hover {
  box-shadow: 0 12px 32px var(--brand-glow);
  color: #fff;
}
.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-sm);
}
.btn-secondary:hover {
  color: var(--text);
  border-color: var(--brand-2);
}

/* ─── Section title ──────────────────────────────────────────────────── */

.section-title {
  text-align: center;
  margin: 96px 0 40px;
}
.section-title .eyebrow {
  display: inline-block;
  color: var(--brand-2);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.section-title h2 {
  font-size: clamp(28px, 4vw, 38px);
  margin: 0;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

/* ─── Feature grid ───────────────────────────────────────────────────── */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
}
.feature {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}
.feature:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}
.feature .feature-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  margin-bottom: 18px;
  box-shadow: 0 6px 16px var(--brand-glow);
}
.feature .feature-icon svg {
  width: 22px; height: 22px;
}
.feature h3 {
  margin: 0 0 8px;
  font-size: 18px;
  letter-spacing: -0.01em;
  font-weight: 700;
}
.feature p {
  margin: 0;
  font-size: 15px;
  color: var(--text-soft);
  line-height: 1.55;
}

/* ─── Trust callout ──────────────────────────────────────────────────── */

.trust {
  margin: 96px 0 0;
  background: linear-gradient(135deg, var(--brand-soft), transparent);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 48px;
  text-align: center;
}
.trust h2 {
  font-size: clamp(24px, 3.4vw, 32px);
  margin: 0 0 12px;
  letter-spacing: -0.02em;
}
.trust p {
  color: var(--text-soft);
  margin: 0 auto 24px;
  max-width: 560px;
}

/* ─── Document pages (privacy / terms / support) ─────────────────────── */

.doc {
  max-width: 720px;
}
.doc-header {
  text-align: center;
  margin-bottom: 48px;
  padding: 32px 0 16px;
  position: relative;
}
.doc-header::before {
  content: "";
  position: absolute;
  top: -40px; left: 50%;
  transform: translateX(-50%);
  width: 380px; height: 380px;
  background: radial-gradient(circle, var(--brand-glow) 0%, transparent 60%);
  filter: blur(80px);
  z-index: -1;
  opacity: 0.45;
  pointer-events: none;
}
.doc-header h1 {
  font-size: clamp(34px, 5vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
  font-weight: 800;
}
.doc-header .updated {
  color: var(--text-muted);
  font-size: 14px;
  letter-spacing: 0.02em;
  margin: 0;
}

.doc h2 {
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand-2);
  margin: 44px 0 12px;
  font-weight: 700;
}
.doc p, .doc li {
  color: var(--text-soft);
  font-size: 16.5px;
  line-height: 1.7;
}
.doc p { margin: 0 0 14px; }
.doc ul {
  padding-left: 22px;
  margin: 8px 0 18px;
}
.doc li {
  margin-bottom: 8px;
}
.doc strong { color: var(--text); font-weight: 600; }

/* ─── Contact cards (support page) ───────────────────────────────────── */

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin: 24px 0 56px;
}
.contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
  font: inherit;
  color: inherit;
  text-align: left;
  width: 100%;
}
button.contact-card { cursor: pointer; }
.contact-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}
.contact-card .icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  box-shadow: 0 6px 16px var(--brand-glow);
}
.contact-card .icon svg { width: 22px; height: 22px; }
.contact-card h3 {
  margin: 0 0 6px;
  font-size: 17px;
  letter-spacing: -0.01em;
  font-weight: 700;
}
.contact-card p {
  margin: 0 0 14px;
  color: var(--text-soft);
  font-size: 14.5px;
}
.contact-card .email-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--brand-2);
  font-weight: 600;
  font-size: 14.5px;
}
.contact-card .email-link::after { content: "→"; transition: transform 150ms ease; }
.contact-card:hover .email-link::after { transform: translateX(3px); }

/* ─── FAQ ────────────────────────────────────────────────────────────── */

details.faq {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 22px;
  margin: 12px 0;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}
details.faq[open] {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-sm);
}
details.faq summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--text);
  font-size: 16px;
  list-style: none;
  position: relative;
  padding-right: 28px;
  letter-spacing: -0.005em;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--text-muted);
  border-bottom: 2px solid var(--text-muted);
  transform: translateY(-70%) rotate(45deg);
  transition: transform 200ms ease, border-color 200ms ease;
}
details.faq[open] summary::after {
  transform: translateY(-30%) rotate(225deg);
  border-color: var(--brand-2);
}
details.faq p {
  margin: 14px 0 4px;
  color: var(--text-soft);
  font-size: 15.5px;
  line-height: 1.65;
}

/* ─── Contact modal ──────────────────────────────────────────────────── */

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(20, 18, 29, 0.55);
  backdrop-filter: saturate(180%) blur(8px);
  -webkit-backdrop-filter: saturate(180%) blur(8px);
  z-index: 100;
  padding: 24px;
  animation: fadeIn 180ms ease;
}
.modal.open { display: flex; }

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.modal-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  width: 100%;
  max-width: 480px;
  box-shadow: var(--shadow-glow);
  position: relative;
  animation: slideUp 220ms cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0)    scale(1); }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px; height: 36px;
  border-radius: 10px;
  background: transparent;
  border: 0;
  cursor: pointer;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 120ms ease, color 120ms ease;
}
.modal-close:hover {
  background: var(--brand-soft);
  color: var(--text);
}
.modal-close svg { width: 18px; height: 18px; }

.modal h2 {
  margin: 0 0 6px;
  font-size: 22px;
  letter-spacing: -0.01em;
  font-weight: 700;
}
.modal .modal-sub {
  margin: 0 0 22px;
  color: var(--text-soft);
  font-size: 14.5px;
}

.field {
  display: block;
  margin-bottom: 16px;
}
.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
  letter-spacing: -0.005em;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--bg-soft);
  color: var(--text);
  font: inherit;
  font-size: 15px;
  transition: border-color 120ms ease, background 120ms ease, box-shadow 120ms ease;
}
.field textarea {
  min-height: 110px;
  resize: vertical;
  line-height: 1.5;
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--brand-2);
  background: var(--surface);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
}

.form-status {
  font-size: 14px;
  margin-top: 10px;
  min-height: 20px;
}
.form-status.success { color: #2dba6c; }
.form-status.error   { color: #ff5c7a; }

/* ─── Responsive tweaks ──────────────────────────────────────────────── */

@media (max-width: 640px) {
  main { padding: 40px 0 64px; }
  .hero { padding: 16px 0 24px; }
  .hero-mark { width: 92px; height: 92px; border-radius: 22px; margin-bottom: 22px; }
  .section-title { margin: 64px 0 28px; }
  .trust { margin-top: 64px; padding: 32px 24px; }
  .doc-header { padding-top: 16px; margin-bottom: 32px; }
  nav.top-links { gap: 18px; font-size: 14px; }
}
