.story-page {
  --chapter-columns: minmax(0,.96fr) minmax(0,1.04fr);
  --chapter-gap: clamp(32px,4.6vw,64px);
  --preview-width: clamp(140px,17.8vw,224px);
  --preview-gap: clamp(14px,2vw,27px);
  --frame-padding: 8px;
  --frame-radius: 23px;
  --screen-radius: 15px;
}
:lang(ko) .story-page { word-break: keep-all; overflow-wrap: break-word; }
.headline-line { display: block; }
:lang(ko) .headline-line { white-space: nowrap; }

.story-hero {
  display: grid;
  grid-template-columns: minmax(0,1fr) minmax(0,1.13fr);
  align-items: center;
  gap: clamp(28px,5vw,68px);
  padding-block: clamp(29px,4.6vw,63px) clamp(27px,4.4vw,55px);
}
.story-hero .hero-copy:only-child { grid-column: 1 / -1; }
.story-hero h1 { font-size: clamp(32px,3.75vw,50px); font-weight: 750; line-height: 1.23; letter-spacing: -.053em; }
:lang(ko) .story-hero h1 { font-size: clamp(27px,3.58vw,49px); }
.story-hero .hero-copy p { max-width: 34rem; margin-top: clamp(20px,2.3vw,30px); line-height: 1.78; }
.story-film {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  margin: 0;
  background: #ead6c7;
  border-radius: clamp(20px,4vw,44px);
}
.story-film video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.chapter { --wash: #f9f3eb; background: var(--wash); border-top: 1px solid #e9ded4; }
.chapter-keepsake { --wash: #ebe5f0; }
.chapter-memories { --wash: #f7ede6; }
.chapter-growth { --wash: #edf0e7; }
.chapter-inner {
  display: grid;
  grid-template-columns: var(--chapter-columns);
  align-items: center;
  gap: var(--chapter-gap);
  padding-block: clamp(38px,6vw,82px);
}
.chapter-copy h2 { font-size: clamp(31px,3.5vw,48px); font-weight: 735; line-height: 1.22; letter-spacing: -.052em; }
:lang(ko) .chapter-keepsake h2 { font-size: clamp(27px,3.08vw,42px); }
.chapter-copy p, .visit-copy p {
  max-width: 35rem;
  margin-top: clamp(19px,2vw,27px);
  color: #53463f;
  font-size: clamp(16px,1.54vw,19px);
  line-height: 1.76;
}
.chapter-keepsake .story-return { max-width: 30em; margin-top: clamp(17px,2vw,25px); color: #39313e; font-weight: 690; }
.chapter-moments .chapter-inner {
  grid-template-areas: "album photos" "privacy photos";
  grid-template-rows: 1fr 1fr;
  row-gap: clamp(20px,2.4vw,30px);
}
.chapter-moments .chapter-copy { grid-area: album; align-self: end; }
.chapter-moments .preview-pair { grid-area: photos; }
.family-privacy { grid-area: privacy; align-self: start; border-top: 1px solid #ded1c6; padding-top: clamp(18px,2vw,27px); scroll-margin-top: 20px; }
.family-privacy h3 { font-size: clamp(18px,2vw,23px); line-height: 1.32; letter-spacing: -.035em; }
.family-privacy p { margin-top: 11px; color: #53463f; font-size: 15px; line-height: 1.72; }

.preview-pair {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  align-items: start;
  gap: var(--preview-gap);
  justify-self: center;
  width: min(100%,calc(var(--preview-width) + var(--preview-width) + var(--preview-gap)));
  min-width: 0;
}
.story-app { width: 100%; margin: 0; min-width: 0; }
.app-frame {
  display: block;
  width: 100%;
  padding: var(--frame-padding);
  background: #fffaf6;
  border: 1px solid #e0d6ce;
  border-radius: var(--frame-radius);
  box-shadow: 0 14px 30px #392d2314;
}
.app-screen { display: block; aspect-ratio: 393 / 852; overflow: hidden; border-radius: var(--screen-radius); background: #f8f6f2; }
.app-screen img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center; }
.screen-link { cursor: zoom-in; }
.screen-link:hover { border-color: #927b6a; }
.story-app figcaption, .visit-documents figcaption { margin-top: 13px; color: #463a33; font-size: 14px; font-weight: 650; line-height: 1.45; text-align: center; }
.story-app figcaption span { display: block; margin-top: 4px; color: #5c514b; font-size: 13px; font-weight: 500; }
.care-links { display: flex; flex-wrap: wrap; column-gap: 20px; margin-top: 13px; }
.care-links a { text-decoration: underline; text-underline-offset: .22em; }

.preparation-showcase {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: var(--chapter-columns);
  align-items: center;
  gap: var(--chapter-gap);
  min-width: 0;
  padding-top: clamp(29px,4vw,54px);
  border-top: 1px solid #d5d9cd;
  scroll-margin-top: 20px;
}
.showcase-copy h3, .visit-copy h3 { font-size: clamp(25px,3vw,37px); line-height: 1.24; letter-spacing: -.046em; }
.showcase-copy p { max-width: 41ch; margin-top: 16px; color: #53463f; font-size: 16px; line-height: 1.72; }
.preparation-showcase .sample-note, .visit-copy .sample-note, .story-note { margin-top: 13px; color: #5c514b; font-size: 13px; line-height: 1.6; }
.visit-feature {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0,.85fr) minmax(0,1.15fr);
  align-items: center;
  gap: clamp(22px,4vw,55px);
  padding: clamp(18px,4vw,48px);
  border: 1px solid #d7d4cb;
  border-radius: clamp(18px,3vw,32px);
  background: #f9f7f4;
}
.visit-copy ul { padding-left: 19px; margin: 18px 0; color: #53463f; }
.visit-copy li { margin-top: 9px; font-size: 15px; line-height: 1.67; }
.visit-documents { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: clamp(8px,2vw,17px); align-items: start; }
.visit-documents figure { margin: 0; min-width: 0; }
.visit-documents img { display: block; width: 100%; aspect-ratio: 778 / 1100; object-fit: contain; border: 1px solid #e1dad4; border-radius: 6px; box-shadow: 0 9px 20px #392e2412; }
.story-note { margin-block: 14px 23px; }

.story-reference { padding-block: clamp(40px,6.4vw,85px); }
.feature-reference { background: #f0e9e0; border-block: 1px solid #e1d6ca; }
.faq-reference { background: var(--paper); }
.reference-inner { display: grid; grid-template-columns: minmax(0,.7fr) minmax(0,1.3fr); gap: clamp(22px,5vw,72px); align-items: start; }
.story-reference h2 { font-size: clamp(27px,3.5vw,43px); line-height: 1.24; letter-spacing: -.048em; }
.feature-group { border-top: 1px solid #d9cec3; scroll-margin-top: 18px; }
.feature-group:last-child { border-bottom: 1px solid #d9cec3; }
.feature-group summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 54px;
  padding: 12px 2px;
  cursor: pointer;
  font-size: clamp(17px,2vw,20px);
  font-weight: 700;
  line-height: 1.42;
  list-style: none;
}
.feature-group summary::-webkit-details-marker { display: none; }
.feature-group summary::after { content: ""; flex: 0 0 8px; height: 8px; margin-inline-end: 8px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.feature-group[open] summary::after { transform: rotate(225deg); }
.feature-group summary:focus-visible, .faq-list summary:focus-visible { outline: 2px solid #755a48; outline-offset: 4px; }
.feature-index { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px clamp(16px,3vw,32px); margin: 0; min-width: 0; padding: 11px 0 30px; }
.feature-entry { min-width: 0; scroll-margin-top: 22px; }
.feature-entry dt { font-size: 16px; font-weight: 740; line-height: 1.4; }
.feature-entry dd { margin: 6px 0 0; color: #53463f; font-size: 15px; line-height: 1.67; }
.feature-previews { display: flex; flex-wrap: wrap; gap: var(--preview-gap); margin: 8px 0 23px; }
.feature-previews .story-app { flex: 0 1 min(var(--preview-width),calc((100% - var(--preview-gap)) / 2)); }
.faq-list details { border-top: 1px solid #d9cec3; padding: 13px 0; }
.faq-list details:last-child { border-bottom: 1px solid #d9cec3; }
.faq-list summary { cursor: pointer; font-weight: 680; padding: 5px 8px 5px 0; }
.faq-list p { margin: 13px 0 0; max-width: 48rem; font-size: 15px; line-height: 1.68; color: #53463f; }

.screen-dialog { width: min(94vw,478px); max-width: none; max-height: 95vh; max-height: 95svh; overscroll-behavior: contain; border: 1px solid #d9cec3; border-radius: 20px; padding: 14px; background: var(--snow); color: var(--ink); }
.screen-dialog::backdrop { background: #28201bd6; }
.screen-dialog form { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; font-size: 15px; }
.screen-dialog button { min-height: 44px; flex: none; cursor: pointer; padding: 0 9px; border: 1px solid #c7b3a5; color: var(--ink); background: #f5ede6; border-radius: 10px; }
.screen-dialog img { width: auto; max-width: 100%; max-height: calc(95vh - 85px); max-height: calc(95svh - 85px); object-fit: contain; margin: auto; border-radius: 9px; }

@media (max-width: 900px) {
  .story-page { --chapter-columns: 1fr; --chapter-gap: 24px; --preview-width: clamp(138px,26vw,224px); }
  .story-hero, .visit-feature { grid-template-columns: 1fr; }
  .story-hero { gap: 23px; }
  .story-hero h1 { font-size: clamp(28px,6.2vw,49px); }
  :lang(ko) .story-hero h1 { font-size: clamp(26px,6.1vw,49px); }
  .chapter-inner { padding-block: 38px; }
  .chapter-moments .chapter-inner { grid-template-areas: "album" "photos" "privacy"; grid-template-rows: auto; }
  .reference-inner { grid-template-columns: 1fr; gap: 23px; }
}
@media (max-width: 530px) {
  .story-page { --preview-width: min(216px,calc((100vw - 74px) / 2)); --preview-gap: 12px; --frame-padding: 5px; --frame-radius: 17px; --screen-radius: 12px; }
  .story-hero h1 { font-size: clamp(25px,7.35vw,39px); }
  :lang(ko) .story-hero h1 { font-size: clamp(22px,7.55vw,39px); }
  .chapter-copy h2 { font-size: clamp(27px,7.65vw,38px); }
  :lang(ko) .chapter-keepsake h2 { font-size: clamp(21px,6.75vw,33px); }
  .feature-index { grid-template-columns: 1fr; row-gap: 14px; }
}
@media (max-width: 380px) {
  .story-app figcaption, .visit-documents figcaption, .story-app figcaption span { font-size: 12px; }
}
