:root {
  color-scheme: light;
  --ink-950: #091321;
  --ink-900: #101a2c;
  --ink-800: #18263b;
  --ink-700: #283a50;
  --text: #1b2635;
  --muted: #5c5b58;
  --paper: #f6f0e5;
  --paper-deep: #eee3d2;
  --card: #fffaf0;
  --line: #dbccb6;
  --gold: #ddb676;
  --gold-pale: #f2d6a5;
  --bronze: #79501b;
  --cyan: #98c8c6;
  --teal: #185b60;
  --white: #f9f0e0;
  --dark-muted: #bcc9d2;
  --dark-line: #405068;
  --font-serif: "PT Serif", Georgia, "Times New Roman", serif;
  --font-sans: "Source Sans 3", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --shell: 1200px;
  --gutter: clamp(18px, 4.5vw, 64px);
  --radius: 15px;
  --shadow: 0 18px 46px #382b1b14;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-padding-block-start: 18px; }

body {
  margin: 0;
  min-width: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 1rem/1.6 var(--font-sans);
  -webkit-font-smoothing: antialiased;
}

[hidden] { display: none !important; }

img, svg { display: block; max-width: 100%; }
img { height: auto; }
picture { display: block; }
figure { margin: 0; }
/* Entry artwork keeps one frame when square thumbnails replace wide covers. */
.daily-entry [data-art-override] { max-width:450px; aspect-ratio:40/21; overflow:hidden; }
.daily-entry [data-art-override] img { width:100%; height:100%; object-fit:cover; }
h1, h2, h3, h4, p, ul, ol { margin-block-start: 0; }
h1, h2, h3, h4 { line-height: 1.13; overflow-wrap: anywhere; }

h1, h2, h3 {
  margin-block-end: 0.6em;
  font-family: var(--font-serif);
  font-weight: 400;
}

h1 { font-size: clamp(2.35rem, 5.95vw, 5rem); letter-spacing: -0.043em; }
h2 { font-size: clamp(1.9rem, 4vw, 3.35rem); letter-spacing: -0.039em; }
h3 { font-size: clamp(1.35rem, 2.25vw, 1.9rem); letter-spacing: -0.022em; }
h4 { margin-block-end: 0.65em; }

a {
  color: var(--teal);
  text-decoration-thickness: 0.07em;
  text-underline-offset: 0.2em;
}

a:hover { text-decoration-thickness: 0.12em; }

:focus-visible {
  outline: 3px solid #246b71;
  outline-offset: 4px;
}

.site-header :focus-visible,
.hero :focus-visible,
.ink :focus-visible,
.site-footer :focus-visible { outline-color: var(--cyan); }

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
::selection { color: var(--ink-950); background: var(--gold-pale); }

.site-shell {
  width: min(100% - var(--gutter) * 2, var(--shell));
  margin-inline: auto;
  min-width: 0;
}

.page-main { min-width: 0; }

.skip-link {
  position: fixed;
  z-index: 10;
  inset: 12px auto auto 12px;
  translate: 0 calc(-100% - 18px);
  padding: 12px 16px;
  border-radius: 6px;
  background: var(--card);
  color: var(--ink-900);
}

.skip-link:focus { translate: 0; }

.site-header {
  position: relative;
  z-index: 2;
  background: var(--ink-950);
  color: var(--white);
  border-bottom: 1px solid #50607765;
}

.site-header .site-shell,
.header-inner {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2.4vw, 32px);
  min-height: 72px;
}

.brand {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 10px;
  color: var(--white);
  font: 400 clamp(1.42rem, 2.35vw, 2rem)/1 var(--font-serif);
  letter-spacing: -0.055em;
  text-decoration: none;
  white-space: nowrap;
}

.brand-mark,
.brand > svg,
.brand > img {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  color: var(--gold);
}

.brand-mark svg { width: 100%; height: 100%; }

.top-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  gap: clamp(10px, 1.65vw, 23px);
  min-width: 0;
}

.top-nav ul,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.top-nav a,
.header-actions > a:not(.btn) {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--dark-muted);
  font-size: 0.87rem;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
}

.top-nav a:hover,
.top-nav [aria-current="page"],
.header-actions a:hover { color: var(--gold-pale); }

.top-nav [aria-current="page"] { text-decoration: underline; }

.header-actions {
  margin-inline-start: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}

.header-actions .btn { min-height: 40px; padding: 8px 12px; font-size: 0.82rem; }
.header-actions svg { width: 19px; height: 19px; }

.nav-toggle {
  min-height: 44px;
  padding: 7px 12px;
  color: var(--white);
  border: 1px solid var(--dark-line);
  border-radius: 8px;
  background: transparent;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  min-height: 47px;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--ink-900);
  background: var(--gold);
  font-size: 0.93rem;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  text-decoration: none;
  transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}

.btn.primary:hover, .btn:hover { background: var(--gold-pale); color: var(--ink-950); }

.btn.secondary {
  border-color: #866d4c;
  color: var(--text);
  background: transparent;
}

.btn.secondary:hover { border-color: var(--bronze); color: var(--ink-950); background: var(--paper-deep); }

.hero .btn.secondary,
.site-header .btn.secondary,
.ink .btn.secondary {
  border-color: #ad9673;
  color: var(--white);
}

.hero .btn.secondary:hover,
.site-header .btn.secondary:hover,
.ink .btn.secondary:hover {
  border-color: var(--gold);
  color: var(--gold-pale);
  background: #ddb67619;
}

.btn svg { width: 1.05em; height: 1.05em; }

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  min-height: clamp(470px, 45vw, 655px);
  overflow: hidden;
  align-items: center;
  background: var(--ink-900);
  color: var(--white);
}

.hero::after {
  position: absolute;
  z-index: -1;
  inset: auto var(--gutter) 0;
  height: 1px;
  background: #e6be7c46;
  content: "";
}

.hero > .site-shell,
.hero-inner { position: relative; width: min(100% - var(--gutter) * 2, var(--shell)); margin-inline: auto; }

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(100%, 645px);
  padding-block: clamp(47px, 8.5vw, 112px);
}

.hero-copy h1 {
  max-width: 13ch;
  margin-block-end: 0.31em;
  line-height: 0.98;
  text-wrap: balance;
}

.hero-copy h1 em {
  color: var(--gold-pale);
  font-weight: inherit;
}

.hero .lead {
  max-width: 46ch;
  color: #dce2e7;
  font-size: clamp(1.04rem, 1.75vw, 1.25rem);
}

.eyebrow,
.article-kicker {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-block-end: 0.85rem;
  color: var(--bronze);
  font: 700 0.74rem/1.35 var(--font-sans);
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.eyebrow::before,
.article-kicker::before {
  flex: 0 0 22px;
  height: 1px;
  background: currentColor;
  content: "";
}

.hero .eyebrow,
.ink .eyebrow,
.ink .article-kicker { color: var(--gold); }

.hero-art {
  position: absolute;
  z-index: -2;
  inset: 0 0 0 24%;
  width: 76%;
  height: 100%;
  object-fit: cover;
  object-position: 62% 50%;
  overflow: hidden;
  background: var(--ink-900);
  pointer-events: none;
}

.hero-art picture,
.hero-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 62% 50%;
}

.hero::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  background: linear-gradient(90deg, var(--ink-900) 0%, #101a2cfb 25%, #101a2cd9 39%, #101a2c45 58%, #101a2c00 78%);
  pointer-events: none;
  content: "";
}

.hero .site-shell:has(.hero-art) { position: static; }

.hero-compact { min-height: 315px; }
.hero-compact .hero-copy { padding-block: clamp(38px, 6vw, 74px); }
.hero-compact .hero-copy h1 { max-width: 19ch; }

.lead { font-size: clamp(1.04rem, 1.6vw, 1.22rem); line-height: 1.6; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-block-start: 25px;
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
  list-style: none;
  margin: 0;
  padding: 15px 0;
}

.quick-links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  font-weight: 650;
  font-size: 0.88rem;
}

.quick-links svg { width: 17px; height: 17px; }
.hero .quick-links a,
.ink .quick-links a { color: var(--cyan); }

.section { padding-block: clamp(35px, 6.3vw, 85px); }
.section + .section { border-top: 1px solid var(--line); }
.section.cream { background: var(--paper-deep); }

.section.ink,
.ink {
  background: var(--ink-900);
  border-color: var(--dark-line);
  color: var(--white);
}

.ink a:not(.btn) { color: var(--cyan); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 12px 22px;
  margin-block-end: clamp(15px, 3.35vw, 34px);
}

.section-head h1,
.section-head h2,
.section-head h3 { margin-block-end: 0; }
.section-head p { max-width: 59ch; margin: 0.45rem 0 0; }
.section-head > a { flex: none; font-weight: 650; }

.card-grid,
.catalog-grid,
.desk-grid {
  display: grid;
  gap: clamp(12px, 2.35vw, 26px);
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feature-card,
.panel {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}

.feature-card {
  display: flex;
  flex-direction: column;
  color: var(--text);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

a.feature-card { text-decoration: none; }

.feature-card:hover,
.feature-card:focus-within {
  border-color: #ad9369;
  box-shadow: 0 18px 44px #382b1b25;
}

.feature-card h3 > a,
a.feature-card h3 {
  color: var(--text);
  text-decoration: none;
}

.feature-card h3 > a:hover,
a.feature-card:hover h3 {
  color: var(--teal);
  text-decoration: underline;
}

.feature-card.featured .feature-media { aspect-ratio: 16 / 9; }

.feature-media {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 16 / 8.25;
  overflow: hidden;
  background: var(--ink-800);
  color: var(--gold);
}

.feature-media picture,
.feature-media img { width: 100%; height: 100%; object-fit: cover; }
.feature-media > svg { width: 32%; max-width: 96px; height: auto; }
.feature-card:hover .feature-media img { filter: brightness(1.04); }

.feature-body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  flex: 1 1 auto;
  gap: 7px;
  padding: clamp(15px, 2.5vw, 25px);
}

.feature-title { display: block; margin-block-start: 0; line-height: 1.13; overflow-wrap: anywhere; font-family: var(--font-serif); font-size: clamp(1.35rem, 2.25vw, 1.9rem); letter-spacing: -0.022em; font-weight: 400; }
.feature-body .feature-title,
.feature-body p { margin-block-end: 0; }
.feature-body p { color: var(--muted); }
.feature-body > .btn,
.feature-body > .card-link { margin-block-start: auto; }
.feature-body > .card-link { padding-block-start: 7px; font-size: 0.88rem; font-weight: 700; }

.card-meta {
  color: var(--bronze);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.ink .feature-card,
.ink .panel {
  background: var(--ink-800);
  border-color: var(--dark-line);
  color: var(--white);
}

.ink .feature-body p,
.ink .muted { color: var(--dark-muted); }

.ink .feature-card h3 > a,
.ink a.feature-card h3 { color: var(--white); }

.ink .card-meta { color: var(--gold); }

.topic-icon {
  display: inline-grid;
  place-items: center;
  width: 42px;
  aspect-ratio: 1;
  flex: 0 0 42px;
  border-radius: 50%;
  border: 1px solid #d4bd96;
  color: var(--bronze);
  background: #f4e8d2;
}

.topic-icon svg,
.topic-icon img { width: 60%; height: 60%; object-fit: contain; }
.ink .topic-icon { color: var(--gold); background: var(--ink-700); border-color: #826c4e; }

.today-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: clamp(12px, 2.35vw, 26px);
}

.panel { padding: clamp(16px, 3.2vw, 32px); }
.panel > :last-child { margin-block-end: 0; }

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  margin-block: 0 23px;
  list-style: none;
}

.pill,
.filter-pills a,
.filter-pills button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 5px 12px;
  border: 1px solid #cebda2;
  border-radius: 999px;
  color: var(--text);
  background: #fff9ec;
  font-size: 0.85rem;
  font-weight: 650;
  line-height: 1.35;
  text-decoration: none;
}

.filter-pills a,
.filter-pills button { min-height: 44px; }

.filter-pills a:hover,
.filter-pills button:hover,
.filter-pills [aria-current],
.filter-pills [aria-pressed="true"] {
  border-color: #56787a;
  background: #dcebe5;
  color: #163f43;
}

.ink .pill,
.ink .filter-pills a,
.ink .filter-pills button { background: var(--ink-700); border-color: var(--dark-line); color: var(--white); }

.ink .filter-pills [aria-current],
.ink .filter-pills [aria-pressed="true"] { color: var(--ink-950); background: var(--cyan); }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 7px;
  align-items: baseline;
  margin-block: clamp(15px, 3vw, 28px);
  color: var(--muted);
  font-size: 0.82rem;
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.breadcrumbs li + li::before { margin-inline-end: 8px; color: var(--bronze); content: "/"; }

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 780px) minmax(220px, 300px);
  justify-content: space-between;
  align-items: start;
  gap: clamp(24px, 5vw, 72px);
  padding-block: 15px clamp(38px, 7vw, 92px);
}

.article-main,
.article-side { min-width: 0; }

.article-main > h1,
.article-main header h1 { font-size: clamp(2.25rem, 5.25vw, 4.45rem); text-wrap: balance; }

.article-main > .lead,
.article-main header .lead { max-width: 64ch; color: var(--muted); }

.article-cover {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 8;
  margin-block: 22px clamp(23px, 4vw, 42px);
  overflow: hidden;
  border: 1px solid #7f6c52;
  border-radius: var(--radius);
  background: var(--ink-800);
  color: var(--gold);
  object-fit: cover;
}

.article-cover picture,
.article-cover img { width: 100%; height: 100%; object-fit: cover; }

.article-prose {
  max-width: 68ch;
  color: #242d38;
  font: 400 clamp(1.05rem, 2vw, 1.2rem)/1.77 var(--font-serif);
  overflow-wrap: anywhere;
}

.article-prose p,
.article-prose ul,
.article-prose ol,
.article-prose blockquote { margin-block-end: 1.15em; }

.article-prose h2 { font-size: clamp(1.52rem, 3vw, 2.6rem); }
.article-prose h3 { font-size: clamp(1.28rem, 2.5vw, 1.94rem); }
.article-prose h2,
.article-prose h3 { margin-block: 1.3em 0.55em; }

.article-prose li + li { margin-block-start: 0.35em; }
.article-prose ul, .article-prose ol { padding-inline-start: 1.35em; }

.article-prose blockquote {
  margin-inline: 0;
  padding: 12px 20px;
  border-inline-start: 3px solid #ac7840;
  background: #f0e4d3;
  color: var(--ink-800);
}

.article-prose blockquote > :last-child { margin-block-end: 0; }
.article-prose img { border-radius: 8px; }

.article-prose table {
  display: block;
  max-width: 100%;
  margin-block: 0 1.15em;
  overflow: auto;
  border-collapse: collapse;
  font: 400 0.94rem/1.45 var(--font-sans);
}

.article-prose th,
.article-prose td { min-width: 6em; padding: 8px 10px; border: 1px solid var(--line); text-align: start; }
.article-prose th { background: var(--paper-deep); }
.article-prose code { font-size: 0.87em; }
.article-side .panel + .panel { margin-block-start: 15px; }
.article-side h2 { font-size: 1.6rem; }
.article-side li + li { margin-block-start: 0.5em; }

.tool-form {
  display: grid;
  gap: 17px;
  max-width: 750px;
}

.tool-form.panel { max-width: none; }

.form-grid {
  display: grid;
  gap: 12px 15px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field,
.tool-form label {
  display: grid;
  align-content: start;
  gap: 5px;
  min-width: 0;
  color: var(--text);
  font-size: 0.88rem;
  font-weight: 650;
}

.tool-form input:not([type="checkbox"], [type="radio"]),
.tool-form select,
.tool-form textarea,
.search-form input {
  max-width: 100%;
  width: 100%;
  min-width: 0;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid #9d8a6f;
  border-radius: 7px;
  background: #fffcf5;
  color: var(--text);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.3;
}

.tool-form input[type="date"],
.tool-form input[type="time"] { min-inline-size: 0; }
.tool-form textarea { resize: vertical; }
.tool-form [aria-invalid="true"] { border-color: #a93532; }
.tool-form .btn { justify-self: start; }
.tool-form .notice { margin: 0; }
.form-note,
.muted { color: var(--muted); }
.form-note { font-size: 0.86rem; margin-block-end: 0; }
.ink .tool-form label,
.ink .field { color: var(--white); }

.tool-result {
  margin-block: 20px;
  padding: clamp(18px, 4vw, 34px);
  border: 1px solid #ad956d;
  border-radius: var(--radius);
  background: #fff8e9;
  box-shadow: inset 0 3px #ce9d5f;
}

.tool-result:empty { display: none; }
.tool-result > :last-child,
.result-cell > :last-child { margin-block-end: 0; }
.result-title { margin-block-end: 0.5em; }

.result-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.result-cell {
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid #d3c6b0;
  border-radius: 8px;
  background: var(--card);
  overflow-wrap: anywhere;
}

.notice {
  padding: 12px 15px;
  border-inline-start: 3px solid #6c938c;
  border-radius: 0 7px 7px 0;
  background: #e7eee4;
  color: #2d4642;
}

.notice > :last-child,
.empty-state > :last-child { margin-block-end: 0; }
.notice.error { border-color: #a93532; background: #fae6de; color: #721e1b; }

.empty-state {
  padding: clamp(20px, 5vw, 48px);
  border: 1px dashed #aa9578;
  border-radius: var(--radius);
  background: #fff8e9;
}

.search-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 660px;
  margin-block-end: 22px;
}

.search-form label { width: 100%; font-size: 0.9rem; font-weight: 650; }
.search-form input { flex: 1 1 210px; width: auto; }
.search-form > .btn { flex: 0 0 auto; }
.site-header .search-form { margin: 0; }
.site-header .search-form input { min-height: 40px; }
.pager { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-block-start: 26px; }

.pager a,
.pager [aria-current="page"] {
  min-width: 44px;
  min-height: 44px;
  display: inline-grid;
  place-items: center;
  padding: 0 9px;
  border: 1px solid #b7a17d;
  border-radius: 7px;
  color: var(--text);
  text-decoration: none;
}

.pager [aria-current="page"],
.pager a:hover { background: var(--ink-800); color: var(--white); }

.site-footer {
  min-width: 0;
  padding-block: clamp(31px, 5.7vw, 66px);
  border-top: 1px solid var(--dark-line);
  background: var(--ink-950);
  color: var(--dark-muted);
  font-size: 0.9rem;
}

.site-footer .site-shell {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px 25px;
}

.site-footer a:not(.brand) { color: var(--cyan); }
.site-footer .brand { color: var(--white); }
.site-footer p { margin-block-end: 0; }
.site-footer nav a { display: inline-flex; align-items: center; min-height: 40px; }

@media (max-width: 1050px) {
  .site-header .site-shell,
  .header-inner { flex-wrap: wrap; padding-block: 10px 4px; gap: 3px 14px; min-height: 0; }
  .site-header .top-nav { order: 3; flex-basis: 100%; justify-content: flex-start; }
  .top-nav ul { gap: 0 15px; }
  .top-nav a, .header-actions > a:not(.btn) { font-size: 0.85rem; }
}

@media (max-width: 780px) {
  .hero { min-height: 0; }
  .hero-copy { width: min(100%, 580px); padding-block: 48px 58px; }
  .hero-art { inset-inline-start: 16%; width: 84%; }
  .hero::before {
    background: linear-gradient(90deg, var(--ink-900) 0%, #101a2cf7 15%, #101a2cdd 36%, #101a2c71 76%, #101a2c2f);
  }
  .card-grid,
  .catalog-grid,
  .desk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-layout { grid-template-columns: minmax(0, 1fr); }
  .article-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .article-side .panel + .panel { margin-block-start: 0; }
}

@media (max-width: 540px) {
  .site-header .site-shell,
  .header-inner { padding-block: 9px 3px; }
  .site-header .top-nav {
    flex-wrap: wrap;
    gap: 0 13px;
    min-width: 0;
    border-top: 1px solid #50607745;
  }
  .top-nav ul { gap: 0 13px; }
  .top-nav a { min-height: 42px; font-size: 0.82rem; }
  .brand-mark, .brand > svg, .brand > img { width: 29px; height: 29px; flex-basis: 29px; }
  .header-actions .btn { max-width: 134px; }

  .hero {
    display: grid;
    align-items: end;
  }

  .hero-art {
    inset: 0 0 auto;
    width: 100%;
    height: clamp(182px, 62vw, 289px);
    object-position: 62% 50%;
  }

  .hero-art picture,
  .hero-art img { object-position: 62% 50%; }

  .hero::before {
    background: linear-gradient(180deg, #101a2c00 60px, #101a2c0a 110px, #101a2cb7 178px, var(--ink-900) 285px);
  }

  .hero-copy { padding-block: clamp(152px, 48vw, 229px) 34px; }
  .hero:not(:has(.hero-art)) .hero-copy { padding-block-start: 38px; }
  .hero-compact .hero-copy { padding-block-end: 31px; }
  .hero-copy h1 { max-width: 15ch; line-height: 1.03; }
  .hero .lead { font-size: 1.04rem; }
  .hero-actions { gap: 8px; margin-block-start: 19px; }
  .hero-actions .btn { min-height: 46px; flex: 1 1 155px; }
  .section-head { align-items: start; }
  .today-grid,
  .article-side { grid-template-columns: minmax(0, 1fr); }
  .result-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-cover { aspect-ratio: 16 / 9; }
}

@media (max-width: 410px) {
  .card-grid,
  .catalog-grid,
  .desk-grid,
  .form-grid { grid-template-columns: minmax(0, 1fr); }
  .feature-media { aspect-ratio: 16 / 7; }
  .panel .tool-form .btn { justify-self: stretch; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
.trust-strip { color: var(--muted); font-size: .82rem; line-height: 1.7; overflow-wrap: anywhere; }
.trust-strip--home { margin: 0 auto; padding-block: 1.1rem; }
.site-footer .trust-strip { max-width: 37rem; }
.methodology-shell { max-width: 48rem; margin-block: 2rem; }
.methodology-note { padding: clamp(1rem, 3vw, 1.6rem); border: 1px solid var(--line); border-radius: 12px; }
.methodology-note h2 { font-size: 1.15rem; margin: 0 0 .6rem; }
.methodology-note p { font-size: .9rem; line-height: 1.7; }
.methodology-note a { display: inline-flex; align-items: center; min-height: 44px; font-size: .85rem; }
.article-publication { color: var(--muted); font-size: .82rem; margin-block: .8rem; }

/* The daily reminder reserves its dot even when today's draw is complete. */
.site-header .top-nav .ritual-nav { padding-inline: 10px; border: 1px solid var(--line); border-radius: 8px; }
.ritual-nav::before { content: ''; width: 6px; height: 6px; margin-inline-end: 8px; flex: 0 0 6px; border-radius: 50%; background: var(--gold); opacity: 0; }
.ritual-nav[data-unread]::before { opacity: 1; }
#karta-dnya { scroll-margin-top: 12px; }

.ritual-result { margin-top: 20px; padding: 16px; border-top: 1px solid var(--line); }
.ritual-result p { font-size: .9rem; line-height: 1.6; max-width: 42rem; }
.ritual-result .btn { min-height: 44px; }

/* Static geometry: the decorative card and day digits never wait for an image. */
.ritual-invitation { max-width: 48rem; margin-block: 2rem; padding: 18px; display: grid; grid-template-columns: 42px minmax(0,1fr); gap: 18px; align-items: center; min-height: 130px; border: 1px solid var(--line); border-radius: 12px; }
.ritual-invitation p { font-size: .9rem; line-height: 1.6; margin: 0 0 12px; }
.ritual-invitation .btn { min-height: 44px; white-space: normal; }
.ritual-mini { width: 42px; height: 64px; display: grid; place-items: center; color: var(--gold); background: repeating-linear-gradient(45deg, #182237 0 4px, #10192a 4px 8px); border: 1px solid var(--gold); border-radius: 5px; transform: rotate(-5deg); }
[data-ritual-lunar] { display: inline-block; width: 2ch; text-align: right; font-variant-numeric: tabular-nums; }

@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: optional;
  src: url(/assets/fonts/manrope-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: optional;
  src: url(/assets/fonts/manrope-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Prata';
  font-style: normal;
  font-weight: 400;
  font-display: optional;
  src: url(/assets/fonts/prata-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Prata';
  font-style: normal;
  font-weight: 400;
  font-display: optional;
  src: url(/assets/fonts/prata-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --font-serif: "Prata", Georgia, "Times New Roman", serif;
  --font-sans: "Manrope", system-ui, sans-serif;
  --ink-950: #0b1222;
  --ink-900: #0e1728;
  --paper: #f8f3ea;
  --card: #fffaf2;
}
body { font-size: 0.985rem; }
.site-header .site-shell { flex-wrap: nowrap; min-height: 72px; }
.site-header .brand { gap: 8px; font-size: 1.66rem; letter-spacing: -.075em; }
.brand>span:nth-child(2) { margin-left: -8px; color: var(--gold-pale); }
.site-header .top-nav { order: 0; flex-basis: auto; justify-content: center; }
.top-nav a { font-size: .88rem; }
.small-nav-icon { display: flex !important; align-items: center; gap: .42rem; justify-content: center; min-width: 42px; min-height: 44px; border-radius: 6px; }
.small-nav-icon:hover { background: #99adcf14; }
.mobile-menu { display: none; }
.hero-home { min-height: clamp(545px,44vw,670px); background: #0b1222; }
.hero-home>.site-shell { position: relative; }
.hero-home .hero-copy { width: min(100%, 635px); }
.hero-home .hero-copy h1 { max-width: 12ch; text-wrap: initial; font-size: clamp(3.05rem,6.1vw,5.4rem); line-height: 1.11; letter-spacing: -.063em; }
.hero-home .hero-copy h1 em { font-style: normal; }
.hero-home .hero-copy .lead { color: #d7dee6; }
.hero-home .hero-art { inset: 0 0 0 25%; width: 75%; background: #0b1222; }
.hero-home .hero-art img { object-position: 66% 52%; }
.hero-home::before { display: none; }
.hero-vignette { position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(90deg,#0b1222 0%,#0b1222 18%,#0b1222f6 27%,#0b1222d8 37%,#0b122273 50%,transparent 67%),linear-gradient(0deg,#0b12227a,transparent 24%); }
.starfield { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; pointer-events: none; }
.hero-caption { position: absolute; inset: auto 1rem .9rem auto; color: #f1d2a7; font-size: .62rem; letter-spacing: .2em; white-space: nowrap; }
.hero-caption span { display: inline-block; width: 20px; height: 1px; margin-inline: .45rem; vertical-align: middle; background: currentColor; }
.hero-home .hero-actions { gap: 10px; }
.hero-home .hero-actions .primary { gap: 12px; }

.section-head h2 { line-height: 1.16; }
.topic-grid { display: grid; gap: 13px; grid-template-columns: repeat(3,minmax(0,1fr)); }
.topic-tile { display: flex; gap: .75em; align-items: center; min-height: 68px; padding: 10px 17px; background: var(--card); border-radius: 9px; border: 1px solid var(--line); color: var(--text); text-decoration: none; font-weight: 700; }
.topic-tile:hover { border-color: #a98d61; color: var(--teal); }
.topic-tile>:last-child { margin-left: auto; color: var(--teal); }
.topic-grid-compact .topic-tile { min-height: 51px; }
.today-home { grid-template-columns: repeat(3,minmax(0,1fr)); }
.today-grid .panel { display: flex; flex-direction: column; align-items: flex-start; }
.today-grid .panel>* { max-width: 100%; }
.today-grid .panel h3 { font-size: clamp(1.23rem,2vw,1.65rem); }
.today-grid .panel .eyebrow { margin-bottom: 0.7rem; }
.daily-card-panel { background: #101a2c; border-color:#25354c; color: var(--white); }
.daily-card-panel .eyebrow, .daily-card-panel .daily-card-number { color: var(--gold-pale); }
.daily-card-panel [data-daily-card] h3 { color: var(--gold-pale); }
.daily-card-panel [data-daily-card] p { color: #e0e3e7; }
.daily-card-panel .btn.secondary { border-color: #a38966; color: var(--gold-pale); }
.daily-card-panel .btn.secondary:hover { background: #344456; }
.daily-card-number { display: inline-block; font-variant-numeric: tabular-nums; font-size:.77rem; margin-bottom: 5px; }
.daily-card-reflection, [data-reflect-result] { margin-top: .65em; border-left: 2px solid #a28252; padding-left: .75em; }
.moon-panel { position: relative; }
.moon-panel .topic-icon { position:absolute; top: 12px; right: 12px; width: 34px; padding: 0; }
.moon-panel .topic-icon svg { margin: auto; }
.moon-panel a { margin-top: auto; padding-top: 9px; font-size: .78rem; }
.reflect-panel .filter-pills { row-gap: 6px; }
[data-reflect-result] { margin-bottom: .4rem; }
.utility-shell, .article-shell { padding-block: 25px clamp(45px,7vw,100px); }
.utility-heading { padding-block: clamp(28px,5.8vw,68px) clamp(17px,3.5vw,40px); }
.utility-heading h1 { max-width: 18ch; font-size: clamp(2.37rem,5.5vw,4.35rem); line-height: 1.15; }
.utility-heading .lead { max-width: 56ch; color: var(--muted); }
.utility-links { margin-top: 1.8rem; flex-wrap: wrap; }
.utility-copy { margin-top: 2.6rem; max-width: 72ch; }
.utility-note { margin: .65rem 0; font-size: .83rem; }
.daily-spread { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: clamp(12px,2vw,27px); }
.daily-spread .panel { min-height: 230px; }
.daily-art { position: relative; border-radius: var(--radius); min-height: 100%; overflow: hidden; background: var(--ink-900); }
.daily-art img { width: 100%; height: 100%; position:absolute; object-fit: cover; }
.text-card { padding-top: 15px; }
.text-card>.topic-icon { margin-inline-start: clamp(15px,2.5vw,25px); }
.text-card .feature-body { padding-top: 13px; }
.text-card h3 { font-size: clamp(1.05rem,1.55vw,1.47rem); line-height: 1.25; }
.archive-featured { margin: 0 0 3rem; }
.archive-shell>h2 { font-size: clamp(1.55rem,3vw,2.45rem); }
.more-topics-heading { margin-top: 3.4rem; }
.article-header h1 { letter-spacing: -.04em; line-height: 1.17; }
.article-action-row { display:flex; align-items:center; flex-wrap:wrap; gap: .8em; margin: 1rem 0; }
.reading-time { font-size:.85rem; color: var(--muted); }
.bookmark-button { display:inline-flex; align-items: center; gap:.4em; padding-inline: 12px; font-size:.84rem; }
.bookmark-button svg { width:18px; height:18px; }
.bookmark-button[aria-pressed=true] { background:#e8dfcf; color:var(--ink-900); }
.article-cover { aspect-ratio: 16/6.5; min-height: 0; }
.legacy-wrap+.article-cover, .clock-panel+.article-cover { margin-top: 1.4rem; }
.article-prose { overflow-wrap: anywhere; }
.article-gallery { display:flex; align-items:flex-start; flex-wrap:wrap; gap:12px; margin-bottom:1.25rem; }
.article-gallery figure { flex:1 1 210px; min-width:0; }
.article-gallery img { width:100%; max-height:350px; object-fit:cover; }
.calendar-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.calendar-grid section { background: var(--card); padding: 11px; border: 1px solid var(--line); border-radius: 8px; }
.calendar-grid section h3 { margin: .3rem 0 .7rem; }
.calendar-grid section ul { font-size:.83rem; padding:0; margin:0; list-style:none; }
.calendar-grid section li { display:grid; grid-template-columns: 9ch 1fr; gap:.4em; }
.calendar-grid section li span { color:var(--muted); white-space:nowrap; }
.site-footer .footer-links { gap: clamp(.5rem,1vw,1.4rem); flex-wrap:wrap; }
.site-footer p { margin-top:.5rem; }
[data-personal-result]:not([hidden]), [data-clock-result]:not([hidden]) { border-left: 2px solid #a98355; margin-top:1em; padding-left:.8em; }
.desk-summary,.desk-bookmarks,.desk-journal { border:1px solid var(--line); border-radius: 10px; background:var(--card); padding:clamp(13px,3vw,25px); margin-bottom:1rem; }
.desk-journal textarea { display:block; width:100%; padding:.6em; border:1px solid #ac9f8a; border-radius:7px; margin:.5em 0; }
.desk-confirmation { margin-top:.75rem; }
.search-items { margin: 1.7rem 0; padding-left:0; list-style:none; max-width:75ch; }
.search-items li { border-top:1px solid var(--line); padding:.8rem 0; }
.search-items li>a { font-size:1.05em; font-weight:700; }

@media(max-width:1020px) {
  .top-nav { gap: 10px; }
  .top-nav a { font-size: .81rem; }
  .desk-link span { display:none; }
}
@media(max-width:810px) {
  .site-header .site-shell { justify-content: space-between; min-height: 61px; }
  .site-header .top-nav { display:none; }
  .mobile-menu { display:block; margin-inline-start:.15rem; }
  .mobile-menu summary { font-size:.85rem; display:flex; min-height:44px; align-items:center; padding: 0 .65em; color: var(--white); border:1px solid #616878; border-radius:6px; cursor:pointer; }
  .mobile-menu summary::marker, .mobile-menu summary::-webkit-details-marker { display:none; }
  .mobile-menu[open] nav { position:absolute; z-index:5; top:100%; inset-inline:0; background:var(--ink-950); display:grid; padding: 12px var(--gutter) 22px; border-bottom:1px solid #69573d; box-shadow: 0 14px 25px #080d20a5; }
  .mobile-menu[open] nav a { min-height:44px; display:flex; align-items:center; color:var(--white); }
  .hero-home .hero-art { inset:0 0 0 16%; width:84%; }
  .hero-home .hero-copy h1 { font-size: clamp(3.1rem,8.5vw,4.7rem); }
  .hero-vignette { background:linear-gradient(90deg,#0b1222 0%,#0b1222f4 18%,#0b1222ce 36%,#0b12224d 68%,transparent 100%); }
  .today-home { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media(max-width:650px) {
  .hero-home { min-height:auto; align-items:end; }
  .hero-home .hero-copy { padding-block: clamp(203px,56vw,330px) 42px; }
  .hero-home .hero-copy h1 { font-size: clamp(2.8rem,10.7vw,4.15rem); margin-bottom:.45em; }
  .hero-home .hero-art, .hero-home .hero-art img { object-position: 78% 42%; }
  .hero-home .hero-art { inset: 0 0 auto; width:100%; height:clamp(245px,67vw,370px); }
  .hero-vignette { background: linear-gradient(0deg,#0b1222 0%,#0b1222 35%,#0b1222ed 50%,#0b122261 71%,transparent 91%); }
  .hero-home .hero-caption { display:none; }
  .hero-home .hero-actions .btn { font-size: .83rem; }
  .topic-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap:8px; }
  .topic-tile { padding: 8px; font-size: .82rem; gap: .45em; }
  .topic-tile .topic-icon { width:30px; flex-basis:30px; }
  .daily-spread { grid-template-columns:1fr; }
  .daily-spread .daily-art { min-height: 185px; }
  .today-home { grid-template-columns: 1fr; }
  .article-shell { padding-top:12px; }
}
@media(max-width:380px) {
  .site-header .brand { font-size:1.45rem; }
  .site-header .brand-mark { width:29px; flex-basis:29px; }
  .site-header .header-actions { gap:0; }
  .header-actions .desk-link { display:none !important; }
  .topic-grid { grid-template-columns:1fr; }
  .calendar-grid { grid-template-columns:1fr; }
}

@media(prefers-reduced-motion:reduce) {
  .hero-home,.hero-home *, .daily-card-panel, .daily-card-panel * { animation: none !important; transition: none !important; scroll-behavior:auto !important; }
}
.quick-calculation { margin-top:17px; padding:14px 19px; }
.quick-calculation summary { cursor:pointer; min-height:31px; font-weight:750; color:var(--teal); }
.quick-calculation[open] summary { margin-bottom:10px; }
.daily-card-panel [data-save-daily] { margin-top:.45rem; }
.daily-card-panel [data-card-content] { min-height:3.1rem; }
.daily-card-panel [data-card-content] h3 { line-height:1.23; margin-top:.2em; }
@media (prefers-reduced-motion:no-preference) {
  .daily-card-panel [data-card-content]:has(.daily-card-number) { animation: reading-in 340ms ease-out both; }
  @keyframes reading-in {
    from {opacity:0;translate:0 5px}
    to {opacity:1;translate:0 0}
  }
}
.palm-figure { display:grid; grid-template-columns:minmax(125px,.62fr) 1fr; align-items:center; gap:clamp(12px,4vw,40px); margin-block:18px; padding:clamp(12px,2.2vw,26px); background:var(--card); border:1px solid var(--line); border-radius:10px; }
.palm-figure svg { width:100%; max-height:260px; }
.palm-figure figcaption { font-size:.88rem; color:var(--muted); }
.palm-figure figcaption strong { display:block; margin-bottom:.55rem; color:var(--text); }
.palm-figure figcaption span { display:flex; align-items:center; gap:.55rem; }
.palm-figure figcaption p { margin:.7rem 0 0; }
.palm-key { width:16px; height:3px; border-radius:4px; }
.palm-zhizni { background:#805925; }.palm-golovy { background:#296b70; }.palm-serdtsa { background:#955150; }
.desk-journal button,[data-desk]>button,.desk-confirmation button { min-height:44px; border:1px solid #9f8867; border-radius:6px; background:#f1e5d2; color:var(--ink-900); padding:7px 13px; font-weight:700; }
.desk-confirmation button + button { margin-left:.6em; }
[data-personal-result] small { display:block; margin-bottom:.75rem; }
@media(max-width:500px) {
 .palm-figure { grid-template-columns:1fr; }
 .palm-figure svg { max-height:175px; }
}
.line-arrow { display:inline-grid; place-items:center; width:14px; height:14px; flex:0 0 14px; vertical-align:middle; }
.line-arrow svg { width:100%;height:100%; stroke-width:1.8; }
.hero-actions a .line-arrow { width:16px;height:16px;flex-basis:16px; }
@media(max-width:650px) { .hero-home .hero-actions .primary { gap: 7px; padding-inline: 10px; } }
@media(max-width:410px) { .hero-home .hero-actions .primary .line-arrow { display:none; } }
@media(hover:hover) and (pointer:fine) and (min-width:800px) and (prefers-reduced-motion:no-preference) {
  .hero-home .hero-art { transform:translate3d(var(--sky-x,0px),var(--sky-y,0px),0) scale(1.025); }
}

.more-menu { position: relative; }
.more-menu summary { cursor: pointer; white-space: nowrap; }
.more-menu > nav { position: absolute; right: 0; top: 2rem; z-index: 20; min-width: 230px; padding: 1rem; background: var(--card); border: 1px solid var(--line); border-radius: 12px; display: grid; gap: .8rem; }
.section-directory { padding-block: 2rem; }
.section-directory-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,230px),1fr)); gap: 1.5rem; }
.section-directory h3 { font-size: 1.1rem; }
.section-directory ul { padding-left: 1.1rem; font-size: .88rem; line-height: 1.65; }
.section-directory li { margin-bottom: .45rem; }
.playing-history li { display: flex; align-items: center; gap: .75rem; }
.playing-history img, .playing-reward-list img { width: 48px; height: 72px; object-fit: contain; }
@media(min-width:1100px) { .top-nav { gap: 1rem; font-size: .84rem; } .desk-link span { display:none; } }

/* AuraMagic Reaction feedback widget */
.aura-reaction {
  margin-top: 2rem;
  padding: 1.25rem 1.5rem;
  background: var(--card, #fff);
  border: 1px solid var(--line, #e2e8f0);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: .8rem;
}
.aura-reaction-heading {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text, #1a202c);
  margin: 0;
}
.aura-reaction-buttons {
  display: flex;
  gap: .6rem;
  flex-wrap: wrap;
}
.aura-reaction-btn {
  background: var(--bg, #f7fafc);
  border: 1px solid var(--line, #cbd5e0);
  color: var(--text, #2d3748);
  padding: .45rem 1.1rem;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all .2s ease;
  min-height: 38px;
}
.aura-reaction-btn:hover:not(:disabled) {
  border-color: #805925;
  color: #805925;
  transform: translateY(-1px);
}
.aura-reaction-btn.is-active {
  background: #805925;
  border-color: #805925;
  color: #ffffff;
}
.aura-reaction-result {
  font-size: .88rem;
  color: var(--muted, #718096);
  display: flex;
  align-items: center;
  gap: .4rem;
  min-height: 1.2rem;
}

:root {
  --ink-950: #241923;
  --ink-900: #332534;
  --ink-800: #493548;
  --ink-700: #62495d;
  --paper: #f8f2eb;
  --paper-deep: #f0e5dc;
  --card: #fffbf6;
  --text: #302430;
  --muted: #66545f;
  --line: #dfd2ce;
  --gold: #efbfa8;
  --gold-pale: #fae0d0;
  --bronze: #843f3b;
  --teal: #843f3b;
  --cyan: #f7cab4;
  --white: #fff1e9;
  --dark-muted: #ddc6c5;
  --dark-line: #6d505f;
  --radius: 14px;
  --shadow: 0 18px 60px #4b272218;
}
.site-header { background: var(--paper); color: var(--text); border-bottom-color: var(--line); }
.site-header .brand, .site-header .brand span, .site-header .header-actions a { color: var(--text); }
.site-header .brand-mark, .site-header .top-nav a[aria-current] { color: var(--bronze); }
.site-header .top-nav a { color: var(--muted); }
.site-header .top-nav a:hover, .site-header .top-nav a[aria-current] { border-bottom-color: currentColor; }
.site-header :focus-visible, :focus-visible { outline-color: var(--bronze); }
.site-header .mobile-menu summary { color: var(--text); border-color: var(--line); }
.site-header .mobile-menu nav a { color: var(--white); }
.section-head .eyebrow:empty { display: none; }
.site-footer { border-top: 1px solid var(--line); }
.edition-masthead { padding-block: clamp(25px, 4.5vw, 72px); }
.edition-layout { display: grid; align-items: center; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.15fr); gap: clamp(26px, 5.75vw, 94px); }
.edition-date { display: inline-flex; gap: 8px; align-items: center; margin-block-end: 20px; color: var(--bronze); font-size: .91rem; font-weight: 650; }
.edition-date svg { width: 19px; height: 19px; }
.edition-copy h1 { font-size: clamp(3rem, 7vw, 6.5rem); margin: 0; max-width: 10ch; line-height: .98; letter-spacing: -.055em; }
.edition-copy h1 em { color: var(--bronze); font-style: normal; }
.edition-lead { margin: 24px 0 0; max-width: 34ch; color: var(--muted); font-size: clamp(1.02rem, 1.6vw, 1.25rem); line-height: 1.55; }
.edition-home-preview { color: var(--bronze); margin: .7em 0 0; font-size: .95rem; font-weight: 650; }
.edition-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 22px; margin-block-start: 24px; }
.edition-actions .primary, .edition-note .primary, .edition-feature .primary { color: #fff7f4; background: #773c42; border-color: #773c42; border-radius: 8px; }
.edition-actions .primary:hover, .edition-note .primary:hover, .edition-feature .primary:hover { background: #602d35; border-color: #602d35; }
.edition-secondary { font-weight: 650; color: var(--bronze); }
.edition-scene { position: relative; aspect-ratio: 1.18; border-radius: 5px 36px 5px 36px; overflow: hidden; isolation: isolate; background: #2c1d30; box-shadow: var(--shadow); min-width: 0; }
.edition-scene picture, .edition-scene .starfield { position: absolute; inset: 0; width: 100%; height: 100%; }
.edition-scene picture { transform: translate3d(var(--sky-x, 0px), var(--sky-y, 0px), 0) scale(1.045); }
.edition-scene img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.edition-scene .starfield { pointer-events: none; opacity: .7; mix-blend-mode: screen; }
.edition-plate { position: absolute; display: grid; grid-template-columns: 1fr auto; gap: 3px 17px; align-items: center; inset: auto clamp(12px, 3vw, 27px) clamp(12px, 3vw, 27px); padding: 12px 15px; border: 1px solid #d7b8a67f; border-radius: 5px 13px 5px 13px; text-decoration: none; color: var(--white); background: #211622e8; }
.edition-plate > span:first-child { color: var(--gold-pale); font-size: .76rem; font-weight: 650; }
.edition-plate strong { grid-column: 1; font-weight: 620; font-size: clamp(.96rem, 1.65vw, 1.2rem); line-height: 1.28; }
.edition-plate-arrow { grid-column: 2; grid-row: 1 / span 2; width: 26px; }
.entries-section { padding-block-start: clamp(22px, 4vw, 42px); }
.entry-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.entry-point { display: grid; align-items: start; grid-template-columns: 32px 1fr 20px; gap: 10px; padding: clamp(14px,2vw,24px); border: 1px solid var(--line); background: var(--card); border-radius: 10px; color: var(--text); text-decoration: none; }
.entry-point:hover { border-color: #b57b72; background: #fff7ed; }
.entry-point h3 { font-size: clamp(1.08rem, 1.6vw, 1.48rem); margin: 0 0 5px; }
.entry-point p { font-size: .92rem; line-height: 1.45; margin: 0; color: var(--muted); }
.entry-icon, .entry-arrow { color: var(--bronze); }
.edition-inside { padding-block: clamp(18px, 3.15vw, 40px) 16px; }
.edition-inside .edition-layout { grid-template-columns: minmax(0, 1.4fr) minmax(0, .8fr); }
.edition-inside .edition-copy h1 { font-size: clamp(2.5rem, 5vw, 4.1rem); max-width: 18ch; }
.edition-inside .edition-date { margin-bottom: 9px; }
.edition-inside .edition-lead { margin-top: 10px; max-width: 53ch; }
.edition-inside .edition-scene { max-height: 152px; aspect-ratio: 2.5; }
.edition-content { padding-bottom: clamp(45px, 7vw, 100px); }
.edition-toolbar, .edition-days, .edition-diary-link, .edition-note-actions { display: flex; align-items: center; gap: 9px; }
.edition-toolbar { justify-content: space-between; border-block: 1px solid var(--line); padding-block: 10px; }
.edition-day-button { display: inline-grid; place-items: center; min-width: 42px; min-height: 40px; border: 1px solid var(--line); border-radius: 7px; background: var(--card); color: var(--text); }
.edition-day-button:hover:enabled { border-color: var(--bronze); }
.edition-day-button:disabled { opacity: .38; cursor: default; }
.edition-day-button svg, .edition-diary-link svg { width: 19px; height: 19px; }
.edition-day-today { padding-inline: 13px; font-weight: 620; }
.edition-diary-link, .edition-recent-link { color: var(--bronze); font-weight: 620; }
.edition-recent-link { padding: 8px 3px; }
.edition-resume { margin: 13px 0 0; font-size: .94rem; color: var(--muted); }
.edition-topic { margin-block: clamp(16px, 2.8vw, 32px) 17px; }
.edition-kicker { color: var(--bronze); font-size: .81rem; font-weight: 650; }
.edition-topic h2 { margin: 6px 0 9px; line-height: 1.03; }
.edition-topic p { max-width: 56ch; color: var(--muted); }
.edition-topic .topic-lead { display: block; color: var(--text); margin-block-end: 3px; }
.edition-board, .edition-bottom { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .78fr); gap: clamp(14px, 2.1vw, 30px); }
.edition-board { align-items: start; }
.edition-feature { grid-column: 1; grid-row: 1; align-self: stretch; }
.edition-practice { grid-column: 2; grid-row: 1; }
.edition-note { grid-column: 1; grid-row: 2 / span 2; }
.edition-moon { grid-column: 2; grid-row: 2; }
.edition-reading { grid-column: 2; grid-row: 3; }
.edition-feature, .edition-note, .edition-practice, .edition-reading, .edition-tomorrow, .edition-recent { border-radius: 12px; padding: clamp(16px, 2.65vw, 32px); }
.edition-feature { background: #382638; color: var(--white); border: 1px solid #5e4052; }
.edition-feature .edition-kicker, .edition-feature .daily-card-reflection { color: #f4c9b8; }
.edition-feature .daily-card-panel { background: none; border: 0; padding: 0; color: var(--white); }
.edition-feature .daily-card-panel .btn.secondary { color: var(--white); border-color: #bd958f; }
.edition-feature .topic-icon, .edition-feature :focus-visible { outline-color: var(--gold-pale); }
.edition-feature h3, .edition-note h3, .edition-practice h3 { margin: 5px 0 12px; }
.edition-practice { background: #f1e4d8; border: 1px solid #decdc0; }
.edition-practice p { margin-bottom: .85em; }
.edition-check, .edition-quiet { padding: 8px 11px; min-height: 38px; border: 1px solid #bb8d7f; color: var(--bronze); border-radius: 6px; background: var(--card); font-weight: 620; }
.edition-check[aria-pressed="true"] { background: #f4d5c1; color: #643936; }
.edition-quiet { border-color: transparent; background: none; text-decoration: underline; }
.edition-note, .edition-reading, .edition-recent { background: var(--card); border: 1px solid var(--line); }
.edition-note-title { display: flex; align-items: start; gap: 10px; }
.edition-note-title > span { color: var(--bronze); width: 28px; flex: none; }
.edition-note label { display: block; font-weight: 620; }
.edition-note textarea { width: 100%; min-height: 85px; margin: 4px 0 9px; padding: 9px 11px; border-radius: 6px; border: 1px solid #bdaba7; color: var(--text); background: #fffdfa; resize: vertical; }
.edition-note-actions { flex-wrap: wrap; }
.edition-form-status { margin: 5px 0 0; color: var(--muted); }
.edition-form-status:empty { display: none; }
.edition-moon .panel { border: 1px solid var(--line); background: var(--card); padding: clamp(16px, 2.5vw, 26px); }
.edition-moon .topic-icon, .edition-moon .eyebrow { display: none; }
.edition-moon h3 { font-size: 1.35rem; margin-bottom: 8px; }
.edition-moon p { margin-bottom: 6px; font-size: .92rem; }
.edition-moon a { font-size: .86rem; }
.edition-reading a { display: block; margin-top: 4px; font-weight: 650; }
.edition-bottom { margin-top: 18px; }
.edition-teaser { border-top: 1px solid var(--line); margin-top: 18px; padding-top: 13px; }
.edition-teaser .edition-kicker { display: flex; gap: 6px; align-items: center; }
.edition-teaser .edition-kicker svg { width: 17px; }
.edition-teaser h4 { margin: 7px 0 3px; font-size: 1.16rem; }
.edition-teaser p { margin: 0; color: var(--muted); }
.edition-recent { grid-column: 1 / -1; }
.edition-recent h3 { scroll-margin-top: 5rem; }
.edition-recent ol { list-style: none; margin: 0; padding: 0; }
.edition-recent li + li { border-top: 1px solid var(--line); }
.edition-recent a, .desk-editions a { display: flex; gap: 8px; justify-content: space-between; padding-block: 6px; color: var(--bronze); }
.edition-recent a span { color: var(--muted); font-size: .85rem; }
.arcana-marker { display: grid; width: 64px; aspect-ratio: .72; border: 1px solid #f4c8b2; border-radius: 5px; margin: 10px 0 12px; place-items: center; color: #f4c8b2; background: radial-gradient(ellipse, #b641642c, transparent 74%), #261a2a; }
.arcana-marker::before { content: '✧'; box-shadow: inset 0 0 0 1px #f0c2b375; border-radius: 50%; width: 38px; height: 52px; display: grid; place-items: center; font-size: 25px; }
.arcana-open { animation: turn-card 420ms cubic-bezier(.2,.8,.3,1) both; }
@keyframes turn-card { from { opacity: .6; transform: translateY(5px) rotateY(-42deg); } to { opacity: 1; transform: none; } }
.daily-callout { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px 16px; border: 1px solid var(--line); padding: 12px 16px; border-left: 4px solid #ab635f; background: #f5e8de; }
.daily-callout strong { color: var(--text); }
.desk-editions { margin-block: 18px; padding: 15px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); }
.desk-editions article + article { border-top: 1px solid var(--line); margin-top: 8px; }
.desk-editions p { white-space: pre-wrap; overflow-wrap: anywhere; }
@media (max-width: 880px) {
  .entry-grid { grid-template-columns: 1fr; }
  .entry-point { align-items: center; }
}
@media (max-width: 670px) {
  .edition-masthead { padding-block: 23px 17px; }
  .edition-layout, .edition-inside .edition-layout { grid-template-columns: 1fr; gap: 18px; }
  .edition-copy h1 { font-size: clamp(2.83rem,12.5vw,4.25rem); max-width: 11ch; }
  .edition-lead { margin-top: 12px; }
  .edition-date { margin-block-end: 10px; }
  .edition-actions { margin-block-start: 13px; }
  .edition-home .edition-scene { aspect-ratio: 1.65; }
  .edition-inside .edition-scene { display: none; }
  .edition-board, .edition-bottom { grid-template-columns: minmax(0,1fr); }
  .edition-board > * { grid-column: 1; grid-row: auto; }
  .edition-copy h1 em { white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) {
  .arcana-open { animation: none; }
  .edition-scene picture { transform: none; }
}
@media (max-width: 370px) {
  .edition-toolbar { flex-wrap: wrap; }
  .edition-diary-link svg { display: none; }
}
.library-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
.library-card h2 { font-size: clamp(1.45rem,3vw,2.1rem); margin: 8px 0; }
.library-card p { color: var(--muted); }
.library-links { display: flex; flex-wrap: wrap; gap: 7px 16px; font-weight: 620; }
@media (max-width: 630px) { .library-grid { grid-template-columns: 1fr; } }

:root {
  --gold: #d8b783;
  --gold-pale: #efcf9a;
  --cyan: #bdc9d8;
  --white: #f6eee0;
  --ink-950: #0c1121;
  --ink-900: #141c2e;
  --ink-800: #1d2940;
  --ink-700: #2a364e;
  --dark-muted: #bdc3d1;
  --dark-line: #414a60;
}

:root:not([data-theme="light"]) {
  color-scheme: dark;
  --paper: #0d1221;
  --paper-deep: #101727;
  --card: #151e31;
  --text: #f4eddf;
  --muted: #b5bbcb;
  --line: #343d52;
  --bronze: #d8b783;
  --teal: #dfc396;
  --shadow: 0 18px 54px #04071038;
}

:root[data-theme="light"] {
  color-scheme: light;
  --paper: #f8f2e8;
  --paper-deep: #eee3d4;
  --card: #fffaf2;
  --text: #252438;
  --muted: #5e5864;
  --line: #ded1bf;
  --bronze: #7b521d;
  --teal: #765020;
}

.site-header .site-shell { min-height: 70px; gap: 24px; }
.site-header .brand { flex: 0 0 auto; }
.site-header .brand-mark { color: var(--bronze); }
.site-header .brand span:last-child { color: var(--bronze); }
.site-header .top-nav { gap: clamp(14px, 2vw, 33px); }
.site-header .top-nav a { padding-inline: 0; }
.header-actions { gap: 4px; }
.theme-toggle { border: 0; color: var(--bronze); background: transparent; }
.theme-toggle svg, .header-actions .small-nav-icon svg { width: 21px; height: 21px; }
[data-theme-moon], [data-theme="light"] [data-theme-sun] { display: none; }
[data-theme="light"] [data-theme-moon] { display: block; }
.night-hero {
  --sky-warm: #e6c895;
  --sky-cool: #aebcde;
  --sky-lines: #bba580;
  --sky-meteor: #ffe1a4;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: #f6efe2;
  background: radial-gradient(ellipse at 74% 42%, #1a253d 0, #101729 41%, #0d1324 72%);
  border-bottom: 1px solid #2b3449;
}

.night-hero-art {
  position: absolute;
  z-index: 1;
  top: -24px;
  left: clamp(260px, 31vw, 540px);
  width: min(50vw, 660px);
  pointer-events: none;
  opacity: 0.88;
}
.night-hero-art img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  mix-blend-mode: screen;
  mask-image: radial-gradient(ellipse at 50% 50%, #000 35%, #000b 58%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 50%, #000 35%, #000b 58%, transparent 78%);
}
.night-hero::after {
  position: absolute;
  z-index: 0;
  inset: 0;
  pointer-events: none;
  content: "";
  background: linear-gradient(90deg, #0c1224f0 0%, #0c1224c0 28%, #0c122450 48%, transparent 68%), linear-gradient(0deg, #0d1324cc 0%, transparent 28%);
}
.night-hero .starfield { z-index: 0; opacity: 0.86; }
.night-orbit {
  position: absolute;
  z-index: 0;
  top: 50%;
  left: clamp(260px, 31vw, 540px);
  width: min(42vw, 560px);
  aspect-ratio: 1;
  border-radius: 50%;
  border: 1px solid #d8b78324;
  transform: translate(-10%, -50%);
  animation: orbit-turn 200s linear infinite;
  background: repeating-conic-gradient(from 1.5deg, #d8b78355 0deg .21deg, transparent .21deg 10deg);
  mask: radial-gradient(circle, transparent 68%, #000 68.3%);
  -webkit-mask: radial-gradient(circle, transparent 68%, #000 68.3%);
}
@keyframes orbit-turn { to { transform: translate(-10%, -50%) rotate(360deg); } }
.night-hero:not([data-orbit-visible]) .night-orbit { animation-play-state: paused; }

.night-hero-content {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.95fr);
  gap: clamp(28px, 4vw, 58px);
  min-height: 510px;
  align-items: center;
  padding-block: 44px 44px;
}
.night-hero-content:has(.night-return:not([hidden])) { min-height: min(380px, 50vh); }
.night-intro { width: 100%; max-width: 520px; }
.night-hero-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-block-end: 18px;
}
.night-moon-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 14px 5px 8px;
  background: rgba(18, 25, 41, 0.88);
  border: 1px solid rgba(216, 183, 131, 0.35);
  border-radius: 999px;
  color: #e6c895;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.night-moon-badge:hover {
  border-color: rgba(216, 183, 131, 0.65);
  box-shadow: 0 4px 20px rgba(216, 183, 131, 0.15);
}
.night-moon-badge-disk {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
}
.night-moon-badge-disk svg {
  width: 24px;
  height: 24px;
}
.night-moon-badge-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
  text-align: left;
}
.night-moon-badge-phase {
  font-weight: 650;
  font-size: 0.82rem;
  color: #f5eedf;
}
.night-moon-badge-day {
  font-size: 0.73rem;
  color: #c4a471;
}

.night-hero-deck {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}
.night-hero-deck .morning-card {
  width: 100%;
  max-width: 440px;
  background: rgba(13, 20, 36, 0.92);
  border: 1px solid rgba(216, 183, 131, 0.35);
  border-radius: 20px;
  padding: clamp(20px, 2.5vw, 28px);
  box-shadow: 0 20px 50px rgba(3, 6, 14, 0.72), 0 0 28px rgba(216, 183, 131, 0.14);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.night-hero-deck .morning-card:hover {
  border-color: rgba(216, 183, 131, 0.65);
  box-shadow: 0 24px 60px rgba(3, 6, 14, 0.82), 0 0 38px rgba(216, 183, 131, 0.22);
}
.night-hero-deck [data-playing-card] {
  cursor: pointer;
  touch-action: manipulation;
}
.night-hero-deck .playing-card-surface {
  box-shadow: 0 4px 0 #9f8867, 0 8px 0 #182236, 0 12px 0 #9f8867, 0 20px 40px rgba(0,0,0,0.65);
  border-radius: 12px;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.35s ease;
}
.night-hero-deck .playing-card-surface:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 6px 0 #9f8867, 0 11px 0 #182236, 0 16px 0 #9f8867, 0 26px 50px rgba(216, 183, 131, 0.28);
}
@media (max-width: 960px) {
  .night-hero-content {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-block: 28px 36px;
  }
  .night-hero-art {
    display: none;
  }
  .night-orbit {
    display: none;
  }
  .night-hero-deck {
    order: 0;
    max-width: 420px;
    margin-inline: auto;
  }
}
.night-date { display: flex; align-items: center; gap: 9px; color: #dfbf8b; margin-block: 0 19px; font-size: .83rem; font-weight: 750; }
.night-date svg { width: 21px; height: 21px; }
.night-hero h1 { margin: 0; font-size: clamp(3.95rem, 7.05vw, 6.1rem); line-height: 1.05; white-space: nowrap; letter-spacing: -.062em; }
.night-hero h1 em { font-style: normal; color: #e6c79a; }
.night-lead { margin: 17px 0 27px; color: #d3d7e0; max-width: 36ch; font-size: clamp(1.03rem, 1.35vw, 1.19rem); line-height: 1.58; }
.night-form-text { font-weight: 700; font-size: .88rem; margin-block-end: 9px; }
.night-private { margin: 8px 0 0; color: #bcc2d2; font-size: .76rem; }
.night-form { width: min(100%, 424px); }
.night-form .legacy-wrap { margin: 0; }
.night-form .calc[data-calc="home"] { color: #f6efe2; }
.night-form .calc-form label { color: #f6efe2; }
.night-form .calc-form input[type=date] { background: #131c30; color: #f6efe2; border-color: #525e75; color-scheme: dark; }
.night-return { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.btn.primary, .calc .calc-form .btn, .edition-feature .primary, .edition-note .primary {
  border-color: #d8b783; border-radius: 8px; color: #231b12; background: #d8b783;
}
.btn.primary:hover, .calc .calc-form .btn:hover, .edition-feature .primary:hover, .edition-note .primary:hover { background: #e7c997; border-color: #e7c997; }
.btn.secondary { border-color: var(--line); color: var(--teal); }
.quiet-button { min-height: 42px; color: #e6c79a; border: 0; background: transparent; text-decoration: underline; text-underline-offset: 4px; }

.morning-content { padding-block: 30px 60px; }
.morning-section { margin-block-end: clamp(32px, 4.65vw, 68px); }
.morning-heading { display: flex; align-items: baseline; gap: 12px 20px; flex-wrap: wrap; margin: 0 0 17px; }
.morning-heading h2 { margin: 0 auto 0 0; font-size: clamp(1.9rem, 3.15vw, 3.17rem); }
.morning-heading > a, .morning-heading > p { font-size: .84rem; margin: 0; }
.morning-grid { display: grid; grid-template-columns: 1.37fr 1.11fr .74fr; gap: 14px; }
.morning-grid .panel, .morning-bottom .panel { min-width: 0; min-height: 231px; padding: clamp(15px, 1.75vw, 25px); box-shadow: none; }
.morning-grid .panel h3 { margin: 0 0 9px; font-size: clamp(1.3rem, 1.75vw, 1.69rem); }
.morning-icon { width: 32px; height: 32px; margin: 0 0 12px; padding: 5px; color: var(--bronze); border-radius: 100%; border: 1px solid color-mix(in srgb, var(--bronze) 44%, transparent); }
.morning-card { position: relative; display: grid; align-items: center; grid-template-columns: minmax(0, 1fr) minmax(85px, 36%); gap: 8px; }
.morning-card-intro { min-width: 0; }
.morning-card-intro .muted { margin: 0 0 12px; font-size: .84rem; }
.morning-card-intro [data-playing-status]:empty { display: none; }
.morning-card-intro [data-playing-share]:not([hidden]) { margin-block-start: 7px; }
.morning-card-intro [data-playing-summary] { margin-block-end: 6px; }
.morning-card [data-playing-card] { min-width: 0; }
.morning-card [data-playing-card] .playing-card { max-width: 143px; margin-inline: auto; }
.morning-sub-link { display: block; width: fit-content; font-size: .8rem; margin-block-start: 10px; color: var(--teal); }
.morning-number-value { margin: 0 0 4px; font: 400 clamp(2.55rem, 4.28vw, 4rem)/1 var(--font-serif); color: var(--bronze); }
.morning-number .muted { margin-block: 0 8px; font-size: .83rem; }
.moon-panel { background: var(--card); color: var(--text); }
.lunar-current { display: flex; align-items: center; gap: 11px; margin-block: 4px 8px; }
.lunar-current p, .lunar-sky p { margin: 0; font-size: .83rem; }
.lunar-disk { width: 54px; min-width: 54px; height: 54px; --moon-screen: #182035; --moon-night: #24334f; --moon-light: #dabc89; }
.lunar-name { color: var(--bronze); font-weight: 800; }
.lunar-next, .lunar-time-note, .lunar-method { color: var(--muted); font-size: .73rem; }
.morning-grid .lunar-time-note, .morning-grid .lunar-method { display: none; }
.lunar-sky-facts { font-weight: 750; }
.lunar-guidance { margin-block-start: 5px !important; }
.lunar-disk { animation: moon-in 650ms cubic-bezier(.22,.75,.23,1) both; }
@keyframes moon-in { from { opacity: 0; scale: .92; } to { opacity: 1; scale: 1; } }

.home-personal-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.home-personal-card { min-width: 0; border: 1px solid var(--line); border-radius: 12px; background: var(--card); padding: 15px 18px; color: var(--text); text-decoration: none; }
.home-personal-label, .home-personal-value { display: block; }
.home-personal-label { font-size: .78rem; color: var(--muted); }
.home-personal-value { color: var(--bronze); font-size: 1rem; margin-block-start: 4px; overflow-wrap: anywhere; }
.home-personal-card:hover, .home-feed-article:hover, .journey-links a:hover { border-color: var(--bronze); }
.morning-biorhythm-panel { padding: 17px 21px; }
.morning-biorhythm-panel ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px 22px; }
.morning-power { display: flex; align-items: center; gap: 7px; margin: 0 0 12px; color: var(--bronze); font-size: .87rem; }
.morning-power svg { width: 18px; height: 18px; }
.morning-cycle { display: grid; grid-template-columns: 1fr auto; gap: 5px 8px; align-items: baseline; font-size: .85rem; }
.morning-cycle-value { color: var(--bronze); font-variant-numeric: tabular-nums; }
.morning-cycle-gauge { grid-column: 1 / -1; position: relative; display: block; height: 6px; border-radius: 4px; background: var(--line); }
.morning-cycle-gauge::after { position: absolute; top: -2px; bottom: -2px; left: 50%; width: 1px; background: var(--muted); content: ""; }
.morning-cycle-fill { position: absolute; inset-block: 0; left: 50%; width: var(--cycle-width); border-radius: 4px; background: var(--bronze); }
.morning-cycle-fill[data-direction="negative"] { left: auto; right: 50%; background: var(--muted); }

.home-articles { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.home-feed-article { position: relative; display: grid; align-items: center; grid-template-columns: minmax(82px, 39%) minmax(0, 1fr); min-height: 119px; overflow: hidden; text-decoration: none; color: var(--text); background: var(--card); border: 1px solid var(--line); border-radius: 12px; }
.home-feed-article img { width: 100%; height: auto; aspect-ratio: auto; object-fit: contain; }
.home-feed-article-title { display: block; padding: 12px 14px; font-size: clamp(.9rem, 1.25vw, 1.15rem); line-height: 1.43; }
.home-feed-article:first-child .home-feed-article-title::before { display: block; content: "Статья дня"; color: var(--bronze); margin-block-end: 5px; font-size: .7rem; font-weight: 800; }
.morning-bottom { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); margin-block-end: 26px; gap: 14px; }
.morning-bottom .panel { min-height: 0; }
.morning-bottom h2 { margin-block-end: 8px; font-size: clamp(1.26rem, 1.82vw, 1.8rem); }
.morning-bottom p:not(.morning-icon) { margin: 0 0 6px; color: var(--muted); font-size: .89rem; }
.morning-bottom a { font-size: .85rem; }
.morning-bottom .mirror-short { margin-block-start: 11px !important; }
.morning-people { margin-block-end: 0; }
[data-playing-status] { font-size: .84rem; }

.article-main .article-header h1 { max-width: 24ch; font-size: clamp(1.95rem, 4.35vw, 3.65rem); line-height: 1.13; margin-block-end: .36em; }
.article-header .lead { margin-block: 0 18px; }
.article-header + .legacy-wrap { margin-block-start: 0; }
.article-side { align-self: start; }
.article-prose { color: var(--text); }
.article-prose :is(th, tr:nth-child(even) td) { background: var(--paper-deep); color: var(--text); }
.article-prose :is(table, th, td) { border-color: var(--line); }
.article-prose table { display: block; overflow-x: auto; max-width: 100%; }
.article-prose img { border-radius: 10px; }
.article-action-row { margin-block: 12px; }
.article-main > .journey-start { margin-block: 15px; }
.playing-article-cover { display: grid; place-items: center; aspect-ratio: 2.7; overflow: hidden; border-radius: 14px; border: 1px solid #374059; color: #e4c392; background: radial-gradient(ellipse at 52% 56%, #232c43 0, #101828 69%); }
.playing-article-cover strong { font: 400 clamp(2rem, 8vw, 5rem)/1 var(--font-serif); }
.playing-hub-suits { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.playing-hub-suits details { min-width: 0; padding: 11px; border: 1px solid var(--line); border-radius: 8px; }
.playing-hub-suits summary { cursor: pointer; color: var(--bronze); }
.playing-hub-suits ul { padding-inline-start: 18px; }
.personal-section .quiet-button { color: var(--bronze); }
.journey-start, .journey-end, .journey-hub { min-width: 0; margin: 18px 0 25px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); padding: 15px 18px; }
.journey-start h2, .journey-end h2, .journey-hub h2 { font-size: 1.43rem; margin-bottom: 9px; }
.journey-start a { font-weight: 750; }
.journey-links { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; list-style: none; }
.journey-links a { display: inline-block; max-width: 100%; padding: 7px 10px; border: 1px solid var(--line); border-radius: 5px; text-decoration: none; font-size: .84rem; }
.preserved-links { font-size: .84rem; color: var(--muted); margin-block: 13px 0; }
.preserved-links summary { cursor: pointer; }
.preserved-links ul { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,220px),1fr)); gap: 3px 12px; margin-block-start: 8px; }
.preserved-links-shell { padding-block-end: 20px; }
.site-footer .preserved-links a { color: #d2c6b7; }
:root:not([data-theme="light"]) .search-form input, :root:not([data-theme="light"]) .tool-form input,
:root:not([data-theme="light"]) .calc .calc-form input, :root:not([data-theme="light"]) .calc .calc-form select { color: var(--text); background: #131c30; border-color: #556076; }
:root:not([data-theme="light"]) .calc .calc-form { background: transparent; border-color: var(--line); }
:root:not([data-theme="light"]) .calc :is(table, th, td, .calc-card, .calc-mini, .calc-result-card, .hint, .block) { background: var(--paper-deep); color: var(--text); border-color: var(--line); }
:root:not([data-theme="light"]) .calc :is(.res-card, .res-card.muted) { background: var(--card); color: var(--text); border-color: var(--line); border-block-start-color: var(--bronze); }
:root:not([data-theme="light"]) .calc .res-title { color: var(--text); }
:root:not([data-theme="light"]) .calc .steps { background: var(--paper-deep); border-color: var(--bronze); }
:root[data-theme="light"] .calc .res-title { color: var(--text); }
:root:not([data-theme="light"]) .calc .meta, :root:not([data-theme="light"]) .calc .note { color: var(--muted); }
:root:not([data-theme="light"]) .bookmark-button[aria-pressed=true] { color: #231b12; }
:root:not([data-theme="light"]) .skip-link { color: var(--text); }
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .17s; }

@media (max-width: 1050px) {
  .night-hero-art { width: 67vw; right: -12vw; }
  .morning-grid { grid-template-columns: 1.27fr 1fr .74fr; gap: 10px; }
}

@media (max-width: 800px) {
  .site-header .site-shell { min-height: 61px; gap: 10px; }
  .site-header .brand { font-size: 1.46rem; }
  .site-header .desk-link { display: none !important; }
  .morning-grid { grid-template-columns: 1.15fr 1fr; }
  .morning-number { grid-column: 1/-1; }
  .morning-grid .morning-number { min-height: 0; }
  .morning-number .morning-icon { display: none; }
  .home-articles, .morning-bottom { grid-template-columns: minmax(0,1fr); }
  .home-feed-article { grid-template-columns: 93px minmax(0,1fr); min-height: 78px; }
  .home-feed-article img { height: 100%; }
}

@media (max-width: 620px) {
  .night-hero-content, .night-hero-content:has(.night-return:not([hidden])) { min-height: 0; padding-block: 38px 29px; }
  .night-hero-art { width: min(76vw, 360px); height: 229px; right: -36px; top: -19px; bottom: auto; mask-image: radial-gradient(ellipse at 64% 49%, #000e 32%, #0009 48%, transparent 69%); }
  .night-hero-art img { object-position: center; mask-image: none; }
  .night-hero::after { background: linear-gradient(90deg, #0c1224f4 0%, #0c122481 37%, transparent 77%), linear-gradient(0deg, #0d1324 10%, transparent 65%); }
  .night-orbit { display: none; }
  .night-date { margin-block-end: 12px; font-size: .76rem; }
  .night-hero h1 { font-size: clamp(2.66rem, 12vw, 4.2rem); }
  .night-lead { margin-block: 10px 18px; max-width: 28ch; font-size: .98rem; }
  .night-form-text { font-size: .79rem; margin-block-end: 7px; }
  .night-form .calc .home-calc-form { grid-template-columns: minmax(0, 1fr) auto; gap: 7px; }
  .night-form .calc .home-calc-form input { min-height: 45px; padding-inline: 7px; font-size: .9rem; }
  .night-form .calc .home-calc-form button.btn { width: auto; min-height: 45px; font-size: .82rem; padding-inline: 12px; }
  .morning-content { padding-block-start: 22px; }
  .morning-grid { grid-template-columns: minmax(0,1fr); }
  .morning-grid .panel { min-height: 0; }
  .morning-card { grid-template-columns: minmax(0,1fr) minmax(90px, 35%); }
  .morning-card [data-playing-card] .playing-card { max-width: 112px; }
  .home-personal-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; }
  .home-personal-card { padding: 9px 12px; }
  .home-personal-value { font-size: .88rem; }
  .morning-section { margin-block-end: 29px; }
  .morning-heading { margin-block-end: 12px; }
  .morning-biorhythm-panel ul { grid-template-columns: 1fr; }
  .playing-hub-suits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  .night-orbit, .lunar-disk, ::view-transition-old(root), ::view-transition-new(root) { animation: none; }
}

/* Wave 1: compact first screen and isolated celestial/deck zones. */
.profile-menu { position: relative; font-size: .75rem; flex: 0 0 auto; }
.profile-menu summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--bronze); }
.profile-popover { position: absolute; right: 0; top: 100%; width: min(310px, 88vw); padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; z-index: 50; }
.profile-popover input { display: block; width: 100%; min-width: 0; }
.profile-popover button { min-height: 44px; margin-block: 6px; }
.night-hero-art { left: 0; width: 51%; opacity: .35; }
.night-orbit { width: 45vw; left: 3%; }
.night-intro { position: relative; z-index: 1; }
.night-hero-deck { position: relative; z-index: 2; }
.night-moon-badge-disk { flex: 0 0 28px; }
[data-moon] { min-height: 190px; }
.night-date { min-height: 24px; }
.playing-animate .playing-card-surface { animation-duration: 700ms; }
@media(max-width:620px) {
  .site-header .site-shell { gap: 6px; }
  .site-header .brand { font-size: 1.2rem; }
  .header-actions { gap: 2px; }
  .night-hero-content { gap: 12px; padding-block: 14px 18px; }
  .night-hero-top-row { margin-bottom: 8px; gap: 4px; flex-wrap: nowrap; }
  .night-moon-badge { width: 112px; padding: 5px; gap: 4px; border-radius: 12px; }
  .night-moon-badge-phase { font-size: .68rem; }
  .night-moon-badge-day { font-size: .61rem; }
  .night-date { font-size: .68rem; margin: 0; }
  .night-hero h1 { font-size: 2.7rem; }
  .night-lead { margin: 8px 0; font-size: .85rem; max-width: none; }
  .night-form-text { margin: 6px 0; }
  .night-private { margin: 3px 0; }
  .night-hero-deck .morning-card { padding: 12px; grid-template-columns: minmax(0,1fr) 156px; gap: 8px; }
  .night-hero-deck .playing-card { width: 156px; max-width: 156px !important; }
  .night-hero-deck .playing-deck-tip { font-size: .75rem; margin-bottom: 6px; }
  .night-hero-deck .morning-card-header h3 { font-size: 1.1rem; }
  .night-hero-deck .playing-how-calc { margin-top: 5px; padding-top: 5px; }
  .night-hero-deck .btn { padding: 8px; min-height: 44px; font-size: .75rem; }
  .night-intro, .night-form, .calc, .calc-form { min-width: 0; }
}
@media(prefers-reduced-motion:reduce) { .night-hero-deck * { transition: none !important; animation: none !important; } }
html:is([data-has-profile],[data-ritual-entry]):not([data-editing-profile]) .night-guest { display: none; }
html:is([data-has-profile],[data-ritual-entry]) .night-return { display: flex; }
html[data-editing-profile] .night-guest:not([hidden]) { display: block; }
.night-hero-content { min-height: 510px !important; }
.morning-number-value { min-height: 1em; }
@media(max-width:620px) {
  .night-hero-content { min-height: 0 !important; }
  .night-hero-deck [data-playing-card] { width: 156px; }
  .night-hero-top-row { min-height: 63px; }
  .night-hero-deck .playing-how-calc p { font-size: .75rem; }
}
.aura-reaction-btn {background:#111b2c;color:#e8d3a7;border:1px solid #665b45;min-height:44px;padding:10px 14px;border-radius:8px}
.aura-reaction-btn.is-active {background:#d8b880;color:#101624}

/* The home has one task per visit: birth results or the returning daily ritual. */
html:not([data-has-profile]):not([data-ritual-entry]) .night-hero-deck,
html[data-editing-profile] .night-hero-deck { display:none; }
html:not([data-has-profile]):not([data-ritual-entry]) .night-hero-content,
html[data-editing-profile] .night-hero-content { grid-template-columns:minmax(0,1fr);min-height:300px!important; }
html:not([data-has-profile]):not([data-ritual-entry]) .night-intro { max-width:650px; }
.morning-moon-line { color:#e8d3a7;font-size:1rem;line-height:1.6;text-underline-offset:4px;max-width:510px; }
.night-return { margin-top:18px; }
[data-playing-reward-notice] {font-size:.85rem;color:#e8d3a7;}
@media(max-width:620px) {
  .night-hero-content {padding-block:20px;}
  .night-hero h1 {font-size:2.35rem;margin-top:12px;}
  .morning-moon-line {font-size:.9rem;}
  .night-return {margin-top:8px;}
}
.return-heading {display:none;}
html:is([data-has-profile],[data-ritual-entry]):not([data-editing-profile]) .guest-heading {display:none;}
html:is([data-has-profile],[data-ritual-entry]):not([data-editing-profile]) .return-heading {display:inline;}
.morning-moon-line {min-height:3.2em;}
html:is([data-has-profile],[data-ritual-entry]):not([data-editing-profile]) .night-return[hidden] {display:flex!important;}
.home-site-links {padding-block:20px;font-size:.85rem;}
.home-site-links > summary {cursor:pointer;min-height:44px;color:#e8d3a7;}

.v31-next{display:block;margin-block:2rem;padding-block:1.25rem;border-top:1px solid var(--line,#7776)}
.v31-next a{max-width:100%;overflow-wrap:anywhere}.v31-next [data-v31-backup]{font-size:.95rem}
.v31-catalog{margin-block:1.25rem}.v31-catalog details{border-bottom:1px solid var(--line,#7776);padding:.65rem 0}.v31-catalog summary{cursor:pointer;min-height:44px;display:flex;align-items:center;font-weight:600}.v31-catalog details a,.v31-nearby a{display:inline-block;padding:.5rem .75rem;overflow-wrap:anywhere}.v31-catalog ul{columns:3;list-style:none;padding:0}.v31-catalog li{break-inside:avoid}
.v31-menu>nav{max-height:70vh;overflow:auto;min-width:260px}.v31-menu>nav a,.mobile-menu>nav a{min-height:44px;display:flex;align-items:center}.v31-previous{margin-block:1rem}
@media(max-width:600px){.v31-catalog ul{columns:1}.v31-next{align-items:stretch;flex-direction:column}.v31-next .primary{width:100%}.mobile-menu>nav{max-height:75vh;overflow-y:auto}}

.v31-next-core{display:flex;align-items:center;gap:1rem;flex-wrap:wrap}.v31-ritual{margin-block-start:1.5rem;border-top:1px solid var(--line,#7776);padding-top:1rem}.v31-ritual-topic{display:block;font-size:.9rem;opacity:.8}.v31-ritual a{display:inline-block;min-height:44px;padding-block:.6rem}.v31-authority{margin-block:1.5rem;padding-block:1rem;border-top:1px solid var(--line,#7776);font-size:.9rem}.v31-authority p{margin-block:.4rem}.v31-authority time{margin-inline-end:1rem}
/* Stable layout contract shared with design-v31. */
.v31-section-nav{display:flex;align-items:center;gap:1rem;border-block:1px solid var(--line,#7776);padding-block:.45rem;max-width:100%;box-sizing:border-box}.v31-section-nav .section-home{font-weight:700;flex-shrink:0;max-width:18rem}.v31-section-nav ul{display:flex;list-style:none;margin:0;padding:0;gap:.35rem;overflow-x:auto}.v31-section-nav a{display:flex;align-items:center;min-height:44px;padding:.4rem .65rem;white-space:nowrap}.v31-section-nav [aria-current]{border-bottom:2px solid var(--gold,#b58d42)}.v31-portal{display:grid;gap:1rem;margin-block:1.25rem}.v31-portal-panel ul{list-style:none;padding:0;display:grid;gap:.65rem}.v31-portal-panel a{display:inline-block;min-height:44px}.v31-section-search{display:flex;gap:.75rem;align-items:center;flex-wrap:wrap}.v31-section-search input{font:inherit;min-height:44px;min-width:0;max-width:100%;padding:.5rem;border:1px solid var(--line,#7776);background:var(--paper,#fff);color:inherit}.v31-section-search a{min-height:44px;display:flex;align-items:center}.v31-portal-panel h2:empty{display:none}.v31-catalog [hidden]{display:none!important}
@media(max-width:600px){.v31-section-nav{display:block}.v31-section-nav .section-home{max-width:100%;white-space:normal;padding-block:.2rem}.v31-section-nav ul{scrollbar-width:thin}.v31-section-nav ul a{max-width:230px;white-space:normal}.v31-section-search{align-items:stretch}.v31-section-search input{width:100%}}

/* Shared taxonomy, hub and cross-section navigation. */
.structure-journey, .date-context { padding-block: 2rem; }
.structure-journey { display: grid; gap: 1.5rem; }
.structure-journey h2, .date-context h2 { font-size: 1.5rem; margin: 0 0 .8rem; }
.structure-start { margin: 1rem 0; font-size: .95rem; }
.structure-start a { color: var(--bronze); }
.structure-next { border: 1px solid var(--line); border-radius: 16px; padding: 1.4rem; background: var(--card); }
.structure-next > a { font: 400 1.4rem/1.4 var(--font-serif); color: var(--bronze); }
.structure-hub { margin-block: 2rem; }
.structure-hub h3 { font-size: 1.45rem; margin-top: 2rem; }
.hub-link-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,220px),1fr)); gap: .6rem 1.5rem; padding-left: 1.1rem; font-size: .95rem; }
.hub-link-grid li { padding: .3rem; }
.stone-filters { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,210px),1fr)); align-items: start; gap: .65rem; }
.stone-filters details, .angel-calendar details { padding: .85rem 1rem; border: 1px solid var(--line); background: var(--card); border-radius: 10px; }
.stone-filters summary, .angel-calendar summary { cursor: pointer; }
.stone-filters summary span { color: var(--muted); font-size: .8rem; }
.stone-filters ul, .angel-calendar ul { padding-left: 1.1rem; font-size: .9rem; }
.stone-filters li, .angel-calendar li { margin-block: .5rem; }
.angel-calendar { display: grid; gap: .5rem; }
.date-context { border-top: 1px solid var(--line); }
.date-context[hidden] { display:none; }
.section-directory { content-visibility: auto; contain-intrinsic-size: auto 800px; }
.section-directory h2 { font-size:clamp(1.5rem,3vw,2rem); overflow-wrap:anywhere; }
@media(max-width:620px) { .structure-journey { gap: 1rem; } .structure-next { padding: 1rem; } }

/* Shared internal-page foundation. Homepage retains its own art direction. */
:root {
  --aura-night: #101426;
  --aura-depth: #080c17;
  --aura-gold: #c5a56a;
  --aura-highlight: #e4cea0;
  --type-caption: .75rem;
  --type-small: .875rem;
  --type-body: 1.0625rem;
  --type-lead: clamp(1.125rem, 1.6vw, 1.3rem);
  --type-title: clamp(2rem, 4.2vw, 3.75rem);
  --type-section: clamp(1.5rem, 2.6vw, 2.3rem);
  --leading-body: 1.8;
  --reading-measure: 68ch;
  --space-1: .5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-6: clamp(3rem, 6vw, 6rem);
  --radius-small: 8px;
  --radius-card: 18px;
  --shadow-card: 0 18px 45px #03061135;
  --shadow-hover: 0 22px 50px #03061155, 0 0 30px #c5a56a0b;
  --layer-content: 0;
  --layer-header: 10;
  --layer-overlay: 30;
  --motion-fast: 150ms;
  --motion-base: 250ms;
  --motion-reveal: 400ms;
  --ease-out: cubic-bezier(.2,.7,.2,1);
  --ease-standard: cubic-bezier(.4,0,.2,1);
}

/* Loaded only on internal pages, after existing component sheets. */
:root:not([data-theme="light"]) {
  color-scheme: dark;
  --paper: var(--aura-night);
  --paper-deep: var(--aura-depth);
  --card: #171d32;
  --text: #ebe9e3;
  --muted: #b2b7c9;
  --line: #b6bfd522;
  --gold: var(--aura-gold);
  --gold-pale: var(--aura-highlight);
  --bronze: var(--aura-gold);
  --teal: var(--aura-highlight);
}
body { font-size: var(--type-body); line-height: var(--leading-body); }
a, a:hover { text-decoration: none; }
a { transition: color var(--motion-fast) var(--ease-out); }
a:hover { color: var(--bronze); }
:focus-visible { outline: 2px solid var(--bronze); outline-offset: 5px; }
h1 { font-size: var(--type-title); line-height: 1.2; letter-spacing: -.035em; text-wrap: balance; }
h2 { font-size: var(--type-section); line-height: 1.3; }
.site-header { z-index: var(--layer-header); }
.breadcrumbs, .breadcrumbs a { color: var(--muted); font-size: var(--type-small); }
.breadcrumbs a:hover { color: var(--bronze); }
.top-nav [aria-current="page"] { text-decoration: none; color: var(--gold-pale); }
.btn, .calc button[type="submit"] { border-radius: var(--radius-small); transition: background var(--motion-base) var(--ease-out), box-shadow var(--motion-base) var(--ease-out), transform var(--motion-base) var(--ease-out); }
.btn.primary { color: var(--aura-depth); background: var(--aura-gold); border-color: transparent; }
.btn.secondary { color: var(--text); background: transparent; border-color: var(--line); }
.btn.secondary:hover { background: var(--card); color: var(--text); border-color: var(--bronze); }
.btn:active { transform: translateY(1px); }
[data-article-page] {
  --article-bg: var(--paper);
  --article-surface: var(--card);
  --article-inset: var(--paper-deep);
  --article-text: var(--text);
  --article-heading: var(--text);
  --article-soft: var(--muted);
  --article-muted: var(--muted);
  --article-gold: var(--bronze);
  --article-link: var(--teal);
  --article-line: var(--line);
  --article-reading-width: min(68ch, 720px);
}
.article-main .article-header h1 { font-size: var(--type-title); line-height: 1.2; }
.article-hero { background: radial-gradient(ellipse at 85% 0%, #5861a019, transparent 65%); }
.article-hero-inner { padding-block: var(--space-6) var(--space-5); }
.article-hero .lead { font-size: var(--type-lead); line-height: 1.75; color: var(--muted); }
.article-prose { font-size: var(--type-body); line-height: var(--leading-body); }
.article-prose :is(p, li) > a:not([class]), .article-prose p > a {
  color: var(--article-link);
  text-decoration: none;
  background-image: linear-gradient(var(--aura-gold),var(--aura-gold));
  background-position: 0 100%; background-repeat: no-repeat; background-size: 100% 1px;
  transition: background-size var(--motion-base) var(--ease-out), background-color var(--motion-base) var(--ease-out), color var(--motion-base) var(--ease-out);
}
.article-prose :is(p,li) > a:hover { background-size: 100% 2px; background-color: #c5a56a12; }
.article-prose :is(nav,.am-links,.am-item) a { background: none; text-decoration: none; }
.article-prose :is(h2,h3) { scroll-margin-top: 2rem; }
.am-short, .am-brief, .article-summary { border: 0; border-left: 2px solid var(--bronze); border-radius: 0; background: transparent; padding: 1rem 1.5rem; }
.am-passport { gap: 1rem 2rem; padding-block: 1rem; border-block: 1px solid var(--line); }
.am-passport > div { border: 0; background: transparent; border-radius: 0; padding: 0; }
.am-faq, .faq-section { max-width: var(--reading-measure); margin-inline: auto; }
.am-faq details, .faq-section details { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; padding: 1rem 0; }
.article-toc-inline { margin-block: 1rem 2rem; border: 0; background: transparent; }
.article-toc a { text-decoration: none; font-size: var(--type-small); color: var(--muted); }
.article-toc p { display: none; }
.article-side { font-size: var(--type-small); }
.article-hero-art { overflow: hidden; }
.article-hero-art img { translate: 0 var(--art-offset, 0px); }
.utility-shell { padding-block: var(--space-5) var(--space-6); }
.utility-heading { max-width: 52rem; margin-bottom: var(--space-5); }
.utility-heading .lead { max-width: var(--reading-measure); font-size: var(--type-lead); color: var(--muted); }
.eyebrow, .article-kicker { color: var(--muted); font-size: var(--type-caption); letter-spacing: .11em; }
.eyebrow::before, .article-kicker::before { display: none; }
.card-grid, .catalog-grid { gap: clamp(1rem, 2.5vw, 2rem); }
.feature-card, .panel, .structure-next { border-color: transparent; box-shadow: none; }
.feature-card { border-radius: var(--radius-card); overflow: hidden; background: var(--card); transition: transform var(--motion-base) var(--ease-out), box-shadow var(--motion-base) var(--ease-out), background var(--motion-base) var(--ease-out); }
.feature-title { font-size: clamp(1.2rem, 1.8vw, 1.6rem); line-height: 1.4; }
.feature-body { padding: 1.5rem; gap: .7rem; }
.feature-body p { font-size: var(--type-small); line-height: 1.7; color: var(--muted); }
.feature-card:hover .feature-title { text-decoration: none; }
.feature-card .card-link { color: var(--muted); font-size: var(--type-small); }
.catalog-grid .feature-media { aspect-ratio: 16/10; }
.catalog-grid .feature-media img { object-fit: contain; }
.catalog-grid .feature-card { min-width: 0; }
.structure-next, .structure-hub { border: 0; background: transparent; }
.hub-link-grid { gap: .75rem; }
.hub-link-grid > a { border-color: var(--line); background: transparent; text-decoration: none; }
.stone-filters details, .angel-calendar details { background: var(--card); border-color: transparent; border-radius: var(--radius-small); }
.ui-catalog-filter { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; margin-block: 1.5rem; color: var(--muted); font-size: var(--type-small); }
.ui-catalog-filter input { width: min(100%, 26rem); padding: .8rem 1rem; color: var(--text); border: 1px solid var(--line); background: var(--card); border-radius: var(--radius-small); }
.ui-today { display: flex; flex-wrap: wrap; align-items: baseline; gap: .5rem 2rem; padding-block: 1.25rem; margin-block: 2rem; border-block: 1px solid var(--line); }
.ui-today span { color: var(--muted); font-size: var(--type-small); }
.calc-result, .result-panel, [data-personal-result] { border-color: var(--line); border-radius: var(--radius-card); box-shadow: none; }
@media (hover:hover) { .feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); border-color: transparent; } }
@media (min-width:1050px) {
  .article-reading:has(>.article-toc-inline) { display: grid; grid-template-columns: minmax(0,1fr); position: relative; }
  .article-toc-inline { position: absolute; left: calc(100% + 3rem); top: 0; width: 220px; max-height: 75vh; overflow: auto; }
  .article-toc-inline > summary { pointer-events: none; list-style: none; font-size: var(--type-caption); color: var(--muted); margin-bottom: .75rem; }
}
@media (max-width:650px) {
  .archive-featured .feature-card { display: grid; grid-template-columns: 96px minmax(0,1fr); }
  .archive-featured .feature-media { height: 100%; aspect-ratio: auto; }
  .archive-featured .feature-body { padding: 1rem; }
  .archive-featured .feature-body p { display: none; }
  .catalog-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .catalog-grid .feature-body { padding: 1rem; }
  .catalog-grid .feature-body p, .catalog-grid .card-link { display: none; }
  .catalog-grid .feature-title { font-family: var(--font-sans); font-size: .875rem; line-height: 1.5; }
  .article-hero-inner { padding-block: 2rem; }
}
@media (prefers-reduced-motion:no-preference) {
  @view-transition { navigation: auto; }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: 250ms; }
  .ui-reveal { animation: aura-arrive var(--motion-reveal) var(--ease-out) both; }
  @keyframes aura-arrive { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
}
@media (prefers-reduced-motion:reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .article-hero-art img { translate: none; }
}

.am-short { border: 0; border-inline-start: 2px solid var(--bronze); border-radius: 0; background: transparent; box-shadow: none; }

@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion:no-preference) {
    .article-hero-art img { animation: aura-parallax linear both; animation-timeline: scroll(root); animation-range: 0px 600px; }
    @keyframes aura-parallax { to { transform: translateY(16px); } }
  }
}
/* Match component specificity from the inherited article sheet. */
.article-prose .am-short { border: 0; border-inline-start: 2px solid var(--bronze); border-radius: 0; background: transparent; box-shadow: none; }
.article-prose details.am-faq { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; padding: .75rem 0; }
.article-toc ul { list-style: none; padding: 0; margin: 0; }
.article-toc li { margin-block: .5rem; }
.utility-heading { padding-block: 1.5rem 0; margin-bottom: 1.5rem; }
.utility-heading h1 { font-size: var(--type-title); }

/* Catalog and research refinements. */
[hidden] { display: none !important; }
.ui-stone-filters fieldset { border: 0; padding: 0; margin: 0 0 1.5rem; min-width: 0; }
.ui-stone-filters legend { color: var(--muted); font-size: var(--type-small); margin-bottom: .75rem; }
.ui-chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-block: .75rem; }
.ui-chips button { color: var(--muted); background: transparent; border: 1px solid var(--line); border-radius: 999px; padding: .55rem .9rem; font: inherit; font-size: .8rem; cursor: pointer; transition: background var(--motion-fast), color var(--motion-fast); }
.ui-chips button[aria-pressed=true] { color: var(--aura-depth); background: var(--aura-gold); border-color: transparent; }
.ui-chips button:disabled { opacity: .35; cursor: default; }
.ui-stone-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1.5rem; margin-block: 2rem; }
.ui-stone-card { display: flex; flex-direction: column; gap: 1rem; min-width: 0; border-radius: var(--radius-card); padding: 1rem; background: var(--card); transition: transform var(--motion-base), box-shadow var(--motion-base); }
.ui-stone-card img { width: 100%; height: auto; aspect-ratio: 16/10; object-fit: contain; border-radius: var(--radius-small); }
.ui-stone-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.ui-pagination { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-block: 2rem; }
.ui-pagination button:disabled { opacity: .35; cursor: default; }
.am-items:has(.ui-tarot-card) { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1.5rem; }
.article-prose .ui-tarot-card { padding: 0; border: 0; background: transparent; min-width: 0; }
.ui-tarot-card h3 { font-size: 1rem; }
.ui-tarot-card a { display: flex; flex-direction: column; gap: .75rem; }
.ui-tarot-card img { width: 100%; height: auto; aspect-ratio: 800/1350; object-fit: contain; background: var(--card); border-radius: var(--radius-small); }
.ui-tarot-card p { font-size: .85rem; line-height: 1.6; color: var(--muted); }
.ui-related-card { display: flex; flex-direction: column; gap: .75rem; max-width: 240px; }
.ui-related-card img { width: 100%; height: 110px; object-fit: contain; background: var(--card); border-radius: var(--radius-small); }
.article-hero-art { transition: transform var(--motion-reveal) var(--ease-out); }
.article-hero-art.ui-reversed { transform: rotate(180deg); }
:is(.lunar-table,.lunar-scroll table) th { color: var(--aura-gold); }
:is(.lunar-table,.lunar-scroll table) :is(td,th) { border: 0; border-bottom: 1px solid var(--line); }
:is(.lunar-table,.lunar-scroll table) tr:nth-child(even) { background: #ffffff05; }
.article-prose .am-passport { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
:is(.stone-filters,.angel-calendar,.article-prose) summary { list-style: none; cursor: pointer; }
:is(.stone-filters,.angel-calendar,.article-prose) summary::-webkit-details-marker { display: none; }
:is(.stone-filters,.angel-calendar,.article-prose) summary::after { content: '+'; float: right; color: var(--bronze); transition: transform var(--motion-base); }
:is(.stone-filters,.angel-calendar,.article-prose) details[open]>summary::after { transform: rotate(45deg); }
@media (min-width:1250px) {
 .article-reading:has(>.article-toc-inline) { grid-template-columns: minmax(0,720px) 220px; gap: 3rem; width: 988px; max-width: calc(100vw - 4rem); }
 .article-toc-inline { position: sticky; left: auto; top: 2rem; grid-column: 2; grid-row: 1 / span 3; align-self: start; width: 220px; }
 .article-reading>.article-prose, .article-reading>.article-action-row { grid-column: 1; }
}
@media (max-width:1249px) and (min-width:1050px) { .article-toc-inline { position: static; width: auto; } }
@media (max-width:650px) { .ui-stone-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: .75rem; } .ui-stone-card { padding: .75rem; font-size: .85rem; } .am-items:has(.ui-tarot-card) { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1rem; } }
@media (hover:hover) and (prefers-reduced-motion:no-preference) { .ui-tarot-card:hover img { transform: perspective(800px) rotateY(-4deg) rotateX(2deg); transition: transform var(--motion-base); } }
@media (max-width:650px) { .ui-stone-filters .ui-chips { flex-wrap: nowrap; overflow-x: auto; padding-bottom: .5rem; } .ui-stone-filters .ui-chips button { flex: 0 0 auto; } }
.article-main:has(.angel-passport) h1 { font-size: clamp(1.8rem,3.3vw,3rem); max-width: 22ch; text-wrap: balance; }

/* P0 presentation invariants; loaded after page-specific styles. */
*, *::before, *::after { box-sizing:border-box; }
.article-header { display:flow-root; min-width:0; }
.article-header .article-publication { position:static; height:auto; margin:16px 0 24px; }
.article-header .legacy-wrap { clear:both; margin-top:24px; }
.reading-tile > strong, .reading-tile .tile-link { display:block; }
.reading-tile .tile-link { margin-top:12px; }
.structure-next, .structure-next * { min-width:0; overflow-wrap:anywhere; }
.structure-next .ritual-invitation { width:100%; padding:12px; }
.structure-next .btn { white-space:normal; max-width:100%; }
.home-feed-article img { height:auto; aspect-ratio:auto; object-fit:contain; }
.article-hero-art { aspect-ratio:var(--source-ratio, auto); max-height:none; }
.article-hero-art img { height:auto; aspect-ratio:var(--source-ratio, auto); object-fit:contain; }
.feature-media:has(img), .catalog-art:has(img) { aspect-ratio:var(--source-ratio, auto); height:auto; }
.feature-media img, .catalog-art img { height:auto; aspect-ratio:auto; object-fit:contain; }
.angel-date-cards img { height:auto; aspect-ratio:auto; object-fit:contain; }
.calc .lines { display:grid; gap:4px; }
.calc .lines li { height:auto; min-height:min-content; }
@media(max-width:720px) {
 .article-header, .article-reading, .article-prose { min-width:0; }
 .article-hero--art { grid-template-columns:minmax(0,1fr); }
 .article-hero-art { justify-self:start; }
 .article-table table { width:100%; table-layout:fixed; }
 .article-table :is(th,td) { white-space:normal; overflow-wrap:anywhere; min-width:0; }
 .am-choirs thead, .angel-month-tables thead { display:none; }
 .am-choirs tbody, .am-choirs tr, .am-choirs td { max-width:100%; min-width:0; }
 .reading-grid, .structure-journey { grid-template-columns:minmax(0,1fr); }
 .article-hero .calc { padding-inline:8px; }
 .calc .res-card { padding:8px; }
}
/* The private integration receipt has no shared site shell. */
html:has(title):not(:has(.page-main)) { color-scheme:dark; }
body:has(> h1:first-child) { background:#0a1021; color:#ebe5d8; overflow-wrap:anywhere; }
body:has(> h1:first-child) a { color:#e6cf9e; }
html[data-theme=light] body:has(> h1:first-child) { background:#fff; color:#222; }
html[data-theme=light] body:has(> h1:first-child) a { color:#6545a5; }
@media(max-width:720px) {
 .lunar-today { flex-direction:column; }
 .lunar-today > div { width:100%; }
 .lunar-scroll .lunar-table { min-width:0; table-layout:fixed; }
 .lunar-table :is(td,th) { padding:6px 3px; overflow-wrap:anywhere; }
 .article-prose :is(.am-short,.res-card) { padding-inline:10px; }
}
/* Inline values and links created by calculator scripts use separate lines. */
.reading-tile > a, .tile-link { display:block; margin-top:12px; }
img[style*="--source-ratio"]:not(.night-hero-art img) { height:auto; aspect-ratio:var(--source-ratio); object-fit:contain; }
@media(max-width:720px) {
 .article-prose .am-tip { padding-inline:10px; }
 .article-prose .am-tip::before { position:static; float:none; display:block; }
}
@media(max-width:720px) { .article-prose .am-tip { display:block; padding-inline:0; } }

/* Fable P0: include last. Natural expansion preserves all personal/calculator text. */
:root {
  --leading-body: 1.65;
  --reading-measure: 680px;
  --type-caption: 12px;
  --type-small: 15px;
  --type-title: clamp(30px, 4.2vw, 48px);
}
[data-article-page] { --article-reading-width: 680px; }

/* Do not reserve a 36rem viewport for an empty or dynamically restored calculator. */
[data-today-calculators] .calc[data-calc] {
  block-size: auto;
  min-block-size: 0;
  max-block-size: none;
  overflow: visible;
  scrollbar-gutter: auto;
  contain: none;
}

/* Two rows total 54px including borders. The live track scrolls without truncation. */
[data-today-layer] {
  --text: #ebe9e3;
  --soft: #c9cbd6;
  --muted: #9aa7bd;
  --plate: var(--aura-night, #101426);
  --depth: var(--aura-depth, #080c17);
  --hl: var(--aura-highlight, #e4cea0);
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: 20px 24px;
  column-gap: 12px;
  block-size: 54px;
  min-block-size: 54px;
  max-inline-size: 100%;
  margin-block: 24px;
  padding: 4px 12px;
  overflow: visible;
  overscroll-behavior: auto;
  scrollbar-gutter: auto;
  contain: none;
  border: 1px solid var(--aura-gold, #c5a56a);
  border-radius: var(--radius-small, 8px);
  background: var(--plate);
  color: var(--text);
  font: 400 13px/1.4 var(--font-sans, sans-serif);
  color-scheme: dark;
}
[data-today-layer] > h2 {
  grid-area: 1 / 1;
  min-inline-size: 0;
  margin: 0;
  color: var(--text);
  font: 600 12px/20px var(--font-sans, sans-serif);
}
[data-today-layer] .today-lines {
  grid-area: 2 / 1;
  display: flex;
  gap: 20px;
  min-inline-size: 0;
  min-block-size: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
}
[data-today-layer] .today-lines p {
  display: block;
  flex: 0 0 auto;
  margin: 0;
  max-inline-size: none;
  overflow: visible;
  white-space: nowrap;
  -webkit-line-clamp: unset;
  -webkit-box-orient: initial;
  font-size: 13px;
  line-height: 20px;
}
[data-today-layer] .today-details { grid-area: 1 / 2; min-inline-size: 0; }
[data-today-layer] .today-details summary {
  min-block-size: 0;
  padding: 0;
  color: var(--hl);
  font-size: 12px;
  line-height: 20px;
}
[data-today-layer] .today-edit {
  grid-area: 2 / 2;
  display: block;
  min-block-size: 0;
  padding: 0;
  color: var(--hl);
  font-size: 12px;
  line-height: 24px;
}
[data-today-layer]:has(.today-profile:not([hidden])),
[data-today-layer]:has(.today-details[open]) {
  block-size: auto;
  grid-template-rows: 20px auto;
  row-gap: 8px;
  padding-block: 12px;
}
[data-today-layer]:has(.today-profile:not([hidden])) .today-lines,
[data-today-layer]:has(.today-details[open]) .today-lines { flex-wrap: wrap; overflow: visible; }
[data-today-layer]:has(.today-profile:not([hidden])) .today-lines p,
[data-today-layer]:has(.today-details[open]) .today-lines p {
  flex: 1 1 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}
[data-today-layer] .today-details[open] { grid-area: 3 / 1 / auto / -1; }
[data-today-layer] .today-details[open] p { margin-block: 8px; line-height: 1.5; }
[data-today-layer] .today-profile {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
  gap: 8px;
  padding: 0;
}
[data-today-layer] .today-profile :is(input, button) {
  min-inline-size: 0;
  min-block-size: 44px;
  border-color: var(--aura-gold, #c5a56a);
  background: var(--depth);
  color: var(--text);
  font: 400 16px/1.4 var(--font-sans, sans-serif);
}
[data-today-layer] .today-profile button { background: var(--aura-gold); color: var(--depth); }
[data-today-layer] .today-profile [role="status"] { grid-column: 1 / -1; margin: 0; }
[data-today-layer] [hidden] { display: none !important; }
[data-today-layer] :focus-visible { outline: 2px solid var(--hl); outline-offset: 2px; }

/* Shared text rhythm; components keep their own font sizes and hierarchy. */
:root[data-p0-kind] :is(h1,h2,h3,h4,h5,h6,.feature-title,.section-head h2) { line-height: 1.3; }
:root[data-p0-kind] :is(p,li,dt,dd,summary,label,figcaption,th,td,button,input,select,textarea) { line-height: 1.4; }
.article-main .article-header h1 {
  max-inline-size: 100%;
  font-size: var(--type-title);
  line-height: 1.3;
  letter-spacing: -.012em;
  text-wrap: balance;
}
[data-article-page] .article-prose {
  inline-size: 100%;
  max-inline-size: 680px;
  font-size: 18px;
  line-height: var(--leading-body);
}
:root[data-p0-kind] .article-prose :is(p,li,blockquote) { line-height: var(--leading-body); }
.article-prose :is(h2,h3,h4), .article-prose .am-item > h2 { line-height: 1.3; }
.article-prose h2 { margin-block: 56px 16px; }
.article-prose h3 { margin-block: 32px 8px; }
.article-prose p { margin-block-end: 16px; }
.article-side p, .am-passport dt, .article-prose .am-cal__month :is(a,span,small),
.hero-caption, .night-date, .night-moon-badge-phase, .night-moon-badge-day, .lunar-grid small,
.lunar-next, .lunar-time-note, .lunar-method, .cm-keywords span,
.home-feed-article:first-child .home-feed-article-title::before {
  font-size: 12px;
  line-height: 1.4;
}
small, figcaption { font-size: max(12px, .75rem); line-height: 1.4; }
.edition-plate strong, .edition-topic h2, .legacy-wrap :is(h1,h2,h3), .calc .calc-title, .calc .res-title,
.article-prose .am-item > h2 { line-height: 1.3; }
/* Keep the compact rows' exact metrics above the shared text rhythm. */
:root[data-p0-kind] [data-today-layer] > h2 { line-height: 20px; }
:root[data-p0-kind] [data-today-layer] .today-lines p { line-height: 20px; }
:root[data-p0-kind] [data-today-layer] .today-details summary { line-height: 20px; }

@media (max-width: 900px) {
  .article-hero-inner, [data-article-page] .article-layout { padding-inline: 16px; }
  [data-article-page] .article-layout { grid-template-columns: minmax(0, 1fr); }
  .article-reading, .article-prose { min-inline-size: 0; }
}
@media (max-width: 720px) {
  :root[data-p0-kind] .article-main .article-header h1 { font-size: 30px; line-height: 39px; max-inline-size: 100%; }
  .article-hero-inner { padding-block: 32px 24px; }
  [data-article-page] .article-prose { font-size: 17px; }
  .article-main .article-header .lead { font-size: 18px; line-height: 28px; }
  .article-prose :is(.am-short,.am-brief,.article-summary,.am-note,blockquote,.am-box) {
    margin-inline: 0;
    padding-inline: 12px;
  }
  .article-prose .am-item { padding-inline: 12px; }
  :root[data-p0-kind="hub"] .article-hero-art { display: none; }
  :root[data-p0-kind="hub"] .article-hero--art { grid-template-columns: minmax(0, 1fr); }
}

.p0-onward { max-width:1080px; padding-block:32px; }
.p0-onward > :is(nav,aside,div,details) { width:100%; margin:24px 0; padding-inline:0; }
.p0-onward nav { display:block; }
.p0-onward nav a { display:block; min-width:0; padding:12px 0; overflow-wrap:anywhere; }
.p0-onward .structure-next { display:none; }
.p0-onward .methodology-note { background:none; border:0; padding:0; }
.p0-onward .methodology-note h2 { display:none; }
.p0-meta { display:flex; flex-wrap:wrap; gap:12px 24px; font-size:13px; line-height:1.4; }
.p0-meta .article-publication { position:static; height:auto; margin:0; }
.p0-meta .methodology-note { flex-basis:100%; font-size:13px; }
.p0-archive > :not(summary) { max-width:100%; padding-inline:0; }
.p0-archive a { margin:8px 0; }
.p0-archive:not([open]) > :not(summary) { display:none; }
.p0-lead-continuation { max-width:680px; margin:0 0 24px; font-size:18px; line-height:1.65; }
 .p0-method { position:relative; max-width:100%; }
.p0-method > summary { list-style:none; cursor:pointer; color:var(--article-link); }
.p0-method-preview { max-height:420px; overflow:hidden; margin-bottom:16px; color:var(--article-text); font-size:18px; line-height:1.65; }
.p0-method-preview[data-preview]::before { content:attr(data-preview); }
.p0-method-action::after { content:'Читать целиком'; }
.p0-method[open] .p0-method-preview { display:none; }
.p0-method[open] > summary { margin-bottom:24px; }
.p0-catalog-controls { display:flex; gap:16px; margin:24px 0; }
.p0-catalog-controls button { padding:10px 16px; }
[data-p0-entry][hidden], .angel-month[hidden] { display:none !important; }
.p0-stone-search { display:grid; gap:8px; margin-bottom:16px; }
.p0-stone-search input { width:100%; min-height:44px; }
.article-hero-art:has([data-p0-image=engraving]) { border:0; border-radius:12px; background:#0b0f1d; }
.home-feed-article img[data-p0-image=engraving] { aspect-ratio:16/9; object-fit:contain; background:#0b0f1d; border:0; border-radius:12px; }
img[data-p0-image=square] { border-radius:12px; }
@media(max-width:720px) {
  :root[data-p0-kind] .article-main .article-header h1.p0-long-title { font-size:24px; line-height:32px; }
  .breadcrumbs li:not(:nth-last-child(2)) { display:none; }
  .breadcrumbs ol { min-height:24px; }
  .article-hero-inner { padding-top:20px; }
  .article-hero-card { width:132px; max-width:132px; }
  .p0-onward { padding-inline:16px; }
  .p0-lead-continuation { font-size:17px; }
}

/* Text metrics apply to dynamically inserted calculator and home content too. */
html[data-p0-kind] body :is(a,span,strong,b,em,i,p,li,dt,dd,summary,label,figcaption,th,td,button,input,select,textarea) { line-height:1.4 !important; }
html[data-p0-kind] body :is(h1,h2,h3,h4,h5,h6) { line-height:1.3 !important; }
html[data-p0-kind] body .article-prose :is(p,li,blockquote) { line-height:1.65 !important; }
html[data-p0-kind] body [data-today-layer] > h2,
html[data-p0-kind] body [data-today-layer] .today-lines p,
html[data-p0-kind] body [data-today-layer] .today-details summary { line-height:20px !important; }
html[data-p0-kind] body [data-today-layer] .today-edit { line-height:24px !important; }

[data-today-layer] .today-lines { overflow:hidden; }
[data-today-layer] .today-lines p { flex:1 1 auto; max-width:100%; overflow:hidden; text-overflow:ellipsis; }
[data-today-layer] .today-lines p:not(:first-child) { display:none; }
[data-today-layer]:has(.today-details[open]) .today-lines { display:none; }
/* Dream data and expanded content stay behind the existing Today disclosure. */
html body .dream-reading[data-dreams-today] { min-block-size:0; margin-block:8px; padding-block:8px; }
html body .dream-reading [data-dream-disclosure] > summary { min-height:44px; cursor:pointer; }
.p0-archive .site-shell { width:100%; padding:0; margin:0; }
@media(max-width:720px) { .lunar-today { padding-inline:10px; } }

html[data-p0-kind] body :is(h1,h2,h3,h4,h5,h6) { line-height:1.31 !important; }
@media(max-width:720px) {
  .article-hero-inner, [data-article-page] .article-layout, .p0-onward { width:100%; padding-inline:18px; }
}

.p0-entity-catalog .hub-link-grid:has([data-p0-entry]) { display:grid; grid-template-columns:repeat(auto-fit,minmax(130px,1fr)); gap:16px; }
.p0-entity-catalog [data-p0-entry] a { display:grid; gap:8px; font-size:14px; }
.p0-entity-catalog [data-p0-entry] img { width:100%; max-width:132px; height:auto; object-fit:contain; }
[data-p0-entry][hidden] { display:none !important; }
.angel-date-cards img { width:56px; height:56px; }

html[data-p0-kind] :is(.home-feed-article,.ui-stone-card) img[data-p0-image=engraving] { aspect-ratio:16/9; object-fit:contain; background:#0b0f1d; border:0; border-radius:12px; }
.feature-media:has(img[data-p0-image=engraving]) { aspect-ratio:16/9; display:grid; place-items:center; background:#0b0f1d; border:0; border-radius:12px; }

/* Historical edges need one anchor each, without a nested directory tree. */
.preserved-link-archive > a { display:block; margin-block:8px; overflow-wrap:anywhere; }

/* Layout audit: retain usable controls and an entirely visible profile panel. */
.site-header .small-nav-icon { min-inline-size: 44px; min-block-size: 44px; }
.site-footer { --muted: #b6becb; }
@media (max-width: 720px) {
  .site-header .site-shell { position: relative; min-inline-size: 0; }
  .profile-menu { position: static; }
  .profile-menu .profile-popover { inset-inline: 12px; inline-size: auto; max-inline-size: calc(100vw - 24px); }
}
@media (max-width: 360px) {
  .site-header .site-shell { gap: 4px; }
  .site-header .brand { gap: 4px; font-size: 16px; min-inline-size: 0; }
  .site-header .brand-mark { display: none; }
  .site-header .header-actions { gap: 0; margin-inline-start: auto; }
  .site-header .profile-menu summary { min-inline-size: 44px; font-size: 11px; }
}
