/* ============================================================
 * smartimoti — marketing site shared CSS
 * Shared by: landing.html, how-it-works.html, pricing.html, about.html
 * Tokens kept in sync with index.html (the app)
 * ============================================================ */

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

:root {
  color-scheme: light dark;
  --indigo-50: #eef2ff; --indigo-100: #e0e7ff; --indigo-300: #a5b4fc;
  --indigo-500: #6366f1; --indigo-600: #4f46e5; --indigo-700: #4338ca;
  --slate-50: #f8fafc; --slate-100: #f1f5f9; --slate-200: #e2e8f0;
  --slate-300: #cbd5e1; --slate-400: #94a3b8; --slate-500: #64748b;
  --slate-600: #475569; --slate-700: #334155; --slate-800: #1e293b;
  --slate-900: #0f172a; --slate-950: #020617;

  --bg: #f4f6fb;
  --bg-gradient: radial-gradient(120% 60% at 50% 0%, #eef2ff 0%, #f4f6fb 60%, #f1f4f9 100%);
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --surface-3: #f1f5f9;
  --text: #0f172a;
  --text-strong: #020617;
  --text-muted: #475569;
  --text-subtle: #64748b;
  --border: rgba(15, 23, 42, 0.08);
  --border-strong: rgba(15, 23, 42, 0.14);
  --accent: #4f46e5;
  --accent-hover: #4338ca;
  --accent-soft: #eef2ff;
  --accent-on: #ffffff;
  --success: #10b981;
  --warning: #d97706;
  --danger: #ef4444;

  --radius-sm: 10px; --radius: 14px; --radius-md: 12px;
  --radius-lg: 18px; --radius-xl: 24px; --radius-2xl: 32px; --radius-pill: 9999px;

  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow: 0 4px 12px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 6px 20px rgba(15, 23, 42, 0.08), 0 2px 6px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.10), 0 4px 12px rgba(15, 23, 42, 0.05);
  --shadow-xl: 0 24px 56px rgba(15, 23, 42, 0.14), 0 8px 16px rgba(15, 23, 42, 0.06);
  --shadow-focus: 0 0 0 3px rgba(79, 70, 229, 0.35);

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-fast: 120ms; --dur-base: 180ms; --dur-slow: 260ms;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0d14;
    --bg-gradient: radial-gradient(120% 60% at 50% 0%, #1a1c2e 0%, #0b0d14 60%, #0e1119 100%);
    --surface: #14171f;
    --surface-2: #1a1d28;
    --surface-3: #21242f;
    --text: #f1f5f9;
    --text-strong: #ffffff;
    --text-muted: #cbd5e1;
    --text-subtle: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.14);
    --accent: #818cf8;
    --accent-hover: #a5b4fc;
    --accent-soft: rgba(129, 140, 248, 0.12);
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.35);
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 6px 20px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 24px 56px rgba(0, 0, 0, 0.6);
    --shadow-focus: 0 0 0 3px rgba(129, 140, 248, 0.45);
  }
}

html { scroll-behavior: smooth; }
body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  background-image: var(--bg-gradient);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
}

/* a11y */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}
a:focus-visible, button:focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
}
::selection { background: rgba(79, 70, 229, 0.18); color: var(--text-strong); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
.skip-link {
  position: fixed; top: 8px; left: 8px; z-index: 9999;
  padding: 10px 16px; background: var(--accent); color: #fff;
  font-weight: 600; border-radius: 10px; text-decoration: none;
  transform: translateY(-200%); transition: transform 150ms var(--ease-out);
}
.skip-link:focus { transform: translateY(0); }

/* Container */
.container { max-width: 1200px; margin: 0 auto; padding-inline: 24px; }
@media (max-width: 640px) { .container { padding-inline: 16px; } }
.container-narrow { max-width: 880px; margin: 0 auto; padding-inline: 24px; }
/* Full-width container — used for sections that should span the viewport
   (e.g. the floor-plan / renovation-budget showcase). Keeps gutter
   padding so content doesn't touch the screen edge. */
.container.container-wide,
.container-wide { max-width: none; }

/* ============================================================
 * NAV
 * ============================================================ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--surface) 84%, transparent);
  backdrop-filter: blur(16px) saturate(1.6);
  -webkit-backdrop-filter: blur(16px) saturate(1.6);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  display: flex; align-items: center; gap: 28px;
  padding: 14px 0;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 800; font-size: 20px; letter-spacing: -0.02em;
  color: var(--text-strong); text-decoration: none;
}
.brand-mark {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, var(--accent), #a78bfa);
  border-radius: 9px;
  display: grid; place-items: center;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.32);
  flex-shrink: 0;
}
.brand-mark svg { width: 18px; height: 18px; color: #fff; }
.brand-name span {
  background: linear-gradient(135deg, var(--accent), #a78bfa);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.nav-links { display: flex; gap: 6px; margin-inline: auto; }
.nav-links a {
  color: var(--text-muted); text-decoration: none; font-weight: 500;
  padding: 8px 14px; border-radius: 10px; font-size: 14.5px;
  transition: color var(--dur-fast) var(--ease-out),
              background-color var(--dur-fast) var(--ease-out);
}
.nav-links a:hover { color: var(--text-strong); background: var(--surface-2); }
.nav-links a.is-active { color: var(--accent); background: var(--accent-soft); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-lang {
  appearance: none; -webkit-appearance: none;
  background: transparent; border: 1px solid var(--border-strong);
  color: var(--text-muted);
  font: 600 13px/1 inherit; padding: 7px 28px 7px 12px;
  border-radius: 10px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 8px center;
}
/* Compact mobile state: options are flag-emoji-only (no language name),
   so the control only needs room for one glyph + the dropdown arrow. */
.nav-lang--compact { padding: 7px 24px 7px 8px; }
.menu-btn {
  display: none; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  background: none; border: 1px solid var(--border); border-radius: 10px;
  cursor: pointer; color: var(--text-muted); flex-shrink: 0;
}
.menu-btn:hover { background: var(--surface-2); }
.nav-mobile {
  display: none; flex-direction: column; gap: 4px;
  padding: 12px 0 16px; border-top: 1px solid var(--border);
  background: var(--surface);
}
.nav-mobile.is-open { display: flex; }
.nav-mobile a {
  color: var(--text-muted); text-decoration: none; font-weight: 500;
  font-size: 15px; padding: 10px 16px; border-radius: 10px;
  transition: color var(--dur-fast), background-color var(--dur-fast);
}
.nav-mobile a:hover, .nav-mobile a.is-active {
  color: var(--text-strong); background: var(--surface-2);
}
@media (max-width: 880px) {
  .nav-links { display: none; }
  .menu-btn { display: flex; }
  .nav-actions .btn-ghost { display: none; }
  .nav-actions .btn-primary { padding: 8px 12px; font-size: 13px; }
}

/* ============================================================
 * BUTTONS
 * ============================================================ */
.btn, .btn-primary, .btn-outline, .btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: inherit; font-weight: 600; line-height: 1;
  border: 1px solid transparent; border-radius: 12px;
  cursor: pointer; user-select: none; white-space: nowrap;
  text-decoration: none;
  transition: background-color var(--dur-fast) var(--ease-out),
              border-color var(--dur-fast) var(--ease-out),
              color var(--dur-fast) var(--ease-out),
              box-shadow var(--dur-fast) var(--ease-out),
              transform var(--dur-fast) var(--ease-out);
}
.btn, .btn-primary, .btn-outline { padding: 11px 18px; font-size: 14.5px; min-height: 44px; }
.btn-sm { padding: 8px 12px; font-size: 13px; min-height: 36px; }
.btn-lg { padding: 14px 24px; font-size: 16px; min-height: 52px; border-radius: 14px; }
.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  color: var(--accent-on); border-color: transparent;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.16) inset,
              0 6px 16px rgba(79, 70, 229, 0.32);
}
.btn-primary:hover {
  filter: brightness(1.06); transform: translateY(-1px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.18) inset,
              0 10px 24px rgba(79, 70, 229, 0.40);
}
.btn-primary:active { transform: translateY(0); filter: brightness(0.96); }
.btn {
  background: var(--surface); color: var(--text);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-xs);
}
.btn:hover { background: var(--surface-2); border-color: var(--accent); color: var(--accent); transform: translateY(-1px); }
.btn-outline { background: transparent; color: var(--accent); border-color: var(--accent); }
.btn-outline:hover { background: var(--accent-soft); }
.btn-ghost {
  background: transparent; color: var(--text-muted);
  padding: 8px 12px; min-height: 36px; font-size: 14px;
}
.btn-ghost:hover { background: var(--surface-2); color: var(--text-strong); }
@media (hover: none) {
  .btn:hover, .btn-primary:hover, .btn-outline:hover { transform: none; }
}

/* ============================================================
 * SECTIONS & TYPOGRAPHY
 * ============================================================ */
section.block { padding: 88px 0; }
@media (max-width: 720px) { section.block { padding: 64px 0; } }
/* Tighter spacing between sections on the landing page so users see more
   content per scroll without the gaps feeling cramped. */
body.landing-page section.block { padding: 56px 0; }
@media (max-width: 720px) {
  body.landing-page section.block { padding: 40px 0; }
}
.section-eyebrow {
  font-size: 13px; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 12px;
}
.section-title {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 800; letter-spacing: -0.025em; line-height: 1.15;
  color: var(--text-strong);
  max-width: 22ch; margin-bottom: 16px;
}
.section-lede {
  font-size: 17px; color: var(--text-muted); line-height: 1.65;
  max-width: 60ch; margin-bottom: 40px;
}

/* Landing page only: center each section's eyebrow, title, and lede.
   Scoped to <body class="landing-page"> so the other marketing pages
   (pricing / about / how-it-works) keep their left-aligned look.
   `!important` because data-reveal animation styles + the base rule
   above can otherwise win the cascade. */
body.landing-page .section-eyebrow,
body.landing-page .section-title,
body.landing-page .section-lede {
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
.text-muted { color: var(--text-muted); }
.text-subtle { color: var(--text-subtle); }

/* ============================================================
 * SHARED PAGE HERO (subpages)
 * ============================================================ */
.page-hero {
  padding: 80px 0 56px;
  text-align: center;
}
@media (max-width: 640px) { .page-hero { padding: 56px 0 32px; } }
.page-hero h1 {
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 800; letter-spacing: -0.03em; line-height: 1.1;
  color: var(--text-strong); margin-bottom: 16px;
}
.page-hero .lede {
  font-size: 18px; color: var(--text-muted); line-height: 1.65;
  max-width: 56ch; margin: 0 auto;
}

/* ============================================================
 * CARDS
 * ============================================================ */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--dur-base) var(--ease-out),
              box-shadow var(--dur-base) var(--ease-out),
              border-color var(--dur-base) var(--ease-out);
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--border-strong); }

/* ============================================================
 * CTA SECTION (shared)
 * ============================================================ */
.cta {
  background: linear-gradient(135deg, var(--indigo-700) 0%, var(--accent) 50%, #6d28d9 100%);
  color: #fff;
  padding: 80px 0;
  position: relative; overflow: hidden;
  border-radius: 32px;
  margin: 0 24px 64px;
}
@media (max-width: 640px) { .cta { margin-inline: 12px; border-radius: 24px; padding: 56px 0; } }
.cta::before {
  content: ""; position: absolute;
  inset: -50% -20% auto auto; width: 60%; aspect-ratio: 1;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.18), transparent 60%);
  pointer-events: none;
}
.cta-inner { position: relative; text-align: center; }
.cta h2 {
  font-size: clamp(30px, 4vw, 44px);
  font-weight: 800; letter-spacing: -0.025em; line-height: 1.15;
  margin-bottom: 16px; color: #fff;
}
.cta p { color: rgba(255, 255, 255, 0.85); font-size: 17px; max-width: 50ch; margin: 0 auto 32px; }
.cta .btn-primary {
  background: #fff; color: var(--accent);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}
.cta .btn-primary:hover { background: var(--slate-50); }
.cta .btn-outline {
  background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.5);
}
.cta .btn-outline:hover { background: rgba(255, 255, 255, 0.1); border-color: #fff; }
.cta-actions { display: inline-flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

/* ============================================================
 * FOOTER
 * ============================================================ */
footer.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 56px 0 32px;
}
.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 40px;
}
@media (max-width: 880px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .foot-grid { grid-template-columns: 1fr; gap: 28px; } }
.foot-brand p { color: var(--text-muted); font-size: 14px; margin-top: 12px; max-width: 32ch; }
.foot-col h4 {
  font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-subtle); margin-bottom: 14px;
}
.foot-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.foot-col a {
  color: var(--text-muted); text-decoration: none; font-size: 14px;
  transition: color var(--dur-fast) var(--ease-out);
}
.foot-col a:hover { color: var(--accent); }
.foot-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex; flex-wrap: wrap; gap: 16px;
  justify-content: space-between;
  color: var(--text-subtle); font-size: 13px;
}
.foot-legal { display: flex; gap: 18px; flex-wrap: wrap; }
.foot-legal a { color: var(--text-subtle); text-decoration: none; }
.foot-legal a:hover { color: var(--accent); }

/* ============================================================
 * REVEAL ON SCROLL
 * ============================================================ */
[data-reveal] {
  opacity: 0; transform: translateY(16px);
  transition: opacity 600ms var(--ease-out), transform 600ms var(--ease-out);
}
[data-reveal].visible { opacity: 1; transform: none; }
