/* =========================================================
   Surabaya Worker Support — styles
   Light/dark via CSS variables; no framework, no build step.
   ========================================================= */

:root {
  /* brand */
  --brand: #000072;
  --brand-strong: #00004f;
  --brand-tint: #e8e8f4;

  /* surfaces */
  --bg: #f3f0e7;
  --paper: #fffdf8;
  --paper-2: #f7f4ec;

  /* ink */
  --ink: #171717;
  --muted: #5a5852;
  --line: #d0ccc2;
  --line-strong: #b6b1a3;

  /* on-brand (used over the dark blue section) */
  --on-brand: #ffffff;
  --on-brand-muted: rgba(255, 255, 255, 0.72);
  --on-brand-line: rgba(255, 255, 255, 0.22);

  /* accents */
  --focus: #000072;
  --danger: #8a1c1c;

  /* radii / sizes */
  --radius: 16px;
  --container: 1200px;
  --header-h: 76px;

  /* type */
  --font-display: "Archivo Black", "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* motion */
  --t-fast: 120ms;
  --t-base: 180ms;
  --ease: cubic-bezier(0.2, 0.6, 0.2, 1);
}

[data-theme="dark"] {
  --brand: #5a5cff;
  --brand-strong: #8a8dff;
  --brand-tint: #1a1c4a;

  --bg: #0a0a1f;
  --paper: #12132e;
  --paper-2: #181a3a;

  --ink: #f1efe6;
  --muted: #9b9bb0;
  --line: #2a2c52;
  --line-strong: #3a3d6a;

  --on-brand: #f1efe6;
  --on-brand-muted: rgba(241, 239, 230, 0.7);
  --on-brand-line: rgba(241, 239, 230, 0.18);

  --focus: #8a8dff;
}

/* honor the user's preferred theme until they pick one */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --brand: #5a5cff;
    --brand-strong: #8a8dff;
    --brand-tint: #1a1c4a;
    --bg: #0a0a1f;
    --paper: #12132e;
    --paper-2: #181a3a;
    --ink: #f1efe6;
    --muted: #9b9bb0;
    --line: #2a2c52;
    --line-strong: #3a3d6a;
    --on-brand: #f1efe6;
    --on-brand-muted: rgba(241, 239, 230, 0.7);
    --on-brand-line: rgba(241, 239, 230, 0.18);
    --focus: #8a8dff;
  }
}

/* =========================================================
   Reset
   ========================================================= */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
}

body { overflow-x: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

img, svg, video { display: block; max-width: 100%; height: auto; }

h1, h2, h3, h4, h5, h6 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 0.95;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

p { margin: 0; }

a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

button, input, textarea {
  font: inherit;
  color: inherit;
}

button { background: none; border: 0; cursor: pointer; }

ul, ol { margin: 0; padding: 0; list-style: none; }

::selection { background: var(--brand); color: var(--on-brand); }

/* =========================================================
   Layout primitives
   ========================================================= */

.container {
  width: min(calc(100% - 32px), var(--container));
  margin-inline: auto;
}

.section { padding: clamp(64px, 8vw, 112px) 0; }
.section--paper { background: var(--paper); }
.section--blue { background: var(--brand); color: var(--on-brand); }

.section-heading {
  max-width: 820px;
  margin-bottom: clamp(36px, 5vw, 64px);
}
.section-heading h2 {
  color: var(--brand);
  font-size: clamp(2.4rem, 6.4vw, 4.8rem);
  line-height: 0.92;
  letter-spacing: -0.045em;
  margin-bottom: 18px;
}
.section-heading p {
  max-width: 660px;
  color: var(--muted);
  font-size: clamp(1rem, 1.2vw, 1.08rem);
  line-height: 1.55;
}

.section--blue .section-heading p,
.section--blue .muted-on-dark { color: var(--on-brand-muted); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
}
.eyebrow::before {
  width: 32px;
  height: 2px;
  background: currentColor;
  content: "";
}
.section--blue .eyebrow { color: var(--on-brand); }

/* =========================================================
   Buttons
   ========================================================= */

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 22px;
  border: 2px solid var(--brand);
  background: var(--brand);
  color: var(--on-brand);
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  transition: transform var(--t-base) var(--ease),
              background-color var(--t-base) var(--ease),
              color var(--t-base) var(--ease),
              box-shadow var(--t-base) var(--ease);
}

.button:hover {
  background: var(--brand-strong);
  transform: translateY(-1px);
  box-shadow: 0 6px 0 -2px var(--brand);
}
.button:active { transform: translateY(0); box-shadow: none; }

.button--light {
  background: var(--paper);
  color: var(--brand);
  border-color: var(--paper);
}
.button--light:hover {
  background: var(--on-brand);
  color: var(--brand);
  box-shadow: 0 6px 0 -2px rgba(255, 255, 255, 0.45);
}
[data-theme="dark"] .button--light {
  background: var(--on-brand);
  color: var(--bg);
  border-color: var(--on-brand);
}
[data-theme="dark"] .button--light:hover {
  background: var(--paper);
  color: var(--brand);
  box-shadow: none;
}

.button--outline {
  background: transparent;
  color: var(--brand);
}
.button--outline:hover {
  background: var(--brand-tint);
  box-shadow: none;
}

.button--outline-light {
  background: transparent;
  color: var(--on-brand);
  border-color: var(--on-brand);
}
.button--outline-light:hover {
  background: var(--on-brand);
  color: var(--brand);
  box-shadow: none;
}

/* =========================================================
   Placeholder (X-cross) — keeps wireframe intent intact
   ========================================================= */

.placeholder {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(
      to top right,
      transparent calc(50% - 0.6px),
      var(--line-strong) 50%,
      transparent calc(50% + 0.6px)
    ),
    linear-gradient(
      to bottom right,
      transparent calc(50% - 0.6px),
      var(--line-strong) 50%,
      transparent calc(50% + 0.6px)
    ),
    var(--paper-2);
  border: 2px solid var(--brand);
}
.placeholder::after {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  padding: 6px 12px;
  background: var(--paper);
  color: var(--muted);
  content: attr(data-label);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  border: 1px solid var(--line);
}
[data-theme="dark"] .placeholder::after { background: var(--paper-2); color: var(--muted); border-color: var(--line); }

.wire-label {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.wire-line {
  display: block;
  width: 100%;
  height: 10px;
  margin-top: 8px;
  background: #d8d5cc;
  border-radius: 2px;
}
[data-theme="dark"] .wire-line { background: #2a2c52; }
.wire-line--100 { width: 100%; }
.wire-line--90 { width: 90%; }
.wire-line--85 { width: 85%; }
.wire-line--80 { width: 80%; }
.wire-line--75 { width: 75%; }
.wire-line--70 { width: 70%; }
.wire-line--65 { width: 65%; }
.wire-line--60 { width: 60%; }
.wire-line--55 { width: 55%; }
.wire-line--45 { width: 45%; }

.section--blue .wire-label,
.section--blue .agenda-copy .wire-label,
.section--blue .contribute-copy .wire-label,
.program-card--feature .wire-label,
.partner-copy .wire-label {
  color: var(--on-brand-muted);
}
.section--blue .wire-line,
.section--blue .agenda-copy .wire-line,
.section--blue .contribute-copy .wire-line,
.program-card--feature .wire-line,
.partner-copy .wire-line {
  background: rgba(255, 255, 255, 0.18);
}

.wire-quote { display: grid; gap: 0; margin: 0; }
.wire-avatar {
  width: 44px;
  aspect-ratio: 1;
  border: 1px solid var(--brand);
  border-radius: 50%;
  background: var(--brand-tint);
}

/* =========================================================
   Skip link
   ========================================================= */

.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 100;
  padding: 12px 18px;
  background: var(--brand);
  color: var(--on-brand);
  font-weight: 800;
  transition: top var(--t-base) var(--ease);
}
.skip-link:focus { top: 16px; }

/* =========================================================
   Header
   ========================================================= */

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 2px solid var(--brand);
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  /* ponytail: backdrop-filter intentionally omitted — it would make
     the .nav-links (a child) a containing-block, breaking its
     position: fixed viewport-relative mobile menu. The slightly
     opaque background gives a similar depth without the bug. */
}
[data-theme="dark"] .site-header {
  background: color-mix(in srgb, var(--bg) 94%, transparent);
}

.nav {
  display: flex;
  min-height: var(--header-h);
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--brand);
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 0.95;
}
.brand-mark {
  display: block;
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: 0;
  flex: 0 0 auto;
}
.brand-mark--fallback {
  display: grid;
  place-items: center;
  background: var(--brand);
  color: var(--on-brand);
  font-size: 0.85rem;
  font-weight: 900;
  text-align: center;
}
.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 0.95;
}
.brand-text-1 { color: var(--muted); font-weight: 800; font-size: 0.7rem; letter-spacing: 0.04em; }
.brand-text-2 { color: var(--brand); font-weight: 900; }

.nav-end {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}
.nav-links > a {
  position: relative;
  padding: 8px 2px;
  transition: color var(--t-base) var(--ease);
}
.nav-links > a:hover { color: var(--brand); }
.nav-links > a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t-base) var(--ease);
}
.nav-links > a:hover::after { transform: scaleX(1); }
.nav-links > .button { padding: 0 18px; min-height: 42px; font-size: 0.88rem; }
.nav-links > .button::after { display: none; }

/* theme toggle */
.theme-toggle {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 2px solid var(--brand);
  background: var(--paper);
  color: var(--brand);
  transition: background-color var(--t-base) var(--ease), color var(--t-base) var(--ease);
}
.theme-toggle:hover { background: var(--brand-tint); }
.theme-icon { width: 18px; height: 18px; }
.theme-icon--moon { display: none; }
[data-theme="dark"] .theme-icon--sun { display: none; }
[data-theme="dark"] .theme-icon--moon { display: block; }

/* mobile menu toggle */
.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 2px solid var(--brand);
  background: var(--paper);
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  transition: background-color var(--t-base) var(--ease);
}
.nav-toggle:hover { background: var(--brand-tint); }
.nav-toggle-bar {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--brand);
  transition: transform var(--t-base) var(--ease);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(3.5px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  transform: translateY(-3.5px) rotate(-45deg);
}

/* =========================================================
   Hero
   ========================================================= */

.hero { padding: clamp(20px, 4vw, 48px) 0 clamp(20px, 4vw, 32px); }

.hero-shell {
  border: 2px solid var(--brand);
  background: var(--paper);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  min-height: 560px;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
}
.hero-grid > * { min-width: 0; }

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(36px, 6vw, 80px);
}
.hero-copy h1 {
  font-size: clamp(2.6rem, 8.4vw, 6.2rem);
  line-height: 0.92;
  letter-spacing: -0.05em;
  text-transform: uppercase;
  color: var(--brand);
  max-width: 100%;
  margin: 0;
  text-wrap: balance;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: manual;
}
.hero-copy p {
  max-width: 52ch;
  margin-top: 26px;
  color: var(--muted);
  font-size: clamp(1rem, 1.2vw, 1.12rem);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.hero-art {
  display: grid;
  grid-template-rows: 1fr auto;
  border-left: 2px solid var(--brand);
  background: var(--brand-tint);
  min-height: 460px;
}
.hero-photo { min-height: 420px; }
.hero-note {
  padding: 22px 24px;
  background: var(--brand);
  color: var(--on-brand);
}
.hero-note strong {
  display: block;
  margin-bottom: 4px;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.005em;
}
.hero-note span {
  color: var(--on-brand-muted);
  font-size: 0.88rem;
}

/* identity bar */
.identity-bar {
  display: grid;
  grid-template-columns: 1.25fr repeat(3, 1fr);
  border-top: 2px solid var(--brand);
}
.identity-intro,
.identity-item { padding: 24px 26px; }
.identity-intro {
  background: var(--brand);
  color: var(--on-brand);
  font-weight: 800;
  font-size: 0.95rem;
  line-height: 1.3;
}
.identity-item + .identity-item { border-left: 2px solid var(--brand); }
.identity-intro + .identity-item { border-left: 0; }
.identity-item strong {
  display: block;
  color: var(--brand);
  font-size: clamp(1.5rem, 2vw, 1.8rem);
  line-height: 1;
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}
.identity-item span {
  display: block;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.4;
}

/* =========================================================
   Agenda panel
   ========================================================= */

.agenda-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  border: 2px solid var(--brand);
  background: var(--paper);
}
.agenda-panel > * { min-width: 0; }
.agenda-copy {
  padding: clamp(32px, 5vw, 64px);
  background: var(--brand);
  color: var(--on-brand);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.agenda-copy h2 {
  font-size: clamp(2.2rem, 5.4vw, 4.2rem);
  line-height: 0.95;
  letter-spacing: -0.05em;
  margin-bottom: 20px;
  color: var(--on-brand);
}
.agenda-copy p { max-width: 480px; margin-bottom: 28px; color: var(--on-brand-muted); }
.agenda-copy .button { align-self: flex-start; }

.agenda-card {
  display: grid;
  align-content: center;
  gap: 22px;
  padding: clamp(32px, 5vw, 64px);
}
.agenda-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}
.agenda-row:last-child { border-bottom: 0; padding-bottom: 0; }
.agenda-row span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding-top: 4px;
}
.agenda-row strong {
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--ink);
}

/* =========================================================
   About
   ========================================================= */

.about-grid {
  display: grid;
  align-items: start;
  gap: clamp(40px, 6vw, 80px);
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
}
.about-grid > * { min-width: 0; }
.about-poster { min-height: 620px; }
.about-copy h2 {
  font-size: clamp(2.2rem, 5.4vw, 4.4rem);
  line-height: 0.95;
  letter-spacing: -0.05em;
  margin-bottom: 22px;
  color: var(--brand);
}
.about-copy > p { margin-bottom: 32px; color: var(--muted); }

.principles { border-top: 2px solid var(--brand); }
.principle {
  display: grid;
  grid-template-columns: 78px 1fr;
  gap: 24px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  align-items: start;
}
.principle-number {
  color: var(--brand);
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1;
  font-weight: 900;
}
.principle h3 {
  margin-bottom: 10px;
  font-size: 1.05rem;
  font-weight: 800;
  font-family: var(--font-body);
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink);
}
.principle p { color: var(--muted); font-size: 0.95rem; }

/* =========================================================
   Join (4-step flow)
   ========================================================= */

.join-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 24px;
}
.join-grid > * { min-width: 0; }
.join-intro,
.join-steps { border: 2px solid var(--brand); background: var(--paper); }
.join-intro {
  padding: 36px;
  background: var(--brand-tint);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.join-intro h3 {
  color: var(--brand);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
  margin-bottom: 16px;
}
.join-intro p { color: var(--muted); max-width: 36ch; }

.join-steps {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  counter-reset: step;
}
.join-step {
  position: relative;
  padding: 32px 28px;
}
.join-step + .join-step { border-left: 2px solid var(--brand); }
.join-step:nth-child(n+3) { border-top: 2px solid var(--brand); }
.join-step:nth-child(3) { border-left: 0; }
.join-step-number {
  display: block;
  margin-bottom: 14px;
  color: var(--brand);
  font-family: var(--font-display);
  font-size: 1.8rem;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -0.02em;
}
.join-step h4 {
  margin-bottom: 8px;
  font-size: 1rem;
  font-weight: 800;
  font-family: var(--font-body);
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink);
}
.join-step p { color: var(--muted); font-size: 0.93rem; line-height: 1.5; }

/* =========================================================
   Fit (cocok / tidak harus)
   ========================================================= */

.fit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.fit-card {
  border: 2px solid var(--brand);
  background: var(--paper);
  padding: 32px;
  display: flex;
  flex-direction: column;
}
.fit-card h3 {
  margin-bottom: 22px;
  color: var(--brand);
  font-size: clamp(1.4rem, 2.4vw, 1.7rem);
  line-height: 1;
  letter-spacing: -0.03em;
}
.fit-list { display: grid; gap: 0; }
.fit-item {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 14px;
  align-items: start;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}
.fit-item:first-child { border-top: 0; padding-top: 0; }
.fit-icon {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 2px solid var(--brand);
  font-weight: 900;
  font-size: 0.9rem;
  line-height: 1;
  background: var(--paper);
}
.fit-icon--plus { color: var(--brand); }
.fit-icon--minus { color: var(--muted); border-color: var(--line-strong); }
.fit-item p { color: var(--muted); font-size: 0.95rem; line-height: 1.5; }

/* =========================================================
   Programs
   ========================================================= */

.program-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px;
}
.program-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 320px;
  padding: 30px;
  border: 2px solid var(--brand);
  background: var(--paper);
  transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease);
}
.program-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 0 -4px var(--brand);
}
.program-card:nth-child(1) { grid-column: span 7; }
.program-card:nth-child(2),
.program-card:nth-child(3) { grid-column: span 5; }
.program-card:nth-child(4) { grid-column: span 12; }

.program-card--feature { background: var(--brand); color: var(--on-brand); }
.program-card--feature .program-index { color: var(--on-brand-muted); }
.program-card--feature p { color: var(--on-brand-muted); }

.program-index {
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 18px;
}
.program-card h3 {
  font-size: clamp(1.8rem, 3.4vw, 3rem);
  line-height: 0.95;
  letter-spacing: -0.045em;
  margin: 0 0 14px;
  color: inherit;
}
.program-card p { color: var(--muted); max-width: 56ch; font-size: 0.95rem; }

/* =========================================================
   Gallery
   ========================================================= */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px;
}
.gallery-card {
  border: 2px solid var(--brand);
  background: var(--paper);
  display: flex;
  flex-direction: column;
  transition: transform var(--t-base) var(--ease);
}
.gallery-card:hover { transform: translateY(-2px); }
.gallery-card:nth-child(1) { grid-column: span 7; }
.gallery-card:nth-child(2),
.gallery-card:nth-child(3) { grid-column: span 5; }
.gallery-card:nth-child(4) { grid-column: span 12; }
.gallery-image {
  min-height: 320px;
  border: 0;
  border-bottom: 2px solid var(--brand);
}
.gallery-card:nth-child(2) .gallery-image,
.gallery-card:nth-child(3) .gallery-image { min-height: 240px; }
.gallery-card:nth-child(4) .gallery-image { min-height: 280px; }
.gallery-copy { padding: 24px 26px; }
.gallery-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin-bottom: 12px;
  color: var(--brand);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.gallery-copy h3 {
  margin-bottom: 8px;
  font-size: 1.25rem;
  font-weight: 800;
  font-family: var(--font-body);
  text-transform: none;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.gallery-copy p { color: var(--muted); font-size: 0.92rem; }

/* =========================================================
   Stories
   ========================================================= */

.stories-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.story-card {
  border: 2px solid var(--brand);
  background: var(--paper);
  padding: 30px;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  margin: 0;
  transition: transform var(--t-base) var(--ease);
}
.story-card:hover { transform: translateY(-2px); }
.story-card .wire-quote {
  color: var(--brand);
  font-family: var(--font-display);
  font-size: 1.18rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
  text-transform: none;
}
.story-person {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 12px;
  margin-top: auto;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.story-person .wire-label { margin-bottom: 4px; }

/* =========================================================
   Contribute panel
   ========================================================= */

.contribute-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  border: 2px solid var(--brand);
  background: var(--paper);
}
.contribute-panel > * { min-width: 0; }
.contribute-copy {
  padding: clamp(32px, 5vw, 64px);
  background: var(--brand);
  color: var(--on-brand);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.contribute-copy h2 {
  font-size: clamp(2.2rem, 5.4vw, 4.4rem);
  line-height: 0.95;
  letter-spacing: -0.05em;
  margin-bottom: 20px;
  color: var(--on-brand);
}
.contribute-copy p { max-width: 480px; color: var(--on-brand-muted); }

.contribute-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.contribute-item {
  padding: 28px;
  border-left: 2px solid var(--brand);
  border-bottom: 2px solid var(--brand);
  min-height: 170px;
}
.contribute-item strong {
  display: block;
  margin-bottom: 8px;
  color: var(--brand);
  font-size: 1.05rem;
  font-weight: 800;
}
.contribute-item p { color: var(--muted); font-size: 0.93rem; }

/* =========================================================
   Partnership (on dark section)
   ========================================================= */

.partner-layout {
  display: grid;
  gap: clamp(40px, 6vw, 80px);
  align-items: start;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
}
.partner-layout > * { min-width: 0; }
.partner-copy h2 {
  font-size: clamp(2.2rem, 5.4vw, 4.4rem);
  line-height: 0.95;
  letter-spacing: -0.05em;
  margin-bottom: 20px;
  color: var(--on-brand);
}
.partner-copy p { color: var(--on-brand-muted); margin-bottom: 28px; max-width: 48ch; }

.partner-types { display: grid; gap: 0; }
.partner-type {
  padding: 22px 0;
  border-top: 1px solid var(--on-brand-line);
}
.partner-type:last-child { border-bottom: 1px solid var(--on-brand-line); }
.partner-type strong {
  display: block;
  margin-bottom: 6px;
  color: var(--on-brand);
  font-size: 1.05rem;
  font-weight: 800;
}
.partner-type span { color: var(--on-brand-muted); font-size: 0.92rem; display: block; }

/* =========================================================
   FAQ
   ========================================================= */

.faq-grid { display: grid; gap: 12px; }
.faq-item {
  border: 2px solid var(--brand);
  background: var(--paper);
  transition: background-color var(--t-base) var(--ease);
}
.faq-item[open] { background: var(--brand-tint); }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 22px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--brand);
  font-weight: 800;
  font-size: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary > span:first-child { line-height: 1.35; }
.faq-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 2px solid var(--brand);
  background: var(--paper);
  font-weight: 900;
  font-size: 1rem;
  line-height: 1;
  position: relative;
  flex: 0 0 28px;
  transition: background-color var(--t-base) var(--ease);
}
.faq-icon::before, .faq-icon::after {
  content: "";
  position: absolute;
  background: var(--brand);
  transition: transform var(--t-base) var(--ease);
}
.faq-icon::before { width: 12px; height: 2px; }
.faq-icon::after { width: 2px; height: 12px; }
.faq-item[open] .faq-icon::after { transform: scaleY(0); }
.faq-answer {
  padding: 0 24px 24px;
  color: var(--muted);
  max-width: 780px;
  line-height: 1.6;
}

/* =========================================================
   Contact
   ========================================================= */

.contact-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  border: 2px solid var(--brand);
  background: var(--paper);
}
.contact-panel > * { min-width: 0; }
.contact-copy {
  padding: clamp(32px, 5vw, 64px);
}
.contact-copy h2 {
  font-size: clamp(2.4rem, 5.4vw, 4.6rem);
  line-height: 0.92;
  letter-spacing: -0.055em;
  margin-bottom: 22px;
  color: var(--brand);
}
.contact-copy > p { max-width: 50ch; margin-bottom: 32px; color: var(--muted); }

.social-links { display: grid; gap: 12px; }
.social-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 64px;
  padding: 0 22px;
  border: 2px solid var(--brand);
  background: var(--paper);
  color: var(--brand);
  font-weight: 800;
  transition: background-color var(--t-base) var(--ease), color var(--t-base) var(--ease);
}
.social-link:hover { background: var(--brand); color: var(--on-brand); }
.social-link:hover .social-link-handle { color: var(--on-brand-muted); }
.social-link-label { font-size: 0.95rem; }
.social-link-handle {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--muted);
  transition: color var(--t-base) var(--ease);
}

.contact-form {
  display: grid;
  align-content: center;
  gap: 18px;
  padding: clamp(32px, 5vw, 64px);
  border-left: 2px solid var(--brand);
  background: var(--brand-tint);
}
.form-hint { color: var(--muted); margin: -4px 0 6px; font-size: 0.92rem; }

.field { display: grid; gap: 8px; }
.field label {
  color: var(--brand);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.field input,
.field textarea {
  width: 100%;
  padding: 0 16px;
  border: 2px solid var(--brand);
  background: var(--paper);
  color: var(--ink);
  outline: none;
  font: inherit;
  transition: border-color var(--t-base) var(--ease), background-color var(--t-base) var(--ease);
}
.field input { min-height: 50px; }
.field textarea {
  min-height: 140px;
  padding: 14px 16px;
  resize: vertical;
}
.field input::placeholder,
.field textarea::placeholder { color: var(--muted); opacity: 0.7; }
.field input:focus-visible,
.field textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.form-status { color: var(--brand); font-weight: 700; font-size: 0.9rem; min-height: 1.2em; }
.form-status[data-state="error"] { color: var(--danger); }

/* =========================================================
   Footer
   ========================================================= */

.site-footer {
  padding: 56px 0 40px;
  border-top: 2px solid var(--brand);
  background: var(--paper);
}
.footer-grid {
  display: grid;
  align-items: start;
  gap: 40px;
  grid-template-columns: 1.4fr 1fr;
}
.footer-brand { max-width: 540px; }
.footer-copy {
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.55;
}
.footer-right { text-align: right; }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 20px;
  margin-bottom: 18px;
  color: var(--brand);
  font-weight: 700;
  font-size: 0.9rem;
}
.footer-links a { transition: opacity var(--t-base) var(--ease); }
.footer-links a:hover { opacity: 0.65; }
.footer-note { color: var(--muted); font-size: 0.82rem; }

/* =========================================================
   Responsive — tablet
   ========================================================= */

@media (max-width: 980px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: fixed;
    top: var(--header-h);
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 40;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 32px 24px;
    background: var(--bg);
    border-top: 2px solid var(--brand);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform var(--t-base) var(--ease);
  }
  .nav-links[data-open="true"] { transform: translateX(0); }
  .nav-links > a {
    padding: 18px 0;
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--ink);
    border-bottom: 1px solid var(--line);
  }
  .nav-links > a:not(.button) { color: var(--ink); }
  .nav-links > .button { color: var(--on-brand); }
  .nav-links > a::after { display: none; }
  .nav-links > .button {
    margin-top: 24px;
    width: 100%;
    min-height: 52px;
    font-size: 1rem;
  }

  .hero-grid,
  .agenda-panel,
  .about-grid,
  .join-grid,
  .fit-grid,
  .contribute-panel,
  .partner-layout,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .hero-art {
    border-top: 2px solid var(--brand);
    border-left: 0;
  }

  .identity-bar { grid-template-columns: 1fr 1fr; }
  .identity-item + .identity-item { border-left: 0; }
  .identity-item:nth-child(even) { border-left: 2px solid var(--brand); }
  .identity-item:nth-child(n+3) { border-top: 2px solid var(--brand); }

  .join-steps { grid-template-columns: 1fr; }
  .join-step + .join-step { border-left: 0; border-top: 2px solid var(--brand); }
  .join-step:nth-child(3) { border-left: 0; }

  .stories-grid { grid-template-columns: 1fr; }

  .contact-form {
    border-top: 2px solid var(--brand);
    border-left: 0;
  }

  .footer-grid { grid-template-columns: 1fr; }
  .footer-right { text-align: left; }
  .footer-links { justify-content: flex-start; }
}

/* =========================================================
   Responsive — phone
   ========================================================= */

@media (max-width: 640px) {
  :root { --header-h: 68px; }

  .section { padding: 56px 0; }
  .container { width: min(calc(100% - 24px), var(--container)); }

  .hero { padding: 12px 0 8px; }
  .hero-copy { padding: 36px 24px 40px; }
  .hero-photo { min-height: 280px; }

  .identity-bar { grid-template-columns: 1fr; }
  .identity-item:nth-child(even),
  .identity-item + .identity-item { border-left: 0; }
  .identity-item:nth-child(n+2) { border-top: 2px solid var(--brand); }

  .agenda-row { grid-template-columns: 1fr; gap: 6px; }
  .agenda-row span { padding-top: 0; }

  .principle { grid-template-columns: 48px 1fr; gap: 16px; padding: 20px 0; }

  .program-card,
  .program-card:nth-child(1),
  .program-card:nth-child(2),
  .program-card:nth-child(3),
  .program-card:nth-child(4),
  .gallery-card,
  .gallery-card:nth-child(1),
  .gallery-card:nth-child(2),
  .gallery-card:nth-child(3),
  .gallery-card:nth-child(4) {
    grid-column: 1 / -1;
  }
  .program-card { min-height: 0; padding: 24px; }
  .gallery-image { min-height: 220px; }
  .gallery-card:nth-child(2) .gallery-image,
  .gallery-card:nth-child(3) .gallery-image { min-height: 220px; }

  .fit-grid,
  .contribute-grid { grid-template-columns: 1fr; }
  .contribute-item { border-left: 0; }
  .contribute-item + .contribute-item { border-top: 0; }

  .nav-end { gap: 8px; }
  .theme-toggle,
  .nav-toggle { width: 40px; height: 40px; }
  .brand-text-1 { font-size: 0.62rem; }
  .brand-text-2 { font-size: 0.72rem; }
  .brand-text { gap: 1px; }
}

/* =========================================================
   Reduced motion
   ========================================================= */

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