@font-face { font-family: 'FILM Allura'; src: url('fonts/film-allura.ttf') format('truetype'); font-style: normal; font-weight: 400; font-display: swap; }
@font-face { font-family: 'FILM Noto Serif KR'; src: url('fonts/film-noto-serif-kr.ttf') format('truetype'); font-style: normal; font-weight: 400; font-display: swap; }
* { margin: 0; padding: 0; box-sizing: border-box; }
:root { color-scheme: dark; --opening-progress: 0; }
body { background: #172a38; color: #fffdf5; font-family: 'Gowun Batang', serif; overflow: hidden; width: 100%; height: 100vh; height: 100dvh; }
button { font: inherit; color: inherit; cursor: pointer; }
button:disabled { cursor: default; }
button:focus-visible { outline: 2px solid white; outline-offset: 7px; }
[hidden] { display: none !important; }
.seamless-world { --reveal: 0; --wind: 0; position: fixed; inset: 0; overflow: hidden; isolation: isolate; background: linear-gradient(#397db2, #b6dcec 60%, #d6a86b); transform-origin: 54% 35%; transition: transform 1.65s cubic-bezier(.5,0,.16,1), filter 1.4s; }
.scenery { position: absolute; inset: -4%; background: url('images/autumn-school.png') center center / cover no-repeat; transform: translate3d(0,12%,0) scale(1.42); will-change: transform; }
.scene-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,26,41,.25), transparent 32%, rgba(15,34,43,.12) 60%, rgba(18,27,29,.43)); }
.seamless-world::after { content: ''; position: absolute; inset: 0; background: #101f2a; opacity: calc(1 - var(--reveal)); pointer-events: none; }
.sunlight-overlay { position: absolute; inset: -15%; background: radial-gradient(ellipse at 88% 12%, #fff6dba1, #ffdeb21c 29%, transparent 55%); mix-blend-mode: screen; animation: sunlight 11s ease-in-out infinite alternate; }
@keyframes sunlight { from { opacity: .4; transform: rotate(-3deg); } to { opacity: .85; transform: rotate(3deg) scale(1.04); } }
.wind-light { position: absolute; inset: -30%; background: linear-gradient(115deg, transparent 24%, #fff6e434 43%, #fff8ea5c 49%, transparent 65%); opacity: calc(var(--wind) * .65); transform: translateX(calc((1 - var(--wind)) * -35%)); transition: opacity 1.2s, transform 2.2s cubic-bezier(.2,.6,.2,1); mix-blend-mode: screen; }
#atmosphere { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 3; pointer-events: none; transition: opacity 1s; }
.film-grain { position: fixed; inset: 0; z-index: 5; pointer-events: none; opacity: .035; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath fill='%23fff' filter='url(%23n)' d='M0 0h180v180H0z'/%3E%3C/svg%3E"); }
.cinema-bars { position: fixed; inset: 0; z-index: 7; pointer-events: none; }
.cinema-bars::before,.cinema-bars::after { content: ''; position: absolute; left: 0; right: 0; height: 8%; background: #11212b; transition: transform 1.7s cubic-bezier(.22,1,.36,1); }
.cinema-bars::before { top: 0; }
.cinema-bars::after { bottom: 0; }
body:not([data-stage="OPENING"]):not([data-stage="LOADING"]) .cinema-bars::before { transform: translateY(-100%); }
body:not([data-stage="OPENING"]):not([data-stage="LOADING"]) .cinema-bars::after { transform: translateY(100%); }
.hud-frame { position: fixed; inset: 26px; z-index: 30; pointer-events: none; }
.corner { position: absolute; width: 20px; height: 20px; border-style: solid; border-color: #ffffff80; }
.tl { top: 0; left: 0; border-width: 1px 0 0 1px; }.tr { top: 0; right: 0; border-width: 1px 1px 0 0; }.bl { bottom: 0; left: 0; border-width: 0 0 1px 1px; }.br { bottom: 0; right: 0; border-width: 0 1px 1px 0; }
.hud-top,.hud-bottom { display: flex; justify-content: space-between; align-items: center; padding: 12px 22px; gap: 20px; font-family: 'Cormorant Garamond', Georgia, serif; font-size: 12px; letter-spacing: 2.3px; text-shadow: 0 1px 10px #183342; }
.hud-bottom { position: absolute; bottom: 0; left: 0; right: 0; }
.hud-status { display: flex; align-items: center; gap: 18px; }
.hud-time { font-variant-numeric: tabular-nums; opacity: .65; letter-spacing: 1px; }
.rec-dot { width: 5px; height: 5px; border-radius: 50%; background: #ecac75; box-shadow: 0 0 8px #ffc89877; }
.playback-controls { display: flex; gap: 18px; align-items: center; }
.hud-btn { pointer-events: auto; background: none; border: 0; border-bottom: 1px solid #ffffff4d; padding: 9px 0; font-family: 'Gowun Batang', serif; font-size: 13px; letter-spacing: .8px; text-shadow: 0 2px 8px #172c39; transition: border-color .2s; }
.hud-btn:hover { border-color: white; }.pause-btn { opacity: .65; }
.opening-caption { position: fixed; z-index: 8; bottom: 19%; left: 0; width: 100%; padding: 0 30px; text-align: center; font-size: clamp(18px,2.1vw,29px); letter-spacing: .2em; text-shadow: 0 2px 20px #233c3d, 0 1px 4px #233c3d; opacity: 0; transform: translateY(12px); transition: opacity .8s, transform 1.3s; pointer-events: none; }
.opening-caption.visible { opacity: 1; transform: translateY(0); }
.sky-title-container { position: fixed; z-index: 10; inset: 0; display: flex; flex-direction: column; justify-content: center; align-items: center; padding-bottom: 4vh; text-align: center; opacity: 0; visibility: hidden; pointer-events: none; transform: translateY(15px); transition: opacity .7s, transform 1.7s, visibility .7s; text-shadow: 0 2px 20px #24496688; }
body[data-stage="SKY"] .sky-title-container { opacity: 1; visibility: visible; transform: translateY(0); }
.title-prelude { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 13px; letter-spacing: .42em; padding-left: .42em; margin-bottom: 4px; }
.pen-logo-group { font-weight: normal; display: flex; flex-direction: column; align-items: center; }
.film-pen-svg { width: clamp(290px,34vw,530px); height: auto; overflow: visible; }
.svg-film-stroke { font-family: 'FILM Allura', 'Segoe Script', cursive; font-weight: 400; font-synthesis: none; font-size: 176px; fill: transparent; stroke: #fffdf5; stroke-width: .45; stroke-dasharray: 1100; stroke-dashoffset: 1100; filter: drop-shadow(0 2px 6px #21496b33); }
body[data-stage="SKY"] .svg-film-stroke { animation: writeFilm 2.3s .15s ease forwards; }
@keyframes writeFilm { 0% { stroke-dashoffset: 1100; fill: transparent; stroke-width: .45; } 65% { stroke-dashoffset: 0; fill: transparent; stroke-width: .45; } 100% { stroke-dashoffset: 0; fill: #fffdf5; stroke-width: 0; } }
.pen-kor-stroke { font-family: 'FILM Noto Serif KR', 'Batang', serif; font-weight: 400; font-synthesis: none; font-size: 30px; letter-spacing: .3em; padding-left: .3em; margin-top: 4px; opacity: 0; }
.title-description { font-size: 15px; letter-spacing: .12em; margin-top: 15px; opacity: 0; }
body[data-stage="SKY"] .pen-kor-stroke { animation: appear 1.2s .75s both; }
body[data-stage="SKY"] .title-description { animation: appear 1.4s 1.1s both; }
.record-btn-wrap { margin-top: clamp(25px,5vh,65px); opacity: 0; }
body[data-stage="SKY"] .record-btn-wrap { animation: appear 1.1s 1.8s both; }
@keyframes appear { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: translateY(0); } }
.record-memory-btn { border: 0; background: none; padding: 10px 28px 0; }
body[data-stage="SKY"] .record-memory-btn { pointer-events: auto; }
.pen-btn-stroke { display: block; font-family: 'Caveat', cursive; font-size: 34px; letter-spacing: 1px; text-shadow: 0 2px 16px #21415f; transition: transform .3s; }
.record-memory-btn:hover .pen-btn-stroke { transform: translateY(-4px); }
.pen-line-svg { display: block; width: 200px; height: 22px; margin: -2px auto 0; }
.pen-line-svg path { stroke-dasharray: 260; stroke-dashoffset: 260; }
body[data-stage="SKY"] .pen-line-svg path { animation: underline 1.2s 2.2s forwards; }
@keyframes underline { to { stroke-dashoffset: 0; } }
.entry-note { display: block; font-size: 12px; letter-spacing: .14em; margin-top: 9px; opacity: .75; }
.opening-progress { position: fixed; z-index: 31; bottom: 0; left: 0; width: 100%; height: 2px; background: #f5c28a; transform: scaleX(var(--opening-progress)); transform-origin: left; opacity: .7; transition: opacity 1s; }
body[data-stage="SKY"] .opening-progress,body[data-stage="ARCHIVE"] .opening-progress { opacity: 0; }
.seamless-world.archive-mode { transform: scale(1.35); filter: blur(5px) brightness(.62) saturate(.75); }
.transition-light { position: fixed; inset: 0; z-index: 20; pointer-events: none; background: radial-gradient(ellipse at 60% 35%, #fffef5 15%, #ffedd3 70%); opacity: 0; }
body[data-stage="ENTERING"] .transition-light { animation: lightPass 1.15s ease-in-out both; }
@keyframes lightPass { 0% { opacity: 0; } 47% { opacity: .88; } 100% { opacity: 0; } }
body[data-stage="ENTERING"] #atmosphere,body[data-stage="ARCHIVE"] #atmosphere { opacity: .2; }
.archive-screen { position: fixed; inset: 0; z-index: 25; display: flex; align-items: center; justify-content: center; padding: 95px 60px; opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .75s, visibility .75s; overflow-y: auto; }
.archive-screen.active { opacity: 1; visibility: visible; pointer-events: auto; }
.archive-glass-box { width: 100%; max-width: 940px; }
.archive-header { margin-bottom: 25px; text-shadow: 0 2px 14px #19344966; }
.archive-idx { font-family: 'Cormorant Garamond', serif; font-size: 13px; letter-spacing: 4px; opacity: .8; }
.archive-header h2 { font-family: 'Cormorant Garamond', serif; font-size: clamp(26px,3vw,40px); font-style: italic; letter-spacing: 3px; margin-top: 6px; font-weight: 500; }
.archive-cards { display: flex; flex-direction: column; gap: 10px; }
.glass-card { display: flex; align-items: center; min-height: 76px; padding: 14px 28px; background: #ffffff12; border: 1px solid #ffffff38; backdrop-filter: blur(12px); transition: background .3s, transform .3s; }
.glass-card:hover { background: #ffffff25; transform: translateX(6px); }
.c-num { font-family: 'Cormorant Garamond',serif; font-size: 25px; font-style: italic; width: 65px; opacity: .65; flex-shrink: 0; }
.c-info h3 { font-family: 'Cormorant Garamond',serif; font-size: 24px; font-weight: 500; letter-spacing: 2px; }
.c-info p { font-size: 14px; opacity: .8; margin-top: 4px; }
.c-go { margin-left: auto; opacity: .5; padding-left: 12px; }
.is-paused *, .tab-hidden * { animation-play-state: paused !important; }
.noscript-message { position: fixed; inset: 40% 10%; z-index: 50; text-align: center; line-height: 2; }
@media (max-width: 640px) {
  .hud-frame { inset: 16px; }.hud-top,.hud-bottom { padding: 9px 10px; }.hud-status { gap: 9px; }.hud-meta,.hud-time { display: none; }
  .hud-brand { font-size: 10px; letter-spacing: 1px; }.hud-label { font-size: 11px; letter-spacing: 1.4px; }.hud-btn { font-size: 12px; }.playback-controls { gap: 13px; }
  .scenery { background-position: 48% center; }.title-description { font-size: 13px; }.title-prelude { font-size: 11px; }.sky-title-container { padding-bottom: 8vh; }
  .archive-screen { padding: 90px 27px; align-items: flex-start; }.archive-glass-box { margin: auto 0; }.glass-card { padding: 13px 16px; min-height: 78px; }.c-num { width: 40px; }.c-info h3 { font-size: 21px; }.c-info p { font-size: 12px; line-height: 1.6; }.archive-header h2 { letter-spacing: 1px; }
}
@media (max-height: 620px) { .film-pen-svg { width: 280px; }.title-prelude { margin-top: 20px; }.pen-kor-stroke { font-size: 25px; }.title-description { margin-top: 8px; }.record-btn-wrap { margin-top: 15px; }.entry-note { display: none; }.archive-screen { align-items: flex-start; } }
@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
  .sunlight-overlay { animation: none; }.seamless-world.archive-mode { transform: none; }.transition-light { display: none; }
}
