/* 디코 사진관 디자인 샘플 — 필름·폴라로이드형 */
:root {
  --paper: #F4F1EC; --white: #FFFDF9; --film: #141312; --film-2: #23211F;
  --safe: #D64933; --mustard: #E3B23C;
  --text: #2C2927; --sub: #77706A; --line: #DCD5CB;
  --header-h: 72px;
  --serif: 'DM Serif Display', 'Times New Roman', serif;
  --mono: 'Courier Prime', 'Courier New', monospace;
  --sans: 'Pretendard Variable', Pretendard, -apple-system, 'Noto Sans KR', sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }
body { margin: 0; font-family: var(--sans); color: var(--text); background: var(--paper); line-height: 1.75; word-break: keep-all; -webkit-font-smoothing: antialiased; overflow-x: clip; }
svg, img { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p, dl, dd, figure { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 14px; background: var(--film); color: #fff; }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--safe); outline-offset: 3px; }
.container { width: min(1200px, 100% - 48px); margin-inline: auto; }
.mono { font-family: var(--mono); font-size: 13px; letter-spacing: .12em; color: var(--safe); }
.ph { display: inline-block; padding: 0 6px; border: 1px dashed var(--safe); color: #B03A27; font-size: .9em; }

.sample-banner { background: var(--film); color: #DAD3CB; font-size: 12.5px; }
.sample-banner__inner { display: flex; gap: 10px; align-items: center; padding: 8px 0; }
.sample-banner__tag { flex: none; padding: 0 10px; background: var(--safe); color: #fff; }
.sample-banner a { color: var(--mustard); }

.site-header { position: sticky; top: 0; z-index: 50; background: rgba(244, 241, 236, .92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--serif); font-size: 24px; }
.logo small { font-family: var(--mono); font-size: 11px; letter-spacing: .2em; color: var(--sub); }
.logo__dot { width: 14px; height: 14px; border-radius: 50%; background: var(--safe); box-shadow: 0 0 0 4px rgba(214, 73, 51, .2); }
.site-nav ul { display: flex; gap: 28px; }
.site-nav a { text-decoration: none; font-weight: 600; font-size: 15px; }
.site-nav a:hover, .site-nav a.is-active { color: var(--safe); }
.nav-toggle { display: none; }

.btn { display: inline-flex; align-items: center; justify-content: center; padding: 14px 28px; font-weight: 700; font-size: 15px; text-decoration: none; border: 1.5px solid var(--film); transition: background .3s, color .3s, transform .3s; }
.btn:hover { transform: translateY(-2px); }
.btn--dark { background: var(--film); color: var(--white); }
.btn--dark:hover { background: var(--safe); border-color: var(--safe); }
.btn--line { color: var(--film); }
.btn--line:hover { background: var(--film); color: #fff; }

/* 셔터 등장: 위아래 검은 막이 열리듯
 * 완전히 가리면(inset 50%) IntersectionObserver 가 보이지 않는 요소로 판단해 열리지 않으므로 가는 틈을 남긴다 */
.has-motion .up { opacity: 0; clip-path: inset(45% 0 45% 0); transition: opacity .2s, clip-path .9s cubic-bezier(.7, 0, .2, 1); transition-delay: var(--d, 0s); }
.has-motion .up.is-in { opacity: 1; clip-path: inset(0 0 0 0); }

/* 히어로 */
.hero { padding: 80px 0 100px; overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 40px; align-items: center; }
.hero__title { margin-top: 18px; font-family: var(--serif); font-weight: 400; font-size: clamp(44px, 5.6vw, 80px); line-height: 1.12; letter-spacing: -.01em; }
.hero__title em { color: var(--safe); }
.hero__lead { margin-top: 22px; max-width: 28em; font-size: 17px; color: var(--sub); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero__tip { margin-top: 26px; color: var(--sub); }
.pile { position: relative; height: 560px; }
.polaroid { position: absolute; left: var(--x); top: var(--y); width: 44%; padding: 12px 12px 46px; background: var(--white); box-shadow: 0 18px 40px -18px rgba(20, 19, 18, .45); transform: rotate(var(--r)); cursor: grab; touch-action: none; user-select: none; transition: box-shadow .3s; }
.polaroid:active { cursor: grabbing; box-shadow: 0 30px 60px -20px rgba(20, 19, 18, .55); }
.polaroid svg { width: 100%; aspect-ratio: 1; pointer-events: none; }
.polaroid figcaption { position: absolute; left: 0; right: 0; bottom: 12px; text-align: center; font-family: var(--mono); font-size: 13px; color: var(--sub); }
.has-motion .polaroid { animation: drop .9s cubic-bezier(.2, 1.3, .4, 1) both; animation-delay: calc(var(--i) * .18s + .2s); }
@keyframes drop { from { opacity: 0; transform: translate(40px, -120px) rotate(calc(var(--r) * -3)) scale(1.2); } to { opacity: 1; transform: rotate(var(--r)); } }

/* 섹션 공통 */
.section { padding: 120px 0; position: relative; }
.section--dark { background: var(--film); color: #DAD3CB; }
.section--paper { background: var(--white); }
.head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px 30px; margin-bottom: 48px; }
.head .mono { flex-basis: 100%; }
.head h2, .visit__title { font-family: var(--serif); font-weight: 400; font-size: clamp(36px, 4.4vw, 58px); line-height: 1.1; }
.section--dark h2 { color: #fff; }
.note { margin-top: 26px; text-align: center; font-size: 13.5px; color: var(--sub); }
.note--left { text-align: left; }

/* 필름 띠 */
.film { background: var(--film); padding: 34px 0; position: relative; overflow: hidden; }
.film::before, .film::after { content: ""; position: absolute; left: 0; right: 0; height: 14px; background: repeating-linear-gradient(90deg, transparent 0 14px, var(--paper) 14px 28px); opacity: .9; }
.film::before { top: 10px; } .film::after { bottom: 10px; }
.film__track { display: flex; gap: 18px; width: max-content; padding: 0 9px; }
.has-motion .film__track { animation: roll 36s linear infinite; }
.film:hover .film__track { animation-play-state: paused; }
@keyframes roll { to { transform: translateX(-50%); } }
.frame { position: relative; width: 300px; background: var(--film-2); padding: 12px; display: grid; grid-template-columns: 110px 1fr; gap: 14px; align-items: center; color: #EDE6DD; }
.frame svg { width: 110px; aspect-ratio: 1; }
.frame b { display: block; font-size: 17px; }
.frame span:not(.frame__no) { font-size: 13.5px; color: #B5ADA4; }
.frame__no { position: absolute; right: 10px; top: 6px; font-size: 11px; color: var(--mustard); }

/* 갤러리 */
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filter { padding: 8px 18px; border: 1px solid #5A5550; background: none; color: #DAD3CB; font: inherit; font-weight: 600; cursor: pointer; transition: background .3s, color .3s, border-color .3s; }
.filter.is-on { background: var(--safe); border-color: var(--safe); color: #fff; }
.masonry { columns: 4 220px; column-gap: 16px; }
.masonry li { break-inside: avoid; margin-bottom: 16px; transition: opacity .4s, transform .4s; }
.masonry li.is-out { display: none; }
.shot { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; position: relative; overflow: hidden; }
.shot svg { width: 100%; height: auto; transition: transform .8s cubic-bezier(.2, .8, .2, 1), filter .5s; }
.shot:hover svg { transform: scale(1.05); filter: saturate(1.2); }
.shot::after { content: "+"; position: absolute; right: 12px; bottom: 10px; width: 34px; height: 34px; border-radius: 50%; background: rgba(20, 19, 18, .7); color: #fff; display: grid; place-items: center; font-size: 22px; opacity: 0; transition: opacity .3s; }
.shot:hover::after, .shot:focus-visible::after { opacity: 1; }

/* 라이트박스: 조리개처럼 열림 */
.lightbox { width: min(760px, 92vw); max-height: 92vh; padding: 0; border: 0; background: transparent; overflow: visible; }
.lightbox::backdrop { background: rgba(10, 9, 9, .9); }
.lightbox__iris { clip-path: circle(75% at 50% 50%); background: var(--film); }
.has-motion .lightbox[open] .lightbox__iris { animation: iris .7s cubic-bezier(.7, 0, .2, 1); }
@keyframes iris { from { clip-path: circle(0 at 50% 50%); } to { clip-path: circle(75% at 50% 50%); } }
.lightbox__img svg { width: 100%; height: auto; max-height: 80vh; }
.lightbox__cap { margin-top: 12px; text-align: center; color: #DAD3CB; }
.lightbox__btn, .lightbox__close { position: absolute; border: 0; background: rgba(255, 253, 249, .9); color: var(--film); cursor: pointer; font-size: 30px; width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; line-height: 1; }
.lightbox__prev { left: -66px; top: 45%; } .lightbox__next { right: -66px; top: 45%; }
.lightbox__close { right: -10px; top: -60px; font-size: 26px; }

/* 촬영 과정: 밀착 인화지 */
.contact-sheet { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; padding: 26px; background: var(--film); }
.contact-sheet li { position: relative; padding: 30px 18px 26px; background: #EDE6DD; min-height: 200px; }
.cs__no { position: absolute; left: 10px; top: 6px; color: var(--film); font-weight: 700; }
.cs__frame b { display: block; font-family: var(--serif); font-weight: 400; font-size: 26px; margin-bottom: 8px; }
.cs__frame p { font-size: 14.5px; color: #4E4842; }
.grease { position: absolute; inset: -6px; width: calc(100% + 12px); height: calc(100% + 12px); pointer-events: none; overflow: visible; }
.grease path { fill: none; stroke: var(--safe); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 600; stroke-dashoffset: 0; }
.has-motion .contact-sheet:not(.is-in) .grease path { stroke-dashoffset: 600; }
.has-motion .contact-sheet .grease path { transition: stroke-dashoffset 1.4s ease-in-out 1s; }
.is-pick { background: #fff !important; }

/* 가격: 봉투 */
.envelopes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; align-items: start; }
.env { position: relative; padding: 70px 30px 34px; background: #EFE7DA; border: 1px solid var(--line); }
.env::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 50px; background: #E3D8C6; clip-path: polygon(0 0, 100% 0, 50% 100%); }
.env h3 { font-family: var(--serif); font-weight: 400; font-size: 28px; margin-top: 6px; }
.env__price { margin: 18px 0; font-size: 18px; }
.env ul li { padding: 8px 0; border-top: 1px dashed #C9BEAD; font-size: 15px; }
.env--main { background: var(--film); color: #EDE6DD; border-color: var(--film); transform: translateY(-16px); }
.env--main::before { background: #2D2A27; }
.env--main .ph { border-color: var(--mustard); color: var(--mustard); }
.env--main ul li { border-color: #4A4540; }

/* 방문 */
.visit__grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 70px; align-items: start; }
.visit__title { margin-top: 12px; }
.visit__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.faq { margin-top: 40px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; display: flex; justify-content: space-between; padding: 18px 0; font-weight: 700; cursor: pointer; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--mono); color: var(--safe); transition: transform .3s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq p { padding-bottom: 18px; color: var(--sub); }
.ticket { position: relative; padding: 0 30px 26px; background: var(--white); border: 1px solid var(--line); box-shadow: 0 20px 40px -26px rgba(20, 19, 18, .4); -webkit-mask: radial-gradient(circle 14px at 0 74px, transparent 98%, #000) , radial-gradient(circle 14px at 100% 74px, transparent 98%, #000); -webkit-mask-composite: source-in; mask-composite: intersect; }
.ticket__top { display: flex; justify-content: space-between; align-items: center; height: 74px; border-bottom: 2px dashed var(--line); margin-bottom: 8px; }
.ticket__top b { font-family: var(--serif); font-weight: 400; font-size: 26px; }
.ticket > div:not(.ticket__top) { display: grid; grid-template-columns: 60px 1fr; padding: 12px 0; border-bottom: 1px solid var(--line); }
.ticket dt { font-weight: 700; }

.site-footer { padding: 30px 0; background: var(--film); color: #9A938B; font-size: 13px; }
.site-footer b { color: #fff; }
.site-footer .ph { border-color: rgba(227, 178, 60, .5); color: var(--mustard); }
.credit a { display: inline-flex; align-items: center; gap: 6px; color: #fff; vertical-align: middle; }
.credit img { filter: brightness(0) invert(1); }

@media (max-width: 1023.98px) {
  .nav-toggle { display: block; padding: 8px 14px; border: 1.5px solid var(--film); background: none; font-family: var(--mono); font-weight: 700; letter-spacing: .14em; cursor: pointer; }
  .nav-toggle[aria-expanded="true"] { background: var(--film); color: #fff; }
  .site-nav { position: fixed; inset: var(--nav-top, var(--header-h)) 0 0; z-index: 45; background: var(--film); display: grid; place-items: center; clip-path: inset(0 0 100% 0); transition: clip-path .6s cubic-bezier(.7, 0, .2, 1); }
  .site-nav.is-open { clip-path: inset(0); }
  .site-nav ul { flex-direction: column; align-items: center; gap: 18px; }
  .site-nav a { color: #fff; font-family: var(--serif); font-weight: 400; font-size: 34px; }
  .hero__grid, .visit__grid { grid-template-columns: 1fr; }
  .pile { height: 520px; max-width: 560px; width: 100%; margin: 0 auto; }
  .contact-sheet { grid-template-columns: repeat(3, 1fr); }
  .lightbox__prev { left: 6px; } .lightbox__next { right: 6px; }
  .lightbox__close { right: 6px; top: -56px; }
}
@media (max-width: 767.98px) {
  :root { --header-h: 64px; }
  .container { width: calc(100% - 40px); }
  .sample-banner__inner { align-items: flex-start; font-size: 12px; }
  .logo small { display: none; }
  .hero { padding: 44px 0 70px; }
  .hero__actions .btn { flex: 1 1 100%; }
  .pile { height: 400px; }
  .polaroid { width: 52%; padding: 8px 8px 34px; }
  .polaroid figcaption { font-size: 11px; bottom: 8px; }
  .section { padding: 84px 0; }
  .frame { width: 250px; grid-template-columns: 86px 1fr; }
  .frame svg { width: 86px; }
  .masonry { columns: 2; column-gap: 10px; }
  .masonry li { margin-bottom: 10px; }
  .contact-sheet { grid-template-columns: 1fr 1fr; padding: 12px; }
  .contact-sheet li { min-height: 0; }
  .envelopes { grid-template-columns: 1fr; }
  .env--main { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
