/* Rieltly — сайт продукту. Тимчасовий простий стиль: системні шрифти, mobile-first; дизайн-система прийде пізніше. */
:root {
  --bg: #F7F7F4;
  --surface: #FFFFFF;
  --fg: #17211E;
  --muted: #5F6A66;
  --line: #E2E5E0;
  --accent: #0F6E56;
  --accent-ink: #0B5342;
  --accent-soft: #E3F1EC;
  --warn-bg: #FFF4DE;
  --warn-ink: #7A4B00;
  --radius: 14px;
  --wrap: 1040px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font: 16px/1.55 var(--font); color: var(--fg); background: var(--bg); }
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-ink); text-underline-offset: 2px; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(28px, 6vw, 44px); font-weight: 800; }
h2 { font-size: clamp(22px, 4.5vw, 30px); font-weight: 700; }
h3 { font-size: 18px; font-weight: 700; }
p { margin: 0 0 1em; }
.wrap { width: min(100% - 32px, var(--wrap)); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }

/* Шапка */
.nav { position: sticky; top: 0; background: rgba(247,247,244,.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); z-index: 5; }
.nav-in { display: flex; align-items: center; gap: 12px; min-height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 20px; text-decoration: none; color: var(--fg); margin-right: auto; }
.brand img { width: 28px; height: 28px; }
.nav-links { display: none; gap: 18px; font-size: 15px; }
.nav-links a { color: var(--muted); text-decoration: none; }
.nav-links a[aria-current="page"] { color: var(--fg); font-weight: 600; }
@media (min-width: 760px) { .nav-links { display: flex; } }

/* Кнопки */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 20px; border-radius: 10px; font-weight: 600; text-decoration: none; border: 1px solid transparent; cursor: pointer; font-size: 16px; line-height: 1.2; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-ink); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--fg); }
.btn-sm { padding: 8px 14px; font-size: 14px; }

/* Мовне меню */
.lang { position: relative; }
.lang summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 10px; font-size: 14px; background: var(--surface); }
.lang summary::-webkit-details-marker { display: none; }
.lang-pop { position: absolute; right: 0; top: calc(100% + 6px); background: var(--surface); border: 1px solid var(--line); border-radius: 10px; min-width: 170px; padding: 6px; box-shadow: 0 8px 24px rgba(0,0,0,.08); }
.lang-pop a { display: flex; justify-content: space-between; gap: 12px; padding: 8px 10px; border-radius: 8px; text-decoration: none; color: var(--fg); font-size: 15px; }
.lang-pop a:hover, .lang-pop a[aria-current="true"] { background: var(--accent-soft); }
.lang-pop a span { color: var(--muted); font-size: 13px; }
.lang-foot { display: flex; flex-wrap: wrap; gap: 14px; font-size: 14px; margin-top: 12px; }
.lang-foot a[aria-current="true"] { font-weight: 600; text-decoration: none; }
.lang-hint { position: fixed; left: 12px; right: 12px; bottom: 12px; display: flex; gap: 12px; align-items: center; background: var(--fg); color: #fff; padding: 12px 14px; border-radius: 12px; font-size: 15px; z-index: 20; }
.lang-hint a { color: #fff; font-weight: 600; }
.lang-hint button { margin-left: auto; background: none; border: 0; color: #fff; font-size: 20px; cursor: pointer; }

/* Головна */
.hero { padding: 48px 0 32px; }
.hero .kicker { color: var(--accent-ink); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: 13px; margin-bottom: 10px; }
.hero p.lead { font-size: clamp(17px, 2.4vw, 20px); color: var(--muted); max-width: 58ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 20px; }
.stores { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.store { display: inline-flex; flex-direction: column; gap: 2px; min-width: 150px; padding: 8px 14px; border-radius: 10px; background: #1B1F1E; color: #fff; text-decoration: none; line-height: 1.15; }
.store small { font-size: 11px; opacity: .8; }
.store b { font-size: 16px; }
.store.soon { background: var(--surface); color: var(--muted); border: 1px dashed var(--line); }
.section { padding: 32px 0; }
.cards { display: grid; gap: 14px; }
@media (min-width: 760px) { .cards { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.card .ic { width: 36px; height: 36px; border-radius: 10px; background: var(--accent-soft); color: var(--accent-ink); display: grid; place-items: center; margin-bottom: 12px; }
.card p { color: var(--muted); margin: 0; }
.price { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: grid; gap: 8px; }
.price .amount { font-size: clamp(32px, 7vw, 44px); font-weight: 800; letter-spacing: -.02em; }
.price .amount small { font-size: 16px; font-weight: 500; color: var(--muted); }
.price .trial { display: inline-block; background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; padding: 4px 10px; border-radius: 999px; font-size: 14px; width: max-content; }
.price p { color: var(--muted); margin: 0; }
@media (min-width: 760px) { .price { grid-template-columns: 1fr 1fr; align-items: center; } .price .trial { grid-column: 1; } }

/* Документи */
.doc-hero { padding: 36px 0 8px; }
.doc-kind { color: var(--accent-ink); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: 13px; margin-bottom: 8px; }
.doc-meta { color: var(--muted); }
.doc-grid { display: grid; gap: 24px; padding-bottom: 40px; }
@media (min-width: 900px) { .doc-grid { grid-template-columns: 1fr 240px; } .toc { position: sticky; top: 76px; align-self: start; } }
.doc { max-width: 72ch; }
.doc h2 { font-size: 20px; margin-top: 1.8em; }
.doc ul, .doc ol { padding-left: 1.3em; }
.doc li { margin-bottom: .4em; }
.toc { font-size: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.toc h2 { font-size: 14px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0 0 8px; }
.toc ol { margin: 0; padding-left: 1.2em; }
.toc li { margin: 4px 0; }
.toc a { text-decoration: none; }
.note { background: var(--accent-soft); border-radius: 10px; padding: 12px 14px; margin: 16px 0; }
.todo { background: var(--warn-bg); color: var(--warn-ink); border-radius: 10px; padding: 12px 14px; margin: 16px 0; font-size: 15px; }
.lang-note { background: var(--warn-bg); color: var(--warn-ink); border-radius: 10px; padding: 10px 14px; font-size: 14px; }

/* Сторінка відкриття / 404 */
.open-page main { padding: 48px 0; }
.open-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 22px; max-width: 560px; }
.open-more { color: var(--muted); font-size: 15px; margin-top: 18px; }

/* Підвал */
.foot { border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--muted); font-size: 14px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 8px; }
.foot-links a { color: var(--fg); text-decoration: none; }
