/* MAJ — NPO法人モンゴル人協会・日本 */
:root {
  --blue: #0b4ea2;
  --blue-deep: #08356f;
  --blue-soft: #e8f0fb;
  --red: #c4272f;
  --gold: #d9a521;
  --ink: #1d2430;
  --muted: #5b6575;
  --line: #dfe4ec;
  --bg: #ffffff;
  --bg-alt: #f6f8fb;
  --radius: 14px;
  --max: 1120px;
  --font: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  --font-serif: "Noto Serif JP", "Hiragino Mincho ProN", "Yu Mincho", serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.85;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); }
a:hover { color: var(--red); }

.container { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.94);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); min-width: 0; }
.brand-mark { width: 42px; height: 42px; flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.brand-text strong { font-size: 15px; letter-spacing: .02em; white-space: nowrap; }
.brand-text small { font-size: 11px; color: var(--muted); white-space: nowrap; }

.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  text-decoration: none; color: var(--ink); font-size: 14px; font-weight: 500; white-space: nowrap;
  padding: 8px 12px; border-radius: 8px;
}
.nav a:hover { background: var(--blue-soft); color: var(--blue); }
.lang-switch { display: flex; gap: 2px; margin-left: 8px; border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.lang-switch a { font-size: 12px; padding: 4px 10px; border-radius: 999px; }
.lang-switch a[aria-current="true"] { background: var(--blue); color: #fff; }

.menu-btn { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: var(--ink); }
.menu-btn svg { width: 26px; height: 26px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(255,255,255,.14), transparent 60%),
    linear-gradient(135deg, var(--blue-deep) 0%, var(--blue) 60%, #1769c9 100%);
}
.hero::after { /* steppe horizon */
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 120px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 120' preserveAspectRatio='none'%3E%3Cpath d='M0 80 C 180 40 300 70 460 50 S 760 10 920 45 S 1260 90 1440 55 V120 H0Z' fill='%23ffffff' fill-opacity='.08'/%3E%3Cpath d='M0 100 C 240 70 420 95 640 80 S 1040 60 1200 85 S 1380 100 1440 92 V120 H0Z' fill='%23ffffff'/%3E%3C/svg%3E") bottom / 100% 100% no-repeat;
}
.hero-inner { position: relative; z-index: 1; padding: 96px 20px 150px; display: grid; grid-template-columns: 1.3fr .9fr; gap: 48px; align-items: center; }
.eyebrow { display: inline-block; font-size: 13px; letter-spacing: .14em; opacity: .9; border: 1px solid rgba(255,255,255,.4); padding: 4px 14px; border-radius: 999px; margin-bottom: 20px; }
.hero h1 { font-family: var(--font-serif); font-size: clamp(28px, 3.9vw, 46px); line-height: 1.35; margin: 0 0 20px; font-weight: 700; letter-spacing: .02em; }
.hero h1 .accent { color: #ffd76a; }
.hero p.lead { font-size: 17px; opacity: .95; margin: 0 0 32px; max-width: 34em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 700;
  padding: 13px 26px; border-radius: 999px; font-size: 15px; transition: transform .15s, box-shadow .15s, background .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--red); color: #fff; box-shadow: 0 6px 18px rgba(196,39,47,.35); }
.btn-primary:hover { color: #fff; background: #ad1f27; }
.btn-ghost { color: #fff; border: 1.5px solid rgba(255,255,255,.7); }
.btn-ghost:hover { color: var(--blue); background: #fff; }
.btn-outline { color: var(--blue); border: 1.5px solid var(--blue); }
.btn-outline:hover { background: var(--blue); color: #fff; }

.hero-card {
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.25); border-radius: 20px;
  padding: 28px; backdrop-filter: blur(4px);
}
.hero-card .mn-name { font-size: 22px; font-weight: 700; margin: 0 0 4px; }
.hero-card .en-name { font-size: 14px; opacity: .85; margin: 0 0 18px; }
.hero-card dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; font-size: 14px; }
.hero-card dt { opacity: .75; }
.hero-card dd { margin: 0; font-weight: 500; }

/* ---------- Sections ---------- */
section { padding: 88px 0; }
section.alt { background: var(--bg-alt); }
.section-head { text-align: center; margin-bottom: 48px; }
.section-head .kicker { color: var(--red); font-weight: 700; letter-spacing: .18em; font-size: 12px; text-transform: uppercase; }
.section-head h2 { font-family: var(--font-serif); font-size: clamp(26px, 3.2vw, 36px); margin: 6px 0 12px; line-height: 1.4; }
.section-head p { color: var(--muted); margin: 0 auto; max-width: 42em; }
.ornament { display: block; width: 120px; height: 14px; margin: 14px auto 0; }

/* Mission */
.mission-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.mission {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 36px;
  position: relative; overflow: hidden;
}
.mission::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 5px; background: var(--blue); }
.mission:nth-child(2)::before { background: var(--red); }
.mission .num { font-family: var(--font-serif); font-size: 14px; font-weight: 700; color: var(--blue); letter-spacing: .1em; }
.mission:nth-child(2) .num { color: var(--red); }
.mission h3 { font-size: 21px; margin: 6px 0 14px; line-height: 1.5; }
.mission p { color: var(--muted); margin: 0 0 12px; font-size: 15px; }
.note { font-size: 13px; color: var(--muted); background: var(--bg-alt); border-radius: 10px; padding: 12px 16px; margin-top: 16px; }

/* Activities */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px;
  transition: box-shadow .2s, transform .2s;
}
.card:hover { box-shadow: 0 14px 34px rgba(11,78,162,.1); transform: translateY(-3px); }
.card .icon { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: var(--blue-soft); color: var(--blue); margin-bottom: 16px; }
.card:nth-child(3n+2) .icon { background: #fdecec; color: var(--red); }
.card:nth-child(3n) .icon { background: #fbf3df; color: #a77a0b; }
.card .icon svg { width: 26px; height: 26px; }
.card h3 { font-size: 18px; margin: 0 0 8px; }
.card p { margin: 0; color: var(--muted); font-size: 14.5px; }

/* Timeline */
.timeline { position: relative; max-width: 860px; margin: 0 auto; padding-left: 28px; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 6px; bottom: 6px; width: 2px; background: linear-gradient(var(--blue), var(--red)); }
.tl-item { position: relative; padding: 0 0 34px 22px; }
.tl-item::before {
  content: ""; position: absolute; left: -28px; top: 7px; width: 16px; height: 16px; border-radius: 50%;
  background: #fff; border: 3px solid var(--blue);
}
.tl-item.hl::before { border-color: var(--red); }
.tl-date { font-weight: 700; color: var(--blue); font-size: 14px; letter-spacing: .04em; }
.tl-item.hl .tl-date { color: var(--red); }
.tl-item h3 { font-size: 18px; margin: 2px 0 6px; }
.tl-item p { margin: 0; color: var(--muted); font-size: 15px; }
.tl-item details { margin-top: 10px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px 16px; font-size: 14.5px; }
.tl-item summary { cursor: pointer; font-weight: 700; color: var(--blue); }
.tl-item details p { margin-top: 10px; }

/* Greeting */
.greeting { display: grid; grid-template-columns: 280px 1fr; gap: 48px; align-items: start; max-width: 980px; margin: 0 auto; }
.greeting-aside { background: linear-gradient(160deg, var(--blue), var(--blue-deep)); color: #fff; border-radius: 20px; padding: 32px 28px; position: sticky; top: 96px; }
.greeting-aside .q { font-family: var(--font-serif); font-size: 21px; line-height: 1.6; margin: 0 0 18px; }
.greeting-aside .who { font-size: 13px; opacity: .85; margin: 0; }
.greeting-body p { margin: 0 0 1.2em; }
.greeting-body .sign { text-align: right; color: var(--muted); font-size: 14px; }

/* Organization */
.org-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: start; }
.info-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); font-size: 15px; }
.info-table th, .info-table td { padding: 14px 18px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.info-table tr:last-child th, .info-table tr:last-child td { border-bottom: 0; }
.info-table th { width: 32%; background: var(--blue-soft); color: var(--blue-deep); font-weight: 700; font-size: 14px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.panel + .panel { margin-top: 20px; }
.panel h3 { margin: 0 0 14px; font-size: 18px; }
.depts { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.depts li { display: grid; grid-template-columns: 112px 1fr; gap: 12px; font-size: 14.5px; padding-bottom: 10px; border-bottom: 1px dashed var(--line); }
.depts li:last-child { border-bottom: 0; padding-bottom: 0; }
.depts b { color: var(--blue); }
.officers { list-style: none; margin: 0; padding: 0; font-size: 15px; }
.officers li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.officers li:last-child { border-bottom: 0; }
.officers span:first-child { color: var(--muted); font-size: 14px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { background: var(--blue-soft); color: var(--blue-deep); font-size: 13px; padding: 5px 12px; border-radius: 999px; font-weight: 500; }

/* Join */
.join-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.join-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 32px 28px; display: flex; flex-direction: column; }
.join-card.featured { border: 2px solid var(--red); box-shadow: 0 14px 34px rgba(196,39,47,.1); }
.join-card h3 { margin: 0 0 6px; font-size: 20px; }
.join-card .price { font-size: 26px; font-weight: 700; color: var(--red); margin: 6px 0 14px; }
.join-card .price small { font-size: 14px; color: var(--muted); font-weight: 500; }
.join-card ul { padding-left: 1.2em; margin: 0 0 22px; color: var(--muted); font-size: 14.5px; flex: 1; }
.join-card .btn { align-self: flex-start; }

/* Links */
.link-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.link-grid a {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px;
  text-decoration: none; color: var(--ink); font-weight: 500; font-size: 15px;
}
.link-grid a:hover { border-color: var(--blue); color: var(--blue); }
.link-grid a::after { content: "↗"; color: var(--muted); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 32px; align-items: start; }
.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.contact-list li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; }
.contact-list .ci { width: 44px; height: 44px; border-radius: 12px; background: var(--blue-soft); color: var(--blue); display: grid; place-items: center; }
.contact-list .ci svg { width: 22px; height: 22px; }
.contact-list b { display: block; font-size: 13px; color: var(--muted); font-weight: 500; }
.map { width: 100%; height: 300px; border: 0; border-radius: var(--radius); margin-top: 24px; background: var(--bg-alt); }
form.contact { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; display: grid; gap: 16px; }
form.contact label { font-size: 14px; font-weight: 700; display: grid; gap: 6px; }
form.contact input, form.contact select, form.contact textarea {
  font: inherit; font-weight: 400; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); width: 100%;
}
form.contact input:focus, form.contact select:focus, form.contact textarea:focus { outline: 2px solid var(--blue); outline-offset: 0; border-color: var(--blue); }
form.contact textarea { min-height: 140px; resize: vertical; }
form.contact .btn { justify-self: start; border: 0; cursor: pointer; font-family: inherit; }
.form-note { font-size: 13px; color: var(--muted); margin: 0; }

/* Footer */
.site-footer { background: var(--blue-deep); color: rgba(255,255,255,.85); padding: 56px 0 28px; font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.site-footer h4 { color: #fff; margin: 0 0 12px; font-size: 15px; }
.site-footer a { color: rgba(255,255,255,.85); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.footer-brand { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.footer-brand strong { color: #fff; font-size: 16px; }
.copyright { border-top: 1px solid rgba(255,255,255,.15); margin-top: 40px; padding-top: 20px; font-size: 12.5px; text-align: center; opacity: .75; }

.pattern-bar { height: 10px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='10' viewBox='0 0 40 10'%3E%3Cpath d='M0 9 H8 V1 H16 V6 H12 V4 M20 9 H28 V1 H36 V6 H32 V4' fill='none' stroke='%23d9a521' stroke-width='1.6'/%3E%3C/svg%3E") repeat-x center / 40px 10px; background-color: var(--blue-deep); }

/* Reveal */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; padding-top: 72px; }
  .cards, .join-grid, .link-grid { grid-template-columns: repeat(2, 1fr); }
  .org-grid, .contact-grid, .greeting { grid-template-columns: 1fr; }
  .greeting-aside { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1100px) {
  .menu-btn { display: block; }
  .nav {
    position: absolute; top: 68px; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; padding: 12px 16px 18px; gap: 2px; display: none;
    box-shadow: 0 14px 24px rgba(0,0,0,.06);
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px; }
  .lang-switch { margin: 10px 0 0; align-self: flex-start; }
}
@media (max-width: 640px) {
  body { font-size: 15px; }
  .container { padding: 0 16px; }
  section { padding: 64px 0; }
  .hero-inner { padding: 56px 16px 130px; gap: 32px; }
  .mission-grid, .cards, .join-grid, .link-grid, .footer-grid { grid-template-columns: 1fr; }
  .mission, .panel, form.contact { padding: 24px; }
  .info-table th, .info-table td { display: block; width: 100%; }
  .info-table th { border-bottom: 0; padding-bottom: 6px; }
  .info-table td { padding-top: 6px; }
  .depts li { grid-template-columns: 1fr; gap: 2px; }
  .brand-text small { display: none; }
}
.nb { display: inline-block; }

/* Gallery */
.gallery { display: grid; grid-auto-flow: dense; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 200px; gap: 14px; }
.gallery figure { margin: 0; position: relative; overflow: hidden; border-radius: 12px; background: var(--bg-alt); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gallery figure:hover img { transform: scale(1.04); }
.gallery figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 12px 8px; font-size: 12.5px; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.6)); }
.gallery .g-wide { grid-column: span 2; grid-row: span 2; }
.gallery .g-tall { grid-row: span 2; }
.gallery .g-tall img { object-fit: contain; background: #fff; }
@media (max-width: 980px) { .gallery { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .gallery { grid-auto-rows: 160px; gap: 10px; } .gallery .g-wide { grid-column: span 2; } }
