/* ─── TOKENS ─────────────────────────────────────────────────────── */
:root {
  --sidebar-w: 220px;
  --site-bg: #f7f6f3;
  --sidebar-bg: #ffffff;
  --sidebar-border: #e8e4dc;
  --ink: #1a1a1a;
  --ink-muted: #888078;
  --ink-soft: #eceae4;
  --brand: #d4a853;
  --post-badge-bg: #1a1a1a;
  --topics-card-bg: #1a4a3a;
  --authors-card-bg: #f0ede8;
  --card-ol-start: rgba(10,10,10,.72);
  --card-ol-end: rgba(10,10,10,.22);
  --studio-ink: #1a1a1a;
  --studio-muted: #5d574e;
  --studio-paper: #fffaf0;
  --studio-paper-strong: #ffffff;
  --radius: 14px;
  --radius-lg: 18px;
  --shadow: 0 2px 12px rgba(0,0,0,.07);
  --shadow-hover: 0 8px 32px rgba(0,0,0,.14);
  --transition: .22s cubic-bezier(.4,0,.2,1);
  --font-head: 'Inter', system-ui, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;
}

/* ─── RESET ──────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; scroll-behavior: smooth; }
body {
  font-family: var(--font-head);
  background: var(--site-bg);
  color: var(--ink);
  display: flex;
  min-height: 100vh;
  line-height: 1.6;
}

body.tone-sand {
  --site-bg: #f7f6f3;
  --sidebar-bg: #ffffff;
  --sidebar-border: #e8e4dc;
  --ink: #1a1a1a;
  --ink-muted: #888078;
  --ink-soft: #eceae4;
  --post-badge-bg: #1a1a1a;
  --topics-card-bg: #1a4a3a;
  --authors-card-bg: #f0ede8;
  --card-ol-start: rgba(10,10,10,.72);
  --card-ol-end: rgba(10,10,10,.22);
}

body.tone-midnight {
  --site-bg: #0f1520;
  --sidebar-bg: #0b1018;
  --sidebar-border: #1e2535;
  --ink: #e8eaf0;
  --ink-muted: #8891a8;
  --ink-soft: #1e2535;
  --post-badge-bg: #3b5bdb;
  --topics-card-bg: #1a2a5e;
  --authors-card-bg: #161e30;
  --card-ol-start: rgba(5,8,18,.75);
  --card-ol-end: rgba(5,8,18,.25);
}

body.tone-forest {
  --site-bg: #f2f5f0;
  --sidebar-bg: #ffffff;
  --sidebar-border: #d8e8d0;
  --ink: #1a2e1a;
  --ink-muted: #5a7a5a;
  --ink-soft: #e0ead8;
  --post-badge-bg: #2d6a2d;
  --topics-card-bg: #1a4a2a;
  --authors-card-bg: #e8f0e0;
  --card-ol-start: rgba(10,26,10,.72);
  --card-ol-end: rgba(10,26,10,.22);
}

body.tone-rose {
  --site-bg: #fdf8f5;
  --sidebar-bg: #ffffff;
  --sidebar-border: #f0ddd5;
  --ink: #2a1a18;
  --ink-muted: #8a6a62;
  --ink-soft: #f5e8e2;
  --post-badge-bg: #b5634a;
  --topics-card-bg: #7a3a2a;
  --authors-card-bg: #fce8e2;
  --card-ol-start: rgba(42,20,18,.72);
  --card-ol-end: rgba(42,20,18,.22);
}

body.tone-gray {
  --site-bg: #f4f5f7;
  --sidebar-bg: #ffffff;
  --sidebar-border: #e0e5ee;
  --ink: #1e2433;
  --ink-muted: #6b7585;
  --ink-soft: #e4e8f0;
  --post-badge-bg: #2d3a50;
  --topics-card-bg: #2d3a50;
  --authors-card-bg: #eaedf3;
  --card-ol-start: rgba(18,24,40,.72);
  --card-ol-end: rgba(18,24,40,.22);
}

body.tone-amber {
  --site-bg: #fffbf2;
  --sidebar-bg: #ffffff;
  --sidebar-border: #eedfa8;
  --ink: #221a06;
  --ink-muted: #8a7040;
  --ink-soft: #f5edce;
  --post-badge-bg: #7a5500;
  --topics-card-bg: #5a3e00;
  --authors-card-bg: #fef5d8;
  --card-ol-start: rgba(34,26,6,.72);
  --card-ol-end: rgba(34,26,6,.22);
}

a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; height: 100%; object-fit: cover; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
ul { list-style: none; }

/* ─── SIDEBAR ────────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  min-height: 100vh;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--sidebar-border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0;
  z-index: 100;
  overflow-y: auto;
  transition: transform var(--transition);
}

.sidebar-logo {
  padding: 20px 18px 16px;
  border-bottom: 1px solid var(--sidebar-border);
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
}
.sidebar-brand img { max-width: 130px; max-height: 40px; object-fit: contain; }

.logo-mark {
  width: 34px; height: 34px;
  border-radius: 9px;
  color: var(--sidebar-bg);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-serif);
  font-size: 0; font-weight: 700; font-style: italic;
  flex-shrink: 0;
}

.logo-mark::first-letter { font-size: 18px; }

.logo-mark-img {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
}

.logo-name {
  font-family: var(--font-serif);
  font-size: 18px; font-weight: 700; font-style: italic;
  letter-spacing: -.3px; line-height: 1;
  color: var(--ink);
}

.sidebar-nav { padding: 12px 10px; flex: 1; }

.sidebar-nav-list li a {
  display: flex; align-items: center;
  gap: 9px;
  padding: 8px 12px;
  border-radius: 9px;
  font-size: 13px; font-weight: 500;
  color: var(--ink-muted);
  transition: background var(--transition), color var(--transition);
}
.sidebar-nav-list li a:hover,
.sidebar-nav-list li.nav-current a {
  background: var(--site-bg);
  color: var(--ink);
  font-weight: 600;
}

/* Ghost injects <li class="nav-current"> on the active link */
.sidebar-nav-list li.nav-current > a { font-weight: 700; }

.sidebar-section-label {
  font-size: 10px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--ink-muted);
  padding: 14px 12px 5px;
}

.sidebar-tag-list li a {
  display: flex; align-items: center; gap: 9px;
  padding: 6px 12px; border-radius: 9px;
  font-size: 13px; font-weight: 500; color: var(--ink-muted);
  transition: background var(--transition);
}
.sidebar-tag-list li a:hover { background: var(--site-bg); }

.tag-dot {
  width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0;
}

.sidebar-footer {
  padding: 14px 18px;
  border-top: 1px solid var(--sidebar-border);
  font-size: 11px; color: var(--ink-muted);
}

.sidebar-social {
  display: flex; gap: 10px; margin-bottom: 8px;
}
.sidebar-social a {
  width: 28px; height: 28px; border-radius: 7px;
  border: 1px solid var(--sidebar-border);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: var(--ink-muted);
  transition: border-color var(--transition), color var(--transition);
}
.sidebar-social a:hover { border-color: var(--ink-muted); color: var(--ink); }
.sidebar-social:empty { display: none; }

/* ─── LAYOUT SHELL ───────────────────────────────────────────────── */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

/* ─── TOPBAR ─────────────────────────────────────────────────────── */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--site-bg) 92%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--sidebar-border);
  display: flex; align-items: center; gap: 10px;
  padding: 0 20px; height: 52px;
}

.hamburger {
  display: none;
  width: 36px; height: 36px;
  border-radius: 8px;
  align-items: center; justify-content: center;
  flex-direction: column; gap: 5px;
  background: color-mix(in srgb, var(--ink) 8%, var(--site-bg));
}
.hamburger span {
  display: block; width: 16px; height: 2px;
  border-radius: 2px; background: var(--ink);
  transition: transform .2s, opacity .2s;
}

.topic-filter {
  display: flex; align-items: center; gap: 2px;
  overflow-x: auto; scrollbar-width: none; flex: 1;
}
.topic-filter::-webkit-scrollbar { display: none; }

.topic-btn {
  padding: 5px 13px; border-radius: 20px;
  font-size: 12.5px; font-weight: 500; color: var(--ink-muted);
  white-space: nowrap;
  transition: background var(--transition), color var(--transition);
}
.topic-btn:hover { background: var(--sidebar-border); color: var(--ink); }
.topic-btn.active { background: var(--ink); color: var(--sidebar-bg); }

.topbar-right,
.topbar-member {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-search {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--ink) 8%, var(--site-bg));
  color: var(--ink); font-size: 18px;
  transition: background var(--transition);
}
.btn-search:hover { background: color-mix(in srgb, var(--ink) 14%, var(--site-bg)); }

.btn-account,
.btn-signin,
.btn-signup {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border-radius: 18px;
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  letter-spacing: .01em;
  transition: background var(--transition), border-color var(--transition), color var(--transition), transform var(--transition);
}
.btn-account,
.btn-signin {
  background: color-mix(in srgb, var(--ink) 8%, var(--site-bg));
  color: var(--ink);
  border: 1px solid color-mix(in srgb, var(--ink) 10%, var(--site-bg));
}
.btn-account:hover,
.btn-signin:hover {
  background: color-mix(in srgb, var(--ink) 13%, var(--site-bg));
  border-color: color-mix(in srgb, var(--ink) 20%, var(--site-bg));
}
.btn-signup {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--ink) 92%, var(--brand)), var(--ink));
  color: var(--sidebar-bg);
  border: 1px solid var(--ink);
  box-shadow: 5px 5px 0 color-mix(in srgb, var(--brand) 50%, transparent);
}
.btn-signup:hover {
  background: var(--ink);
  border-color: color-mix(in srgb, var(--ink) 90%, var(--brand));
  transform: translateY(-1px);
}

.auth-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  place-items: center;
  padding: 24px;
}
.auth-modal.open {
  display: grid;
}
.auth-modal-open {
  overflow: hidden;
}
.auth-modal-backdrop {
  position: absolute;
  inset: 0;
  background: color-mix(in srgb, var(--ink) 58%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.auth-dialog {
  position: relative;
  z-index: 1;
  width: min(860px, 100%);
  min-height: 520px;
  display: grid;
  grid-template-columns: .92fr 1fr;
  overflow: hidden;
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius-lg);
  background: var(--sidebar-bg);
  box-shadow: 0 30px 90px rgba(0,0,0,.28);
}
.auth-close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 3;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--ink) 12%, transparent);
  border-radius: 50%;
  background: color-mix(in srgb, var(--sidebar-bg) 88%, transparent);
  color: var(--ink);
  font-size: 20px;
  line-height: 1;
}
.auth-art {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 34px;
  color: #fff;
  background:
    linear-gradient(to top, rgba(0,0,0,.82), rgba(0,0,0,.22) 62%, rgba(0,0,0,.04)),
    radial-gradient(circle at 22% 18%, color-mix(in srgb, var(--brand) 65%, transparent), transparent 28%),
    linear-gradient(135deg, color-mix(in srgb, var(--ink) 94%, #2f4d4a), color-mix(in srgb, var(--ink) 80%, #6f4b2f));
}
.auth-art span {
  width: fit-content;
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.auth-art strong {
  display: block;
  max-width: 300px;
  margin-top: 18px;
  font-family: var(--font-serif);
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1.02;
}
.auth-art p {
  max-width: 300px;
  margin-top: 14px;
  color: rgba(255,255,255,.76);
  font-size: 14px;
  line-height: 1.55;
}
.auth-panel {
  padding: 42px clamp(24px, 4vw, 46px);
}
.auth-tabs {
  width: fit-content;
  display: flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--sidebar-border);
  border-radius: 999px;
  background: var(--site-bg);
}
.auth-tab {
  min-height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  color: var(--ink-muted);
  font-size: 12px;
  font-weight: 800;
}
.auth-tab.active {
  background: var(--ink);
  color: var(--sidebar-bg);
}
.auth-view {
  display: none;
  margin-top: 34px;
}
.auth-view.active {
  display: block;
}
.auth-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 18%, var(--site-bg));
  color: var(--brand);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.auth-view h2 {
  margin-top: 14px;
  font-family: var(--font-serif);
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.08;
}
.auth-view p {
  max-width: 360px;
  margin-top: 12px;
  color: var(--ink-muted);
  font-size: 14px;
  line-height: 1.55;
}
.auth-form {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}
.auth-form label {
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
}
.auth-form input {
  width: 100%;
  height: 48px;
  border: 1px solid var(--sidebar-border);
  border-radius: 24px;
  background: var(--site-bg);
  color: var(--ink);
  font: inherit;
  padding: 0 16px;
  outline: none;
}
.auth-form input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent);
}
.auth-form button {
  height: 48px;
  margin-top: 6px;
  border-radius: 24px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--ink) 92%, var(--brand)), var(--ink));
  color: var(--sidebar-bg);
  font-size: 13px;
  font-weight: 900;
  box-shadow: 6px 6px 0 color-mix(in srgb, var(--brand) 50%, transparent);
}
.auth-success,
.auth-error {
  display: none;
  margin-top: 4px;
  font-size: 12px;
}
.auth-success { color: #16813a; }
.auth-error { color: #b42318; }
.auth-form.success .auth-success,
.auth-form.error .auth-error {
  display: block;
}

/* ─── HERO SECTION (creative redesign) ──────────────────────────── */
.hero-section {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
  min-height: 610px;
  gap: 18px;
  margin-bottom: -34px;
  padding: 18px 18px 58px;
  background:
    linear-gradient(to bottom, transparent calc(100% - 86px), var(--site-bg) 100%),
    linear-gradient(135deg, rgba(255,255,255,.74), rgba(255,255,255,0) 36%),
    radial-gradient(circle at 8% 18%, color-mix(in srgb, var(--brand) 28%, transparent), transparent 24%),
    linear-gradient(120deg, color-mix(in srgb, var(--ink) 92%, #2f4d4a), color-mix(in srgb, var(--ink) 88%, #6f4b2f));
  isolation: isolate;
  overflow: hidden;
  position: relative;
}

.hero-section::before {
  content: "";
  position: absolute;
  inset: 18px;
  z-index: -1;
  opacity: .26;
  background-image:
    linear-gradient(rgba(255,255,255,.16) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.16) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(90deg, #000, transparent 74%);
}

.hero-section::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  right: -76px;
  bottom: -88px;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 50%;
  box-shadow: inset 0 0 0 34px rgba(255,255,255,.04);
  pointer-events: none;
}

/* ── Big main card ── */
.hero-main-card {
  position: relative;
  overflow: hidden;
  min-height: 574px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  border-radius: 8px 34px 8px 8px;
  box-shadow: 0 28px 70px rgba(0,0,0,.26);
  clip-path: polygon(0 0, 96% 0, 100% 9%, 100% 100%, 0 100%);
}

.hmc-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  filter: saturate(1.05) contrast(1.02);
  transform: scale(1.01);
  transition: transform .7s cubic-bezier(.25,.46,.45,.94), filter .7s ease;
}
.hero-main-card:hover .hmc-bg {
  filter: saturate(1.18) contrast(1.05);
  transform: scale(1.06);
}

/* multi-layer veil: dark at bottom, slight color tint at top */
.hmc-veil {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(5,5,5,.86) 0%, rgba(7,7,7,.58) 42%, rgba(7,7,7,.08) 78%),
    linear-gradient(to top, rgba(5,5,5,.92) 0%, rgba(5,5,5,.44) 43%, rgba(5,5,5,.06) 100%),
    radial-gradient(circle at 84% 18%, color-mix(in srgb, var(--brand) 46%, transparent), transparent 30%);
  pointer-events: none;
}

/* thin brand-colored vertical accent bar on the left edge */
.hmc-accent-bar {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  width: 86px;
  height: 86px;
  border-top: 2px solid rgba(255,255,255,.86);
  border-left: 2px solid rgba(255,255,255,.86);
  border-radius: 8px 0 0 0;
  opacity: .86;
}

.hmc-accent-bar::after {
  content: "";
  position: absolute;
  left: -2px;
  top: 22px;
  width: 2px;
  height: 120px;
  background: linear-gradient(to bottom, var(--brand), transparent);
}

.hmc-body {
  position: relative; z-index: 3;
  padding: 0 clamp(24px, 4.4vw, 62px) clamp(28px, 4.5vw, 58px);
  color: #fff;
  max-width: 760px;
}

.hmc-eyebrow {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.hmc-tag {
  display: inline-flex; align-items: center;
  padding: 5px 11px; border-radius: 999px;
  background: #fff; color: var(--ink);
  font-size: 10px; font-weight: 800;
  letter-spacing: .08em; text-transform: uppercase;
  box-shadow: 0 8px 24px rgba(0,0,0,.22);
  transition: transform var(--transition), background var(--transition);
}
.hmc-tag:hover { background: var(--brand); transform: translateY(-1px); }

.hmc-reading-time {
  font-size: 10px; font-weight: 700; color: rgba(255,255,255,.7);
  letter-spacing: .06em; text-transform: uppercase;
}

.hmc-title {
  font-family: var(--font-serif);
  font-size: clamp(34px, 5.4vw, 82px);
  line-height: .94; font-weight: 700; margin-bottom: 18px;
  text-wrap: balance;
  max-width: 720px;
}
.hmc-title a { color: #fff; transition: opacity var(--transition); }
.hmc-title a:hover { opacity: .85; }

.hmc-excerpt {
  font-size: 14px; line-height: 1.68;
  color: rgba(255,255,255,.78);
  max-width: 500px; margin-bottom: 26px; font-weight: 500;
}

.hmc-footer {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  max-width: 610px;
}

.hmc-author-row {
  display: flex; align-items: center; gap: 9px;
  min-width: 0;
}
.hmc-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  object-fit: cover; border: 2px solid rgba(255,255,255,.58);
  flex-shrink: 0;
}
.hmc-by {
  font-size: 12px; font-weight: 600; color: rgba(255,255,255,.88);
}
.hmc-date {
  font-size: 11px; color: rgba(255,255,255,.5); font-weight: 400;
}
.hmc-date::before { content: '·'; margin-right: 9px; }

.hmc-cta {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.55);
  background: rgba(255,255,255,.18);
  backdrop-filter: blur(12px);
  color: #fff; font-size: 12px; font-weight: 800;
  white-space: nowrap;
  box-shadow: 0 14px 30px rgba(0,0,0,.24);
  transition: background var(--transition), border-color var(--transition), transform var(--transition);
}
.hmc-cta:hover { background: #fff; border-color: #fff; color: var(--ink); transform: translateY(-2px); }
.hmc-cta-arrow { display: inline-block; transition: transform var(--transition); }
.hmc-cta:hover .hmc-cta-arrow { transform: translateX(4px); }

/* large faded post index number, bottom-right corner */
.hmc-index {
  position: absolute; top: 24px; right: 24px; z-index: 1;
  width: 74px;
  height: 74px;
  border: 1px solid rgba(255,255,255,.34);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--font-serif); font-size: 26px; font-weight: 700; font-style: italic;
  line-height: 1; color: rgba(255,255,255,.72);
  background: rgba(0,0,0,.16);
  backdrop-filter: blur(8px);
  pointer-events: none; user-select: none;
}

/* ── Side stack ── */
.hero-side-stack {
  display: flex; flex-direction: column;
  gap: 12px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  padding: 12px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.1);
  counter-reset: hero-side;
}

.hss-card {
  position: relative;
  display: grid; grid-template-columns: 118px 1fr;
  align-items: center; gap: 0;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 8px;
  flex: 1;
  overflow: hidden;
  background: color-mix(in srgb, var(--site-bg) 93%, transparent);
  box-shadow: 0 16px 34px rgba(0,0,0,.12);
  transition: background var(--transition), transform var(--transition), border-color var(--transition);
  min-height: 0;
  counter-increment: hero-side;
}
.hss-card::before {
  content: "0" counter(hero-side);
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 1;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,.88);
  color: var(--ink);
  font-family: var(--font-serif);
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(0,0,0,.16);
}
.hss-card:hover {
  background: #fff;
  border-color: rgba(255,255,255,.36);
  transform: translateX(-5px);
}

.hss-img-wrap {
  height: 100%; min-height: 112px;
  overflow: hidden; flex-shrink: 0;
  clip-path: polygon(0 0, 100% 0, 88% 100%, 0 100%);
}
.hss-img-wrap img,
.hss-img-fallback {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.hss-card:hover .hss-img-wrap img,
.hss-card:hover .hss-img-fallback { transform: scale(1.07); }

.hss-body {
  padding: 16px 18px 16px 12px;
  display: flex; flex-direction: column; gap: 5px;
  min-width: 0;
  position: relative;
  z-index: 3;
}

.hss-tag {
  font-size: 9.5px; font-weight: 800; letter-spacing: .08em;
  text-transform: uppercase; color: var(--brand);
}

.hss-title {
  font-size: 13.5px; font-weight: 800; line-height: 1.34;
}
.hss-title a { color: var(--ink); transition: color var(--transition); }
.hss-title a:hover { color: var(--brand); }

.hss-meta {
  font-size: 10.5px; color: var(--ink-muted); font-weight: 400;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* scrolling ticker strip at bottom of side stack */
.hero-ticker {
  height: 38px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 8px;
  overflow: hidden; display: flex; align-items: center;
  background: rgba(0,0,0,.42); flex-shrink: 0;
  backdrop-filter: blur(12px);
}
.hero-ticker span {
  display: inline-block; white-space: nowrap;
  font-size: 10px; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; color: rgba(255,255,255,.45);
  padding: 0 10px;
  animation: ticker 18s linear infinite;
}
.hero-ticker span:nth-child(odd) { color: rgba(255,255,255,.7); }

@keyframes ticker {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.hmc-body a,
.hss-body a,
.hmc-tag,
.hmc-cta {
  position: relative;
  z-index: 4;
}

/* alternate hero style: bright studio collage */
.hero-style-studio {
  grid-template-columns: minmax(0, 1fr) minmax(340px, .58fr);
  gap: 22px;
  min-height: 640px;
  padding: 24px 24px 64px;
  background:
    linear-gradient(to bottom, transparent calc(100% - 92px), var(--site-bg) 100%),
    linear-gradient(90deg, rgba(26,26,26,.08) 1px, transparent 1px),
    linear-gradient(rgba(26,26,26,.08) 1px, transparent 1px),
    linear-gradient(135deg, var(--studio-paper) 0%, #f7f6f3 42%, #e8f2ef 100%);
  background-size: auto, 28px 28px, 28px 28px, auto;
}

.hero-style-studio::before {
  inset: 24px;
  opacity: 1;
  background:
    linear-gradient(110deg, transparent 0 56%, rgba(26,26,26,.09) 56% 56.35%, transparent 56.35%),
    linear-gradient(25deg, rgba(255,255,255,.72), transparent 58%);
  background-size: auto;
  mask-image: none;
}

.hero-style-studio::after {
  width: 170px;
  height: 170px;
  right: 34%;
  bottom: 42px;
  border-color: color-mix(in srgb, var(--brand) 62%, transparent);
  border-radius: 26px;
  box-shadow: none;
  transform: rotate(12deg);
}

.hero-style-studio .hero-main-card {
  min-height: 592px;
  justify-content: flex-end;
  border: 1px solid rgba(26,26,26,.12);
  border-radius: 10px;
  clip-path: none;
  background:
    linear-gradient(180deg, rgba(255,255,255,.76), rgba(255,255,255,.96)),
    var(--site-bg);
  box-shadow: 14px 14px 0 rgba(26,26,26,.1), 0 24px 56px rgba(26,26,26,.14);
}

.hero-style-studio .hero-main-card::before,
.hero-style-studio .hero-main-card::after {
  content: "";
  position: absolute;
  z-index: 2;
  pointer-events: none;
}

.hero-style-studio .hero-main-card::before {
  top: 18px;
  left: 50%;
  width: 82px;
  height: 24px;
  background: color-mix(in srgb, var(--brand) 72%, #fff);
  opacity: .82;
  transform: translateX(-50%) rotate(-4deg);
  box-shadow: 0 8px 18px rgba(26,26,26,.12);
}

.hero-style-studio .hero-main-card::after {
  right: 22px;
  top: 72px;
  width: 92px;
  height: 92px;
  border: 1px solid rgba(26,26,26,.18);
  border-radius: 50%;
  background:
    linear-gradient(90deg, transparent 48%, rgba(26,26,26,.14) 48% 52%, transparent 52%),
    linear-gradient(transparent 48%, rgba(26,26,26,.14) 48% 52%, transparent 52%);
}

.hero-style-studio .hmc-bg {
  inset: 24px 24px 196px 24px;
  border: 1px solid rgba(26,26,26,.16);
  border-radius: 8px;
  box-shadow: 0 20px 36px rgba(26,26,26,.18);
  filter: saturate(.92) contrast(1.04);
  transform: rotate(-1.2deg) scale(1);
}

.hero-style-studio .hero-main-card:hover .hmc-bg {
  filter: saturate(1.04) contrast(1.06);
  transform: rotate(0deg) scale(1.02);
}

.hero-style-studio .hmc-veil {
  inset: 24px 24px 196px 24px;
  border-radius: 8px;
  background:
    linear-gradient(to top, rgba(0,0,0,.28), rgba(0,0,0,.02) 62%),
    repeating-linear-gradient(90deg, rgba(255,255,255,.12) 0 1px, transparent 1px 5px);
}

.hero-style-studio .hmc-accent-bar {
  top: auto;
  left: auto;
  right: 34px;
  bottom: 164px;
  width: 116px;
  height: 28px;
  border: 0;
  border-radius: 999px;
  background: var(--studio-ink);
  opacity: 1;
  transform: rotate(4deg);
}

.hero-style-studio .hmc-accent-bar::before {
  content: "Featured";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.hero-style-studio .hmc-accent-bar::after { display: none; }

.hero-style-studio .hmc-body {
  max-width: none;
  color: var(--studio-ink);
  padding: 0 clamp(22px, 3.8vw, 46px) 30px;
}

.hero-style-studio .hmc-eyebrow {
  margin-bottom: 10px;
}

.hero-style-studio .hmc-tag {
  background: var(--studio-ink);
  color: #fff;
  box-shadow: none;
}

.hero-style-studio .hmc-tag:hover {
  background: var(--brand);
  color: var(--studio-ink);
}

.hero-style-studio .hmc-reading-time {
  color: var(--studio-muted);
}

.hero-style-studio .hmc-title {
  max-width: 850px;
  font-family: var(--font-head);
  font-size: clamp(34px, 4.9vw, 72px);
  line-height: .92;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-style-studio .hmc-title a {
  color: var(--studio-ink);
}

.hero-style-studio .hmc-excerpt {
  max-width: 560px;
  margin-bottom: 20px;
  color: var(--studio-muted);
}

.hero-style-studio .hmc-by {
  color: var(--studio-ink);
}

.hero-style-studio .hmc-date {
  color: var(--studio-muted);
}

.hero-style-studio .hmc-avatar {
  border-color: #fff;
  box-shadow: 0 4px 14px rgba(26,26,26,.18);
}

.hero-style-studio .hmc-cta {
  border-color: var(--studio-ink);
  background: var(--studio-ink);
  color: #fff;
  box-shadow: 6px 6px 0 color-mix(in srgb, var(--brand) 70%, transparent);
}

.hero-style-studio .hmc-cta:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--studio-ink);
  transform: translate(-2px, -2px);
}

.hero-style-studio .hmc-index {
  top: 34px;
  left: 34px;
  right: auto;
  width: auto;
  height: auto;
  padding: 8px 12px;
  border: 1px solid rgba(26,26,26,.18);
  border-radius: 999px;
  background: rgba(255,255,255,.84);
  color: var(--studio-ink);
  font-family: var(--font-head);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
  letter-spacing: .12em;
}

.hero-style-studio .hero-side-stack {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.hero-style-studio .hss-card {
  display: flex;
  min-height: 0;
  border: 1px solid rgba(26,26,26,.12);
  border-radius: 10px;
  background: rgba(255,255,255,.9);
  box-shadow: 8px 8px 0 rgba(26,26,26,.08);
}

.hero-style-studio .hss-card:nth-child(odd) {
  transform: rotate(1.5deg);
}

.hero-style-studio .hss-card:nth-child(even) {
  transform: rotate(-1.2deg);
}

.hero-style-studio .hss-card:hover {
  background: #fff;
  transform: translateY(-5px) rotate(0deg);
  border-color: rgba(26,26,26,.22);
}

.hero-style-studio .hss-card::before {
  top: 8px;
  left: 8px;
  width: 28px;
  height: 28px;
  background: var(--brand);
  color: var(--studio-ink);
  border: 1px solid rgba(26,26,26,.18);
  box-shadow: none;
}

.hero-style-studio .hss-img-wrap {
  width: 100%;
  height: 46%;
  min-height: 116px;
  clip-path: none;
  border-bottom: 1px solid rgba(26,26,26,.1);
}

.hero-style-studio .hss-body {
  padding: 14px;
}

.hero-style-studio .hss-title {
  font-size: 14px;
  line-height: 1.22;
}

.hero-style-studio .hss-title a {
  color: var(--studio-ink);
}

.hero-style-studio .hss-tag {
  color: #6a4a00;
}

.hero-style-studio .hss-meta {
  color: var(--studio-muted);
}

.hero-style-studio .hero-ticker {
  grid-column: 1 / -1;
  height: 42px;
  border: 1px solid rgba(26,26,26,.14);
  border-radius: 999px;
  background: var(--studio-ink);
  box-shadow: 8px 8px 0 rgba(26,26,26,.08);
}

/* tag-pill kept for backward compat on other templates */
.tag-pill {
  background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.28);
  color: #fff; font-size: 10px; font-weight: 700;
  padding: 3px 10px; border-radius: 20px; letter-spacing: .05em;
  backdrop-filter: blur(4px);
}

.card-abs-link { position: absolute; inset: 0; z-index: 2; }

/* ─── TAG PILL (small, inline) ───────────────────────────────────── */
.tag-pill-sm {
  display: inline-block; font-size: 10px; font-weight: 700;
  padding: 2px 7px; border-radius: 10px; letter-spacing: .03em;
  background: color-mix(in srgb, var(--brand) 18%, var(--site-bg));
  color: var(--brand);
}

.pill-members {
  display: inline-block; font-size: 10px; font-weight: 700;
  padding: 2px 7px; border-radius: 10px;
  background: color-mix(in srgb, #7c3aed 14%, var(--site-bg));
  color: #7c3aed;
}

/* ─── POST CARD GRID ─────────────────────────────────────────────── */
.card-grid-section {
  position: relative;
  z-index: 3;
  padding: 0 24px 8px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}
.card-grid.grid-two  { grid-template-columns: repeat(2, 1fr); }
.card-grid.grid-mixed { grid-template-columns: repeat(4, 1fr); }
.card-grid.grid-mixed .post-card:nth-child(6n+1),
.card-grid.grid-mixed .post-card:nth-child(6n+4) { grid-column: span 2; }

.post-card {
  position: relative;
  background: var(--sidebar-bg);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--sidebar-border);
  transition: box-shadow var(--transition), transform var(--transition);
}
.post-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-3px); }

.post-card-img-wrap { height: 145px; overflow: hidden; }
.post-card-img-wrap img,
.post-card-img-fallback { transition: transform .4s ease; width: 100%; height: 100%; }
.post-card:hover .post-card-img-wrap img,
.post-card:hover .post-card-img-fallback { transform: scale(1.06); }

.post-card-body { padding: 12px 14px 13px; }
.post-card-body h3 { font-size: 13px; font-weight: 600; line-height: 1.4; margin-bottom: 6px; }
.post-card-body h3 a { color: var(--ink); }
.post-card-body h3 a:hover { color: var(--brand); }

.meta { font-size: 11px; color: var(--ink-muted); display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }

/* pagination */
.pagination {
  display: flex; align-items: center; justify-content: center;
  gap: 12px; padding: 4px 0 28px;
  font-size: 13px; color: var(--ink-muted);
}
.pagination .page-number { font-weight: 600; color: var(--ink); }
.pagination a {
  padding: 7px 18px; border-radius: 20px;
  border: 1.5px solid var(--sidebar-border);
  font-size: 13px; font-weight: 600; color: var(--ink);
  transition: all var(--transition);
}
.pagination a:hover { background: var(--ink); color: var(--sidebar-bg); border-color: var(--ink); }

/* ─── SECTION HEADER ─────────────────────────────────────────────── */
.section-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px; padding: 0 24px;
}
.section-header h2 { font-size: 18px; font-weight: 700; }

.view-all-btn {
  font-size: 12px; font-weight: 600; color: var(--ink-muted);
  padding: 5px 13px; border: 1.5px solid var(--sidebar-border);
  border-radius: 18px; transition: all var(--transition);
}
.view-all-btn:hover { border-color: var(--ink-muted); color: var(--ink); }

/* ─── AUTHORS CAROUSEL ───────────────────────────────────────────── */
.authors-section { padding-bottom: 36px; }

.authors-carousel-wrap {
  position: relative; overflow: hidden; padding: 0 24px;
}

.authors-carousel {
  display: flex; gap: 16px;
  overflow-x: auto; scrollbar-width: none; scroll-behavior: smooth;
}
.authors-carousel::-webkit-scrollbar { display: none; }

.author-card {
  flex-shrink: 0; width: 160px;
  background: var(--sidebar-bg);
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius);
  padding: 18px 14px; text-align: center;
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex; flex-direction: column; align-items: center;
}
.author-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-3px); }

.author-card img {
  width: 64px; height: 64px; border-radius: 50%;
  object-fit: cover; margin-bottom: 10px;
  border: 3px solid var(--site-bg);
  box-shadow: 0 2px 8px rgba(0,0,0,.1);
}

.avatar-fallback {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--ink); color: var(--sidebar-bg);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-serif); font-size: 18px; font-style: italic;
  margin-bottom: 10px; flex-shrink: 0;
  overflow: hidden;
}

.author-card h4 { font-size: 12.5px; font-weight: 700; margin-bottom: 5px; }
.author-card p { font-size: 11px; color: var(--ink-muted); line-height: 1.5; font-weight: 400; }

.carousel-arrow {
  position: absolute; right: 24px; top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px;
  background: var(--sidebar-bg); border: 1.5px solid var(--sidebar-border);
  border-radius: 50%; font-size: 20px; color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow); z-index: 2;
  transition: all var(--transition);
}
.carousel-arrow:hover { background: var(--ink); color: var(--sidebar-bg); border-color: var(--ink); }

/* ─── NEWSLETTER ─────────────────────────────────────────────────── */
.newsletter-section {
  margin: 4px 24px 36px;
  background: linear-gradient(120deg, var(--ink) 0%, color-mix(in srgb, var(--ink) 75%, #334) 100%);
  border-radius: var(--radius-lg);
  padding: 36px 42px;
  position: relative; overflow: hidden;
}

.newsletter-inner {
  display: flex; align-items: center;
  justify-content: space-between; gap: 28px;
  position: relative; z-index: 1;
}

.newsletter-text h3 {
  font-family: var(--font-serif);
  font-size: 20px; font-weight: 700; color: #fff; margin-bottom: 6px;
}
.newsletter-text p { font-size: 13px; color: rgba(255,255,255,.62); max-width: 320px; font-weight: 400; }

.newsletter-form { display: flex; gap: 8px; flex-shrink: 0; }

.newsletter-input {
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.1); color: #fff;
  padding: 9px 16px; border-radius: 22px;
  font-size: 12.5px; font-family: inherit;
  width: 220px; transition: border-color var(--transition);
}
.newsletter-input::placeholder { color: rgba(255,255,255,.4); }
.newsletter-input:focus { outline: none; border-color: rgba(255,255,255,.38); }

.newsletter-btn {
  background: var(--brand); color: #fff;
  padding: 9px 20px; border-radius: 22px;
  font-size: 12.5px; font-weight: 700; font-family: inherit;
  border: none; cursor: pointer;
  transition: filter var(--transition);
}
.newsletter-btn:hover { filter: brightness(1.1); }

.nl-success, .nl-error { display: none; font-size: 11px; color: rgba(255,255,255,.7); margin-top: 6px; }

/* decorative circle */
.newsletter-deco {
  position: absolute; top: -60px; right: -60px;
  width: 240px; height: 240px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.07); pointer-events: none;
}
.newsletter-deco::after {
  content: ''; position: absolute; top: 28px; left: 28px; right: 28px; bottom: 28px;
  border-radius: 50%; border: 1px solid rgba(255,255,255,.05);
}

/* ─── TAG SECTIONS ───────────────────────────────────────────────── */
.tag-section { padding: 0 24px 44px; }

.tag-section-header {
  display: flex; align-items: flex-start;
  justify-content: space-between; margin-bottom: 18px;
}
.tag-section-header h2 {
  font-family: var(--font-serif);
  font-size: 19px; font-weight: 700;
  display: flex; align-items: center; gap: 8px; margin-bottom: 5px;
}
.tag-dot-lg { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.tag-section-header p { font-size: 12px; color: var(--ink-muted); max-width: 440px; line-height: 1.55; font-weight: 400; }

.mini-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 12px;
  align-items: start;
}

.mini-card {
  position: relative;
  background: var(--sidebar-bg); border-radius: var(--radius);
  overflow: hidden; border: 1px solid var(--sidebar-border);
  transition: box-shadow var(--transition), transform var(--transition);
}
.mini-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }

.mini-card img,
.mini-card-img-fallback { height: 130px; width: 100%; object-fit: cover; transition: transform .4s ease; }
.mini-card:hover img,
.mini-card:hover .mini-card-img-fallback { transform: scale(1.06); }
.featured-mini img,
.featured-mini .mini-card-img-fallback { height: 190px; }

.mini-card-body { padding: 10px 12px 11px; }
.mini-card-body h4 { font-size: 12px; font-weight: 600; line-height: 1.4; margin-bottom: 4px; }
.mini-card-body h4 a { color: var(--ink); }
.mini-card-body h4 a:hover { color: var(--brand); }
.mini-card-body .meta { font-size: 10.5px; }

/* ─── ARCHIVE / PAGE TEMPLATES ───────────────────────────────────── */
.archive-main, .page-main {
  padding: 40px 24px 60px;
}

.archive-header {
  text-align: center; margin-bottom: 48px;
}
.archive-header > p {
  font-size: 11px; font-weight: 700; letter-spacing: 1.8px;
  text-transform: uppercase; color: var(--brand); margin-bottom: 10px;
}
.archive-header h1 {
  font-family: var(--font-serif);
  font-size: clamp(36px, 4vw, 60px); line-height: 1.08;
}
.archive-header div {
  margin: 18px auto 0; max-width: 560px;
  color: var(--ink-muted); font-size: 15px; font-weight: 400; line-height: 1.6;
}

.archive-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.archive-grid.grid-mixed .post-card:nth-child(6n+1),
.archive-grid.grid-mixed .post-card:nth-child(6n+4) { grid-column: span 2; }

/* Authors grid */
.authors-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.authors-grid .author-card {
  width: auto; padding: 24px 18px;
}
.authors-grid .author-card img { width: 76px; height: 76px; }

/* Topics grid */
.topic-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.topic-card {
  min-height: 220px; padding: 28px 24px;
  border-radius: var(--radius-lg);
  background: linear-gradient(140deg, var(--topics-card-bg), color-mix(in srgb, var(--topics-card-bg) 65%, var(--site-bg)));
  color: #fff; display: flex; flex-direction: column;
  transition: box-shadow var(--transition), transform var(--transition);
}
.topic-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-4px); }
.topic-card span { font-size: 10px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; opacity: .75; }
.topic-card h2 { margin-top: 16px; font-family: var(--font-serif); font-size: 24px; line-height: 1.15; }
.topic-card p { margin-top: 10px; font-size: 13px; font-weight: 400; line-height: 1.6; opacity: .82; flex: 1; }

/* Membership tiers */
.tiers {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
}
.tier-card {
  min-height: 220px; padding: 28px 24px;
  border-radius: var(--radius-lg);
  background: var(--authors-card-bg);
  border: 1px solid var(--sidebar-border);
  display: flex; flex-direction: column;
}
.tier-card h2 { font-family: var(--font-serif); font-size: 22px; color: var(--ink); }
.tier-card p { margin-top: 10px; font-size: 13px; color: var(--ink-muted); font-weight: 400; line-height: 1.6; }
.tier-card strong { display: block; margin-top: 14px; font-size: 20px; color: var(--ink); }
.tier-card ul { margin: 14px 0 0; padding-left: 14px; font-size: 13px; font-weight: 400; color: var(--ink-muted); line-height: 1.7; }
.tier-card > a {
  display: inline-flex; margin-top: 20px; min-height: 42px;
  align-items: center; padding: 0 20px; border-radius: 22px;
  background: var(--ink); color: var(--sidebar-bg); font-weight: 700; font-size: 13px;
  transition: filter var(--transition); width: fit-content;
}
.tier-card > a:hover { filter: brightness(1.12); }

/* Member box */
.member-box {
  padding: 40px; border-radius: var(--radius-lg);
  background: var(--authors-card-bg); text-align: center;
}
.member-box h2 { font-family: var(--font-serif); font-size: 26px; }
.member-box p { margin-top: 10px; font-size: 14px; color: var(--ink-muted); }
.member-box > a {
  display: inline-flex; margin-top: 20px; min-height: 42px;
  align-items: center; padding: 0 22px; border-radius: 22px;
  background: var(--ink); color: var(--sidebar-bg); font-weight: 700;
}

/* Contact */
.contact-page .page-header { text-align: center; margin-bottom: 36px; }
.contact-page .page-header h1 { font-family: var(--font-serif); font-size: clamp(32px, 4vw, 56px); }
.contact-page .page-header p { margin-top: 14px; font-size: 15px; color: var(--ink-muted); font-weight: 400; }
.contact-panel {
  max-width: 520px; margin: 0 auto;
  padding: 36px; border-radius: var(--radius-lg);
  background: var(--authors-card-bg); text-align: center;
}
.contact-panel p { color: var(--ink-muted); font-size: 14px; font-weight: 400; }
.contact-panel a { display: block; margin-top: 8px; font-family: var(--font-serif); font-size: 24px; color: var(--brand); }
.contact-panel a:hover { text-decoration: underline; }

/* Membership hero */
.membership-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, .9fr);
  gap: 22px;
  align-items: stretch;
  margin-bottom: 34px;
  padding: 26px;
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 88% 18%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 28%),
    linear-gradient(135deg, color-mix(in srgb, var(--sidebar-bg) 88%, var(--site-bg)), var(--site-bg));
  overflow: hidden;
}
.membership-hero-copy {
  padding: clamp(12px, 2vw, 24px);
}
.membership-hero-copy > span,
.recommendations-header > span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 20%, var(--site-bg));
  color: var(--brand);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.membership-hero h1 {
  max-width: 640px;
  margin-top: 18px;
  font-family: var(--font-serif);
  font-size: clamp(36px, 5vw, 68px);
  line-height: 1.02;
}
.membership-hero p {
  max-width: 560px;
  margin-top: 16px;
  font-size: 15px;
  color: var(--ink-muted);
  font-weight: 400;
}
.membership-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.membership-primary,
.membership-secondary {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border-radius: 24px;
  font-size: 13px;
  font-weight: 800;
  transition: background var(--transition), border-color var(--transition), color var(--transition), transform var(--transition);
}
.membership-primary {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--ink) 92%, var(--brand)), var(--ink));
  color: var(--sidebar-bg);
  box-shadow: 8px 8px 0 color-mix(in srgb, var(--brand) 55%, transparent);
}
.membership-secondary {
  border: 1px solid var(--sidebar-border);
  background: color-mix(in srgb, var(--sidebar-bg) 82%, transparent);
  color: var(--ink);
}
.membership-primary:hover,
.membership-secondary:hover,
.members-cta-primary:hover,
.members-cta-secondary:hover,
.auth-switch-panel > a:hover {
  transform: translateY(-2px);
}
.membership-card-preview {
  display: flex;
  align-items: flex-end;
  min-height: 280px;
  padding: 18px;
  border-radius: 12px;
  background:
    linear-gradient(to top, rgba(0,0,0,.82), rgba(0,0,0,.2) 58%, transparent),
    radial-gradient(circle at 25% 20%, color-mix(in srgb, var(--brand) 58%, transparent), transparent 24%),
    linear-gradient(135deg, color-mix(in srgb, var(--ink) 92%, #384b48), color-mix(in srgb, var(--ink) 72%, #71552f));
  color: #fff;
  box-shadow: var(--shadow);
}
.membership-card-preview div {
  max-width: 300px;
}
.membership-card-preview small {
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--brand) 75%, #fff);
}
.membership-card-preview strong {
  display: block;
  margin-top: 10px;
  font-family: var(--font-serif);
  font-size: 30px;
  line-height: 1.08;
}
.membership-card-preview span {
  display: block;
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.5;
  opacity: .82;
}

.auth-switch-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: -12px 0 34px;
  padding: 16px 18px 16px 22px;
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--sidebar-bg) 88%, var(--site-bg));
  box-shadow: var(--shadow);
}
.auth-switch-panel strong,
.auth-switch-panel span {
  display: block;
}
.auth-switch-panel strong {
  font-family: var(--font-serif);
  font-size: 20px;
  line-height: 1.15;
}
.auth-switch-panel span {
  margin-top: 4px;
  color: var(--ink-muted);
  font-size: 13px;
  line-height: 1.45;
}
.auth-switch-panel > a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  padding: 0 18px;
  border: 1px solid var(--sidebar-border);
  border-radius: 22px;
  background: var(--site-bg);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  transition: transform var(--transition), background var(--transition), border-color var(--transition);
}

.recommendations-page {
  max-width: 980px;
  margin: 0 auto;
}
.recommendations-header {
  margin-bottom: 28px;
}
.recommendations-header h1 {
  margin-top: 16px;
}
.recommendations-panel {
  padding: 26px;
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius-lg);
  background: var(--sidebar-bg);
  box-shadow: var(--shadow);
}
.recommendation-favicon {
	max-width: 100px;
}
/* ─── POST TEMPLATE ──────────────────────────────────────────────── */
.post-main { padding-bottom: 60px; }

.post-hero {
  width: 100%; min-height: 620px;
  display: grid; place-items: center;
  background-size: cover; background-position: center;
  color: #fff; overflow: hidden;
}
.post-hero.has-color {
  background: linear-gradient(140deg, var(--brand), #ffc66b) !important;
}
.post-hero-inner { width: min(680px, calc(100% - 48px)); text-align: center; }

.post-tag-badge {
  display: inline-flex; align-items: center;
  min-height: 22px; padding: 0 12px; border-radius: 12px;
  background: var(--post-badge-bg); color: #fff;
  font-size: 10px; font-weight: 700; letter-spacing: 1px;
  text-transform: uppercase; margin-bottom: 22px;
}
.post-hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(32px, 3.8vw, 58px); line-height: 1.12;
}
.post-meta {
  margin-top: 22px; display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: 16px;
  color: rgba(255,255,255,.86); font-size: 13px; font-weight: 500;
}
.reading-time { letter-spacing: 1px; text-transform: uppercase; }

.post-content-wrap {
  position: relative; z-index: 2; clear: both;
  width: min(1060px, calc(100% - 48px));
  margin: -52px auto 0; padding: 66px 0 110px;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  background: var(--site-bg);
}
.gh-content {
  display: block; width: min(620px, calc(100% - 48px));
  margin: 0 auto;
  color: var(--ink); font-family: Arial, Helvetica, sans-serif;
  font-weight: 400; font-size: 18px; line-height: 1.7;
}
.gh-content > * + * { margin-top: 1.4em; }
.gh-content h2, .gh-content h3 {
  color: var(--ink); font-family: var(--font-head); font-weight: 700; line-height: 1.2;
}
.gh-content a { color: var(--brand); text-decoration: underline; }
.gh-content img { border-radius: var(--radius); }

.kg-width-wide {
  width: min(880px, calc(100vw - 48px));
  max-width: none; margin-left: 50%; transform: translateX(-50%);
}
.kg-width-full {
  width: 100vw; max-width: none; margin-left: 50%; transform: translateX(-50%);
}

.members-cta {
  width: min(580px, calc(100% - 48px));
  margin: 56px auto 0;
  padding: 38px 36px 34px;
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius-lg);
  color: var(--ink);
  text-align: center;
  background:
    radial-gradient(circle at 12% 18%, color-mix(in srgb, var(--brand) 24%, transparent), transparent 28%),
    linear-gradient(135deg, color-mix(in srgb, var(--sidebar-bg) 86%, var(--site-bg)), var(--site-bg));
  box-shadow: var(--shadow);
}
.members-cta > span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 20%, var(--site-bg));
  color: var(--brand);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.members-cta h2 {
  margin-top: 14px;
  font-family: var(--font-serif);
  font-size: 30px;
  line-height: 1.12;
}
.members-cta p {
  margin: 14px auto 0;
  max-width: 420px;
  color: var(--ink-muted);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
}
.members-cta-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}
.members-cta-primary,
.members-cta-secondary {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border-radius: 24px;
  font-size: 13px;
  font-weight: 800;
  transition: transform var(--transition), background var(--transition), border-color var(--transition);
}
.members-cta-primary {
  background: var(--ink);
  color: var(--sidebar-bg);
  box-shadow: 6px 6px 0 color-mix(in srgb, var(--brand) 50%, transparent);
}
.members-cta-secondary {
  border: 1px solid var(--sidebar-border);
  background: color-mix(in srgb, var(--sidebar-bg) 82%, transparent);
  color: var(--ink);
}

.post-action-shell {
  width: min(620px, calc(100% - 48px));
  margin: -34px auto 34px;
  position: relative;
  z-index: 4;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  padding: 14px 10px 12px;
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--sidebar-bg) 96%, var(--site-bg)), var(--sidebar-bg));
  box-shadow: 0 16px 36px rgba(0,0,0,.08);
}
.post-action-btn {
  display: grid;
  justify-items: center;
  gap: 7px;
  min-width: 0;
  padding: 2px 6px;
  color: var(--ink-muted);
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.2;
  transition: color var(--transition), transform var(--transition);
}
.post-action-btn:hover,
.post-action-btn.active {
  color: var(--ink);
  transform: translateY(-2px);
}
.post-action-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--ink) 10%, var(--site-bg));
  border-radius: 50%;
  background: var(--site-bg);
  color: currentColor;
  transition: background var(--transition), border-color var(--transition), color var(--transition);
}
.post-action-btn.active .post-action-icon {
  border-color: color-mix(in srgb, var(--brand) 45%, var(--sidebar-border));
  background: color-mix(in srgb, var(--brand) 14%, var(--site-bg));
  color: var(--brand);
}
.post-action-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.post-share-modal,
.post-comment-modal {
  position: fixed;
  inset: 0;
  z-index: 210;
  display: none;
  place-items: center;
  padding: 24px;
}
.post-share-modal.open,
.post-comment-modal.open {
  display: grid;
}
.post-modal-open {
  overflow: hidden;
}
.post-modal-backdrop {
  position: absolute;
  inset: 0;
  background: color-mix(in srgb, var(--ink) 56%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.post-share-dialog,
.post-comment-dialog {
  position: relative;
  z-index: 1;
  width: min(520px, 100%);
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius-lg);
  background: var(--sidebar-bg);
  box-shadow: 0 28px 80px rgba(0,0,0,.24);
}
.post-share-dialog {
  padding: 24px;
}
.post-comment-dialog {
  width: min(760px, 100%);
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  padding: 28px;
}
.post-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--sidebar-border);
  border-radius: 50%;
  background: var(--site-bg);
  color: var(--ink);
  font-size: 20px;
  line-height: 1;
}
.post-share-dialog h2,
.post-comment-dialog h2 {
  padding-right: 42px;
  font-size: 18px;
  line-height: 1.2;
}
.share-preview {
  overflow: hidden;
  margin-top: 18px;
  border: 1px solid var(--sidebar-border);
  border-radius: 10px;
  background: var(--site-bg);
}
.share-preview img {
  height: 166px;
}
.share-preview-body {
  padding: 16px;
}
.share-preview-body h3 {
  font-size: 17px;
  line-height: 1.25;
}
.share-preview-body p {
  margin-top: 8px;
  color: var(--ink-muted);
  font-size: 13px;
  line-height: 1.45;
}
.share-preview-body small {
  display: block;
  margin-top: 12px;
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
}
.share-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) repeat(4, 44px);
  gap: 10px;
  margin-top: 14px;
}
.share-actions a,
.share-actions button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--sidebar-border);
  border-radius: 9px;
  background: var(--site-bg);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}
.share-copy {
  gap: 8px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--ink) 92%, var(--brand)), var(--ink)) !important;
  color: var(--sidebar-bg) !important;
  border-color: var(--ink) !important;
  box-shadow: 5px 5px 0 color-mix(in srgb, var(--brand) 48%, transparent);
}
.post-comments-panel {
  margin-top: 20px;
}
.discussion-heading {
  padding-right: 42px;
}
.discussion-heading > span,
.discussion-auth-card > span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 18%, var(--site-bg));
  color: var(--brand);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.discussion-heading h2 {
  margin-top: 12px;
  padding-right: 0;
  font-family: var(--font-serif);
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.08;
}
.discussion-heading p {
  max-width: 520px;
  margin-top: 10px;
  color: var(--ink-muted);
  font-size: 14px;
  line-height: 1.55;
}
.discussion-auth-card {
  padding: 28px;
  border: 1px solid var(--sidebar-border);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 90% 12%, color-mix(in srgb, var(--brand) 18%, transparent), transparent 26%),
    linear-gradient(135deg, color-mix(in srgb, var(--sidebar-bg) 90%, var(--site-bg)), var(--site-bg));
  box-shadow: var(--shadow);
}
.discussion-auth-card h3 {
  margin-top: 14px;
  font-family: var(--font-serif);
  font-size: 30px;
  line-height: 1.1;
}
.discussion-auth-card p {
  max-width: 440px;
  margin-top: 10px;
  color: var(--ink-muted);
  font-size: 14px;
  line-height: 1.55;
}
.discussion-auth-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}
.discussion-auth-primary,
.discussion-auth-secondary {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 22px;
  border-radius: 24px;
  font-size: 13px;
  font-weight: 900;
  transition: transform var(--transition), background var(--transition), border-color var(--transition);
}
.discussion-auth-primary {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--ink) 92%, var(--brand)), var(--ink));
  color: var(--sidebar-bg);
  border: 1px solid var(--ink);
  box-shadow: 6px 6px 0 color-mix(in srgb, var(--brand) 48%, transparent);
}
.discussion-auth-secondary {
  border: 1px solid var(--sidebar-border);
  background: color-mix(in srgb, var(--sidebar-bg) 84%, transparent);
  color: var(--ink);
}
.discussion-auth-primary:hover,
.discussion-auth-secondary:hover {
  transform: translateY(-2px);
}

.next-post-card {
  display: flex; flex-direction: column; align-items: flex-end; justify-content: center;
  padding: 36px 52px;
  min-height: 200px; margin: -2px 0 0;
  color: #fff; text-align: right;
  background-size: cover; background-position: center;
  transition: filter var(--transition);
}
.next-post-card:hover { filter: brightness(1.06); }
.next-post-card span { font-size: 10px; letter-spacing: 1.4px; text-transform: uppercase; opacity: .78; }
.next-post-card h2 { margin-top: 12px; font-family: var(--font-serif); font-size: 24px; line-height: 1.2; max-width: 700px; }

/* ─── PAGE TEMPLATE ──────────────────────────────────────────────── */
.page-main { padding: 40px 24px 80px; }
.page-wrap { max-width: 760px; margin: 0 auto; }
.page-header { text-align: center; margin-bottom: 40px; }
.page-header h1 { font-family: var(--font-serif); font-size: clamp(30px, 3.6vw, 52px); line-height: 1.1; }
.page-header p { margin-top: 14px; font-size: 15px; color: var(--ink-muted); font-weight: 400; }
.page-feature-image { margin-bottom: 40px; }
.page-feature-image img { border-radius: var(--radius); width: 100%; }
.page-feature-image figcaption { margin-top: 8px; text-align: center; color: var(--ink-muted); font-size: 12px; font-weight: 400; }

/* Author archive header */
.archive-header.author-profile img {
  width: 80px; height: 80px; border-radius: 50%; object-fit: cover;
  margin: 0 auto 16px; border: 3px solid var(--sidebar-border);
}

/* ─── FOOTER ─────────────────────────────────────────────────────── */
.site-footer { border-top: 1px solid var(--sidebar-border); }
.site-footer-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center; gap: 18px;
  padding: 28px 24px 20px; max-width: 100%;
}
.footer-brand {
  display: flex; align-items: center; gap: 9px; color: var(--ink);
}
.footer-logo-mark { width: 28px; height: 28px; border-radius: 7px; }
.footer-logo-mark::first-letter { font-size: 14px; }
.footer-logo-name {
  font-family: var(--font-serif); font-size: 17px; font-weight: 700; font-style: italic;
}
.footer-nav ul {
  display: flex; align-items: center; justify-content: center;
  gap: 20px; font-size: 12.5px; font-weight: 500; color: var(--ink-muted);
}
.footer-nav ul a:hover { color: var(--ink); }
.footer-social { display: flex; gap: 12px; font-size: 14px; color: var(--ink-muted); }
.footer-social a:hover { color: var(--ink); }
.footer-social:empty { display: none; }
.footer-copy {
  grid-column: 1 / -1; text-align: center;
  font-size: 11px; color: var(--ink-muted); font-weight: 400; margin-top: 4px;
}

/* ─── MOBILE OVERLAY ─────────────────────────────────────────────── */
.sidebar-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,.4); z-index: 90;
}
.sidebar-overlay.active { display: block; }

/* ─── FADE-IN ANIMATION ──────────────────────────────────────────── */
.fade-in { opacity: 0; transform: translateY(18px); transition: opacity .45s ease, transform .45s ease; }
.fade-in.visible { opacity: 1; transform: none; }

/* ─── SCROLLBAR ──────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--sidebar-border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--ink-muted); }

/* ─── RESPONSIVE ─────────────────────────────────────────────────── */
@media (max-width: 1200px) {
  .card-grid { grid-template-columns: repeat(4, 1fr); }
  .mini-grid { grid-template-columns: 1fr 1fr 1fr; }
  .featured-mini { grid-column: span 3; }
}

@media (max-width: 960px) {
  .hero-section {
    grid-template-columns: 1fr;
    min-height: auto;
    gap: 14px;
  }
  .hero-main-card {
    min-height: 500px;
    border-radius: 8px 28px 8px 8px;
  }
  .hero-side-stack {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-left: 1px solid rgba(255,255,255,.12);
  }
  .hss-card {
    min-height: 124px;
    transform: none;
  }
  .hss-card:hover { transform: translateY(-3px); }
  .hero-ticker { display: none; }
  .card-grid { grid-template-columns: repeat(3, 1fr); }
  .card-grid.grid-mixed { grid-template-columns: repeat(3, 1fr); }
  .archive-grid { grid-template-columns: repeat(2, 1fr); }
  .authors-grid, .topic-grid, .tiers { grid-template-columns: repeat(2, 1fr); }

  .hero-style-studio {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .hero-style-studio .hero-main-card {
    min-height: 610px;
  }
  .hero-style-studio .hero-side-stack {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .hero-style-studio .hss-card {
    min-height: 230px;
  }
}

@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); box-shadow: 4px 0 24px rgba(0,0,0,.16); }
  .main-content { margin-left: 0; }
  .hamburger { display: inline-flex; }

  .hero-section {
    grid-template-columns: 1fr;
    padding: 12px 12px 46px;
  }
  .hero-section::before { inset: 12px; }
  .hero-section::after { display: none; }
  .hero-main-card {
    min-height: 470px;
    clip-path: none;
    border-radius: 8px 22px 8px 8px;
  }
  .hero-side-stack { display: none; }
  .hmc-body { padding: 0 22px 28px; }
  .hmc-title {
    font-size: clamp(34px, 10vw, 54px);
    line-height: 1;
  }
  .hmc-footer {
    align-items: flex-start;
    flex-direction: column;
  }
  .hmc-index {
    width: 58px;
    height: 58px;
    font-size: 21px;
    top: 18px;
    right: 18px;
  }

  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .card-grid.grid-mixed { grid-template-columns: repeat(2, 1fr); }
  .archive-grid { grid-template-columns: 1fr; }
  .authors-grid, .topic-grid, .tiers { grid-template-columns: 1fr; }
  .mini-grid { grid-template-columns: 1fr 1fr; }
  .featured-mini { grid-column: span 2; }

  .newsletter-inner { flex-direction: column; }
  .newsletter-form { flex-direction: column; width: 100%; }
  .newsletter-input { width: 100%; }
  .topbar-member { gap: 6px; }
  .btn-signin,
  .btn-signup {
    min-height: 32px;
    padding: 0 11px;
    font-size: 12px;
  }
  .membership-hero {
    grid-template-columns: 1fr;
    padding: 18px;
  }
  .auth-switch-panel {
    align-items: stretch;
    flex-direction: column;
  }
  .auth-switch-panel > a {
    width: 100%;
  }
  .membership-card-preview {
    min-height: 220px;
  }
  .auth-modal {
    padding: 14px;
    align-items: end;
  }
  .auth-dialog {
    width: 100%;
    max-height: calc(100vh - 28px);
    min-height: 0;
    grid-template-columns: 1fr;
    overflow-y: auto;
  }
  .auth-art {
    min-height: 190px;
    padding: 28px 24px;
  }
  .auth-art strong {
    max-width: 420px;
    font-size: 34px;
  }
  .auth-panel {
    padding: 28px 22px 30px;
  }
  .post-action-shell {
    grid-template-columns: repeat(2, 1fr);
    width: calc(100% - 28px);
    margin-top: -28px;
    margin-bottom: 28px;
    padding: 14px 10px;
    row-gap: 10px;
  }
  .post-share-modal,
  .post-comment-modal {
    padding: 14px;
  }
  .post-share-dialog,
  .post-comment-dialog {
    max-height: calc(100vh - 28px);
    overflow-y: auto;
  }

  .site-footer-inner { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .footer-nav ul { justify-content: center; flex-wrap: wrap; }
  .footer-social { justify-content: center; }

  .hero-style-studio {
    padding: 14px 14px 50px;
  }
  .hero-style-studio::before { inset: 14px; }
  .hero-style-studio .hero-main-card {
    min-height: 610px;
    border-radius: 10px;
    box-shadow: 8px 8px 0 rgba(26,26,26,.1), 0 18px 38px rgba(26,26,26,.12);
  }
  .hero-style-studio .hmc-bg,
  .hero-style-studio .hmc-veil {
    inset: 18px 18px 260px 18px;
  }
  .hero-style-studio .hmc-body {
    padding: 0 20px 24px;
  }
  .hero-style-studio .hmc-title {
    font-size: clamp(31px, 9vw, 48px);
    line-height: .96;
  }
  .hero-style-studio .hmc-accent-bar {
    right: 24px;
    bottom: 228px;
  }
  .hero-style-studio .hmc-index {
    left: 28px;
    right: auto;
    top: 28px;
    width: auto;
    height: auto;
    padding: 7px 10px;
    font-size: 10px;
  }
}

@media (max-width: 480px) {
  .card-grid { grid-template-columns: 1fr; }
  .card-grid.grid-mixed { grid-template-columns: 1fr; }
  .card-grid.grid-mixed .post-card:nth-child(6n+1),
  .card-grid.grid-mixed .post-card:nth-child(6n+4) { grid-column: auto; }
  .card-grid-section { padding: 0 14px 8px; }
  .tag-section, .authors-section { padding-left: 14px; padding-right: 14px; }
  .newsletter-section { margin: 4px 14px 28px; padding: 24px 20px; }
  .section-header { padding: 0 14px; }
  .topbar {
    padding: 0 12px;
  }
  .topbar-member {
    display: none;
  }
  .membership-actions {
    align-items: stretch;
    flex-direction: column;
  }
  .membership-primary,
  .membership-secondary {
    width: 100%;
  }
  .members-cta {
    width: calc(100% - 28px);
    padding: 30px 22px;
  }
  .members-cta-actions {
    align-items: stretch;
    flex-direction: column;
  }
  .members-cta-primary,
  .members-cta-secondary {
    width: 100%;
  }
  .recommendations-panel {
    padding: 18px;
  }
  .auth-art {
    min-height: 150px;
  }
  .auth-art p {
    display: none;
  }
  .auth-tabs {
    width: 100%;
  }
  .auth-tab {
    flex: 1;
  }
  .post-action-btn {
    font-size: 12px;
  }
  .share-actions {
    grid-template-columns: repeat(4, 1fr);
  }
  .share-copy {
    grid-column: 1 / -1;
  }
  .discussion-auth-card {
    padding: 22px;
  }
  .discussion-auth-actions {
    align-items: stretch;
    flex-direction: column;
  }
  .discussion-auth-primary,
  .discussion-auth-secondary {
    width: 100%;
  }

  .hero-style-studio .hero-main-card {
    min-height: 650px;
  }
  .hero-style-studio .hmc-bg,
  .hero-style-studio .hmc-veil {
    inset: 16px 16px 310px 16px;
  }
  .hero-style-studio .hmc-accent-bar {
    bottom: 278px;
  }
  .hero-style-studio .hmc-footer {
    gap: 14px;
  }
  .hero-style-studio .hmc-cta {
    width: 100%;
    justify-content: center;
  }
}
