:root {
  --bg-deep: #020617;
  --bg-main: #050607;
  --bg-soft: #0d1117;
  --bg-card: rgba(17, 24, 39, 0.90);
  --card-soft: rgba(12, 16, 22, 0.82);
  --primary: #38cfff;
  --primary-2: #1687ff;
  --primary-3: #3158f5;
  --cyan: #38cfff;
  --cyan-soft: #7dd3fc;
  --text-main: #f8fbff;
  --text-muted: #c4d3e3;
  --text-soft: #91a7bd;
  --border-glow: rgba(255, 255, 255, 0.08);
  --cyan-glow: rgba(56, 207, 255, 0.06);
  --blue-glow: rgba(37, 99, 235, 0.08);
  --green: #10b981;
  --danger: #ef4444;
  --stroke-strong: rgba(125, 211, 252, 0.20);
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.52), 0 0 36px rgba(37, 99, 235, 0.05);
  --radius-xl: 34px;
  --radius-lg: 26px;
  --radius-md: 18px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  box-sizing: border-box;
}

html {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  width: 100%;
  max-width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  font-family: "Anuphan", "Noto Sans Thai", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  background:
    radial-gradient(circle at 12% 16%, rgba(56, 189, 248, 0.14), transparent 26%),
    radial-gradient(circle at 28% 76%, rgba(168, 85, 247, 0.12), transparent 28%),
    radial-gradient(circle at 58% 18%, rgba(34, 197, 94, 0.08), transparent 24%),
    radial-gradient(circle at 78% 72%, rgba(236, 72, 153, 0.10), transparent 30%),
    radial-gradient(circle at 92% 24%, rgba(59, 130, 246, 0.13), transparent 28%),
    linear-gradient(135deg, #050607 0%, #0d1117 48%, #020617 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.022) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.022) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at center, black, transparent 76%);
  -webkit-mask-image: radial-gradient(circle at center, black, transparent 76%);
  opacity: 0.72;
}

.app-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(120deg,
      rgba(56, 189, 248, 0.08) 0%,
      rgba(168, 85, 247, 0.06) 32%,
      rgba(34, 197, 94, 0.045) 56%,
      rgba(236, 72, 153, 0.055) 78%,
      rgba(59, 130, 246, 0.08) 100%
    );
  opacity: 0.85;
}

button,
a,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ============================= */
/* COMMON COMPONENTS */
/* ============================= */

.primary-btn,
.ghost-btn,
.wallet-btn,
.icon-btn,
.shortcut-btn,
.modal-close {
  border: 0;
}

.primary-btn {
  min-height: 52px;
  padding: 0 22px;
  border-radius: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #ffffff;
  font-weight: 800;
  font-size: 0.98rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 48%, var(--primary-3) 100%);
  box-shadow:
    0 14px 34px rgba(22, 135, 255, 0.26),
    0 0 28px rgba(56, 207, 255, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.20);
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease), filter 0.22s var(--ease);
}

.primary-btn.full {
  width: 100%;
}

.primary-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow:
    0 18px 42px rgba(22, 135, 255, 0.32),
    0 0 34px rgba(56, 207, 255, 0.20),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.primary-btn:active,
.ghost-btn:active,
.shortcut-btn:active,
.wallet-btn:active,
.icon-btn:active {
  transform: scale(0.985);
}

.ghost-btn {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #dbeafe;
  font-weight: 700;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.76), rgba(8, 11, 16, 0.84));
  border: 1px solid var(--border-glow);
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease), background 0.22s var(--ease);
}

.ghost-btn:hover {
  border-color: var(--stroke-strong);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.022)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.86), rgba(8, 11, 16, 0.92));
}

.eyebrow {
  margin: 0 0 8px;
  color: #9edfff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ============================= */
/* AUTH PAGE */
/* ============================= */

.auth-body {
  min-height: 100vh;
}

.auth-page {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  width: 100%;
  display: grid;
  place-items: center;
  padding: clamp(18px, 4vw, 54px);
  overflow-x: hidden;
}

.auth-shell {
  width: min(1180px, 100%);
  min-height: clamp(500px, 55vh, 640px);
  border-radius: var(--radius-xl);
  padding: clamp(28px, 5vw, 72px);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(380px, 0.82fr);
  align-items: center;
  gap: clamp(34px, 6vw, 86px);
  background:
    radial-gradient(circle at 8% 12%, rgba(255, 255, 255, 0.04), transparent 34%),
    radial-gradient(circle at 94% 88%, rgba(37, 99, 235, 0.05), transparent 36%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.018)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid rgba(255, 255, 255, 0.085);
  box-shadow:
    0 28px 80px rgba(0, 0, 0, 0.52),
    0 0 36px rgba(56, 189, 248, 0.045),
    0 0 42px rgba(168, 85, 247, 0.035),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(10px) saturate(150%);
  -webkit-backdrop-filter: blur(10px) saturate(150%);
}

.auth-info,
.auth-card,
.auth-form,
.auth-heading,
.field,
.auth-benefits,
.auth-benefit,
.auth-options,
.auth-switch-text,
.auth-tabs,
.auth-tab {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.auth-logo {
  width: 62px;
  height: 54px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: 0;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.04)),
    linear-gradient(135deg, rgba(34, 211, 238, 0.28), rgba(10, 132, 255, 0.34));
  border: 1px solid rgba(140, 230, 255, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 18px 40px rgba(0, 0, 0, 0.32),
    0 0 24px rgba(10, 132, 255, 0.12);
}

.auth-kicker {
  width: max-content;
  max-width: 100%;
  min-height: 38px;
  margin-top: 18px;
  padding: 0 16px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  color: #dff7ff;
  font-size: 0.9rem;
  font-weight: 700;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.026)),
    rgba(34, 211, 238, 0.09);
  border: 1px solid rgba(120, 226, 255, 0.24);
}

.auth-info h1 {
  margin: 26px 0 12px;
  font-size: clamp(2.85rem, 5.2vw, 4.45rem);
  line-height: 1.02;
  letter-spacing: 0;
  color: var(--text-main);
  font-weight: 800;
  text-shadow: 0 1px 28px rgba(0, 0, 0, 0.32);
}

.auth-info p {
  max-width: 560px;
  margin: 0;
  color: #c6d1df;
  font-size: 1rem;
  line-height: 1.65;
  font-weight: 500;
  overflow-wrap: anywhere;
}

.auth-benefits {
  display: grid;
  gap: 11px;
  margin-top: 26px;
  max-width: 430px;
}

.auth-benefit {
  min-height: 50px;
  padding: 10px 14px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  gap: 11px;
  color: #edf7ff;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.72), rgba(8, 11, 16, 0.82));
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.auth-benefit span {
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: var(--cyan-soft);
  font-size: 0.95rem;
  font-weight: 800;
  background: rgba(34, 211, 238, 0.14);
  border: 1px solid rgba(120, 226, 255, 0.16);
}

.auth-benefit strong {
  font-size: 0.95rem;
  line-height: 1.35;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.auth-card {
  width: 100%;
  max-width: 460px;
  justify-self: end;
  padding: clamp(24px, 3vw, 34px);
  border-radius: 30px;
  overflow: hidden;
  color: var(--text-main);
  background:
    radial-gradient(circle at 16% 0%, rgba(255, 255, 255, 0.04), transparent 30%),
    radial-gradient(circle at 92% 100%, rgba(37, 99, 235, 0.05), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid rgba(255, 255, 255, 0.085);
  box-shadow:
    0 28px 80px rgba(0, 0, 0, 0.52),
    0 0 36px rgba(56, 189, 248, 0.045),
    0 0 42px rgba(168, 85, 247, 0.035),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(10px) saturate(155%);
  -webkit-backdrop-filter: blur(10px) saturate(155%);
}

.auth-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.10), transparent 38%),
    radial-gradient(circle at 0 0, rgba(34, 211, 238, 0.06), transparent 36%);
  opacity: 0.64;
}

.auth-tabs {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 62px;
  padding: 8px;
  border-radius: 22px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.010)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.82), rgba(8, 11, 16, 0.90));
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 8px 22px rgba(0, 0, 0, 0.22);
}

.auth-tabs::before {
  content: "";
  position: absolute;
  top: 7px;
  left: 7px;
  width: calc(50% - 7px);
  height: calc(100% - 14px);
  border-radius: 16px;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.25), transparent 30%),
    linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 50%, var(--primary-3) 100%);
  box-shadow:
    0 14px 34px rgba(22, 135, 255, 0.26),
    0 0 28px rgba(56, 207, 255, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.20);
  transition:
    transform 520ms cubic-bezier(0.16, 1, 0.3, 1),
    border-radius 520ms cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 520ms cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 0;
  pointer-events: none;
}

.auth-tabs.is-register::before {
  transform: translateX(100%);
}

.auth-tabs.is-switching::before {
  border-radius: 22px;
  box-shadow:
    0 20px 44px rgba(22, 135, 255, 0.32),
    0 0 40px rgba(56, 207, 255, 0.20),
    inset 0 1px 0 rgba(255, 255, 255, 0.24);
}

.auth-tab {
  position: relative;
  z-index: 1;
  border: 0;
  border-radius: 17px;
  color: #c4d3e3;
  font-weight: 800;
  background: transparent !important;
  box-shadow: none !important;
  transition:
    color 300ms ease,
    opacity 300ms ease,
    transform 180ms ease;
}

.auth-tab.active {
  color: #ffffff;
  background: transparent !important;
  box-shadow: none !important;
}

.auth-tab:not(.active) {
  color: #c4d3e3;
  opacity: 0.82;
}

.auth-tab:active {
  transform: scale(0.985);
}

.auth-form-stage {
  position: relative;
  min-height: 540px;
  margin-top: 34px;
  overflow: visible;
}

.auth-form {
  position: absolute;
  inset: 0;
  display: grid;
  gap: 15px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(18px) scale(0.985);
  transition:
    opacity 460ms cubic-bezier(0.16, 1, 0.3, 1),
    transform 520ms cubic-bezier(0.16, 1, 0.3, 1),
    visibility 0s linear 520ms;
  will-change: opacity, transform;
}

.auth-form.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
  transition:
    opacity 460ms cubic-bezier(0.16, 1, 0.3, 1),
    transform 520ms cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes formItemIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.auth-form.active .auth-heading,
.auth-form.active .field,
.auth-form.active .auth-options,
.auth-form.active .primary-btn,
.auth-form.active .auth-switch-text {
  animation: formItemIn 260ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.auth-form.active .auth-heading    { animation-delay: 40ms; }
.auth-form.active .field:nth-of-type(1) { animation-delay: 80ms; }
.auth-form.active .field:nth-of-type(2) { animation-delay: 110ms; }
.auth-form.active .field:nth-of-type(3) { animation-delay: 140ms; }
.auth-form.active .auth-options    { animation-delay: 160ms; }
.auth-form.active .primary-btn     { animation-delay: 190ms; }
.auth-form.active .auth-switch-text { animation-delay: 220ms; }

.auth-heading h2 {
  margin: 0 0 8px;
  color: var(--text-main);
  font-size: clamp(1.75rem, 2.5vw, 2.15rem);
  letter-spacing: 0;
  line-height: 1.12;
  font-weight: 700;
}

.auth-heading p {
  margin: 0;
  color: var(--text-muted);
  font-weight: 500;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.field {
  display: grid;
  gap: 8px;
  color: #d9e7f7;
  font-weight: 700;
}

.field input {
  width: 100%;
  min-height: 52px;
  border-radius: 16px;
  padding: 0 16px;
  outline: none;
  color: var(--text-main);
  font-size: 0.96rem;
  font-weight: 500;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.008)),
    linear-gradient(135deg, rgba(5, 8, 13, 0.92), rgba(3, 5, 8, 0.96));
  border: 1px solid rgba(255, 255, 255, 0.075);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.035),
    0 6px 16px rgba(0, 0, 0, 0.24);
  transition: border-color 0.22s var(--ease), box-shadow 0.22s var(--ease), background 0.22s var(--ease);
}

.field input::placeholder {
  color: var(--text-soft);
}

.field input:focus {
  border-color: rgba(56, 189, 248, 0.42);
  box-shadow:
    0 0 0 4px rgba(56, 189, 248, 0.10),
    0 0 24px rgba(22, 135, 255, 0.10),
    0 0 20px rgba(168, 85, 247, 0.06),
    0 10px 28px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.auth-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--text-muted);
  font-size: 0.94rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.remember-check {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  white-space: nowrap;
  min-width: 0;
  cursor: pointer;
}

.remember-check input {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
}

.auth-options a,
.auth-switch-text button {
  color: var(--cyan-soft);
  text-decoration: none;
  font-weight: 800;
  background: none;
  border: 0;
  padding: 0;
}

.auth-options a {
  white-space: nowrap;
  flex-shrink: 0;
  text-align: right;
}

.auth-switch-text {
  margin: 0 0 4px;
  padding-bottom: 4px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.94rem;
  font-weight: 600;
  line-height: 1.5;
}


/* ============================= */
/* APP / DASHBOARD */
/* ============================= */

.app-shell {
  position: relative;
  z-index: 1;
  width: min(1120px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 22px;
  display: grid;
  gap: 22px;
}

.summary-grid,
.shortcut-grid {
  display: none !important;
}

.topbar {
  position: sticky;
  top: 14px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  min-height: 76px;
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.018)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid var(--border-glow);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.44),
    0 0 24px rgba(37, 99, 235, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-mark {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 900;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.28), rgba(10, 132, 255, 0.34));
  border: 1px solid rgba(120, 226, 255, 0.18);
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 1.02rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.brand small {
  margin-top: 2px;
  color: var(--cyan-soft);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.18em;
}

.top-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.wallet-btn,
.icon-btn {
  min-height: 44px;
  border-radius: 15px;
  color: #e5edff;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.80), rgba(8, 11, 16, 0.88));
  border: 1px solid var(--border-glow);
  transition: transform 180ms var(--ease), border-color 180ms var(--ease);
}

.wallet-btn {
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
}

.wallet-btn span {
  color: var(--cyan-soft);
}

.icon-btn {
  width: 48px;
  display: grid;
  place-items: center;
  gap: 4px;
  padding: 11px 0;
}

.icon-btn span {
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: #e5edff;
  transition:
    transform 180ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 140ms ease;
  will-change: transform, opacity;
}

.icon-btn.is-open span:nth-child(1) {
  transform: translate3d(0, 7px, 0) rotate(45deg);
}

.icon-btn.is-open span:nth-child(2) {
  opacity: 0;
}

.icon-btn.is-open span:nth-child(3) {
  transform: translate3d(0, -7px, 0) rotate(-45deg);
}

.hero-card,
.stat-card,
.shortcut-btn,
.promo-section,
.products-section,
.product-card,
.product-detail,
.modal-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.018)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid rgba(255, 255, 255, 0.085);
  box-shadow:
    0 28px 80px rgba(0, 0, 0, 0.52),
    0 0 36px rgba(56, 189, 248, 0.045),
    0 0 42px rgba(168, 85, 247, 0.035),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(10px) saturate(145%);
  -webkit-backdrop-filter: blur(10px) saturate(145%);
}

.hero-card {
  border-radius: 28px;
  padding: clamp(22px, 4vw, 36px);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
}

.hero-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
}

.hero-stat-card {
  min-height: 150px;
  padding: 22px 20px;
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.07), rgba(255,255,255,0.02)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow:
    0 20px 50px rgba(0,0,0,0.35),
    0 0 28px rgba(56, 189, 248, 0.05),
    inset 0 1px 0 rgba(255,255,255,0.06);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  transition: transform 0.25s var(--ease), border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.hero-stat-card:hover {
  transform: translateY(-3px);
  border-color: rgba(125, 211, 252, 0.16);
  box-shadow:
    0 24px 60px rgba(0,0,0,0.42),
    0 0 30px rgba(56, 189, 248, 0.08),
    inset 0 1px 0 rgba(255,255,255,0.06);
}

.hero-stat-label {
  font-size: 0.95rem;
  color: #9ec7e8;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.hero-stat-value {
  font-size: 1.9rem;
  line-height: 1;
  color: #f8fbff;
  font-weight: 900;
}

.hero-stat-sub {
  font-size: 0.75rem;
  color: #91a7bd;
  font-weight: 600;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.summary-grid .stat-card {
  min-height: 126px;
  border-radius: 24px;
  padding: 18px;
  display: grid;
  gap: 8px;
}

.stat-icon,
.shortcut-btn span {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--cyan-soft);
  font-weight: 900;
  background: rgba(34, 211, 238, 0.12);
  border: 1px solid rgba(120, 226, 255, 0.14);
}

.summary-grid .stat-card small {
  color: var(--text-muted);
  font-weight: 600;
}

.summary-grid .stat-card strong {
  font-size: 1.18rem;
}

.shortcut-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.shortcut-btn {
  min-height: 100px;
  border-radius: 22px;
  padding: 16px 10px;
  display: grid;
  place-items: center;
  gap: 10px;
  color: #e5edff;
  font-weight: 800;
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease), background 0.22s var(--ease);
}

.shortcut-btn:hover {
  transform: translateY(-2px);
  border-color: rgba(125, 211, 252, 0.16);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.48),
    0 0 32px rgba(56, 189, 248, 0.08),
    0 0 30px rgba(168, 85, 247, 0.055);
}

.promo-section,
.products-section,
.product-detail {
  border-radius: 28px;
  padding: 20px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.section-head h2 {
  margin: 0;
  font-size: 1.35rem;
}

.section-head > span,
.section-head a {
  color: var(--cyan-soft);
  font-size: 0.9rem;
  font-weight: 800;
}

.promo-slider {
  position: relative;
  min-height: 230px;
  overflow: hidden;
  border-radius: 24px;
}

.promo-card {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: clamp(20px, 4vw, 34px);
  color: #ffffff;
  background:
    radial-gradient(circle at 14% 14%, rgba(34, 211, 238, 0.30), transparent 32%),
    radial-gradient(circle at 86% 88%, rgba(37, 99, 235, 0.42), transparent 40%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(3, 7, 18, 0.98));
  opacity: 0;
  visibility: hidden;
  transform: translateX(18px) scale(0.99);
  transition: opacity 260ms var(--ease), transform 260ms var(--ease), visibility 0s linear 260ms;
}

.promo-card.active {
  opacity: 1;
  visibility: visible;
  transform: translateX(0) scale(1);
  transition-delay: 0s;
}

.promo-tag {
  display: inline-flex;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  align-items: center;
  color: #c7f9ff;
  font-size: 0.78rem;
  font-weight: 900;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.promo-card h3 {
  margin: 14px 0 8px;
  font-size: clamp(1.8rem, 5vw, 3.4rem);
  line-height: 1;
}

.promo-card p {
  margin: 0;
  color: #cbd5e1;
}

.promo-art {
  width: min(32vw, 170px);
  aspect-ratio: 1;
  border-radius: 32px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: clamp(2rem, 6vw, 4rem);
  font-weight: 900;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.28), rgba(37, 99, 235, 0.42));
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.slider-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}

.slider-dots button {
  width: 8px;
  height: 8px;
  border: 0;
  border-radius: 999px;
  padding: 0;
  background: rgba(255, 255, 255, 0.22);
  transition: width 0.25s var(--ease), background 0.25s var(--ease);
}

.slider-dots button.active {
  width: 28px;
  background: linear-gradient(135deg, var(--cyan), var(--primary-3));
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.product-card {
  border-radius: 22px;
  padding: 16px;
  display: grid;
  gap: 12px;
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease);
}

.product-card:hover {
  transform: translateY(-2px);
  border-color: rgba(125, 211, 252, 0.16);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.48),
    0 0 32px rgba(56, 189, 248, 0.08),
    0 0 30px rgba(168, 85, 247, 0.055);
}

.product-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.product-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: var(--cyan-soft);
  font-weight: 900;
  background: rgba(34, 211, 238, 0.12);
  border: 1px solid rgba(120, 226, 255, 0.14);
}

.product-card h3 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.35;
}

.product-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
}

.product-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.price {
  color: #ffffff;
  font-size: 1.25rem;
  font-weight: 900;
}

.buy-btn {
  min-height: 40px;
  padding: 0 14px;
  border: 0;
  border-radius: 13px;
  color: #ffffff;
  font-weight: 800;
  background: linear-gradient(135deg, var(--cyan), var(--primary-3));
}

.product-detail {
  display: grid;
  grid-template-columns: 0.75fr 1fr;
  gap: 24px;
  align-items: stretch;
}

.detail-art {
  min-height: 360px;
  border-radius: 26px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: clamp(3rem, 10vw, 6rem);
  font-weight: 900;
  background:
    radial-gradient(circle at 20% 20%, rgba(56, 189, 248, 0.16), transparent 32%),
    radial-gradient(circle at 80% 80%, rgba(37, 99, 235, 0.14), transparent 34%),
    linear-gradient(135deg, #112240, #051024);
  border: 1px solid var(--border-glow);
}

.detail-info {
  display: grid;
  align-content: center;
  gap: 16px;
}

.detail-info h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.1;
}

.detail-info p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.65;
}

.detail-list {
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.detail-list li {
  padding: 12px 14px;
  border-radius: 15px;
  color: #dbeafe;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.016)),
    linear-gradient(135deg, rgba(12, 18, 30, 0.58), rgba(6, 10, 20, 0.68));
  border: 1px solid var(--border-glow);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(3, 7, 18, 0.62);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 180ms var(--ease), visibility 0s linear 180ms;
}

.modal.show {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition-delay: 0s;
}

.modal-panel {
  width: min(440px, 100%);
  border-radius: 26px;
  padding: 24px;
  position: relative;
  transform: translateY(12px) scale(0.98);
  transition: transform 180ms var(--ease);
}

.modal.show .modal-panel {
  transform: translateY(0) scale(1);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  color: #ffffff;
  font-size: 1.4rem;
  background: rgba(255, 255, 255, 0.08);
}

.modal-panel h2 {
  margin: 0 0 10px;
}

.modal-panel p:not(.eyebrow) {
  color: var(--text-muted);
  line-height: 1.6;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

/* ============================= */
/* RESPONSIVE */
/* ============================= */

@media (max-width: 960px) {
  .auth-shell {
    grid-template-columns: 1fr;
    gap: 34px;
    min-height: auto;
  }

  .auth-info {
    text-align: center;
    display: grid;
    justify-items: center;
  }

  .auth-benefits {
    width: 100%;
  }

  .auth-card {
    justify-self: center;
  }

  .summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .product-detail {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .auth-page {
    min-height: 100vh;
    padding: 18px;
    place-items: start center;
  }

  .auth-shell {
    width: min(100%, 680px);
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 22px;
    padding: 24px;
    border-radius: 28px;
    overflow: hidden;
  }

  .auth-info h1 {
    margin: 20px 0 10px;
    font-size: clamp(2.25rem, 9vw, 3rem);
    line-height: 1.04;
  }

  .auth-info p {
    max-width: 520px;
    font-size: 0.94rem;
    line-height: 1.55;
  }

  .auth-benefits {
    gap: 8px;
    margin-top: 18px;
    max-width: 100%;
  }

  .auth-benefit {
    min-height: 44px;
    padding: 8px 12px;
  }

  .auth-card {
    width: 100%;
    max-width: 430px;
    padding: 22px;
    border-radius: 24px;
  }

  .auth-form-stage {
    margin-top: 24px;
    min-height: 500px;
  }

  .app-shell {
    padding: 16px;
  }

  .hero-card {
    align-items: stretch;
    flex-direction: column;
  }

  .promo-slider {
    min-height: 210px;
  }
}

@media (max-width: 560px) {
  body {
    background:
      radial-gradient(circle at 10% 10%, rgba(56, 189, 248, 0.10), transparent 24%),
      radial-gradient(circle at 28% 78%, rgba(168, 85, 247, 0.08), transparent 26%),
      radial-gradient(circle at 78% 18%, rgba(59, 130, 246, 0.10), transparent 26%),
      radial-gradient(circle at 88% 88%, rgba(236, 72, 153, 0.07), transparent 28%),
      linear-gradient(135deg, #050607 0%, #0d1117 50%, #020617 100%);
  }

  .auth-page {
    padding: 14px;
  }

  .auth-shell {
    gap: 18px;
    padding: 18px;
    border-radius: 26px;
    overflow: hidden;
  }

  .auth-logo {
    width: 56px;
    height: 48px;
    border-radius: 16px;
    font-size: 0.92rem;
  }

  .auth-kicker {
    min-height: 34px;
    margin-top: 13px;
    padding: 0 12px;
    font-size: 0.8rem;
  }

  .auth-info h1 {
    margin: 16px 0 9px;
    font-size: clamp(2rem, 10vw, 2.42rem);
  }

  .auth-info p {
    font-size: 0.88rem;
    line-height: 1.48;
  }

  .auth-benefit {
    min-height: 40px;
    padding: 7px 10px;
    border-radius: 18px;
  }

  .auth-benefit strong {
    font-size: 0.82rem;
  }

  .auth-card {
    padding: 18px 18px 22px;
    border-radius: 24px;
    overflow: hidden;
  }

  .auth-form-stage {
    margin-top: 18px;
    min-height: 560px;
  }

  .auth-tabs {
    min-height: 52px;
    border-radius: 20px;
  }

  .auth-tab {
    border-radius: 16px;
    font-size: 0.9rem;
  }

  .auth-tabs::before {
    border-radius: 16px;
  }

  .auth-tabs.is-switching::before {
    border-radius: 20px;
  }

  .auth-form {
    gap: 14px;
  }

  .auth-heading h2 {
    font-size: 1.55rem;
  }

  .auth-heading p,
  .field,
  .auth-options,
  .auth-switch-text {
    font-size: 0.9rem;
  }

  .auth-options {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    flex-wrap: nowrap;
  }

  .field input,
  .primary-btn {
    min-height: 50px;
  }

  .field input {
    padding: 0 14px;
    font-size: 0.95rem;
    border-radius: 17px;
  }

  .primary-btn {
    border-radius: 18px;
    font-size: 0.98rem;
  }

  .brand strong {
    font-size: 0.94rem;
  }

  .brand small {
    font-size: 0.58rem;
  }

  .wallet-btn strong {
    display: none;
  }

  .topbar {
    padding: 14px 14px;
    min-height: 64px;
    gap: 10px;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
    min-width: 38px;
    font-size: 0.7rem;
    border-radius: 12px;
  }

  .brand strong {
    font-size: 0.85rem;
  }

  .brand small {
    font-size: 0.5rem;
    letter-spacing: 0.1em;
  }

  .wallet-btn {
    min-height: 38px;
    padding: 0 10px;
    font-size: 0.85rem;
  }

  .icon-btn {
    width: 40px;
    min-height: 38px;
  }

  .icon-btn span {
    width: 16px;
    height: 2px;
  }

  .hero-stats-grid,
  .stats-grid {
    gap: 12px;
    max-width: 100%;
  }

  .hero-stat-card,
  .stat-card {
    min-height: 108px;
    padding: 14px 12px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
  }

  .hero-stat-card:hover,
  .stat-card:hover {
    transform: none !important;
  }

  .hero-stat-label,
  .stat-label {
    display: block;
    font-size: 0.78rem;
    line-height: 1.25;
    color: #bfe5ff;
    font-weight: 800;
    margin-bottom: 8px;
  }

  .hero-stat-value,
  .stat-value {
    display: block;
    font-size: 1.35rem;
    line-height: 1;
    color: #f8fbff;
    font-weight: 900;
    margin-bottom: 6px;
  }

  .hero-stat-sub,
  .stat-meta {
    display: block;
    font-size: 0.72rem;
    line-height: 1.25;
    color: rgba(225, 235, 245, 0.68);
    font-weight: 600;
  }

  .summary-grid,
  .shortcut-grid,
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .shortcut-btn {
    min-height: 90px;
  }

  .promo-card {
    align-items: flex-start;
  }

  .promo-art {
    width: 94px;
    border-radius: 22px;
  }

  .product-card {
    padding: 14px;
  }

  .product-meta {
    align-items: stretch;
    flex-direction: column;
  }

  .buy-btn {
    width: 100%;
  }

  .modal-actions {
    flex-direction: column;
  }

  .menu-user-card {
    padding: 12px;
    gap: 10px;
    border-radius: 18px;
  }

  .menu-user-avatar {
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 14px;
  }

  .menu-user-name,
  .menu-user-balance strong {
    font-size: 0.86rem;
  }

  .menu-user-label,
  .menu-user-balance span {
    font-size: 0.68rem;
  }

  .side-menu {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(10, 14, 23, 0.98);
  }

  .menu-backdrop {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(0,0,0,0.42);
  }

  .hero-stat-card,
  .profile-card,
  .profile-hero-card,
  .profile-save-btn,
  .logout-danger-btn,
  .promo-section,
  .products-section {
    animation-delay: 0ms !important;
  }

  .hero-stat-card:hover,
  .product-card:hover {
    transform: none !important;
  }
}

@media (max-width: 430px) {
  .auth-page {
    padding: 12px;
  }

  .auth-shell {
    padding: 15px;
    gap: 15px;
    border-radius: 22px;
    overflow: hidden;
  }

  .auth-info h1 {
    font-size: clamp(1.86rem, 9.3vw, 2.2rem);
  }

  .auth-info p {
    font-size: 0.84rem;
  }

  .auth-benefit span {
    width: 26px;
    height: 26px;
    min-width: 26px;
  }

  .auth-card {
    padding: 15px;
    border-radius: 22px;
  }

  .auth-form-stage {
    margin-top: 15px;
    min-height: 545px;
  }

  .auth-form {
    gap: 11px;
  }

  .auth-tabs {
    min-height: 48px;
    border-radius: 18px;
  }

  .auth-tab {
    font-size: 0.84rem;
    border-radius: 14px;
  }

  .auth-tabs::before {
    border-radius: 14px;
  }

  .auth-tabs.is-switching::before {
    border-radius: 18px;
  }

  .auth-heading h2 {
    font-size: 1.42rem;
  }

  .field input,
  .primary-btn {
    min-height: 48px;
  }

  .field input {
    border-radius: 16px;
  }

  .primary-btn {
    border-radius: 17px;
  }

  .auth-options {
    font-size: 0.82rem;
    gap: 8px;
  }

  .remember-check input {
    width: 17px;
    height: 17px;
  }

  .auth-benefit {
    border-radius: 16px;
  }

  .app-shell {
    padding: 12px;
    gap: 16px;
  }

  .topbar {
    top: 10px;
    padding: 12px 12px;
    min-height: 58px;
    gap: 8px;
    border-radius: 18px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
    min-width: 34px;
    font-size: 0.65rem;
    border-radius: 11px;
  }

  .brand strong {
    font-size: 0.8rem;
  }

  .brand small {
    font-size: 0.48rem;
    letter-spacing: 0.08em;
  }

  .wallet-btn {
    min-height: 34px;
    padding: 0 8px;
    font-size: 0.8rem;
  }

  .icon-btn {
    width: 36px;
    min-height: 34px;
  }

  .icon-btn span {
    width: 14px;
    height: 2px;
  }

  .hero-stats-grid,
  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .hero-stat-card,
  .stat-card {
    min-height: 100px;
    padding: 12px 10px;
    gap: 6px;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .hero-stat-label,
  .stat-label {
    font-size: 0.72rem;
    margin-bottom: 6px;
  }

  .hero-stat-value,
  .stat-value {
    font-size: 1.22rem;
    margin-bottom: 4px;
  }

  .hero-stat-sub,
  .stat-meta {
    font-size: 0.65rem;
  }

  .hero-card,
  .promo-section,
  .products-section,
  .product-detail {
    border-radius: 22px;
    padding: 16px;
  }

  .summary-grid .stat-card {
    min-height: 112px;
    padding: 14px;
    border-radius: 20px;
  }

  .summary-grid .stat-card strong {
    font-size: 1rem;
  }
}

@media (max-width: 390px) {
  .auth-page {
    padding: 10px;
  }

  .auth-shell {
    padding: 13px;
    gap: 13px;
    border-radius: 20px;
    overflow: hidden;
  }

  .auth-info h1 {
    font-size: 1.95rem;
  }

  .auth-benefit strong {
    font-size: 0.78rem;
  }

  .auth-benefit {
    border-radius: 15px;
  }

  .auth-card {
    padding: 13px;
    border-radius: 20px;
  }

  .auth-form-stage {
    margin-top: 13px;
    min-height: 540px;
  }

  .auth-tabs {
    border-radius: 17px;
  }

  .auth-tab {
    font-size: 0.8rem;
    border-radius: 13px;
  }

  .auth-tabs::before {
    border-radius: 13px;
  }

  .auth-tabs.is-switching::before {
    border-radius: 17px;
  }

  .field input {
    padding: 0 12px;
    border-radius: 15px;
  }

  .primary-btn {
    border-radius: 16px;
  }

  .auth-switch-text {
    line-height: 1.5;
  }

  .auth-options {
    font-size: 0.8rem;
  }

  .hero-stats-grid,
  .stats-grid {
    gap: 10px;
  }

  .hero-stat-card,
  .stat-card {
    min-height: 96px;
    padding: 10px 10px;
  }

  .hero-stat-value,
  .stat-value {
    font-size: 1.15rem;
  }
}

/* ============================= */
/* SIDE MENU (Hamburger Drawer)  */
/* ============================= */

.side-menu {
  position: fixed;
  top: 18px;
  right: 18px;
  width: min(340px, calc(100vw - 32px));
  padding: 18px;
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.065), rgba(255,255,255,0.018)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid rgba(255,255,255,0.085);
  box-shadow:
    0 30px 80px rgba(0,0,0,0.45),
    0 0 36px rgba(56, 189, 248, 0.045),
    inset 0 1px 0 rgba(255,255,255,0.06);
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translate3d(16px, 0, 0);
  contain: layout paint;
  will-change: transform, opacity;
  transition:
    opacity 180ms ease,
    transform 220ms cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 220ms;
}

.side-menu.is-open {
  opacity: 1;
  visibility: visible;
  transform: translate3d(0, 0, 0);
  transition:
    opacity 180ms ease,
    transform 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

.side-menu__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  color: #f8fbff;
}

.side-menu__header strong {
  font-size: 1.05rem;
  font-weight: 900;
}

.side-menu__header span {
  color: #91a7bd;
  font-size: 0.82rem;
  font-weight: 700;
}

.menu-user-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  margin: 0 0 16px;
  border-radius: 20px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.075), rgba(255,255,255,0.025)),
    rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow:
    0 18px 44px rgba(0,0,0,0.28),
    inset 0 1px 0 rgba(255,255,255,0.08);
}

.menu-user-avatar {
  width: 46px;
  height: 46px;
  min-width: 46px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #ffffff;
  background: linear-gradient(135deg, #38cfff 0%, #1687ff 48%, #3158f5 100%);
  box-shadow: 0 12px 26px rgba(22, 135, 255, 0.22);
}

.menu-user-info {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.menu-user-label,
.menu-user-balance span {
  font-size: 0.72rem;
  color: #91a7bd;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.menu-user-name,
.menu-user-balance strong {
  color: #f8fbff;
  font-size: 0.92rem;
  font-weight: 900;
  white-space: nowrap;
}

.menu-user-balance {
  margin-left: auto;
  padding-left: 12px;
  border-left: 1px solid rgba(255,255,255,0.10);
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: right;
}

.menu-user-balance strong {
  color: #7dd3fc;
}

.side-menu__section {
  padding: 12px;
  border-radius: 18px;
  background: rgba(255,255,255,0.035);
  border: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 12px;
}

.side-menu__title {
  margin: 0 0 8px;
  color: #91a7bd;
  font-size: 0.82rem;
  font-weight: 700;
}

.side-menu a,
.logout-btn {
  width: 100%;
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 0 12px;
  border-radius: 14px;
  color: #f8fbff;
  text-decoration: none;
  font-weight: 700;
  transition: background 200ms ease, transform 180ms ease;
}

.side-menu a:hover {
  background: rgba(56, 189, 248, 0.10);
  transform: translateX(2px);
}

.logout-btn {
  border: 0;
  background: rgba(239, 68, 68, 0.10);
  color: #fecaca;
  cursor: pointer;
  justify-content: center;
  margin-top: 4px;
}

.logout-btn:hover {
  background: rgba(239, 68, 68, 0.18);
}

.menu-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.42);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 160ms ease,
    visibility 0s linear 160ms;
}

.menu-backdrop.is-open {
  opacity: 1;
  visibility: visible;
  transition: opacity 160ms ease;
}

/* ============================= */
/* PROFILE PAGE */
/* ============================= */

.profile-shell {
  position: relative;
  z-index: 1;
  width: min(840px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 24px;
  display: grid;
  gap: 18px;
}

.profile-topbar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.065), rgba(255,255,255,0.018)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid var(--border-glow);
  box-shadow:
    0 20px 50px rgba(0,0,0,0.44),
    0 0 24px rgba(37, 99, 235, 0.04),
    inset 0 1px 0 rgba(255,255,255,0.06);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
}

.back-btn {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border: 0;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: #e5edff;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.06), rgba(255,255,255,0.015)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.80), rgba(8, 11, 16, 0.88));
  border: 1px solid var(--border-glow);
  cursor: pointer;
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease);
}

.back-btn:hover {
  border-color: var(--stroke-strong);
}

.back-btn:active {
  transform: scale(0.985);
}

.back-btn svg {
  display: block;
}

.profile-topbar h1 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 900;
}

.profile-hero-card {
  border-radius: 28px;
  padding: clamp(24px, 4vw, 36px);
  display: flex;
  align-items: center;
  gap: 20px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.065), rgba(255,255,255,0.018)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid rgba(255,255,255,0.085);
  box-shadow:
    0 28px 80px rgba(0,0,0,0.52),
    0 0 36px rgba(56, 189, 248, 0.045),
    inset 0 1px 0 rgba(255,255,255,0.06);
  backdrop-filter: blur(10px) saturate(145%);
  -webkit-backdrop-filter: blur(10px) saturate(145%);
}

.profile-avatar {
  width: 80px;
  height: 80px;
  min-width: 80px;
  border: 0;
  border-radius: 24px;
  display: grid;
  place-items: center;
  font-size: 2rem;
  font-weight: 900;
  color: #ffffff;
  cursor: pointer;
  background: linear-gradient(135deg, #38cfff 0%, #1687ff 48%, #3158f5 100%);
  box-shadow:
    0 18px 40px rgba(22, 135, 255, 0.28),
    inset 0 1px 0 rgba(255,255,255,0.18);
  transition: filter 180ms var(--ease);
}

.profile-avatar:hover {
  filter: brightness(1.1);
}

.profile-hero-info {
  min-width: 0;
}

.profile-hero-info h2 {
  margin: 0 0 4px;
  font-size: 1.25rem;
  font-weight: 900;
}

.profile-hero-info > p {
  margin: 0 0 8px;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  word-break: break-all;
}

.profile-status-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.50);
}

.status-text {
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 700;
}

.status-divider {
  width: 1px;
  height: 14px;
  background: rgba(255,255,255,0.12);
}

.change-avatar-text {
  color: var(--cyan-soft);
  font-size: 0.78rem;
  font-weight: 700;
}

.profile-card {
  border-radius: 26px;
  padding: 24px;
  display: grid;
  gap: 16px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.065), rgba(255,255,255,0.018)),
    linear-gradient(135deg, rgba(17, 24, 39, 0.90), rgba(8, 11, 16, 0.94));
  border: 1px solid rgba(255,255,255,0.085);
  box-shadow:
    0 28px 80px rgba(0,0,0,0.52),
    0 0 36px rgba(56, 189, 248, 0.045),
    inset 0 1px 0 rgba(255,255,255,0.06);
  backdrop-filter: blur(10px) saturate(145%);
  -webkit-backdrop-filter: blur(10px) saturate(145%);
}

.profile-section-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.profile-section-header .section-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--cyan-soft);
  background: rgba(34, 211, 238, 0.12);
  border: 1px solid rgba(120, 226, 255, 0.14);
  margin-top: 2px;
}

.profile-section-header div {
  min-width: 0;
}

.profile-section-header h3 {
  margin: 0 0 4px;
  font-size: 1.05rem;
  font-weight: 900;
}

.profile-section-header p {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.85rem;
  line-height: 1.55;
}

.profile-field {
  display: grid;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #d9e7f7;
}

.profile-field small {
  display: block;
  color: var(--text-soft);
  font-size: 0.78rem;
  font-weight: 600;
  margin-top: -4px;
}

.profile-input-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 0 16px;
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.008)),
    linear-gradient(135deg, rgba(5, 8, 13, 0.92), rgba(3, 5, 8, 0.96));
  border: 1px solid rgba(255,255,255,0.075);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.035),
    0 6px 16px rgba(0,0,0,0.24);
  transition: border-color 0.22s var(--ease), box-shadow 0.22s var(--ease);
}

.profile-input-wrap:focus-within {
  border-color: rgba(56, 189, 248, 0.42);
  box-shadow:
    0 0 0 4px rgba(56, 189, 248, 0.10),
    0 0 24px rgba(22, 135, 255, 0.10),
    0 10px 28px rgba(0,0,0,0.28),
    inset 0 1px 0 rgba(255,255,255,0.05);
}

.profile-input-wrap .input-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  opacity: 0.5;
  color: var(--cyan-soft);
}

.profile-input-wrap .input-icon svg {
  display: block;
}

.profile-input-wrap input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  outline: none;
  color: var(--text-main);
  font-size: 0.95rem;
  font-weight: 500;
  padding: 14px 0;
}

.profile-input-wrap input::placeholder {
  color: var(--text-soft);
}

.profile-input-wrap input:read-only {
  opacity: 0.55;
}

.password-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 0 12px 0 16px;
}

.password-wrap input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: 0;
  outline: none;
  color: var(--text-main);
  font-size: 0.95rem;
  font-weight: 500;
  padding: 14px 0;
}

.password-wrap input::placeholder {
  color: var(--text-soft);
}

.toggle-password {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #c8d6e5;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.04),
    0 8px 20px rgba(0,0,0,0.20);
  transition:
    transform 180ms ease,
    background 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease,
    color 180ms ease;
  cursor: pointer;
}

.toggle-password svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 1.9;
  fill: none;
  display: block;
}

.toggle-password:hover {
  color: #eef6ff;
  border-color: rgba(125, 211, 252, 0.22);
  background: linear-gradient(180deg, rgba(56,189,248,0.08), rgba(37,99,235,0.06));
  box-shadow:
    0 10px 24px rgba(0,0,0,0.24),
    0 0 0 3px rgba(56,189,248,0.06);
}

.toggle-password:active {
  transform: scale(0.97);
}

.toggle-password:focus-visible {
  outline: none;
  border-color: rgba(56,189,248,0.34);
  box-shadow:
    0 0 0 4px rgba(56,189,248,0.10),
    0 10px 24px rgba(0,0,0,0.24);
}

.profile-save-btn {
  width: 100%;
  min-height: 56px;
  border: 0;
  border-radius: 18px;
  color: #ffffff;
  font-weight: 800;
  font-size: 1.02rem;
  cursor: pointer;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 48%, var(--primary-3) 100%);
  box-shadow:
    0 14px 34px rgba(22, 135, 255, 0.26),
    0 0 28px rgba(56, 207, 255, 0.16),
    inset 0 1px 0 rgba(255,255,255,0.20);
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease), filter 0.22s var(--ease);
}

.profile-save-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow:
    0 18px 42px rgba(22, 135, 255, 0.32),
    0 0 34px rgba(56, 207, 255, 0.20),
    inset 0 1px 0 rgba(255,255,255,0.22);
}

.profile-save-btn:active {
  transform: scale(0.985);
}

.profile-save-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}



.logout-danger-btn {
  width: 100%;
  min-height: 56px;
  border: 0;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #fecaca;
  font-weight: 800;
  font-size: 1.02rem;
  cursor: pointer;
  background: rgba(239, 68, 68, 0.10);
  border: 1px solid rgba(239, 68, 68, 0.15);
  transition: transform 0.22s var(--ease), background 0.22s var(--ease);
}

.logout-danger-btn svg {
  display: block;
}

.logout-danger-btn:hover {
  background: rgba(239, 68, 68, 0.18);
}

.logout-danger-btn:active {
  transform: scale(0.985);
}

@media (max-width: 680px) {
  .profile-shell {
    padding: 16px;
    gap: 16px;
  }

  .profile-topbar {
    padding: 14px;
    border-radius: 20px;
  }

  .back-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
  }

  .profile-topbar h1 {
    font-size: 1.05rem;
  }

  .profile-hero-card {
    padding: 20px;
    gap: 16px;
  }

  .profile-avatar {
    width: 64px;
    height: 64px;
    min-width: 64px;
    border-radius: 20px;
    font-size: 1.6rem;
  }

  .profile-hero-info h2 {
    font-size: 1.1rem;
  }

  .profile-hero-info > p {
    font-size: 0.78rem;
  }

  .profile-card {
    padding: 20px;
    gap: 14px;
  }

  .profile-input-wrap {
    min-height: 52px;
  }

  .profile-input-wrap input {
    font-size: 0.92rem;
    padding: 12px 0;
  }

  .password-wrap {
    min-height: 52px;
    padding: 0 10px 0 14px;
    gap: 10px;
  }

  .password-wrap input {
    font-size: 0.92rem;
    padding: 12px 0;
  }

  .toggle-password {
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 13px;
  }

  .toggle-password svg {
    width: 18px;
    height: 18px;
  }

}

@media (max-width: 430px) {
  .profile-shell {
    padding: 12px;
    gap: 14px;
  }

  .profile-topbar {
    padding: 12px;
    border-radius: 18px;
    gap: 10px;
  }

  .back-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 12px;
  }

  .back-btn svg {
    width: 18px;
    height: 18px;
  }

  .profile-topbar h1 {
    font-size: 0.95rem;
  }

  .profile-hero-card {
    padding: 16px;
    gap: 14px;
  }

  .profile-avatar {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 18px;
    font-size: 1.4rem;
  }

  .profile-hero-info h2 {
    font-size: 1rem;
  }

  .profile-hero-info > p {
    font-size: 0.75rem;
  }

  .profile-card {
    padding: 18px;
    gap: 12px;
    border-radius: 24px;
  }

  .profile-section-header {
    gap: 12px;
  }

  .profile-section-header .section-icon {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 12px;
  }

  .profile-section-header h3 {
    font-size: 0.95rem;
  }

  .profile-section-header p {
    font-size: 0.78rem;
  }

  .profile-input-wrap {
    min-height: 48px;
    padding: 0 14px;
    border-radius: 16px;
  }

  .profile-input-wrap input {
    font-size: 0.88rem;
    padding: 10px 0;
  }

  .password-wrap {
    min-height: 48px;
    padding: 0 8px 0 12px;
    gap: 8px;
  }

  .password-wrap input {
    font-size: 0.88rem;
    padding: 10px 0;
  }

  .toggle-password {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 11px;
  }

  .toggle-password svg {
    width: 16px;
    height: 16px;
  }

  .profile-save-btn,
  .logout-danger-btn {
    min-height: 50px;
    font-size: 0.95rem;
  }

}

/* ============================= */
/* RECENT ORDERS SECTION */
/* ============================= */

.recent-orders-section {
  margin-top: 28px;
  border-radius: 30px;
  padding: 22px 22px 20px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.015)),
    linear-gradient(135deg, rgba(13,18,28,0.96), rgba(8,11,17,0.98));
  border: 1px solid rgba(255,255,255,0.07);
  box-shadow:
    0 14px 38px rgba(0,0,0,0.20),
    inset 0 1px 0 rgba(255,255,255,0.03);
}

.section-kicker {
  font-size: 0.9rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: #9bd7ff;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.section-title {
  font-size: 1.2rem;
  font-weight: 800;
  color: #f7fbff;
  margin: 0;
}

.section-live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  color: rgba(223,232,244,0.72);
  white-space: nowrap;
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 6px rgba(34,197,94,0.10);
  animation: livePulse 2s ease-in-out infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.recent-orders-list {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.recent-orders-empty {
  width: 100%;
  padding: 28px 16px;
  text-align: center;
  color: rgba(225,235,245,0.50);
  font-weight: 600;
  font-size: 0.95rem;
}

.recent-order-card {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 14px 16px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(255,255,255,0.035), rgba(255,255,255,0.015));
  border: 1px solid rgba(255,255,255,0.06);
  color: #eaf3fb;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.02);
  transition: transform 180ms ease, border-color 180ms ease;
  flex: 0 0 auto;
}

@media (hover: hover) and (pointer: fine) {
  .recent-order-card:hover {
    transform: translateY(-2px);
    border-color: rgba(125,211,252,0.15);
  }
}

.order-country {
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.02em;
  min-width: 24px;
}

.order-user {
  font-weight: 700;
  color: rgba(255,255,255,0.9);
}

.order-verb {
  color: rgba(226,235,245,0.56);
}

.order-product {
  color: #35c6ff;
  font-weight: 700;
  white-space: nowrap;
}

.order-price {
  color: #86efac;
  font-weight: 800;
}

.order-time {
  color: rgba(225,235,245,0.50);
  font-size: 0.92rem;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .app-shell {
    width: 100%;
    max-width: 100%;
    padding-left: 14px;
    padding-right: 14px;
    overflow-x: hidden;
  }

  .topbar {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
    overflow: hidden;
  }

  .hero-card {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    padding-left: 16px;
    padding-right: 16px;
  }

  .hero-stats-grid,
  .stats-grid {
    width: 100%;
    max-width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .hero-stat-card,
  .stat-card {
    min-width: 0;
    width: 100%;
    min-height: 96px;
    padding: 12px;
    border-radius: 18px;
  }

  .promo-section {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
  }

  .promo-slider {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
    min-height: 210px;
  }

  .promo-card {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
  }

  .recent-orders-section {
    width: 100%;
    max-width: 100%;
    margin-top: 18px;
    border-radius: 24px;
    padding: 18px 18px 16px;
    overflow: hidden;
  }

  .section-title {
    font-size: 1rem;
  }

  .section-kicker {
    font-size: 0.78rem;
    margin-bottom: 4px;
  }

  .section-live {
    font-size: 0.82rem;
  }

  .recent-orders-list {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    max-width: 100%;
    padding-bottom: 4px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
  }

  .recent-orders-list::-webkit-scrollbar {
    display: none;
  }

  .recent-order-card {
    flex: 0 0 auto;
    gap: 8px;
    padding: 12px 14px;
    min-height: 48px;
    border-radius: 16px;
    min-width: 280px;
    scroll-snap-align: start;
  }

  .products-section {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
  }

  .product-grid {
    width: 100%;
    max-width: 100%;
    grid-template-columns: 1fr;
  }

  .product-card {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .topbar,
  .side-menu,
  .menu-user-card,
  .hero-stat-card,
  .main-content::before,
  .profile-hero-card,
  .profile-card,
  .desktop-stats-grid .stat-card {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .main-content::before {
    opacity: 0;
  }
}

@media (max-width: 430px) {
  .recent-orders-section {
    border-radius: 20px;
    padding: 14px 14px 12px;
    margin-top: 14px;
  }

  .recent-order-card {
    min-width: 260px;
    padding: 10px 12px;
    gap: 6px;
    min-height: 42px;
    border-radius: 14px;
    font-size: 0.88rem;
  }
}

/* ============================= */
/* DESKTOP STATS REDESIGN */
/* ============================= */

@media (min-width: 1024px) {
  .stats-grid {
    max-width: 100%;
    gap: 28px;
  }

  .stat-card {
    position: relative;
    min-height: 190px;
    border-radius: 30px;
    padding: 28px 28px 24px;
    background:
      linear-gradient(145deg, rgba(255,255,255,0.05), rgba(255,255,255,0.015)),
      linear-gradient(135deg, rgba(17,24,39,0.92), rgba(7,10,15,0.96));
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow:
      0 14px 40px rgba(0,0,0,0.22),
      inset 0 1px 0 rgba(255,255,255,0.04);
    transition:
      transform 180ms ease,
      border-color 180ms ease,
      box-shadow 180ms ease;
  }

  .stat-card::after {
    content: "";
    position: absolute;
    top: 14px;
    right: 18px;
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, rgba(56,189,248,0.08), transparent 70%);
    pointer-events: none;
    filter: blur(8px);
    opacity: 0.7;
  }

  @media (hover: hover) and (pointer: fine) {
    .stat-card:hover {
      transform: translateY(-3px);
      border-color: rgba(125, 211, 252, 0.20);
      box-shadow:
        0 18px 44px rgba(0,0,0,0.28),
        0 0 0 1px rgba(56,189,248,0.05);
    }
  }

  .stat-label {
    font-size: 1.05rem;
    font-weight: 700;
    color: #bfe5ff;
    margin-bottom: 18px;
  }

  .stat-value {
    font-size: clamp(2.4rem, 3vw, 3.3rem);
    line-height: 1;
    font-weight: 800;
    color: #f8fbff;
    letter-spacing: -0.03em;
    margin-bottom: 12px;
  }

  .stat-meta {
    font-size: 1rem;
    color: rgba(225, 235, 245, 0.72);
    font-weight: 500;
  }
}

/* ============================= */
/* TOPUP PAGE */
/* ============================= */

.topup-page {
  min-height: 100vh;
  margin: 0;
  padding: 24px;
  color: #f8fbff;
  font-family: "Anuphan", "Noto Sans Thai", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 12% 16%, rgba(56,189,248,0.08), transparent 28%),
    radial-gradient(circle at 86% 78%, rgba(37,99,235,0.08), transparent 30%),
    linear-gradient(135deg, #050607 0%, #0d1117 48%, #020617 100%);
  overflow-x: hidden;
}

.topup-container {
  width: min(100%, 860px);
  margin: 0 auto;
  display: grid;
  gap: 22px;
}

.topup-topbar {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 68px;
  padding: 14px 20px;
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.065), rgba(255,255,255,0.018)),
    linear-gradient(135deg, rgba(17,24,39,0.90), rgba(8,11,16,0.94));
  border: 1px solid rgba(255,255,255,0.085);
  box-shadow:
    0 20px 50px rgba(0,0,0,0.44),
    0 0 24px rgba(37,99,235,0.04),
    inset 0 1px 0 rgba(255,255,255,0.06);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
}

.topup-back-btn {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border: 0;
  border-radius: 15px;
  display: grid;
  place-items: center;
  color: #e5edff;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.06), rgba(255,255,255,0.015)),
    linear-gradient(135deg, rgba(17,24,39,0.80), rgba(8,11,16,0.88));
  border: 1px solid rgba(255,255,255,0.07);
  cursor: pointer;
  transition: transform 0.22s var(--ease), border-color 0.22s var(--ease);
}

.topup-back-btn:hover {
  border-color: rgba(125,211,252,0.20);
}

.topup-back-btn:active {
  transform: scale(0.97);
}

.topup-back-btn svg {
  display: block;
}

.topup-topbar h1 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 900;
  line-height: 1.3;
}

.topup-topbar p {
  margin: 2px 0 0;
  font-size: 0.85rem;
  color: rgba(196,211,227,0.78);
  font-weight: 600;
}

/* ---- Wallet balance card ---- */
.wallet-balance-card {
  border-radius: 28px;
  padding: 24px 24px 22px;
  display: grid;
  gap: 6px;
  text-align: center;
  background:
    radial-gradient(circle at 20% 20%, rgba(56,189,248,0.10), transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(37,99,235,0.08), transparent 38%),
    linear-gradient(145deg, rgba(255,255,255,0.065), rgba(255,255,255,0.018)),
    linear-gradient(135deg, rgba(17,24,39,0.90), rgba(8,11,16,0.94));
  border: 1px solid rgba(255,255,255,0.085);
  box-shadow:
    0 24px 70px rgba(0,0,0,0.40),
    inset 0 1px 0 rgba(255,255,255,0.06);
}

.wallet-label {
  font-size: 0.92rem;
  font-weight: 700;
  color: rgba(196,211,227,0.78);
  letter-spacing: 0.03em;
}

.wallet-amount {
  font-size: clamp(2.4rem, 5vw, 3.2rem);
  font-weight: 900;
  color: #f8fbff;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.wallet-balance-card p {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(145,167,189,0.70);
  font-weight: 600;
}

/* ---- Topup card ---- */
.topup-card {
  border-radius: 28px;
  padding: 22px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.065), rgba(255,255,255,0.018)),
    linear-gradient(135deg, rgba(17,24,39,0.90), rgba(8,11,16,0.94));
  border: 1px solid rgba(255,255,255,0.085);
  box-shadow:
    0 24px 70px rgba(0,0,0,0.40),
    inset 0 1px 0 rgba(255,255,255,0.06);
}

.topup-section-head {
  margin-bottom: 18px;
}

.topup-section-head h2 {
  margin: 0 0 4px;
  font-size: 1.1rem;
  font-weight: 900;
  color: #f8fbff;
}

.topup-section-head p {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(145,167,189,0.75);
  font-weight: 600;
}

/* ---- Amount grid ---- */
.amount-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}

.amount-chip {
  min-height: 54px;
  padding: 0 10px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 800;
  color: #e5edff;
  border: 1px solid rgba(255,255,255,0.08);
  background:
    linear-gradient(145deg, rgba(255,255,255,0.05), rgba(255,255,255,0.012)),
    linear-gradient(135deg, rgba(17,24,39,0.78), rgba(8,11,16,0.88));
  cursor: pointer;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease;
}

.amount-chip:hover {
  border-color: rgba(125,211,252,0.18);
}

.amount-chip:active {
  transform: scale(0.97);
}

.amount-chip.active {
  color: #ffffff;
  border-color: rgba(56,189,248,0.40);
  box-shadow:
    0 0 0 3px rgba(56,189,248,0.10),
    0 8px 24px rgba(0,0,0,0.22);
  background:
    linear-gradient(145deg, rgba(56,189,248,0.12), rgba(37,99,235,0.06)),
    linear-gradient(135deg, rgba(17,24,39,0.84), rgba(8,11,16,0.92));
}

/* ---- Custom amount ---- */
.topup-field {
  display: grid;
  gap: 8px;
  color: #d9e7f7;
  font-weight: 700;
  font-size: 0.88rem;
}

.topup-input-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 16px;
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.008)),
    linear-gradient(135deg, rgba(5,8,13,0.92), rgba(3,5,8,0.96));
  border: 1px solid rgba(255,255,255,0.075);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.035),
    0 6px 16px rgba(0,0,0,0.24);
  transition: border-color 0.22s var(--ease), box-shadow 0.22s var(--ease);
}

.topup-input-wrap:focus-within {
  border-color: rgba(56,189,248,0.42);
  box-shadow:
    0 0 0 4px rgba(56,189,248,0.10),
    0 0 24px rgba(22,135,255,0.10),
    0 10px 28px rgba(0,0,0,0.28),
    inset 0 1px 0 rgba(255,255,255,0.05);
}

.topup-input-prefix {
  color: var(--cyan-soft);
  font-weight: 800;
  font-size: 1.05rem;
}

.topup-input-wrap input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  outline: none;
  color: #f8fbff;
  font-size: 1rem;
  font-weight: 600;
  padding: 14px 0;
  -moz-appearance: textfield;
}

.topup-input-wrap input::-webkit-outer-spin-button,
.topup-input-wrap input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.topup-input-wrap input::placeholder {
  color: rgba(145,167,189,0.60);
}

/* ---- Payment method grid ---- */
.payment-method-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.payment-method-card {
  display: grid;
  gap: 8px;
  padding: 20px 18px;
  border-radius: 22px;
  min-height: 120px;
  text-align: left;
  border: 1px solid rgba(255,255,255,0.08);
  background:
    linear-gradient(145deg, rgba(255,255,255,0.04), rgba(255,255,255,0.012)),
    linear-gradient(135deg, rgba(17,24,39,0.80), rgba(8,11,16,0.90));
  cursor: pointer;
  transition:
    transform 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease;
}

.payment-method-card:hover {
  border-color: rgba(125,211,252,0.16);
}

.payment-method-card:active {
  transform: scale(0.985);
}

.payment-method-card.active {
  border-color: rgba(56,189,248,0.42);
  box-shadow:
    0 0 0 4px rgba(56,189,248,0.08),
    0 18px 46px rgba(0,0,0,0.34);
  background:
    linear-gradient(145deg, rgba(56,189,248,0.08), rgba(37,99,235,0.04)),
    linear-gradient(135deg, rgba(17,24,39,0.86), rgba(8,11,16,0.94));
}

.payment-method-card.active[data-method="truemoney"] {
  border-color: rgba(255,159,28,0.42);
  box-shadow:
    0 0 0 4px rgba(255,159,28,0.08),
    0 18px 46px rgba(0,0,0,0.34);
  background:
    linear-gradient(145deg, rgba(255,159,28,0.08), rgba(251,191,36,0.03)),
    linear-gradient(135deg, rgba(17,24,39,0.86), rgba(8,11,16,0.94));
}

.payment-method-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #7dd3fc;
  background: rgba(34,211,238,0.12);
  border: 1px solid rgba(120,226,255,0.14);
}

.payment-icon-truewallet {
  color: #fbbf24 !important;
  background: rgba(251,191,36,0.12) !important;
  border-color: rgba(251,191,36,0.18) !important;
}

.payment-method-card strong {
  font-size: 1rem;
  font-weight: 800;
  color: #f8fbff;
}

.payment-method-card small {
  font-size: 0.78rem;
  color: rgba(145,167,189,0.72);
  font-weight: 600;
  line-height: 1.4;
}

/* ---- Payment detail ---- */
.payment-detail-card {
  margin-top: 0;
}

.payment-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

.payment-detail-head h2 {
  margin: 0 0 4px;
  font-size: 1.1rem;
  font-weight: 900;
  color: #f8fbff;
}

.payment-detail-head p {
  margin: 0;
  font-size: 0.85rem;
  color: rgba(145,167,189,0.75);
  font-weight: 600;
}

.payment-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #86efac;
  background: rgba(16,185,129,0.12);
  border: 1px solid rgba(16,185,129,0.18);
  white-space: nowrap;
}

.payment-account-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 60px;
  padding: 14px 18px;
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.035), rgba(255,255,255,0.012)),
    linear-gradient(135deg, rgba(5,8,13,0.90), rgba(3,5,8,0.94));
  border: 1px solid rgba(255,255,255,0.07);
  margin-bottom: 18px;
}

.payment-account-info {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.payment-account-info span {
  font-size: 0.78rem;
  font-weight: 700;
  color: rgba(145,167,189,0.70);
}

.payment-account-info strong {
  font-size: 1.1rem;
  font-weight: 800;
  color: #f8fbff;
  letter-spacing: 0.03em;
  word-break: break-all;
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 38px;
  padding: 0 14px;
  border: 0;
  border-radius: 12px;
  color: #7dd3fc;
  font-weight: 800;
  font-size: 0.82rem;
  background:
    linear-gradient(145deg, rgba(56,189,248,0.10), rgba(37,99,235,0.06)),
    linear-gradient(135deg, rgba(17,24,39,0.82), rgba(8,11,16,0.90));
  border: 1px solid rgba(56,189,248,0.14);
  cursor: pointer;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.copy-btn svg {
  display: block;
}

.copy-btn:hover {
  border-color: rgba(56,189,248,0.30);
  background:
    linear-gradient(145deg, rgba(56,189,248,0.14), rgba(37,99,235,0.08)),
    linear-gradient(135deg, rgba(17,24,39,0.86), rgba(8,11,16,0.92));
}

.copy-btn:active {
  transform: scale(0.97);
}

/* ---- QR Placeholder ---- */
.qr-placeholder {
  display: grid;
  place-items: center;
  gap: 6px;
  min-height: 140px;
  padding: 22px;
  border-radius: 20px;
  text-align: center;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.03), rgba(255,255,255,0.010)),
    linear-gradient(135deg, rgba(5,8,13,0.80), rgba(3,5,8,0.88));
  border: 1px dashed rgba(255,255,255,0.10);
}

.qr-icon {
  color: rgba(56,189,248,0.42);
  display: grid;
  place-items: center;
}

.qr-icon svg {
  display: block;
}

.qr-placeholder strong {
  font-size: 0.95rem;
  font-weight: 800;
  color: rgba(248,251,255,0.52);
}

.qr-placeholder small {
  font-size: 0.78rem;
  color: rgba(145,167,189,0.48);
  font-weight: 600;
}

/* ---- Slip upload ---- */
.slip-upload-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 180px;
  padding: 24px;
  border-radius: 22px;
  text-align: center;
  cursor: pointer;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.03), rgba(255,255,255,0.010)),
    linear-gradient(135deg, rgba(5,8,13,0.78), rgba(3,5,8,0.86));
  border: 1px dashed rgba(255,255,255,0.10);
  transition:
    border-color 0.22s var(--ease),
    background 0.22s var(--ease);
}

.slip-upload-box:hover {
  border-color: rgba(56,189,248,0.26);
  background:
    linear-gradient(145deg, rgba(56,189,248,0.04), rgba(37,99,235,0.02)),
    linear-gradient(135deg, rgba(5,8,13,0.82), rgba(3,5,8,0.90));
}

.slip-upload-box input {
  display: none;
}

.upload-icon {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: rgba(125,211,252,0.50);
  background: rgba(34,211,238,0.08);
  border: 1px solid rgba(120,226,255,0.10);
}

.upload-icon svg {
  display: block;
}

.slip-upload-box strong {
  font-size: 1rem;
  font-weight: 800;
  color: rgba(248,251,255,0.70);
}

.slip-upload-box small {
  font-size: 0.8rem;
  color: rgba(145,167,189,0.55);
  font-weight: 600;
}

/* ---- Slip preview ---- */
.slip-preview {
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.08);
  animation: slipFadeIn 180ms cubic-bezier(0.2,0.8,0.2,1) both;
}

@keyframes slipFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.slip-preview img {
  width: 100%;
  height: auto;
  max-height: 320px;
  object-fit: contain;
  display: block;
  background: rgba(0,0,0,0.20);
}

.slip-preview-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.035), rgba(255,255,255,0.012)),
    linear-gradient(135deg, rgba(5,8,13,0.88), rgba(3,5,8,0.92));
  border-top: 1px solid rgba(255,255,255,0.05);
}

.slip-preview-info span {
  font-size: 0.88rem;
  font-weight: 700;
  color: rgba(248,251,255,0.75);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.slip-remove-btn {
  width: 34px;
  height: 34px;
  min-width: 34px;
  border: 0;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: rgba(248,251,255,0.50);
  background: rgba(255,255,255,0.06);
  cursor: pointer;
  transition:
    background 160ms ease,
    color 160ms ease;
}

.slip-remove-btn svg {
  display: block;
}

.slip-remove-btn:hover {
  background: rgba(239,68,68,0.14);
  color: #fca5a5;
}

/* ---- Submit button ---- */
.topup-submit-btn {
  width: 100%;
  min-height: 58px;
  padding: 0 24px;
  border: 0;
  border-radius: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #ffffff;
  font-weight: 800;
  font-size: 1.1rem;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 48%, var(--primary-3) 100%);
  box-shadow:
    0 14px 34px rgba(22,135,255,0.26),
    0 0 28px rgba(56,207,255,0.16),
    inset 0 1px 0 rgba(255,255,255,0.20);
  cursor: pointer;
  transition:
    transform 0.22s var(--ease),
    box-shadow 0.22s var(--ease),
    filter 0.22s var(--ease);
}

.topup-submit-btn svg {
  display: block;
}

.topup-submit-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow:
    0 18px 42px rgba(22,135,255,0.32),
    0 0 34px rgba(56,207,255,0.20),
    inset 0 1px 0 rgba(255,255,255,0.22);
}

.topup-submit-btn:active {
  transform: scale(0.985);
}

.topup-submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none !important;
  filter: none !important;
}

/* ---- Topup responsive ---- */
@media (max-width: 768px) {
  .topup-page {
    padding: 16px;
  }

  .topup-container {
    gap: 18px;
  }

  .topup-topbar {
    padding: 12px 16px;
    min-height: 60px;
    border-radius: 20px;
  }

  .topup-back-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
  }

  .topup-topbar h1 {
    font-size: 1.1rem;
  }

  .topup-topbar p {
    font-size: 0.8rem;
  }

  .wallet-balance-card {
    padding: 20px 18px;
    border-radius: 24px;
  }

  .wallet-amount {
    font-size: clamp(2rem, 5vw, 2.6rem);
  }

  .topup-card {
    padding: 18px;
    border-radius: 24px;
  }

  .amount-grid {
    gap: 10px;
  }

  .amount-chip {
    min-height: 48px;
    border-radius: 16px;
    font-size: 0.92rem;
  }

  .payment-method-card {
    padding: 16px 14px;
    border-radius: 20px;
    min-height: 100px;
  }

  .qr-placeholder {
    min-height: 120px;
    padding: 18px;
  }

  .slip-upload-box {
    min-height: 150px;
    padding: 20px;
  }

  .topup-submit-btn {
    min-height: 52px;
    font-size: 1rem;
    border-radius: 18px;
  }
}

@media (max-width: 560px) {
  .topup-page {
    padding: 14px;
  }

  .topup-topbar {
    padding: 10px 14px;
    min-height: 56px;
    border-radius: 18px;
  }

  .topup-back-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 12px;
  }

  .topup-topbar h1 {
    font-size: 1rem;
  }

  .topup-topbar p {
    font-size: 0.75rem;
  }

  .wallet-balance-card {
    padding: 16px 14px;
    border-radius: 22px;
  }

  .wallet-amount {
    font-size: clamp(1.8rem, 5vw, 2.2rem);
  }

  .topup-card {
    padding: 16px;
    border-radius: 22px;
  }

  .amount-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .amount-chip {
    min-height: 44px;
    border-radius: 14px;
    font-size: 0.88rem;
  }

  .payment-method-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .payment-method-card {
    min-height: 80px;
    padding: 14px;
    border-radius: 18px;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 14px;
  }

  .payment-method-icon {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 12px;
  }

  .payment-method-icon svg {
    width: 20px;
    height: 20px;
  }

  .payment-method-card strong {
    font-size: 0.92rem;
  }

  .payment-method-card small {
    display: none;
  }

  .payment-detail-head {
    flex-direction: column;
    gap: 10px;
  }

  .payment-account-box {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    min-height: auto;
    padding: 14px;
    border-radius: 16px;
  }

  .copy-btn {
    align-self: flex-start;
  }

  .qr-placeholder {
    min-height: 100px;
    padding: 16px;
    border-radius: 16px;
  }

  .slip-upload-box {
    min-height: 130px;
    padding: 16px;
    border-radius: 18px;
  }

  .upload-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
  }

  .upload-icon svg {
    width: 22px;
    height: 22px;
  }

  .slip-upload-box strong {
    font-size: 0.92rem;
  }

  .topup-submit-btn {
    min-height: 48px;
    font-size: 0.95rem;
    border-radius: 16px;
  }
}

@media (max-width: 430px) {
  .topup-page {
    padding: 12px;
  }

  .topup-container {
    gap: 14px;
  }

  .topup-topbar {
    padding: 8px 12px;
    min-height: 52px;
    gap: 12px;
  }

  .topup-back-btn {
    width: 34px;
    height: 34px;
    min-width: 34px;
  }

  .topup-back-btn svg {
    width: 18px;
    height: 18px;
  }

  .topup-topbar h1 {
    font-size: 0.92rem;
  }

  .wallet-amount {
    font-size: 1.8rem;
  }

  .amount-grid {
    gap: 6px;
  }

  .amount-chip {
    min-height: 40px;
    font-size: 0.82rem;
    border-radius: 12px;
  }

  .payment-method-card {
    min-height: 72px;
    padding: 12px;
    gap: 10px;
  }

  .payment-method-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 10px;
  }

  .payment-method-card strong {
    font-size: 0.85rem;
  }

  .payment-account-info strong {
    font-size: 0.95rem;
  }

  .slip-upload-box {
    min-height: 110px;
    padding: 14px;
    gap: 8px;
  }

  .upload-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }

  .upload-icon svg {
    width: 18px;
    height: 18px;
  }

  .slip-preview img {
    max-height: 200px;
  }

  .topup-submit-btn {
    min-height: 44px;
    font-size: 0.9rem;
    border-radius: 14px;
  }
}

/* ============================= */
/* ANIMATIONS */
/* ============================= */

/* ============================= */
/* PAGE ENTER ANIMATION */
/* ============================= */

@keyframes pageEnterFast {
  from {
    opacity: 0;
    transform: translate3d(0, 8px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

.app-shell,
.profile-shell,
.topup-page {
  will-change: transform, opacity;
  animation: pageEnterFast 230ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* ============================= */
/* PAGE LEAVING */
/* ============================= */

body.is-leaving .app-shell,
body.is-leaving .profile-shell,
body.is-leaving .topup-page {
  opacity: 0;
  transform: translate3d(0, 6px, 0);
  transition:
    opacity 120ms ease,
    transform 120ms ease;
}

/* ============================= */
/* CARD / SECTION FADE-IN */
/* ============================= */

@keyframes cardInFast {
  from {
    opacity: 0;
    transform: translate3d(0, 10px, 0);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

.hero-stat-card,
.stat-card,
.promo-section,
.recent-orders-section,
.products-section,
.product-card,
.wallet-balance-card,
.topup-card {
  animation: cardInFast 220ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-stat-card:nth-child(1),
.stat-card:nth-child(1) { animation-delay: 12ms; }
.hero-stat-card:nth-child(2),
.stat-card:nth-child(2) { animation-delay: 24ms; }
.hero-stat-card:nth-child(3),
.stat-card:nth-child(3) { animation-delay: 36ms; }
.hero-stat-card:nth-child(4),
.stat-card:nth-child(4) { animation-delay: 48ms; }

.wallet-balance-card { animation-delay: 20ms; }
.promo-section { animation-delay: 30ms; }
.recent-orders-section { animation-delay: 40ms; }
.products-section { animation-delay: 50ms; }

.product-card:nth-child(1) { animation-delay: 60ms; }
.product-card:nth-child(2) { animation-delay: 70ms; }
.product-card:nth-child(3) { animation-delay: 80ms; }
.product-card:nth-child(4) { animation-delay: 90ms; }
.product-card:nth-child(5) { animation-delay: 100ms; }
.product-card:nth-child(6) { animation-delay: 110ms; }

@media (max-width: 768px) {
  .hero-stat-card,
  .stat-card,
  .promo-section,
  .recent-orders-section,
  .products-section,
  .product-card,
  .wallet-balance-card,
  .topup-card {
    animation-duration: 190ms;
    animation-delay: 0ms !important;
  }
}

/* ============================= */
/* PROFILE PAGE ANIMATIONS */
/* ============================= */

.profile-hero-card,
.profile-card {
  animation: cardInFast 220ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.profile-card:nth-of-type(1) { animation-delay: 20ms; }
.profile-card:nth-of-type(2) { animation-delay: 35ms; }

.profile-save-btn,
.logout-danger-btn {
  animation: cardInFast 220ms cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: 50ms;
}

/* ============================= */
/* MICRO INTERACTIONS */
/* ============================= */

button,
.primary-btn,
.ghost-btn,
.amount-chip,
.payment-method-card,
.product-card button,
.profile-save-btn,
.topup-submit-btn,
.logout-danger-btn,
.wallet-btn,
.copy-btn,
.topup-back-btn,
.hero-stat-card,
.stat-card,
.product-card,
.recent-order-card {
  transition:
    transform 140ms ease,
    background 160ms ease,
    border-color 160ms ease,
    opacity 160ms ease;
}

button:active,
.primary-btn:active,
.ghost-btn:active,
.amount-chip:active,
.payment-method-card:active,
.product-card button:active,
.profile-save-btn:active,
.topup-submit-btn:active,
.logout-danger-btn:active,
.wallet-btn:active,
.copy-btn:active,
.topup-back-btn:active {
  transform: translate3d(0, 1px, 0) scale(0.99);
}

@media (hover: hover) and (pointer: fine) {
  .product-card:hover,
  .stat-card:hover,
  .payment-method-card:hover,
  .recent-order-card:hover {
    transform: translate3d(0, -3px, 0);
  }

  .hero-stat-card:hover {
    transform: translate3d(0, -3px, 0);
  }

  .amount-chip:hover {
    border-color: rgba(125,211,252,0.18);
  }
}

@media (hover: none) {
  .product-card:hover,
  .stat-card:hover,
  .payment-method-card:hover,
  .recent-order-card:hover,
  .hero-stat-card:hover,
  .amount-chip:hover {
    transform: none;
  }
}

/* ============================= */
/* TOAST */
/* ============================= */

.toast-container {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2000;
  display: grid;
  gap: 10px;
  width: min(440px, calc(100vw - 32px));
  pointer-events: none;
}

.toast {
  padding: 16px 20px;
  border-radius: 18px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02)),
    linear-gradient(135deg, rgba(17,24,39,0.96), rgba(8,11,16,0.98));
  border: 1px solid rgba(255,255,255,0.10);
  box-shadow:
    0 20px 60px rgba(0,0,0,0.50),
    0 0 30px rgba(56,189,248,0.06),
    inset 0 1px 0 rgba(255,255,255,0.06);
  color: #f8fbff;
  font-weight: 700;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 12px;
  pointer-events: auto;
  animation: toastIn 200ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.toast.is-leaving {
  animation: toastOut 150ms ease both;
}

.toast-success {
  border-color: rgba(16, 185, 129, 0.30);
}

.toast-success .toast-icon {
  color: #34d399;
}

.toast-error {
  border-color: rgba(239, 68, 68, 0.30);
}

.toast-error .toast-icon {
  color: #f87171;
}

.toast-icon {
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 1rem;
  background: rgba(255,255,255,0.06);
}

.toast-text {
  flex: 1;
  min-width: 0;
  line-height: 1.4;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes toastOut {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateY(10px) scale(0.96);
  }
}

/* ============================= */
/* REDUCED MOTION */
/* ============================= */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
