:root {
  color-scheme: light;
  font-family: "Segoe UI Variable", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-synthesis: none;
  --bg: #fbf8ff;
  --surface: #ffffff;
  --surface-container: #f1ecf7;
  --surface-variant: #e4e1eb;
  --on-surface: #1b1b21;
  --on-surface-variant: #49464f;
  --outline: #79747e;
  --outline-variant: #cac4d0;
  --primary: #6750a4;
  --on-primary: #ffffff;
  --primary-container: #eaddff;
  --on-primary-container: #21005d;
  --secondary-container: #e8def8;
  --on-secondary-container: #1d192b;
  --tertiary: #7d5260;
  --tertiary-container: #ffd9e2;
  --on-tertiary-container: #31101d;
  --success: #386a45;
  --success-container: #b9f2bd;
  --shadow: 0 10px 28px rgba(50, 38, 73, .08);
  --shadow-raised: 0 14px 36px rgba(50, 38, 73, .14);
  --glass: rgba(255, 255, 255, .56);
  --glass-strong: rgba(255, 255, 255, .72);
  --glass-border: rgba(255, 255, 255, .78);
}
* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--on-surface);
  background:
    radial-gradient(circle at 92% 4%, rgba(208, 191, 255, .72), transparent 27rem),
    radial-gradient(circle at -8% 38%, rgba(255, 217, 226, .62), transparent 23rem),
    linear-gradient(135deg, rgba(255, 255, 255, .74), transparent 42%),
    var(--bg);
  background-attachment: fixed;
}
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
.shell { max-width: 1180px; margin: auto; padding-left: 24px; padding-right: 24px; }
.glow { display: none; }
.topbar { height: 84px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--on-surface); font-size: 19px; font-weight: 800; letter-spacing: .08em; }
.brand-icon { display: grid; width: 42px; height: 42px; place-items: center; color: var(--on-primary-container); background: var(--primary-container); border: 1px solid rgba(103, 80, 164, .14); border-radius: 15px 15px 15px 5px; font-size: 22px; transform: rotate(-4deg); }
.accent { color: var(--primary); }
.ghost { color: var(--on-secondary-container); background: var(--glass-strong); border: 1px solid var(--glass-border); border-radius: 999px; padding: 11px 17px; box-shadow: inset 0 1px 0 rgba(255,255,255,.86), 0 8px 24px rgba(72,52,112,.08); backdrop-filter: blur(18px) saturate(145%); transition: background .18s ease, box-shadow .18s ease, transform .18s ease; }
.ghost:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.ghost:active { transform: translateY(0); }
.mini { font-size: 13px; font-weight: 700; }
.hero { position: relative; margin: 20px 0 58px; padding: clamp(42px, 7vw, 82px) clamp(22px, 7vw, 96px); overflow: hidden; text-align: center; background: linear-gradient(135deg, rgba(255,255,255,.72), rgba(242,235,255,.46)); border: 1px solid var(--glass-border); border-radius: 40px 40px 40px 12px; box-shadow: inset 0 1px 0 rgba(255,255,255,.9), var(--shadow); backdrop-filter: blur(24px) saturate(150%); }
.hero::after { content: ""; position: absolute; width: 180px; height: 180px; right: -44px; bottom: -64px; background: var(--tertiary-container); border-radius: 52% 48% 38% 62%; opacity: .72; transform: rotate(15deg); }
.eyebrow { position: relative; z-index: 1; display: flex; align-items: center; justify-content: center; gap: 9px; color: var(--primary); font-size: 12px; font-weight: 800; letter-spacing: .12em; }
.pulse { width: 9px; height: 9px; background: var(--tertiary); border-radius: 50%; box-shadow: 0 0 0 5px rgba(125, 82, 96, .12); }
.hero h1 { position: relative; z-index: 1; max-width: 900px; margin: 20px auto 16px; color: var(--on-surface); font-size: clamp(39px, 6vw, 76px); font-weight: 780; letter-spacing: -.055em; line-height: 1.04; }
.gradient { color: var(--primary); background: none; }
.hero p { position: relative; z-index: 1; max-width: 600px; margin: 0 auto; color: var(--on-surface-variant); font-size: 16px; line-height: 1.65; }
.stats { position: relative; z-index: 1; display: flex; align-items: center; justify-content: center; gap: 28px; margin-top: 34px; }
.stats > div:not(.stat-pill) { display: flex; flex-direction: column; }
.stats strong { color: var(--on-surface); font-size: 30px; line-height: 1.1; }
.stats small { margin-top: 4px; color: var(--on-surface-variant); font-size: 12px; }
.stat-pill { padding: 11px 16px; color: var(--on-primary-container); background: var(--primary-container); border: 1px solid rgba(103, 80, 164, .13); border-radius: 999px; font-size: 12px; font-weight: 700; }
.catalog-title { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 24px; }
.catalog-title h2 { margin: 0 0 6px; font-size: 29px; letter-spacing: -.035em; }
.catalog-title h2 span { color: var(--tertiary); }
.catalog-title p { margin: 0; color: var(--on-surface-variant); font-size: 14px; }
.filters { display: flex; gap: 10px; }
.filters input, .filters select { min-width: 174px; padding: 12px 15px; color: var(--on-surface); background: var(--glass-strong); border: 1px solid var(--glass-border); border-radius: 14px; outline: none; box-shadow: inset 0 1px 0 rgba(255,255,255,.84); backdrop-filter: blur(18px) saturate(145%); transition: border-color .18s ease, box-shadow .18s ease; }
.filters input:focus, .filters select:focus, .field:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(103, 80, 164, .16); }
.catalog { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.gift { position: relative; display: flex; flex-direction: column; overflow: hidden; background: var(--glass); border: 1px solid var(--glass-border); border-radius: 24px 24px 24px 8px; box-shadow: inset 0 1px 0 rgba(255,255,255,.9), 0 2px 0 rgba(50, 38, 73, .02); backdrop-filter: blur(20px) saturate(145%); transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.gift:hover { border-color: rgba(103, 80, 164, .5); box-shadow: var(--shadow-raised); transform: translateY(-4px); }
.gift-image { position: relative; display: flex; height: 166px; align-items: center; justify-content: center; background: rgba(232, 222, 248, .62); }
.gift:nth-child(3n) .gift-image { background: var(--tertiary-container); }
.gift:nth-child(3n + 1) .gift-image { background: var(--primary-container); }
.gift-image img { width: 100%; height: 100%; object-fit: cover; }
.placeholder { color: var(--primary); font-size: 54px; filter: saturate(.9); }
.status { position: absolute; top: 12px; right: 12px; padding: 8px 11px; color: var(--success); background: var(--success-container); border: 1px solid rgba(56, 106, 69, .18); border-radius: 999px; font-size: 11px; font-weight: 800; }
.status.busy { color: var(--on-tertiary-container); background: var(--tertiary-container); border-color: rgba(125, 82, 96, .2); }
.gift-body { display: flex; flex: 1; flex-direction: column; gap: 8px; padding: 18px; }
.gift-category { color: var(--primary); font-size: 10px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.gift h3 { margin: 2px 0 0; font-size: 17px; line-height: 1.3; }
.gift p { flex: 1; margin: 0; color: var(--on-surface-variant); font-size: 13px; line-height: 1.52; }
.price { margin-top: 6px; color: var(--primary); font-size: 15px; font-weight: 750; }
.gift-actions { display: flex; gap: 8px; margin-top: 10px; }
.btn { flex: 1; padding: 11px 14px; color: var(--on-primary); background: var(--primary); border: 0; border-radius: 999px; font-weight: 750; transition: background .18s ease, box-shadow .18s ease, transform .18s ease; }
.btn:hover { background: #5b4494; box-shadow: var(--shadow); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:disabled { color: var(--on-surface-variant); background: var(--surface-variant); cursor: not-allowed; box-shadow: none; transform: none; }
.shop { display: flex; align-items: center; padding: 10px 12px; color: var(--primary); border: 1px solid var(--outline); border-radius: 999px; font-size: 13px; text-decoration: none; }
.shop:hover { background: var(--primary-container); }
.empty { grid-column: 1 / -1; padding: 42px; color: var(--on-surface-variant); text-align: center; }
.footer-note { display: flex; align-items: center; gap: 18px; margin: 52px 0; padding: 23px; background: var(--tertiary-container); border: 1px solid rgba(125, 82, 96, .14); border-radius: 26px 26px 8px 26px; }
.footer-note > span { font-size: 30px; }
.footer-note p { margin: 4px 0 0; color: var(--on-tertiary-container); font-size: 14px; }
.footer { display: flex; justify-content: space-between; gap: 20px; padding-top: 25px; padding-bottom: 32px; color: var(--on-surface-variant); border-top: 1px solid var(--outline-variant); font-size: 12px; }
.linkbutton { padding: 0; color: var(--primary); background: transparent; border: 0; text-decoration: underline; }
.overlay { position: fixed; inset: 0; z-index: 10; display: flex; align-items: center; justify-content: center; padding: 15px; overflow: auto; background: rgba(29, 27, 32, .48); backdrop-filter: blur(5px); }
.hidden { display: none !important; }
.modal { position: relative; width: min(100%, 530px); max-height: 95vh; padding: 30px; overflow: auto; background: var(--glass-strong); border: 1px solid var(--glass-border); border-radius: 30px 30px 30px 10px; box-shadow: inset 0 1px 0 rgba(255,255,255,.92), 0 24px 70px rgba(29, 27, 32, .24); backdrop-filter: blur(26px) saturate(150%); }
.close { position: absolute; top: 12px; right: 15px; color: var(--on-surface-variant); background: transparent; border: 0; font-size: 28px; }
.modal h2 { margin: 2px 30px 9px 0; font-size: 25px; letter-spacing: -.03em; }
.modal p { color: var(--on-surface-variant); font-size: 14px; line-height: 1.6; }
.field { display: block; width: 100%; margin: 7px 0 17px; padding: 13px; color: var(--on-surface); background: rgba(255,255,255,.64); border: 1px solid var(--glass-border); border-radius: 14px; outline: 0; box-shadow: inset 0 1px 0 rgba(255,255,255,.86); backdrop-filter: blur(14px); }
.modal label { font-size: 13px; font-weight: 700; }
.checkline { display: flex; align-items: center; gap: 9px; margin: 8px 0 18px; }
.checkline input { width: 18px; height: 18px; accent-color: var(--primary); }
.checkline label { font-weight: 500; }
.modal .btn { width: 100%; margin-top: 4px; }
.notice { margin: 15px 0; padding: 12px 14px; color: var(--on-primary-container); background: var(--primary-container); border-radius: 16px; font-size: 13px; overflow-wrap: anywhere; }
.success { margin-bottom: 15px; font-size: 40px; }
.admin-list { display: flex; flex-direction: column; gap: 8px; max-height: 400px; margin: 15px 0; overflow: auto; }
.admin-row { display: flex; align-items: center; gap: 10px; padding: 10px; background: rgba(255,255,255,.38); border: 1px solid var(--glass-border); border-radius: 14px; }
.admin-row span { flex: 1; font-size: 14px; }
.admin-row button { padding: 8px 11px; color: var(--on-secondary-container); background: var(--secondary-container); border: 0; border-radius: 999px; }
.admin-row .muted { opacity: .45; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.help { color: var(--on-surface-variant); font-size: 12px; }
.danger { color: #ba1a1a; }
#toast { position: fixed; bottom: 22px; left: 50%; z-index: 99; display: none; max-width: min(90vw, 560px); padding: 13px 20px; color: var(--on-primary); text-align: center; background: #322f35; border-radius: 999px; box-shadow: var(--shadow-raised); transform: translateX(-50%); }
#toast.show { display: block; }
:focus-visible { outline: 3px solid rgba(103, 80, 164, .38); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; } }
@media (max-width: 960px) { .catalog { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 690px) {
  .shell { padding-left: 15px; padding-right: 15px; }
  .topbar { height: 72px; }
  .brand { font-size: 16px; }
  .brand-icon { width: 37px; height: 37px; }
  .hero { margin-top: 12px; padding: 48px 20px 56px; border-radius: 30px 30px 30px 10px; }
  .hero h1 { letter-spacing: -.045em; }
  .catalog { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
  .catalog-title { display: block; }
  .filters { margin-top: 17px; }
  .filters input, .filters select { min-width: 0; width: 50%; }
  .gift-image { height: 130px; }
  .gift { border-radius: 18px 18px 18px 7px; }
  .gift-body { padding: 12px; }
  .gift h3 { font-size: 14px; }
  .gift p { font-size: 12px; }
  .gift-actions { flex-direction: column; }
  .shop { justify-content: center; }
  .stats { gap: 18px; }
  .stat-pill { padding: 9px 11px; font-size: 11px; }
  .modal { padding: 23px; border-radius: 25px 25px 25px 9px; }
  .footer { display: block; }
  .footer button { display: block; margin: 15px 0 0; }
}
@media (max-width: 370px) { .catalog { grid-template-columns: 1fr; } .gift-image { height: 180px; } }

