/* Фокус-покус — общая система стилей для внутренних страниц (design-concept v2) */
:root {
  --lime: #B8DE21;
  --purple: #6C4CF0;
  --coral: #F5654B;
  --yellow: #F2C230;
  --pink: #F0A0C8;
  --green: #3FAF52;

  --sepia-cream: #FBDDBB;
  --sepia-pink: #F4A9A0;
  --sepia-coral: #F0784F;
  --sepia-rose: #C43B54;
  --sepia-plum: #4A1F2B;
  --terracotta: #8C4A2E;
  --teal: #2F7A6E;
  --sand: #E8C9A0;

  --cream: #FFF8EC;
  --ink: #1C1A2E;
  --muted: #6B675C;
}

* { box-sizing: border-box; }
body { margin: 0; font-family: 'Nunito', sans-serif; background: var(--cream); color: var(--ink); }
.wrap { max-width: 1000px; margin: 0 auto; padding: 0 28px; }
h1, h2, h3, .display { font-family: 'Unbounded', sans-serif; margin: 0; line-height: 1.15; }
p { line-height: 1.6; }
a { color: inherit; }

/* ===== header ===== */
header.site { padding: 20px 0; }
header.site .nav-row { max-width: 1000px; margin: 0 auto; padding: 0 28px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px; }
header.site .brand { font-family: 'Unbounded', sans-serif; font-weight: 900; font-size: 1.15rem; text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: 2px; }
header.site .brand small { font-family: 'Nunito', sans-serif; font-weight: 700; font-size: .62rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
nav.links { display: flex; gap: 20px; flex-wrap: wrap; }
nav.links a { font-family: 'Nunito', sans-serif; font-weight: 700; color: var(--ink); text-decoration: none; font-size: .92rem; transition: color .15s; }
nav.links a:hover, nav.links a.active { color: var(--purple); }
.nav-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ===== buttons ===== */
.btn { font-family: 'Unbounded', sans-serif; font-weight: 700; border: none; border-radius: 999px; padding: 16px 28px; font-size: .92rem; cursor: pointer; text-decoration: none; display: inline-block; }
.btn-primary { background: var(--ink); color: var(--cream); }
.btn-secondary { background: var(--purple); color: #fff; }
.btn-telegram { background: var(--lime); color: var(--ink); }
.btn-small { padding: 10px 18px; font-size: .8rem; }

/* ===== page hero (sepia banner, все внутренние страницы) ===== */
.page-hero {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  margin: 8px 28px 40px;
  padding: 54px 40px;
  text-align: center;
  background: radial-gradient(130% 150% at 50% 0%, var(--sepia-cream) 0%, var(--sepia-pink) 38%, var(--sepia-coral) 68%, var(--sepia-rose) 100%);
}
.page-hero .grain {
  position: absolute; inset: 0; opacity: .3; mix-blend-mode: overlay; pointer-events: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}
.page-hero .content { position: relative; z-index: 2; }
.page-hero .eyebrow { display: inline-block; background: var(--lime); color: var(--ink); font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: .78rem; padding: 8px 18px; border-radius: 999px; margin-bottom: 18px; }
.page-hero .badge-draft { background: var(--ink); color: var(--sepia-cream); font-size: .68rem; padding: 3px 10px; border-radius: 999px; margin-left: 8px; font-family: 'Nunito', sans-serif; }
.page-hero h1 { font-size: 2.4rem; font-weight: 900; color: var(--ink); }
.page-hero p.lede { max-width: 560px; margin: 14px auto 0; font-weight: 700; color: var(--sepia-plum); }

/* ===== sections ===== */
section { padding: 40px 0; }
section.alt { background: #FBF3E4; }
.section-head { max-width: 640px; margin-bottom: 26px; }
.section-head .eyebrow { font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--sepia-rose); margin-bottom: 8px; }
.section-head h2 { font-size: 1.6rem; margin-bottom: 10px; }
section > .wrap > h2 { font-size: 1.6rem; margin-bottom: 18px; }

/* ===== disclaimer ===== */
.disclaimer {
  background: var(--sepia-cream); border: 1px solid var(--sepia-pink); border-radius: 16px;
  padding: 16px 20px; font-size: .9rem; color: var(--sepia-plum); font-weight: 700;
}

/* ===== cards / grid ===== */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.card {
  background: #fff; border-radius: 20px; padding: 26px; border-top: 6px solid var(--purple);
  display: flex; flex-direction: column; gap: 10px; box-shadow: 0 8px 20px rgba(28,26,46,0.06);
}
.card:nth-child(4n+1) { border-top-color: var(--coral); }
.card:nth-child(4n+2) { border-top-color: var(--purple); }
.card:nth-child(4n+3) { border-top-color: var(--yellow); }
.card:nth-child(4n+4) { border-top-color: var(--lime); }
.card h3 { font-size: 1.05rem; }
.card p { font-size: .92rem; color: var(--muted); margin: 0; flex-grow: 1; }
.card .tag {
  display: inline-block; align-self: flex-start; font-family: 'Unbounded', sans-serif; font-weight: 700;
  font-size: .68rem; text-transform: uppercase; letter-spacing: .04em; padding: 5px 12px; border-radius: 999px;
  background: var(--sepia-cream); color: var(--sepia-plum);
}

/* ===== publications (cover + title + издание) ===== */
.pub-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.pub-card {
  display: flex; flex-direction: column; background: #fff; border-radius: 20px; overflow: hidden;
  box-shadow: 0 8px 20px rgba(28,26,46,0.06); text-decoration: none; color: inherit;
  transition: transform .15s, box-shadow .15s;
}
.pub-card:hover { transform: translateY(-4px); box-shadow: 0 14px 28px rgba(28,26,46,0.12); }
.pub-cover { width: 100%; height: 160px; object-fit: cover; display: block; background: var(--sepia-cream); }
.pub-body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex-grow: 1; }
.pub-source {
  align-self: flex-start; font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: .68rem;
  text-transform: uppercase; letter-spacing: .04em; padding: 5px 12px; border-radius: 999px;
  background: var(--sepia-cream); color: var(--sepia-plum);
}
.pub-card:nth-child(4n+1) .pub-source { background: var(--lime); color: var(--ink); }
.pub-card:nth-child(4n+2) .pub-source { background: var(--sepia-cream); color: var(--sepia-plum); }
.pub-card:nth-child(4n+3) .pub-source { background: var(--pink); color: var(--ink); }
.pub-card:nth-child(4n+4) .pub-source { background: var(--yellow); color: var(--ink); }
.pub-card h3 { font-size: 1rem; line-height: 1.35; margin: 0; }

/* ===== about-me person block ===== */
.person { display: grid; grid-template-columns: 220px 1fr; gap: 34px; align-items: start; }
@media (max-width: 640px) { .person { grid-template-columns: 1fr; } .avatar-photo { margin: 0 auto; } }
.avatar {
  width: 180px; height: 180px; border-radius: 24px; background: var(--purple); color: #fff;
  display: flex; align-items: center; justify-content: center; text-align: center;
  font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: .9rem;
}
.avatar-photo {
  display: block; width: 100%; max-width: 220px; border-radius: 20px; border: 6px solid #fff;
  box-shadow: 0 14px 28px rgba(28,26,46,0.18); transform: rotate(-2deg); object-fit: cover;
}
.person p strong { color: var(--sepia-rose); }

/* ===== book cover ===== */
.cover {
  width: 100%; height: 280px; border-radius: 16px; background: var(--yellow); color: var(--ink);
  display: flex; align-items: center; justify-content: center; text-align: center;
  font-family: 'Unbounded', sans-serif; font-weight: 700; margin-bottom: 6px; overflow: hidden;
}
.card:nth-child(2n) .cover { background: var(--coral); color: #fff; }
.cover img { width: 100%; height: 100%; object-fit: contain; border-radius: 10px; }
.card .btn { align-self: flex-start; }

/* ===== quiz ===== */
.quiz { background: #fff; border-radius: 20px; padding: 28px; box-shadow: 0 8px 20px rgba(28,26,46,0.06); }
.quiz-q { padding: 16px 0; border-top: 1px solid #EDE6D6; }
.quiz-q:first-child { border-top: none; }
.qtext { font-weight: 700; margin: 0 0 10px; }
.opts { display: flex; gap: 14px; flex-wrap: wrap; }
.opts label { display: flex; align-items: center; gap: 6px; font-size: .88rem; font-weight: 700; color: var(--muted); }
.opts input { accent-color: var(--purple); }
.quiz-result { display: none; margin-top: 16px; background: var(--sepia-cream); border-radius: 14px; padding: 16px 20px; font-weight: 700; color: var(--sepia-plum); }

/* ===== legal / privacy policy ===== */
.lang-toggle { display: flex; gap: 10px; margin-bottom: 30px; }
.lang-toggle button { font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: .82rem; padding: 10px 20px; border-radius: 999px; border: 2px solid var(--purple); background: #fff; color: var(--purple); cursor: pointer; }
.lang-toggle button.active { background: var(--purple); color: #fff; }
.legal-doc { background: #fff; border-radius: 20px; padding: 40px; box-shadow: 0 8px 20px rgba(28,26,46,0.06); max-width: 820px; }
.legal-doc h2 { font-size: 1.05rem; margin: 28px 0 10px; }
.legal-doc h2:first-child, .legal-doc h1:first-child + h2 { margin-top: 0; }
.legal-doc h1 { font-size: 1.4rem; margin-bottom: 6px; }
.legal-doc p { margin: 0 0 14px; font-size: .94rem; color: var(--ink); }
.legal-doc ul, .legal-doc ol { margin: 0 0 14px; padding-left: 22px; font-size: .94rem; }
.legal-doc li { margin-bottom: 6px; }
.legal-updated { color: var(--muted); font-size: .82rem; font-weight: 700; margin-bottom: 24px; }
.legal-lang-block { display: none; }
.legal-lang-block.active { display: block; }
.legal-lang-block[dir="rtl"] { direction: rtl; text-align: right; }
.legal-lang-block[dir="rtl"] ul, .legal-lang-block[dir="rtl"] ol { padding-left: 0; padding-right: 22px; }

/* ===== copeland checklist ===== */
.cat-heading {
  font-family: 'Unbounded', sans-serif; font-size: .95rem; font-weight: 700; color: var(--sepia-rose);
  margin: 30px 0 4px; padding-top: 18px; border-top: 2px solid #EDE6D6;
}
.copeland-cat:first-of-type .cat-heading { margin-top: 6px; padding-top: 0; border-top: none; }
.sub-heading { font-family: 'Unbounded', sans-serif; font-size: .78rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; margin: 14px 0 2px; }
.copeland-note { font-size: .82rem; color: var(--muted); margin-bottom: 18px; }
.copeland-result { display: none; margin-top: 20px; }
.copeland-table { width: 100%; border-collapse: collapse; background: var(--sepia-cream); border-radius: 14px; overflow: hidden; font-size: .86rem; }
.copeland-table th, .copeland-table td { padding: 10px 14px; text-align: left; border-bottom: 1px solid #E3D6BE; }
.copeland-table th { font-family: 'Unbounded', sans-serif; font-size: .68rem; text-transform: uppercase; letter-spacing: .03em; color: var(--sepia-plum); }
.copeland-table tr:last-child td { border-bottom: none; }
.copeland-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 18px; }

/* ===== wheel ===== */
.wheel-layout { display: grid; grid-template-columns: 340px 1fr; gap: 32px; align-items: start; }
@media (max-width: 720px) { .wheel-layout { grid-template-columns: 1fr; } }
.wheel-slider { margin-bottom: 16px; }
.wheel-slider label { display: flex; justify-content: space-between; font-weight: 700; margin-bottom: 6px; font-size: .88rem; }
.wheel-slider input[type=range] { width: 100%; accent-color: var(--purple); }
.wheel-svg-wrap { display: flex; justify-content: center; }
.wheel-summary { margin-top: 16px; }
.wheel-summary p { margin: 0 0 6px; font-size: .9rem; }

/* ===== data table (колесо + навыки/ключи) ===== */
.data-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 8px 20px rgba(28,26,46,0.06); }
.data-table th { background: var(--purple); color: #fff; font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; padding: 14px 16px; text-align: left; }
.data-table td { padding: 14px 16px; font-size: .88rem; vertical-align: top; border-top: 1px solid #F0E9D8; }
.data-table tr:nth-child(odd) td { background: #FBF6EC; }
.data-table td:first-child { font-weight: 700; }
.table-scroll { overflow-x: auto; border-radius: 16px; }
.table-scroll .data-table { min-width: 640px; }
.credit { color: var(--muted); font-size: .8rem; font-weight: 700; margin-top: 18px; }

/* ===== accordion (сферы жизни по каждому симптому) ===== */
.accordion { border-radius: 16px; overflow: hidden; box-shadow: 0 8px 20px rgba(28,26,46,0.06); margin-bottom: 10px; }
.accordion summary {
  cursor: pointer; list-style: none; background: #fff; padding: 16px 20px;
  font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: .92rem;
  display: flex; justify-content: space-between; align-items: center;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after { content: '+'; color: var(--purple); font-size: 1.3rem; font-weight: 900; }
.accordion[open] summary::after { content: '–'; }
.accordion .acc-body { background: #FBF6EC; padding: 4px 20px 18px; }
.accordion-lg { margin-bottom: 20px; }
.accordion-lg > summary { font-size: 1.2rem; padding: 24px 28px; }
.acc-body-lg { background: #fff; padding: 6px 28px 30px; }
.acc-area { margin-top: 14px; }
.acc-area h4 { font-family: 'Unbounded', sans-serif; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--sepia-rose); margin-bottom: 6px; }
.acc-area ul { margin: 0; padding: 0; list-style: none; }
.acc-area li { margin-bottom: 4px; }
.check-item { display: flex; align-items: flex-start; gap: 10px; font-size: .88rem; color: var(--ink); cursor: pointer; padding: 6px 8px; border-radius: 10px; transition: background .15s; }
.check-item:hover { background: #F0E9D8; }
.check-item input[type=checkbox] { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--purple); flex-shrink: 0; cursor: pointer; }
.check-item input[type=checkbox]:checked ~ span { font-weight: 700; color: var(--sepia-rose); }
.acc-score { margin-top: 16px; padding-top: 14px; border-top: 1px solid #E9E1CE; font-size: .85rem; font-weight: 700; }
.acc-score span.acc-score-val { color: var(--purple); }

/* ===== footer ===== */
footer.site { padding: 40px 0 50px; text-align: center; }
footer.site .foot-links { display: flex; justify-content: center; gap: 20px; flex-wrap: wrap; margin-bottom: 16px; }
footer.site .foot-links a { font-weight: 700; font-size: .88rem; text-decoration: none; color: var(--ink); }
footer.site .foot-links a:hover { color: var(--purple); }
footer.site p { color: var(--muted); font-size: .82rem; font-weight: 700; margin: 0; }
