/* Shared sub-page chrome (journal, legal, etc.) — layered on theme.css */

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  border-radius: 0.5rem;
  background: hsl(var(--foreground));
  color: hsl(var(--background));
  font-size: 0.875rem;
  transition: top 200ms var(--ease-organic);
}
.skip-link:focus { top: 1rem; outline: 2px solid hsl(var(--accent)); outline-offset: 2px; }

.container-narrative {
  width: 100%;
  max-width: 72rem;
  margin: 0 auto;
  padding: 0 1.5rem;
}
@media (min-width: 768px) {
  .container-narrative { padding: 0 2.5rem; }
}

.brand { display: flex; align-items: center; gap: 0.75rem; }
.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  border-radius: 6px;
  background: hsl(var(--foreground));
  color: hsl(var(--background));
  font-family: var(--font-serif);
  font-size: 0.95rem;
}
.brand-name {
  font-family: var(--font-serif);
  font-size: 1.125rem;
  letter-spacing: -0.01em;
}
.brand-tag-sub {
  display: none;
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: hsl(var(--foreground) / 0.5);
  margin-left: 0.25rem;
}
@media (min-width: 768px) { .brand-tag-sub { display: inline; } }

.subpage-header {
  position: sticky; top: 0; z-index: 30;
  border-bottom: 1px solid hsl(var(--border-soft) / 0.6);
  background: hsl(var(--background) / 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.subpage-header .header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 5rem;
}
.back-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.4rem 0.9rem; border-radius: 9999px;
  font-size: 0.875rem; color: hsl(var(--foreground) / 0.7);
  transition: color .2s ease;
}
.back-link:hover { color: hsl(var(--foreground)); }
.back-link .arrow-back { transition: transform .2s ease; }
.back-link:hover .arrow-back { transform: translateX(-2px); }

.site-footer {
  border-top: 1px solid hsl(var(--border-soft));
  background: hsl(var(--background));
}
.footer-inner { padding-block: 1.1rem; }
.footer-top { display: flex; align-items: center; }
.footer-tagline {
  margin-top: 0.25rem; font-size: 0.7rem; line-height: 1.35;
  color: hsl(var(--foreground) / 0.6); max-width: 50%;
}
@media (max-width: 767px) { .footer-tagline { max-width: 100%; } }
.footer-bottom {
  margin-top: 0.75rem; border-top: 1px solid hsl(var(--border-soft));
  padding-top: 0.65rem; display: flex; flex-wrap: wrap;
  align-items: center; justify-content: space-between; gap: 0.75rem;
}
.footer-legal {
  display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem;
  font-size: 0.75rem; color: hsl(var(--foreground) / 0.6);
  align-items: center;
}
.footer-legal a, .footer-link-btn {
  color: inherit; background: none; border: 0; padding: 0;
  font: inherit; cursor: pointer;
}
.footer-legal a:hover, .footer-link-btn:hover { color: hsl(var(--foreground)); }
.footer-final {
  margin-top: 0.5rem; font-size: 0.7rem;
  color: hsl(var(--foreground) / 0.5);
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

@media (max-width: 640px) {
  .subpage-header .header-inner { height: 3.75rem; }
  .brand-tag-sub { display: none; }
  .back-link { font-size: 0.8rem; padding: 0.35rem 0.65rem; gap: 0.35rem; }
}

/* ===== Legal & sub-page typography (prototypes/front/css/pages.css) ===== */

.subpage-hero .eyebrow,
.legal-toc .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0;
  border: none;
  background: none;
  backdrop-filter: none;
  border-radius: 0;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: hsl(var(--foreground) / 0.6);
  font-weight: 500;
  font-family: var(--font-sans);
  margin-bottom: 0;
}
.subpage-hero .eyebrow::before,
.legal-toc .eyebrow::before {
  content: "";
  width: 24px;
  height: 1px;
  background: hsl(var(--gold));
}
.subpage-hero .eyebrow .dot { display: none; }

.subpage-hero {
  position: relative;
  overflow: hidden;
  background: var(--gradient-warm);
}
.subpage-hero-inner { padding-block: 5rem 4rem; }
@media (min-width: 768px) {
  .subpage-hero-inner { padding-block: 7rem 5rem; }
}
.subpage-hero h1 { margin-top: 1.25rem; }

.narrative-heading {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw + 1rem, 3.75rem);
  line-height: 1.05;
  margin-top: 1.5rem;
  max-width: 56rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: hsl(var(--foreground));
}
.narrative-lead {
  font-size: clamp(1.125rem, 0.5vw + 1rem, 1.25rem);
  line-height: 1.65;
  color: hsl(var(--foreground) / 0.75);
  font-family: var(--font-serif);
  font-weight: 300;
  font-style: italic;
  margin-top: 2rem;
  max-width: 36rem;
}
.muted-line-block { display: block; color: hsl(var(--foreground) / 0.55); }
.meta-row {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: hsl(var(--foreground) / 0.5);
}
.meta-row .sep { color: hsl(var(--foreground) / 0.35); }

.gold-divider {
  height: 1px;
  width: 6rem;
  margin: 1rem 0 0;
  max-width: 14rem;
  background: var(--divider-gold);
}

.legal-body {
  border-top: 1px solid hsl(var(--border-soft));
  background: hsl(var(--background));
  padding-block: 3.5rem 5rem;
}
@media (min-width: 768px) {
  .legal-body { padding-block: 5rem 6rem; }
}
.legal-grid {
  display: grid;
  gap: 3rem;
}
@media (min-width: 768px) {
  .legal-grid { grid-template-columns: 220px 1fr; gap: 4rem; }
}
.legal-toc { position: relative; }
@media (min-width: 768px) {
  .legal-toc { position: sticky; top: 5rem; align-self: start; }
}
.legal-toc .eyebrow { margin-bottom: 1rem; }
.legal-toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  counter-reset: tocnum;
}
.legal-toc a {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  font-size: 0.875rem;
  color: hsl(var(--foreground) / 0.6);
  padding: 0.25rem 0 0.25rem 0.75rem;
  border-left: 2px solid transparent;
  transition: color .2s ease, border-color .2s ease;
  text-decoration: none;
}
.legal-toc a::before {
  content: counter(tocnum, decimal-leading-zero);
  counter-increment: tocnum;
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  color: hsl(var(--foreground) / 0.35);
}
.legal-toc a:hover { color: hsl(var(--foreground)); }
.legal-toc a.is-active {
  color: hsl(var(--accent));
  border-left-color: hsl(var(--accent));
}
.legal-content { max-width: 65ch; }
.legal-section { scroll-margin-top: 7rem; }
.legal-section + .legal-section { margin-top: 4rem; }
.legal-section h2 {
  font-family: 'Fraunces', var(--font-serif);
  font-size: 1.5rem;
  line-height: 1.2;
  font-weight: 400;
  margin: 0;
}
@media (min-width: 768px) {
  .legal-section h2 { font-size: 1.875rem; }
}
.legal-section p,
.legal-section ul,
.legal-section ol { margin-top: 1.25rem; }
.legal-section ul.bullet {
  list-style: disc;
  padding-left: 1.4rem;
}
.legal-section ul.bullet li {
  margin-top: 0.5rem;
  color: hsl(var(--foreground) / 0.78);
  line-height: 1.7;
}
.legal-section a.inline-link {
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: hsl(var(--foreground) / 0.3);
  transition: color .2s ease, text-decoration-color .2s ease;
}
.legal-section a.inline-link:hover {
  color: hsl(var(--foreground));
  text-decoration-color: hsl(var(--foreground));
}
.legal-section code {
  background: hsl(var(--surface-sand) / 0.6);
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-size: 0.85em;
}
.legal-section .strong { font-weight: 500; color: hsl(var(--foreground)); }

.jurisdiction-group { margin-top: 2.5rem; }
.jurisdiction-label {
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: hsl(var(--foreground) / 0.5);
}
.jurisdiction-chips {
  margin-top: 0.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.legal-body .chip,
.subpage-hero .chip {
  border: 1px solid hsl(var(--foreground) / 0.2);
  background: hsl(var(--background));
  border-radius: 9999px;
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  color: hsl(var(--foreground) / 0.75);
  cursor: pointer;
  transition: all .2s ease;
}
.legal-body .chip:hover,
.subpage-hero .chip:hover {
  border-color: hsl(var(--accent));
  color: hsl(var(--accent));
}
.legal-body .chip.is-active,
.subpage-hero .chip.is-active {
  background: hsl(var(--accent));
  border-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
  box-shadow: var(--shadow-soft);
}

.def-grid { display: grid; gap: 2rem; margin-top: 2rem; }
@media (min-width: 768px) {
  .def-grid.two { grid-template-columns: 1fr 1fr; }
  .def-grid.three { grid-template-columns: repeat(3, 1fr); }
}
.def dt,
.card-soft dt {
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: hsl(var(--foreground) / 0.5);
}
.def dd,
.card-soft dd {
  margin: 0.5rem 0 0;
  color: hsl(var(--foreground) / 0.78);
  line-height: 1.7;
}
.card-soft {
  border: 1px solid hsl(var(--border-soft));
  border-radius: 1rem;
  padding: 1.25rem;
  background: hsl(var(--background));
}
.card-sand { background: hsl(var(--surface-sand) / 0.4); }

.action-row {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}
.action-row .arrow { margin-left: 0.15rem; }

.cookie-table-wrap {
  margin-top: 2rem;
  overflow: hidden;
  border: 1px solid hsl(var(--border-soft));
  border-radius: 1rem;
}
.cookie-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.875rem;
}
.cookie-table thead {
  background: hsl(var(--surface-sand) / 0.5);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: hsl(var(--foreground) / 0.6);
}
.cookie-table th,
.cookie-table td {
  padding: 1rem 1.25rem;
  vertical-align: top;
}
.cookie-table tbody tr + tr { border-top: 1px solid hsl(var(--border-soft)); }
.cookie-table td { color: hsl(var(--foreground) / 0.78); }
.cookie-table td.cat { color: hsl(var(--foreground)); font-weight: 500; }

@media (max-width: 640px) {
  .cookie-table thead { display: none; }
  .cookie-table tr { display: block; padding: 1rem 1.25rem; }
  .cookie-table tbody tr + tr { border-top: 1px solid hsl(var(--border-soft)); }
  .cookie-table td { display: block; padding: 0.25rem 0; }
  .cookie-table td::before {
    content: attr(data-label) " · ";
    color: hsl(var(--foreground) / 0.5);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
  }
  .cookie-table td.cat::before { display: none; }
  .subpage-hero h1.narrative-heading { font-size: clamp(1.7rem, 8vw, 2.25rem); line-height: 1.15; }
  .legal-grid { gap: 2rem; }
}

@media (max-width: 480px) {
  .subpage-hero h1.narrative-heading { font-size: 1.5rem; }
}

.drift-in { animation: drift-in 0.6s var(--ease-organic) both; }
@keyframes drift-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .drift-in { animation: none !important; }
}

/* ===== Sticky breadcrumb bar (matches blog-detail) ===== */
.bd-breadcrumb-bar {
  position: sticky;
  top: var(--pm-nav-h, 4rem);
  z-index: 25;
  background: hsl(33 35% 94% / 0.96);
  backdrop-filter: saturate(140%) blur(6px);
  -webkit-backdrop-filter: saturate(140%) blur(6px);
  border-bottom: 1px solid hsl(var(--border-soft));
  box-shadow: 0 1px 0 hsl(var(--border-soft) / 0.4);
}
.bd-breadcrumb-inner {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0.6rem 1.5rem;
  font-size: 0.78rem;
  color: hsl(var(--foreground) / 0.55);
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: nowrap;
  overflow-x: auto;
  scrollbar-width: none;
  white-space: nowrap;
}
@media (min-width: 768px) {
  .bd-breadcrumb-inner { padding: 0.6rem 2.5rem; }
}
.bd-breadcrumb-inner::-webkit-scrollbar { display: none; }
.bd-breadcrumb-inner a {
  color: hsl(var(--foreground) / 0.7);
  border-bottom: 1px dotted hsl(var(--foreground) / 0.25);
  padding: 0.25rem 0.1rem;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
}
.bd-breadcrumb-inner a:hover { color: hsl(var(--foreground)); border-color: hsl(var(--gold) / 0.7); }
.bd-breadcrumb-inner a:focus-visible {
  outline: 2px solid hsl(var(--gold));
  outline-offset: 3px;
  border-radius: 4px;
  border-bottom-color: transparent;
}
.bd-breadcrumb-inner .sep { color: hsl(var(--foreground) / 0.3); }
.bd-breadcrumb-inner .current {
  color: hsl(var(--foreground));
  font-weight: 500;
  max-width: 28ch;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bd-breadcrumb-inner .bd-current-section {
  color: hsl(var(--gold));
  font-weight: 600;
  letter-spacing: 0.01em;
  max-width: 22ch;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity 0.2s ease;
}
@media (max-width: 640px) {
  .bd-breadcrumb-inner { padding: 0.5rem 1rem; font-size: 0.74rem; gap: 0.35rem; }
  .bd-breadcrumb-inner a { min-height: 36px; padding: 0.35rem 0.15rem; }
  .bd-breadcrumb-inner .current { max-width: 18ch; }
  .bd-breadcrumb-inner .bd-current-section { max-width: 18ch; }
}

