:root {
  --ink: #000000;
  --paper: #ffffff;
  --u: 8px;
  --maxw: 1160px;
  --sans: "Noto Sans JP", "Helvetica Neue", Helvetica, Arial, system-ui, "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  --serif: "Noto Serif JP", "Times New Roman", YuMincho, "Hiragino Mincho ProN", serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.8;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input { font-family: inherit; font-size: 16px; }
p { margin: 0 0 1.1em; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.35; margin: 0 0 16px; }
h1 { letter-spacing: -0.01em; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

/* ---------- 页头 ---------- */
.top {
  position: relative;
  z-index: 30;
  background: var(--paper);
  border-bottom: 1px solid var(--ink);
}

.top-in {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 10px 16px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  grid-template-areas: "l b r";
  align-items: center;
  gap: 8px;
}

.top-left { grid-area: l; justify-self: start; display: flex; gap: 8px; }
.top-right { grid-area: r; justify-self: end; display: flex; gap: 8px; align-items: center; min-width: 0; }

.brand {
  grid-area: b;
  justify-self: center;
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 4px 8px;
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

/* 折叠菜单 */
.dd { position: relative; }

.dd > summary {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
  cursor: pointer;
  min-height: 40px;
  padding: 8px 16px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  font-size: 16px;
  font-weight: 500;
  white-space: nowrap;
  transition: background 0.16s ease, color 0.16s ease;
}

.dd > summary::-webkit-details-marker { display: none; }
.dd > summary::after { content: "＋"; font-size: 13px; line-height: 1; }
.dd[open] > summary::after { content: "－"; }
.dd > summary:hover { background: var(--ink); color: var(--paper); }

.dd-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 40;
  width: 218px;
  max-width: calc(100vw - 32px);
  margin: 0;
  padding: 8px;
  list-style: none;
  display: grid;
  gap: 6px;
  background: var(--paper);
  border: 1px solid var(--ink);
  box-shadow: 8px 8px 0 var(--ink);
}

.dd-r .dd-menu { left: auto; right: 0; }

.pill {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-size: 16px;
  line-height: 1.4;
  transition: background 0.16s ease, color 0.16s ease;
}

.pill:hover { background: var(--ink); color: var(--paper); }

/* 搜索 */
.srch {
  display: flex;
  align-items: stretch;
  min-height: 40px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  overflow: hidden;
}

.srch input {
  width: 148px;
  min-width: 0;
  border: 0;
  background: transparent;
  padding: 0 14px;
  outline: none;
}

.srch input::placeholder { color: #6b6b6b; }

.srch button {
  border: 0;
  border-left: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  padding: 0 14px;
  min-height: 40px;
  cursor: pointer;
}

/* ---------- 粘性锚点条 ---------- */
.bar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--ink);
  border-bottom: 1px solid var(--ink);
}

.bar-in {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 6px 16px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.bar-in::-webkit-scrollbar { display: none; }

.bar-in a {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 14px;
  border: 1px solid #4a4a4a;
  border-radius: 999px;
  color: var(--paper);
  font-size: 15px;
  white-space: nowrap;
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}

.bar-in a:hover { background: #fff; color: #000; border-color: #fff; }
.bar-in a[aria-current="true"] { background: #fff; color: #000; border-color: #fff; }
.bar-in a:focus-visible { outline-color: #fff; }

/* ---------- 首屏 ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr;
  border-bottom: 1px solid var(--ink);
  background-image: radial-gradient(rgba(0, 0, 0, 0.34) 1px, transparent 1px);
  background-size: 14px 14px;
}

.hero-txt {
  text-align: center;
  padding: 56px 20px 24px;
}

.hero-mark {
  margin: 0 0 18px;
  font-size: 12px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  font-weight: 500;
}

.hero h1 {
  margin: 0 auto;
  max-width: 15em;
  font-size: clamp(30px, 6.4vw, 62px);
  line-height: 1.14;
  letter-spacing: -0.015em;
}

.hero-media {
  align-self: end;
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 16px 32px;
  min-height: 8px;
}

.hero-img {
  width: 100%;
  max-height: 48vh;
  object-fit: cover;
  border: 1px solid var(--ink);
  box-shadow: 12px 12px 0 var(--ink);
}

/* ---------- 主体网格 ---------- */
.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 40px 16px 72px;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
  align-items: start;
}

.content-col { grid-column: 1 / span 8; min-width: 0; }
div { min-width: 0; }

div section { scroll-margin-top: 88px; }

div > section {
  counter-increment: sec;
  margin-top: 44px;
  padding-top: 40px;
  border-top: 1px solid var(--ink);
}

div { counter-reset: sec; }
div > section:first-child { margin-top: 0; padding-top: 0; border-top: 0; }

div > section h2::before {
  content: counter(sec, decimal-leading-zero);
  display: block;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.24em;
  margin-bottom: 10px;
}

div h2 { font-size: clamp(22px, 3vw, 31px); }
div h3 { font-size: 20px; }

div ul, div ol { padding-left: 1.3em; margin: 0 0 1.2em; }
div li { margin-bottom: 0.4em; }

div a {
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

div blockquote {
  margin: 0 0 1.2em;
  padding: 4px 0 4px 18px;
  border-left: 4px solid var(--ink);
  font-family: var(--serif);
}

div table { width: 100%; border-collapse: collapse; margin-bottom: 1.2em; font-size: 16px; }
div th, div td { border: 1px solid var(--ink); padding: 8px 10px; text-align: left; }

/* ---------- 右侧栏 ---------- */
.rail {
  grid-column: 10 / span 3;
  position: sticky;
  top: 80px;
  padding: 20px;
  background: var(--paper);
  border: 1px solid var(--ink);
  box-shadow: 6px 6px 0 var(--ink);
}

.rail h2 {
  font-size: 18px;
  line-height: 1.45;
  margin: 0 0 8px;
}

.rail .subtitle {
  margin: 0 0 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ink);
  font-size: 15px;
  line-height: 1.7;
  color: #333;
}

.rail ul { list-style: none; margin: 0; padding: 0; }
.rail li + li { margin-top: 2px; }

.rail-a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 0;
  border-bottom: 1px dashed #b4b4b4;
  font-size: 15px;
  line-height: 1.5;
  transition: padding-left 0.16s ease;
}

.rail-a:hover { padding-left: 6px; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 页脚 ---------- */
.foot {
  border-top: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  padding: 48px 0 24px;
}

.foot-in {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 16px;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 32px;
  align-items: start;
}

.mega {
  margin: 0;
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(40px, 9vw, 92px);
  line-height: 0.92;
  letter-spacing: 0.02em;
}

.addr {
  font-style: normal;
  font-size: 16px;
  line-height: 1.7;
  border-top: 2px solid var(--paper);
  padding-top: 10px;
  display: block;
}

.foot-links ul {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 2px solid var(--paper);
  padding-top: 10px;
}

.foot-a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 4px 0;
  font-size: 16px;
  line-height: 1.5;
  color: var(--paper);
}

.foot-a:hover { text-decoration: underline; text-underline-offset: 4px; }

.foot :focus-visible { outline-color: var(--paper); }

.foot-end {
  max-width: var(--maxw);
  margin: 40px auto 0;
  padding: 16px 16px 0;
  border-top: 1px solid #4a4a4a;
}

.cpr { margin: 0; font-size: 13px; letter-spacing: 0.08em; }

/* ---------- 移动端 ---------- */
@media (max-width: 900px) {
  .content-col { grid-column: 1 / span 12; }
  .rail {
    grid-column: 1 / span 12;
    position: static;
    margin-top: 40px;
  }
  .foot-in { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  body { font-size: 16px; }
  .top-in {
    grid-template-columns: 1fr auto 1fr;
    grid-template-areas: "l b ." "r r r";
    row-gap: 8px;
    padding: 10px 12px;
  }
  .top-right { justify-self: stretch; width: 100%; }
  .srch { flex: 1 1 auto; }
  .srch input { width: 100%; }
  .brand { font-size: 18px; letter-spacing: 0.12em; }
  .wrap { padding: 28px 14px 56px; }
  .hero-txt { padding: 40px 16px 20px; }
  .hero-mark { letter-spacing: 0.3em; margin-bottom: 14px; }
  .hero-media { padding: 0 14px 26px; }
  .hero-img { box-shadow: 8px 8px 0 var(--ink); max-height: 40vh; }
  .foot-in { grid-template-columns: 1fr; gap: 28px; }
  .foot { padding-top: 36px; }
  .rail { padding: 16px; box-shadow: 4px 4px 0 var(--ink); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

button[aria-expanded]{min-width:44px;min-height:44px}
