* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: #0d0b08;
  color: #b0a48c;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 15px;
  line-height: 1.85;
}

a {
  color: #7a5c2e;
  text-decoration: none;
}

a:hover {
  color: #b8843e;
  text-decoration: underline;
}

a:visited {
  color: #5a4420;
}

/* ─── Layout ─────────────────────────────── */

#wrapper {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 28px;
}

.layout {
  display: flex;
  gap: 40px;
  padding-top: 32px;
  padding-bottom: 60px;
}

/* ─── Header ─────────────────────────────── */

#site-header {
  border-bottom: 1px solid #1e1a12;
  padding: 42px 0 28px;
  text-align: center;
}

#site-header .site-title {
  font-size: 34px;
  letter-spacing: 14px;
  color: #7a6e54;
  font-weight: normal;
  text-transform: uppercase;
  margin-bottom: 8px;
}

#site-header .site-title a {
  color: inherit;
  text-decoration: none;
}

#site-header .site-title a:hover {
  color: #a89060;
  text-decoration: none;
}

#site-header .hebrew-title {
  font-size: 26px;
  color: #4a3e28;
  letter-spacing: 4px;
  display: block;
  margin-bottom: 12px;
  font-weight: normal;
}

#site-header .subtitle {
  font-size: 11px;
  color: #5a4c30;
  letter-spacing: 5px;
  text-transform: uppercase;
}

/* ─── Sidebar ────────────────────────────── */

#sidebar {
  width: 200px;
  flex-shrink: 0;
}

#sidebar .nav-section {
  margin-bottom: 30px;
}

#sidebar .nav-label {
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #5a4c30;
  padding-bottom: 9px;
  border-bottom: 1px solid #2a2218;
  margin-bottom: 11px;
  display: block;
}

#sidebar ul {
  list-style: none;
}

#sidebar ul li {
  border-bottom: 1px solid #151210;
}

#sidebar ul li a {
  font-size: 13px;
  color: #6a5838;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 6px 0;
  line-height: 1.4;
}

#sidebar ul li a:hover {
  color: #a8803a;
  text-decoration: none;
}

#sidebar ul li a.active {
  color: #9a7432;
}

#sidebar ul li .seph-name {
  font-size: 10px;
  color: #4e4028;
  letter-spacing: 1px;
  text-align: right;
}

/* ─── Content ────────────────────────────── */

#content {
  flex: 1;
  min-width: 0;
}

#content h2 {
  font-size: 12px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #6a5c3e;
  font-weight: normal;
  border-bottom: 1px solid #1a1610;
  padding-bottom: 11px;
  margin-bottom: 26px;
}

#content h3 {
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #5a4e34;
  font-weight: normal;
  margin: 32px 0 14px;
}

#content p {
  font-size: 15px;
  margin-bottom: 18px;
  color: #a89c82;
}

.blockquote {
  border-left: 2px solid #201c12;
  padding: 6px 0 6px 20px;
  margin: 26px 0;
  color: #7a6e52;
  font-style: italic;
  font-size: 15px;
}

.blockquote cite {
  display: block;
  margin-top: 10px;
  font-size: 11px;
  letter-spacing: 2px;
  font-style: normal;
  color: #5a4c30;
}

/* ─── Qliphah entry page header ─────────── */

.qliphah-header {
  text-align: center;
  padding-bottom: 28px;
  border-bottom: 1px solid #1a1610;
  margin-bottom: 32px;
}

.qliphah-header .hebrew-name {
  font-size: 46px;
  color: #5a4e34;
  display: block;
  margin-bottom: 6px;
  font-weight: normal;
  letter-spacing: 4px;
}

.qliphah-header .latin-name {
  font-size: 22px;
  letter-spacing: 9px;
  color: #7a6c4e;
  text-transform: uppercase;
  font-weight: normal;
  margin-bottom: 8px;
}

.qliphah-header .meaning {
  font-size: 13px;
  color: #4a4030;
  font-style: italic;
  margin-bottom: 16px;
}

.qliphah-header .rule-line {
  color: #4a3e28;
  font-size: 12px;
  letter-spacing: 2px;
}

/* ─── Tunnel header ──────────────────────── */

.tunnel-header {
  text-align: center;
  padding-bottom: 24px;
  border-bottom: 1px solid #1a1610;
  margin-bottom: 32px;
}

.tunnel-header .tunnel-letter {
  font-size: 52px;
  color: #3a3020;
  display: block;
  font-weight: normal;
  margin-bottom: 4px;
  line-height: 1;
}

.tunnel-header .tunnel-name {
  font-size: 20px;
  letter-spacing: 8px;
  color: #7a6c4e;
  text-transform: uppercase;
  font-weight: normal;
  margin-bottom: 6px;
}

.tunnel-header .tunnel-entity {
  font-size: 13px;
  color: #5a4e34;
  font-style: italic;
  margin-bottom: 14px;
}

.tunnel-header .tunnel-path {
  font-size: 11px;
  color: #2a2418;
  letter-spacing: 2px;
}

/* ─── Correspondences table ──────────────── */

.corr-table {
  width: 100%;
  border-collapse: collapse;
  margin: 22px 0;
  font-size: 13px;
}

.corr-table td {
  padding: 9px 12px;
  border-bottom: 1px solid #181410;
}

.corr-table td:first-child {
  color: #4a4030;
  letter-spacing: 2px;
  font-size: 11px;
  text-transform: uppercase;
  width: 36%;
}

.corr-table td:last-child {
  color: #9a8e72;
}

/* ─── Tunnels overview table ─────────────── */

.tunnels-table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 12px;
}

.tunnels-table th {
  text-align: left;
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #3c3020;
  padding: 8px 10px;
  border-bottom: 1px solid #201c12;
  font-weight: normal;
}

.tunnels-table td {
  padding: 7px 10px;
  border-bottom: 1px solid #161210;
  color: #8a7e64;
  vertical-align: top;
}

.tunnels-table td:first-child {
  color: #4a3e28;
  font-size: 16px;
  width: 42px;
  text-align: center;
}

.tunnels-table td .t-entity {
  color: #6a5a3a;
  display: block;
}

.tunnels-table td .t-path {
  color: #3a3020;
  font-size: 11px;
  display: block;
  margin-top: 2px;
}

.tunnels-table tr:hover td {
  background: #100e0a;
}

/* ─── SVG Tree ───────────────────────────── */

.tree-container {
  margin: 28px 0;
  text-align: center;
}

.tree-container svg {
  max-width: 100%;
  height: auto;
}

/* ─── Tunnel sections ────────────────────── */

.tunnel-entry {
  padding: 18px 0;
  border-bottom: 1px solid #141210;
}

.tunnel-entry:last-child {
  border-bottom: none;
}

.tunnel-entry h3 {
  margin: 0 0 10px;
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #5a4e34;
}

.tunnel-entry .te-meta {
  font-size: 11px;
  color: #3a3020;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.tunnel-entry p {
  font-size: 14px;
  margin: 0;
}

/* ─── Sigil ──────────────────────────────── */

.sigil {
  text-align: center;
  margin: 24px 0 32px;
  opacity: 0.55;
  transition: opacity 0.55s;
}

.sigil:hover {
  opacity: 0.92;
}

.sigil svg {
  max-width: 108px;
  height: auto;
  filter: brightness(2.8);
}

/* ─── Navigation arrows ──────────────────── */

.page-nav {
  display: flex;
  justify-content: space-between;
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid #1a1610;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* ─── Kliphah illustrations ─────────────── */

.klip-art {
  margin: 4px 0 34px;
  opacity: 0.62;
  transition: opacity 0.6s;
  text-align: center;
}
.klip-art:hover { opacity: 1; }
.klip-art svg {
  width: 100%;
  max-width: 480px;
  height: auto;
  display: inline-block;
  filter: brightness(3);
}

/* ─── Shevirat animation ─────────────────── */

#shevirat { display: block; margin: 28px auto; }

/* ─── Tunnel visual map ──────────────────── */

.tunnel-map-wrap { margin: 28px 0 8px; }
.tunnel-map-wrap svg {
  width: 100%;
  height: auto;
  display: block;
  filter: brightness(2.5);
}
#tmap-info {
  border: 1px solid #1a1610;
  background: #0f0d09;
  padding: 14px 18px;
  min-height: 56px;
  margin-bottom: 32px;
  font-size: 13px;
}
.tmi-name { color: #8a7248; letter-spacing: 2px; text-transform: uppercase; font-size: 12px; margin-bottom: 4px; }
.tmi-path { color: #3a2e18; font-size: 10px; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 10px; }
.tmi-desc { color: #7a6a4a; line-height: 1.65; }
.tmi-prompt { color: #2a2018; font-style: italic; font-size: 12px; letter-spacing: 1px; }

/* ─── Dark Seal (Zeigarnik hook) ────────── */

.dark-seal {
  color: #3a2a14;
  font-style: italic;
  font-size: 13px;
  letter-spacing: 0.8px;
  line-height: 1.7;
  text-align: center;
  margin: 36px 0 28px;
  padding: 16px 24px;
  border-top: 1px solid #1a1408;
  border-bottom: 1px solid #1a1408;
}

/* ─── Footer ─────────────────────────────── */

#site-footer {
  border-top: 1px solid #1e1a14;
  padding: 22px 0 32px;
  text-align: center;
  font-size: 11px;
  color: #4a4028;
  letter-spacing: 3px;
}

#site-footer a {
  color: #5a4828;
}

/* ─── Active nav ─────────────────────────── */

#sidebar a.nav-current {
  color: #b8843e;
  pointer-events: none;
  background: linear-gradient(to right, rgba(140,90,30,0.10) 0%, transparent 85%);
}
#sidebar a.nav-current .seph-name {
  color: #9a7836;
}

/* Topnav: подсвечиваем активный пункт внутри dropdown */
#topnav .tn-drop a.nav-current {
  color: #b8843e;
  pointer-events: none;
  background: rgba(140,90,30,0.08);
}

/* Активный «архив»/«инструменты» в верхней панели — мягкая подсветка */
#topnav .tn-item.tn-active > .tn-link {
  color: #a07832;
}

/* Активная топ-кнопка «услуги» */
#topnav .tn-services.nav-current {
  color: #c89244;
  pointer-events: none;
}

/* ─── Search ─────────────────────────────── */

.search-wrap {
  margin: 32px 0 48px;
}

.search-input-wrap {
  position: relative;
  margin-bottom: 36px;
}

#search-input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid #2a1e0c;
  color: #a89c82;
  font-family: Georgia, serif;
  font-size: 18px;
  padding: 10px 0;
  outline: none;
  letter-spacing: 0.5px;
  transition: border-color 0.3s;
}

#search-input:focus {
  border-bottom-color: #5a3a18;
}

#search-input::placeholder {
  color: #2a2010;
  letter-spacing: 2px;
  font-size: 12px;
}

.search-count {
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #2a2010;
  margin-bottom: 24px;
}

.search-result {
  padding: 22px 0;
  border-bottom: 1px solid #141010;
  transition: border-color 0.2s;
}

.search-result:hover {
  border-bottom-color: #2a1e0c;
}

.sr-title {
  display: block;
  font-size: 16px;
  color: #7a6a4a;
  font-family: Georgia, serif;
  font-style: italic;
  margin-bottom: 4px;
  text-decoration: none;
}

.sr-title:hover {
  color: #a08848;
  text-decoration: none;
}

.sr-sub {
  display: block;
  font-size: 9px;
  color: #2a2010;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.sr-excerpt {
  font-size: 13px;
  color: #7a7060;
  line-height: 1.8;
}

.sr-excerpt mark {
  background: transparent;
  color: #9a8050;
  font-style: italic;
}

.search-empty {
  font-size: 12px;
  color: #2a2010;
  letter-spacing: 2px;
  font-style: italic;
  margin-top: 40px;
}

/* ─── Tarot cards ────────────────────────── */

.tcard-frame svg {
  filter: brightness(2.2);
}

/* ─── Donate block ───────────────────────── */

.donate-block {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid #161210;
}

.donate-text {
  font-size: 10px;
  color: #5a4e30;
  letter-spacing: 3.5px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.donate-addr {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.donate-label {
  font-size: 9px;
  color: #5a4828;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.donate-wallet {
  font-family: 'Courier New', monospace;
  font-size: 11px;
  color: #4a3c22;
  letter-spacing: 1.5px;
}

.donate-note {
  font-size: 9px;
  color: #3a3018;
  letter-spacing: 2px;
  font-style: italic;
  margin-top: 8px;
}

/* ─── Tree tooltip ───────────────────────── */

#tree-tip {
  display: none;
  position: fixed;
  z-index: 200;
  pointer-events: none;
  background: #0f0d0a;
  border: 1px solid #241a0c;
  padding: 14px 18px 16px;
  min-width: 190px;
  max-width: 240px;
}

.tt-heb {
  display: block;
  font-size: 21px;
  color: #40300e;
  letter-spacing: 4px;
  text-align: right;
  margin-bottom: 10px;
  direction: rtl;
}

.tt-name {
  display: block;
  font-size: 13px;
  color: #9a8060;
  font-family: Georgia, serif;
  font-style: italic;
  letter-spacing: 0.5px;
  margin-bottom: 2px;
}

.tt-seph {
  display: block;
  font-size: 9px;
  color: #3a2e18;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.tt-demon {
  display: block;
  font-size: 11px;
  color: #5a4828;
  margin-bottom: 4px;
}

.tt-quality {
  display: block;
  font-size: 10px;
  color: #2a2010;
  font-style: italic;
  letter-spacing: 0.3px;
  line-height: 1.5;
}

/* ─── Progress bar ───────────────────────── */

#progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  background: #8a5c28;
  z-index: 9999;
  transition: width 0.08s linear;
  pointer-events: none;
}

/* ─── Reading time ───────────────────────── */

.reading-time {
  font-size: 8px;
  color: #2a2010;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  margin: -8px 0 24px;
  text-align: right;
}

/* ─── Last read (search page) ────────────── */

#last-read {
  margin-bottom: 18px;
  font-size: 10px;
  color: #2a2010;
  letter-spacing: 2px;
  text-transform: uppercase;
}

#last-read a {
  color: #3a2e18;
  border-bottom: 1px solid #221808;
  text-transform: none;
  letter-spacing: 0.5px;
  font-size: 12px;
  font-style: italic;
}

#last-read a:hover {
  color: #7a5c2e;
  text-decoration: none;
  border-color: #5a3a18;
}

/* ─── Контекстный глоссарий ─────────────── */

.gl-term {
  position: relative;
  display: inline;
  border-bottom: 1px dotted #2a2010;
  cursor: help;
  transition: border-color 0.15s;
}
.gl-term:hover { border-bottom-color: #7a5c2e; }
.gl-tip {
  visibility: hidden;
  opacity: 0;
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: #070503;
  border: 1px solid #1e1609;
  padding: 10px 15px;
  font-size: 11px;
  font-family: Georgia, serif;
  font-style: italic;
  color: #5a4a28;
  max-width: 260px;
  width: max-content;
  white-space: normal;
  line-height: 1.65;
  letter-spacing: 0.3px;
  z-index: 400;
  pointer-events: none;
  transition: opacity 0.15s;
  text-align: left;
}
.gl-term:hover .gl-tip { visibility: visible; opacity: 1; }

/* ─── Гематрия ───────────────────────────── */

.gm-wrap {
  position: relative;
  display: inline;
}
.gm-num {
  font-family: 'Courier New', monospace;
  font-size: 8px;
  color: #252010;
  vertical-align: super;
  margin-left: 1px;
  cursor: default;
  user-select: none;
  transition: color 0.15s;
}
.gm-wrap:hover .gm-num { color: #7a5830; }
.gm-tip {
  visibility: hidden;
  opacity: 0;
  position: absolute;
  bottom: calc(100% + 7px);
  left: 50%;
  transform: translateX(-50%);
  background: #060402;
  border: 1px solid #1c1408;
  padding: 7px 13px;
  font-size: 9px;
  font-family: 'Courier New', monospace;
  color: #4a3a1e;
  white-space: nowrap;
  z-index: 500;
  pointer-events: none;
  letter-spacing: 0.5px;
  transition: opacity 0.12s;
}
.gm-wrap:hover .gm-tip { visibility: visible; opacity: 1; }

/* ─── Инициационный прогресс ────────────── */

.init-track {
  margin-bottom: 12px;
  line-height: 1;
}
.init-label {
  display: block;
  font-size: 7px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #141008;
  margin-bottom: 6px;
}
.init-dot {
  font-size: 11px;
  color: #181208;
  letter-spacing: 5px;
  font-family: Georgia, serif;
  transition: color 0.4s;
}
.init-dot.seen    { color: #2e2010; }
.init-dot.current { color: #7a5c2e; }

/* ─── Чернение от неподвижности ──────────── */

#still-veil {
  position: fixed;
  inset: 0;
  background: #020100;
  pointer-events: none;
  opacity: 0;
  z-index: 9990;
  transition: opacity 14s ease;
}
#still-veil.dark { opacity: 0.94; }

/* ─── Лунный отсчёт ──────────────────────── */

.lunar-cd {
  font-size: 9px;
  letter-spacing: 2px;
  color: #1c1408;
  margin-bottom: 10px;
}
.lunar-event {
  color: #3a2c14;
  font-style: normal;
}

/* ─── Дата-атмосфера ─────────────────────── */

.atm-line {
  font-size: 9px;
  color: #2e2410;
  letter-spacing: 2px;
  margin-bottom: 10px;
  font-style: italic;
}

/* ─── Куда войти (entry block) ─────────── */

.entry-block {
  margin: 0 0 50px;
  padding: 28px 0 26px;
  border-top: 1px solid #1a1408;
  border-bottom: 1px solid #1a1408;
  text-align: center;
}

.eb-label {
  font-size: 9px;
  color: #5a4020;
  letter-spacing: 5px;
  text-transform: uppercase;
  margin-bottom: 22px;
  display: block;
}

.eb-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 18px;
}

.eb-card {
  display: block;
  text-decoration: none;
  background: #040201;
  border: 1px solid #1c1208;
  padding: 18px 16px 16px;
  transition: border-color 0.25s, background 0.2s, transform 0.2s;
  text-align: left;
  position: relative;
  overflow: hidden;
}

.eb-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 10% 0%, rgba(80,40,8,0.10) 0%, transparent 60%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}

.eb-card:hover {
  border-color: #3a2010;
  background: #060403;
  transform: translateY(-2px);
  text-decoration: none;
}
.eb-card:hover::before { opacity: 1; }

.eb-card-heb {
  display: block;
  font-size: 16px;
  color: #4a3818;
  direction: rtl;
  letter-spacing: 3px;
  margin-bottom: 8px;
  transition: color 0.25s;
}
.eb-card:hover .eb-card-heb { color: #6a5028; }

.eb-card-name {
  display: block;
  font-size: 12px;
  color: #7a5828;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 7px;
  transition: color 0.25s;
}
.eb-card:hover .eb-card-name { color: #a07038; }

.eb-card-desc {
  display: block;
  font-size: 11px;
  color: #3a2c14;
  line-height: 1.65;
  font-style: italic;
}

/* Второй ряд — странные двери, компактнее */
.eb-row {
  margin: 22px 0 4px;
  padding-top: 20px;
  border-top: 1px dashed #1a1408;
}
.eb-row-label {
  display: block;
  font-size: 9px;
  color: #4a3818;
  letter-spacing: 4px;
  text-transform: uppercase;
  font-style: italic;
  margin-bottom: 14px;
  text-align: center;
}
.eb-row-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.eb-row-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 8px;
  text-decoration: none;
  border: 1px solid #150f08;
  background: #030201;
  transition: border-color .25s, background .2s, transform .2s;
  text-align: center;
}
.eb-row-link:hover {
  border-color: #2a1808;
  background: #060403;
  transform: translateY(-1px);
  text-decoration: none;
}
.erl-heb {
  font-size: 14px;
  color: #4a3618;
  direction: rtl;
  letter-spacing: 2px;
  transition: color .25s;
}
.eb-row-link:hover .erl-heb { color: #7a5828; }
.erl-name {
  font-size: 10px;
  color: #6a4818;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  line-height: 1.4;
  transition: color .25s;
}
.eb-row-link:hover .erl-name { color: #a07832; }

@media (max-width: 680px) {
  .eb-row-grid { grid-template-columns: repeat(2, 1fr); }
}

.eb-skip {
  font-size: 9px;
  color: #2a1e08;
  letter-spacing: 3px;
  font-style: italic;
  margin: 6px 0 0;
}

@media (max-width: 540px) {
  .eb-grid { grid-template-columns: 1fr; }
}

/* ─── Scroll-reveal ─────────────────────── */

.sr {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}
.sr-l {
  opacity: 0;
  transform: translateX(-28px);
  transition: opacity 0.75s ease, transform 0.75s ease;
}
.sr-scale {
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 1s ease, transform 1s ease;
}
.sr.in, .sr-l.in, .sr-scale.in {
  opacity: 1;
  transform: none;
}

/* ─── Natal section separators ──────────── */

.natal-sep {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 44px 0 36px;
}
.natal-sep::before,
.natal-sep::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #1e1408;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 1.1s cubic-bezier(0.4,0,0.2,1);
}
.natal-sep::after { transform-origin: right center; }
.natal-sep.in::before,
.natal-sep.in::after { transform: scaleX(1); }
.natal-sep-sym {
  font-size: 13px;
  color: #2e2010;
  flex-shrink: 0;
  font-family: Georgia, serif;
}

/* ─── Wheel outer ring rotation ─────────── */

@keyframes slowRotate {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.wheel-ring-rot {
  transform-box: fill-box;
  transform-origin: center;
  animation: slowRotate 120s linear infinite;
}

/* ─── Outer circle draw-in ───────────────── */

@keyframes circReveal {
  from { stroke-dashoffset: 1400; }
  to   { stroke-dashoffset: 0; }
}
.circ-anim {
  stroke-dasharray: 1400;
  stroke-dashoffset: 1400;
  animation: circReveal 2.6s cubic-bezier(0.4,0,0.15,1) both 0.4s;
}

/* ─── Hebrew materialise ─────────────────── */

@keyframes hebrewMat {
  from { opacity: 0; filter: blur(14px); letter-spacing: 20px; }
  to   { opacity: 1; filter: blur(0);   letter-spacing: 3px;  }
}
.heb-mat { animation: hebrewMat 1.8s cubic-bezier(0.4,0,0.2,1) both; }

/* ─── Connector line draw ────────────────── */

@keyframes lineGrow {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}
.planet-strip.in .ps-line {
  animation: lineGrow 0.7s cubic-bezier(0.4,0,0.2,1) both 0.2s;
}
.planet-strip.in .ps-line::after {
  animation: lineGrow 0.7s cubic-bezier(0.4,0,0.2,1) both 0.85s;
}

/* ─── Активная Клипа ─────────────────────── */

.atm-active {
  font-size: 10px;
  color: #4a3818;
  letter-spacing: 2px;
  margin-bottom: 12px;
  font-style: italic;
}

.atm-kname {
  color: #7a5c28;
  font-style: normal;
}

/* ─── Топнав ─────────────────────────────── */

#topnav {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid #131008;
  position: relative;
  z-index: 100;
}

.tn-item {
  position: relative;
}

.tn-link {
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #7a6848;
  padding: 10px 15px;
  display: block;
  text-decoration: none;
  cursor: pointer;
  border-right: 1px solid #111008;
  transition: color 0.2s;
  white-space: nowrap;
  user-select: none;
  line-height: 1;
}

.tn-link:hover,
.tn-item:hover > .tn-link {
  color: #7a5c2e;
  text-decoration: none;
}

.tn-item-services {
  margin-left: auto;
  border-left: 1px solid #111008;
}

.tn-services {
  color: #9a6030;
  border-right: none;
  letter-spacing: 4px;
}

.tn-services:hover,
.tn-item-services:hover > .tn-services { color: #c07838; text-decoration: none; }

.tn-drop-r { left: auto; right: 0; }

.tn-drop {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #060402;
  border: 1px solid #181408;
  border-top: none;
  min-width: 210px;
  z-index: 300;
  padding: 4px 0;
}

.tn-item:hover .tn-drop { display: block; }

.tn-drop a {
  display: block;
  padding: 8px 18px;
  font-size: 11px;
  color: #3a2e18;
  letter-spacing: 1px;
  text-decoration: none;
  transition: color 0.15s, background 0.1s;
}

.tn-drop a:hover {
  color: #7a5c2e;
  background: #0b0806;
  text-decoration: none;
}

.tn-drop-divider {
  font-size: 8px;
  color: #3a2c14;
  letter-spacing: 3px;
  text-transform: uppercase;
  padding: 14px 18px 6px;
  margin-top: 6px;
  border-top: 1px solid #141008;
  font-style: italic;
  pointer-events: none;
  user-select: none;
}

/* ─── "А теперь" — связь между страницами ─── */

.next-step {
  margin: 50px 0 30px;
  padding: 24px 22px;
  border: 1px solid #1a1408;
  background: #040201;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.next-step::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 0%, rgba(80,40,8,0.08) 0%, transparent 60%);
  pointer-events: none;
}
.ns-label {
  position: relative;
  font-size: 9px;
  color: #3a2c14;
  letter-spacing: 4px;
  text-transform: uppercase;
  margin-bottom: 14px;
  display: block;
  font-style: italic;
}
.ns-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  max-width: 540px;
  margin: 0 auto;
}
.ns-card {
  display: block;
  text-decoration: none;
  background: #060403;
  border: 1px solid #1c1208;
  padding: 14px 16px;
  text-align: left;
  transition: border-color .25s, background .2s, transform .2s;
}
.ns-card:hover {
  border-color: #3a2010;
  background: #0a0604;
  transform: translateY(-2px);
  text-decoration: none;
}
.ns-card-heb {
  display: block;
  font-size: 12px;
  color: #4a3818;
  direction: rtl;
  letter-spacing: 2px;
  margin-bottom: 6px;
  transition: color .25s;
}
.ns-card:hover .ns-card-heb { color: #6a5028; }
.ns-card-name {
  display: block;
  font-size: 10px;
  color: #7a5828;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 4px;
  transition: color .25s;
}
.ns-card:hover .ns-card-name { color: #a07038; }
.ns-card-hint {
  display: block;
  font-size: 10px;
  color: #3a2c14;
  font-style: italic;
  line-height: 1.5;
}

@media (max-width: 540px) {
  .ns-grid { grid-template-columns: 1fr; }
}

/* ─── Мобильная навигация ────────────────── */

/* Hamburger button — only on mobile */
#mobile-nav-btn {
  display: none;
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9991;
  width: 42px;
  height: 42px;
  background: #0d0b08;
  border: 1px solid #2a1808;
  color: #7a5c2e;
  font-family: Georgia, serif;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  letter-spacing: 0;
  transition: color 0.25s, border-color 0.25s, background 0.25s;
}
#mobile-nav-btn:hover {
  color: #b8843e;
  border-color: #5a3818;
}
#mobile-nav-btn .bar {
  display: block;
  width: 18px;
  height: 1.5px;
  background: currentColor;
  margin: 4px auto;
  transition: transform 0.3s, opacity 0.3s;
}
body.mn-open #mobile-nav-btn .bar:nth-child(1) {
  transform: translateY(5.5px) rotate(45deg);
}
body.mn-open #mobile-nav-btn .bar:nth-child(2) {
  opacity: 0;
}
body.mn-open #mobile-nav-btn .bar:nth-child(3) {
  transform: translateY(-5.5px) rotate(-45deg);
}

/* Mobile overlay panel */
#mobile-nav-panel {
  position: fixed;
  inset: 0;
  background: #050402;
  z-index: 9990;
  display: none;
  flex-direction: column;
  overflow-y: auto;
  padding: 78px 28px 60px;
}
body.mn-open #mobile-nav-panel { display: flex; }

.mn-section {
  margin-bottom: 28px;
}
.mn-section-title {
  font-size: 9px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #4a3818;
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid #1a1408;
  display: block;
}
.mn-section a {
  display: block;
  font-size: 14px;
  color: #7a5c2e;
  padding: 9px 0;
  border-bottom: 1px solid #131008;
  text-decoration: none;
  letter-spacing: 0.5px;
}
.mn-section a:hover { color: #b8843e; }
.mn-section a.featured {
  color: #9a6030;
  letter-spacing: 4px;
  text-transform: uppercase;
  font-size: 11px;
}
.mn-section a:last-child { border-bottom: none; }
.mn-divider {
  font-size: 8px;
  color: #2a1e08;
  letter-spacing: 3px;
  text-transform: uppercase;
  padding: 14px 0 4px;
  font-style: italic;
}
.mn-klipa-sub {
  font-size: 10px;
  color: #2a2018;
  letter-spacing: 1px;
  float: right;
}

/* Layout on mobile */
@media (max-width: 760px) {
  #mobile-nav-btn { display: block; }
  #topnav { display: none; }
  #sidebar { display: none; }
  .layout {
    display: block;
    padding-top: 20px;
    padding-bottom: 30px;
  }
  #wrapper {
    padding: 0 20px;
  }
  #site-header {
    padding: 36px 0 22px;
  }
  #site-header .site-title {
    font-size: 26px;
    letter-spacing: 8px;
  }
  #site-header .hebrew-title {
    font-size: 22px;
    letter-spacing: 3px;
  }
  #site-header .subtitle {
    font-size: 9px;
    letter-spacing: 3px;
  }
  #content {
    width: 100%;
  }
  #content h2 {
    font-size: 11px;
    margin-bottom: 20px;
  }
  #content p {
    font-size: 14.5px;
  }
}

/* Prevent body scroll when menu open */
body.mn-open { overflow: hidden; }

/* ─── Натальная карта ────────────────────── */

.natal-intro {
  color: #6a5c3c;
  font-style: italic;
  font-size: 14px;
  margin-bottom: 8px;
}

.natal-note {
  font-size: 10px;
  color: #2e2410;
  letter-spacing: 1px;
  font-style: italic;
  margin-bottom: 28px;
}

.natal-form {
  margin: 28px 0 36px;
}

.natal-field {
  margin-bottom: 20px;
}

.natal-field label {
  display: block;
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #4a3c20;
  margin-bottom: 7px;
}

.natal-field input {
  background: transparent;
  border: none;
  border-bottom: 1px solid #201a0e;
  color: #9a8c70;
  font-family: Georgia, serif;
  font-size: 15px;
  padding: 7px 0;
  width: 100%;
  max-width: 340px;
  outline: none;
  letter-spacing: 0.5px;
  transition: border-color 0.2s;
  color-scheme: dark;
}

.natal-field input:focus { border-bottom-color: #5a3a18; }

.natal-field input::placeholder {
  color: #2a2010;
  font-size: 12px;
  letter-spacing: 2px;
}

.natal-btn {
  background: transparent;
  border: 1px solid #2e2010;
  color: #7a5828;
  font-family: Georgia, serif;
  font-size: 10px;
  letter-spacing: 4px;
  text-transform: uppercase;
  padding: 13px 32px;
  cursor: pointer;
  transition: border-color 0.3s, color 0.3s;
  margin-top: 8px;
}

.natal-btn:hover {
  border-color: #7a4820;
  color: #a87038;
}

#natal-result {
  opacity: 0;
  transition: opacity 1.4s ease;
  pointer-events: none;
}

#natal-result.visible {
  opacity: 1;
  pointer-events: auto;
}

/* ── Героическая зона колеса ── */

.natal-hero {
  background: #030201;
  border: 1px solid #161008;
  margin: 36px 0 44px;
  padding: 36px 20px 28px;
  text-align: center;
}

.natal-who {
  font-size: 10px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #5a4a28;
  margin-bottom: 28px;
}

@keyframes wheelReveal {
  from { opacity: 0; transform: scale(0.92) rotate(-6deg); }
  to   { opacity: 1; transform: scale(1) rotate(0deg); }
}

.natal-hero svg {
  animation: wheelReveal 2.2s cubic-bezier(0.4, 0, 0.2, 1) both;
}

@keyframes pmarkIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.pmark { animation: pmarkIn 0.5s ease both; }

.natal-approx {
  font-size: 8px;
  color: #2a1e0a;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 20px;
}

/* ── Планетарные коннекторы ── */

.natal-connections {
  margin: 0 0 44px;
}

.planet-strip {
  display: flex;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #111008;
  transition: background 0.2s;
  gap: 0;
}

.planet-strip:hover { background: #060403; }

.ps-sym {
  font-size: 20px;
  width: 36px;
  text-align: center;
  color: #5a4820;
  flex-shrink: 0;
  font-family: 'Segoe UI Symbol', 'Apple Symbols', 'DejaVu Sans', Georgia, serif;
  font-style: normal;
}

.ps-name {
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #6a5430;
  width: 96px;
  flex-shrink: 0;
}

.ps-sign {
  font-size: 11px;
  color: #3a2e18;
  width: 88px;
  flex-shrink: 0;
  font-style: italic;
  font-family: 'Segoe UI Symbol', 'Apple Symbols', Georgia, serif;
}

.ps-line {
  flex: 1;
  position: relative;
  height: 1px;
  background: linear-gradient(to right, #181008, #3a2010, #181008);
  margin: 0 10px;
}

.ps-line::after {
  content: '';
  position: absolute;
  right: -1px;
  top: -3.5px;
  border: 4px solid transparent;
  border-left: 6px solid #3a2010;
}

.ps-klipa {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  width: 136px;
  text-align: right;
  flex-shrink: 0;
}

.ps-klipa a {
  color: #7a5828;
  text-decoration: none;
  border-bottom: 1px solid #301808;
  transition: color 0.2s;
}

.ps-klipa a:hover { color: #b07838; border-bottom-color: #6a3818; text-decoration: none; }

.ps-demon {
  font-size: 10px;
  color: #3a2c14;
  width: 84px;
  text-align: right;
  flex-shrink: 0;
  font-style: italic;
}

/* ── Доминирующая Клипа ── */

.natal-dominant {
  border: 1px solid #221608;
  padding: 26px 28px;
  margin: 0 0 44px;
  background: #040201;
}

.nd-label {
  font-size: 8px;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: #3a2a10;
  margin-bottom: 14px;
}

.nd-name {
  font-size: 26px;
  color: #7a5e2e;
  letter-spacing: 5px;
  text-transform: uppercase;
  margin-bottom: 6px;
  font-weight: normal;
}

.nd-heb {
  font-size: 22px;
  color: #3e2e12;
  direction: rtl;
  letter-spacing: 3px;
  margin-bottom: 14px;
  font-weight: normal;
}

.nd-desc {
  font-size: 13px;
  color: #5a4820;
  font-style: italic;
  line-height: 1.75;
  margin-bottom: 10px;
}

.nd-link {
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #5a3e18;
  border-bottom: 1px solid #2a1a08;
  text-decoration: none;
}

.nd-link:hover { color: #9a6028; text-decoration: none; }

/* ── Интерпретации ── */

.natal-interp { margin: 0 0 44px; }

.natal-interp-item {
  padding: 18px 0 18px 18px;
  border-bottom: 1px solid #111008;
  border-left: 2px solid #1a1008;
  margin-bottom: 2px;
  transition: border-left-color 0.3s;
}

.natal-interp-item:hover { border-left-color: #4a2e10; }
.natal-interp-item:last-child { border-bottom: none; }

.natal-interp-planet {
  font-size: 9px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #4a3818;
  margin-bottom: 8px;
  font-family: 'Segoe UI Symbol', 'Apple Symbols', Georgia, serif;
}

.natal-interp-text {
  font-size: 13px;
  color: #6a5a36;
  font-style: italic;
  line-height: 1.75;
}

/* ── CTA ── */

@keyframes ctaBorder {
  0%, 100% { border-color: #1e1408; box-shadow: none; }
  50%       { border-color: #5a3010; box-shadow: 0 0 28px rgba(70,35,8,0.18); }
}

.natal-cta {
  margin: 0 0 20px;
  border: 1px solid #1e1408;
  padding: 44px 28px;
  text-align: center;
  background: #030201;
  animation: ctaBorder 4s ease-in-out infinite;
}

.cta-eyebrow {
  font-size: 8px;
  letter-spacing: 5px;
  text-transform: uppercase;
  color: #3a2a10;
  margin-bottom: 14px;
}

.cta-title {
  font-size: 17px;
  color: #8a7040;
  letter-spacing: 4px;
  text-transform: uppercase;
  font-style: italic;
  font-weight: normal;
  margin-bottom: 18px;
}

.cta-desc {
  font-size: 13px;
  color: #5a4a24;
  line-height: 1.85;
  max-width: 420px;
  margin: 0 auto 22px;
}

.cta-price {
  font-size: 32px;
  color: #9a6e30;
  letter-spacing: 2px;
  margin-bottom: 26px;
  font-family: Georgia, serif;
  font-weight: normal;
}

.cta-btn {
  display: inline-block;
  border: 1px solid #5a3010;
  color: #9a6028;
  font-family: Georgia, serif;
  font-size: 11px;
  letter-spacing: 5px;
  text-transform: uppercase;
  padding: 17px 44px;
  text-decoration: none;
  transition: border-color 0.3s, color 0.3s, background 0.3s;
  margin-bottom: 18px;
}

.cta-btn:hover {
  border-color: #a06020;
  color: #d09040;
  background: #0b0806;
  text-decoration: none;
}

.cta-note {
  font-size: 9px;
  color: #2e2010;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-style: italic;
  display: block;
}


/* ─── Связанные услуги / навигация в конце статьи ─── */
.page-related {
  margin: 60px 0 20px;
  padding-top: 30px;
  border-top: 1px solid #1a1408;
}
.page-related-label {
  font-size: 9px; color: #5a4828;
  letter-spacing: 5px; text-transform: uppercase;
  display: block; text-align: center;
  margin-bottom: 22px;
  font-style: italic;
}
.page-related-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.page-related-card {
  display: flex; flex-direction: column;
  padding: 18px 16px;
  text-decoration: none;
  border: 1px solid #1a1208;
  background: #050403;
  transition: border-color .3s ease, background .25s ease, transform .25s ease;
  position: relative;
}
.page-related-card:hover {
  border-color: #3a2010;
  background: #080605;
  transform: translateY(-2px);
  text-decoration: none;
}
.page-related-card .pr-heb {
  font-size: 14px; color: #5a4218;
  direction: rtl; letter-spacing: 2px;
  margin-bottom: 8px;
  transition: color .25s;
}
.page-related-card:hover .pr-heb { color: #8a6a32; }
.page-related-card .pr-name {
  font-size: 11px; color: #7a5828;
  letter-spacing: 2px; text-transform: uppercase;
  margin-bottom: 8px; line-height: 1.4;
  transition: color .25s;
}
.page-related-card:hover .pr-name { color: #a07832; }
.page-related-card .pr-desc {
  font-size: 11px; color: #4a3a1e;
  font-style: italic; line-height: 1.6;
}
@media (max-width: 680px) {
  .page-related-grid { grid-template-columns: 1fr; }
}


/* ═══════════════════════════════════════════════════════
   MOBILE SAFETY — предотвращение горизонтального overflow
   Добавлено в БЛОКе 3 подготовки к деплою.
   ═══════════════════════════════════════════════════════ */
html, body {
  overflow-x: hidden;
  max-width: 100vw;
}
* { box-sizing: border-box; }
img, svg, video, table { max-width: 100%; height: auto; }
pre, code { overflow-x: auto; max-width: 100%; }
table { display: block; overflow-x: auto; }

@media (max-width: 760px) {
  /* subtitle с &nbsp;·&nbsp; ломается на мобильных — разрешить обёртку */
  #site-header .subtitle {
    white-space: normal;
    word-spacing: 4px;
    padding: 0 8px;
    line-height: 1.6;
  }
  /* Уменьшить letter-spacing на крупных заголовках legal/faq/payment */
  .legal-hero h1, .pay-hero h1 {
    font-size: 20px !important;
    letter-spacing: 3px !important;
  }
  .legal-hero .heb, .pay-hero .heb {
    font-size: 36px !important;
    letter-spacing: 5px !important;
  }
  .faq-section > h2, .pay-body h2, .legal-body h2 {
    letter-spacing: 3px !important;
    font-size: 11px !important;
  }
  /* Крипто-адреса — уменьшить шрифт чтобы полностью влезли */
  .wallet-addr {
    font-size: 10px !important;
    letter-spacing: 0 !important;
    padding: 12px 10px !important;
  }
  /* Сузить boundary для teaser overlays */
  .gpv-teaser-heb { font-size: 18px !important; letter-spacing: 3px !important; }
  .gpv-teaser-title { font-size: 10px !important; letter-spacing: 3px !important; }
}

@media (max-width: 480px) {
  #site-header .subtitle { font-size: 8px !important; letter-spacing: 2px !important; }
  .legal-hero h1, .pay-hero h1 { font-size: 17px !important; letter-spacing: 2px !important; }
  .faq-nav a { font-size: 9px !important; padding: 3px 8px !important; letter-spacing: 2px !important; }
}
/* Tightening: страницы legal/pay/faq — уменьшить padding на mobile */
@media (max-width: 760px) {
  .legal-main, .pay-main {
    padding: 30px 14px 60px !important;
    max-width: 100vw;
  }
  #wrapper {
    padding: 0 12px !important;
  }
  .pay-steps li {
    padding-left: 46px !important;
  }
  .pay-steps li::before {
    left: 10px !important;
    width: 24px !important; height: 24px !important;
    font-size: 12px !important;
  }
  .wallet-block { padding: 18px 14px !important; }
  .wallet-block::before { top: 5px; left: 5px; right: 5px; bottom: 5px; }
  /* Аккордеон FAQ: уменьшить padding + font */
  details.faq-item summary {
    padding: 14px 40px 14px 16px !important;
    font-size: 13px !important;
  }
  details.faq-item summary::after { right: 14px !important; }
  .faq-body { padding: 4px 16px 18px !important; font-size: 13px !important; }
}

/* ═══════════════════════════════════════════════════════
   A11Y CONTRAST FIX — точечные overrides для читаемого текста
   Соблюдение WCAG AA (>= 4.5:1 для body, >= 3:1 для large).
   ═══════════════════════════════════════════════════════ */
#site-header .subtitle { color: #7a5c3a; }
.blockquote cite { color: #7a6238; }
.legal-updated { color: #7a5a2a; }
.pay-updated { color: #7a5a2a; }
.faq-still h3 { color: #a07030; }
.dark-seal { color: #8a7448; }
.gtl-num, .gs-lbl { color: #8a6a3a; }

/* Keyboard-nav visibility: focus-outline на всех интерактивных */
a:focus-visible, button:focus-visible, summary:focus-visible,
input:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid #c8a250;
  outline-offset: 3px;
  border-radius: 1px;
}
a:focus:not(:focus-visible), button:focus:not(:focus-visible) { outline: none; }

/* ═══════════════════════════════════════════════════════
   PRINT-STYLES — для распечатки legal/faq/payment
   Читаемо на бумаге, без анимаций и bg.
   ═══════════════════════════════════════════════════════ */
@media print {
  body { background: #fff !important; color: #000 !important; font-family: Georgia, serif; }
  #topnav, #sidebar, #mobile-nav-btn, #site-footer, .my-klipa-badge,
  #kliphot-legal, #age-gate-overlay, #mobile-nav-panel,
  .faq-nav, canvas, .init-overlay, .kl-lightbox {
    display: none !important;
  }
  a { color: #000 !important; text-decoration: underline; }
  a[href^="http"]:after, a[href^="mailto:"]:after {
    content: " (" attr(href) ")";
    font-size: 0.85em;
    color: #555;
    font-style: italic;
  }
  a[href^="#"]:after, a[href^="/"]:after { content: ""; }
  h1, h2, h3, h4 { color: #000 !important; page-break-after: avoid; break-after: avoid; }
  #site-header {
    text-align: center;
    padding: 0 0 20px !important;
    border-bottom: 1px solid #000;
    margin-bottom: 30px;
  }
  #site-header .hebrew-title, #site-header .subtitle { color: #333 !important; }
  #site-header .site-title, #site-header .site-title a { color: #000 !important; }

  .legal-main, .pay-main { max-width: 100% !important; padding: 20px !important; }
  .legal-hero, .pay-hero { border-bottom: 1px solid #000 !important; }
  .legal-hero .heb, .pay-hero .heb { color: #333 !important; }
  .legal-hero h1, .pay-hero h1 { color: #000 !important; }
  .legal-body, .pay-body, .faq-body { color: #000 !important; }
  .legal-body h2, .pay-body h2, .faq-section > h2 {
    color: #000 !important; border-bottom: 1px solid #999 !important;
  }
  .legal-body em, .pay-body em, .faq-body em { color: #000 !important; font-style: italic; text-decoration: underline; }
  .legal-body strong, .pay-body strong, .faq-body strong { color: #000 !important; font-weight: bold; }
  .legal-body .callout, .pay-warning {
    border: 1px solid #666 !important; background: #f5f5f5 !important; color: #000 !important; padding: 12px !important;
  }
  .wallet-block { border: 1px solid #000 !important; background: none !important; padding: 12px !important; }
  .wallet-addr { border: 1px solid #999 !important; background: #f8f8f8 !important; color: #000 !important; }

  /* FAQ: раскрыть все аккордеоны при печати */
  details.faq-item { border: 1px solid #ccc !important; background: none !important; margin-bottom: 8px !important; page-break-inside: avoid; }
  details.faq-item[open], details.faq-item {
    display: block !important;
  }
  details.faq-item > summary { list-style: none; cursor: default; font-weight: bold; color: #000 !important; }
  details.faq-item > summary::after { content: "" !important; }
  details.faq-item > *:not(summary) { display: block !important; }
  details.faq-item .faq-body { color: #000 !important; padding: 8px 16px 16px !important; }

  .legal-updated, .pay-updated {
    color: #333 !important; border-top: 1px solid #999 !important; margin-top: 30px; padding-top: 12px;
  }

  /* Скрыть decorative images для экономии тонера */
  .qliphah-header .hebrew-name { color: #333 !important; }
  .dark-seal { border: 1px solid #999; padding: 8px; color: #000 !important; text-align: center; margin-top: 24px; }

  /* Print-header с URL для контекста */
  @page {
    margin: 1.5cm;
  }
}

/* ═══════════════════════════════════════════════════════
   MOBILE HARD-FIX (viewport < 420px) — гарантия отсутствия
   горизонтального overflow на iPhone/Android узких экранах.
   ═══════════════════════════════════════════════════════ */
@media (max-width: 480px) {
  /* Заголовки: значительно уменьшить letter-spacing */
  #site-header .site-title { font-size: 22px !important; letter-spacing: 5px !important; }
  #site-header .hebrew-title { font-size: 18px !important; letter-spacing: 2px !important; }
  #site-header .subtitle {
    font-size: 8px !important; letter-spacing: 1.5px !important;
    padding: 0 6px !important; word-spacing: 2px !important;
  }
  /* Init-rite overlay subtitle */
  #init-overlay .rite-sub,
  #init-overlay .subtitle,
  .rite-line { font-size: 9px !important; letter-spacing: 1.5px !important; }

  /* Content wrap padding — jam maximum */
  #wrapper { padding: 0 8px !important; }
  .legal-main, .pay-main { padding: 20px 10px 50px !important; }

  /* FAQ nav pills — smaller и с overflow-x-scroll */
  .faq-nav {
    gap: 4px 8px !important;
    padding: 0 4px !important;
    justify-content: flex-start !important;
    overflow-x: auto !important;
    flex-wrap: nowrap !important;
    -webkit-overflow-scrolling: touch;
  }
  .faq-nav a {
    font-size: 8.5px !important;
    letter-spacing: 1.5px !important;
    padding: 3px 7px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
  }

  /* Section h2 (FAQ / Pay / Legal) */
  .faq-section > h2, .pay-body h2, .legal-body h2 {
    font-size: 10px !important; letter-spacing: 2px !important;
  }
  .faq-section > h2 .heb-side, .legal-body h2 .heb-side {
    letter-spacing: 1px !important; font-size: 0.95em !important;
  }

  /* Body text */
  .legal-body, .pay-body, .faq-body { font-size: 13.5px !important; line-height: 1.7 !important; }

  /* Payment steps */
  .pay-steps li { padding: 12px 12px 12px 40px !important; font-size: 12.5px !important; }
  .pay-steps li::before { left: 8px !important; width: 22px !important; height: 22px !important; font-size: 11px !important; }

  /* Wallet — сузить */
  .wallet-block { padding: 12px 10px !important; }
  .wallet-addr {
    font-size: 9px !important; padding: 10px 8px !important;
    letter-spacing: 0 !important; word-break: break-all !important;
  }

  /* Footer legal-links */
  #kliphot-legal { font-size: 8px !important; letter-spacing: 1.5px !important; line-height: 1.8 !important; }
  #kliphot-legal a { margin: 0 4px !important; padding-bottom: 0 !important; }

  /* Prevent any element sticking wider than viewport */
  body * { max-width: 100vw; }
  main, article, section, header, footer, nav, div, p, ul, ol {
    max-width: 100% !important;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  /* Tables — force scroll wrapper */
  table { display: block !important; overflow-x: auto !important; max-width: 100% !important; }

  /* Init rite overlay: reduce hero content */
  .init-hero .heb, .rite-heb { font-size: 42px !important; letter-spacing: 6px !important; }
  .rite-name-input, .rite-input { max-width: 90vw !important; }
}