:root {
  --g-ink: #202e37;
  --g-ink2: #394853;
  --g-mint: #9ad4d5;
  --g-teal: #2a7b7f;
  --g-mint50: #d9ebeb;
  --g-mint25: #eef7f7;
  --g-paper: #f4f4f4;
  --g-line: #dce6e6;
  --g-muted: #5d6b74;
  --g-gold: #c9a45e;
  --g-display: "El Messiri", Georgia, serif;
  --g-sans: "Nunito", Arial, sans-serif;
}

.gift-page { background: var(--g-paper); color: #222; font-family: var(--g-sans); }
.gift-top { position: relative; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 10px; max-width: 1440px; margin: 0 auto; padding: 12px 16px; }
.gift-logo { flex-shrink: 0; display: inline-flex; align-items: center; min-height: 44px; }
.gift-logo img { display: block; width: 84px; height: auto; }
.gift-top-nav .gift-top-link:first-child { display: none; }
.gift-top-nav { display: flex; align-items: center; gap: 2px; }
.gift-top-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 10px; color: var(--g-ink2); font-size: 15px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.gift-top-link:hover { color: var(--g-teal); }
.gift-top-wide { display: none; }

.gift-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 24px; border: 0; border-radius: 30px; font: 500 16px var(--g-sans); text-decoration: none; white-space: nowrap; cursor: pointer; transition: background-color .2s, color .2s; }
.gift-btn-dark { background: var(--g-ink); color: #fff; }
.gift-btn-dark:hover { background: var(--g-mint); color: var(--g-ink); }
.gift-btn:disabled { opacity: .6; cursor: default; }

.gift { max-width: 1440px; margin: 0 auto; padding: 4px 16px 64px; }
.gift-grid { display: grid; gap: 20px; }

.gift-intro { padding: 8px 2px 0; }
.gift-kicker { margin: 0; font-style: italic; font-weight: 600; font-size: 13px; color: var(--g-teal); }
.gift-h1 { margin: 10px 0 0; font-family: var(--g-display); font-weight: 500; text-transform: uppercase; letter-spacing: .02em; font-size: clamp(30px, 8.6vw, 56px); line-height: 1; color: var(--g-ink); }
.gift-h2 { margin: 8px 0 0; font-family: var(--g-display); font-weight: 500; font-size: clamp(24px, 6.4vw, 32px); line-height: 1.08; color: var(--g-ink); }
.gift-text { margin: 12px 0 0; font-weight: 300; font-size: 15px; line-height: 1.55; color: #222; max-width: 480px; }
.gift-facts { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 18px 0 0; padding: 0; }
.gift-facts li { display: grid; gap: 2px; align-content: start; padding: 12px 10px; border-radius: 16px; background: #fff; box-shadow: inset 0 0 0 1px var(--g-line); }
.gift-facts b { font-family: var(--g-display); font-weight: 500; font-size: 17px; line-height: 1.15; color: var(--g-ink); }
.gift-facts span { font-size: 12px; line-height: 1.3; color: var(--g-muted); }

.gift-sticky { min-width: 0; }
.gift-stage { position: relative; height: clamp(300px, 92vw, 460px); border-radius: 24px; overflow: hidden; background: radial-gradient(75% 60% at 50% 42%, #33505a 0%, #213238 58%, #182429 100%); box-shadow: 0 30px 60px -40px rgba(23, 35, 40, .8); }
.gift-canvas { position: absolute; inset: 0; }
.gift-canvas canvas { display: block; }
.gift-static { display: none; position: absolute; left: 50%; top: 50%; width: min(84%, 620px); height: auto; transform: translate(-50%, -50%); border-radius: 14px; box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .6); }
.gift.is-static .gift-static { display: block; }
.gift.is-static .gift-replay { display: none; }
.gift-replay { position: absolute; right: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 1px solid rgba(255, 255, 255, .28); border-radius: 999px; background: rgba(255, 255, 255, .08); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: #fff; font: 600 14px var(--g-sans); white-space: nowrap; cursor: pointer; opacity: 0; pointer-events: none; transition: opacity .5s, background-color .2s; }
.gift.is-opened .gift-replay { opacity: 1; pointer-events: auto; }
.gift-replay:hover { background: rgba(255, 255, 255, .18); }

.gift-config { min-width: 0; padding: 22px 18px; border-radius: 24px; background: #fff; box-shadow: 0 1px 0 var(--g-line), 0 30px 60px -44px rgba(32, 46, 55, .45); }
.gift-preview { display: block; width: 100%; height: auto; margin-top: 16px; border-radius: 12px; box-shadow: 0 16px 36px -24px rgba(32, 46, 55, .6); }
.gift-set { margin: 18px 0 0; padding: 0; border: 0; min-width: 0; }
.gift-legend { padding: 0; margin-bottom: 8px; font-weight: 700; font-size: 14px; color: var(--g-ink); }
.gift-chips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.gift-chips-amount { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.gift-chip { min-height: 46px; padding: 0 8px; border: 1px solid var(--g-line); border-radius: 999px; background: #fff; color: var(--g-ink2); font: 600 15px var(--g-sans); white-space: nowrap; cursor: pointer; transition: border-color .2s, background-color .2s, color .2s; }
.gift-chip:hover { border-color: var(--g-mint); }
.gift-chip[aria-pressed="true"] { border-color: var(--g-ink); background: var(--g-ink); color: #fff; }
.gift-chips .gift-chip:last-child:nth-child(odd) { grid-column: 1 / -1; }
.gift-chips-amount .gift-chip:last-child:nth-child(odd) { grid-column: auto; }
.gift-field { display: grid; gap: 6px; margin-top: 14px; min-width: 0; }
.gift-field-label { font-size: 14px; font-weight: 700; color: var(--g-ink); }
.gift-opt { font-weight: 400; color: var(--g-muted); }
.gift-input { width: 100%; min-height: 48px; padding: 12px 14px; box-sizing: border-box; border: 1px solid var(--g-line); border-radius: 14px; background: #fff; font: 400 16px/1.4 var(--g-sans); color: var(--g-ink); outline: none; transition: border-color .2s, box-shadow .2s; }
.gift-input:focus { border-color: var(--g-teal); box-shadow: 0 0 0 3px rgba(42, 123, 127, .14); }
.gift-form { display: grid; margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--g-mint25); }
.gift-row { display: grid; gap: 0 12px; }
.gift-radio { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; align-items: start; min-height: 44px; padding: 12px; margin-top: 8px; border: 1px solid var(--g-line); border-radius: 14px; cursor: pointer; font-size: 15px; line-height: 1.4; color: var(--g-ink2); }
.gift-radio:has(input:checked) { border-color: var(--g-teal); background: var(--g-mint25); }
.gift-radio input, .gift-check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--g-teal); }
.gift-radio b { color: var(--g-ink); }
.gift-check { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; align-items: start; min-height: 44px; margin-top: 12px; font-size: 14px; line-height: 1.4; color: var(--g-ink2); cursor: pointer; }
.gift-check a { color: var(--g-teal); }
.gift-error { margin: 12px 0 0; padding: 10px 12px; border-radius: 12px; background: #fef3f2; color: #b42318; font-size: 14px; }
.gift-submit { justify-self: stretch; margin-top: 18px; }
.gift-note { margin: 12px 0 0; font-size: 13px; line-height: 1.5; color: var(--g-muted); }
.gift-done { margin-top: 18px; padding: 18px; border-radius: 18px; background: var(--g-mint25); }
.gift-done-title { margin: 0; font-family: var(--g-display); font-size: 24px; color: var(--g-ink); }

@media (max-width: 330px) {
  .gift-chips { grid-template-columns: 1fr; }
  .gift-chips .gift-chip:last-child:nth-child(odd) { grid-column: auto; }
  .gift-chips-amount { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gift-chips-amount .gift-chip:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

@media (min-width: 360px) {
  .gift-top-nav .gift-top-link:first-child { display: inline-flex; }
}

@media (min-width: 520px) {
  .gift-top-wide { display: inline-flex; }
  .gift-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gift-config { padding: 28px 26px; }
  .gift-chips { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .gift-chips .gift-chip:last-child:nth-child(odd) { grid-column: auto; }
  .gift-submit { justify-self: start; }
}

@media (min-width: 1024px) {
  .gift-top { padding: 16px 28px; }
  .gift-logo img { width: 96px; }
  .gift { padding: 8px 24px 96px; }
  .gift-grid { grid-template-columns: minmax(0, 1fr) 500px; grid-template-rows: auto 1fr; gap: 24px 32px; align-items: start; }
  .gift-sticky { grid-column: 1; grid-row: 1 / span 2; position: sticky; top: 16px; }
  .gift-stage { height: calc(100vh - 32px); min-height: 600px; border-radius: 28px; }
  .gift-intro { grid-column: 2; grid-row: 1; padding: 40px 0 0; }
  .gift-config { grid-column: 2; grid-row: 2; }
  .gift-preview { display: none; }
  .gift-replay { right: 20px; bottom: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .gift-replay { transition: none; }
}
