:root {
  --bg1: #fff6e7;
  --bg2: #ffe9d2;
  --text: #3f2a1f;
  --shadow: rgba(63, 42, 31, 0.18);
  --frame-size: min(24vw, 250px);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Sora", sans-serif;
  background: radial-gradient(circle at top, var(--bg1) 0%, var(--bg2) 70%);
  color: var(--text);
}

.page-content {
  width: min(1200px, 100%);
  margin-inline: auto;
  padding: clamp(16px, 3vw, 32px);
  display: grid;
  gap: clamp(18px, 3vw, 34px);
}

.layout {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: clamp(12px, 3vw, 40px);
}

.column {
  display: grid;
  gap: clamp(8px, 1.5vw, 16px);
  justify-items: center;
}

.column img {
  width: var(--frame-size);
  height: auto;
  display: block;
  filter: drop-shadow(0 10px 20px var(--shadow));
}

.center-text {
  font-family: "Caveat", cursive;
  font-weight: 700;
  text-align: center;
  font-size: clamp(2.4rem, 8vw, 7rem);
  line-height: 1;
  letter-spacing: 0.04em;
  margin: 0;
  text-shadow: 0 4px 10px rgba(63, 42, 31, 0.14);
  white-space: normal;
}

.story-block {
  text-align: center;
  padding: clamp(12px, 2vw, 20px) clamp(8px, 2vw, 16px);
}

.story-title {
  margin: 0;
  font-family: "Caveat", cursive;
  font-weight: 700;
  font-size: clamp(3.6rem, 10vw, 7rem);
  line-height: 0.95;
}

.story-text {
  margin: 14px auto 0;
  max-width: 33ch;
  font-family: "Sora", sans-serif;
  font-size: clamp(1.3rem, 3.3vw, 2.2rem);
  line-height: 1.4;
}

.wedding-title-block {
  text-align: center;
  padding: clamp(8px, 1.8vw, 18px) clamp(8px, 2vw, 16px);
}

.wedding-title {
  margin: 0;
  font-family: "Caveat", cursive;
  font-weight: 700;
  font-size: clamp(2.4rem, 7vw, 5.2rem);
  line-height: 0.98;
  letter-spacing: 0.01em;
}

.rings-grid {
  width: min(520px, 100%);
  margin: 18px auto 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
}

.ring-item {
  height: 100%;
  display: grid;
  grid-template-rows: auto auto auto auto;
  justify-items: center;
  align-content: start;
  gap: 6px;
  padding: 18px 14px 16px;
  border: 1px solid rgba(175, 109, 77, 0.14);
  border-radius: 24px;
  background: rgba(255, 252, 247, 0.72);
  box-shadow: 0 12px 28px rgba(63, 42, 31, 0.08);
}

.ring-media {
  width: clamp(84px, 18vw, 120px);
  aspect-ratio: 1 / 1;
  display: grid;
  place-items: center;
}

.ring-media img {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
}

.ring-item:nth-child(4) .ring-media {
  width: clamp(76px, 16vw, 96px);
}

.wedding-proof-title {
  margin: 0;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  letter-spacing: 0.08em;
  text-align: center;
}

.wedding-proof-text {
  margin: 0;
  font-size: clamp(0.95rem, 1.7vw, 1.15rem);
  text-align: center;
  overflow-wrap: anywhere;
}

.wedding-proof-text a,
.wedding-proof-text a:visited,
.wedding-proof-text a:hover,
.wedding-proof-text a:focus-visible {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.countdown-block {
  text-align: center;
  padding: clamp(8px, 2vw, 20px) clamp(8px, 2vw, 16px);
}

.countdown-label {
  margin: 0 0 12px;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: clamp(1.15rem, 2.5vw, 1.7rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  width: min(720px, 100%);
  margin: 0 auto;
}

.countdown-unit {
  padding: 16px 12px;
  border-radius: 20px;
  border: 1px solid rgba(175, 109, 77, 0.14);
  background: rgba(255, 252, 247, 0.8);
  box-shadow: 0 12px 28px rgba(63, 42, 31, 0.08);
}

.countdown-unit strong {
  display: block;
  font-family: "Syne", sans-serif;
  font-size: clamp(2rem, 5vw, 3rem);
  color: var(--text);
  line-height: 1;
}

.countdown-unit span {
  display: block;
  margin-top: 6px;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(63, 42, 31, 0.72);
}

.invite-block {
  text-align: center;
  padding: clamp(14px, 2.2vw, 24px) clamp(10px, 2.2vw, 18px);
}

.invite-text {
  margin: 0;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: clamp(1.9rem, 4.8vw, 3.7rem);
  line-height: 1.15;
  letter-spacing: 0.01em;
}

.confirm-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 18px;
  padding: 14px 24px;
  border-radius: 999px;
  background: linear-gradient(135deg, #af6d4d, #d48a68);
  color: #fffaf7;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: clamp(0.95rem, 2.3vw, 1.1rem);
  letter-spacing: 0.04em;
  text-decoration: none;
  box-shadow: 0 14px 30px rgba(141, 79, 53, 0.24);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.confirm-button:hover,
.confirm-button:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(141, 79, 53, 0.3);
}

.invite-contact {
  margin: 36px 0 0;
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  line-height: 1.4;
}

.final-photo-block {
  text-align: center;
  padding-top: clamp(8px, 1.8vw, 16px);
}

.final-photo {
  width: min(390px, 100%);
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(63, 42, 31, 0.22);
}

@media (max-width: 1024px) {
  .page-content {
    padding: 12px;
    gap: 18px;
  }

  .layout {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 14px;
  }

  .column {
    grid-auto-flow: row;
    gap: 8px;
  }

  .column img {
    width: clamp(72px, 18vw, 96px);
  }

  .center-text {
    order: 2;
    white-space: normal;
    font-size: clamp(2rem, 12vw, 4rem);
  }

  .layout > .column:first-of-type {
    order: 1;
  }

  .layout > .column:last-of-type {
    order: 3;
  }

  .story-block,
  .wedding-title-block,
  .countdown-block,
  .invite-block,
  .final-photo-block {
    padding-left: 4px;
    padding-right: 4px;
  }

  .story-title {
    font-size: clamp(2.8rem, 14vw, 4.6rem);
  }

  .story-text {
    max-width: 100%;
    font-size: clamp(1.05rem, 4.2vw, 1.35rem);
  }

  .wedding-title {
    font-size: clamp(2.1rem, 9vw, 3.6rem);
  }

  .rings-grid {
    width: min(100%, 620px);
    gap: 12px;
  }

  .ring-item {
    padding: 14px 10px 12px;
    grid-template-rows: auto auto auto auto;
  }

  .countdown {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: min(520px, 100%);
  }

  .countdown-unit {
    padding: 14px 10px;
  }

  .countdown-unit strong {
    font-size: clamp(1.7rem, 8vw, 2.4rem);
  }

  .invite-text {
    font-size: clamp(1.5rem, 6vw, 2.3rem);
  }

  .confirm-button {
    width: 100%;
    max-width: 320px;
  }

  .final-photo {
    width: min(100%, 340px);
  }
}

@media (max-width: 560px) {
  .rings-grid {
    grid-template-columns: 1fr;
  }

  .ring-item {
    grid-template-rows: auto auto auto auto;
  }

  .ring-media {
    width: clamp(72px, 24vw, 84px);
  }

  .countdown {
    grid-template-columns: 1fr;
  }

  .countdown-label {
    font-size: 1rem;
  }

  .wedding-proof-title {
    font-size: 1rem;
  }

  .wedding-proof-text {
    font-size: 0.9rem;
  }
}
