:root {
  --brand: #27f275;
  --brand-dark: #0d5830;
  --ink: #0f172a;
  --muted: #475569;
  --line: #e2e8f0;
  --surface: #ffffff;
  --soft: #f8fafc;
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  line-height: 1.6;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 6rem; }
body { margin: 0; background: var(--soft); color: var(--ink); }
a { color: var(--brand-dark); text-underline-offset: 0.2em; }
a:hover { color: #075f2d; }
code { overflow-wrap: anywhere; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }

.skip-link {
  position: fixed;
  z-index: 20;
  top: 0.5rem;
  left: 0.5rem;
  padding: 0.65rem 0.9rem;
  border-radius: 0.5rem;
  background: var(--ink);
  color: white;
  transform: translateY(-150%);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  z-index: 10;
  top: 0;
  border-bottom: 1px solid var(--line);
  background: rgb(255 255 255 / 94%);
  backdrop-filter: blur(12px);
}
.header-inner {
  display: flex;
  width: min(100% - 2rem, 76rem);
  min-height: 4.5rem;
  margin: auto;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--ink);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-decoration: none;
}
.brand img { width: 2.25rem; height: 2.25rem; }
.brand-section {
  padding-left: 0.75rem;
  border-left: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0;
}
.app-link {
  display: inline-flex;
  min-height: 2.7rem;
  align-items: center;
  padding: 0.55rem 0.95rem;
  border: 1px solid var(--ink);
  border-radius: 0.55rem;
  background: var(--ink);
  box-shadow: 0 3px 0 var(--brand);
  color: white;
  font-size: 0.875rem;
  font-weight: 700;
  text-decoration: none;
}
.app-link:hover { color: white; transform: translateY(-1px); }

.release-bar {
  display: flex;
  width: min(100% - 2rem, 76rem);
  margin: 1.5rem auto 0;
  gap: 0.75rem;
}
.release-bar > div {
  flex: 1;
  padding: 0.85rem 1rem;
  border: 1px solid #b7f7cf;
  border-radius: 0.75rem;
  background: #effff5;
}
.release-bar span { display: block; color: var(--muted); font-size: 0.75rem; font-weight: 650; text-transform: uppercase; letter-spacing: 0.06em; }
.release-bar strong { display: block; margin-top: 0.15rem; font-size: 0.9rem; }

.page-layout {
  display: grid;
  width: min(100% - 2rem, 76rem);
  margin: 1.5rem auto 3rem;
  grid-template-columns: 15.5rem minmax(0, 1fr);
  gap: 2.25rem;
  align-items: start;
}
.contents {
  position: sticky;
  top: 6rem;
  max-height: calc(100vh - 7.5rem);
  overflow-y: auto;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: var(--surface);
}
.contents > p { margin: 0 0 0.6rem; font-size: 0.75rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; }
.contents ol,
.mobile-contents ol { margin: 0; padding-left: 1.35rem; }
.contents li,
.mobile-contents li { padding: 0.28rem 0 0.28rem 0.15rem; color: var(--muted); font-size: 0.82rem; line-height: 1.35; }
.contents a,
.mobile-contents a { color: inherit; font-weight: 600; text-decoration: none; }
.contents a:hover,
.mobile-contents a:hover { color: var(--brand-dark); text-decoration: underline; }
.mobile-contents { display: none; }

.manual {
  min-width: 0;
  padding: clamp(1.25rem, 4vw, 3.5rem);
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--surface);
  box-shadow: 0 18px 50px rgb(15 23 42 / 6%);
}
.manual article { max-width: 47rem; margin: auto; }
.manual h1 {
  margin: 0;
  font-size: clamp(2.2rem, 6vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.055em;
}
.manual h2 {
  margin: 3.25rem 0 1rem;
  padding-top: 0.35rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.2;
  letter-spacing: -0.035em;
}
.manual h2::before {
  display: block;
  width: 2.5rem;
  height: 0.28rem;
  margin-bottom: 0.75rem;
  border-radius: 999px;
  background: var(--brand);
  content: "";
}
.manual h3 { margin: 2rem 0 0.65rem; font-size: 1.16rem; line-height: 1.35; }
.manual p { margin: 0.8rem 0; color: #263449; }
.manual ul,
.manual ol { padding-left: 1.55rem; }
.manual li { margin: 0.4rem 0; padding-left: 0.2rem; }
.manual strong { color: var(--ink); }
.manual article > h2:nth-of-type(1) { margin-top: 1.25rem; color: var(--muted); font-size: 1.1rem; letter-spacing: 0; }
.manual article > h2:nth-of-type(1)::before { display: none; }
.manual article > h2:nth-of-type(2) { margin-top: 2.25rem; }
.manual article > h2:nth-of-type(2) + ol {
  padding: 1rem 1rem 1rem 2.8rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: var(--soft);
  columns: 2;
  column-gap: 2rem;
}
.manual article > h2:nth-of-type(2) + ol li { break-inside: avoid; }
.manual-footer {
  max-width: 47rem;
  margin: 3.5rem auto 0;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.85rem;
}

@media (max-width: 820px) {
  html { scroll-padding-top: 5.25rem; }
  .brand-section { display: none; }
  .release-bar { flex-direction: column; }
  .mobile-contents { display: block; width: min(100% - 2rem, 76rem); margin: 1rem auto 0; }
  .mobile-contents details { border: 1px solid var(--line); border-radius: 0.75rem; background: white; }
  .mobile-contents summary { padding: 0.85rem 1rem; cursor: pointer; font-weight: 750; }
  .mobile-contents ol { padding: 0 1.25rem 1rem 2.5rem; }
  .page-layout { display: block; margin-top: 1rem; }
  .contents { display: none; }
}

@media (max-width: 540px) {
  .header-inner { width: min(100% - 1.25rem, 76rem); }
  .brand { gap: 0.45rem; font-size: 1.1rem; }
  .brand img { width: 1.9rem; height: 1.9rem; }
  .app-link { min-height: 2.4rem; padding: 0.45rem 0.65rem; font-size: 0.78rem; }
  .release-bar,
  .mobile-contents,
  .page-layout { width: min(100% - 1rem, 76rem); }
  .manual { padding: 1.4rem 1.1rem; border-radius: 0.75rem; }
  .manual article > h2:nth-of-type(2) + ol { columns: 1; }
}

@media print {
  .site-header,
  .release-bar,
  .contents,
  .mobile-contents { display: none; }
  body { background: white; }
  .page-layout { display: block; width: 100%; margin: 0; }
  .manual { padding: 0; border: 0; box-shadow: none; }
  .manual h2 { break-after: avoid; }
}
