/* ==========================================================================
   Desa Dhompo — public site stylesheet
   Editorial system: white-dominant, charcoal text, mustard accent.
   Tokens first. No !important. No inline-style dependencies (CSP-safe).
   ========================================================================== */

:root {
  /* Color */
  --white: #ffffff;
  --surface: #f6f7f8;
  --surface-strong: #eef0f2;
  --ink: #171b20;
  --charcoal: #171b20;
  --muted: #5c6570;
  --line: #e5e8ec;
  --line-soft: #eef0f2;
  --accent: #c69a24;
  --accent-hover: #b28a1d;
  --accent-dark: #7a5909;
  --accent-soft: #f6efdc;
  --danger: #b3261e;

  /* Layout */
  --container-max: 1200px;
  --gutter: 40px;
  --section-space: clamp(48px, 6.5vw, 84px);
  --radius-lg: 16px;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-soft: 0 12px 28px rgba(23, 27, 32, .07);
  --shadow-small: 0 4px 12px rgba(23, 27, 32, .06);

  /* Type */
  --font-sans: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Homepage + inner pages share one soft translucent gold wash behind the header; content fades to white. */
body.page-home,
body.page-inner {
  background-color: var(--white);
  background-image:
    radial-gradient(88% 62% at 14% 0%, rgba(198, 154, 36, .22) 0%, rgba(198, 154, 36, 0) 60%),
    linear-gradient(180deg, rgba(122, 89, 9, .20) 0%, rgba(122, 89, 9, .08) 54%, rgba(122, 89, 9, 0) 100%);
  background-repeat: no-repeat;
  background-size: 100% 440px, 100% 440px;
}

img { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
::selection { background: var(--accent-soft); color: var(--ink); }

h1, h2, h3, h4, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.14; letter-spacing: -0.02em; font-weight: 700; }

:focus-visible { outline: 3px solid rgba(198, 154, 36, .68); outline-offset: 2px; border-radius: 2px; }

/* Cross-document page transition where supported; plain navigation elsewhere. */
@view-transition { navigation: auto; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  @view-transition { navigation: none; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* --------------------------------------------------------------- utilities */
.container { width: min(var(--container-max), calc(100% - (var(--gutter) * 2))); margin-inline: auto; }
.narrow { max-width: 820px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; z-index: 100; top: 12px; left: 12px; padding: 10px 16px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-small); transform: translateY(-200%); }
.skip-link:focus { transform: none; }

/* ----------------------------------------------------------------- header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(122, 89, 9, .26), rgba(122, 89, 9, .17));
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(122, 89, 9, .24);
  transition: box-shadow .18s ease;
}
.site-header.is-scrolled { box-shadow: 0 6px 18px rgba(23, 27, 32, .07); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 78px; }

.brand { display: block; line-height: 1.2; min-width: 0; }
.brand strong { display: block; font-size: 18px; font-weight: 800; letter-spacing: -0.02em; }
.brand small { display: block; margin-top: 3px; font-size: 12px; font-weight: 500; color: #4f5860; letter-spacing: 0.01em; }

.site-header nav { display: flex; align-items: center; gap: 30px; }
.site-header nav a {
  position: relative;
  font-size: 14.5px;
  font-weight: 600;
  color: #4a525b;
  padding: 8px 0;
  transition: color .16s ease;
}
.site-header nav a:hover { color: var(--ink); }
.site-header nav a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.site-header nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  padding: 0;
  background: none;
  border: 0;
  border-radius: var(--radius-sm);
  cursor: pointer;
  position: relative;
}
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
  position: absolute;
  left: 10px; right: 10px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform .18s ease, opacity .18s ease;
}
.nav-toggle-bars { top: 21px; }
.nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; left: 0; right: 0; }
.nav-toggle-bars::before { top: -7px; }
.nav-toggle-bars::after { top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars { transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(7px) rotate(-90deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { opacity: 0; }

@media (max-width: 860px) {
  :root { --gutter: 20px; }
  .header-inner { height: 66px; }
  .brand strong { font-size: 16px; }
  .brand small { font-size: 12px; }
  .nav-toggle { display: block; }
  .site-header nav {
    position: fixed;
    inset: 66px 0 auto;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px 20px 18px;
    background: rgba(248, 242, 227, .98);
    border-bottom: 1px solid rgba(122, 89, 9, .22);
    box-shadow: 0 18px 30px rgba(23, 27, 32, .1);
    opacity: 0;
    transform: translateY(-8px);
    visibility: hidden;
    transition: opacity .18s ease, transform .18s ease, visibility .18s;
  }
  .site-header nav.open { opacity: 1; transform: none; visibility: visible; }
  .site-header nav a { padding: 13px 2px; border-bottom: 1px solid var(--line-soft); font-size: 15px; }
  .site-header nav a:last-child { border-bottom: 0; }
  .site-header nav a[aria-current="page"] { color: var(--accent-dark); }
  .site-header nav a[aria-current="page"]::after { display: none; }
}

/* ---------------------------------------------------------------- button */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
  cursor: pointer;
  background: var(--surface);
  color: var(--ink);
  transition: background-color .17s ease, border-color .17s ease, color .17s ease, box-shadow .17s ease, transform .17s ease;
}
.button:hover { transform: translateY(-1px); }
.button.primary { background: var(--accent); color: var(--ink); }
.button.primary:hover { background: var(--accent-hover); box-shadow: var(--shadow-small); }
.button.dark { background: var(--ink); color: var(--white); }
.button.dark:hover { background: #2a3138; }
.button.ghost { background: var(--white); border-color: var(--line); color: var(--ink); }
.button.ghost:hover { border-color: #cfd5db; background: var(--surface); }
.button.outline { background: transparent; border-color: rgba(255, 255, 255, .58); color: var(--white); }
.button.outline:hover { background: rgba(255, 255, 255, .14); border-color: rgba(255, 255, 255, .8); }

.link-more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--accent-dark);
}
.link-more svg { transition: transform .17s ease; }
.link-more:hover svg { transform: translateX(3px); }
.link-more:hover { color: #634709; }

/* ------------------------------------------------------------------ hero */
.hero {
  position: relative;
  margin: 24px 32px 0;
  border-radius: 18px;
  overflow: hidden;
  background: var(--charcoal);
  color: var(--white);
}
.hero-media { position: absolute; inset: 0; background: var(--charcoal); }
.hero-photo { width: 100%; height: 100%; object-fit: cover; object-position: 62% 42%; display: block; }
.hero-scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(23, 27, 32, .82) 0%, rgba(23, 27, 32, .58) 42%, rgba(23, 27, 32, .18) 72%, rgba(23, 27, 32, .12) 100%),
    linear-gradient(0deg, rgba(23, 27, 32, .38) 0%, rgba(23, 27, 32, 0) 38%);
}
.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: clamp(460px, 38vw, 540px);
  padding: 48px 56px;
}
.hero-copy { max-width: 560px; }
.hero .eyebrow { color: #ecd9a0; }
.hero h1 {
  margin: 18px 0 16px;
  font-size: clamp(38px, 4.6vw, 66px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.025em;
  color: var(--white);
}
.hero-lead { max-width: 520px; margin-bottom: 0; font-size: 16.5px; line-height: 1.65; color: rgba(255, 255, 255, .88); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

@media (max-width: 1100px) {
  :root { --gutter: 24px; }
  .hero { margin: 20px 24px 0; }
  .hero-content { padding: 44px 40px; }
}
@media (max-width: 840px) {
  .hero { margin: 12px 16px 0; border-radius: 16px; }
  .hero-media { position: relative; aspect-ratio: 4 / 3; }
  .hero-scrim { background: linear-gradient(180deg, rgba(23, 27, 32, 0) 52%, rgba(23, 27, 32, .45) 100%); }
  .hero-photo { object-position: 62% 38%; }
  .hero-content { height: auto; padding: 24px; background: var(--charcoal); }
  .hero h1 { font-size: clamp(34px, 9.8vw, 42px); margin: 14px 0 12px; }
  .hero-lead { font-size: 15.5px; }
  .hero-actions { margin-top: 22px; }
}
@media (max-width: 420px) {
  .hero-actions { display: grid; grid-template-columns: 1fr; gap: 10px; }
  .hero-actions .button { width: 100%; }
}

/* --------------------------------------------------------------- sections */
.section { padding-block: var(--section-space); }
.section.alt { background: var(--surface); }
.page-head + .section { padding-top: clamp(28px, 4vw, 44px); }

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 36px;
}
.section-head h2 { margin-bottom: 0; }

h2 { font-size: clamp(26px, 3vw, 38px); font-weight: 700; }
.section h2 { margin-bottom: 20px; }
.lead { font-size: 17px; line-height: 1.7; color: var(--muted); }

.eyebrow {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--accent-dark);
}

/* stats strip */
.stat-strip { border-block: 1px solid var(--line); background: var(--white); }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 26px 28px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat strong { display: block; font-size: clamp(28px, 3vw, 38px); font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
.stat span { display: block; margin-top: 4px; font-size: 13.5px; color: var(--muted); }
@media (max-width: 760px) {
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat { padding: 20px; }
  .stat:nth-child(odd) { border-left: 0; padding-left: 0; }
  .stat:nth-child(n + 3) { border-top: 1px solid var(--line); }
}

/* editorial split (mengenal, contact CTA) */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
.split.top { align-items: start; }
.split h2 { margin-bottom: 18px; }
.split .lead { margin-bottom: 22px; }
.split-photo { border-radius: var(--radius-lg); overflow: hidden; }
.split-photo img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
@media (max-width: 840px) {
  .split { grid-template-columns: 1fr; gap: 28px; }
}

/* ----------------------------------------------------------------- cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.card:hover { transform: translateY(-3px); border-color: #d3d9df; box-shadow: var(--shadow-small); }
.card-media { aspect-ratio: 4 / 3; overflow: hidden; background: var(--surface); }
.card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-body { display: flex; flex-direction: column; gap: 8px; padding: 20px 22px 22px; }
.card-body h3 { margin: 0; font-size: 19px; line-height: 1.3; }
.card-body p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--muted); }
.card-label { font-size: 12px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--accent-dark); }
.clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ------------------------------------------------------------- news (home) */
.news-layout { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 4vw, 52px); align-items: start; }
.news-featured { display: block; }
.news-featured .news-media { border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.news-featured .news-media img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.news-featured h3 { margin: 18px 0 10px; font-size: 23px; line-height: 1.28; }
.news-featured h3 a:hover { color: var(--accent-dark); }
.news-featured p { margin-bottom: 0; font-size: 15px; color: var(--muted); }
.news-meta { display: flex; align-items: center; gap: 12px; }
.news-list-rows { border-top: 1px solid var(--line); }
.news-row { display: block; padding: 18px 2px; border-bottom: 1px solid var(--line); }
.news-row h3 { margin: 10px 0 0; font-size: 17px; line-height: 1.35; font-weight: 600; }
.news-row:hover h3 { color: var(--accent-dark); }
.news-single { max-width: 760px; }
.news-single .news-media { border-radius: var(--radius); overflow: hidden; }
.news-single .news-media img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.news-single h3 { margin: 18px 0 10px; font-size: 24px; }
@media (max-width: 840px) {
  .news-layout { grid-template-columns: 1fr; gap: 26px; }
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}
.badge.neutral { background: var(--surface-strong); color: var(--muted); }
.date { font-size: 13px; color: var(--muted); }

/* --------------------------------------------------------------- gallery */
.gallery-layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); grid-auto-rows: 236px; gap: 16px; }
.gallery-layout figure { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.gallery-layout figure:first-child { grid-row: span 2; }
.gallery-layout img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-layout figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 30px 16px 12px;
  font-size: 12.5px;
  line-height: 1.45;
  color: #fff;
  background: linear-gradient(180deg, rgba(23, 27, 32, 0), rgba(23, 27, 32, .72));
}
.gallery-layout.count-1 { grid-template-columns: 1fr; grid-auto-rows: minmax(280px, 420px); }
.gallery-layout.count-1 figure:first-child { grid-row: span 1; }
.gallery-layout.count-2 figure:first-child { grid-row: 1 / span 2; }
.gallery-layout.count-2 figure:nth-child(2) { grid-row: 1 / span 2; }
@media (max-width: 760px) {
  .gallery-layout { grid-template-columns: 1fr; grid-auto-rows: auto; }
  .gallery-layout figure { aspect-ratio: 4 / 3; }
  .gallery-layout figure:first-child { grid-row: auto; aspect-ratio: 4 / 3; }
}

/* Full gallery page: uniform photo grid. */
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.photo-grid figure { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.photo-grid img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.photo-grid figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 28px 14px 11px;
  font-size: 12.5px;
  line-height: 1.45;
  color: #fff;
  background: linear-gradient(180deg, rgba(23, 27, 32, 0), rgba(23, 27, 32, .72));
}
@media (max-width: 560px) {
  .photo-grid { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------ contact CTA */
.contact-cta .split { align-items: center; }
.contact-cta h2 { margin-bottom: 0; font-size: clamp(24px, 2.6vw, 32px); }
.contact-cta .lead { margin-bottom: 20px; }

/* --------------------------------------------------------------- page head */
.page-head { padding-block: 40px clamp(24px, 3vw, 34px); background: transparent; }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px 10px; margin: 0 0 14px; padding: 0; list-style: none; font-size: 12.5px; color: var(--muted); }
.crumbs li { display: flex; align-items: center; gap: 10px; }
.crumbs li + li::before { content: "/"; color: #b6bdc4; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }
.page-head h1 { margin-bottom: 14px; font-size: clamp(30px, 3.4vw, 42px); }
.page-head .lead { max-width: 680px; margin-bottom: 0; }

.page-cover { margin: 4px 0 clamp(28px, 4vw, 44px); border-radius: var(--radius-lg); overflow: hidden; }
.page-cover img { display: block; width: 100%; aspect-ratio: 12 / 5; object-fit: cover; }

/* ----------------------------------------------------------------- prose */
.prose { font-size: 17px; line-height: 1.75; }
.prose > :first-child { margin-top: 0; }
.prose p { margin-bottom: 1.1em; }
.prose h2 { margin: 1.6em 0 .6em; font-size: 26px; }
.prose h3 { margin: 1.4em 0 .5em; font-size: 20px; }
.prose ul, .prose ol { padding-left: 1.4em; margin-bottom: 1.1em; }
.prose li { margin-bottom: .35em; }
.prose a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 3px; }
.prose img { border-radius: 12px; }
.prose blockquote { margin: 1.4em 0; padding: 6px 0 6px 20px; border-left: 3px solid var(--accent); color: var(--muted); }

/* ----------------------------------------------------------------- filters */
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 34px; }
.toolbar input[type="search"], .toolbar input[type="text"], .toolbar select {
  min-height: 46px;
  padding: 10px 14px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--ink);
}
.toolbar input[type="search"], .toolbar input[type="text"] { flex: 1 1 240px; }
.toolbar input:focus, .toolbar select:focus { border-color: var(--accent); outline: 3px solid rgba(198, 154, 36, .3); outline-offset: 0; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 30px; }
.chip {
  padding: 9px 17px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  transition: border-color .16s ease, color .16s ease, background-color .16s ease;
}
.chip:hover { border-color: #cfd5db; color: var(--ink); }
.chip.active { background: var(--ink); border-color: var(--ink); color: var(--white); }

/* ---------------------------------------------------------- posts listing */
.post-rows { border-top: 1px solid var(--line); }
.post-row { display: block; padding: 26px 2px; border-bottom: 1px solid var(--line); }
.post-row .news-meta { margin-bottom: 10px; }
.post-row h2 { margin: 0 0 8px; font-size: 21px; line-height: 1.35; }
.post-row:hover h2 { color: var(--accent-dark); }
.post-row p { margin: 0; max-width: 720px; font-size: 15px; color: var(--muted); }

.pagination { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 38px; }
.pagination a {
  display: grid;
  place-items: center;
  min-width: 42px;
  height: 42px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  font-weight: 600;
  color: var(--muted);
  transition: border-color .16s ease, color .16s ease, background-color .16s ease;
}
.pagination a:hover { border-color: #cfd5db; color: var(--ink); }
.pagination a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--ink); font-weight: 700; }

/* ------------------------------------------------------------------ empty */
.empty-state {
  padding: 48px 28px;
  background: var(--surface);
  border: 1px dashed #d9dee3;
  border-radius: var(--radius-lg);
  text-align: center;
}
.empty-state h2 { margin-bottom: 8px; font-size: 21px; }
.empty-state p { margin: 0; font-size: 14.5px; color: var(--muted); }

/* ------------------------------------------------------------------- info */
.hamlet-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.hamlet { padding: 24px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.hamlet .index { font-size: 12.5px; font-weight: 700; color: var(--accent-dark); }
.hamlet h3 { margin: 8px 0 6px; font-size: 18px; }
.hamlet p { margin: 0; font-size: 14.5px; color: var(--muted); }

.official-group { margin-top: 44px; }
.official-group:first-of-type { margin-top: 0; }
.official-group > h3 {
  margin: 0 0 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.official-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.official { display: flex; align-items: center; gap: 16px; padding: 20px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.official .avatar { flex: 0 0 auto; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-dark); font-weight: 800; font-size: 15px; }
.official strong { display: block; font-size: 15.5px; line-height: 1.35; }
.official p { margin: 3px 0 0; font-size: 13.5px; color: var(--muted); }

.leader-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-bottom: 8px; }
.leader { display: flex; align-items: center; gap: 20px; padding: 28px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.leader .avatar { flex: 0 0 auto; display: grid; place-items: center; width: 60px; height: 60px; border-radius: 50%; background: var(--ink); color: var(--accent); font-weight: 800; font-size: 19px; }
.avatar-photo { overflow: hidden; padding: 0; background: var(--surface); }
.avatar-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.leader strong { display: block; font-size: 19px; line-height: 1.3; }
.leader p { margin: 4px 0 0; font-size: 14px; color: var(--accent-dark); font-weight: 600; }

@media (max-width: 900px) {
  .hamlet-grid, .official-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  .hamlet-grid, .official-grid, .leader-grid { grid-template-columns: 1fr; }
}

/* ----------------------------------------------------------------- detail */
.article-head { padding-block: 40px 26px; }
.article-head h1 { max-width: 860px; margin: 12px 0 14px; font-size: clamp(28px, 3.6vw, 44px); line-height: 1.16; }
.article-head .lead { max-width: 720px; }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.article-media { margin: 4px auto clamp(28px, 4vw, 44px); max-width: 920px; border-radius: var(--radius-lg); overflow: hidden; }
.article-media img { display: block; width: 100%; aspect-ratio: 12 / 5; object-fit: cover; }
.article-body { max-width: 720px; margin-inline: auto; }
.article-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  margin-top: 48px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}
.preview-note { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; color: var(--accent-dark); }

/* ------------------------------------------------------------------ contact */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(28px, 4vw, 56px); align-items: start; }
.contact-list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.contact-item { padding: 20px 0; border-bottom: 1px solid var(--line); }
.contact-item .eyebrow { margin-bottom: 6px; }
.contact-item .value { margin: 0; font-size: 17px; font-weight: 600; line-height: 1.55; overflow-wrap: anywhere; white-space: pre-line; }
.contact-item a:hover { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 3px; }
.map-panel {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
  min-height: 300px;
  padding: 32px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
}
.map-panel h2 { margin-bottom: 10px; font-size: 21px; }
.map-panel p { margin: 0; font-size: 14.5px; color: var(--muted); }
@media (max-width: 840px) {
  .contact-grid { grid-template-columns: 1fr; }
}

/* ------------------------------------------------------------ error pages */
.error-page { min-height: 62vh; display: grid; place-items: center; padding: 60px 24px; text-align: center; }
.error-page .code { font-size: 13px; font-weight: 800; letter-spacing: 0.1em; color: var(--accent-dark); }
.error-page h1 { margin: 14px 0 12px; font-size: clamp(30px, 4.4vw, 46px); }
.error-page p { margin-bottom: 26px; color: var(--muted); }

/* ----------------------------------------------------------------- footer */
.site-footer { margin-top: 8px; background: var(--charcoal); color: #c9cfd6; }
.footer-inner { display: grid; grid-template-columns: 1.7fr 1fr 1fr; gap: 40px; padding: 56px 0 40px; }
.footer-inner.has-contact { grid-template-columns: 1.5fr 1fr 1fr 1.2fr; }
.footer-brand strong { display: block; font-size: 17px; font-weight: 800; color: var(--white); letter-spacing: -0.015em; }
.footer-brand p { margin: 8px 0 0; font-size: 13.5px; line-height: 1.6; color: #98a0a8; max-width: 340px; }
.footer-label { margin: 0 0 14px; font-size: 12px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: #98a0a8; }
.footer-col { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.footer-col a, .footer-col span { font-size: 14px; color: #c9cfd6; overflow-wrap: anywhere; }
.footer-col a { transition: color .16s ease; }
.footer-col a:hover { color: var(--white); text-decoration: underline; text-underline-offset: 3px; }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
  padding: 20px 0 26px;
  border-top: 1px solid rgba(255, 255, 255, .14);
  font-size: 12.5px;
  color: #98a0a8;
}
.footer-bottom a { color: #98a0a8; }
.footer-bottom a:hover { color: var(--white); }
@media (max-width: 840px) {
  .footer-inner, .footer-inner.has-contact { grid-template-columns: 1fr 1fr; gap: 32px 24px; padding: 44px 0 32px; }
  .footer-brand { grid-column: 1 / -1; }
}

/* -------------------------------------------------------------- animation */
.js .reveal { opacity: 0; transform: translateY(26px); }
.js .reveal.is-in {
  opacity: 1;
  transform: none;
  transition: opacity .7s cubic-bezier(.22, .68, .3, 1), transform .7s cubic-bezier(.22, .68, .3, 1);
}

/* Large photos drift slightly while scrolling (offsets set by site.js). */
.js [data-drift] {
  will-change: transform;
  transform: translate3d(0, var(--drift-y, 0px), 0) scale(var(--drift-scale, 1.02));
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal, .js .reveal.is-in { opacity: 1; transform: none; transition: none; }
  .js [data-drift] { transform: none; will-change: auto; }
}

/* small screens */
@media (max-width: 640px) {
  :root { --gutter: 20px; }
}
@media (max-width: 400px) {
  :root { --gutter: 16px; }
}
