:root {
  --paper: #fbf7f0;
  --paper-deep: #f0e5da;
  --ink: #30271f;
  --muted: #766b5f;
  --sage: #7b886f;
  --sage-dark: #424c39;
  --blush: #c8998d;
  --rose: #8d5f58;
  --brass: #ad8350;
  --white: #fffaf4;
  --line: rgba(48, 39, 31, 0.16);
  --shadow: 0 20px 60px rgba(48, 39, 31, 0.14);
  --serif: "Iowan Old Style", "Noto Serif KR", "AppleMyungjo", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: Inter, "Noto Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", ui-sans-serif, system-ui, -apple-system,
    BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  touch-action: pan-x pan-y;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

#details,
#story,
#photos,
#questions {
  scroll-margin-top: 4.8rem;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  letter-spacing: 0;
  touch-action: pan-x pan-y;
}

body.nav-open {
  overflow: hidden;
}

body.lightbox-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.05;
}

.skip-link {
  position: fixed;
  left: 1rem;
  top: 1rem;
  z-index: 100;
  transform: translateY(-150%);
  background: var(--ink);
  color: var(--white);
  padding: 0.7rem 1rem;
  border-radius: 6px;
}

.skip-link:focus {
  transform: translateY(0);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  --language-active-bg: var(--white);
  --language-active-fg: var(--ink);
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 1.4rem;
  color: var(--white);
  transition: background 180ms ease, color 180ms ease, box-shadow 180ms ease, padding 180ms ease;
}

.site-header.is-scrolled,
.site-header.nav-active {
  --language-active-bg: var(--ink);
  --language-active-fg: var(--white);
  background: rgba(251, 247, 240, 0.94);
  color: var(--ink);
  box-shadow: 0 10px 30px rgba(48, 39, 31, 0.08);
  backdrop-filter: blur(14px);
}

.brand {
  font-family: var(--serif);
  font-size: 1.25rem;
  text-decoration: none;
}

.site-nav {
  display: none;
}

.site-nav a {
  text-decoration: none;
  font-size: 0.9rem;
}

.language-switcher {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: max-content;
  min-width: 8.5rem;
  padding: 0.18rem;
  border: 1px solid currentColor;
  border-radius: 999px;
}

.language-option {
  min-width: 3.8rem;
  min-height: 2rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 0.78rem;
  cursor: pointer;
}

.language-option.is-active {
  background: var(--language-active-bg);
  color: var(--language-active-fg);
}

.nav-toggle {
  width: 2.65rem;
  height: 2.65rem;
  display: inline-grid;
  place-content: center;
  gap: 0.28rem;
  border: 1px solid currentColor;
  border-radius: 999px;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.nav-toggle span {
  width: 1rem;
  height: 1px;
  background: currentColor;
}

.hero {
  position: relative;
  min-height: 86svh;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--white);
  isolation: isolate;
}

.hero picture,
.hero img,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-overlay {
  z-index: 1;
  background:
    linear-gradient(rgba(31, 25, 20, 0.28), rgba(31, 25, 20, 0.36)),
    radial-gradient(circle at 50% 20%, rgba(255, 250, 244, 0.2), transparent 35%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(92vw, 860px);
  padding: 8.5rem 1rem 4rem;
  text-align: center;
}

.kicker,
.section-kicker {
  font-size: 0.82rem;
  text-transform: uppercase;
  color: inherit;
}

.section-kicker {
  color: var(--rose);
  margin-bottom: 0.9rem;
}

.hero h1 {
  margin-top: 1rem;
  font-size: 4rem;
}

.hero-date {
  margin-top: 1.2rem;
  font-family: var(--serif);
  font-size: 1.35rem;
}

.hero-place {
  margin-top: 0.4rem;
  font-size: 0.95rem;
}

.intro {
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.intro-inner,
.section-shell,
.questions-inner {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}

.intro-inner {
  display: grid;
  gap: 1.35rem;
  place-items: center;
  padding: 5rem 0;
  text-align: center;
}

.intro h2,
.section-heading h2,
.questions h2 {
  font-size: 2.6rem;
}

.intro p:not(.section-kicker) {
  max-width: 640px;
  color: var(--muted);
  white-space: pre-line;
}

.countdown {
  display: inline-flex;
  align-items: baseline;
  gap: 0.6rem;
  margin-top: 0.6rem;
  padding: 0.85rem 1.15rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--sage-dark);
  background: rgba(123, 136, 111, 0.08);
}

.countdown [data-countdown-days] {
  font-family: var(--serif);
  font-size: 1.8rem;
  line-height: 1;
}

.details {
  background: var(--paper);
  padding: 5.5rem 0;
}

.section-heading {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 2rem;
  text-align: center;
}

.detail-grid {
  display: grid;
  gap: 1rem;
}

.detail-card {
  min-height: 18rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.65rem;
  padding: 1.35rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 12px 35px rgba(48, 39, 31, 0.07);
}

.detail-time {
  color: var(--brass);
  font-family: var(--serif);
  font-size: 1.55rem;
}

.detail-card h3 {
  font-size: 2rem;
}

.detail-card p:not(.detail-time) {
  color: var(--muted);
}

.story {
  display: grid;
  background: var(--sage-dark);
  color: var(--white);
}

.story-image {
  min-height: 24rem;
}

.story-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-copy {
  display: grid;
  align-content: center;
  gap: 1.2rem;
  padding: 4rem 1rem;
}

.story-copy .section-kicker {
  color: #ead1ca;
}

.story-copy h2 {
  font-size: 3rem;
}

.story-copy p:not(.section-kicker) {
  max-width: 560px;
  color: rgba(255, 250, 244, 0.82);
}

.photos {
  padding: 5.5rem 0;
  background: var(--white);
}

.photo-grid {
  display: grid;
  gap: 1rem;
}

.photo-tile {
  margin: 0;
  min-height: 22rem;
  overflow: hidden;
  border-radius: 8px;
  background: var(--paper-deep);
}

.photo-button {
  width: 100%;
  height: 100%;
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.photo-button:focus-visible {
  outline: 3px solid var(--brass);
  outline-offset: 3px;
}

.photo-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lightbox[hidden] {
  display: none;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(20, 18, 15, 0.82);
  cursor: pointer;
}

.lightbox-panel {
  position: relative;
  z-index: 1;
  width: min(100%, 980px);
  max-height: calc(100vh - 2rem);
  max-height: calc(100dvh - 2rem);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3.4rem 3.8rem 0;
}

.lightbox-figure {
  width: 100%;
  max-height: calc(100vh - 6.5rem);
  max-height: calc(100dvh - 6.5rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  margin: 0;
}

.lightbox-figure img {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 72vh;
  max-height: min(72dvh, 680px);
  object-fit: contain;
  border-radius: 8px;
  background: rgba(255, 250, 244, 0.08);
}

.lightbox-figure figcaption {
  flex: 0 0 auto;
  min-height: 1.5rem;
  color: var(--white);
  text-align: center;
  font-size: 0.9rem;
}

.lightbox-close,
.lightbox-control {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 250, 244, 0.72);
  border-radius: 999px;
  background: rgba(20, 18, 15, 0.42);
  color: var(--white);
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.lightbox-close {
  top: 0.1rem;
  right: 0.1rem;
  width: 2.8rem;
  height: 2.8rem;
  font-size: 1.6rem;
  line-height: 1;
}

.lightbox-control {
  top: 50%;
  width: 3.1rem;
  height: 3.1rem;
  transform: translateY(-50%);
  font-size: 2.6rem;
  line-height: 1;
}

.lightbox-control-prev {
  left: 0.1rem;
}

.lightbox-control-next {
  right: 0.1rem;
}

.lightbox-close:focus-visible,
.lightbox-control:focus-visible {
  outline: 3px solid var(--white);
  outline-offset: 3px;
}

.questions {
  padding: 5rem 0;
  background: var(--paper-deep);
}

.questions-inner {
  display: grid;
  gap: 2rem;
  text-align: center;
}

.question-list {
  display: grid;
  gap: 1rem;
  text-align: left;
}

.question-list article {
  padding: 1.3rem 0;
  border-top: 1px solid var(--line);
}

.question-list article:last-child {
  border-bottom: 1px solid var(--line);
}

.question-list h3 {
  font-size: 1.55rem;
  margin-bottom: 0.35rem;
}

.question-list p {
  color: var(--muted);
}

.site-footer {
  display: grid;
  gap: 0.2rem;
  justify-items: center;
  padding: 2.5rem 1rem;
  background: var(--ink);
  color: var(--white);
  text-align: center;
}

.site-footer p:first-child {
  font-family: var(--serif);
  font-size: 1.65rem;
}

.site-footer p:last-child {
  color: rgba(255, 250, 244, 0.72);
  font-size: 0.92rem;
}

@media (max-width: 767px) {
  .site-nav {
    position: fixed;
    inset: 4.9rem 1rem auto 1rem;
    display: grid;
    gap: 0.25rem;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--white);
    color: var(--ink);
    box-shadow: var(--shadow);
    transform: translateY(-0.8rem);
    opacity: 0;
    pointer-events: none;
    transition: opacity 160ms ease, transform 160ms ease;
  }

  .site-nav.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .site-nav a {
    padding: 0.85rem;
    border-radius: 6px;
  }

  .language-switcher {
    margin: 0.55rem 0.75rem 0;
  }

  .site-nav a:focus,
  .site-nav a:hover {
    background: rgba(123, 136, 111, 0.1);
  }

  .hero img {
    object-position: right center;
  }

  .hero-content {
    width: min(100%, 24rem);
    padding: 7rem 1.1rem 3.4rem;
  }

  .hero h1 {
    font-size: 3.45rem;
  }

  .hero-date {
    max-width: 18rem;
    margin-left: auto;
    margin-right: auto;
    font-size: 1.08rem;
    line-height: 1.38;
  }

  .hero-place {
    max-width: 20rem;
    margin-left: auto;
    margin-right: auto;
    font-size: 0.84rem;
    line-height: 1.4;
  }

  .lightbox {
    padding: 0.5rem;
  }

  .lightbox-panel {
    width: 100%;
    max-height: calc(100vh - 1rem);
    max-height: calc(100dvh - 1rem);
    padding: 3.15rem 0.4rem 3.4rem;
  }

  .lightbox-figure img {
    max-height: calc(100vh - 9rem);
    max-height: calc(100dvh - 9rem);
  }

  .lightbox-close {
    top: 0.35rem;
    right: 0.35rem;
  }

  .lightbox-control {
    top: auto;
    bottom: 0.25rem;
    transform: none;
  }

  .lightbox-control-prev {
    left: 0.35rem;
  }

  .lightbox-control-next {
    right: 0.35rem;
  }
}

@media (min-width: 768px) {
  .site-header {
    padding: 1.35rem 2.25rem;
  }

  .site-header.is-scrolled {
    padding: 0.95rem 2.25rem;
  }

  .nav-toggle {
    display: none;
  }

  .site-nav {
    display: flex;
    align-items: center;
    gap: 1.45rem;
  }

  .language-switcher {
    margin-left: 0.25rem;
  }

  .hero {
    min-height: 88vh;
  }

  .hero h1 {
    font-size: 6.5rem;
  }

  .hero-date {
    font-size: 1.7rem;
  }

  .intro-inner {
    padding: 6.5rem 0;
  }

  .intro h2,
  .section-heading h2,
  .questions h2 {
    font-size: 3.6rem;
  }

  .detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .story {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  }

  .story-copy {
    padding: 5.5rem 8vw;
  }

  .story-copy h2 {
    font-size: 4.2rem;
  }

  .photo-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: 20rem;
  }

  .photo-tile {
    min-height: 0;
  }

  .photo-tile-wide {
    grid-column: span 2;
  }

  .question-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2rem;
  }

  .question-list article,
  .question-list article:last-child {
    border-bottom: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
