:root {
  --paper: #f7f1e7;
  --paper-2: #fbf8f2;
  --paper-3: #efe6d8;
  --ink: #25312d;
  --muted: #68736f;
  --faint: #8a958f;
  --line: rgba(68, 82, 75, .16);
  --line-strong: rgba(68, 82, 75, .28);
  --accent: #1f827a;
  --accent-soft: #dceee9;
  --warm: #c46f3a;
  --warm-soft: #f1dcc8;
  --blue-soft: #dbe7e7;
  --white: #fffdf8;
  --shadow: 0 18px 50px rgba(52, 44, 32, .09);
  --shadow-soft: 0 10px 24px rgba(52, 44, 32, .06);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --max: 1120px;
  --gutter: clamp(20px, 4vw, 40px);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --serif: var(--font);
  --sans: var(--font);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background:
    radial-gradient(circle at 12% 0%, rgba(31,130,122,.10), transparent 30%),
    radial-gradient(circle at 86% 16%, rgba(196,111,58,.10), transparent 32%),
    linear-gradient(180deg, var(--paper-2), var(--paper));
  color: var(--ink);
  line-height: 1.75;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
img { max-width: 100%; height: auto; display: block; }
.skip-link { position: absolute; left: -999px; top: 12px; background: var(--ink); color: #fff; padding: 8px 12px; z-index: 99; border-radius: 8px; }
.skip-link:focus { left: 12px; }
.site-header { position: sticky; top: 0; z-index: 20; backdrop-filter: blur(16px); background: rgba(251, 248, 242, .82); border-bottom: 1px solid var(--line); }
.nav { max-width: calc(var(--max) + var(--gutter)*2); margin: 0 auto; padding: 14px var(--gutter); display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: .01em; }
.brand img { width: 34px; height: 34px; }
.nav-links { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.nav-links a { padding: 8px 10px; border-radius: 999px; }
.nav-links a[aria-current="page"], .nav-links a:hover { background: rgba(31,130,122,.09); color: var(--ink); }
.nav-toggle { display: none; border: 1px solid var(--line); background: var(--white); border-radius: 999px; width: 42px; height: 42px; align-items: center; justify-content: center; color: var(--ink); }
main { overflow: hidden; }
.container { max-width: calc(var(--max) + var(--gutter)*2); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: clamp(54px, 8vw, 92px) 0; }
.section.compact { padding: clamp(38px, 6vw, 64px) 0; }
.eyebrow { color: var(--accent); font-size: 14px; letter-spacing: .08em; font-weight: 700; text-transform: uppercase; }
h1, h2, h3 { margin: 0; text-wrap: pretty; }
h1 { font-family: var(--font); font-size: clamp(2.35rem, 5vw, 3.55rem); line-height: 1.12; letter-spacing: -.055em; font-weight: 700; max-width: 820px; }
h2 { font-family: var(--font); font-size: clamp(1.75rem, 3vw, 2.25rem); line-height: 1.25; letter-spacing: -.035em; font-weight: 700; }
h3 { font-family: var(--font); font-size: 1.24rem; line-height: 1.38; letter-spacing: 0; }
p { margin: 0; color: var(--muted); }
.lead { font-size: clamp(1.04rem, 1.8vw, 1.18rem); line-height: 1.85; max-width: 760px; color: var(--muted); }
.small { font-size: 14px; color: var(--faint); }
.hero { padding: clamp(56px, 8vw, 104px) 0 48px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.hero-copy { display: grid; gap: 24px; }
.hero-actions, .actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.btn { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: 999px; font-weight: 700; border: 1px solid var(--line-strong); background: var(--white); box-shadow: var(--shadow-soft); transition: transform .2s ease, border-color .2s ease, background .2s ease; }
.btn:hover { transform: translateY(-1px); border-color: rgba(31,130,122,.36); color: var(--ink); }
.btn.primary { background: var(--accent); color: white; border-color: transparent; }
.btn.primary:hover { background: #176d66; color: white; }
.tag-row { display: flex; gap: 10px; flex-wrap: wrap; }
.tag { display: inline-flex; align-items: center; gap: 8px; min-height: 34px; padding: 5px 11px; border: 1px solid var(--line); border-radius: 999px; color: #50625d; background: rgba(255,253,248,.72); font-size: 14px; }
.tag::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); opacity: .75; }
.visual-card { background: rgba(255,253,248,.82); border: 1px solid var(--line); border-radius: var(--radius-xl); padding: clamp(18px, 3vw, 26px); box-shadow: var(--shadow); }
.visual-card img { border-radius: 18px; }
.image-zoom-card { background: transparent; border: 0; padding: 0; box-shadow: none; }
.image-zoom-trigger { position: relative; display: block; width: 100%; padding: 0; border: 0; border-radius: 18px; background: transparent; color: inherit; cursor: zoom-in; }
.image-zoom-trigger img { width: 100%; transition: transform .2s ease, filter .2s ease; }
.image-zoom-trigger:hover img, .image-zoom-trigger:focus-visible img { transform: scale(1.012); filter: saturate(1.03); }
.image-zoom-trigger:focus-visible { outline: 3px solid rgba(31,130,122,.36); outline-offset: 4px; }
.image-lightbox[hidden] { display: none; }
.image-lightbox { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: clamp(14px, 3vw, 32px); }
.image-lightbox__backdrop { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: rgba(19,28,25,.72); backdrop-filter: blur(10px); cursor: zoom-out; }
.image-lightbox__figure { position: relative; z-index: 1; width: min(96vw, 1280px); max-height: min(92vh, 900px); margin: 0; display: grid; gap: 10px; }
.image-lightbox__img { width: 100%; max-height: calc(92vh - 58px); object-fit: contain; border-radius: 18px; background: #fffdf8; box-shadow: 0 26px 80px rgba(0,0,0,.32); }
.image-lightbox__close { position: absolute; top: -14px; right: -14px; width: 42px; height: 42px; border-radius: 999px; border: 1px solid rgba(255,255,255,.42); background: rgba(37,49,45,.92); color: #fff; font-size: 28px; line-height: 1; cursor: pointer; box-shadow: 0 12px 30px rgba(0,0,0,.24); }
.image-lightbox__close:focus-visible { outline: 3px solid rgba(255,255,255,.72); outline-offset: 3px; }
.image-lightbox__caption { justify-self: center; color: rgba(255,255,255,.78); font-size: 14px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.section-head p { max-width: 560px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.card { position: relative; background: rgba(255,253,248,.76); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px; box-shadow: var(--shadow-soft); }
.card::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: linear-gradient(145deg, rgba(255,255,255,.32), transparent 38%); }
.card > * { position: relative; z-index: 1; }
.card h3 { margin-bottom: 10px; }
.card-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.pill { display: inline-flex; align-items: center; min-height: 28px; padding: 3px 10px; border-radius: 999px; font-size: 13px; color: #566660; border: 1px solid var(--line); background: rgba(239,230,216,.55); }
.pill.green { background: var(--accent-soft); color: #23635f; border-color: rgba(31,130,122,.18); }
.pill.warm { background: var(--warm-soft); color: #87502f; border-color: rgba(196,111,58,.18); }
.number { width: 36px; height: 36px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--accent-soft); color: var(--accent); font-weight: 800; margin-bottom: 16px; }
.flow-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; align-items: stretch; }
.flow-step { padding: 18px; border-radius: var(--radius-md); border: 1px dashed var(--line-strong); background: rgba(255,253,248,.66); }
.flow-step strong { display: block; margin-bottom: 6px; }
.contact-panel { display: grid; grid-template-columns: minmax(0, .95fr) minmax(300px, 1.05fr); gap: 20px; align-items: stretch; }
.contact-info { padding: clamp(24px, 4vw, 36px); border-radius: var(--radius-xl); background: var(--ink); color: #fff; }
.contact-info p { color: rgba(255,255,255,.72); }
.contact-info a { color: #fff; border-bottom: 1px solid rgba(255,255,255,.3); }
.qr-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.qr-card { background: rgba(255,253,248,.8); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px; text-align: center; }
.qr-card img { margin: 0 auto 12px; border-radius: 14px; border: 1px solid var(--line); background: var(--paper-2); }
.page-hero { padding: clamp(48px, 7vw, 82px) 0 28px; }
.page-hero .lead { margin-top: 18px; }
.list { display: grid; gap: 14px; }
.list-item { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: start; padding: 22px; border-radius: var(--radius-lg); border: 1px solid var(--line); background: rgba(255,253,248,.72); }
.article-title { font-size: clamp(20px, 2vw, 27px); font-weight: 750; color: var(--ink); line-height: 1.35; }
.note-box { padding: 20px; border-radius: var(--radius-lg); background: rgba(220,238,233,.55); border: 1px solid rgba(31,130,122,.16); }
.policy { max-width: 860px; display: grid; gap: 24px; }
.policy section { padding: 24px; background: rgba(255,253,248,.72); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.policy h2 { font-size: clamp(24px, 3vw, 34px); margin-bottom: 10px; }
.policy ul, .card ul { color: var(--muted); margin: 10px 0 0; padding-left: 1.2em; }
.site-footer { border-top: 1px solid var(--line); padding: 30px 0 42px; color: var(--faint); }
.footer-grid { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer-links { display: flex; gap: 14px; flex-wrap: wrap; }
.reveal { opacity: 1; transform: none; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .nav-links { position: absolute; left: var(--gutter); right: var(--gutter); top: 65px; display: none; flex-direction: column; align-items: stretch; padding: 12px; background: rgba(255,253,248,.96); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); }
  .nav-links.is-open { display: flex; }
  .hero-grid, .contact-panel, .grid-2 { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .flow-strip { grid-template-columns: 1fr 1fr; }
  .section-head { display: grid; }
  .list-item { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  :root { --gutter: 18px; }
  .hero { padding-top: 38px; }
  .qr-grid, .flow-strip { grid-template-columns: 1fr; }
  .btn { width: 100%; }
  .hero-actions .btn, .actions .btn { width: auto; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

.prose { max-width: 860px; display: grid; gap: 18px; }
.prose h2 { margin-top: 28px; }
.prose h3 { margin-top: 18px; }
.prose ul { color: var(--muted); margin: 0; padding-left: 1.2em; }
.notice { border: 1px solid var(--line); background: rgba(31,130,122,.07); border-radius: var(--radius-lg); padding: 20px; color: var(--muted); }
.long-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-xl); padding: clamp(22px,4vw,36px); box-shadow: var(--shadow-soft); }
.contact-panel h1 { color: var(--white); font-family: var(--font); font-size: clamp(2.2rem, 4vw, 3.25rem); line-height: 1.12; letter-spacing: -.05em; }

/* v3: real QR assets */
.qr-card img[src$=".jpg"] { width: min(100%, 230px); aspect-ratio: 1 / 1; object-fit: contain; background: #fff; padding: 10px; }
@media (max-width: 640px) { h1 { letter-spacing: -.04em; } }


/* v5: portrait is understated and only used on About page */
.profile-aside { display: grid; gap: 18px; align-content: start; }
.profile-aside .note-box { padding: 18px; border-radius: var(--radius-lg); background: rgba(220,238,233,.42); border: 1px solid rgba(31,130,122,.14); }
.profile-aside .note-box strong { display: block; margin-bottom: 8px; color: var(--ink); }
.portrait-card { margin: 0; width: min(100%, 190px); background: rgba(255,253,248,.72); border: 1px solid var(--line); border-radius: 18px; padding: 8px; box-shadow: var(--shadow-soft); }
.portrait-card-small img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; object-position: center 34%; border-radius: 13px; display: block; }
.portrait-card figcaption { margin-top: 6px; color: var(--muted); font-size: 12px; line-height: 1.45; text-align: center; }
.nav-links { gap: 10px; }
@media (max-width: 860px) { .portrait-card { width: min(170px, 100%); } }
/* v6: article publishing layout */
.article-figure { margin: 26px 0 30px; padding: clamp(10px, 2vw, 16px); border-radius: var(--radius-xl); background: rgba(255,253,248,.72); border: 1px solid var(--line); box-shadow: var(--shadow-soft); }
.article-figure img { width: 100%; height: auto; border-radius: 18px; }
.article-figure-wide { margin-left: max(-40px, -4vw); margin-right: max(-40px, -4vw); }
.prose > p { font-size: 1.02rem; }
.prose h2 + p, .prose h3 + p { margin-top: -4px; }
@media (max-width: 760px) { .article-figure-wide { margin-left: 0; margin-right: 0; } }
