/* Replio — refined, restrained design. Inspired by Emil Kowalski / Linear / Vercel:
   near-monochrome, typographic hierarchy, hairline surfaces, one quiet accent, subtle motion. */
:root {
  --bg: #ffffff;
  --bg-elev: #ffffff;
  --bg-soft: #f7f7f6;
  --ink: #16171a;          /* near-black text */
  --ink-2: #5b6066;        /* secondary text */
  --ink-3: #8b9097;        /* tertiary / captions */
  --line: #ececeb;         /* hairline */
  --line-2: #e2e2e0;
  --accent: #10795a;       /* deep, quiet emerald */
  --accent-weak: #ecf4f0;
  --radius: 12px;
  --radius-sm: 9px;
  --maxw: 1080px;
  --measure: 680px;
  --ease: cubic-bezier(.22,.61,.36,1);
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --shadow: 0 1px 2px rgba(16,17,20,.04), 0 8px 24px -12px rgba(16,17,20,.12);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0a0a0b; --bg-elev: #121214; --bg-soft: #101012; --ink: #ededee; --ink-2: #a2a6ad;
    --ink-3: #74787f; --line: #1e1f22; --line-2: #26272b; --accent: #3bc492; --accent-weak: #12241d;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px -14px rgba(0,0,0,.6); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0a0a0b; --bg-elev: #121214; --bg-soft: #101012; --ink: #ededee; --ink-2: #a2a6ad;
  --ink-3: #74787f; --line: #1e1f22; --line-2: #26272b; --accent: #3bc492; --accent-weak: #12241d;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px -14px rgba(0,0,0,.6); color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans);
  font-size: 16px; line-height: 1.6; letter-spacing: -0.011em; -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.1; letter-spacing: -0.025em; color: var(--ink); text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: 24px; }
.muted { color: var(--ink-2); }
.eyebrow { font-size: 13px; font-weight: 550; letter-spacing: 0.01em; color: var(--accent); }
.center { text-align: center; }

/* ---- nav ---- */
header.nav { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: color-mix(in srgb, var(--bg) 80%, transparent); backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line); }
.nav-in { display: flex; align-items: center; gap: 10px; height: 60px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 600; font-size: 17px; letter-spacing: -0.03em; color: var(--ink); }
.brand .mark { width: 26px; height: 26px; border-radius: 7px; background: var(--ink); position: relative; flex: none; }
.brand .mark::after { content: ""; position: absolute; inset: 7px 6px; border-radius: 50% 50% 50% 2px; background: var(--bg); }
.nav .links { display: flex; gap: 2px; margin-left: 20px; }
.nav .links a { color: var(--ink-2); font-weight: 500; font-size: 14.5px; padding: 7px 11px; border-radius: 8px; transition: color .15s, background .15s; }
.nav .links a:hover { color: var(--ink); }
.nav .links a.active { color: var(--ink); }
.nav .spacer { flex: 1; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid transparent;
  border-radius: 9px; padding: 9px 15px; font-family: var(--sans); font-weight: 550; font-size: 14.5px;
  letter-spacing: -0.01em; cursor: pointer; transition: transform .12s var(--ease), background .15s, border-color .15s, opacity .15s; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn.primary { background: var(--ink); color: var(--bg); }
.btn.primary:hover { opacity: .88; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn.ghost:hover { background: var(--bg-soft); }
.btn.lg { padding: 12px 20px; font-size: 15px; border-radius: 10px; }
.menu-toggle { display: none; background: none; border: 0; color: var(--ink); cursor: pointer; padding: 8px; margin-right: -8px; }
.hide-sm { display: inline-flex; }

/* ---- sections ---- */
section { padding-block: 88px; }
.sec-head { max-width: 640px; margin: 0 auto 52px; }
.sec-head.left { margin-inline: 0; }
.sec-head h2 { font-size: clamp(27px, 3.4vw, 36px); margin-top: 14px; }
.sec-head p { color: var(--ink-2); margin-top: 14px; font-size: 18px; letter-spacing: -0.014em; }
.bg-soft { background: var(--bg-soft); border-block: 1px solid var(--line); }

/* ---- hero ---- */
.hero { padding-block: 84px 56px; }
.hero-grid { display: grid; grid-template-columns: 1.02fr 0.98fr; gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(38px, 5vw, 56px); letter-spacing: -0.035em; line-height: 1.02; }
.hero .lead { font-size: 19px; color: var(--ink-2); margin-top: 22px; max-width: 42ch; letter-spacing: -0.014em; }
.hero .cta { display: flex; gap: 11px; margin-top: 30px; flex-wrap: wrap; }
.trust { display: flex; gap: 18px; margin-top: 28px; flex-wrap: wrap; color: var(--ink-3); font-size: 13.5px; font-weight: 500; }
.trust span { display: inline-flex; align-items: center; gap: 7px; }
.dot { width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }

/* ---- app mockup ---- */
.mock { background: var(--bg-elev); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow); }
.mock-bar { display: flex; align-items: center; gap: 6px; padding: 10px 13px; border-bottom: 1px solid var(--line); }
.mock-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-2); }
.mock-bar b { margin-left: 8px; font-size: 11.5px; color: var(--ink-3); font-weight: 550; }
.mock-body { display: grid; grid-template-columns: 54px 1fr 158px; height: 300px; }
.m-rail { background: var(--bg-soft); border-right: 1px solid var(--line); display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 13px 0; }
.m-acc { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; font-weight: 600; font-size: 12px; color: #fff; position: relative; letter-spacing: 0; }
.m-acc.sel { box-shadow: 0 0 0 2px var(--bg-elev), 0 0 0 3.5px var(--ink); }
.m-acc .b { position: absolute; top: -4px; right: -5px; min-width: 15px; height: 15px; padding: 0 4px; border-radius: 8px; background: #e5484d; color: #fff; font-size: 9px; font-weight: 600; display: grid; place-items: center; border: 2px solid var(--bg-soft); }
.m-acc .f { position: absolute; bottom: -4px; right: -5px; min-width: 14px; height: 14px; border-radius: 8px; background: var(--accent); color: #fff; font-size: 9px; font-weight: 600; display: grid; place-items: center; border: 2px solid var(--bg-soft); }
.m-chat { background: var(--bg-soft); display: grid; place-items: center; text-align: center; color: var(--ink-2); }
.m-chat .w { width: 46px; height: 46px; border-radius: 50%; background: var(--bg-elev); border: 1px solid var(--line); display: grid; place-items: center; margin: 0 auto 12px; color: var(--accent); }
.m-chat .t1 { font-weight: 600; font-size: 13px; color: var(--ink); }
.m-chat .t2 { font-size: 11.5px; margin-top: 4px; color: var(--ink-3); }
.m-crm { background: var(--bg-elev); border-left: 1px solid var(--line); padding: 12px; }
.m-crm .h { color: var(--ink-3); font-weight: 600; letter-spacing: 0.02em; font-size: 10px; text-transform: uppercase; margin-bottom: 10px; }
.m-lead { border: 1px solid var(--line); border-radius: 9px; padding: 8px 9px; margin-bottom: 7px; }
.m-lead b { display: block; font-size: 11.5px; color: var(--ink); }
.m-lead .s { font-size: 8.5px; font-weight: 600; padding: 1px 6px; border-radius: 5px; float: right; letter-spacing: 0.02em; }
.s.q { background: #fdf2d6; color: #8a6400; } .s.n { background: var(--accent-weak); color: var(--accent); }
.m-lead .mt { color: var(--ink-3); font-size: 9.5px; } .m-lead .od { color: #c4453f; font-size: 9.5px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .s.q { background: #2a2208; color: #e4b94e; } }
:root[data-theme="dark"] .s.q { background: #2a2208; color: #e4b94e; }

/* ---- cards / features ---- */
.grid { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
.grid > .card { background: var(--bg); border: 0; border-radius: 0; }
.card { background: var(--bg); padding: 28px 26px; transition: background .2s; }
.grid > .card:hover { background: var(--bg-soft); }
.card .ic { width: 34px; height: 34px; display: grid; place-items: center; margin-bottom: 18px; color: var(--ink); }
.card .ic svg { width: 20px; height: 20px; }
.card h3 { font-size: 16.5px; letter-spacing: -0.02em; }
.card p { color: var(--ink-2); font-size: 14.5px; margin-top: 8px; letter-spacing: -0.01em; }

/* standalone cards (not in hairline grid) */
.card.solo { border: 1px solid var(--line); border-radius: var(--radius); }

/* ---- steps ---- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.step .n { font-size: 13px; font-weight: 600; color: var(--ink-3); font-variant-numeric: tabular-nums; margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.step h3 { font-size: 15.5px; } .step p { color: var(--ink-2); font-size: 14px; margin-top: 7px; }

/* ---- pricing ---- */
.price { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: stretch; }
.plan { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; transition: border-color .2s, box-shadow .2s; }
.plan:hover { border-color: var(--line-2); }
.plan.feat { border-color: var(--ink); box-shadow: var(--shadow); }
.plan .tag { align-self: flex-start; font-size: 11.5px; font-weight: 600; color: var(--bg); background: var(--ink); padding: 3px 9px; border-radius: 999px; margin-bottom: 14px; letter-spacing: 0; }
.plan h3 { font-size: 18px; } .plan .sub { color: var(--ink-2); font-size: 14px; margin-top: 5px; }
.plan .big { font-size: 32px; font-weight: 600; margin: 20px 0 2px; letter-spacing: -0.03em; }
.plan .big span { font-size: 14px; font-weight: 500; color: var(--ink-3); letter-spacing: 0; }
.plan ul { list-style: none; padding: 0; margin: 20px 0 24px; display: grid; gap: 11px; }
.plan li { display: flex; gap: 10px; font-size: 14px; color: var(--ink-2); align-items: flex-start; }
.plan li .ck { color: var(--accent); flex: none; margin-top: 1px; }
.plan .btn { margin-top: auto; width: 100%; }

/* ---- note / split ---- */
.split { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items: center; }
.checklist { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 14px; }
.checklist li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; }
.checklist .ck { color: var(--accent); flex: none; margin-top: 2px; }
.checklist b { font-weight: 550; color: var(--ink); } .checklist span { color: var(--ink-2); }
.note { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; background: var(--bg-soft); }
.note h3 { font-size: 15px; } .note p { color: var(--ink-2); font-size: 14.5px; margin-top: 9px; }

/* ---- testimonials ---- */
.quote { border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; display: flex; flex-direction: column; gap: 18px; background: var(--bg); }
.quote p { font-size: 15.5px; color: var(--ink); line-height: 1.55; letter-spacing: -0.012em; }
.quote .who { display: flex; align-items: center; gap: 11px; margin-top: auto; }
.quote .av { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 600; font-size: 13px; flex: none; }
.quote .who b { display: block; font-size: 13.5px; font-weight: 550; } .quote .who span { color: var(--ink-3); font-size: 12.5px; }
.stars { color: var(--ink-3); letter-spacing: 1px; font-size: 13px; }
.ph-note { background: var(--accent-weak); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); color: var(--accent); border-radius: 10px; padding: 12px 16px; font-size: 13.5px; font-weight: 500; }

/* ---- contact ---- */
.field { margin-bottom: 15px; } .field label { display: block; font-size: 13px; font-weight: 500; color: var(--ink-2); margin-bottom: 6px; }
.field input, .field textarea, .field select { width: 100%; padding: 11px 13px; border: 1px solid var(--line-2); border-radius: 9px; background: var(--bg); color: var(--ink); font: inherit; font-size: 14.5px; transition: border-color .15s, box-shadow .15s; }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-weak); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact-method { display: flex; gap: 14px; align-items: flex-start; padding: 18px 0; border-bottom: 1px solid var(--line); }
.contact-method:last-child { border-bottom: 0; }
.contact-method .ic { width: 36px; height: 36px; border-radius: 9px; border: 1px solid var(--line); color: var(--ink); display: grid; place-items: center; flex: none; }
.contact-method b { font-size: 14.5px; font-weight: 550; } .contact-method p { color: var(--ink-2); font-size: 14px; margin-top: 2px; }
.copywrap { display: inline-flex; align-items: center; gap: 8px; margin-top: 4px; }
.copy-btn { border: 1px solid var(--line-2); background: var(--bg); border-radius: 7px; padding: 2px 9px; font-size: 12px; font-weight: 550; cursor: pointer; color: var(--ink-2); transition: background .15s; }
.copy-btn:hover { background: var(--bg-soft); }

/* ---- cta band ---- */
.cta-band { border: 1px solid var(--line); border-radius: 16px; padding: 56px 40px; text-align: center; background: var(--bg-soft); }
.cta-band h2 { font-size: clamp(25px, 3.2vw, 34px); }
.cta-band p { color: var(--ink-2); margin-top: 12px; font-size: 17px; }
.cta-band .cta { display: flex; justify-content: center; gap: 11px; margin-top: 28px; flex-wrap: wrap; }

/* ---- faq ---- */
.faq { max-width: var(--measure); margin: 0 auto; }
details { border-bottom: 1px solid var(--line); padding: 4px 2px; }
summary { cursor: pointer; font-weight: 550; padding: 18px 0; list-style: none; display: flex; justify-content: space-between; gap: 12px; font-size: 16px; letter-spacing: -0.015em; }
summary::-webkit-details-marker { display: none; }
summary::after { content: ""; width: 9px; height: 9px; border-right: 1.5px solid var(--ink-3); border-bottom: 1.5px solid var(--ink-3); transform: rotate(45deg); transition: transform .2s var(--ease); margin-top: 4px; flex: none; }
details[open] summary::after { transform: rotate(-135deg); margin-top: 8px; }
details > p { color: var(--ink-2); padding-bottom: 20px; font-size: 15px; max-width: 60ch; }

/* ---- footer ---- */
footer.site { border-top: 1px solid var(--line); padding-block: 56px 40px; background: var(--bg); }
footer.site .cols { display: grid; grid-template-columns: 1.8fr 1fr 1fr 1fr; gap: 32px; }
footer.site h4 { color: var(--ink); font-size: 13px; font-weight: 550; margin-bottom: 15px; }
footer.site a { color: var(--ink-2); display: block; padding: 5px 0; font-size: 14px; transition: color .15s; }
footer.site a:hover { color: var(--ink); }
footer.site .brand { color: var(--ink); margin-bottom: 14px; }
footer.site .tagline { color: var(--ink-2); font-size: 14px; max-width: 32ch; line-height: 1.55; }
footer.site .legal { border-top: 1px solid var(--line); margin-top: 40px; padding-top: 24px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--ink-3); font-size: 12.5px; }

/* ---- page header ---- */
.pagehead { padding-block: 72px 24px; }
.pagehead h1 { font-size: clamp(32px, 4.4vw, 46px); letter-spacing: -0.035em; }
.pagehead p { color: var(--ink-2); font-size: 18px; margin-top: 16px; max-width: 56ch; letter-spacing: -0.014em; }

/* ---- reveal-on-scroll (enhancement only; visible without JS) ---- */
.js .reveal { opacity: 0; transform: translateY(10px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; transition: none; } }

/* ---- responsive ---- */
@media (max-width: 900px) {
  section { padding-block: 64px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .g3, .g4, .price, .contact-grid, .steps { grid-template-columns: 1fr; }
  .g2 { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; gap: 28px; }
  .steps { gap: 0; }
  .step { padding: 20px 0; border-bottom: 1px solid var(--line); }
  .step:last-child { border-bottom: 0; }
  .step .n { border-bottom: 0; padding-bottom: 0; margin-bottom: 8px; }
  footer.site .cols { grid-template-columns: 1fr 1fr; gap: 28px 20px; }
  .nav .links { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--bg); border-bottom: 1px solid var(--line); flex-direction: column; padding: 8px 16px 14px; margin: 0; }
  .nav .links.open { display: flex; }
  .nav .links a { padding: 11px; }
  .menu-toggle { display: inline-flex; }
  header.nav { position: relative; }
}
@media (max-width: 520px) { .mock-body { height: 270px; } footer.site .cols { grid-template-columns: 1fr; } }

/* plain grid for cards that carry their own border (testimonials) */
.quotes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.stat-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.stat-card .k { font-size: 24px; font-weight: 600; letter-spacing: -0.03em; }
.stat-card p { color: var(--ink-2); font-size: 13.5px; margin-top: 4px; }
@media (max-width: 900px) { .quotes { grid-template-columns: 1fr; } }

/* language switch */
.langswitch { display: inline-flex; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; margin-right: 10px; }
.langswitch button { border: 0; background: transparent; color: var(--ink-3); font: 550 12.5px/1 var(--sans); padding: 7px 10px; cursor: pointer; transition: color .15s, background .15s; }
.langswitch button.on { color: var(--ink); background: var(--bg-soft); }
.langswitch button:hover { color: var(--ink); }
@media (max-width: 520px) { .langswitch { margin-right: 6px; } .langswitch button { padding: 6px 8px; } }
