/* Стиль як на nscrystal.com.ua (shared/styles/base.css), шрифт — Zakon. Mobile-first. */
@font-face { font-family: 'Zakon'; src: url('fonts/Zakon-Regular.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Zakon'; src: url('fonts/Zakon-Bold.woff2') format('woff2'); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Zakon'; src: url('fonts/Zakon-Italic.woff2') format('woff2'); font-weight: 400; font-style: italic; font-display: swap; }

:root {
  --dark: #1c1c1e;
  --dark2: #242426;
  --dark3: #2e2e30;
  --pink: #d4849c;
  --pink-light: #e8aabf;
  --pink-dark: #b86682;
  --gold: #c9a84c;
  --light: #f8f5f0;
  --light2: #ede8e0;
  --text-light: #f8f5f0;
  --muted: #a3a3a3;
  --line: rgba(255, 255, 255, 0.1);
  --ff: 'Zakon', 'Montserrat', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --radius: 2px;
  --t: 0.25s ease;
  --wrap: 640px;
  --gutter: 1rem;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--ff); font-size: 1rem; line-height: 1.6; background: var(--dark); color: var(--text-light); min-height: 100vh; overflow-x: hidden; }
[hidden] { display: none !important; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
:focus-visible { outline: 2px solid var(--pink); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- Типографіка ---------- */
.eyebrow { display: block; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--pink); margin-bottom: 0.75rem; }
.h1, .h2 { font-weight: 400; line-height: 1.15; }
.h1 { font-size: clamp(2.1rem, 8vw, 3.2rem); }
.h2 { font-size: clamp(1.5rem, 5.5vw, 2.1rem); }
.lead { font-size: 0.98rem; line-height: 1.75; opacity: 0.85; }
.line { display: block; width: 44px; height: 1px; background: var(--pink); margin: 1.1rem 0; }
.note { font-size: 0.8rem; color: var(--muted); margin-top: 1rem; line-height: 1.55; }
.note a { color: var(--pink-light); }

/* ---------- Кнопки ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 50px; padding: 0.85rem 1.6rem; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; text-decoration: none; border-radius: var(--radius); transition: background var(--t), color var(--t), border-color var(--t), opacity var(--t); width: 100%; text-align: center; }
.btn--accent { background: var(--pink); color: #fff; }
.btn--accent:hover { background: var(--pink-dark); }
.btn--accent:disabled { opacity: 0.45; cursor: default; }
.btn--ghost { border: 1px solid rgba(248, 245, 240, 0.35); color: var(--text-light); }
.btn--ghost:hover { border-color: var(--pink-light); color: var(--pink-light); }
.btn-row { display: flex; flex-direction: column; gap: 0.75rem; margin-top: 1.25rem; }
@media (min-width: 480px) { .btn-row { flex-direction: row; } .btn-row .btn { flex: 1; } }

/* ---------- Шапка ---------- */
.top { position: sticky; top: 0; z-index: 10; background: rgba(28, 28, 30, 0.96); backdrop-filter: blur(10px); border-bottom: 1px solid rgba(255, 255, 255, 0.06); }
.top__inner { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); height: 60px; display: flex; align-items: center; justify-content: space-between; }
.logo { display: inline-flex; align-items: center; text-decoration: none; flex-shrink: 0; }
.logo img { height: 30px; width: auto; }
.top__sub { margin-right: auto; margin-left: 0.8rem; padding-left: 0.8rem; border-left: 1px solid rgba(255, 255, 255, 0.2); font-size: 0.62rem; font-weight: 700; letter-spacing: 0.24em; text-transform: uppercase; color: var(--pink); line-height: 1.2; }
.top__count { font-size: 0.75rem; letter-spacing: 0.12em; color: var(--muted); font-variant-numeric: tabular-nums; }
.progress { height: 2px; background: var(--dark3); }
.progress span { display: block; height: 100%; width: 0; background: var(--pink); transition: width 0.35s ease; }

/* ---------- Екрани ---------- */
main { max-width: var(--wrap); margin: 0 auto; padding: 2rem var(--gutter) 3rem; }
.screen { animation: fade 0.35s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.intro { min-height: calc(100vh - 140px); display: flex; flex-direction: column; justify-content: center; }
.intro__gem { width: 76px; height: auto; margin-bottom: 1.5rem; }
.intro .btn { margin-top: 1.75rem; }
.intro .btn + .btn { margin-top: 0.75rem; }

/* ---------- Питання ---------- */
.q-title { outline: none; }
.q-hint { color: var(--muted); font-size: 0.9rem; margin-top: 0.6rem; }
.q-hint:empty { display: none; }
#qbody { margin-top: 1.5rem; }
.opts { display: grid; gap: 0.6rem; }
.opts--compact { grid-template-columns: repeat(2, 1fr); }
.opt { display: flex; align-items: center; gap: 0.9rem; width: 100%; min-height: 56px; padding: 0.85rem 1rem; text-align: left; background: var(--dark2); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color var(--t), background var(--t); }
.opt:hover { border-color: rgba(212, 132, 156, 0.6); }
.opt[aria-pressed='true'] { border-color: var(--pink); background: rgba(212, 132, 156, 0.14); }
.opt:disabled { opacity: 0.4; cursor: default; }
.opt__e { font-size: 1.4rem; line-height: 1; flex-shrink: 0; }
.opt__t { display: block; font-size: 1rem; line-height: 1.35; }
.opt__s { display: block; font-size: 0.8rem; color: var(--muted); margin-top: 0.15rem; }
.opt__mark { margin-left: auto; width: 20px; height: 20px; flex-shrink: 0; border: 1px solid rgba(255, 255, 255, 0.3); border-radius: 50%; display: grid; place-items: center; }
.opts--multi .opt__mark { border-radius: var(--radius); }
.opt[aria-pressed='true'] .opt__mark { background: var(--pink); border-color: var(--pink); }
.opt[aria-pressed='true'] .opt__mark::after { content: ''; width: 6px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0; transform: translateY(-1px) rotate(45deg); }

/* Плитки 2×2 з картинкою (як у макеті Люди) */
.opts--tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.opts--tiles .opt { min-width: 0; flex-direction: column; align-items: stretch; justify-content: flex-start; padding: 0.65rem; gap: 0.6rem; }
.vis { display: flex; align-items: center; justify-content: center; gap: 8px; height: 68px; border-radius: var(--radius); background: var(--dark3); font-size: 2.1rem; line-height: 1; }
.vis--nails { align-items: flex-end; gap: 5px; padding: 0 0.6rem 0.5rem; }
.vis--nails i { flex: 1; height: 82%; border-radius: 40% 40% 6px 6px; }
.vis--nails i:nth-child(1) { height: 64%; }
.vis--nails i:nth-child(2), .vis--nails i:nth-child(4) { height: 76%; }
.vis--nails i:nth-child(5) { height: 54%; }
.vis--shape { align-items: flex-end; gap: 6px; padding-bottom: 8px; }
.vis--shape i { display: block; width: 18px; background: var(--pink); opacity: 0.7; }
.opt[aria-pressed='true'] .vis { background: rgba(212, 132, 156, 0.18); }
.opts--tiles .opt__cap { padding: 0 0.15rem 0.1rem; }
.opts--tiles .opt__t { font-size: 0.95rem; }
.opts--tiles .opt__s { font-size: 0.72rem; }

/* Шкала */
.scale { display: grid; gap: 0.4rem; }
.scale--5 { grid-template-columns: repeat(5, 1fr); }
.scale--11 { grid-template-columns: repeat(6, 1fr); }
@media (min-width: 560px) { .scale--11 { grid-template-columns: repeat(11, 1fr); } }
.scale .opt { justify-content: center; min-height: 52px; padding: 0.5rem; font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.scale__labels { display: flex; justify-content: space-between; gap: 1rem; font-size: 0.78rem; color: var(--muted); margin-top: 0.6rem; }

/* Текст і контакти */
.field { display: block; margin-bottom: 0.9rem; }
.field__l { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 0.4rem; }
.input { width: 100%; min-height: 50px; padding: 0.75rem 0.9rem; background: var(--dark2); border: 1px solid var(--line); border-radius: var(--radius); font-size: 1rem; }
.input:focus { outline: none; border-color: var(--pink); }
textarea.input { min-height: 120px; resize: vertical; line-height: 1.5; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--pink) 50%), linear-gradient(135deg, var(--pink) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
.check { display: flex; gap: 0.75rem; align-items: flex-start; font-size: 0.85rem; line-height: 1.5; color: rgba(248, 245, 240, 0.85); cursor: pointer; margin-top: 0.4rem; }
.check input { width: 20px; height: 20px; flex-shrink: 0; margin-top: 2px; accent-color: var(--pink); }
.q-error { color: var(--pink-light); font-size: 0.85rem; min-height: 1.3em; margin-top: 0.9rem; }

.nav { display: flex; gap: 0.75rem; margin-top: 0.75rem; }
.nav .btn { flex: 1; }
.nav #back { flex: 0 0 auto; width: auto; padding: 0.85rem 1.2rem; }

/* ---------- Результат ---------- */
.res-head { text-align: center; padding: 1rem 0 1.75rem; }
.res-emoji { font-size: 3.2rem; line-height: 1; margin: 0.5rem 0 0.9rem; }
.res-tags { color: var(--pink-light); letter-spacing: 0.08em; margin-top: 0.6rem; font-size: 0.9rem; }
.card { background: var(--dark2); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: var(--radius); padding: 1.2rem 1.25rem; margin-bottom: 0.75rem; }
.card__k { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--pink); margin-bottom: 0.45rem; }
.card p { line-height: 1.65; }
.card .big { font-size: 1.35rem; }
.card--row { display: flex; align-items: center; gap: 1.1rem; }
.swatch { width: 54px; height: 54px; border-radius: 50%; flex-shrink: 0; box-shadow: 0 0 0 3px var(--dark2), 0 0 0 4px rgba(255, 255, 255, 0.25); }
.grid2 { display: grid; gap: 0.75rem; margin-bottom: 0.75rem; }
.grid2 .card { margin-bottom: 0; }
@media (min-width: 520px) { .grid2 { grid-template-columns: 1fr 1fr; } }

.gift { margin: 2rem 0; padding: 1.75rem 1.25rem; text-align: center; background: var(--light); color: var(--dark); border-radius: var(--radius); }
.gift .eyebrow { color: var(--pink-dark); }
.gift__text { font-size: 1.05rem; line-height: 1.6; }
.gift__code { display: inline-block; margin: 1.1rem 0 0.9rem; padding: 0.6rem 1.4rem; border: 1px dashed var(--pink-dark); font-size: 1.9rem; letter-spacing: 0.18em; font-weight: 700; color: var(--pink-dark); font-variant-numeric: tabular-nums; }
.gift__terms { font-size: 0.82rem; color: #6e6860; }

.story { text-align: center; margin: 2.5rem 0; }
.story img { width: min(100%, 300px); height: auto; margin: 0.5rem auto 0; border-radius: 10px; box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45); background: var(--dark3); aspect-ratio: 9 / 16; }
.thanks { text-align: center; padding: 2rem 0 0; border-top: 1px solid rgba(255, 255, 255, 0.06); }
.thanks .line { margin-left: auto; margin-right: auto; }
