
.merged-index { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:36px; max-width:1120px; margin:0 auto; padding:20px 40px 64px; }
.merged-index h2 { font:600 16px/1.5 Inter,sans-serif; margin:0 0 14px; }
.merged-index ul { list-style:none; padding:0; margin:0; }
.merged-index li { margin:8px 0; }
.merged-index a { font-size:16px; color:#333; text-underline-offset:4px; }
.merged-project { scroll-margin-top:90px; max-width:1120px; margin:auto; padding:64px 40px; border-top:1px solid #dedbd3; display:grid; grid-template-columns:1fr 1fr; gap:64px; align-items:center; }
.merged-project-copy h2 { font:400 42px/1.1 'Instrument Serif',serif; margin:0 0 20px; }
.merged-project-copy p { font:16px/1.8 Inter,sans-serif; margin:0 0 20px; }
.merged-project-copy a { color:#1d3a8a; text-underline-offset:6px; }
.merged-project video { width:100%; max-height:540px; object-fit:contain; }
.merged-scroll-image { max-height:500px; overflow:auto; }
.merged-scroll-image img { width:100%; display:block; }
.merged-project:not(.has-video):not(:has(img)) { grid-template-columns:1fr; padding-top:40px; padding-bottom:40px; }
.merged-about { max-width:760px; margin:auto; }
.merged-about p { line-height:1.8; margin:20px 0; }
.merged-about h2 { margin-top:40px; font-size:22px; }
.merged-about .story-gallery { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin:24px 0; }
.merged-about .story-gallery p { margin:0; }
.merged-about img { display:block; width:100%; height:auto; }
#built,#planfold { scroll-margin-top:80px; }
@media(max-width:640px) { .merged-index{grid-template-columns:1fr;gap:24px;padding:24px;} .merged-project{grid-template-columns:1fr;gap:28px;padding:40px 24px;} .merged-project-copy h2{font-size:34px;} }

/* Match the original full-width alternating paper sections. */
.merged-section { border-top:1px solid var(--border-light, #dedbd3); scroll-margin-top:80px; }
.merged-section-warm { background:var(--paper-warm); }
.go-out-media { max-width:390px; }
.go-out-media video { aspect-ratio:auto; max-height:620px; background:transparent; }
.merged-section .merged-scroll-image { width:100%; max-width:520px; justify-self:center; }

/* A shorter opening, then generous product sections and compact collections. */
.site-shell .hero { min-height:0; padding-bottom:12px; }
.site-shell .hero-grid { padding-top:72px; padding-bottom:20px; }
.site-shell .hero-copy { padding-bottom:0; }
.merged-index { padding-top:16px; padding-bottom:48px; }
#go-out.planfold-section,#clearmind.planfold-section { padding-top:72px; padding-bottom:72px; }
#clearmind { background:var(--paper); scroll-margin-top:90px; }
.compact-work-group { padding:72px 56px; border-top:1px solid rgba(26,26,26,.12); background:var(--paper-warm); }
.compact-work-group h2 { font:400 36px/1.2 'Instrument Serif',serif; margin:0 0 36px; }
.compact-work-grid { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:56px; }
.compact-work-card { min-width:0; scroll-margin-top:100px; }
.compact-work-card h3 { font-size:24px; font-weight:500; margin:0 0 16px; }
.compact-work-card p { font-size:16px; line-height:1.8; margin:0 0 24px; color:var(--ink-body); }
.compact-work-card video { display:block; width:100%; max-height:380px; object-fit:contain; }
.compact-work-card .merged-scroll-image { max-height:380px; }
.design-work-group { background:var(--paper); }
@media(max-width:820px) {
 .site-shell .hero-grid { padding-top:60px; padding-bottom:8px; }
 .compact-work-group { padding:48px 28px; }
 .compact-work-grid { grid-template-columns:1fr; gap:40px; }
 #go-out.planfold-section,#clearmind.planfold-section { padding-top:48px; padding-bottom:48px; }
 .go-out-media { max-width:320px; }
}
@media(max-width:540px) {
 .compact-work-group { padding:40px 20px; }
 .merged-index { padding-bottom:32px; }
 .compact-work-group h2 { font-size:30px; margin-bottom:28px; }
 .compact-work-card h3 { font-size:22px; }
}

/* Chinese text follows the opening's clean sans-serif body style. */
html[lang^="zh"] .product-intro,
html[lang^="zh"] .product-intro h3,
html[lang^="zh"] .product-intro p,
html[lang^="zh"] .compact-work-group h2,
html[lang^="zh"] .compact-work-card,
html[lang^="zh"] .merged-index,
html[lang^="zh"] .merged-index h2,
html[lang^="zh"] .merged-about h2 { font-family:var(--font-body-cjk); }
html[lang^="zh"] .compact-work-group h2 { font-size:28px; font-weight:500; }

/* One underline system for project actions and the internal making-of link. */
.site-shell .planfold-play-link,
.site-shell .build-entry-link,
.site-shell .build-entry:hover .build-entry-link,
.site-shell .build-entry:focus-visible .build-entry-link {
 border-bottom:0;
 text-decoration-line:underline;
 text-decoration-color:currentColor;
 text-decoration-thickness:1px;
 text-underline-offset:6px;
 text-decoration-skip-ink:auto;
 padding:6px 0;
 font-size:15px;
 line-height:1.5;
 letter-spacing:0;
 min-height:0;
}
.site-shell a.build-entry { text-decoration:none; }
.site-shell .merged-index a { text-decoration-thickness:1px; text-underline-offset:6px; }

/* Size each demo frame from the media's native ratio, without letterboxing. */
#go-out .planfold-media { width:100%; max-width:304px; padding:0; }
#go-out .planfold-media video { display:block; width:100%; height:auto; max-height:none; aspect-ratio:720 / 1466; background:transparent; }
#ai-animation-course .planfold-media { padding:0; }
#ai-animation-course .planfold-media video { display:block; width:100%; height:auto; max-height:none; aspect-ratio:1280 / 756; background:transparent; }
#go-out .demo-ink-frame, #ai-animation-course .demo-ink-frame { inset:-4px; width:calc(100% + 8px); height:calc(100% + 8px); }

/* Both hand-drawn outlines sit outside the recording, including its title. */
#go-out .demo-ink-frame { inset:-32px -12px; width:calc(100% + 24px); height:calc(100% + 64px); }

/* The scrapbook recording uses its native landscape proportions. */
#obsidian-scrapbook .planfold-media { padding:10px; }
#obsidian-scrapbook .planfold-media video { width:100%; height:auto; max-height:none; aspect-ratio:3808 / 2160; background:transparent; }

/* Intro and project index share the left column beside the portrait. */
.site-shell .hero-grid .hero-copy { min-width:0; }
.hero-copy .merged-index { width:100%; max-width:none; margin:32px 0 0; padding:0; gap:24px; }
.hero-copy .merged-index section { min-width:0; }
.hero-copy .merged-index a { overflow-wrap:break-word; }
@media(min-width:821px) {
 .site-shell .hero-grid { grid-template-columns:minmax(0,1.35fr) minmax(0,1fr); }
}
@media(max-width:640px) {
 .hero-copy .merged-index { grid-template-columns:1fr; gap:24px; margin-top:28px; }
}
