@font-face {
  font-family: "Gowun Batang";
  src: url("assets/fonts/GowunBatang-WeddingSubset.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #fbf8f0;
  --paper-deep: #efe6d5;
  --ink: #272721;
  --muted: #6c6b5f;
  --line: rgba(39, 39, 33, 0.16);
  --sage: #607163;
  --sage-dark: #3f5144;
  --gold: #b39055;
  --white: #fffdfa;
  --shadow: 0 20px 48px rgba(44, 41, 34, 0.12);
  --texture: url("assets/paper-texture.jpg");
  --font-body: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Segoe UI", sans-serif;
  --font-serif-ko: "Gowun Batang", "AppleMyungjo", "Nanum Myeongjo", "Noto Serif KR", "Batang", "Times New Roman", serif;
  --font-serif-en: Georgia, "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

html {
  background: #e7e0d1;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(96, 113, 99, 0.16), transparent 26%, transparent 74%, rgba(179, 144, 85, 0.14)),
    var(--texture),
    var(--paper);
  background-blend-mode: normal, multiply, normal;
  font-family: var(--font-body);
  line-height: 1.65;
  letter-spacing: 0;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.invitation {
  width: min(100%, 460px);
  min-height: 100vh;
  margin: 0 auto;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.48), rgba(245, 238, 224, 0.38)),
    var(--texture),
    var(--paper);
  background-blend-mode: normal, multiply, normal;
  box-shadow: 0 0 80px rgba(38, 35, 30, 0.18);
}

.hero {
  position: relative;
  min-height: 92vh;
  display: grid;
  align-items: start;
  isolation: isolate;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background: var(--texture);
  opacity: 0.16;
  mix-blend-mode: soft-light;
  pointer-events: none;
}

.hero__image,
.hero__scrim {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero__image {
  object-fit: cover;
  object-position: center;
  z-index: 0;
}

.hero__scrim {
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(251, 248, 240, 0.76) 0%, rgba(251, 248, 240, 0.42) 28%, rgba(251, 248, 240, 0.02) 54%),
    linear-gradient(0deg, rgba(38, 26, 18, 0.18), transparent 42%);
}

.hero__content {
  position: relative;
  z-index: 3;
  width: 100%;
  padding: max(42px, env(safe-area-inset-top)) 30px 40px;
  text-align: center;
}

.eyebrow,
.section-label {
  margin: 0 0 18px;
  color: var(--sage-dark);
  font-family: var(--font-serif-en);
  letter-spacing: 0;
  text-transform: uppercase;
}

.eyebrow {
  margin-bottom: 16px;
  font-size: 0.74rem;
}

.section-label {
  font-size: 0.9rem;
  font-weight: 700;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 22px;
  font-family: var(--font-serif-ko);
  font-size: clamp(3rem, 12.8vw, 4.55rem);
  font-weight: 400;
  line-height: 1.08;
  color: #2d2b25;
  white-space: nowrap;
}

.amp {
  display: inline;
  color: var(--gold);
  font-family: var(--font-serif-en);
  font-size: 0.68em;
  font-weight: 400;
  line-height: 1;
}

.hero__date {
  margin-bottom: 6px;
  color: #2c241d;
  font-weight: 700;
}

.hero__venue {
  color: #4a4035;
}

.section {
  position: relative;
  padding: 72px 28px;
  border-top: 1px solid var(--line);
}

.section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--texture);
  opacity: 0.16;
  mix-blend-mode: multiply;
  pointer-events: none;
}

.section > * {
  position: relative;
  z-index: 1;
}

.intro {
  text-align: center;
  background:
    linear-gradient(180deg, rgba(251, 248, 240, 0.92) 0%, rgba(255, 253, 248, 0.94) 100%),
    var(--texture),
    var(--paper);
  background-blend-mode: normal, multiply, normal;
}

.parents {
  margin-bottom: 34px;
  color: var(--muted);
  font-size: 0.94rem;
}

.message {
  font-family: var(--font-serif-ko);
  font-size: 1.14rem;
  line-height: 2;
}

.message p {
  margin-bottom: 8px;
}

.date-panel {
  text-align: center;
  background:
    linear-gradient(180deg, rgba(245, 239, 227, 0.92), rgba(240, 230, 211, 0.88)),
    var(--texture),
    #f5efe3;
  background-blend-mode: normal, multiply, normal;
}

h2 {
  margin-bottom: 8px;
  font-size: 1.44rem;
  font-weight: 700;
}

.muted {
  color: var(--muted);
}

.mini-calendar {
  position: relative;
  width: min(100%, 318px);
  margin: 30px auto 0;
  padding: 22px 18px 18px;
  border: 1px solid rgba(179, 144, 85, 0.36);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 253, 250, 0.86), rgba(248, 241, 229, 0.76)),
    var(--texture);
  background-blend-mode: normal, multiply;
  box-shadow:
    0 16px 34px rgba(44, 41, 34, 0.1),
    inset 0 1px rgba(255, 255, 255, 0.62);
}

.mini-calendar__rings {
  position: absolute;
  top: -9px;
  left: 50%;
  display: flex;
  gap: 28px;
  transform: translateX(-50%);
}

.mini-calendar__rings span {
  width: 12px;
  height: 22px;
  border: 2px solid rgba(179, 144, 85, 0.56);
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  background: var(--paper);
}

.mini-calendar__header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  color: var(--sage-dark);
}

.mini-calendar__header span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.mini-calendar__header span:first-child {
  text-align: left;
}

.mini-calendar__header span:last-child {
  text-align: right;
}

.mini-calendar__header strong {
  width: 54px;
  height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(179, 144, 85, 0.14);
  color: #735a2f;
  font-family: var(--font-serif-ko);
  font-size: 1.42rem;
  font-weight: 400;
}

.mini-calendar__weekdays,
.mini-calendar__grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.mini-calendar__weekdays {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.mini-calendar__day {
  aspect-ratio: 1;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #4f4a40;
  font-size: 0.88rem;
  line-height: 1;
}

.mini-calendar__day--sun {
  color: #a96b59;
}

.mini-calendar__day--sat {
  color: var(--sage-dark);
}

.mini-calendar__day--wedding {
  position: relative;
  background: var(--sage-dark);
  color: var(--white);
  font-weight: 800;
  box-shadow:
    0 8px 18px rgba(63, 81, 68, 0.28),
    0 0 0 5px rgba(96, 113, 99, 0.13);
}

.mini-calendar__day--wedding::after {
  content: "";
  position: absolute;
  right: 6px;
  bottom: 6px;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: var(--gold);
}

.countdown {
  width: 100%;
  margin: 28px auto 30px;
  padding: 22px;
  border: 1px solid rgba(96, 113, 99, 0.28);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 253, 250, 0.78), rgba(252, 247, 237, 0.68)),
    var(--texture);
  background-blend-mode: normal, multiply;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.55);
}

.countdown strong {
  display: block;
  color: var(--sage-dark);
  font-size: 2rem;
  line-height: 1.1;
}

.countdown span {
  color: var(--muted);
  font-size: 0.92rem;
}

.button-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 22px;
}

.button,
button.button,
.copy-account,
.icon-link {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--sage-dark);
  border-radius: 8px;
  background: var(--sage-dark);
  color: var(--white);
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.button--light,
.icon-link--light {
  background: transparent;
  color: var(--sage-dark);
}

.button--wide {
  width: 100%;
  margin-top: 18px;
}

.gallery {
  background:
    linear-gradient(180deg, rgba(255, 253, 250, 0.88), rgba(248, 243, 233, 0.82)),
    var(--texture),
    var(--white);
  background-blend-mode: normal, multiply, normal;
}

.gallery__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: 160px;
  gap: 10px;
}

.gallery__item {
  min-width: 0;
  min-height: 0;
  margin: 0;
  overflow: hidden;
  border-radius: 8px;
  background: var(--paper-deep);
  box-shadow: 0 14px 30px rgba(44, 41, 34, 0.08);
}

.gallery__item--tall {
  grid-row: span 2;
}

.gallery__item img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.gallery__item:nth-child(1) img {
  object-position: 48% 43%;
}

.gallery__item:nth-child(2) img {
  object-position: 58% 58%;
}

.gallery__item:nth-child(3) img {
  object-position: 52% 58%;
}

.gallery__item:nth-child(4) img {
  object-position: 50% 58%;
}

.gallery__item:nth-child(5) img {
  object-position: 50% 64%;
}

.venue {
  background:
    linear-gradient(180deg, rgba(248, 243, 233, 0.93), rgba(244, 236, 220, 0.9)),
    var(--texture),
    #f8f3e9;
  background-blend-mode: normal, multiply, normal;
}

address {
  margin-top: 18px;
  color: var(--ink);
  font-style: normal;
}

.info-list {
  margin: 28px 0 0;
}

.info-list div {
  padding: 18px 0;
  border-top: 1px solid var(--line);
}

.info-list dt {
  margin-bottom: 4px;
  color: var(--sage-dark);
  font-weight: 800;
}

.info-list dd {
  margin: 0;
  color: var(--muted);
}

.direction-maps {
  display: grid;
  gap: 18px;
  margin-top: 34px;
}

.direction-map {
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(179, 144, 85, 0.28);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.86), rgba(248, 242, 231, 0.78)),
    var(--texture),
    #fffdf8;
  background-blend-mode: normal, multiply, normal;
  box-shadow: 0 14px 34px rgba(44, 41, 34, 0.08);
}

.direction-map img {
  width: 100%;
  display: block;
  background: #fbf8f0;
}

.direction-map figcaption {
  display: grid;
  gap: 2px;
  padding: 14px 16px 16px;
  border-top: 1px solid rgba(179, 144, 85, 0.2);
}

.direction-map strong {
  color: var(--sage-dark);
  font-size: 0.98rem;
}

.direction-map span {
  color: var(--muted);
  font-size: 0.86rem;
}

.rsvp {
  text-align: center;
  background:
    linear-gradient(180deg, rgba(96, 113, 99, 0.96), rgba(66, 82, 70, 0.98)),
    var(--texture),
    var(--sage);
  background-blend-mode: normal, soft-light, normal;
  color: var(--white);
}

.rsvp .muted {
  color: rgba(255, 253, 250, 0.8);
}

.rsvp .button {
  border-color: var(--white);
  background: var(--white);
  color: var(--sage-dark);
}

.guestbook {
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.94), rgba(247, 239, 226, 0.88)),
    var(--texture),
    #fffdf8;
  background-blend-mode: normal, multiply, normal;
}

.guestbook-form {
  display: grid;
  gap: 12px;
  margin-top: 24px;
}

.field {
  display: grid;
  gap: 8px;
  color: var(--sage-dark);
  font-size: 0.9rem;
  font-weight: 800;
}

.field input,
.field textarea {
  width: 100%;
  border: 1px solid rgba(96, 113, 99, 0.28);
  border-radius: 8px;
  background: #fffefa;
  color: var(--ink);
  font: inherit;
  font-weight: 400;
}

.field input {
  min-height: 48px;
  padding: 0 14px;
}

.field textarea {
  min-height: 118px;
  padding: 13px 14px;
  line-height: 1.55;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: 2px solid rgba(96, 113, 99, 0.25);
  border-color: var(--sage-dark);
}

.guestbook-list {
  display: grid;
  gap: 12px;
  margin-top: 28px;
}

.guestbook-more {
  margin-top: 16px;
}

.guestbook-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.72), rgba(245, 239, 227, 0.72)),
    var(--texture);
  background-blend-mode: normal, multiply;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.55);
}

.guestbook-card__meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.guestbook-card strong {
  color: var(--sage-dark);
}

.guestbook-card time {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.82rem;
}

.guestbook-card p,
.guestbook-empty {
  margin: 0;
  color: var(--muted);
}

.guestbook-empty {
  padding: 16px 0;
  text-align: center;
}

.contact-list,
.account-list {
  display: grid;
  gap: 12px;
}

.contact-card,
.account-card {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 8px;
  align-items: center;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 253, 250, 0.78), rgba(248, 241, 229, 0.68)),
    var(--texture);
  background-blend-mode: normal, multiply;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.54);
}

.account-card {
  grid-template-columns: 1fr auto;
}

.contact-card p,
.account-card p {
  margin-bottom: 2px;
  color: var(--muted);
  font-size: 0.84rem;
}

.contact-card strong,
.account-card strong,
.account-card span {
  display: block;
}

.account-card strong,
.account-card span {
  user-select: text;
}

.icon-link,
.copy-account {
  min-width: 50px;
  min-height: 40px;
  padding: 0 12px;
  font-size: 0.9rem;
}

.copy-account {
  border-color: rgba(179, 144, 85, 0.45);
  background: #fff7e8;
  color: #735a2f;
}

.footer {
  padding: 48px 28px max(34px, env(safe-area-inset-bottom));
  text-align: center;
  background: #272721;
  color: var(--white);
}

.footer p {
  margin-bottom: 18px;
  font-family: var(--font-serif-ko);
  font-size: 1.4rem;
}

.footer .button {
  border-color: rgba(255, 253, 250, 0.65);
}

.footer .button--light {
  color: var(--white);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: max(22px, env(safe-area-inset-bottom));
  z-index: 10;
  width: max-content;
  max-width: calc(100vw - 36px);
  padding: 12px 16px;
  border-radius: 8px;
  background: rgba(39, 39, 33, 0.92);
  color: var(--white);
  font-size: 0.92rem;
  opacity: 0;
  transform: translate(-50%, 12px);
  transition: opacity 180ms ease, transform 180ms ease;
  pointer-events: none;
}

.toast--visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

@media (max-width: 360px) {
  .hero__content {
    padding-inline: 22px;
  }

  .section {
    padding-inline: 20px;
  }

  .contact-card,
  .account-card {
    grid-template-columns: 1fr;
  }

  .icon-link,
  .copy-account {
    width: 100%;
  }
}

@media (min-width: 760px) {
  body {
    padding: 28px 0;
  }

  .invitation {
    border-radius: 8px;
  }
}
