:root {
  color-scheme: light;
  --paper: #fffcff;
  --ink: #493050;
  --muted: #75627b;
  --line: #e7d7e9;
  --accent: #b92d77;
  --accent-hover: #9e2264;
  --pink: #ee5ba8;
  --pink-soft: #fff0f8;
  --pink-hero: #fbd6ec;
  --lavender: #a17bdf;
  --lavender-soft: #eee4fa;
  --lavender-deep: #7950b5;
  --yellow: #fff4ce;
  --font: "Yu Gothic", "Hiragino Kaku Gothic ProN", "Noto Sans JP", Meiryo, sans-serif;
  --display: "Avenir Next", "Trebuchet MS", var(--font);
  font-family: var(--font);
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 32px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-size: 16px; line-height: 1.9; letter-spacing: .015em; overflow-x: clip; }
body:has(dialog[open]) { overflow: hidden; }
a { color: var(--accent); text-underline-offset: 4px; }
a:hover { color: var(--accent-hover); }
button { font: inherit; cursor: pointer; }
a, button { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid var(--lavender-deep); outline-offset: 5px; }
::selection { background: #f4c5df; color: var(--ink); }
img { display: block; max-width: 100%; height: auto; }
figure { margin: 24px 0 16px; }
figcaption { margin-top: 12px; font-size: 12px; line-height: 1.8; color: var(--muted); }
p { margin: 0 0 16px; }
h1, h2, h3 { margin: 0; line-height: 1.5; font-weight: 700; letter-spacing: .01em; }
h2 { font-size: 28px; }
h3 { font-size: 17px; }
strong { font-weight: 700; }
.wrap { width: min(1200px, calc(100% - 96px)); margin-inline: auto; }
.skip { position: fixed; z-index: 20; top: -100px; left: 24px; padding: 12px 24px; background: white; border: 2px solid var(--accent); }
.skip:focus { top: 12px; }

/* Header and first screen */
.site-header { width: min(1344px, calc(100% - 96px)); height: 100px; margin: auto; display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); font: 700 23px var(--display); text-decoration: none; white-space: nowrap; }
.brand b { color: var(--accent); font-weight: 700; }
.brand img { border-radius: 10px; width: 36px; height: 36px; }
.site-header nav { display: flex; gap: 32px; align-items: center; }
.site-header nav a { padding-block: 12px; font-size: 13px; font-weight: 700; color: var(--ink); text-decoration: none; border-bottom: 2px solid transparent; transition: color 160ms, border-color 160ms; }
.site-header nav a:hover { color: var(--accent); border-color: var(--pink); }
.hero { position: relative; isolation: isolate; clip-path: inset(0 -100vw); display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 56px; min-height: 560px; padding-block: 64px 72px; }
.hero::before { content: ""; position: absolute; z-index: -2; left: calc(50% - 50vw); top: 0; bottom: 0; width: 100vw; background: var(--pink-hero); }
.hero::after { content: ""; position: absolute; z-index: -1; width: 68%; height: 116%; right: calc((100% - 100vw) / 2); top: -8%; background: #d9bdf4; border-radius: 50%; transform: none; pointer-events: none; }
.eyebrow { display: inline-block; margin-bottom: 24px; padding: 6px 16px; background: white; border: 1px solid #f0c5df; border-radius: 6px; box-shadow: 4px 4px 0 #db98c0; color: var(--accent); font-size: 12px; font-weight: 700; }
h1 { font: 800 clamp(40px, 4.1vw, 60px)/1.25 var(--display); letter-spacing: -.025em; }
h1 span { display: block; white-space: nowrap; paint-order: stroke fill; -webkit-text-stroke: 4px #fff; text-shadow: 3px 4px 0 #ae78b435; }
.hero-product { color: #c53782; }
.hero-guide { color: var(--lavender-deep); margin-top: 8px; font-family: var(--font); font-size: .87em; font-weight: 800; letter-spacing: .025em; }
.hero-description { margin: 24px 0 28px; color: #67446a; font-size: 14px; line-height: 2; max-width: 34em; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 24px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 20px; min-height: 52px; padding: 14px 24px; border: 2px solid white; border-radius: 32px; font-size: 13px; font-weight: 700; line-height: 1.6; text-decoration: none; transition: background-color 160ms, border-color 160ms, color 160ms; }
.primary { color: white; background: var(--accent); box-shadow: 4px 4px 0 #ad77a42b; }
.primary:hover { background: var(--accent-hover); color: white; border-color: white; }
.text-link { display: inline-flex; align-items: center; gap: 12px; font-size: 13px; font-weight: 700; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.release-meta { margin: 16px 0 0; font-size: 11px; color: #73556f; }
.hero-photo { margin: 0; transform: rotate(2deg); }
.hero-photo .zoom-link { padding: 8px; background: #fffafd; border: 2px solid white; border-radius: 24px; box-shadow: 10px 10px 0 #ac7bc42e; }
.hero-photo .zoom-link img { border-radius: 14px; }
.hero-photo figcaption { margin: 20px 8px 0; transform: rotate(-2deg); color: #63476d; }

/* Photo links and requirements */
.zoom-link { position: relative; display: block; background: white; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; cursor: zoom-in; line-height: 0; }
.zoom-link img { width: 100%; }
.zoom-label { position: absolute; right: 12px; bottom: 12px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 20px; background: #fffffff2; color: #654477; font-size: 10px; line-height: 1.4; pointer-events: none; }
.section-label { margin-bottom: 8px; color: var(--muted); font-size: 11px; font-weight: 700; line-height: 1.7; }
.requirements { position: relative; margin-block: 40px 0; padding: 28px 32px; background: white; border: 1px solid var(--line); border-radius: 24px; display: grid; grid-template-columns: 176px 1fr; gap: 20px 32px; }
.requirements h2 { font-size: 23px; }
.requirements dl { margin: 0; display: grid; grid-template-columns: 1.15fr 1fr 1.3fr; gap: 24px; }
.requirements dt { margin-bottom: 8px; font-size: 12px; font-weight: 700; color: #76519c; }
.requirements dd { margin: 0; font-size: 12px; color: var(--muted); line-height: 1.8; }
.requirements-note { grid-column: 2; margin: 0; font-size: 11px; color: var(--muted); }

/* Numbered instructions */
.guide-layout { display: grid; grid-template-columns: 200px minmax(0, 1fr); align-items: start; gap: 40px; padding-top: 56px; }
.contents { position: sticky; top: 32px; padding: 24px 16px; background: #f6effb; border: 1px solid #e8d9f0; border-radius: 20px; }
.contents > p { margin: 0 8px 16px; }
.contents nav { display: grid; gap: 4px; }
.contents nav a { display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 8px; border-radius: 10px; font-size: 12px; color: #6c5476; text-decoration: none; transition: background-color 160ms, color 160ms; }
.contents nav a span { color: var(--lavender-deep); font: 700 12px var(--display); font-variant-numeric: tabular-nums; }
.contents nav a:hover, .contents nav a[aria-current="location"] { color: var(--accent); background: #f9dfed; }
.contents-extra { display: inline-block; margin: 20px 8px 0; font-size: 11px; text-decoration: none; }
.steps { min-width: 0; }
.step { margin-bottom: 32px; padding: 32px; border: 1px solid var(--line); border-radius: 24px; background: white; scroll-margin-top: 24px; }
.step:last-child { margin-bottom: 0; }
.step-heading { display: flex; align-items: center; gap: 20px; margin-bottom: 24px; }
.step-number { display: grid; place-items: center; width: 48px; height: 48px; flex-shrink: 0; border: 2px solid white; border-radius: 16px; color: var(--accent); background: #fde1f0; box-shadow: 3px 3px 0 #e5c6e2; font: 700 20px var(--display); font-variant-numeric: tabular-nums; }
.step:nth-child(even) .step-number { background: #eee4fa; color: var(--lavender-deep); }
.step-heading .section-label { color: #86558c; }
.step h2 { font-size: 25px; text-wrap: balance; }
.step > p { font-size: 14px; }
.file-name { padding: 12px 16px; border: 1px dashed #d8b9e0; border-radius: 12px; color: #70537b; background: #fcf7ff; font: 12px/1.9 ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; }
.finder-photo .zoom-link { aspect-ratio: 2.7; }
.finder-photo img { height: 100%; object-fit: cover; object-position: top; }
.note { margin-top: 24px; padding: 20px 24px; border: 1px solid #efdfab; border-left: 4px solid #d5b550; border-radius: 14px; background: var(--yellow); }
.note h3 { margin-bottom: 8px; font-size: 14px; }
.note p { margin: 0; font-size: 12px; }
.inline-note { margin-top: 24px; padding: 20px 24px; border: 1px solid #e5d8f0; border-radius: 14px; background: #f5effb; }
.inline-note > strong { font-size: 13px; color: #6c4396; }
.inline-note p { margin: 8px 0 0; font-size: 12px; }
.disk-layout { display: grid; grid-template-columns: 1fr .72fr; align-items: start; gap: 32px; }
.disk-layout figure { margin-top: 12px; }
.disk-notes { padding-top: 24px; }
.disk-notes h3 { margin-bottom: 24px; font-size: 14px; }
.disk-notes ol { margin: 0; padding-left: 20px; }
.disk-notes li { padding-left: 4px; margin-bottom: 24px; font-size: 12px; color: var(--muted); }
.disk-notes strong { color: var(--ink); }
.settings-photo .zoom-link { aspect-ratio: 1.85; }
.settings-photo img { height: 100%; object-fit: cover; object-position: top; }
.setup-flow { padding-left: 24px; margin: 28px 0 0; }
.setup-flow li { padding-left: 8px; margin-bottom: 24px; font-size: 14px; }
.setup-flow li::marker { color: var(--accent); font-weight: 700; }
.setup-flow p { margin: 8px 0 0; font-size: 13px; color: var(--muted); }
.small { font-size: 12px !important; color: var(--muted); }

/* Input and display settings */
.japanese-section { margin-top: 64px; padding: 56px 0; background: var(--pink-soft); border-block: 1px solid #f3e0ec; }
.japanese-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 96px; align-items: center; }
.japanese-layout h2 { margin-bottom: 24px; font-size: 32px; color: #8055a9; }
.japanese-layout > div > p:not(.section-label) { max-width: 420px; font-size: 14px; color: var(--muted); }
.key-steps { display: grid; align-content: center; gap: 20px; }
.key-steps > div > span { color: #77568b; font-size: 12px; }
.key-steps p { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 8px 0 0; }
kbd { padding: 8px 16px; border: 1px solid #dbc7e3; border-bottom: 4px solid #cfb3db; border-radius: 10px; color: #744596; background: white; font: 600 16px/1.5 var(--display); }
.key-steps b { font-size: 12px; font-weight: 400; color: var(--muted); }
.key-helper { font-size: 11px; color: var(--muted); }
.key-steps > p { display: block; font-size: 12px; line-height: 1.9; }
.display-section { padding-block: 72px; display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 72px; border-bottom: 1px solid var(--line); }
.display-copy h2 { margin-bottom: 24px; color: #8055a9; }
.display-copy p:not(.section-label) { font-size: 14px; }
.display-photo { margin: 0; }
.display-photo .zoom-link { padding: 8px; aspect-ratio: 1.04; background: #f4edfb; border: 1px solid #dfcdec; border-radius: 24px; }
.display-photo img { height: 100%; object-fit: cover; object-position: top; border-radius: 16px; }

/* FAQ, download and footer */
.faq-section { display: grid; grid-template-columns: 240px 1fr; gap: 48px; padding-block: 64px; }
.faq-section h2 { font-size: 28px; color: #8055a9; }
.faq-list { display: grid; gap: 12px; }
details { padding: 20px 24px; border: 1px solid var(--line); border-radius: 16px; background: white; }
summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; font-size: 14px; font-weight: 700; cursor: pointer; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "＋"; color: var(--accent); font-size: 18px; font-weight: 400; }
details[open] { background: #fcf7ff; }
details[open] summary::after { content: "−"; }
details p { margin: 16px 16px 0 0; font-size: 13px; line-height: 2; color: var(--muted); }
.end-download { display: flex; align-items: center; justify-content: space-between; gap: 32px; margin-bottom: 56px; padding: 40px; border: 2px solid white; border-radius: 28px; background: var(--lavender-soft); box-shadow: 6px 6px 0 #e5cce9; }
.end-download h2 { font-size: 24px; color: #6d4495; }
.end-download p { margin: 8px 0 0; font-size: 13px; color: #70547f; }
.end-download .button { white-space: nowrap; }
.site-footer { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding-bottom: 32px; }
.footer-brand { font: 700 20px var(--display); color: var(--ink); text-decoration: none; }
.site-footer p { margin-top: 12px; font-size: 11px; color: var(--muted); line-height: 1.9; }
.footer-links { display: flex; justify-content: end; align-items: start; flex-wrap: wrap; gap: 24px; padding-top: 4px; }
.footer-links a { font-size: 12px; text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }
.footer-meta { grid-column: 1/-1; margin: 0 !important; padding-top: 20px; border-top: 1px solid var(--line); font-size: 10px !important; }

/* Alternative BOOTH installation route */
.contents nav .contents-subsection { min-height: 32px; margin-left: 20px; font-size: 11px; }
.download-alternative { margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--line); scroll-margin-top: 24px; }
.download-alternative h3 { font-size: 20px; }
.download-alternative > p { margin-top: 16px; font-size: 14px; }
.download-alternative > .small { font-size: 12px; }
.installer-photo { max-width: 570px; margin: 20px auto 8px; }

/* Photo viewer */
dialog { width: min(1200px, calc(100vw - 40px)); max-width: none; max-height: 92vh; max-height: 92dvh; overflow: auto; padding: 0; border: 3px solid white; border-radius: 20px; background: white; color: var(--ink); box-shadow: 0 24px 90px #49305055; }
dialog::backdrop { background: #493050b8; }
.photo-toolbar { position: sticky; top: 0; left: 0; width: 100%; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px 20px; background: #fff9fd; border-bottom: 1px solid var(--line); }
.photo-toolbar p { min-width: 0; margin: 0; font-size: 12px; line-height: 1.6; }
.photo-toolbar button { flex-shrink: 0; padding: 8px 12px; border: 1px solid #ddc5e6; border-radius: 12px; background: white; color: #744596; font-size: 12px; }
.photo-toolbar button:hover { background: var(--lavender-soft); }
.photo-actions { display: flex; gap: 8px; flex-shrink: 0; }
#photo-full { width: 100%; height: auto; }
#photo-full.is-zoomed { width: auto; min-width: 100%; max-width: none; }

@media (max-width: 1050px) {
  .wrap, .site-header { width: calc(100% - 64px); }
  .site-header nav { gap: 20px; }
  .hero { gap: 32px; min-height: 520px; padding-block: 48px 56px; }
  h1 { font-size: 44px; }
  .hero-description { font-size: 13px; }
  .hero-actions { gap: 16px; }
  .hero-actions .button { font-size: 12px; padding: 12px 16px; }
  .guide-layout { grid-template-columns: 176px minmax(0, 1fr); gap: 24px; }
  .requirements { grid-template-columns: 144px 1fr; gap: 20px; padding: 24px; }
  .requirements dl { gap: 16px; }
  .requirements dd { font-size: 11px; }
  .step { padding: 24px; }
  .step h2 { font-size: 22px; }
  .step-heading { gap: 16px; }
  .disk-layout { gap: 24px; }
  .japanese-layout { gap: 56px; }
  .display-section { gap: 40px; }
  .faq-section { grid-template-columns: 200px 1fr; gap: 32px; }
  .end-download h2 { font-size: 22px; }
}

@media (max-width: 760px) {
  .wrap, .site-header { width: calc(100% - 40px); }
  .site-header { height: 80px; gap: 16px; }
  .brand { font-size: 19px; gap: 8px; }
  .brand img { width: 32px; height: 32px; }
  .site-header nav { gap: 16px; }
  .site-header nav a { font-size: 11px; }
  .site-header .main-nav a:nth-child(2), .site-header .main-nav a:nth-child(3) { display: none; }
  .hero { display: grid; grid-template-columns: 1fr; gap: 36px; min-height: 0; padding-block: 40px 48px; }
  .hero::after { width: 125%; height: 48%; right: calc((100% - 100vw) / 2); top: auto; bottom: -3%; transform: none; }
  .eyebrow { font-size: 11px; padding: 6px 12px; margin-bottom: 24px; }
  h1 { font-size: clamp(38px, 9.5vw, 50px); }
  h1 span { -webkit-text-stroke-width: 3px; }
  .hero-guide { margin-top: 8px; }
  .hero-description { margin: 20px 0 24px; font-size: 14px; }
  .hero-actions { gap: 20px; }
  .hero-actions .button { font-size: 12px; padding: 14px 20px; }
  .hero-photo { transform: rotate(1deg); }
  .hero-photo .zoom-link { padding: 6px; border-radius: 20px; box-shadow: 6px 6px 0 #ac7bc42e; }
  .hero-photo .zoom-link img { border-radius: 12px; }
  .hero-photo figcaption { transform: rotate(-1deg); margin: 16px 4px 0; font-size: 11px; }
  .release-meta { font-size: 10px; }
  .requirements { margin-top: 32px; display: block; padding: 24px; border-radius: 20px; }
  .requirements h2 { font-size: 22px; margin-bottom: 20px; }
  .requirements dl { grid-template-columns: 1fr; gap: 20px; }
  .requirements dl > div { display: grid; grid-template-columns: 88px 1fr; gap: 12px; }
  .requirements dt, .requirements dd { font-size: 11px; }
  .requirements-note { margin-top: 20px; }
  .guide-layout { grid-template-columns: 1fr; gap: 24px; padding-top: 32px; }
  .contents { position: static; padding: 20px; }
  .contents > p { margin: 0 0 12px; }
  .contents nav { grid-template-columns: 1fr 1fr; gap: 4px; }
  .contents nav a { font-size: 11px; padding: 8px 4px; gap: 8px; }
  .contents-extra { margin: 16px 4px 0; }
  .step { padding: 24px 20px; margin-bottom: 24px; border-radius: 20px; }
  .step-heading { gap: 12px; margin-bottom: 20px; }
  .step-number { width: 40px; height: 40px; font-size: 17px; border-radius: 12px; }
  .step h2 { font-size: 20px; }
  .step-heading .section-label { font-size: 10px; }
  .step > p { font-size: 14px; }
  .file-name { font-size: 10px; padding: 12px; }
  figure { margin: 24px 0 16px; }
  figcaption { font-size: 11px; }
  .finder-photo .zoom-link { aspect-ratio: 2; }
  .note, .inline-note { padding: 16px; }
  .note h3 { font-size: 13px; }
  .disk-layout { grid-template-columns: 1fr; gap: 4px; }
  .disk-layout figure { width: min(100%, 400px); margin: 12px auto; }
  .disk-notes { padding-top: 16px; }
  .disk-notes h3 { margin-bottom: 16px; }
  .disk-notes ol { display: grid; gap: 16px; padding-left: 20px; }
  .disk-notes li { margin-bottom: 0; }
  .settings-photo .zoom-link { aspect-ratio: 1.5; }
  .setup-flow { padding-left: 20px; }
  .setup-flow li { font-size: 13px; padding-left: 4px; }
  .setup-flow p { font-size: 12px; }
  .japanese-section { margin-top: 40px; padding: 40px 0; }
  .japanese-layout { grid-template-columns: 1fr; gap: 24px; }
  .japanese-layout h2 { font-size: 28px; margin-bottom: 20px; }
  .key-steps { gap: 20px; }
  kbd { font-size: 14px; padding: 8px 12px; }
  .display-section { grid-template-columns: 1fr; gap: 24px; padding-block: 40px; }
  .display-copy h2 { font-size: 26px; }
  .display-photo { width: 100%; max-width: 480px; margin: auto; }
  .faq-section { grid-template-columns: 1fr; gap: 24px; padding-block: 40px; }
  .faq-section h2 { font-size: 26px; }
  details { padding: 20px; }
  summary { font-size: 13px; }
  .end-download { display: block; padding: 28px 24px; margin-bottom: 40px; border-radius: 24px; }
  .end-download h2 { font-size: 22px; }
  .end-download .button { margin-top: 24px; width: 100%; font-size: 12px; white-space: normal; }
  .site-footer { grid-template-columns: 1fr; gap: 20px; }
  .footer-links { justify-content: start; gap: 20px; }
  .footer-meta { grid-column: 1; }
  dialog { width: calc(100vw - 16px); border-radius: 16px; }
  .photo-toolbar { padding: 12px; gap: 12px; }
  .photo-toolbar p { font-size: 10px; }
  .photo-toolbar button { font-size: 11px; padding: 8px; }
  .zoom-label { font-size: 9px; right: 8px; bottom: 8px; padding: 6px 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  a, button { transition: none !important; }
}

/* Shared language selector. Links work even when JavaScript/storage is disabled. */
html:lang(en) { --font: "Avenir Next", "Segoe UI", sans-serif; }
html:lang(ko) { --font: "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif; }
html:lang(zh-Hans) { --font: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif; }
html:lang(ko) body { word-break: keep-all; overflow-wrap: anywhere; }
.site-header { gap: 24px; height: auto; min-height: 100px; padding-block: 16px; flex-wrap: wrap; }
.site-header .main-nav { margin-left: auto; }
.language-picker { position: relative; z-index: 25; flex-shrink: 0; padding: 0; border-radius: 12px; background: white; }
.language-picker summary { padding: 10px 14px; gap: 12px; min-height: 44px; font-size: 12px; }
.language-picker summary::after { content: "⌄"; font-size: 14px; line-height: 1; }
.language-picker[open] { background: white; }
.language-picker[open] summary::after { content: "⌄"; transform: rotate(180deg); }
.site-header .language-picker nav { display: grid; position: absolute; top: calc(100% + 8px); right: 0; width: 168px; gap: 4px; padding: 8px; border: 1px solid var(--line); border-radius: 14px; background: white; box-shadow: 0 8px 24px #49305018; }
.site-header .language-picker nav a { display: block; border: 0; padding: 10px 12px; border-radius: 8px; font-size: 13px; }
.site-header .language-picker nav a:hover, .site-header .language-picker nav a[aria-current="page"] { background: var(--pink-soft); color: var(--accent); }
@media (max-width: 760px) {
  .site-header { min-height: 100px; gap: 8px 12px; }
  .brand { flex: 1; }
  .language-picker { order: 2; }
  .site-header .main-nav { order: 3; flex-basis: 100%; margin-left: 0; justify-content: space-between; }
  .site-header .main-nav a { padding-block: 4px; }
}
