/* ================================================
   Salamandra.pro — минималистичная дизайн-система
   Светло-серые тона, стиль Notion/Linear.
   ================================================ */

:root {
  /* Палитра */
  --bg: #ffffff;
  --bg-subtle: #fafafa;
  --bg-hover: #f4f4f5;
  --border: #e5e7eb;
  --border-subtle: #f0f0f0;
  --text: #18181b;
  --text-muted: #52525b;
  --text-subtle: #a1a1aa;
  --accent: #18181b;
  --accent-hover: #27272a;

  /* Размеры */
  --radius-sm: 4px;
  --radius: 6px;
  --radius-lg: 10px;

  /* Тени */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);

  /* Grid */
  --container-width: 880px;
  --container-width-narrow: 720px;

  /* Типографика */
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, "Noto Sans", sans-serif,
               "Apple Color Emoji", "Segoe UI Emoji";
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
}

* { box-sizing: border-box; }

html {
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

a {
  color: var(--text);
  text-decoration: none;
  transition: color 0.15s ease;
}
a:hover { color: var(--text-muted); }

h1, h2, h3, h4 {
  margin: 0 0 0.8em;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

h1 { font-size: 2.25rem; letter-spacing: -0.03em; }
h2 { font-size: 1.5rem; margin-top: 2.5em; }
h3 { font-size: 1.15rem; margin-top: 1.8em; }

p { margin: 0 0 1em; color: var(--text-muted); }
p.lead { font-size: 1.1rem; color: var(--text); }

/* ═══════════════════ HEADER ═══════════════════ */

.header {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(8px);
  -webkit-backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 100;
}

.header__inner {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.logo {
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.logo__mark {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
}

.nav {
  display: flex;
  gap: 4px;
  margin-left: auto;
  flex-wrap: wrap;
}

.nav__link {
  padding: 6px 12px;
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: background 0.15s ease, color 0.15s ease;
}

.nav__link:hover {
  background: var(--bg-hover);
  color: var(--text);
}

.nav__link.is-active {
  color: var(--text);
  background: var(--bg-hover);
}

.lang-toggle {
  display: inline-flex;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2px;
  margin-left: 12px;
}

.lang-toggle__btn {
  padding: 4px 10px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-subtle);
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
}

.lang-toggle__btn:hover { color: var(--text); }

.lang-toggle__btn.is-active {
  background: var(--bg);
  color: var(--text);
  box-shadow: var(--shadow-xs);
}

/* ═══════════════════ USER CHIP ═══════════════════ */

.user-box {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-left: 12px;
}

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 4px 3px 3px;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.85rem;
}

.user-chip__avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 600;
  background: var(--accent);
  color: #fff;
}

.user-chip__avatar--mock { text-transform: uppercase; }

.user-chip__name {
  color: var(--text);
  max-width: 110px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-chip__logout {
  color: var(--text-subtle);
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 0.72rem;
  line-height: 1;
}
.user-chip__logout:hover { color: var(--text); background: var(--bg-hover); }

.user-chip__caret {
  color: var(--text-subtle);
  font-size: 0.7rem;
  margin: 0 6px 0 2px;
  transition: transform 0.15s ease;
}

/* Dropdown via <details> */
.user-menu { position: relative; }
.user-menu > summary {
  list-style: none;
  cursor: pointer;
}
.user-menu > summary::-webkit-details-marker { display: none; }
.user-menu[open] > summary .user-chip__caret { transform: rotate(180deg); }
.user-menu > summary:hover .user-chip__name { color: var(--text-muted); }

.user-menu__drop {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  min-width: 240px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm), 0 8px 24px rgba(0, 0, 0, 0.08);
  padding: 6px;
  z-index: 200;
  animation: user-menu-fade 0.12s ease;
}

@keyframes user-menu-fade {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.user-menu__head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px 12px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 6px;
}

.user-menu__avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  object-fit: cover;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  font-weight: 600;
  background: var(--accent);
  color: #fff;
  flex-shrink: 0;
}
.user-menu__avatar--mock { text-transform: uppercase; }

.user-menu__name { font-weight: 600; font-size: 0.92rem; line-height: 1.2; }
.user-menu__username { font-size: 0.78rem; color: var(--text-subtle); margin-top: 2px; }

.user-menu__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: var(--radius);
  color: var(--text);
  font-size: 0.9rem;
  text-decoration: none;
}
.user-menu__item:hover {
  background: var(--bg-hover);
  color: var(--text);
}

.user-menu__item--admin { color: #a16207; }
.user-menu__item--admin:hover { background: #fef3c7; color: #854d0e; }

.user-menu__item--logout { color: #b91c1c; }
.user-menu__item--logout:hover { background: #fee2e2; color: #991b1b; }

.user-menu__sep {
  border: none;
  border-top: 1px solid var(--border-subtle);
  margin: 6px 8px;
}

/* ═══════════════════ PROFILE PAGE ═══════════════════ */

.profile-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-top: 24px;
}

.profile-card__head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.profile-card__avatar {
  width: 64px; height: 64px;
  border-radius: 50%;
  object-fit: cover;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  font-weight: 600;
  background: var(--accent);
  color: #fff;
  flex-shrink: 0;
}
.profile-card__avatar--mock { text-transform: uppercase; }

.profile-card__name {
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.profile-card__username {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.profile-kv {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 12px 16px;
  margin: 0;
  font-size: 0.92rem;
}
.profile-kv dt {
  font-weight: 500;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.profile-kv dd { margin: 0; color: var(--text); }
.profile-kv .mono { font-family: var(--font-mono); font-size: 0.86rem; }

@media (max-width: 520px) {
  .profile-kv { grid-template-columns: 1fr; gap: 4px 0; }
  .profile-kv dd { margin-bottom: 12px; }
  .profile-card { padding: 16px; }
  .user-menu__drop { right: -8px; min-width: 220px; }
}

/* ═══════════════════ LOGIN PAGE EXTRAS ═══════════════════ */

.login-lang {
  display: inline-flex;
  gap: 6px;
  margin-bottom: 28px;
}

.login-lang__btn {
  padding: 4px 12px;
  font-size: 0.82rem;
  font-weight: 500;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text-muted);
}
.login-lang__btn.is-active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.login-widget { min-height: 52px; }
.login-note { color: var(--text-muted); font-size: 0.85rem; }

.login-providers {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin: 8px 0;
}

.login-provider-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 22px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.12s ease, filter 0.12s ease;
  min-width: 224px;
  border: none;
  font-family: inherit;
}
.login-provider-btn:hover { transform: translateY(-1px); }
.login-provider-btn:active { transform: translateY(0); }

.login-provider-btn--yandex {
  background: #000;
  color: #fff;
}
.login-provider-btn--yandex:hover { background: #1a1a1a; color: #fff; filter: none; }

.login-provider-btn--google {
  background: #fff;
  color: #3c4043;
  border: 1px solid #dadce0;
}
.login-provider-btn--google:hover { background: #f8f9fa; color: #3c4043; filter: none; }

.login-error {
  margin-top: 20px;
  padding: 8px 14px;
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
  border-radius: var(--radius);
  font-size: 0.88rem;
}

.login-page {
  max-width: 880px;
  margin: 0 auto;
  padding: 48px 24px 80px;
}

.login-hero {
  text-align: center;
  padding: 32px 0 48px;
}

.login-hero__logo {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 16px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.login-hero__title {
  font-size: 2.4rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 auto 14px;
  max-width: 680px;
}

.login-hero__sub {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 580px;
  margin: 0 auto 24px;
}

.login-sections {
  padding: 40px 0 24px;
  border-top: 1px solid var(--border-subtle);
}

.login-sections__title,
.login-features h2 {
  font-size: 1.3rem;
  text-align: center;
  margin-bottom: 24px;
  letter-spacing: -0.01em;
}

.login-sections .card { text-align: left; }

.login-features {
  padding: 24px 0 40px;
  max-width: 700px;
  margin: 0 auto;
}

.features-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 14px;
}
.features-list li {
  padding: 14px 18px;
  background: var(--bg-subtle);
  border-radius: var(--radius);
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.features-list li strong { color: var(--text); }

@media (max-width: 640px) {
  .login-hero__title { font-size: 1.8rem; }
  .login-hero__sub { font-size: 0.95rem; }
  .login-page { padding: 24px 16px 48px; }
}

.login-why {
  margin: 32px auto 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: 520px;
  text-align: center;
}
.login-why summary {
  cursor: pointer;
  color: var(--text-subtle);
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--radius);
}
.login-why summary:hover { background: var(--bg-subtle); color: var(--text-muted); }
.login-why p { margin-top: 16px; text-align: left; }
.login-privacy { font-size: 0.78rem; color: var(--text-subtle); }

/* ═══════════════════ CONTAINER ═══════════════════ */

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 48px 24px 96px;
}

.container--narrow { max-width: var(--container-width-narrow); }

/* ═══════════════════ HERO ═══════════════════ */

.hero {
  padding: 80px 0 64px;
  text-align: center;
}

.hero__title {
  font-size: 3rem;
  font-weight: 700;
  letter-spacing: -0.035em;
  margin-bottom: 0.4em;
}

.hero__subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 540px;
  margin: 0 auto 2em;
}

.hero__cta {
  display: inline-flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ═══════════════════ BUTTONS ═══════════════════ */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
  text-decoration: none;
}

.btn:hover {
  background: var(--bg-hover);
  color: var(--text);
}

.btn--primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn--primary:hover {
  background: var(--accent-hover);
  color: #fff;
}

/* ═══════════════════ CARDS ═══════════════════ */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  margin: 32px 0;
}

.card {
  padding: 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  border-color: #d4d4d8;
  box-shadow: var(--shadow-sm);
}

.card__emoji { font-size: 1.4rem; margin-bottom: 8px; }
.card__title { font-weight: 600; margin-bottom: 4px; font-size: 0.95rem; }
.card__desc  { font-size: 0.85rem; color: var(--text-muted); margin: 0; }

/* ═══════════════════ HORARY TREE ═══════════════════ */

.horary-tree { margin-top: 24px; }

.horary-tree__controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
  padding: 12px 16px;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.horary-tree__stats {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.horary-tree__search {
  flex: 1;
  min-width: 200px;
  padding: 6px 12px;
  font-size: 0.88rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
}
.horary-tree__search:focus { outline: 2px solid #d4d4d8; outline-offset: -1px; }

.tree-actions { display: flex; gap: 6px; }

.tree-action-btn {
  padding: 4px 10px;
  font-size: 0.78rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  font-family: inherit;
}
.tree-action-btn:hover { background: var(--bg-hover); color: var(--text); }

.cat-group {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 8px;
  background: var(--bg);
  overflow: hidden;
}

.cat-group > summary {
  padding: 12px 16px;
  cursor: pointer;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 10px;
  list-style: none;
  user-select: none;
  transition: background 0.12s ease;
}
.cat-group > summary:hover { background: var(--bg-subtle); }
.cat-group > summary::-webkit-details-marker { display: none; }

.cat-group > summary::before {
  content: "▸";
  font-size: 0.7rem;
  color: var(--text-subtle);
  transition: transform 0.15s ease;
  width: 10px;
  display: inline-block;
}
.cat-group[open] > summary::before { transform: rotate(90deg); }

.cat-group__emoji { font-size: 1rem; }

.cat-group__count {
  margin-left: auto;
  font-size: 0.78rem;
  color: var(--text-subtle);
  font-variant-numeric: tabular-nums;
  background: var(--bg-subtle);
  padding: 2px 8px;
  border-radius: 999px;
}

.question-list {
  list-style: none;
  margin: 0;
  padding: 0 0 4px;
  border-top: 1px solid var(--border-subtle);
}

.question-item {
  padding: 8px 16px 8px 38px;
  font-size: 0.88rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--border-subtle);
}
.question-item:last-child { border-bottom: none; }

.question-item__meta {
  font-size: 0.72rem;
  color: var(--text-subtle);
  background: var(--bg-subtle);
  padding: 1px 6px;
  border-radius: 3px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.question-item__text { flex: 1; }

.question-item.is-hidden { display: none; }
.cat-group.is-hidden { display: none; }

mark {
  background: #fef08a;
  color: inherit;
  padding: 0 2px;
  border-radius: 2px;
}

/* ═══════════════════ FOOTER ═══════════════════ */

.footer {
  border-top: 1px solid var(--border-subtle);
  padding: 32px 24px;
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-subtle);
}

.footer a { color: var(--text-muted); }

/* ═══════════════════ LANGUAGE LANDING ═══════════════════ */

.lang-landing {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  background: var(--bg);
}

.lang-landing__logo {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-landing__logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 18px;
}

.lang-landing__title {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 40px;
  font-weight: 400;
  text-align: center;
  max-width: 420px;
}

.lang-cards {
  display: grid;
  grid-template-columns: repeat(2, 200px);
  gap: 12px;
}

.lang-card {
  padding: 28px 20px;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg);
  cursor: pointer;
  transition: all 0.15s ease;
  text-decoration: none;
  color: var(--text);
}

.lang-card:hover {
  border-color: #a1a1aa;
  background: var(--bg-subtle);
  transform: translateY(-1px);
}

.lang-card__code {
  font-size: 1.4rem;
  font-weight: 600;
  display: block;
  margin-bottom: 4px;
  letter-spacing: 0.02em;
}

.lang-card__name {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* ═══════════════════ ADMIN ═══════════════════ */

.nav__link--admin {
  color: #a16207;
}
.nav__link--admin:hover { color: #854d0e; }

.admin-layout {
  max-width: 1040px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}

.admin-sidebar {
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 12px;
}

.admin-sidebar__title {
  font-weight: 600;
  color: var(--text-subtle);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}

.admin-sidenav {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 4px;
}

.admin-sidenav__link {
  padding: 7px 14px;
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: 0.9rem;
  white-space: nowrap;
}
.admin-sidenav__link:hover {
  background: var(--bg-hover);
  color: var(--text);
}
.admin-sidenav__link.is-active {
  background: var(--bg-hover);
  color: var(--text);
  font-weight: 500;
}

.admin-content {
  width: 100%;
}

.admin-content h1 { margin: 0 0 24px; font-size: 1.7rem; }
.admin-content h2 { font-size: 1.1rem; margin-top: 32px; margin-bottom: 12px; }

.admin-count {
  color: var(--text-subtle);
  font-size: 0.85rem;
  margin-bottom: 16px;
}

.admin-filter {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.admin-filter__input {
  flex: 1;
  min-width: 220px;
  padding: 7px 12px;
  font-size: 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
}

/* KPI cards */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.kpi {
  padding: 14px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.kpi__label { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 4px; }
.kpi__value { font-size: 1.6rem; font-weight: 600; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.kpi__sub { font-size: 0.72rem; color: var(--text-subtle); margin-top: 2px; }

/* Data tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 8px;
  font-size: 0.88rem;
}
.data-table th {
  text-align: left;
  padding: 8px 10px;
  font-weight: 500;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-subtle);
  border-bottom: 1px solid var(--border);
}
.data-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border-subtle);
  vertical-align: top;
}
.data-table tr.is-blocked { opacity: 0.5; }
.data-table .empty {
  text-align: center;
  color: var(--text-subtle);
  padding: 20px;
}
.data-table .subtle { color: var(--text-subtle); font-size: 0.8rem; }
.data-table .mono { font-family: var(--font-mono); }
.data-table code { font-size: 0.82rem; background: var(--bg-subtle); padding: 1px 5px; border-radius: 3px; }

.avatar-xs {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 600;
  background: var(--accent);
  color: #fff;
  object-fit: cover;
}
.avatar-xs--mock { text-transform: uppercase; }

.badge {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 500;
}
.badge--ok  { background: #dcfce7; color: #166534; }
.badge--err { background: #fee2e2; color: #991b1b; }
.badge--premium { background: #fef3c7; color: #854d0e; }

.admin-filter__check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
}
.admin-filter__check input { margin: 0; }

/* Security section cards */
.sec-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 16px;
  background: var(--bg);
}

.sec-card__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.sec-card__name {
  font-weight: 600;
  font-size: 0.95rem;
}

.sec-card__stats {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.sec-form {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.sec-form input[type="text"] {
  flex: 1;
  min-width: 240px;
  padding: 7px 12px;
  font-size: 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
}

.sec-subheading {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 16px;
  margin-bottom: 6px;
}

.top-ips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.top-ip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.82rem;
}

.top-ip code {
  font-size: 0.8rem;
  background: none;
  padding: 0;
}

.top-ip__btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0 2px;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.top-ip__btn:hover { color: #991b1b; }

@media (max-width: 720px) {
  .admin-layout { padding: 20px 14px 60px; }
  .admin-sidenav { overflow-x: auto; flex-wrap: nowrap; }
  .data-table { font-size: 0.8rem; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ═══════════════════ RESPONSIVE ═══════════════════ */

@media (max-width: 720px) {
  html { font-size: 14px; }

  .hero { padding: 48px 0 32px; }
  .hero__title { font-size: 2.2rem; }
  .hero__subtitle { font-size: 1rem; }

  .container { padding: 32px 18px 64px; }

  .header__inner {
    padding: 12px 16px;
    flex-wrap: wrap;
    gap: 12px;
  }

  .nav { gap: 2px; width: 100%; order: 3; overflow-x: auto; }
  .nav__link { padding: 4px 8px; font-size: 0.85rem; }
  .lang-toggle { margin-left: auto; order: 2; }

  .cards { grid-template-columns: 1fr; }

  .lang-cards { grid-template-columns: 1fr; width: 100%; max-width: 260px; }

  .cat-group > summary { padding: 10px 12px; }
  .question-item { padding: 8px 12px 8px 28px; }
}

@media (max-width: 480px) {
  .logo { font-size: 0.95rem; }
  .horary-tree__controls { padding: 10px; }
  .horary-tree__search { min-width: 100%; }
}

/* ── Natal chart ───────────────────────────────────────────────── */

.natal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.natal-head__edit {
  font-size: 0.88rem;
  color: #6b7280;
  text-decoration: none;
  padding: 6px 12px;
  border-radius: 6px;
  border: 1px solid #e5e7eb;
  transition: all 0.12s;
}
.natal-head__edit:hover { background: #f9fafb; color: #111827; }

.natal-meta {
  padding: 12px 16px;
  background: #f9fafb;
  border-radius: 8px;
  margin-bottom: 24px;
  font-size: 0.92rem;
  color: #374151;
}
.natal-meta b { color: #111827; }

.natal-back {
  display: inline-block;
  font-size: 0.9rem;
  color: #6b7280;
  text-decoration: none;
  margin-bottom: 12px;
  padding: 4px 0;
}
.natal-back:hover { color: #111827; }

.natal-sections {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.natal-sections__card {
  display: block;
  padding: 18px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  background: #fff;
  transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s;
}
.natal-sections__card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
  border-color: #d1d5db;
}
.natal-sections__card--soon {
  opacity: 0.5;
  cursor: default;
}
.natal-sections__card--soon:hover {
  transform: none;
  box-shadow: none;
  border-color: #e5e7eb;
}
.natal-sections__emoji { font-size: 1.6rem; margin-bottom: 6px; }
.natal-sections__title { font-weight: 600; margin-bottom: 6px; }
.natal-sections__desc { font-size: 0.88rem; color: #6b7280; line-height: 1.4; }

/* Форма ввода */
.natal-form {
  display: grid;
  gap: 16px;
  max-width: 480px;
  margin-top: 24px;
}
.form-error {
  padding: 10px 14px;
  background: #fef2f2;
  color: #991b1b;
  border-radius: 8px;
  border: 1px solid #fecaca;
}
.field {
  display: grid;
  gap: 4px;
}
.field__label {
  font-size: 0.88rem;
  color: #374151;
  font-weight: 500;
}
.field input[type="text"],
.field input[type="date"],
.field input[type="time"] {
  padding: 10px 12px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.12s, box-shadow 0.12s;
}
.field input:focus {
  outline: none;
  border-color: #6b7280;
  box-shadow: 0 0 0 3px rgba(107, 114, 128, 0.1);
}
.field--error input { border-color: #ef4444; }
.field__err {
  font-size: 0.82rem;
  color: #dc2626;
  margin-top: 2px;
}
.field__hint {
  font-size: 0.82rem;
  color: #6b7280;
  margin-top: 2px;
}
.field--radio {
  border: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.field--radio legend { padding: 0; margin-bottom: 6px; }
.radio {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  font-size: 0.95rem;
}
.btn {
  display: inline-block;
  padding: 10px 22px;
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  font-family: inherit;
  transition: transform 0.12s, filter 0.12s;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary {
  background: #111827;
  color: #fff;
}
.btn--primary:hover { background: #1f2937; }

.header__login {
  padding: 7px 18px;
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: 8px;
  white-space: nowrap;
}

/* ── Horary Smart Search ─────────────────────────────────────────── */
.horary-ai {
  margin: 24px 0 32px;
  padding: 24px;
  background: linear-gradient(135deg, #faf5ff 0%, #fef3c7 100%);
  border: 1px solid #e9d5ff;
  border-radius: 14px;
}
.horary-ai h2 { margin-top: 0; margin-bottom: 8px; font-size: 1.2rem; }
.horary-ai__hint {
  font-size: 0.88rem;
  color: #57534e;
  margin-bottom: 16px;
  line-height: 1.5;
}
.horary-ai__box {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}
.horary-ai__input {
  flex: 1;
  padding: 14px 18px;
  font-size: 1rem;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #fff;
  font-family: inherit;
  transition: border-color 0.12s, box-shadow 0.12s;
}
.horary-ai__input:focus {
  outline: none;
  border-color: #9333ea;
  box-shadow: 0 0 0 3px rgba(147, 51, 234, 0.12);
}
.horary-ai__spinner {
  position: absolute;
  right: 16px;
  font-size: 1.2rem;
  animation: ai-spin 1s linear infinite;
}
@keyframes ai-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.horary-ai__results {
  margin-top: 16px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
.ai-empty {
  padding: 14px 16px;
  color: #6b7280;
  font-style: italic;
  font-size: 0.92rem;
}
.ai-card {
  background: #fff;
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  transition: transform 0.12s, box-shadow 0.12s;
}
.ai-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  border-color: #c4b5fd;
}
.ai-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}
.ai-card__cat {
  font-size: 0.82rem;
  color: #6b7280;
  font-weight: 500;
}
.ai-card__score {
  font-size: 0.75rem;
  padding: 2px 8px;
  background: #ede9fe;
  color: #6d28d9;
  border-radius: 10px;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
}
.ai-card__title {
  font-size: 1rem;
  font-weight: 500;
  color: #111827;
  margin-bottom: 4px;
}
.ai-card__house {
  font-size: 0.78rem;
  color: #9ca3af;
}
.ai-card {
  display: block;
  text-decoration: none;
  color: inherit;
}

/* Horary ask/result pages */
.horary-ask, .horary-result {
  margin-top: 24px;
}
.horary-ask__cat, .horary-result__cat {
  font-size: 0.88rem;
  color: #6b7280;
  margin-bottom: 4px;
}
.horary-ask__title, .horary-result__title {
  margin: 0 0 8px 0;
  font-size: 1.4rem;
}
.horary-ask__meta, .horary-result__meta {
  font-size: 0.88rem;
  color: #374151;
  padding: 10px 14px;
  background: #f9fafb;
  border-radius: 8px;
  margin-bottom: 20px;
}
.horary-ask__lead {
  font-size: 0.92rem;
  color: #374151;
  margin: 20px 0;
  line-height: 1.5;
  padding: 14px 16px;
  background: #faf5ff;
  border-left: 3px solid #9333ea;
  border-radius: 4px;
}
.horary-ask__form {
  display: grid;
  gap: 18px;
  max-width: 520px;
}

.horary-result__pages {
  display: grid;
  gap: 20px;
}
.horary-page {
  white-space: pre-wrap;
  line-height: 1.6;
  font-size: 0.95rem;
  color: #1f2937;
  background: #fff;
  padding: 20px 24px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
}
.horary-page b { color: #111827; }
.horary-page + .horary-page {
  border-top: 3px solid #ede9fe;
}
.horary-result__footer {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid #e5e7eb;
  text-align: center;
}
.horary-result__footer .btn {
  background: #f3f4f6;
  color: #374151;
  border: 1px solid #e5e7eb;
}

/* Tools timezone banner */
.tz-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  margin: 12px 0 20px;
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  border-radius: 8px;
  font-size: 0.86rem;
  color: #0c4a6e;
  line-height: 1.4;
}
.tz-banner__icon { flex-shrink: 0; }
.tz-banner__text { flex: 1; }
.tz-banner a { color: #0369a1; font-weight: 500; }

/* Lunar calendar grid */
.lunar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin-top: 12px;
}
.lunar-grid--weekdays {
  margin-bottom: 0;
  margin-top: 16px;
}
.lunar-wd {
  text-align: center;
  font-size: 0.78rem;
  font-weight: 600;
  color: #6b7280;
  padding: 4px 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.lunar-tile--empty {
  background: transparent;
  border: 1px dashed #f3f4f6;
  pointer-events: none;
  min-height: 76px;
}
.lunar-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 10px 6px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  text-align: center;
  position: relative;
  transition: transform 0.1s, border-color 0.1s, box-shadow 0.1s;
  min-height: 76px;
}
.lunar-tile:hover {
  transform: translateY(-1px);
  border-color: #9333ea;
  box-shadow: 0 2px 8px rgba(147, 51, 234, 0.08);
}
.lunar-tile.is-today {
  border-color: #9333ea;
  background: linear-gradient(135deg, #faf5ff 0%, #fef3c7 100%);
}
.lunar-tile.has-eclipse {
  background: #fef2f2;
}
.lunar-tile__date {
  font-size: 0.95rem;
  font-weight: 600;
  color: #111827;
}
.lunar-tile__phase { font-size: 1.2rem; line-height: 1; }
.lunar-tile__lday {
  font-size: 0.7rem;
  color: #6b7280;
  font-variant-numeric: tabular-nums;
}
.lunar-tile__ecl {
  position: absolute;
  top: 2px;
  right: 4px;
  font-size: 0.7rem;
}

/* Garden calendar (FullCalendar) */
.garden-cal {
  margin-top: 16px;
}
.garden-cal .fc { font-family: inherit; }
.garden-cal .fc-toolbar-title {
  font-size: 1.2rem !important;
  font-weight: 600;
  text-transform: capitalize;
}
.garden-cal .fc-button {
  background: #f3f4f6 !important;
  color: #111827 !important;
  border-color: #e5e7eb !important;
  font-weight: 500;
  text-transform: none !important;
  padding: 6px 14px !important;
}
.garden-cal .fc-button:hover { background: #e5e7eb !important; }
.garden-cal .fc-button-primary:not(:disabled).fc-button-active {
  background: #9333ea !important;
  border-color: #9333ea !important;
  color: #fff !important;
}
.garden-cal .fc-daygrid-day {
  cursor: pointer;
  transition: filter 0.12s;
}
.garden-cal .fc-daygrid-day:hover { filter: brightness(0.96); }
.garden-cal .fc-day-today {
  /* фон НЕ трогаем — чтобы не перебивать градиент стихий,
     сегодня выделяем только рамкой */
  background: transparent !important;
  box-shadow: inset 0 0 0 3px #9333ea;
  position: relative;
  z-index: 1;
}
.garden-cal .garden--fertile { background: #f0fdf4 !important; }
.garden-cal .garden--neutral { background: #fefce8 !important; }
.garden-cal .garden--barren { background: #fef2f2 !important; }
.garden-badge {
  font-size: 0.78rem;
  text-align: center;
  padding: 2px 4px;
  line-height: 1.2;
}
.garden-badge__lday {
  display: inline-block;
  background: rgba(255,255,255,0.7);
  border-radius: 8px;
  padding: 0 5px;
  font-size: 0.66rem;
  font-weight: 600;
  color: #374151;
  font-variant-numeric: tabular-nums;
}

/* Lunar calendar badges */
.lunar-badge {
  text-align: center;
  padding: 2px 0 4px;
  line-height: 1.15;
}
.lunar-badge__phase { font-size: 1.1rem; }
.lunar-badge__lday {
  font-size: 0.66rem;
  color: #6b7280;
  font-variant-numeric: tabular-nums;
}
.lunar--eclipse {
  box-shadow: inset 0 0 0 2px #f87171 !important;
}

/* Info table (natal info page) */
.info-meta {
  padding: 10px 14px;
  background: #f9fafb;
  border-radius: 8px;
  margin-bottom: 18px;
  font-size: 0.92rem;
  color: #374151;
}
.info-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
  font-size: 0.94rem;
}
.info-table td {
  padding: 7px 8px;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: middle;
}
.info-table__sym {
  font-size: 1.2rem;
  width: 32px;
  text-align: center;
  color: #6b7280;
}
.info-table__name { font-weight: 500; color: #111827; }
.info-table__sign { color: #374151; white-space: nowrap; }
.info-table__deg {
  color: #6b7280; font-variant-numeric: tabular-nums; white-space: nowrap;
}
.info-table__house {
  color: #9ca3af; font-size: 0.88rem;
  white-space: nowrap; text-align: right;
}
.info-retro { color: #dc2626; font-weight: 600; margin-left: 4px; }

/* Календарь стрижек */
.haircut-modes {
  display: flex;
  gap: 8px;
  margin: 14px 0 6px;
}
.haircut-mode {
  padding: 8px 16px;
  border-radius: 8px;
  background: #f3f4f6;
  color: #374151;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  border: 1px solid #e5e7eb;
}
.haircut-mode.is-active {
  background: #9333ea;
  color: #fff;
  border-color: #9333ea;
}
.haircut-legend {
  font-size: 0.85rem;
  color: #6b7280;
  margin: 8px 0 12px;
}
.haircut-badge {
  text-align: center;
  padding: 2px 0;
  line-height: 1.2;
}
.haircut-badge__emoji { font-size: 1.1rem; }
.haircut-badge__score {
  font-size: 0.74rem;
  color: #374151;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* Народный календарь */
.folk-badge {
  font-size: 0.74rem;
  color: #57534e;
  padding: 2px 4px;
  text-align: center;
  line-height: 1.2;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lunar-badge__trans {
  font-size: 0.66rem;
  color: #374151;
  font-weight: 500;
  margin-top: 1px;
}

/* Вертикальная полоска «текущее время» в ячейке сегодняшнего дня */
.lunar-now-line {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #dc2626;
  z-index: 5;
  pointer-events: none;
  box-shadow: 0 0 4px rgba(220, 38, 38, 0.55);
}
.lunar-now-line::before {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #dc2626;
  box-shadow: 0 0 6px rgba(220, 38, 38, 0.55);
}

/* Иконка знака зодиака — на центральном дне серии (под текстом) */
.lunar-zodiac {
  position: absolute;
  bottom: 4px;
  right: 4px;
  width: 32px;
  height: 32px;
  font-size: 32px;
  color: #1f2937;
  opacity: 0.45;
  pointer-events: none;
  z-index: 0;
}

/* Garden modal */
.garden-modal {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
}
.garden-modal[hidden] { display: none; }
.garden-modal__backdrop {
  position: absolute; inset: 0;
  background: rgba(17, 24, 39, 0.55);
}
.garden-modal__panel {
  position: relative;
  background: #fff;
  border-radius: 14px;
  padding: 24px 28px;
  max-width: 520px;
  width: calc(100% - 32px);
  max-height: 88vh;
  overflow: auto;
  box-shadow: 0 12px 40px rgba(0,0,0,0.25);
}
.garden-modal__close {
  position: absolute; top: 8px; right: 12px;
  font-size: 1.6rem; line-height: 1; padding: 4px 10px;
  background: transparent; border: none; cursor: pointer;
  color: #6b7280;
}
.garden-modal__close:hover { color: #111827; }

/* Автокомплит города */
.autocomplete-wrap { position: relative; }
.autocomplete {
  position: absolute;
  top: calc(100% + 2px); left: 0; right: 0;
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  max-height: 280px;
  overflow-y: auto;
  z-index: 100;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  display: none;
}
.autocomplete.is-open { display: block; }
.ac-item {
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 1px solid #f3f4f6;
  font-size: 0.92rem;
  line-height: 1.3;
}
.ac-item:last-child { border-bottom: none; }
.ac-item:hover { background: #f9fafb; }
.ac-item b { color: #111827; font-weight: 600; }
.ac-meta { color: #6b7280; font-size: 0.86rem; }

/* Психика: меню и подменю */
.psy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
  margin-top: 20px;
}
.psy-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 14px 10px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  text-decoration: none;
  color: inherit;
  min-height: 90px;
  transition: all 0.12s;
  position: relative;
}
.psy-btn:hover {
  background: #f9fafb;
  border-color: #9ca3af;
  transform: translateY(-1px);
}
.psy-btn__emoji { font-size: 1.4rem; }
.psy-btn__title { font-size: 0.88rem; margin-top: 4px; font-weight: 500; }
.psy-btn--soon {
  opacity: 0.45;
  cursor: default;
  pointer-events: none;
}
.psy-btn__badge {
  position: absolute;
  top: 4px;
  right: 4px;
  font-size: 0.68rem;
  padding: 1px 6px;
  background: #e5e7eb;
  border-radius: 8px;
  color: #6b7280;
}

.psy-subs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 16px 0 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid #e5e7eb;
}
.psy-sub {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  font-size: 0.85rem;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  background: #fff;
  color: #374151;
  text-decoration: none;
  transition: all 0.1s;
}
.psy-sub:hover { border-color: #9ca3af; color: #111827; }
.psy-sub.is-active {
  background: #111827;
  color: #fff;
  border-color: #111827;
}
.psy-sub__emoji { font-size: 0.95rem; }

.psy-text {
  white-space: pre-wrap;
  line-height: 1.6;
  font-size: 0.95rem;
  color: #1f2937;
}
.psy-text b { color: #111827; }

/* Psy help (collapsible accordion) */
.psy-help {
  margin-top: 24px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #f9fafb;
  overflow: hidden;
}
.psy-help__summary {
  cursor: pointer;
  padding: 12px 16px;
  font-weight: 500;
  color: #111827;
  font-size: 0.95rem;
  user-select: none;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
}
.psy-help__summary::-webkit-details-marker { display: none; }
.psy-help__summary::before {
  content: '▶';
  font-size: 0.7rem;
  color: #9ca3af;
  transition: transform 0.15s;
  display: inline-block;
}
.psy-help[open] .psy-help__summary::before { transform: rotate(90deg); }
.psy-help__hint {
  font-size: 0.82rem;
  color: #9ca3af;
  font-weight: 400;
  margin-left: 4px;
}
.psy-help__body {
  padding: 4px 18px 18px;
  white-space: pre-wrap;
  line-height: 1.55;
  font-size: 0.9rem;
  color: #374151;
  border-top: 1px solid #e5e7eb;
}
.psy-help__body b { color: #111827; }

.psy-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 28px 0 8px;
  padding-top: 18px;
  border-top: 1px solid #e5e7eb;
}
.psy-pager__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  border-radius: 20px;
  text-decoration: none;
  background: #111827;
  color: #fff;
  font-size: 1rem;
  transition: transform 0.12s;
}
.psy-pager__btn:hover { transform: translateY(-1px); }
.psy-pager__btn--disabled {
  background: #e5e7eb;
  color: #9ca3af;
  cursor: default;
}
.psy-pager__pos {
  font-size: 0.92rem;
  color: #374151;
  font-variant-numeric: tabular-nums;
  min-width: 54px;
  text-align: center;
}

.natal-footnote {
  margin-top: 32px;
  padding-top: 16px;
  border-top: 1px solid #e5e7eb;
  font-size: 0.82rem;
  color: #6b7280;
  font-style: italic;
}

