/* ============================================================
   ClarityCraft — магазин привилегий.
   Токены те же, что на основном сайте: одна семья, одна бумага.
   Здесь только то, чего в tokens.css нет: раскладка магазина.
   ============================================================ */

:root {
  --page-pad: 24px;
  --gap: 96px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-ui, "Golos Text", system-ui, sans-serif);
  font-size: 15px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  transition: background .5s ease, color .5s ease;
}

a { color: inherit; }
img { max-width: 100%; display: block; }

.wrap {
  width: min(1120px, 100% - var(--page-pad) * 2);
  margin-inline: auto;
}

/* ---------- Шапка ---------- */
.top {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.top-in { display: flex; align-items: center; gap: 16px; height: 60px; }
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; font-weight: 600; }
.brand svg { width: 22px; height: 22px; color: var(--accent); }
.top nav { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.top nav a {
  text-decoration: none; color: var(--text-2); font-size: 14px;
  padding: 7px 11px; border-radius: 8px; transition: background .18s, color .18s;
}
.top nav a:hover { background: var(--surface-2); color: var(--text); }
.icon-btn {
  display: grid; place-items: center;
  width: 34px; height: 34px; padding: 0;
  border: 1px solid var(--border); border-radius: 9px;
  background: var(--surface); color: var(--text-2);
  cursor: pointer; transition: background .18s, color .18s, border-color .18s;
}
.icon-btn:hover { background: var(--surface-2); color: var(--text); border-color: var(--border-2); }
.icon-btn svg { width: 17px; height: 17px; }
.lang-btn { width: auto; padding: 0 10px; font: 600 12px/1 var(--font-ui, inherit); letter-spacing: .04em; }

/* ---------- Секции ---------- */
section { padding: var(--gap) 0; }
.sec-head { max-width: 640px; margin-bottom: 40px; }
.eyebrow {
  display: inline-block; font-size: 12px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--accent-text); margin-bottom: 10px; font-weight: 600;
}
h1 {
  font-family: var(--font-display, "Literata", Georgia, serif);
  font-size: clamp(30px, 4.2vw, 44px); line-height: 1.08; margin: 0 0 18px; font-weight: 500;
}
h2 {
  font-family: var(--font-display, "Literata", Georgia, serif);
  font-size: clamp(25px, 3.4vw, 36px); line-height: 1.16; margin: 0 0 12px; font-weight: 500;
}
h3 { font-size: 17px; margin: 0 0 7px; font-weight: 600; }
p { margin: 0 0 12px; color: var(--text-2); }
.lead { font-size: 17px; color: var(--text-2); }

/* ---------- Первый экран ----------
   Роли должны попадать на первый экран без прокрутки,
   поэтому отступы сверху меньше обычных. */
section.first { padding-top: 44px; }
section.first .sec-head { max-width: 660px; margin-bottom: 28px; }
section.first h1 { margin-bottom: 14px; }

/* ---------- Карточки ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--sh-1);
}
.pad { padding: 22px; }

/* ---------- Роли ---------- */
.ranks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.rank { overflow: hidden; display: flex; flex-direction: column; position: relative; }
.rank-art { aspect-ratio: 3 / 2; background: var(--surface-3); overflow: hidden; }
.rank-art img { width: 100%; height: 100%; object-fit: cover; }
.rank-b { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.rank-top { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.rank-name { font-family: var(--font-display, serif); font-size: 26px; font-weight: 500; }
.rank-price { margin-left: auto; font-weight: 600; color: var(--text-3); font-size: 15px; }
.rank-sub { color: var(--text-3); font-size: 14px; margin-bottom: 16px; }
.rank ul { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 9px; }
.rank li { display: flex; gap: 10px; font-size: 14px; color: var(--text-2); line-height: 1.45; }
.rank li svg { width: 16px; height: 16px; flex: none; margin-top: 3px; color: var(--ok); }
.rank .btn { margin-top: auto; }
.tag {
  position: absolute; top: 14px; right: 14px; z-index: 2;
  font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  padding: 5px 9px; border-radius: 7px;
  background: var(--accent); color: var(--accent-ink);
}

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 18px; border-radius: 11px; font-weight: 600; font-size: 14px;
  border: 1px solid transparent; cursor: pointer; text-decoration: none;
  transition: background .18s, border-color .18s, color .18s;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent-h); }
.btn[disabled], .btn.soon {
  background: var(--surface-3); color: var(--text-3);
  border-color: var(--border); cursor: not-allowed;
}

/* ---------- Разовые ---------- */
.extras { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; }
.extra { display: flex; gap: 13px; align-items: flex-start; }
.tile {
  width: 38px; height: 38px; flex: none; border-radius: 10px;
  display: grid; place-items: center;
}
.tile svg { width: 19px; height: 19px; }
.extra p { font-size: 13.5px; margin: 0; }
.extra .price { display: block; margin-top: 6px; font-size: 13px; color: var(--text-3); font-weight: 600; }

/* ---------- Чего не продаём ---------- */
.never { background: var(--surface-2); }
.never-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; }
.never-item {
  display: flex; gap: 11px; align-items: flex-start;
  padding: 15px 16px; border: 1px dashed var(--border-2); border-radius: 12px;
}
.never-item svg { width: 17px; height: 17px; flex: none; margin-top: 2px; color: var(--danger); }
.never-item span { font-size: 14px; color: var(--text-2); }

/* ---------- Вопросы ---------- */
.faq { display: grid; gap: 10px; max-width: 780px; }
details.q {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; padding: 15px 18px;
}
details.q summary {
  cursor: pointer; font-weight: 600; list-style: none;
  display: flex; align-items: center; gap: 10px;
}
details.q summary::-webkit-details-marker { display: none; }
details.q summary::after {
  content: ""; margin-left: auto; width: 8px; height: 8px;
  border-right: 2px solid var(--text-3); border-bottom: 2px solid var(--text-3);
  transform: rotate(45deg); transition: transform .2s ease;
}
details.q[open] summary::after { transform: rotate(-135deg); }
details.q p { margin: 10px 0 0; font-size: 14.5px; }

/* ---------- Подвал ---------- */
footer {
  border-top: 1px solid var(--border); padding: 34px 0 44px;
  color: var(--text-3); font-size: 14px;
}
.foot-in { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.foot-in a { color: var(--text-2); text-decoration: none; }
.foot-in a:hover { color: var(--accent-text); }
.foot-in .sp { margin-left: auto; }

/* ---------- Появление ---------- */
.rise { opacity: 0; transform: translateY(14px); transition: opacity .7s cubic-bezier(.22,.61,.36,1), transform .7s cubic-bezier(.22,.61,.36,1); }
.rise.in { opacity: 1; transform: none; }

/* ---------- Узкий экран ---------- */
@media (max-width: 820px) {
  :root { --gap: 64px; }
  .ranks { grid-template-columns: 1fr; }
  .top nav a.hide-sm { display: none; }
}
