/* =====================================================================
   Afghanha Newspaper Port — main stylesheet
   Ported from the Lovable "newspaper" editorial design (visual master).
   Plain CSS, no Tailwind / no build step. All rules are scoped under
   .afgh-site so old plugin styles are less likely to collide.
   ===================================================================== */

/* ---------------------------------------------------------------------
   1. Design tokens (ported 1:1 from the Lovable styles.css :root)
   --------------------------------------------------------------------- */
:root {
  --afgh-radius: 0.25rem;

  /* Hex fallbacks first, then the exact oklch values from the master. */
  --afgh-paper: #fbfaf7;
  --afgh-paper: oklch(0.985 0.004 80);
  --afgh-ink: #23262d;
  --afgh-ink: oklch(0.18 0.012 250);
  --afgh-accent: #2f5d76;
  --afgh-accent: oklch(0.38 0.07 230);
  --afgh-accent-foreground: #fbfaf7;
  --afgh-accent-foreground: oklch(0.985 0.004 80);

  --afgh-muted: #f0efea;
  --afgh-muted: oklch(0.95 0.005 80);
  --afgh-muted-foreground: #6b6f76;
  --afgh-muted-foreground: oklch(0.45 0.01 250);

  --afgh-rule: #ddd9d2;
  --afgh-rule: oklch(0.88 0.006 80);
  --afgh-rule-strong: #b3aea5;
  --afgh-rule-strong: oklch(0.7 0.008 80);

  --afgh-destructive: #b3261e;
  --afgh-destructive: oklch(0.45 0.18 28);

  --afgh-serif: "Ibarra Real Nova", ui-serif, Georgia, "Times New Roman", serif;
  --afgh-sans: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  --afgh-container: 1320px;
}

/* ---------------------------------------------------------------------
   2. Base — scoped to the theme wrapper
   --------------------------------------------------------------------- */
.afgh-site {
  background-color: var(--afgh-paper);
  color: var(--afgh-ink);
  font-family: var(--afgh-serif);
  font-feature-settings: "kern", "liga", "onum";
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.afgh-site *,
.afgh-site *::before,
.afgh-site *::after {
  box-sizing: border-box;
  border-color: var(--afgh-rule);
}

.afgh-site main {
  flex: 1 0 auto;
}

.afgh-site a {
  color: inherit;
  text-decoration: none;
}

.afgh-site img {
  max-width: 100%;
  height: auto;
  display: block;
}

.afgh-site h1,
.afgh-site h2,
.afgh-site h3,
.afgh-site h4,
.afgh-site h5,
.afgh-site h6,
.afgh-site p,
.afgh-site figure,
.afgh-site ul,
.afgh-site ol {
  margin: 0;
}

.afgh-site ::selection {
  background: color-mix(in oklab, var(--afgh-accent) 18%, transparent);
  color: var(--afgh-ink);
}

.afgh-container {
  margin-inline: auto;
  max-width: var(--afgh-container);
  padding-inline: 24px;
  width: 100%;
}

.afgh-skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--afgh-ink);
  color: var(--afgh-paper);
  padding: 10px 16px;
  z-index: 100;
  font-family: var(--afgh-sans);
  font-size: 13px;
}
.afgh-skip-link:focus {
  left: 8px;
  top: 8px;
}

/* ---------------------------------------------------------------------
   3. Typographic utilities (ported from @utility blocks)
   --------------------------------------------------------------------- */
.afgh-eyebrow {
  font-family: var(--afgh-sans);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.afgh-kicker {
  font-family: var(--afgh-sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.afgh-meta {
  font-family: var(--afgh-sans);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--afgh-muted-foreground);
}
.afgh-meta a:hover { color: var(--afgh-ink); }

.afgh-accent { color: var(--afgh-accent); }
.afgh-ink { color: var(--afgh-ink); }
.afgh-muted-fg { color: var(--afgh-muted-foreground); }
.afgh-italic { font-style: italic; }

.afgh-rule-top { border-top: 1px solid var(--afgh-rule); }
.afgh-rule-strong-top { border-top: 2px solid var(--afgh-ink); }

/* Underline-grow link used on every headline */
.afgh-headline {
  background-image: linear-gradient(currentColor, currentColor);
  background-size: 0 1px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  transition: background-size 250ms ease;
}
.afgh-headline:hover { background-size: 100% 1px; }

/* Diagonal-hatch placeholder shown when a post has no featured image */
.afgh-photo {
  background:
    repeating-linear-gradient(135deg,
      oklch(0.92 0.006 80) 0 6px,
      oklch(0.9 0.006 80) 6px 12px);
  background-color: #ededea; /* fallback for no-oklch browsers */
  display: grid;
  place-items: center;
  color: oklch(0.55 0.01 250);
  font-family: var(--afgh-sans);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  overflow: hidden;
}
.afgh-photo img { width: 100%; height: 100%; object-fit: cover; }
.afgh-photo > span { padding: 8px; text-align: center; }

/* Aspect-ratio helpers (match the Tailwind aspect-[..] usages) */
.afgh-ar-16-9 { aspect-ratio: 16 / 9; }
.afgh-ar-16-8 { aspect-ratio: 16 / 8; }
.afgh-ar-4-3  { aspect-ratio: 4 / 3; }
.afgh-ar-3-2  { aspect-ratio: 3 / 2; }

/* ---------------------------------------------------------------------
   4. Header / masthead / navigation
   --------------------------------------------------------------------- */
.afgh-header {
  border-bottom: 2px solid var(--afgh-ink);
  background-color: var(--afgh-paper);
}

.afgh-utility {
  border-bottom: 1px solid var(--afgh-rule);
}
.afgh-utility .afgh-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 8px;
  padding-bottom: 8px;
  font-family: var(--afgh-sans);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--afgh-muted-foreground);
}
.afgh-utility-left,
.afgh-utility-right { display: flex; align-items: center; gap: 20px; }
.afgh-utility a:hover { color: var(--afgh-ink); }
.afgh-utility-strong { color: var(--afgh-ink); }

.afgh-masthead {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding-top: 28px;
  padding-bottom: 28px;
}
.afgh-masthead-side {
  display: flex;
  flex-direction: column;
  font-family: var(--afgh-sans);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--afgh-muted-foreground);
}
.afgh-masthead-side.is-right {
  flex-direction: row;
  align-items: center;
  justify-content: flex-end;
}
.afgh-masthead-title {
  text-align: center;
}
.afgh-masthead-title .afgh-logo {
  font-family: var(--afgh-serif);
  font-size: clamp(34px, 6vw, 60px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.02em;
  display: inline-block;
}
.afgh-masthead-title .custom-logo-link { display: inline-block; }
.afgh-masthead-title .custom-logo { max-height: 72px; width: auto; display: inline-block; }
.afgh-tagline {
  margin-top: 8px;
  font-family: var(--afgh-sans);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.32em;
  color: var(--afgh-muted-foreground);
}
.afgh-btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--afgh-ink);
  padding: 6px 12px;
  font-family: var(--afgh-sans);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--afgh-ink);
  transition: background-color 150ms ease, color 150ms ease;
}
.afgh-btn-outline:hover { background: var(--afgh-ink); color: var(--afgh-paper); }

/* Primary nav */
.afgh-nav {
  border-top: 1px solid var(--afgh-ink);
  border-bottom: 1px solid var(--afgh-ink);
}
.afgh-nav .afgh-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.afgh-nav-menu {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  flex: 1;
  overflow-x: auto;
  padding: 10px 0;
  font-family: var(--afgh-sans);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  scrollbar-width: none;
}
.afgh-nav-menu::-webkit-scrollbar { display: none; }
.afgh-nav-menu > li { flex-shrink: 0; }
.afgh-nav-menu > li > a {
  display: block;
  padding: 6px 12px;
  white-space: nowrap;
}
.afgh-nav-menu > li > a:hover,
.afgh-nav-menu > li.current-menu-item > a,
.afgh-nav-menu > li.current-cat > a { color: var(--afgh-accent); }
/* Hide nested items in the masthead — keep the bar from exploding */
.afgh-nav-menu .sub-menu,
.afgh-nav-menu ul.children { display: none !important; }

.afgh-nav-search {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  padding: 10px 0;
  font-family: var(--afgh-sans);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--afgh-muted-foreground);
}
.afgh-nav-search:hover { color: var(--afgh-ink); }
.afgh-icon { width: 14px; height: 14px; }

/* Mobile menu toggle + panel */
.afgh-nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  background: none;
  border: 1px solid var(--afgh-ink);
  padding: 7px 12px;
  font-family: var(--afgh-sans);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--afgh-ink);
  cursor: pointer;
}
.afgh-mobile-panel {
  display: none;
  border-bottom: 2px solid var(--afgh-ink);
  background: var(--afgh-paper);
}
.afgh-mobile-panel.is-open { display: block; }
.afgh-mobile-panel ul { list-style: none; }
.afgh-mobile-panel > .afgh-container > ul > li > a {
  display: block;
  padding: 12px 0;
  border-bottom: 1px solid var(--afgh-rule);
  font-family: var(--afgh-sans);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.afgh-mobile-panel .sub-menu,
.afgh-mobile-panel ul.children { display: none !important; }
.afgh-mobile-search { padding: 16px 0; }
.afgh-mobile-search form { display: flex; border-bottom: 2px solid var(--afgh-ink); }
.afgh-mobile-search input[type="search"] {
  flex: 1;
  background: transparent;
  border: 0;
  outline: none;
  padding: 8px 0;
  font-family: var(--afgh-sans);
  font-size: 14px;
}

/* ---------------------------------------------------------------------
   5. Layout helpers
   --------------------------------------------------------------------- */
.afgh-main { padding-top: 40px; padding-bottom: 40px; }

/* Section heading row: italic serif title + "View all" link */
.afgh-section { margin-top: 80px; }
.afgh-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
  border-top: 2px solid var(--afgh-ink);
  padding-top: 12px;
}
.afgh-section-title {
  font-family: var(--afgh-serif);
  font-style: italic;
  font-size: clamp(28px, 4vw, 34px);
  font-weight: 500;
  line-height: 1.1;
}
.afgh-section-head .afgh-kicker { white-space: nowrap; }
.afgh-section-head .afgh-kicker:hover { color: var(--afgh-accent); }
.afgh-section-note {
  font-family: var(--afgh-sans);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--afgh-muted-foreground);
}

/* ---------------------------------------------------------------------
   6. Hero band (front page)
   --------------------------------------------------------------------- */
.afgh-hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}
.afgh-hero-lead {}
.afgh-hero-rail {}

.afgh-lead-kicker { margin-bottom: 16px; display: inline-block; }
.afgh-lead-title {
  font-family: var(--afgh-serif);
  font-size: clamp(40px, 6vw, 68px);
  line-height: 1.02;
  font-weight: 500;
  letter-spacing: -0.015em;
}
.afgh-lead-dek {
  margin-top: 20px;
  max-width: 55ch;
  font-family: var(--afgh-serif);
  font-size: clamp(20px, 2.4vw, 22px);
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-byline {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.afgh-lead-photo { margin-top: 28px; width: 100%; }

.afgh-sub-grid {
  margin-top: 40px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  border-top: 2px solid var(--afgh-ink);
  padding-top: 32px;
}

/* Rail blocks */
.afgh-rail-block { margin-top: 32px; }
.afgh-rail-companion { border-bottom: 1px solid var(--afgh-rule); padding-bottom: 32px; }
.afgh-rail-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  border-bottom: 2px solid var(--afgh-ink);
  padding-bottom: 8px;
}
.afgh-list { list-style: none; }
.afgh-list.is-divided > li { border-top: 1px solid var(--afgh-rule); }
.afgh-list.is-divided > li:first-child { border-top: 0; }

.afgh-briefing-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 12px 0;
}
.afgh-briefing-time { margin-top: 2px; width: 48px; flex-shrink: 0; }
.afgh-briefing-text { font-family: var(--afgh-serif); font-size: 15.5px; line-height: 1.35; }

.afgh-rail-more { margin-top: 16px; display: inline-block; }
.afgh-rail-more:hover { color: var(--afgh-accent); }

.afgh-mostread { margin-top: 14px; list-style: none; }
.afgh-mostread > li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 14px 0;
  border-top: 1px solid var(--afgh-rule);
}
.afgh-mostread > li:first-child { border-top: 0; }
.afgh-mostread-num {
  font-family: var(--afgh-serif);
  font-size: 30px;
  line-height: 1;
  color: var(--afgh-accent);
}
.afgh-mostread-title { font-family: var(--afgh-serif); font-size: 16.5px; line-height: 1.35; }

/* ---------------------------------------------------------------------
   7. Story card (the reusable article teaser)
   --------------------------------------------------------------------- */
.afgh-card {}
.afgh-card.has-rule { border-top: 1px solid var(--afgh-rule); padding-top: 20px; }
.afgh-card-photo { margin-bottom: 16px; width: 100%; }
.afgh-card-kicker { margin-bottom: 8px; display: inline-block; }
.afgh-card-kicker:hover { text-decoration: underline; }
.afgh-card-title { font-family: var(--afgh-serif); font-weight: 500; }
.afgh-card-dek { margin-top: 12px; font-family: var(--afgh-serif); color: var(--afgh-muted-foreground); }
.afgh-card-meta { margin-top: 12px; display: flex; align-items: center; gap: 8px; }

/* Card size tiers (ported from TITLE_SIZE / DEK_SIZE) */
.afgh-card.size-xl .afgh-card-title { font-size: clamp(36px, 5vw, 60px); line-height: 1.02; letter-spacing: -0.015em; }
.afgh-card.size-lg .afgh-card-title { font-size: clamp(24px, 3vw, 30px); line-height: 1.1; letter-spacing: -0.01em; }
.afgh-card.size-md .afgh-card-title { font-size: 20px; line-height: 1.3; }
.afgh-card.size-sm .afgh-card-title { font-size: 17px; line-height: 1.3; }
.afgh-card.size-xs .afgh-card-title { font-size: 15px; line-height: 1.3; }

.afgh-card.size-xl .afgh-card-dek { font-size: clamp(18px, 2vw, 20px); line-height: 1.6; }
.afgh-card.size-lg .afgh-card-dek { font-size: 16px; line-height: 1.6; }
.afgh-card.size-md .afgh-card-dek { font-size: 14.5px; line-height: 1.6; }
.afgh-card.size-sm .afgh-card-dek { font-size: 13.5px; line-height: 1.6; }
.afgh-card.size-xs .afgh-card-dek { font-size: 13px; line-height: 1.35; }

/* ---------------------------------------------------------------------
   8. Grids used across home / archive / single
   --------------------------------------------------------------------- */
.afgh-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px 40px;
}
.afgh-grid.cols-2 { }
.afgh-grid.cols-3 { }
.afgh-grid.cols-4 { }

/* Opinion strip — 3 bordered columns */
.afgh-opinion-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}
.afgh-opinion-item { padding-left: 24px; }
.afgh-opinion-item .afgh-opinion-title {
  font-family: var(--afgh-serif);
  font-size: 26px;
  line-height: 1.2;
  font-weight: 500;
  font-style: italic;
}
.afgh-opinion-item .afgh-opinion-dek {
  margin-top: 12px;
  font-family: var(--afgh-serif);
  font-size: 15px;
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-opinion-item .afgh-opinion-meta { margin-top: 16px; }

/* Culture + Books split */
.afgh-split {
  margin-top: 80px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px 40px;
}
.afgh-split-stack > * + * { margin-top: 28px; }

/* ---------------------------------------------------------------------
   9. Single article
   --------------------------------------------------------------------- */
.afgh-article-head { border-bottom: 1px solid var(--afgh-rule); }
.afgh-article-head-inner { max-width: 1100px; margin-inline: auto; padding: 48px 24px 40px; }
.afgh-breadcrumb {
  margin-bottom: 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.afgh-article-headbox { max-width: 760px; margin-inline: auto; }
.afgh-article-kicker { margin-bottom: 20px; display: inline-block; }
.afgh-article-title {
  font-family: var(--afgh-serif);
  font-size: clamp(34px, 5vw, 56px);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.012em;
}
.afgh-article-dek {
  margin-top: 24px;
  font-family: var(--afgh-serif);
  font-style: italic;
  font-size: clamp(20px, 2.6vw, 24px);
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-article-byline {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--afgh-rule);
  padding-top: 20px;
}
.afgh-article-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--afgh-sans);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--afgh-muted-foreground);
}
.afgh-article-actions a,
.afgh-article-actions button {
  border: 1px solid var(--afgh-rule-strong);
  background: transparent;
  padding: 6px 12px;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  color: inherit;
  cursor: pointer;
}
.afgh-article-actions a:hover,
.afgh-article-actions button:hover { background: var(--afgh-ink); color: var(--afgh-paper); }

.afgh-article-figure { max-width: 1100px; margin-inline: auto; padding: 0 24px 48px; }
.afgh-article-figure figcaption { margin-top: 12px; }

.afgh-article-body-wrap { max-width: 1100px; margin-inline: auto; padding: 56px 24px; }
.afgh-article-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
}

/* The long-form body — readable measure, generous leading */
.afgh-article-body {
  max-width: 680px;
  margin-inline: auto;
  font-family: var(--afgh-serif);
  font-size: 19px;
  line-height: 1.75;
  color: var(--afgh-ink);
}
.afgh-article-body > p { margin-top: 24px; }
.afgh-article-body > p:first-child { margin-top: 0; }
/* Drop cap on the opening paragraph (opt-in via .afgh-has-dropcap) */
.afgh-article-body.afgh-has-dropcap > p:first-of-type::first-letter {
  float: left;
  margin-right: 12px;
  margin-top: 8px;
  font-family: var(--afgh-serif);
  font-size: 88px;
  font-weight: 500;
  line-height: 0.8;
  color: var(--afgh-accent);
}
.afgh-article-body h2 {
  margin-top: 48px;
  font-family: var(--afgh-serif);
  font-size: 30px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.afgh-article-body h3 {
  margin-top: 40px;
  font-family: var(--afgh-serif);
  font-size: 24px;
  font-weight: 500;
  line-height: 1.25;
}
.afgh-article-body h4 { margin-top: 32px; font-family: var(--afgh-sans); font-size: 14px; text-transform: uppercase; letter-spacing: 0.12em; }
.afgh-article-body a { color: var(--afgh-accent); background-image: linear-gradient(currentColor, currentColor); background-size: 100% 1px; background-repeat: no-repeat; background-position: 0 100%; }
.afgh-article-body ul,
.afgh-article-body ol { margin-top: 24px; padding-left: 1.4em; }
.afgh-article-body li { margin-top: 8px; }
.afgh-article-body blockquote {
  margin: 48px 0;
  border-left: 2px solid var(--afgh-ink);
  padding-left: 28px;
}
.afgh-article-body blockquote p {
  font-family: var(--afgh-serif);
  font-size: 28px;
  line-height: 1.25;
  font-style: italic;
  color: var(--afgh-ink);
}
.afgh-article-body blockquote cite { display: block; margin-top: 16px; font-style: normal; }
.afgh-article-body img { margin: 32px 0; }
.afgh-article-body figure { margin: 32px 0; }
.afgh-article-body figcaption { font-family: var(--afgh-sans); font-size: 11px; color: var(--afgh-muted-foreground); margin-top: 8px; }
.afgh-article-body hr { margin: 48px 0; border: 0; border-top: 2px solid var(--afgh-ink); }
.afgh-article-body table { width: 100%; border-collapse: collapse; margin: 32px 0; font-size: 16px; }
.afgh-article-body th,
.afgh-article-body td { border: 1px solid var(--afgh-rule); padding: 8px 12px; text-align: left; }
.afgh-article-body pre { background: var(--afgh-muted); padding: 16px; overflow-x: auto; font-family: ui-monospace, monospace; font-size: 14px; margin: 24px 0; }
.afgh-article-body code { font-family: ui-monospace, monospace; font-size: 0.9em; }

.afgh-article-aside > * + * { margin-top: 40px; }
.afgh-aside-head { border-bottom: 2px solid var(--afgh-ink); padding-bottom: 8px; }
.afgh-aside-list { list-style: none; margin-top: 12px; }
.afgh-aside-related { list-style: none; margin-top: 16px; }
.afgh-aside-related > li + li { margin-top: 20px; }
.afgh-aside-related-title { font-family: var(--afgh-serif); font-size: 15.5px; line-height: 1.35; }

.afgh-more {
  border-top: 2px solid var(--afgh-ink);
}
.afgh-more-inner { max-width: 1320px; margin-inline: auto; padding: 56px 24px; }
.afgh-more-title { margin-bottom: 32px; font-family: var(--afgh-serif); font-style: italic; font-size: 30px; }

/* Tags / post footer */
.afgh-post-tags { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.afgh-tag {
  border: 1px solid var(--afgh-rule-strong);
  padding: 4px 10px;
  font-family: var(--afgh-sans);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--afgh-muted-foreground);
}
.afgh-tag:hover { background: var(--afgh-ink); color: var(--afgh-paper); }

/* ---------------------------------------------------------------------
   10. Section / archive / category pages
   --------------------------------------------------------------------- */
.afgh-arch-head { border-bottom: 2px solid var(--afgh-ink); padding-bottom: 24px; }
.afgh-arch-title {
  font-family: var(--afgh-serif);
  font-size: clamp(48px, 8vw, 72px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
}
.afgh-arch-head-row {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.afgh-arch-desc {
  max-width: 42ch;
  font-family: var(--afgh-serif);
  font-style: italic;
  font-size: 17px;
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-arch-nav {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  font-family: var(--afgh-sans);
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.afgh-arch-nav a {
  padding: 6px 12px;
  color: var(--afgh-muted-foreground);
}
.afgh-arch-nav a:hover { color: var(--afgh-accent); }
.afgh-arch-nav a.is-active { color: var(--afgh-accent); border-bottom: 2px solid var(--afgh-accent); }

.afgh-arch-lead-grid {
  margin-top: 40px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}
.afgh-arch-lead-photo { width: 100%; }
.afgh-arch-lead-title {
  margin-top: 8px;
  font-family: var(--afgh-serif);
  font-size: clamp(34px, 4vw, 48px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.012em;
}
.afgh-arch-lead-dek {
  margin-top: 16px;
  max-width: 55ch;
  font-family: var(--afgh-serif);
  font-size: 18px;
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-arch-picks { list-style: none; margin-top: 8px; }
.afgh-arch-picks > li { padding: 16px 0; border-top: 1px solid var(--afgh-rule); }
.afgh-arch-picks > li:first-child { border-top: 0; }
.afgh-arch-picks-title { font-family: var(--afgh-serif); font-size: 17px; line-height: 1.3; }

.afgh-arch-grid-head {
  margin-top: 64px;
  margin-bottom: 32px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  border-top: 2px solid var(--afgh-ink);
  padding-top: 12px;
}

/* ---------------------------------------------------------------------
   11. Search
   --------------------------------------------------------------------- */
.afgh-search-head { border-bottom: 2px solid var(--afgh-ink); padding-bottom: 32px; }
.afgh-search-title {
  margin-top: 12px;
  font-family: var(--afgh-serif);
  font-size: clamp(44px, 7vw, 64px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
}
.afgh-search-intro {
  margin-top: 16px;
  max-width: 60ch;
  font-family: var(--afgh-serif);
  font-style: italic;
  font-size: 18px;
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-search-form { margin-top: 32px; }
.afgh-search-field { position: relative; border-bottom: 2px solid var(--afgh-ink); display: flex; align-items: center; }
.afgh-search-field svg { flex-shrink: 0; color: var(--afgh-muted-foreground); margin-right: 8px; }
.afgh-search-field input[type="search"] {
  flex: 1;
  width: 100%;
  background: transparent;
  border: 0;
  outline: none;
  padding: 16px 0;
  font-family: var(--afgh-serif);
  font-style: italic;
  font-size: clamp(22px, 3vw, 30px);
}
.afgh-search-submit {
  background: none; border: 0; cursor: pointer;
  font-family: var(--afgh-sans); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.16em; color: var(--afgh-ink);
  padding: 8px;
}
.afgh-search-suggest { margin-top: 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.afgh-chip {
  border: 1px solid var(--afgh-rule-strong);
  padding: 4px 12px;
  font-family: var(--afgh-sans);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--afgh-muted-foreground);
}
.afgh-chip:hover { background: var(--afgh-ink); color: var(--afgh-paper); }

.afgh-search-results { margin-top: 24px; list-style: none; }
.afgh-search-results > li { padding: 28px 0; border-top: 1px solid var(--afgh-rule); }
.afgh-search-results > li:first-child { border-top: 0; }
.afgh-result-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
.afgh-result-title {
  font-family: var(--afgh-serif);
  font-size: 26px;
  line-height: 1.2;
  font-weight: 500;
  letter-spacing: -0.005em;
}
.afgh-result-dek {
  margin-top: 8px;
  max-width: 68ch;
  font-family: var(--afgh-serif);
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-result-badge {
  border: 1px solid var(--afgh-rule-strong);
  padding: 4px 8px;
  font-family: var(--afgh-sans);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--afgh-muted-foreground);
}
.afgh-empty { border-top: 1px solid var(--afgh-rule); border-bottom: 1px solid var(--afgh-rule); padding: 80px 0; text-align: center; }
.afgh-empty h2 { font-family: var(--afgh-serif); font-style: italic; font-size: 30px; }
.afgh-empty p { margin-top: 12px; font-family: var(--afgh-serif); color: var(--afgh-muted-foreground); }

/* ---------------------------------------------------------------------
   12. Pagination
   --------------------------------------------------------------------- */
.afgh-pagination {
  margin-top: 48px;
  border-top: 1px solid var(--afgh-rule);
  padding-top: 24px;
  font-family: var(--afgh-sans);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}
.afgh-pagination ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.afgh-pagination li { margin: 0; }
.afgh-pagination a.page-numbers,
.afgh-pagination span.page-numbers {
  display: inline-block;
  border: 1px solid var(--afgh-rule-strong);
  padding: 8px 14px;
  color: var(--afgh-muted-foreground);
}
.afgh-pagination span.current { border-color: var(--afgh-ink); color: var(--afgh-ink); }
.afgh-pagination a.page-numbers:hover { background: var(--afgh-ink); color: var(--afgh-paper); }
.afgh-pagination .dots { border-color: transparent; }

/* ---------------------------------------------------------------------
   13. Page (static) + comments
   --------------------------------------------------------------------- */
.afgh-page-wrap { max-width: 820px; margin-inline: auto; padding: 56px 24px; }
.afgh-page-title {
  font-family: var(--afgh-serif);
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.015em;
}
.afgh-page-body { margin-top: 32px; }

.afgh-comments { max-width: 680px; margin: 56px auto 0; }
.afgh-comments .comment-list { list-style: none; padding: 0; }
.afgh-comments .comment-list li { border-top: 1px solid var(--afgh-rule); padding: 20px 0; }
.afgh-comments input[type="text"],
.afgh-comments input[type="email"],
.afgh-comments input[type="url"],
.afgh-comments textarea {
  width: 100%;
  border: 1px solid var(--afgh-rule-strong);
  background: transparent;
  padding: 10px;
  font-family: var(--afgh-sans);
  font-size: 14px;
  margin-bottom: 12px;
}

/* ---------------------------------------------------------------------
   14. Footer
   --------------------------------------------------------------------- */
.afgh-footer {
  margin-top: 96px;
  border-top: 2px solid var(--afgh-ink);
  background-color: var(--afgh-paper);
}
.afgh-footer-inner { max-width: 1320px; margin-inline: auto; padding: 64px 24px; }
.afgh-footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  border-bottom: 1px solid var(--afgh-rule);
  padding-bottom: 56px;
}
.afgh-footer-brand .afgh-footer-logo {
  font-family: var(--afgh-serif);
  font-size: 30px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.02em;
}
.afgh-footer-about {
  margin-top: 20px;
  max-width: 36ch;
  font-family: var(--afgh-serif);
  font-size: 15px;
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-footer-col h4 { margin-bottom: 20px; color: var(--afgh-muted-foreground); }
.afgh-footer-col ul { list-style: none; }
.afgh-footer-col li { margin-bottom: 10px; font-family: var(--afgh-sans); font-size: 13px; }
.afgh-footer-col a:hover { color: var(--afgh-accent); }
.afgh-footer-news p {
  margin-bottom: 16px;
  font-family: var(--afgh-serif);
  font-size: 15px;
  line-height: 1.6;
  color: var(--afgh-muted-foreground);
}
.afgh-footer-news form { display: flex; align-items: center; border-bottom: 2px solid var(--afgh-ink); }
.afgh-footer-news input[type="email"] {
  flex: 1; background: transparent; border: 0; outline: none;
  padding: 10px 0; font-family: var(--afgh-sans); font-size: 13px;
}
.afgh-footer-news button {
  margin-left: 12px; background: none; border: 0; cursor: pointer;
  font-family: var(--afgh-sans); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.18em; color: var(--afgh-ink); padding: 10px 0;
}
.afgh-footer-news button:hover { color: var(--afgh-accent); }
.afgh-footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-top: 32px;
  font-family: var(--afgh-sans);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--afgh-muted-foreground);
}
.afgh-footer-legal { display: flex; flex-wrap: wrap; gap: 8px 28px; }

/* ---------------------------------------------------------------------
   15. 404
   --------------------------------------------------------------------- */
.afgh-404 { max-width: 760px; margin-inline: auto; padding: 96px 24px; text-align: center; }
.afgh-404 h1 { font-family: var(--afgh-serif); font-size: clamp(40px, 8vw, 72px); font-weight: 500; margin-top: 16px; }
.afgh-404 p { margin-top: 16px; font-family: var(--afgh-serif); font-size: 18px; color: var(--afgh-muted-foreground); }
.afgh-404 .afgh-search-form { max-width: 520px; margin-inline: auto; }

/* ---------------------------------------------------------------------
   16. Borders/dividers helpers used inline by templates
   --------------------------------------------------------------------- */
.afgh-divider-strong { border-top: 2px solid var(--afgh-ink); }
.afgh-pad-top { padding-top: 12px; }

/* ---------------------------------------------------------------------
   17. Defensive CSS against legacy plugin output (WPBakery, etc.)
   Visual containment only — never disables plugins.
   --------------------------------------------------------------------- */
.afgh-site .wpb_row,
.afgh-site .vc_row,
.afgh-site .wpb_column,
.afgh-site .vc_column-inner { max-width: 100%; }
.afgh-site iframe,
.afgh-site embed,
.afgh-site object,
.afgh-site video { max-width: 100%; }
.afgh-site .wp-caption { max-width: 100%; }
.afgh-site .wp-caption-text { font-family: var(--afgh-sans); font-size: 11px; color: var(--afgh-muted-foreground); }
.afgh-site .alignleft { float: left; margin: 0 24px 16px 0; }
.afgh-site .alignright { float: right; margin: 0 0 16px 24px; }
.afgh-site .aligncenter { display: block; margin-inline: auto; }
.afgh-site .sticky,
.afgh-site .gallery { margin: 24px 0; }
.afgh-site .screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

/* ---------------------------------------------------------------------
   18. Responsive
   --------------------------------------------------------------------- */
@media (min-width: 640px) {
  .afgh-footer-bottom { flex-direction: row; align-items: center; justify-content: space-between; }
}

@media (min-width: 768px) {
  .afgh-sub-grid { grid-template-columns: 1fr 1fr; }
  .afgh-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
  .afgh-grid.cols-3 { grid-template-columns: repeat(2, 1fr); }
  .afgh-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .afgh-opinion-grid { grid-template-columns: repeat(3, 1fr); }
  .afgh-opinion-item + .afgh-opinion-item { border-left: 1px solid var(--afgh-rule); }
  .afgh-opinion-item:first-child { border-left: 2px solid var(--afgh-ink); }
  .afgh-arch-head-row { flex-direction: row; align-items: flex-end; justify-content: space-between; }
  .afgh-result-grid { grid-template-columns: 1fr auto; align-items: start; }
  .afgh-result-badge-wrap { text-align: right; }
  .afgh-footer-grid { grid-template-columns: repeat(12, 1fr); }
  .afgh-footer-brand { grid-column: span 4; }
  .afgh-footer-col.col-sections { grid-column: span 2; }
  .afgh-footer-col.col-paper { grid-column: span 2; }
  .afgh-footer-news { grid-column: span 4; }
}

@media (min-width: 1024px) {
  .afgh-hero { grid-template-columns: repeat(12, 1fr); }
  .afgh-hero-lead { grid-column: span 7; border-right: 1px solid var(--afgh-rule); padding-right: 40px; }
  .afgh-hero-rail { grid-column: span 5; }
  .afgh-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
  .afgh-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
  .afgh-split { grid-template-columns: repeat(12, 1fr); }
  .afgh-split-main { grid-column: span 8; border-right: 1px solid var(--afgh-rule); padding-right: 40px; }
  .afgh-split-side { grid-column: span 4; }
  .afgh-arch-lead-grid { grid-template-columns: repeat(12, 1fr); }
  .afgh-arch-lead-main { grid-column: span 8; border-right: 1px solid var(--afgh-rule); padding-right: 40px; }
  .afgh-arch-lead-side { grid-column: span 4; }
  .afgh-article-layout { grid-template-columns: 1fr 240px; }
}

/* Tablet / phone navigation swap */
@media (max-width: 900px) {
  .afgh-masthead-side { display: none; }
  .afgh-masthead { grid-template-columns: 1fr; justify-items: center; }
  .afgh-nav-menu { display: none; }
  .afgh-nav-search { display: none; }
  .afgh-nav-toggle { display: inline-flex; }
  .afgh-nav .afgh-container { justify-content: space-between; padding-top: 8px; padding-bottom: 8px; }
}

@media (min-width: 901px) {
  .afgh-nav-toggle { display: none; }
  .afgh-mobile-panel { display: none !important; }
}
