/* Wujje Store — All CSS Styles (Extracted from index.html) */

:root,
[data-theme="violet"] {
  --bg: #0b0816;
  --orb-1: rgba(168, 85, 247, 0.34);
  --orb-2: rgba(236, 72, 153, 0.22);
  --orb-3: rgba(99, 102, 241, 0.22);
  --glass: rgba(24, 18, 46, 0.58);
  --glass-strong: rgba(30, 22, 58, 0.82);
  --field: rgba(12, 9, 24, 0.76);
  --border: rgba(255, 255, 255, 0.11);
  --border-strong: rgba(192, 132, 252, 0.45);
  --text: #f8f7ff;
  --muted: #a69ec4;
  --price: #e9e4ff;
  --accent: #a855f7;
  --accent-2: #7c3aed;
  --accent-glow: rgba(168, 85, 247, 0.42);
  --accent-soft: rgba(168, 85, 247, 0.16);
  --on-accent: #ffffff;
  --green: #34d399;
  --green-bg: rgba(52, 211, 153, 0.14);
  --green-border: rgba(52, 211, 153, 0.38);
  --gold: #fbbf24;
  --gold-bg: rgba(251, 191, 36, 0.13);
  --gold-border: rgba(251, 191, 36, 0.46);
  --red: #f87171;
  --red-bg: rgba(248, 113, 113, 0.14);
  --red-border: rgba(248, 113, 113, 0.38);
  --dock-bg: rgba(17, 12, 34, 0.80);
  --modal-bg: rgba(18, 13, 35, 0.96);
  --splash-bg: #080612;
  --shadow: 0 14px 34px rgba(0, 0, 0, 0.52);
}

[data-theme="sapphire"] {
  --bg: #070d19;
  --orb-1: rgba(56, 189, 248, 0.30);
  --orb-2: rgba(37, 99, 235, 0.26);
  --orb-3: rgba(14, 165, 233, 0.20);
  --glass: rgba(15, 25, 45, 0.58);
  --glass-strong: rgba(19, 32, 58, 0.82);
  --field: rgba(8, 14, 28, 0.76);
  --border: rgba(255, 255, 255, 0.10);
  --border-strong: rgba(56, 189, 248, 0.45);
  --text: #f3f8ff;
  --muted: #8ea5c4;
  --price: #dbeafe;
  --accent: #38bdf8;
  --accent-2: #2563eb;
  --accent-glow: rgba(56, 189, 248, 0.38);
  --accent-soft: rgba(56, 189, 248, 0.15);
  --on-accent: #ffffff;
  --green: #34d399;
  --green-bg: rgba(52, 211, 153, 0.14);
  --green-border: rgba(52, 211, 153, 0.38);
  --gold: #fbbf24;
  --gold-bg: rgba(251, 191, 36, 0.13);
  --gold-border: rgba(251, 191, 36, 0.46);
  --red: #f87171;
  --red-bg: rgba(248, 113, 113, 0.14);
  --red-border: rgba(248, 113, 113, 0.38);
  --dock-bg: rgba(10, 18, 34, 0.80);
  --modal-bg: rgba(11, 19, 36, 0.96);
  --splash-bg: #050a14;
  --shadow: 0 14px 34px rgba(0, 0, 0, 0.55);
}

[data-theme="emerald"] {
  --bg: #06120f;
  --orb-1: rgba(16, 185, 129, 0.30);
  --orb-2: rgba(20, 184, 166, 0.22);
  --orb-3: rgba(52, 211, 153, 0.18);
  --glass: rgba(12, 31, 26, 0.58);
  --glass-strong: rgba(15, 40, 34, 0.82);
  --field: rgba(7, 18, 15, 0.76);
  --border: rgba(255, 255, 255, 0.10);
  --border-strong: rgba(52, 211, 153, 0.45);
  --text: #f2fdf9;
  --muted: #8bb5a7;
  --price: #d1fae5;
  --accent: #10b981;
  --accent-2: #059669;
  --accent-glow: rgba(16, 185, 129, 0.38);
  --accent-soft: rgba(16, 185, 129, 0.16);
  --on-accent: #ffffff;
  --green: #34d399;
  --green-bg: rgba(52, 211, 153, 0.16);
  --green-border: rgba(52, 211, 153, 0.42);
  --gold: #fbbf24;
  --gold-bg: rgba(251, 191, 36, 0.13);
  --gold-border: rgba(251, 191, 36, 0.46);
  --red: #f87171;
  --red-bg: rgba(248, 113, 113, 0.14);
  --red-border: rgba(248, 113, 113, 0.38);
  --dock-bg: rgba(8, 22, 18, 0.80);
  --modal-bg: rgba(9, 24, 20, 0.96);
  --splash-bg: #040d0b;
  --shadow: 0 14px 34px rgba(0, 0, 0, 0.55);
}

[data-theme="ice"] {
  --bg: #eaf0f8;
  --orb-1: rgba(56, 189, 248, 0.32);
  --orb-2: rgba(167, 139, 250, 0.24);
  --orb-3: rgba(96, 165, 250, 0.22);
  --glass: rgba(255, 255, 255, 0.72);
  --glass-strong: rgba(255, 255, 255, 0.92);
  --field: rgba(241, 245, 252, 0.88);
  --border: rgba(15, 23, 42, 0.09);
  --border-strong: rgba(37, 99, 235, 0.35);
  --text: #0f172a;
  --muted: #5b6b84;
  --price: #1e293b;
  --accent: #2563eb;
  --accent-2: #0284c7;
  --accent-glow: rgba(37, 99, 235, 0.28);
  --accent-soft: rgba(37, 99, 235, 0.11);
  --on-accent: #ffffff;
  --green: #059669;
  --green-bg: rgba(16, 185, 129, 0.14);
  --green-border: rgba(16, 185, 129, 0.35);
  --gold: #d97706;
  --gold-bg: rgba(245, 158, 11, 0.14);
  --gold-border: rgba(245, 158, 11, 0.45);
  --red: #dc2626;
  --red-bg: rgba(220, 38, 38, 0.12);
  --red-border: rgba(220, 38, 38, 0.32);
  --dock-bg: rgba(255, 255, 255, 0.84);
  --modal-bg: rgba(255, 255, 255, 0.97);
  --splash-bg: #e5edf8;
  --shadow: 0 12px 30px rgba(15, 23, 42, 0.10);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Onest", -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, sans-serif;
  font-weight: 400;
  overflow-x: hidden;
  transition: background 0.38s ease, color 0.3s ease;
}

.ambient-bg { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.orb { position: absolute; border-radius: 50%; filter: blur(80px); transition: background 0.45s ease; }
.orb-1 { width: 320px; height: 320px; top: -90px; left: -70px; background: var(--orb-1); }
.orb-2 { width: 300px; height: 300px; top: 24%; right: -100px; background: var(--orb-2); }
.orb-3 { width: 340px; height: 340px; bottom: -80px; left: 15%; background: var(--orb-3); }

.app {
  position: relative; z-index: 1;
  width: 100%; max-width: 860px; min-height: 100vh;
  margin: 0 auto; padding: 14px 14px 104px;
  opacity: 0; transform: translateY(10px);
  transition: opacity 0.45s ease, transform 0.45s ease;
}
.app.app-ready { opacity: 1; transform: translateY(0); }

.topbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.topbar-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.topbar-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

.back-btn {
  width: 36px; height: 36px; border-radius: 12px;
  border: 1px solid var(--border); background: var(--glass);
  backdrop-filter: blur(14px); color: var(--text); font-size: 17px;
  display: none; align-items: center; justify-content: center; cursor: pointer;
}
.back-btn.visible { display: inline-flex; }

.brand-mark {
  width: 42px !important; height: 42px !important; border-radius: 13px !important; flex-shrink: 0;
  display: inline-flex !important; align-items: center !important; justify-content: center !important;
  font-family: "Unbounded", sans-serif !important; font-weight: 700 !important; font-size: 13.5px !important;
  background: linear-gradient(135deg, var(--accent-soft), rgba(255, 255, 255, 0.06)) !important;
  border: 1.5px solid var(--border-strong) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 4px 14px var(--accent-glow) !important;
  overflow: visible;
}
.brand-mark svg { width: 100%; height: 100%; }
.brand-title { font-family: "Unbounded", sans-serif; font-size: 16.5px; font-weight: 700; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -0.02em; }
.brand-sub { font-size: 11px; color: var(--muted); margin-top: 2px; }

.price-num, .cs-rub, .cs-ton, [id*="balanceText"], [id*="Rub"], [id*="Ton"] { font-variant-numeric: tabular-nums; font-family: "Onest", monospace; font-weight: 600; }

.balance-pill {
  position: relative; display: inline-flex; align-items: center; gap: 7px;
  height: 36px; padding: 0 5px 0 12px; border-radius: 999px;
  background: var(--glass-strong); backdrop-filter: blur(16px);
  border: 1px solid var(--border); font-size: 13px; font-weight: 800;
  color: var(--text); box-shadow: var(--shadow);
}
.balance-pill.pulse-green { border-color: var(--green); box-shadow: 0 0 20px var(--green-bg); }
.balance-plus {
  width: 26px; height: 26px; border-radius: 999px; border: none;
  background: linear-gradient(145deg, var(--accent), var(--accent-2));
  color: #fff; font-size: 16px; font-weight: 800;
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
}
#rubPill { position: relative; transition: transform 0.25s ease, box-shadow 0.35s ease, border-color 0.35s ease; }
#rubPill.pulse-green { transform: scale(1.03); border-color: var(--green-border); box-shadow: 0 0 18px var(--green-bg); }
#rubPill.pulse-red { transform: scale(1.03); border-color: var(--red-border); box-shadow: 0 0 18px var(--red-bg); }
.balance-float {
  position: absolute; right: 6px; top: -10px;
  padding: 2px 7px; border-radius: 999px;
  font-size: 11px; font-weight: 800; letter-spacing: 0.01em;
  pointer-events: none; white-space: nowrap; z-index: 20;
  backdrop-filter: blur(8px);
  animation: floatUpSmooth 2.0s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
.balance-float.plus {
  color: #6ee7b7;
  background: rgba(16, 185, 129, 0.22);
  border: 1px solid rgba(52, 211, 153, 0.45);
}
.balance-float.minus {
  color: #fca5a5;
  background: rgba(239, 68, 68, 0.22);
  border: 1px solid rgba(248, 113, 113, 0.45);
}
@keyframes floatUpSmooth {
  0% { opacity: 0; transform: translateY(6px) scale(0.92); }
  18% { opacity: 1; transform: translateY(-4px) scale(1); }
  72% { opacity: 1; transform: translateY(-16px) scale(1); }
  100% { opacity: 0; transform: translateY(-26px) scale(0.96); }
}

.wallet-bar { display: flex; justify-content: flex-end; margin-bottom: 10px; }

.screen { display: none; animation: fadeScreen 0.24s ease; }
.screen.active { display: block; }
@keyframes fadeScreen { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

.glass-card {
  background: var(--glass); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border); border-radius: 20px; padding: 14px;
  margin-bottom: 12px; box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.hero-card {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 15px; border-radius: 22px;
  background: linear-gradient(135deg, var(--accent-soft) 0%, var(--glass-strong) 100%);
  backdrop-filter: blur(20px); border: 1px solid var(--border-strong);
  box-shadow: var(--shadow), 0 0 26px var(--accent-soft); margin-bottom: 11px;
}
.hero-title { font-size: 18.5px; font-weight: 900; line-height: 1.18; }
.hero-sub { font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.hero-btn {
  padding: 11px 14px; border-radius: 14px; border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--on-accent); font-size: 12.5px; font-weight: 800;
  white-space: nowrap; cursor: pointer; box-shadow: 0 10px 22px var(--accent-glow);
}

.live-strip {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 8px 13px; margin-bottom: 11px; border-radius: 999px;
  background: var(--glass); backdrop-filter: blur(14px);
  border: 1px solid var(--border); font-size: 11.5px; color: var(--price);
}
.live-left { display: flex; align-items: center; gap: 8px; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); flex-shrink: 0; }
.live-time { font-size: 11px; color: var(--muted); white-space: nowrap; }

.filter-row { display: flex; gap: 8px; overflow-x: auto; padding: 18px 6px 26px 6px; margin: -14px -6px -14px -6px; scrollbar-width: none; }
.filter-row::-webkit-scrollbar { display: none; }
.filter-chip {
  padding: 8px 14px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--glass); backdrop-filter: blur(12px); color: var(--muted);
  font-size: 12.5px; font-weight: 700; cursor: pointer; white-space: nowrap;
}
.filter-chip.active {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--on-accent); border-color: transparent; box-shadow: 0 6px 18px var(--accent-glow);
}

.custom-stars-card {
  background: var(--glass-strong); border: 1.5px solid var(--gold-border);
  box-shadow: var(--shadow), 0 0 24px var(--gold-bg);
}
.cs-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.cs-title { font-size: 14.5px; font-weight: 800; }
.cs-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.cs-badge {
  font-size: 10.5px; font-weight: 800; padding: 3px 9px; border-radius: 999px;
  color: var(--gold); background: var(--gold-bg); border: 1px solid var(--gold-border);
}
.cs-row { display: flex; align-items: center; gap: 10px; }
.cs-input {
  flex: 1; min-width: 0; padding: 12px 14px; border-radius: 14px;
  border: 1px solid var(--border-strong); background: var(--field);
  color: var(--text); font-size: 18px; font-weight: 900; outline: none;
}
.cs-quote { text-align: right; min-width: 96px; }
.cs-rub { font-size: 16px; font-weight: 900; }
.cs-ton { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.quick-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; margin-top: 10px; }
.quick-btn {
  padding: 8px 4px; border-radius: 11px; border: 1px solid var(--border);
  background: var(--field); color: var(--price); font-size: 12px; font-weight: 800; cursor: pointer;
}

.categories-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 640px) { .categories-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.cat-card {
  position: relative; display: flex; flex-direction: column; justify-content: space-between;
  min-height: 148px; padding: 13px; border-radius: 20px; border: 1px solid var(--border);
  background: var(--glass); backdrop-filter: blur(18px); color: var(--text);
  text-align: left; cursor: pointer; box-shadow: var(--shadow);
}
.cat-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-bottom: 9px; }
.cat-icon {
  width: 42px; height: 42px; border-radius: 14px;
  display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(145deg, var(--accent-soft), var(--field));
  border: 1px solid var(--border-strong); font-size: 19px; overflow: hidden;
}
.cat-icon img { width: 23px; height: 23px; object-fit: contain; filter: brightness(0) invert(1); }
[data-theme="ice"] .cat-icon img { filter: none; }
.cat-name { font-size: 15px; font-weight: 800; line-height: 1.2; }
.cat-desc { font-size: 11.5px; color: var(--muted); margin-top: 4px; line-height: 1.3; }
.cat-bottom { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 10px; }
.cat-from { font-size: 12px; font-weight: 800; color: var(--price); }

.tag-pill {
  font-size: 10px; font-weight: 800; padding: 3px 7px; border-radius: 999px;
  background: var(--green-bg); color: var(--green); border: 1px solid var(--green-border);
  white-space: nowrap;
}
.tag-pill.amber { background: var(--gold-bg); color: var(--gold); border-color: var(--gold-border); }
.tag-pill.out { background: var(--red-bg); color: var(--red); border-color: var(--red-border); }

.nft-search-box { margin-bottom: 11px; }
.nft-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
@media (min-width: 640px) { .nft-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.nft-card {
  position: relative; border-radius: 20px; overflow: hidden;
  border: 1px solid var(--border); background: var(--glass);
  backdrop-filter: blur(18px); box-shadow: var(--shadow);
  display: flex; flex-direction: column; justify-content: space-between;
}
.gift-card {
  position: relative; border-radius: 20px; overflow: hidden;
  border: 1px solid var(--border); background: var(--glass);
  backdrop-filter: blur(18px); box-shadow: var(--shadow);
  display: flex; flex-direction: column; justify-content: space-between;
}
.nft-img-wrap, .gift-img-wrap {
  position: relative; width: 100%; aspect-ratio: 1 / 1;
  background: var(--field); overflow: hidden; cursor: pointer;
}
.nft-img-wrap img, .gift-img-wrap img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nft-body, .gift-body { padding: 11px; cursor: pointer; }
.nft-title, .gift-title { font-size: 13.5px; font-weight: 800; line-height: 1.2; }
.nft-meta, .gift-meta { font-size: 10.5px; color: var(--muted); margin-top: 3px; }
.nft-floor-row, .gift-floor-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); gap: 4px;
}
.nft-price, .gift-price { font-size: 12.5px; font-weight: 900; color: var(--price); }
.nft-ton, .gift-ton { font-size: 10.5px; color: var(--muted); }
.gift-detail-modal .modal-content { max-width: 90vw; }
.detail-preview { width: 100%; aspect-ratio: 1 / 1; background: var(--field); border-radius: 16px; overflow: hidden; margin-bottom: 16px; }
.detail-preview img { width: 100%; height: 100%; object-fit: cover; }
.detail-animation-container { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.detail-info { padding: 0; }
.detail-info p { margin: 0 0 4px 0; }
.detail-info a { display: block; }
.gift-detail-content { max-width: 100%; width: 100%; }
.modal-close { position: absolute; top: 12px; right: 12px; z-index: 10; }
.nft-img-wrap {
  position: relative; width: 100%; aspect-ratio: 1 / 1;
  background: var(--field); overflow: hidden; cursor: pointer;
}
.nft-img-wrap img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bolt-btn {
  position: absolute; top: 8px; right: 8px; z-index: 3;
  width: 34px; height: 34px; border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: rgba(14, 10, 28, 0.78); backdrop-filter: blur(10px);
  color: var(--gold); font-size: 16px;
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.45);
}
.bolt-btn:active { transform: scale(0.88); }

.nft-body { padding: 11px; cursor: pointer; }
.nft-title { font-size: 13.5px; font-weight: 800; line-height: 1.2; }
.nft-meta { font-size: 10.5px; color: var(--muted); margin-top: 3px; }
.nft-floor-row {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); gap: 4px;
}
.nft-price { font-size: 12.5px; font-weight: 900; color: var(--price); }
.nft-ton { font-size: 10.5px; color: var(--muted); }

.model-card {
  border-radius: 20px; overflow: hidden;
  border: 1px solid var(--border); background: var(--glass);
  backdrop-filter: blur(18px); box-shadow: var(--shadow);
  margin-bottom: 12px;
}
.model-specs-bar { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 12px 8px; }
.spec-chip {
  font-size: 11px; font-weight: 700; padding: 4px 9px; border-radius: 999px;
  background: var(--field); border: 1px solid var(--border); color: var(--price);
}
.spec-chip b { color: var(--text); }
.model-photo-box { position: relative; width: 100%; height: 245px; background: var(--field); overflow: hidden; }
.model-photo-box img { width: 100%; height: 100%; object-fit: cover; display: block; }
.model-animation-container { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.model-animation-container canvas { width: 100%; height: 100%; }
.model-admin-row { display: flex; gap: 6px; padding: 8px; border-top: 1px solid rgba(255, 255, 255, 0.1); }
.admin-link { flex: 1; padding: 6px; border-radius: 4px; text-align: center; font-size: 11px; text-decoration: none; cursor: pointer; transition: all 0.2s; }
.admin-link:hover { opacity: 0.85; }
.model-nft-link { padding: 8px 0; border-top: 1px solid rgba(255, 255, 255, 0.1); }
.model-nft-link a { display: block; padding: 6px; text-align: center; font-size: 11px; color: #34d399; text-decoration: none; cursor: pointer; transition: all 0.2s; }
.model-nft-link a:hover { opacity: 0.85; }
.model-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 13px; }

.items-list { display: flex; flex-direction: column; gap: 9px; }
.item-card {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 13px; border-radius: 18px; border: 1px solid var(--border);
  background: var(--glass); backdrop-filter: blur(18px); color: var(--text);
  text-align: left; cursor: pointer; box-shadow: var(--shadow);
}
.item-card.disabled-item { opacity: 0.65; }
.item-left { display: flex; align-items: center; gap: 11px; min-width: 0; }
.item-title { font-size: 14px; font-weight: 800; }
.item-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.item-right { display: flex; align-items: center; gap: 9px; flex-shrink: 0; }
.item-price { font-size: 13.5px; font-weight: 900; text-align: right; }
.item-subprice { font-size: 10.5px; color: var(--muted); text-align: right; }
.field-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.field-label { font-size: 12px; color: var(--muted); font-weight: 600; }
.mini-btn {
  padding: 5px 10px; border-radius: 9px; border: 1px solid var(--border);
  background: var(--field); color: var(--price); font-size: 11.5px; font-weight: 700; cursor: pointer;
}
.input {
  width: 100%; padding: 12px 14px; border-radius: 14px;
  border: 1px solid var(--border); background: var(--field);
  color: var(--text); font-size: 14.5px; font-weight: 600; outline: none;
}
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.primary-btn {
  width: 100%; padding: 13px 16px; border: none; border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--on-accent); font-size: 14.5px; font-weight: 800; cursor: pointer;
  box-shadow: 0 12px 26px var(--accent-glow);
}
.secondary-btn {
  width: 100%; margin-top: 8px; padding: 11px 14px; border-radius: 14px;
  border: 1px solid var(--border); background: var(--field);
  color: var(--price); font-size: 13px; font-weight: 700; cursor: pointer;
}
.status-note { margin-top: 9px; font-size: 12px; color: var(--muted); text-align: center; min-height: 16px; }

.recent-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.recent-chip {
  padding: 4px 10px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--field); color: var(--muted); font-size: 11.5px; font-weight: 700; cursor: pointer;
}
.user-preview {
  margin-top: 10px; padding: 10px 12px; border-radius: 14px;
  border: 1px solid var(--border); background: var(--field);
  display: none; align-items: center; justify-content: space-between; gap: 10px;
}
.user-preview.visible { display: flex; }
.user-preview.found { border-color: var(--green-border); background: var(--green-bg); }
.user-preview.not-found { border-color: var(--red-border); background: var(--red-bg); }
.user-avatar {
  width: 38px; height: 38px; border-radius: 50%; background: var(--accent-soft);
  display: flex; align-items: center; justify-content: center; font-weight: 800; overflow: hidden;
}

.packages-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
@media (min-width: 640px) { .packages-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.package-card {
  display: flex; flex-direction: column; gap: 4px; padding: 11px; border-radius: 15px;
  border: 1px solid var(--border); background: var(--field); color: var(--text); text-align: left; cursor: pointer;
}
.package-card.active { border-color: var(--accent); background: var(--accent-soft); }
.package-top { display: flex; align-items: center; justify-content: space-between; gap: 4px; }
.package-title { font-size: 13.5px; font-weight: 800; }
.package-badge { font-size: 9.5px; font-weight: 800; padding: 2px 6px; border-radius: 999px; background: var(--accent); color: #fff; }
.package-price { font-size: 12px; font-weight: 700; color: var(--price); }
.package-rate { font-size: 10.5px; color: var(--muted); }

.profile-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.profile-avatar {
  width: 52px; height: 52px; border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 900; overflow: hidden; flex-shrink: 0;
}
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.rank-badge {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px;
  font-size: 11px; font-weight: 800; background: var(--accent-soft); border: 1px solid var(--border-strong); margin-top: 5px;
}
.rank-bar { width: 100%; height: 7px; border-radius: 999px; background: var(--field); overflow: hidden; margin-top: 6px; }
.rank-fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--accent), var(--gold)); border-radius: 999px; transition: width 0.35s ease; }

.stats-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-top: 12px; }
.stat-box { padding: 11px; border-radius: 14px; border: 1px solid var(--border); background: var(--field); }
.stat-label { font-size: 11px; color: var(--muted); }
.stat-val { font-size: 15px; font-weight: 800; margin-top: 3px; }

.theme-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-top: 10px; }
.theme-option {
  display: flex; align-items: center; gap: 10px; padding: 11px; border-radius: 15px;
  border: 1.5px solid var(--border); background: var(--field); color: var(--text); text-align: left; cursor: pointer;
}
.theme-option.active { border-color: var(--accent); background: var(--accent-soft); }
.theme-swatch { width: 28px; height: 28px; border-radius: 10px; flex-shrink: 0; border: 1px solid rgba(255, 255, 255, 0.25); }
.theme-icon { font-size: 20px; display: flex; align-items: center; justify-content: center; }
.theme-name { font-size: 12.5px; font-weight: 800; }
.theme-tag { font-size: 10.5px; color: var(--muted); margin-top: 1px; }

.ach-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 8px; }
.ach-card { padding: 10px; border-radius: 13px; border: 1px solid var(--border); background: var(--field); opacity: 0.55; }
.ach-card.unlocked { opacity: 1; border-color: var(--green-border); background: var(--green-bg); }
.ach-title { font-size: 12px; font-weight: 800; }
.ach-desc { font-size: 10.5px; color: var(--muted); margin-top: 2px; }

.order-row { padding: 12px; border-radius: 15px; border: 1px solid var(--border); background: var(--field); margin-bottom: 9px; }
.order-top { display: flex; justify-content: space-between; align-items: center; font-size: 13px; font-weight: 800; gap: 8px; }
.order-sub { font-size: 11.5px; color: var(--muted); margin-top: 4px; line-height: 1.4; }
.faq-item { padding: 13px; border-radius: 16px; border: 1px solid var(--border); background: var(--glass); backdrop-filter: blur(16px); margin-bottom: 10px; }
.faq-q { font-size: 14px; font-weight: 800; }
.faq-a { font-size: 12.5px; color: var(--muted); margin-top: 5px; line-height: 1.45; }

.bottom-dock {
  position: fixed; left: 50%; bottom: max(12px, env(safe-area-inset-bottom));
  transform: translateX(-50%); z-index: 900;
  width: calc(100% - 24px); max-width: 460px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 6px;
  border-radius: 24px; background: var(--dock-bg);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border); box-shadow: 0 18px 44px rgba(0, 0, 0, 0.55);
}
.dock-btn {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; padding: 8px 4px; border-radius: 18px; border: none;
  background: transparent; color: var(--muted); font-size: 10.5px; font-weight: 700; cursor: pointer;
}
.dock-btn svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.dock-btn.active { background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: var(--on-accent); box-shadow: 0 8px 20px var(--accent-glow); }
.dock-badge {
  position: absolute; top: 4px; right: 14px; min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 999px; background: var(--gold); color: #0b0816; font-size: 10px; font-weight: 900;
  display: none; align-items: center; justify-content: center;
}
.dock-badge.show { display: inline-flex; }

.modal-backdrop {
  position: fixed; inset: 0; z-index: 1050;
  display: flex; align-items: center; justify-content: center; padding: 16px;
  background: rgba(0, 0, 0, 0); opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity 0.25s ease, background 0.25s ease, visibility 0.25s ease;
}
.modal-backdrop.open { opacity: 1; visibility: visible; pointer-events: auto; background: rgba(0, 0, 0, 0.64); backdrop-filter: blur(8px); }
.modal-backdrop.sheet { align-items: flex-end; padding: 12px; }
.modal-box {
  width: 100%; max-width: 440px; max-height: 88vh; overflow-y: auto;
  border-radius: 24px; padding: 18px; background: var(--modal-bg);
  border: 1px solid var(--border-strong); box-shadow: 0 24px 60px rgba(0, 0, 0, 0.72);
}
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.modal-title { font-size: 16.5px; font-weight: 900; }
.modal-close { width: 32px; height: 32px; border-radius: 10px; border: 1px solid var(--border); background: var(--field); color: var(--text); font-size: 18px; cursor: pointer; }

.preset-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; margin-top: 10px; }
.preset-chip { padding: 8px 4px; border-radius: 11px; border: 1px solid var(--border); background: var(--field); color: var(--price); font-size: 12px; font-weight: 800; cursor: pointer; }
.promo-box { display: none; margin-top: 8px; padding: 10px; border-radius: 14px; border: 1px solid var(--border); background: var(--field); }
.promo-box.open { display: block; }
.promo-status { margin-top: 6px; font-size: 11.5px; color: var(--muted); }
.promo-status.ok { color: var(--green); }
.promo-status.err { color: var(--red); }
.qr-result-box { display: none; margin-top: 12px; padding: 14px; border-radius: 16px; border: 1px solid var(--border-strong); background: var(--field); text-align: center; }
.qr-result-box.open { display: block; }
.qr-result-img { width: 190px; height: 190px; border-radius: 14px; background: #fff; padding: 8px; display: block; margin: 10px auto 12px; object-fit: contain; }

.pay-choice-btn {
  width: 100%; padding: 14px; border-radius: 16px; border: 1px solid var(--border);
  background: var(--field); color: var(--text); display: flex; align-items: center;
  justify-content: space-between; gap: 10px; cursor: pointer; text-align: left; margin-bottom: 9px;
  transition: all 300ms cubic-bezier(0.22, 1, 0.36, 1);
}
.pay-choice-btn:hover { transform: translateY(-2px); background: var(--glass-strong); }
.pay-choice-btn:active { transform: scale(0.97); }
.pay-choice-left { display: flex; align-items: center; gap: 11px; }
.pay-choice-icon { width: 38px; height: 38px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 900; background: var(--accent-soft); border: 1px solid var(--border-strong); }

button, .hero-btn, .dock-btn { transition: all 300ms cubic-bezier(0.22, 1, 0.36, 1); }
button:hover, .hero-btn:hover, .dock-btn:hover { transform: translateY(-2px); }
button:active, .hero-btn:active, .dock-btn:active { transform: scale(0.97); }

.glass-card { transition: all 350ms cubic-bezier(0.22, 1, 0.36, 1); }
.glass-card:hover { transform: translateY(-4px); }

.screen.active { animation: screenFadeIn 300ms cubic-bezier(0.22, 1, 0.36, 1) forwards; }
@keyframes screenFadeIn {
  0% { opacity: 0; transform: translateY(12px); }
  100% { opacity: 1; transform: translateY(0); }
}

html[data-theme] { transition: --bg 400ms ease, --accent 400ms ease; }
.brand-mark { transition: filter 400ms cubic-bezier(0.22, 1, 0.36, 1); }
.hero-card { transition: all 400ms cubic-bezier(0.22, 1, 0.36, 1); }
.theme-option { transition: transform 300ms cubic-bezier(0.22, 1, 0.36, 1); }
.theme-option.active { transform: scale(1.06); }
.brand-mark svg { transition: all 300ms cubic-bezier(0.22, 1, 0.36, 1); }

@media (max-width: 430px) {
  .brand-title { font-size: 15px; }
  .brand-sub { font-size: 10px; }
  h2, h3 { font-size: 16px !important; letter-spacing: -0.01em; }
  .price-num, .cs-rub, .cs-ton { font-size: 14px; }
}

@media (max-width: 375px) {
  .brand-title { font-size: 14px; }
  .brand-sub { font-size: 9px; }
  h2 { font-size: 14px !important; }
  .topbar-left { gap: 7px; }
}

@keyframes checkmarkBounce {
  0% { transform: scale(0) rotate(-45deg); opacity: 0; }
  70% { transform: scale(1.15); }
  100% { transform: scale(1); opacity: 1; }
}

/* Preloader / Splash Screen */
@keyframes loaderFadeOut {
  0% { opacity: 1; pointer-events: auto; }
  100% { opacity: 0; pointer-events: none; }
}

@keyframes loaderGlow {
  0%, 100% { box-shadow: 0 0 20px rgba(168, 85, 247, 0.4); }
  50% { box-shadow: 0 0 40px rgba(168, 85, 247, 0.8); }
}

@keyframes loaderBarFill {
  0% { width: 0%; }
  70% { width: 70%; }
  100% { width: 100%; }
}

.app-loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 28%, var(--accent-soft), transparent 62%), linear-gradient(160deg, var(--splash-bg) 0%, var(--bg) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 1;
  pointer-events: auto;
  transition: opacity 400ms ease, pointer-events 400ms ease;
}

.app-loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.loader-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  animation: slideInUp 600ms cubic-bezier(0.22, 1, 0.36, 1);
}

.loader-logo {
  font-size: 56px;
  font-weight: 700;
  font-family: "Unbounded", sans-serif;
  background: none !important;
  -webkit-background-clip: unset;
  -webkit-text-fill-color: unset;
  background-clip: unset;
  color: #a855f7;
  filter: none !important;
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
  animation: loaderGlow 2s ease-in-out infinite;
}

.loader-title {
  font-size: 20px;
  font-weight: 600;
  color: #ffffff;
  letter-spacing: 0.5px;
}

.loader-bar {
  width: 120px;
  height: 3px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.loader-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #a855f7, #38bdf8);
  border-radius: 2px;
  animation: loaderBarFill 1.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes slideInUp {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Order cards & bottom dock spacing fix */
.app { padding-bottom: calc(96px + env(safe-area-inset-bottom)) !important; }
.order-card {
  padding: 14px;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: var(--field);
  margin-bottom: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.order-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}
.order-card-header > div:last-child { text-align: right; flex-shrink: 0; }
.order-card-title { font-size: 14px; font-weight: 800; line-height: 1.3; }
.order-card-id { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.order-card-price { font-size: 13.5px; font-weight: 800; }
.order-card-status {
  display: inline-block;
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.08);
}
.order-card-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 8px;
  border-top: 1px solid var(--border);
}
.order-card-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
}
.order-card-label { color: var(--muted); }
.order-card-value { font-weight: 700; text-align: right; word-break: break-word; }
.order-card-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 2px;
}
.order-action-btn {
  padding: 9px 10px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--glass);
  color: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.order-action-btn.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--on-accent);
  border: none;
}
