/* sonamooo — shared styles (home and /explore) */
:root {
  --ink-day: #11301f;
  --ink: var(--ink-day);
  --font: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Noto Sans KR', system-ui, sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, monospace;
  --pill: rgba(255, 255, 255, 0.55);
  --pill-line: rgba(17, 48, 31, 0.1);
  --veil: rgba(226, 241, 231, 0.78);
  --rule: rgba(17, 48, 31, 0.2);
  --panel: rgba(238, 247, 241, 0.94);
}
html.dark { --ink: #fff; --pill: rgba(6, 16, 11, 0.5); --pill-line: rgba(255, 255, 255, 0.1); --veil: rgba(6, 20, 13, 0.62); --rule: rgba(255, 255, 255, 0.2); --panel: rgba(8, 22, 15, 0.92); }
* { box-sizing: border-box; }
/* a still of the first screen, shown until the live sky draws its first frame */
html { background: #d4e8da url(/assets/poster-wide.webp) center / cover no-repeat fixed; }
@media (max-aspect-ratio: 3/4) { html { background-image: url(/assets/poster-tall.webp); } }
html.no-sky { background: linear-gradient(#e7f1ea, #9cc0a8); }
body { margin: 0; color: var(--ink); font-family: var(--font); -webkit-font-smoothing: antialiased; word-break: keep-all; transition: color 0.6s ease; }
a { color: inherit; }

#sky, #people { position: fixed; left: 0; top: 0; pointer-events: none; }
#sky { z-index: 0; opacity: 0; transition: opacity 0.35s ease; }
#sky.ready { opacity: 1; }
#people { z-index: 1; }
main, footer { position: relative; z-index: 2; }

/* Menu bar, behaving like Aria's: a wide transparent bar at the very top that folds
   into a floating pill as soon as you scroll, with a thin page-progress line in it. */
.nav { --enter: cubic-bezier(0.16, 1, 0.3, 1); position: fixed; inset: 0 0 auto; z-index: 10; display: flex; justify-content: center; pointer-events: none; }
.nav-in {
  pointer-events: auto; position: relative; display: flex; align-items: center; gap: 8px; width: 100%;
  max-width: 100vw; height: 72px; margin-top: 0; padding: 0 3.4vw; border-radius: 0;
  transition: max-width 0.7s var(--enter), height 0.7s var(--enter), margin 0.7s var(--enter), padding 0.7s var(--enter), border-radius 0.7s var(--enter), box-shadow 0.7s var(--enter);
}
.nav-in::before {
  content: ''; position: absolute; inset: 0; z-index: -1; border-radius: inherit; opacity: 0; transition: opacity 0.45s ease;
  background: var(--pill); backdrop-filter: blur(16px) saturate(1.25); -webkit-backdrop-filter: blur(16px) saturate(1.25); box-shadow: inset 0 0 0 1px var(--pill-line);
}
.nav.compact .nav-in { max-width: min(640px, calc(100vw - 24px)); height: 56px; margin-top: 12px; padding: 0 8px 0 22px; border-radius: 999px;
  box-shadow: 0 22px 48px -22px rgba(10, 40, 24, 0.45), 0 6px 16px -8px rgba(10, 40, 24, 0.22); }
html.dark .nav.compact .nav-in { box-shadow: 0 22px 48px -22px rgba(0, 0, 0, 0.6), 0 6px 16px -8px rgba(0, 0, 0, 0.4); }
.nav.compact .nav-in::before { opacity: 1; }
.nav-wm { font-weight: 700; font-size: 26px; letter-spacing: -0.04em; text-decoration: none; transition: font-size 0.7s var(--enter); }
.nav.compact .nav-wm { font-size: 20px; }
.links { display: flex; align-items: center; gap: 2px; margin: 0 auto; }
.links > a { font: inherit; font-size: 14px; color: inherit; background: none; border: 0; cursor: pointer; white-space: nowrap; text-decoration: none; opacity: 0.72; padding: 8px 12px; border-radius: 999px; transition: opacity 0.2s ease, background-color 0.2s ease; }
.links > a:hover, .links > a[aria-current='page'] { opacity: 1; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.cta { font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; height: 40px; display: inline-flex; align-items: center; padding: 0 18px; border-radius: 999px; background: var(--ink); color: #fff; transition: transform 0.18s var(--enter), opacity 0.2s ease; }
.cta:hover { transform: translateY(-1px); }
html.dark .cta { color: #0b1d13; }
/* page progress, a hairline along the bottom of the pill */
.nav-prog { position: absolute; left: 22px; right: 22px; bottom: 0; height: 2px; overflow: hidden; opacity: 0; transition: opacity 0.45s ease; pointer-events: none; }
.nav-prog::after { content: ''; position: absolute; inset: 0; transform-origin: 0 0; transform: scaleX(var(--np, 0)); background: linear-gradient(90deg, transparent, var(--ink)); opacity: 0.6; }
.nav.compact .nav-prog { opacity: 1; }
.contact { position: relative; }
.panel.contact-panel { left: auto; right: 0; transform: none; min-width: 300px; }
.contact-mail { margin: 4px 10px 14px; font: 500 15px/1.4 var(--mono); word-break: break-all; }
.contact-actions { display: flex; gap: 8px; padding: 0 6px 6px; }
.pill-solid, .pill-ghost { flex: 1; height: 40px; display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; font: inherit; font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer; border: 0; }
.pill-solid { background: var(--ink); color: #fff; }
html.dark .pill-solid { color: #0b1d13; }
.pill-ghost { background: color-mix(in srgb, var(--ink) 10%, transparent); color: inherit; }
.cta { border: 0; font-family: inherit; cursor: pointer; }
.panel {
  position: absolute; top: calc(100% + 16px); left: 50%; transform: translateX(-50%); min-width: 340px; padding: 10px; border-radius: 20px;
  background: var(--panel); backdrop-filter: blur(18px) saturate(1.2); -webkit-backdrop-filter: blur(18px) saturate(1.2);
  box-shadow: inset 0 0 0 1px var(--pill-line), 0 18px 40px rgba(6, 20, 13, 0.16);
}
.panel[hidden] { display: none; }
.panel-title { margin: 6px 10px 8px; font: 600 11px/1 var(--mono); letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.55; }
.services { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.services a { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px; border-radius: 14px; text-decoration: none; }
.services a:hover { background: color-mix(in srgb, var(--ink) 8%, transparent); }
.services b { font-size: 15px; font-weight: 600; }
.services span { grid-column: 1; font-size: 13px; opacity: 0.68; line-height: 1.5; }
.services i { grid-row: 1 / 3; grid-column: 2; align-self: center; font: 500 12px/1 var(--mono); opacity: 0.6; }
/* phones: a round menu button whose two lines turn into an X, and a sheet that unrolls */
.nav-menu { display: none; position: relative; width: 40px; height: 40px; border: 0; border-radius: 50%; background: color-mix(in srgb, var(--ink) 10%, transparent); color: inherit; cursor: pointer; margin-left: 6px; }
.nav-menu i { position: absolute; left: 12px; right: 12px; height: 1.5px; background: currentColor; border-radius: 1px; transition: transform 0.42s var(--enter); }
.nav-menu i:nth-of-type(1) { top: 16px; }
.nav-menu i:nth-of-type(2) { top: 22px; }
.nav.open .nav-menu i:nth-of-type(1) { transform: translateY(3px) rotate(45deg); }
.nav.open .nav-menu i:nth-of-type(2) { transform: translateY(-3px) rotate(-45deg); }
.nav-sheet {
  position: fixed; inset: 0; z-index: -1; pointer-events: auto; padding: 96px 22px 32px; overflow: auto;
  background: var(--panel); backdrop-filter: blur(22px) saturate(1.2); -webkit-backdrop-filter: blur(22px) saturate(1.2);
  clip-path: inset(0 0 100% 0); transition: clip-path 0.65s var(--enter); visibility: hidden;
}
.nav.open .nav-sheet { clip-path: inset(0); visibility: visible; }
.nav-sheet ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.nav-sheet li { opacity: 0; transform: translateY(14px); transition: opacity 0.3s ease, transform 0.3s ease; }
.nav.open .nav-sheet li { opacity: 1; transform: none; transition: opacity 0.52s var(--enter) calc(150ms + var(--i, 0) * 45ms), transform 0.62s var(--enter) calc(150ms + var(--i, 0) * 45ms); }
.nav-sheet .big a { display: block; font-size: 30px; font-weight: 700; letter-spacing: -0.04em; text-decoration: none; padding: 10px 4px; }
.nav-sheet .panel-title { margin: 26px 4px 8px; }
.nav.open .nav-in::before, .nav.open .nav-prog { opacity: 0; }
.nav.open.compact .nav-in { box-shadow: none; }
.nav.open .contact { opacity: 0; pointer-events: none; }

.hero { height: 100vh; height: 100svh; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding: 17vh 20px 0; text-align: center; }
.hero h1 { margin: 0; font-size: clamp(72px, 14vw, 200px); line-height: 0.9; letter-spacing: -0.065em; font-weight: 700; }
.hero p { margin: 20px 0 0; font-size: clamp(18px, 1.9vw, 24px); line-height: 1.35; letter-spacing: -0.02em; font-weight: 500; }
.hero p span { opacity: 0.62; }

/* each chapter holds its words on screen for a while (sticky), then scrolls on */
.chapter { height: 165vh; height: 165svh; position: relative; padding-top: 22vh; padding-top: 22svh; }
.copy { position: sticky; top: 22vh; top: 22svh; margin-left: 8vw; max-width: 560px; }
/* a soft haze behind the words so they stay readable over any place */
.copy::before, .hero::before, .records .inner::before {
  content: ''; position: absolute; z-index: -1; inset: -14vh -12vw -12vh -14vw; pointer-events: none;
  background: radial-gradient(closest-side, var(--veil), transparent); transition: background 0.6s ease;
}
.hero, .records .inner { position: relative; }
.hero::before { inset: 4vh 12vw 30vh; }
.copy .date { margin: 0 0 18px; font: 500 13px/1 var(--mono); display: inline-flex; align-items: center; gap: 8px; opacity: 0.8; }
.copy h2 { margin: 0; font-size: clamp(40px, 5vw, 76px); line-height: 1.05; letter-spacing: -0.05em; font-weight: 700; }
.copy h2 span { opacity: 0.5; }
.copy .body { margin: 18px 0 0; font-size: clamp(15px, 1.3vw, 18px); line-height: 1.6; opacity: 0.75; }
.place { font: 600 12px/1 var(--font); }
.place::before { content: '·'; margin-right: 8px; opacity: 0.6; }
.tag { font: 600 11px/1 var(--font); padding: 5px 8px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--pill-line); background: var(--pill); }
.tag.now { background: var(--ink); color: #fff; box-shadow: none; }
html.dark .tag.now { color: #0b1d13; }

.clock {
  position: fixed; z-index: 9; left: 20px; bottom: 20px; display: flex; align-items: center; gap: 8px; margin: 0;
  padding: 8px 13px 8px 11px; border-radius: 999px; background: var(--pill); color: var(--ink);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); box-shadow: inset 0 0 0 1px var(--pill-line);
  font: 500 12px/1 var(--mono); transition: background 0.6s ease, color 0.6s ease;
}
.clock i { width: 10px; height: 10px; border-radius: 50%; background: currentColor; }
html.dark .clock i { background: transparent; box-shadow: inset -3px 1px 0 0 currentColor; }
html.at-end .clock { opacity: 0; pointer-events: none; }
.clock { transition: opacity 0.4s ease, background 0.6s ease, color 0.6s ease; }
.clock span + span::before { content: '·'; margin-right: 8px; opacity: 0.5; }

.records { padding: 24vh 8vw 8vh; }
.records .inner { max-width: 1080px; margin: 0 auto; }
.records h2 { margin: 0; font-size: clamp(48px, 6.4vw, 96px); line-height: 1; letter-spacing: -0.055em; font-weight: 700; }
.records .lead { margin: 18px 0 0; max-width: 440px; opacity: 0.72; line-height: 1.6; font-size: 17px; }
.record-list { margin-top: 64px; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 40px 32px; }
.year h3 { margin: 0 0 14px; padding-bottom: 12px; border-bottom: 1px solid var(--pill-line); font-size: 18px; font-weight: 600; }
.year ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.year li { font-size: 15px; display: flex; gap: 12px; opacity: 0.85; }
.year time { font: 500 13px/1.6 var(--mono); opacity: 0.6; }
.records .more { margin-top: 32px; font-size: 13px; opacity: 0.55; }

/* the closing screen: sunset, the finished name at the bottom, a small copyright */
/* the closing screen ends with the rule near the middle and the records still in view above */
footer { height: 52vh; height: 52svh; padding: 0 5.4vw; }
.foot { border-top: 1px solid var(--rule); padding-top: 26px; font-size: 15px; }
.copy-right { margin: 0; display: flex; align-items: center; gap: 6px; }
.copy-right > span { opacity: 0.75; margin-right: 6px; }
.foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 24px; }
.foot-links { margin: 0; display: flex; gap: 18px; }
.foot-links a { text-decoration: none; opacity: 0.75; }
.foot-links a:hover { opacity: 1; }
.foot-links { flex-wrap: wrap; align-items: center; }
.letters { position: fixed; z-index: 3; inset: 0; pointer-events: none; overflow: hidden; }
.letters canvas { position: absolute; left: 0; top: 0; image-rendering: pixelated; opacity: 0; transform-origin: 50% 50%; will-change: transform; }

@media (max-width: 760px) {
  .nav-in { height: 64px; padding: 0 12px 0 18px; }
  .nav.compact .nav-in { max-width: calc(100vw - 16px); height: 56px; margin-top: 8px; padding: 0 6px 0 18px; }
  .nav-wm { font-size: 22px; }
  .nav.compact .nav-wm { font-size: 20px; }
  .links { display: none; }
  .contact { margin-left: auto; }
  .cta { height: 36px; padding: 0 14px; font-size: 13px; }
  .panel.contact-panel { position: fixed; top: 76px; left: 12px; right: 12px; min-width: 0; }
  .nav-menu { display: block; }
  .nav-prog { display: none; }
  .hero { padding-top: 16vh; }
  .hero h1 { font-size: 21vw; }
  .hero p { font-size: 17px; }
  .chapter { padding-top: 12svh; }
  .copy { top: 12vh; top: 12svh; margin: 0 68px 0 22px; max-width: none; }
  .copy::before { inset: -6vh -10vw -4vh -10vw; }
  .copy h2 { font-size: 34px; }
  .copy .body { margin-top: 10px; font-size: 14px; }
  .records { padding: 18vh 22px 10vh; }
  footer { padding: 0 22px; }
  .foot { font-size: 13px; }
  .record-list { margin-top: 40px; }
  .clock { left: 12px; bottom: 12px; }
}

/* footer icons: GitHub and copy-the-mail-address */
.foot-icon { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 0; border: 0; border-radius: 9px; background: none; color: inherit; cursor: pointer; opacity: 0.85; }
.foot-icon:hover { opacity: 1; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.foot-copy { --mail-cut: #dfeee4; }
html.dark .foot-copy { --mail-cut: #0b1d13; }
.copied { position: absolute; bottom: calc(100% + 10px); left: 50%; transform: translate(-50%, 4px); display: grid; justify-items: center; gap: 5px; padding: 9px 12px; border-radius: 12px; font: 600 12px/1 var(--mono); white-space: nowrap;
  background: var(--ink); color: #fff; opacity: 0; pointer-events: none; transition: opacity 0.2s ease, transform 0.2s ease; }
html.dark .copied { color: #0b1d13; }
.copied.show { opacity: 1; transform: translate(-50%, 0); }
.copied b { font-weight: 600; font-size: 13px; }
.copied span { font: 600 11px/1 var(--font); opacity: 0.7; }
/* after Contact brings you down: a soft ring around the mail icon */
.foot-copy.pulse::after { content: ''; position: absolute; inset: -4px; border-radius: 12px; box-shadow: 0 0 0 2px currentColor; opacity: 0; animation: mailpulse 1.6s ease-out 2; }
@keyframes mailpulse { 0% { opacity: 0.9; transform: scale(0.85); } 100% { opacity: 0; transform: scale(1.35); } }
