/* Positive Strides Wishlist Tree - shared styles */
:root {
  --navy: #0f2f45;
  --blue: #1a4d6d;
  --blue-2: #2d5f7f;
  --gold: #d9a441;
  --gold-2: #f3cf7a;
  --cream: #fbf6ea;
  --ink: #1d2a33;
  --radius: 14px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }
html { background: var(--navy); overflow-x: hidden; }

body {
  font-family: "Alegreya Sans", "Trebuchet MS", sans-serif;
  color: var(--cream);
  background: radial-gradient(ellipse at 50% 0%, var(--blue-2) 0%, var(--blue) 45%, var(--navy) 100%);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: "Cormorant Garamond", Georgia, serif; font-weight: 700; margin: 0; }

a { color: var(--gold-2); }

/* ---------- tree ---------- */
.tree-wrap {
  position: relative;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  aspect-ratio: 1000 / 1330;
}
.tree-img, .tree-lights {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  display: block;
  pointer-events: none;
  user-select: none;
}
.tree-img { filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .35)); }

.tree-star {
  position: absolute;
  left: 50%; top: 4.2%;
  width: 13%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  animation: star-glow 3.2s ease-in-out infinite;
  z-index: 3;
}
@keyframes star-glow {
  0%, 100% { filter: drop-shadow(0 0 6px rgba(255, 214, 120, .7)); }
  50%      { filter: drop-shadow(0 0 16px rgba(255, 226, 150, 1)); }
}

.ornament {
  position: absolute;
  width: 11%;
  aspect-ratio: 172 / 230;
  padding: 0; margin: 0;
  border: 0; background: none;
  cursor: pointer;
  transform: translate(-50%, -63%);
  z-index: 2;
  -webkit-tap-highlight-color: transparent;
}
.ornament img {
  width: 100%; height: 100%;
  display: block;
  transform-origin: 50% 2%;
  filter: drop-shadow(0 4px 5px rgba(0, 0, 0, .45));
  animation: sway 5s ease-in-out infinite;
  animation-delay: var(--delay, 0s);
  transition: transform .25s ease, filter .25s ease;
}
@keyframes sway {
  0%, 100% { transform: rotate(-2.5deg); }
  50%      { transform: rotate(2.5deg); }
}
.ornament:hover img, .ornament:focus-visible img {
  animation: none;
  transform: scale(1.35);
  filter: drop-shadow(0 0 10px rgba(255, 220, 140, .9)) drop-shadow(0 6px 8px rgba(0, 0, 0, .5));
}
.ornament:hover, .ornament:focus-visible { z-index: 5; }
.ornament:focus-visible { outline: none; }
.ornament:focus-visible img { outline: 3px solid var(--gold-2); outline-offset: 2px; border-radius: 50%; }

/* hover name tag (mouse users) */
.ornament .tag {
  position: absolute;
  left: 50%; bottom: -8px;
  transform: translate(-50%, 100%);
  white-space: nowrap;
  background: var(--cream); color: var(--ink);
  font-size: 14px; line-height: 1.2;
  padding: 4px 9px; border-radius: 999px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, .35);
  opacity: 0; pointer-events: none;
  transition: opacity .2s ease;
  display: none;
}
.ornament .tag b { color: #8a5a00; }
@media (hover: hover) {
  .ornament .tag { display: block; }
  .ornament:hover .tag, .ornament:focus-visible .tag { opacity: 1; }
}

/* ---------- pop-up ---------- */
.gift-dialog {
  border: 0; padding: 0;
  width: min(640px, calc(100vw - 24px));
  max-height: calc(100vh - 24px);
  border-radius: 18px;
  background: var(--cream); color: var(--ink);
  box-shadow: 0 25px 60px rgba(0, 0, 0, .5);
  overflow: auto;
}
.gift-dialog::backdrop { background: rgba(6, 20, 30, .7); backdrop-filter: blur(2px); }
.gift-dialog[open] { animation: pop .25s ease-out; }
@keyframes pop { from { transform: scale(.92); opacity: 0; } to { transform: none; opacity: 1; } }
.gift-inner { display: grid; grid-template-columns: 220px 1fr; gap: 20px; padding: 22px; align-items: center; }
.gift-inner img { width: 100%; height: auto; border-radius: 10px; display: block; }
.gift-inner h2 { font-size: 30px; line-height: 1.05; color: var(--blue); }
.gift-price { font-size: 26px; font-weight: 700; color: #8a5a00; margin: 6px 0 8px; }
.gift-desc { font-size: 18px; line-height: 1.4; margin: 0 0 16px; }
.gift-help { font-size: 15px; line-height: 1.35; color: #4b5a63; margin: 12px 0 0; }
.btn {
  display: inline-block;
  background: linear-gradient(180deg, #e6b453, #c98f26);
  color: #2b1a00; text-decoration: none; font-weight: 700;
  font-size: 19px; padding: 11px 22px; border-radius: 999px;
  box-shadow: 0 4px 0 #9c6d16, 0 6px 14px rgba(0, 0, 0, .25);
  border: 0; cursor: pointer; font-family: inherit;
}
.btn:hover { filter: brightness(1.06); }
.btn:active { transform: translateY(2px); box-shadow: 0 2px 0 #9c6d16; }
.btn-ghost {
  background: none; box-shadow: none; color: var(--blue);
  text-decoration: underline; font-weight: 400; font-size: 16px; padding: 8px 4px;
}
.close-x {
  position: absolute; top: 8px; right: 10px;
  width: 40px; height: 40px; border-radius: 50%;
  border: 0; background: rgba(26, 77, 109, .1); color: var(--blue);
  font-size: 26px; line-height: 1; cursor: pointer;
}
@media (max-width: 560px) {
  .gift-inner { grid-template-columns: 1fr; text-align: center; padding: 18px 18px 22px; gap: 10px; }
  .gift-inner img { width: 58%; margin: 0 auto; }
  .gift-inner h2 { font-size: 26px; }
}

@media (prefers-reduced-motion: reduce) {
  .ornament img, .tree-star, .gift-dialog[open] { animation: none; }
}
