/*
Theme Name: 오클랜드 한인회
Theme URI: https://nz.korean.net
Author: blamejen
Description: Custom theme for The Korean Society of Auckland Inc. — 함께하는 우리, 오클랜드 한인회.
Version: 0.1.0
Requires PHP: 8.0
Text Domain: ksa
*/

/* ------------------------------------------------------------ tokens */
:root {
  --red: #d83025;
  --red-2: #ed4754;
  --blue: #0353a5;
  --blue-2: #1e6fd0;
  --purple: #6255a4;
  --ink: #2b2b2e;
  --ink-2: #55555a;
  --ink-3: #8a8a90;
  --line: #e6e6ea;
  --line-2: #f0f0f3;
  --bg: #ffffff;
  --bg-2: #f6f6f8;
  --bg-blue: #eef4fb;
  --bg-red: #fdf1f0;
  --grad: linear-gradient(120deg, #6255a4 0%, #c93a7a 55%, #ed4754 100%);
  --grad-soft: linear-gradient(135deg, rgba(98, 85, 164, 0.12), rgba(237, 71, 84, 0.12));
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;
  --wrap: 1200px;
  --wrap-narrow: 820px;
  --gutter: clamp(20px, 4vw, 44px);
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px rgba(43, 43, 46, 0.08);
  --shadow-sm: 0 2px 10px rgba(43, 43, 46, 0.06);
  --header-h: 84px;
}

/* ------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { font-size: 18px; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: clip; }
@media (max-width: 1023px) { html { font-size: 17px; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  word-break: keep-all;
  overflow-wrap: anywhere;
  -webkit-font-smoothing: antialiased;
}
body { overflow-x: clip; }
body.nav-open { overflow: hidden; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0; font-weight: 800; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; }
ul[class], ol[class] { list-style: none; }
button { font: inherit; }
iframe { border: 0; }
:focus-visible { outline: 3px solid var(--blue-2); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(var(--wrap), 100% - var(--gutter) * 2); margin-inline: auto; }
.wrap--narrow { width: min(var(--wrap-narrow), 100% - var(--gutter) * 2); }
.wrap--page { width: min(980px, 100% - var(--gutter) * 2); }
.content-wrap { padding: clamp(2rem, 5vw, 3.5rem) 0 clamp(3rem, 7vw, 5rem); }
.screen-reader-text, .skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 1rem; top: 1rem; z-index: 999; background: var(--ink); color: #fff; padding: 0.6rem 1rem; border-radius: 8px; }
.muted { color: var(--ink-3); }
.eyebrow { font-size: 0.9rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--blue); margin: 0 0 0.6rem; }
.eyebrow--grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
.tag { display: inline-block; font-size: 0.78rem; font-weight: 700; padding: 0.15em 0.6em; border-radius: 999px; background: var(--bg-blue); color: var(--blue); white-space: nowrap; }
.tag--red { background: var(--bg-red); color: var(--red); }
.new { display: inline-block; vertical-align: 2px; margin-left: 0.3em; font-size: 0.66rem; font-weight: 800; line-height: 1; padding: 0.3em 0.4em; border-radius: 5px; background: var(--red); color: #fff; }
.empty { color: var(--ink-3); padding: 1.5rem 0; }
svg { width: 1.2em; height: 1.2em; flex: none; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5em;
  padding: 0.7em 1.35em; border-radius: 999px; font-weight: 700; font-size: 1rem; line-height: 1.2;
  border: 2px solid transparent; cursor: pointer; transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  text-decoration: none !important;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--red); color: #fff; box-shadow: 0 6px 18px rgba(216, 48, 37, 0.25); }
.btn--primary:hover { background: #c22a20; }
.btn--outline { border-color: var(--ink); color: var(--ink); background: #fff; }
.btn--outline:hover { background: var(--ink); color: #fff; }
.btn--ghost { color: var(--ink); background: var(--bg-2); }
.btn--ghost:hover { background: var(--line); }
.btn--light { background: #fff; color: var(--red); }
.btn--lg { font-size: 1.1rem; padding: 0.85em 1.7em; }
.btn--sm { font-size: 0.9rem; padding: 0.5em 1.1em; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 12px; border: 0; background: transparent; color: var(--ink); cursor: pointer; }
.icon-btn:hover { background: var(--bg-2); }
.icon-btn svg { width: 26px; height: 26px; }

/* ------------------------------------------------------------ notice bar */
.notice-bar { background: var(--ink); color: #fff; font-size: 0.95rem; }
.notice-bar .wrap { display: flex; align-items: center; gap: 0.6em; padding: 0.5rem 0; }
.notice-bar a { color: #fff; font-weight: 600; }

/* ------------------------------------------------------------ header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, 0.92); backdrop-filter: saturate(160%) blur(12px); border-bottom: 1px solid var(--line-2); transition: box-shadow 0.2s ease; }
.site-header.is-stuck { box-shadow: var(--shadow-sm); }
.site-header__inner { display: flex; align-items: center; gap: 1.5rem; min-height: var(--header-h); }
.site-logo { flex: none; display: block; }
.site-logo img { height: 56px; width: auto; }
.site-header__tools { margin-left: auto; display: flex; align-items: center; gap: 0.25rem; }
.nav-toggle__close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__close { display: inline-flex; }

.site-nav .menu { display: flex; gap: 0.25rem; }
.site-nav .menu > li { position: relative; }
.site-nav .menu > li > a { display: inline-flex; align-items: center; gap: 0.3em; padding: 0.6em 0.9em; border-radius: 10px; font-weight: 700; font-size: 1.02rem; color: var(--ink); }
.site-nav .menu > li > a:hover, .site-nav .menu > li.is-open > a, .site-nav .menu > li.current-menu-ancestor > a, .site-nav .menu > li.current-menu-item > a { background: var(--bg-2); text-decoration: none; color: var(--ink); }
.site-nav .menu > li.current-menu-ancestor > a, .site-nav .menu > li.current-menu-item > a { color: var(--red); }
.site-nav .menu > .menu-item-has-children > a::after { content: ""; width: 0.5em; height: 0.5em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); opacity: 0.55; margin-left: 0.1em; }
.site-nav .sub-menu { position: absolute; top: calc(100% + 6px); left: 0; min-width: 240px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 0.5rem; opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s; }
.site-nav .menu > li:hover > .sub-menu, .site-nav .menu > li.is-open > .sub-menu, .site-nav .menu > li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.site-nav .sub-menu a { display: block; padding: 0.6em 0.9em; border-radius: 9px; color: var(--ink); font-weight: 600; font-size: 1rem; white-space: nowrap; }
.site-nav .sub-menu a:hover { background: var(--bg-2); text-decoration: none; }
.site-nav .sub-menu .current-menu-item > a { color: var(--red); background: var(--bg-red); }
.site-nav__actions { display: none; }

@media (min-width: 1024px) {
  .site-nav { display: flex; align-items: center; gap: 1rem; margin-left: auto; }
  .site-nav__actions { display: flex; gap: 0.5rem; margin-left: 0.5rem; }
  .site-header__tools { margin-left: 0; }
  .nav-toggle { display: none; }
}
@media (min-width: 1024px) and (max-width: 1200px) {
  .site-nav .menu > li > a { padding: 0.6em 0.6em; font-size: 0.98rem; }
  .site-nav__actions .btn { padding: 0.6em 1em; font-size: 0.92rem; }
}
@media (max-width: 1023px) {
  :root { --header-h: 68px; }
  /* backdrop-filter would become the containing block of the fixed nav panel */
  .site-header { backdrop-filter: none; background: #fff; }
  .site-logo img { height: 44px; }
  .site-nav { position: fixed; inset: var(--header-h) 0 0; background: #fff; overflow-y: auto; padding: 1rem var(--gutter) 3rem; transform: translateX(100%); visibility: hidden; transition: transform 0.25s ease, visibility 0s linear 0.25s; z-index: 49; }
  .site-nav.is-open { transform: none; visibility: visible; transition: transform 0.25s ease, visibility 0s; }
  .site-nav .menu { flex-direction: column; gap: 0; }
  .site-nav .menu > li { border-bottom: 1px solid var(--line-2); }
  .site-nav .menu > li > a { display: flex; justify-content: space-between; width: 100%; padding: 1rem 0.25rem; font-size: 1.15rem; border-radius: 0; }
  .site-nav .menu > li > a:hover, .site-nav .menu > li.is-open > a { background: transparent; }
  .site-nav .menu > .menu-item-has-children > a::after { width: 0.6em; height: 0.6em; margin-right: 0.4em; transition: transform 0.2s; }
  .site-nav .menu > li.is-open > .menu-item-has-children > a::after, .site-nav .menu > li.is-open > a::after { transform: translateY(2px) rotate(225deg); }
  .site-nav .sub-menu { position: static; opacity: 1; visibility: visible; transform: none; border: 0; box-shadow: none; padding: 0 0 0.75rem 0.25rem; display: none; min-width: 0; }
  .site-nav .menu > li.is-open > .sub-menu { display: grid; grid-template-columns: 1fr 1fr; gap: 0.15rem; }
  .site-nav .sub-menu a { white-space: normal; font-size: 1.05rem; padding: 0.55em 0.7em; color: var(--ink-2); }
  .site-nav__actions { display: flex; gap: 0.6rem; margin-top: 1.25rem; }
  .site-nav__actions .btn { flex: 1; font-size: 1.05rem; padding: 0.9em; }
}
@media (max-width: 480px) { .site-nav .menu > li.is-open > .sub-menu { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------ hero */
.hero { position: relative; overflow: hidden; background: #fff; }
.hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 80% at 100% 0%, rgba(237, 71, 84, 0.10), transparent 60%), radial-gradient(50% 70% at 0% 100%, rgba(98, 85, 164, 0.10), transparent 60%); pointer-events: none; }
.hero__inner { position: relative; display: grid; grid-template-columns: 1.15fr 0.85fr; align-items: center; gap: clamp(1.5rem, 4vw, 4rem); padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(2rem, 5vw, 4rem); }
.hero h1 { font-size: clamp(2.2rem, 5.2vw, 3.9rem); line-height: 1.15; letter-spacing: -0.02em; margin: 0.4rem 0 1.2rem; }
.hero h1 .line { display: block; }
.hero h1 .line--accent { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero__sub { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--ink-2); max-width: 34em; margin-bottom: 1.8rem; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.hero__visual { display: flex; justify-content: center; }
.hero__mark { width: min(100%, 440px); filter: drop-shadow(0 20px 40px rgba(98, 85, 164, 0.2)); animation: float 7s ease-in-out infinite; }
.hero--photo .hero__visual img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@media (prefers-reduced-motion: reduce) { .hero__mark { animation: none; } }
@media (max-width: 860px) {
  .hero__inner { grid-template-columns: 1fr; padding-top: 2rem; }
  .hero__visual { order: -1; }
  .hero__mark { width: min(56%, 260px); }
  .hero--photo .hero__visual img { aspect-ratio: 16 / 9; }
}

/* ------------------------------------------------------------ quick services */
.quick { padding: 0 0 clamp(2rem, 5vw, 3.5rem); }
.quick__grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 0.9rem; }
.quick__grid a { display: flex; flex-direction: column; align-items: flex-start; gap: 0.35rem; height: 100%; padding: 1.25rem 1.2rem 1.15rem; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; color: var(--ink); transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease; }
.quick__grid a:hover { text-decoration: none; transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.quick__icon { display: inline-flex; width: 48px; height: 48px; border-radius: 12px; align-items: center; justify-content: center; background: var(--grad-soft); color: var(--purple); margin-bottom: 0.4rem; }
.quick__icon svg { width: 26px; height: 26px; }
.quick__grid li:nth-child(2) .quick__icon { color: var(--blue); }
.quick__grid li:nth-child(3) .quick__icon { color: var(--blue); }
.quick__grid li:nth-child(5) .quick__icon { color: var(--red); }
.quick__grid li:nth-child(6) .quick__icon { color: var(--red); }
.quick__title { font-weight: 800; font-size: 1.12rem; }
.quick__desc { font-size: 0.92rem; color: var(--ink-3); line-height: 1.4; }
@media (max-width: 1023px) { .quick__grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px) { .quick__grid { grid-template-columns: repeat(2, 1fr); gap: 0.7rem; } .quick__grid a { padding: 1rem; } }

/* ------------------------------------------------------------ home sections */
.home-section { padding: clamp(2rem, 5vw, 3.75rem) 0; }
.home-section--tint { background: var(--bg-2); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.section-head h2 { font-size: clamp(1.5rem, 2.4vw, 1.9rem); display: inline-flex; align-items: center; gap: 0.4em; }
.section-head h2 svg { color: var(--red); width: 1em; height: 1em; }
.more { display: inline-flex; align-items: center; gap: 0.25em; font-weight: 700; color: var(--ink-2); font-size: 0.95rem; white-space: nowrap; }
.more:hover { color: var(--red); text-decoration: none; }
.more--light, .more--light:hover { color: #fff; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem, 4vw, 4rem); }
.two-col--wide { grid-template-columns: 1.2fr 0.8fr; }
.two-col > .col, .hero__inner > *, .visit__inner > *, .footer-grid > * { min-width: 0; }
@media (max-width: 900px) { .two-col, .two-col--wide { grid-template-columns: 1fr; } }

/* post rows */
.post-list { border-top: 2px solid var(--ink); }
.post-row { border-bottom: 1px solid var(--line); }
.post-row a { display: flex; align-items: center; gap: 0.8rem; padding: 0.95rem 0.25rem; color: var(--ink); }
.post-row a:hover { text-decoration: none; background: var(--bg-2); }
.post-row a:hover .post-row__title { color: var(--red); }
.post-row__title { flex: 1; font-weight: 600; font-size: 1.05rem; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.post-row.is-sticky .post-row__title { font-weight: 800; }
.post-row__date { color: var(--ink-3); font-size: 0.92rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.post-list--archive .post-row a { padding: 1.15rem 0.25rem; }
.post-list--archive .post-row__title { font-size: 1.12rem; }
@media (max-width: 560px) {
  .post-row a { flex-wrap: wrap; gap: 0.35rem 0.6rem; }
  .post-row__title { flex-basis: 100%; order: 2; }
  .post-row__date { order: 3; }
}

/* cards */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.post-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: transform 0.15s ease, box-shadow 0.15s ease; }
.post-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.post-card__media { display: block; aspect-ratio: 3 / 2; overflow: hidden; background: var(--bg-2); }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; }
.card-fallback { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: var(--grad-soft); }
.card-fallback--1 { background: linear-gradient(135deg, rgba(3, 83, 165, 0.12), rgba(98, 85, 164, 0.12)); }
.card-fallback--2 { background: linear-gradient(135deg, rgba(237, 71, 84, 0.12), rgba(216, 48, 37, 0.06)); }
.card-fallback img { width: 34%; opacity: 0.55; }
.post-card__body { padding: 1.1rem 1.25rem 1.3rem; display: flex; flex-direction: column; gap: 0.4rem; }
.post-card__meta { display: flex; align-items: center; gap: 0.6rem; margin: 0; font-size: 0.9rem; color: var(--ink-3); }
.post-card__title { font-size: 1.15rem; font-weight: 800; line-height: 1.4; }
.post-card__title a { color: var(--ink); }
.post-card__title a:hover { color: var(--red); text-decoration: none; }
.post-card__excerpt { margin: 0; color: var(--ink-2); font-size: 0.95rem; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 900px) { .card-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .card-grid { grid-template-columns: 1fr; } }

/* events */
.event-list { display: grid; gap: 0.75rem; }
.event-card a { display: flex; gap: 1rem; align-items: center; padding: 0.9rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--ink); background: #fff; transition: box-shadow 0.15s ease, transform 0.15s ease; }
.event-card a:hover { text-decoration: none; box-shadow: var(--shadow); transform: translateY(-2px); }
.event-card__badge { flex: none; width: 64px; display: flex; flex-direction: column; align-items: center; line-height: 1; padding: 0.5rem 0; border-radius: 12px; background: var(--bg-blue); color: var(--blue); }
.event-card__badge .m { font-size: 0.75rem; font-weight: 700; }
.event-card__badge .d { font-size: 1.6rem; font-weight: 800; margin: 0.15rem 0; }
.event-card__badge .w { font-size: 0.75rem; }
.event-card.is-past .event-card__badge { background: var(--bg-2); color: var(--ink-3); }
.event-card__body { display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; }
.event-card__title { font-weight: 700; font-size: 1.05rem; line-height: 1.4; }
.event-card__meta { color: var(--ink-3); font-size: 0.9rem; }
.event-list--archive { grid-template-columns: 1fr 1fr; margin-bottom: 2.5rem; }
@media (max-width: 700px) { .event-list--archive { grid-template-columns: 1fr; } }
.h-sub { font-size: 1.4rem; margin-bottom: 1rem; }

/* donate panel */
.donate-panel { background: var(--grad); color: #fff; border-radius: var(--radius); padding: clamp(1.4rem, 3vw, 2rem); height: 100%; display: flex; flex-direction: column; gap: 0.75rem; }
.donate-panel__head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.donate-panel h2 { font-size: 1.5rem; display: inline-flex; align-items: center; gap: 0.4em; }
.donate-panel p { margin: 0; opacity: 0.95; }
.donate-panel__bank { margin: 0.25rem 0; background: rgba(255, 255, 255, 0.14); border-radius: 12px; padding: 0.9rem 1.1rem; display: grid; gap: 0.35rem; }
.donate-panel__bank div { display: flex; gap: 1rem; }
.donate-panel__bank dt { width: 3em; opacity: 0.8; font-weight: 600; }
.donate-panel__bank dd { margin: 0; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: 0.02em; }
@media (max-width: 480px) { .donate-panel__bank dd { font-size: 0.92rem; letter-spacing: 0; } }
.donate-panel__list { display: grid; gap: 0.3rem; font-size: 0.95rem; min-width: 0; }
.donate-panel__list li { min-width: 0; }
.donate-panel__list a { color: #fff; opacity: 0.92; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.donate-panel .btn { align-self: flex-start; margin-top: auto; }

/* visit */
.visit { background: var(--bg-2); }
.visit__inner { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: clamp(1.5rem, 4vw, 4rem); align-items: center; }
.visit h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); margin-bottom: 1rem; }
.visit__list { display: grid; gap: 0.9rem; margin-bottom: 1.5rem; }
.visit__list li { display: flex; gap: 0.7rem; align-items: flex-start; font-size: 1.05rem; }
.visit__list svg { color: var(--red); margin-top: 0.25em; }
.visit__map iframe { width: 100%; aspect-ratio: 4 / 3; border-radius: var(--radius); box-shadow: var(--shadow-sm); }
@media (max-width: 860px) { .visit__inner { grid-template-columns: 1fr; } .visit__map iframe { aspect-ratio: 16 / 10; } }

/* insta band */
.insta { background: #fff; }
.insta__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1.25rem; }
.insta__head h2 { font-size: clamp(1.5rem, 2.4vw, 1.9rem); display: inline-flex; align-items: center; gap: 0.4em; }
.insta__head h2 svg { color: var(--red); width: 1em; height: 1em; }
.insta__handle { display: block; margin-top: 0.25rem; color: var(--ink-3); font-weight: 600; font-size: 0.95rem; }
.insta__handle:hover { color: var(--red); text-decoration: none; }
.insta__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.insta__grid .tile { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--grad-soft); display: flex; align-items: center; justify-content: center; }
.insta__grid .tile img { width: 40%; opacity: 0.45; }
.insta__hint { margin: 1rem 0 0; padding: 0.9rem 1.1rem; border-radius: var(--radius-sm); background: var(--bg-blue); color: var(--blue); font-size: 0.95rem; }
/* Smash Balloon → flush 3-column grid of six */
.insta__feed .sb_instagram_header, .insta__feed .sbi_header, .insta__feed #sbi_load, .insta__feed .sbi_load, .insta__feed .sbi_follow_btn, .insta__feed .sbi_expand { display: none !important; }
.insta__feed #sb_instagram { padding: 0 !important; width: 100% !important; }
.insta__feed #sb_instagram #sbi_images { display: grid !important; grid-template-columns: repeat(3, 1fr) !important; gap: 12px !important; padding: 0 !important; margin: 0 !important; width: 100% !important; float: none !important; }
.insta__feed #sb_instagram #sbi_images .sbi_item { width: auto !important; padding: 0 !important; margin: 0 !important; float: none !important; }
.insta__feed #sb_instagram #sbi_images .sbi_item:nth-child(n + 7) { display: none !important; }
.insta__feed #sb_instagram .sbi_photo_wrap, .insta__feed #sb_instagram .sbi_photo { display: block; border-radius: 12px; overflow: hidden; }
.insta__feed #sb_instagram .sbi_photo { aspect-ratio: 1; background-size: cover !important; }
.insta__feed #sb_instagram .sbi_photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.insta__feed #sb_instagram .sbi_photo { transition: transform 0.2s ease; }
.insta__feed #sb_instagram .sbi_item:hover .sbi_photo { transform: scale(1.02); }
@media (max-width: 640px) { .insta__grid, .insta__feed #sb_instagram #sbi_images { grid-template-columns: repeat(2, 1fr) !important; gap: 8px !important; } .insta__feed #sb_instagram #sbi_images .sbi_item:nth-child(n + 7) { display: none !important; } }

/* ------------------------------------------------------------ page hero + tabs */
.page-hero { background: var(--bg-2); border-bottom: 1px solid var(--line-2); }
.page-hero .wrap { padding: clamp(2rem, 5vw, 3.5rem) 0 clamp(1.5rem, 4vw, 2.5rem); }
.page-hero h1 { font-size: clamp(2rem, 4.2vw, 3rem); letter-spacing: -0.02em; }
.page-hero__lead { margin: 0.9rem 0 0; color: var(--ink-2); font-size: 1.1rem; max-width: 40em; }
.section-tabs { background: #fff; border-top: 1px solid var(--line-2); }
.section-tabs .wrap { display: flex; gap: 0.25rem; overflow-x: auto; scrollbar-width: none; }
.section-tabs .wrap::-webkit-scrollbar { display: none; }
.section-tabs a { flex: none; padding: 0.9rem 1rem; font-weight: 700; color: var(--ink-2); border-bottom: 3px solid transparent; }
.section-tabs a:hover { color: var(--ink); text-decoration: none; }
.section-tabs a[aria-current="page"] { color: var(--red); border-color: var(--red); }

/* ------------------------------------------------------------ prose (page/post content) */
.prose { font-size: 1.05rem; line-height: 1.8; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: 1.65rem; margin-top: 2.2em; padding-top: 0.2em; }
.prose h3 { font-size: 1.3rem; margin-top: 1.8em; }
.prose h4 { font-size: 1.1rem; margin-top: 1.5em; }
.prose h2 + *, .prose h3 + * { margin-top: 0.7em; }
.prose ul, .prose ol { padding-left: 1.4em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li + li { margin-top: 0.35em; }
.prose blockquote { margin: 1.5em 0; padding: 1rem 1.4rem; border-left: 4px solid var(--red); background: var(--bg-red); border-radius: 0 12px 12px 0; }
.prose blockquote p:last-child { margin-bottom: 0; }
.prose img { border-radius: 12px; }
.prose figure { margin: 1.5em 0; }
.prose figcaption { font-size: 0.9rem; color: var(--ink-3); text-align: center; margin-top: 0.5em; }
.prose table, .wp-block-table table { width: 100%; border-collapse: collapse; font-size: 1rem; }
.prose th, .prose td { padding: 0.75em 0.9em; border: 1px solid var(--line); vertical-align: top; text-align: left; }
.prose th { background: var(--bg-2); font-weight: 700; }
.prose .wp-block-table { overflow-x: auto; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.5em 0; }
.prose .wp-block-buttons .wp-block-button__link { border-radius: 999px; font-weight: 700; }
.prose a:not(.btn):not(.wp-block-button__link) { text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(3, 83, 165, 0.35); }
.prose .lead { font-size: 1.2rem; color: var(--ink-2); }
.prose .callout { padding: 1.2rem 1.4rem; border-radius: var(--radius); background: var(--bg-blue); border: 1px solid rgba(3, 83, 165, 0.12); }
.prose .callout--red { background: var(--bg-red); border-color: rgba(216, 48, 37, 0.15); }
.prose .callout h3 { margin-top: 0; }
.prose .callout p:last-child { margin-bottom: 0; }
.prose .check { list-style: none; padding-left: 0; }
.prose .check li { position: relative; padding-left: 1.7em; }
.prose .check li::before { content: "✓"; position: absolute; left: 0; color: var(--red); font-weight: 800; }
.prose .fee-table td:last-child, .prose .fee-table th:last-child { text-align: right; font-variant-numeric: tabular-nums; font-weight: 700; }
.prose .bank-box { display: grid; gap: 0.5rem; padding: 1.4rem 1.6rem; border-radius: var(--radius); background: var(--grad); color: #fff; }
.prose .bank-box div { display: flex; gap: 1rem; align-items: baseline; }
.prose .bank-box dt { width: 4.5em; opacity: 0.85; font-weight: 600; }
.prose .bank-box dd { margin: 0; font-size: clamp(1rem, 3.6vw, 1.25rem); font-weight: 800; font-variant-numeric: tabular-nums; }
.prose .service-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0.8rem; padding: 0; list-style: none; }
.prose .service-facts li { padding: 1rem 1.1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); margin: 0; }
.prose .service-facts strong { display: block; font-size: 0.85rem; color: var(--ink-3); font-weight: 600; margin-bottom: 0.2em; }
.prose .link-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0.6rem; padding: 0; list-style: none; }
.prose .link-grid li { margin: 0; }
.prose .link-grid a { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; padding: 0.8rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--ink); text-decoration: none !important; font-weight: 600; }
.prose .link-grid a::after { content: "↗"; color: var(--ink-3); }
.prose .link-grid a:hover { border-color: var(--blue); color: var(--blue); }
.prose .link-grid small { color: var(--ink-3); font-weight: 500; }
.page-thumb { margin-bottom: 2rem; }
.page-thumb img { border-radius: var(--radius); width: 100%; }

/* presidents grid */
.prose .presidents { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1.2rem 1rem; padding: 0; list-style: none; }
@media (max-width: 560px) { .prose .presidents { grid-template-columns: 1fr 1fr; gap: 1rem 0.75rem; } }
.prose .presidents li { margin: 0; text-align: center; }
.presidents img { width: 100%; aspect-ratio: 5 / 6; object-fit: cover; object-position: top; border-radius: 12px; background: var(--bg-2); margin-bottom: 0.6rem; }
.presidents .term { display: block; font-size: 0.85rem; color: var(--ink-3); }
.presidents .name { display: block; font-weight: 800; font-size: 1.05rem; }
.presidents .nth { display: inline-block; font-size: 0.78rem; color: var(--blue); background: var(--bg-blue); border-radius: 999px; padding: 0.05em 0.6em; margin-top: 0.25rem; }
.presidents li.is-current img { outline: 3px solid var(--red); outline-offset: 2px; }

/* tenants / society lists */
.prose .tenants td:first-child { width: 3em; text-align: center; color: var(--ink-3); font-weight: 700; }
.prose .tenants em { display: block; font-style: normal; color: var(--ink-3); font-size: 0.9rem; }

/* greeting */
.greeting { display: grid; grid-template-columns: 300px 1fr; gap: clamp(1.5rem, 4vw, 4rem); align-items: start; }
.greeting__card { position: sticky; top: calc(var(--header-h) + 1.5rem); text-align: center; padding: 1.4rem; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.greeting__photo { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 12px; margin-bottom: 1rem; }
.greeting__photo--empty { display: flex; align-items: center; justify-content: center; background: var(--grad-soft); }
.greeting__photo--empty img { width: 45%; opacity: 0.6; }
.greeting__role { margin: 0; font-size: 0.9rem; color: var(--ink-3); }
.greeting__name { margin: 0; font-weight: 800; font-size: 1.2rem; }
.greeting__letter { font-size: 1.1rem; }
.greeting__letter .sign { text-align: right; font-weight: 700; margin-top: 2em; }
@media (max-width: 800px) { .greeting { grid-template-columns: 1fr; } .greeting__card { position: static; max-width: 320px; } }

/* location */
.location { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(1.5rem, 3vw, 2.5rem); align-items: start; }
.location__map iframe { width: 100%; aspect-ratio: 1 / 1; border-radius: var(--radius); box-shadow: var(--shadow-sm); position: sticky; top: calc(var(--header-h) + 1.5rem); }
.location__info { display: grid; gap: 1rem; }
.info-card { padding: 1.4rem 1.5rem; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.info-card h2 { font-size: 1.15rem; display: flex; align-items: center; gap: 0.4em; margin-bottom: 0.7rem; }
.info-card h2 svg { color: var(--red); }
.info-card .big { font-size: 1.2rem; font-weight: 700; margin-bottom: 0.3rem; }
.info-card p:last-child { margin-bottom: 0; }
.info-card .btn { margin-top: 0.75rem; }
.rows { margin: 0; display: grid; gap: 0.4rem; }
.rows div { display: flex; gap: 1rem; justify-content: space-between; border-bottom: 1px dashed var(--line); padding-bottom: 0.4rem; }
.rows div:last-child { border: 0; }
.rows dt { font-weight: 700; }
.rows dd { margin: 0; text-align: right; color: var(--ink-2); }
@media (max-width: 860px) { .location { grid-template-columns: 1fr; } .location__map iframe { aspect-ratio: 16 / 10; position: static; } }

/* ------------------------------------------------------------ single */
.entry__head { background: var(--bg-2); border-bottom: 1px solid var(--line-2); }
.entry__head .wrap { padding: clamp(2rem, 5vw, 3.5rem) 0 clamp(1.5rem, 4vw, 2.5rem); }
.entry__title { font-size: clamp(1.7rem, 3.6vw, 2.6rem); letter-spacing: -0.02em; margin-bottom: 1rem; }
.entry__meta { margin: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 1.2rem; color: var(--ink-3); font-size: 0.95rem; }
.entry__meta span { display: inline-flex; align-items: center; gap: 0.35em; }
.entry__meta svg { color: var(--red); }
.entry__thumb { padding-top: 2rem; }
.entry__thumb img { width: 100%; border-radius: var(--radius); }
.entry__content { padding: clamp(2rem, 4vw, 3rem) 0; }
.entry__content img { height: auto; }
.entry__foot { padding-bottom: clamp(3rem, 7vw, 5rem); }
.entry__share { margin-bottom: 1.5rem; }
.entry__nav { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; border-top: 1px solid var(--line); padding-top: 1.5rem; }
.entry__nav a { display: block; color: var(--ink); font-weight: 700; line-height: 1.4; }
.entry__nav span { display: block; font-size: 0.85rem; color: var(--ink-3); font-weight: 500; margin-bottom: 0.2em; }
.entry__nav .next { text-align: right; grid-column: 2; }
@media (max-width: 560px) { .entry__nav { grid-template-columns: 1fr; } .entry__nav .next { grid-column: 1; text-align: left; } }

/* pagination */
.pagination { margin-top: 2rem; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 0.4rem; justify-content: center; }
.pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; padding: 0 0.8em; border-radius: 10px; border: 1px solid var(--line); color: var(--ink); font-weight: 700; }
.pagination .page-numbers.current { background: var(--ink); color: #fff; border-color: var(--ink); }
.pagination a.page-numbers:hover { background: var(--bg-2); text-decoration: none; }

/* search */
.search-form { display: flex; gap: 0.4rem; }
.search-form input { flex: 1; font: inherit; padding: 0.6em 0.9em; border: 1px solid var(--line); border-radius: 10px; }
.search-form button { border: 0; background: var(--bg-2); border-radius: 10px; padding: 0 0.8em; cursor: pointer; }
.search-form--big { margin-bottom: 2rem; }
.search-form--big input { font-size: 1.1rem; padding: 0.8em 1.1em; }

/* ------------------------------------------------------------ forms */
.ksa-form { margin-top: 1rem; padding: clamp(1.4rem, 3vw, 2.2rem); border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.ksa-form .hp { position: absolute; left: -9999px; }
.ksa-form__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 1.25rem; }
.ksa-form .field { display: flex; flex-direction: column; gap: 0.35rem; }
.ksa-form .field--wide { grid-column: 1 / -1; }
.ksa-form label { font-weight: 700; font-size: 0.98rem; }
.ksa-form .req { color: var(--red); }
.ksa-form input, .ksa-form select, .ksa-form textarea { font: inherit; font-size: 1.05rem; padding: 0.7em 0.9em; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); width: 100%; }
.ksa-form input:focus, .ksa-form select:focus, .ksa-form textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(3, 83, 165, 0.12); }
.ksa-form textarea { resize: vertical; min-height: 9em; }
.ksa-form__privacy { margin: 1.25rem 0 1rem; color: var(--ink-3); font-size: 0.92rem; }
.form-notice { padding: 1rem 1.25rem; border-radius: var(--radius-sm); margin-bottom: 1rem; }
.form-notice--ok { background: #eaf7ee; color: #1b6b3a; border: 1px solid #bfe5cb; }
.form-notice--err { background: var(--bg-red); color: var(--red); border: 1px solid #f4c2be; }
@media (max-width: 640px) { .ksa-form__grid { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------ footer */
.site-footer { margin-top: auto; background: #fff; border-top: 1px solid var(--line); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 0.8fr 0.8fr; gap: clamp(1.5rem, 4vw, 4rem); padding: clamp(2.5rem, 5vw, 4rem) 0 2rem; }
.footer-brand img { height: 60px; width: auto; margin-bottom: 1rem; }
.footer-brand__note { color: var(--ink-2); font-size: 0.95rem; max-width: 36em; }
.footer-contact { display: grid; gap: 0.5rem; font-size: 0.98rem; }
.footer-contact li { display: flex; gap: 0.6rem; align-items: flex-start; }
.footer-contact svg { color: var(--red); margin-top: 0.25em; }
.footer-contact a { color: var(--ink); }
.footer-h { font-size: 1rem; font-weight: 800; margin-bottom: 0.8rem; color: var(--ink); }
.footer-menu { display: grid; gap: 0.35rem; }
.footer-menu a { color: var(--ink-2); font-size: 0.98rem; }
.footer-menu a:hover { color: var(--red); }
.footer-social { display: inline-flex; align-items: center; gap: 0.4em; margin-top: 1rem; font-weight: 700; color: var(--ink); }
.footer-base { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1.5rem; padding: 1.25rem 0 2rem; border-top: 1px solid var(--line-2); font-size: 0.88rem; color: var(--ink-3); }
.footer-base p { margin: 0; }
.footer-base a { color: var(--ink-3); }
.footer-base__login { margin-left: auto !important; }
.footer-credit a { display: inline-flex; align-items: center; gap: 0.45em; padding: 0.3em 0.75em 0.3em 0.4em; border-radius: 999px; background: var(--bg-2); color: var(--ink-2); font-weight: 600; }
.footer-credit a:hover { background: var(--line); text-decoration: none; color: var(--ink); }
.footer-credit img { width: 20px; height: 20px; border-radius: 50%; box-shadow: 0 0 0 1px var(--line); }
@media (max-width: 640px) { .footer-base { flex-direction: column; align-items: flex-start; } .footer-base__login { margin-left: 0 !important; } }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------ reveal */
[data-reveal] { opacity: 0; transform: translateY(12px); transition: opacity 0.5s ease, transform 0.5s ease; }
[data-reveal].is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { [data-reveal] { opacity: 1; transform: none; transition: none; } }

/* layout: footer to bottom */
body { min-height: 100vh; display: flex; flex-direction: column; }
.site-main { flex: 1 0 auto; }
