/* ══════════════════════════════════════════
   FENIX STORE — CSS COMPARTILHADO
   Inclua em todas as páginas via:
   <link rel="stylesheet" href="fenix.css">
══════════════════════════════════════════ */

:root {
  --bg: #05050a;
  --surface: #0d0d14;
  --surface2: #141420;
  --surface3: #1a1a2e;
  --accent: #6d28d9;
  --accent2: #8b5cf6;
  --accent3: #c4b5fd;
  --gold: #f59e0b;
  --gold2: #fbbf24;
  --gold-glow: rgba(245,158,11,0.3);
  --text: #f0f0ff;
  --muted: #6b6b88;
  --muted2: #9999bb;
  --border: rgba(109,40,217,0.18);
  --border2: rgba(109,40,217,0.38);
  --success: #10b981;
  --sold: #ef4444;
  --danger: #ef4444;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  background-image: url('fexx2.jpeg');
  background-image: -webkit-image-set(url('fexx2.webp') 1x);
  background-image: image-set(url('fexx2.webp') type('image/webp'), url('fexx2.jpeg') type('image/jpeg'));
  background-size: cover;
  background-position: center center;
  /* background-attachment: fixed; — removed: causes iOS mobile scroll bugs */
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Overlay escuro para manter legibilidade */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: rgba(5, 5, 10, 0.12);
  pointer-events: none;
  z-index: 0;
}

/* Noise sutil */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.022;
  pointer-events: none;
  z-index: 1;
}

/* ── ORBS ── */
.orb1 {
  position: fixed; top: -25%; left: -10%;
  width: 65vw; height: 65vw;
  background: radial-gradient(circle, rgba(109,40,217,0.08) 0%, transparent 65%);
  pointer-events: none; z-index: 0;
  animation: orbA 22s ease-in-out infinite alternate;
}
.orb2 {
  position: fixed; bottom: -20%; right: -10%;
  width: 55vw; height: 55vw;
  background: radial-gradient(circle, rgba(245,158,11,0.05) 0%, transparent 65%);
  pointer-events: none; z-index: 0;
  animation: orbB 28s ease-in-out infinite alternate;
}
@keyframes orbA { to { transform: translate(6vw, 4vh) scale(1.1); } }
@keyframes orbB { to { transform: translate(-5vw, -3vh) scale(1.08); } }

/* ── GRID BG ── */
.bg-grid {
  position: fixed; inset: 0;
  background-image:
    linear-gradient(rgba(109,40,217,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(109,40,217,0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  pointer-events: none; z-index: 0;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 40%, black 20%, transparent 100%);
}

/* ── FENIX FIRE LOGO ── */
.fenix-logo-wrap { display: inline-flex; align-items: center; gap: 12px; position: relative; }

.fenix-fire-text {
  position: relative; display: inline-block;
  font-family: 'Syne', sans-serif; font-weight: 800;
  font-size: 1.4rem; letter-spacing: 3px; color: transparent;
  background: linear-gradient(180deg, #fff 0%, #ffe066 10%, #ffaa00 28%, #e05c00 50%, #8b2800 68%, #e05c00 78%, #ffaa00 90%, #ffe066 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 2px #fff176) drop-shadow(0 0 6px #ff8c00) drop-shadow(0 0 14px #ff3d00) drop-shadow(0 0 28px rgba(200,30,0,0.7));
  animation: emberpulse 2.5s ease-in-out infinite;
}
@keyframes emberpulse {
  0%,100% { filter: drop-shadow(0 0 2px #fff176) drop-shadow(0 0 6px #ff8c00) drop-shadow(0 0 14px #ff3d00) drop-shadow(0 0 28px rgba(200,30,0,0.7)); }
  50%     { filter: drop-shadow(0 0 3px #fff) drop-shadow(0 0 10px #fa0) drop-shadow(0 0 22px #f50) drop-shadow(0 0 40px rgba(220,40,0,0.9)); }
}
.fenix-fire-text::before {
  content: 'FENIX STORE'; position: absolute; top: -22px; left: 0;
  font-family: 'Syne', sans-serif; font-weight: 800; font-size: 1.4rem; letter-spacing: 3px;
  -webkit-text-fill-color: transparent;
  background: linear-gradient(180deg, rgba(255,255,200,0) 0%, rgba(255,200,0,0.25) 30%, rgba(255,100,0,0.55) 65%, rgba(255,60,0,0.85) 100%);
  -webkit-background-clip: text; background-clip: text;
  filter: blur(2px); transform: scaleY(-1); opacity: 0.85;
  animation: flameRise 1.4s ease-in-out infinite alternate; pointer-events: none;
}
@keyframes flameRise {
  0%   { transform: scaleY(-1) scaleX(1.00) translateY(2px); opacity: 0.7; filter: blur(1.5px); }
  50%  { transform: scaleY(-1.4) scaleX(0.97) translateY(0px); opacity: 1; filter: blur(2.5px); }
  100% { transform: scaleY(-1.1) scaleX(1.02) translateY(1px); opacity: 0.8; filter: blur(1.8px); }
}
.fenix-fire-text::after {
  content: ''; position: absolute; bottom: -6px; left: 5%; right: 5%; height: 8px;
  background: radial-gradient(ellipse at 50% 0%, rgba(255,120,0,0.5) 0%, transparent 80%);
  filter: blur(3px); animation: heatglow 2s ease-in-out infinite alternate; pointer-events: none;
}
@keyframes heatglow { 0% { opacity: 0.5; transform: scaleX(0.95); } 100% { opacity: 1; transform: scaleX(1.05); } }

/* ── HEADER COMPARTILHADO ── */
header, .admin-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(5,5,10,0.82);
  backdrop-filter: blur(28px) saturate(180%);
  border-bottom: 1px solid var(--border);
  padding: 0 48px; height: 72px;
  display: flex; align-items: center; justify-content: space-between;
}
header::after, .admin-header::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(139,92,246,0.5) 30%, rgba(245,158,11,0.3) 70%, transparent 100%);
}

/* ── BOTÕES ── */
.btn-primary {
  background: linear-gradient(135deg, var(--accent), #4c1d95);
  color: white; border: none; border-radius: 14px; padding: 13px 22px;
  font-size: 0.95rem; font-weight: 700; cursor: pointer;
  font-family: 'Syne', sans-serif; transition: all 0.2s; letter-spacing: 0.5px;
  position: relative; overflow: hidden;
}
.btn-primary::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.15), transparent);
  opacity: 0; transition: opacity 0.2s;
}
.btn-primary:hover::before { opacity: 1; }
.btn-primary:hover { transform: scale(1.02); box-shadow: 0 10px 30px rgba(109,40,217,0.5); }
.btn-primary:active { transform: scale(0.98); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; box-shadow: none; }

/* ── INPUTS COMPARTILHADOS ── */
.field { margin-bottom: 16px; }
.field label {
  display: block; font-size: 0.65rem; color: var(--muted);
  margin-bottom: 6px; text-transform: uppercase;
  letter-spacing: 2px; font-weight: 700; font-family: 'Space Mono', monospace;
}
.input {
  width: 100%; background: var(--surface2); border: 1px solid var(--border);
  border-radius: 13px; padding: 13px 16px; color: var(--text);
  font-size: 0.93rem; font-family: 'DM Sans', sans-serif;
  outline: none; transition: border-color 0.2s, box-shadow 0.2s;
}
.input:focus { border-color: var(--accent2); box-shadow: 0 0 0 3px rgba(139,92,246,0.12); }
.input::placeholder { color: var(--muted); }

/* ── FEEDBACK ── */
.msg-err {
  background: rgba(239,68,68,0.08); border: 1px solid rgba(239,68,68,0.3);
  border-radius: 11px; padding: 11px 14px; color: var(--danger);
  font-size: 0.82rem; margin-top: 12px; display: none;
}
.msg-err.on { display: block; }
.msg-ok {
  background: rgba(16,185,129,0.08); border: 1px solid rgba(16,185,129,0.3);
  border-radius: 11px; padding: 11px 14px; color: var(--success);
  font-size: 0.82rem; margin-top: 12px; display: none;
}
.msg-ok.on { display: block; }

/* ── SKELETON LOADER ── */
.skeleton {
  background: linear-gradient(90deg, var(--surface) 25%, var(--surface2) 50%, var(--surface) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 12px;
}
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* ── TOAST ── */
.toast {
  position: fixed; bottom: 28px; right: 28px; z-index: 9000;
  background: var(--surface2); border: 1px solid var(--border2);
  border-radius: 16px; padding: 14px 22px;
  font-size: 0.88rem; font-weight: 600;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  transform: translateY(20px); opacity: 0;
  transition: all 0.3s cubic-bezier(0.34,1.56,0.64,1);
  pointer-events: none;
}
.toast.show { transform: translateY(0); opacity: 1; }
.toast.success { border-color: rgba(16,185,129,0.4); color: var(--success); }
.toast.error { border-color: rgba(239,68,68,0.4); color: var(--danger); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  header, .admin-header { padding: 0 20px; }
  .fenix-fire-text { font-size: 1.1rem; letter-spacing: 2px; }
}

/* ══════════════════════════════════════════
   FENIX STORE — UPGRADES 4K & VISUAIS v2
   Glassmorphism, cursor chama, partículas,
   preconnect hints já no head de cada página.
══════════════════════════════════════════ */

/* ── CURSOR — padrão do sistema operacional ── */
*, *::before, *::after { cursor: auto; }
a, button, [role="button"], input[type="submit"], input[type="button"], label[for], select { cursor: pointer; }

/* ── PERFORMANCE MOBILE — evitar desfoque/tremble de imagens ── */
img {
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  transform: translateZ(0);
}

/* ── Economizar GPU em mobile — desliga orbs e will-change ── */
@media (max-width: 768px) {
  .orb1, .orb2 { display: none !important; }
  .gift-card { will-change: auto !important; }
  #fxWall .fx-rays { display: none !important; } /* conic-gradient pesado em mobile */
}
/* ── GLASSMORPHISM 4K nos cards ── */
.gift-card {
  backdrop-filter: blur(22px) saturate(170%) brightness(1.05) !important;
  background: rgba(13,13,20,0.68) !important;
  box-shadow:
    0 8px 32px rgba(0,0,0,0.65),
    inset 0 1px 0 rgba(255,255,255,0.07),
    inset 0 -1px 0 rgba(0,0,0,0.3),
    0 0 0 1px rgba(109,40,217,0.10) !important;
  border: 1px solid rgba(109,40,217,0.18) !important;
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1),
              border-color 0.3s, box-shadow 0.3s,
              backdrop-filter 0.3s !important;
}
.gift-card:hover:not(.is-sold) {
  backdrop-filter: blur(30px) saturate(200%) brightness(1.08) !important;
  box-shadow:
    0 32px 80px rgba(109,40,217,0.22),
    0 0 0 1px rgba(139,92,246,0.20),
    inset 0 1px 0 rgba(255,255,255,0.10),
    0 0 60px rgba(109,40,217,0.08) !important;
  border-color: rgba(139,92,246,0.55) !important;
}

/* ── MODAL: sem blur — fogo do canvas fica visível ── */
.modal {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

/* ── HEADER glass aprimorado ── */
header, .admin-header {
  backdrop-filter: blur(40px) saturate(200%) brightness(0.95) !important;
  background: rgba(5,5,10,0.75) !important;
}

/* ── INPUTS glass 4K ── */
.input, input.input {
  backdrop-filter: blur(10px) !important;
  background: rgba(20,20,32,0.82) !important;
}

/* ── TIPOGRAFIA 4K — hero title maior em telas grandes ── */
@media (min-width: 2560px) {
  .fire-letter-group {
    font-size: clamp(5rem, 7vw, 12rem) !important;
  }
  .hero h1 {
    font-size: clamp(4rem, 6vw, 10rem) !important;
  }
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)) !important;
    gap: 32px !important;
  }
  .stat-num { font-size: 3rem !important; }
}

/* ── GLOW nas bordas do header em 4K ── */
header::after, .admin-header::after {
  height: 2px !important;
  filter: blur(1px);
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(139,92,246,0.7) 25%,
    rgba(245,158,11,0.5) 50%,
    rgba(139,92,246,0.7) 75%,
    transparent 100%) !important;
}

/* ── STAT BAR glass ── */
.stats-bar {
  backdrop-filter: blur(20px) saturate(160%) !important;
  background: rgba(13,13,20,0.72) !important;
  box-shadow:
    0 20px 60px rgba(0,0,0,0.5),
    0 0 0 1px rgba(255,255,255,0.04),
    inset 0 1px 0 rgba(255,255,255,0.06) !important;
}

/* ── SCROLL customizado fire ── */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: rgba(5,5,10,0.8); }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(139,92,246,0.7), rgba(109,40,217,0.4));
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(245,158,11,0.8), rgba(200,100,0,0.5));
}

/* ── TEXT SELECTION fogo ── */
::selection {
  background: rgba(245,158,11,0.35);
  color: #fff8e0;
}


/* ══ FXWALL — fênix centralizada sem corte ══ */
#fxWall .fx-img {
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  width: auto !important;
  height: 100% !important;
  min-width: 100% !important;
  min-height: 100% !important;
  object-fit: cover !important;
  object-position: center 20% !important;
}

/* Mobile: mostra mais da fênix (menos corte no topo) */
@media (max-width: 768px) {
  #fxWall .fx-img {
    object-position: center 15% !important;
    height: 100% !important;
    width: 100% !important;
  }
}

/* ══ MODAL OVERLAY — fogo visível no canvas ══ */
/* Anula qualquer backdrop-filter residual no .modal */
.modal,
.modal-overlay .modal {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  background: transparent !important;
}

/* ══════════════════════════════════════════
   FENIX STORE — MOBILE UPGRADE v3
   Safe-area iOS, touch targets, overscroll
══════════════════════════════════════════ */

/* Safe-area para header (iPhone notch / Dynamic Island) */
header, .admin-header {
  padding-left: max(48px, calc(env(safe-area-inset-left) + 20px));
  padding-right: max(48px, calc(env(safe-area-inset-right) + 20px));
  padding-top: env(safe-area-inset-top);
}

/* Evitar overscroll bounce no iOS que parece "bug" */
html {
  overscroll-behavior: none;
  -webkit-tap-highlight-color: transparent;
}

/* Touch targets mínimos 44×44px (Apple HIG / Material) */
button, a, [role="button"], input, select, textarea {
  touch-action: manipulation; /* elimina delay de 300ms no iOS */
}

/* Scroll nativo suave no iOS */
.modal, .overflow-scroll {
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

/* Impede zoom acidental ao focar inputs no iOS */
@media (max-width: 768px) {
  input, select, textarea {
    font-size: max(16px, 1em) !important; /* < 16px causa zoom no Safari */
  }
  header, .admin-header {
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
  }
  /* Botão primário — area mínima toque */
  .btn-primary {
    min-height: 48px;
    padding: 14px 22px;
  }
}

/* Impede imagens de vazar fora do card em mobile */
.gift-card img, .gift-card canvas {
  max-width: 100%;
  height: auto;
}


/* ══════════════════════════════════════════════════════════════
   FENIX STORE — COMPONENTES GLOBAIS v4
   (extraído do index.html para cache separado)
══════════════════════════════════════════════════════════════ */

/* ── COPY DATA BTN ── */
.copy-data-btn {
  background: rgba(109,40,217,0.12);
  border: 1px solid rgba(139,92,246,0.28);
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent3);
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s;
  position: relative;
  overflow: hidden;
  touch-action: manipulation;
  min-height: 36px;
}
.copy-data-btn:hover { background: rgba(109,40,217,0.25); border-color: rgba(139,92,246,0.5); }
.copy-data-btn.copied { background: rgba(16,185,129,0.15); border-color: rgba(16,185,129,0.4); color: var(--success); }

/* ── RIPPLE ── */
.buy-btn, .copy-data-btn { position: relative; overflow: hidden; }
.ripple-circle {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.25);
  transform: scale(0);
  animation: rippleAnim 0.5s linear;
  pointer-events: none;
}
@keyframes rippleAnim { to { transform: scale(4); opacity: 0; } }

/* ── EMPTY STATE ── */
.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 24px;
  color: var(--muted);
}
.empty-state-icon { font-size: 3rem; margin-bottom: 16px; opacity: 0.5; }

/* ── TOAST ANIMATIONS ── */
@keyframes toastSlideIn {
  from { opacity: 0; transform: translateY(20px) scale(0.95); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes toastSlideOut {
  from { opacity: 1; transform: translateY(0) scale(1); }
  to   { opacity: 0; transform: translateY(10px) scale(0.95); }
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes shimmerSkeleton {
  0%   { background-position: -800px 0; }
  100% { background-position:  800px 0; }
}
@keyframes cardReveal {
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pulseRing {
  0%   { transform: scale(1); opacity: 0.4; }
  100% { transform: scale(2.8); opacity: 0; }
}

/* ── MODAL OVERLAY ── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.78);
  backdrop-filter: blur(6px);
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow: hidden;
}
.modal-overlay.open { display: flex; animation: overlayIn 0.25s ease both; }
@keyframes overlayIn { from { opacity: 0; } to { opacity: 1; } }

/* Mobile: modal na base, sem backdrop-filter (iOS fix) */
@media (max-width: 480px) {
  .modal-overlay {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background: rgba(0,0,0,0.85) !important;
    padding: 8px;
    padding-bottom: max(8px, calc(8px + env(safe-area-inset-bottom)));
    align-items: center !important;
  }
}

/* ── MODAL CARD ── */
.modal-fire-container { position: relative; width: 100%; max-width: 420px; z-index: 2; }
.modal {
  position: relative; z-index: 2;
  background: linear-gradient(160deg, rgba(12,8,20,0.97) 0%, rgba(18,10,30,0.96) 50%, rgba(10,6,18,0.98) 100%);
  border: 1px solid rgba(139,92,246,0.25);
  border-top: 1px solid rgba(200,160,255,0.18);
  border-radius: 24px;
  padding: 28px 24px 22px;
  width: 100%; max-height: 92vh;
  overflow-y: auto; overflow-x: hidden;
  box-shadow: 0 32px 80px rgba(0,0,0,0.85), 0 0 0 1px rgba(109,40,217,0.12), inset 0 1px 0 rgba(255,255,255,0.06);
  animation: modalBlast 0.38s cubic-bezier(0.34,1.4,0.64,1) both;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
@keyframes modalBlast {
  0%   { opacity: 0; transform: scale(0.88) translateY(28px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
.modal::before {
  content: ''; position: absolute; top: 0; left: 5%; right: 5%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(200,160,255,0.35), rgba(245,158,11,0.2), rgba(200,160,255,0.35), transparent);
  border-radius: 99px;
}
.modal::-webkit-scrollbar { width: 3px; }
.modal::-webkit-scrollbar-thumb { background: rgba(139,92,246,0.4); border-radius: 3px; }

@media (max-width: 480px) {
  .modal {
    padding: 20px 16px calc(18px + env(safe-area-inset-bottom));
    border-radius: 18px;
    max-height: 96vh;
  }
  .modal-fire-container { max-width: 100%; }
  #fire-bg-canvas, #fire-canvas, #cart-fire-sides { display: none !important; }
  .modal-confirm-details { flex-direction: column; gap: 6px; }
  .modal-confirm-price { font-size: 1.2rem; }
  .modal-proceed-btn { padding: 13px 10px; font-size: 0.82rem; }
}

/* ── MODAL CLOSE ── */
.modal-close {
  background: rgba(139,92,246,0.12) !important;
  border: 1px solid rgba(139,92,246,0.28) !important;
  color: rgba(200,180,255,0.8) !important;
  border-radius: 10px !important;
  width: 32px !important; height: 32px !important;
  z-index: 10 !important;
  transition: all 0.2s !important;
  font-size: 0.85rem !important;
}
.modal-close:hover {
  background: rgba(139,92,246,0.28) !important;
  color: #fff !important;
  transform: scale(1.08) rotate(90deg) !important;
}

/* ── MODAL HEADER ── */
.modal-card-header {
  background: linear-gradient(135deg, rgba(109,40,217,0.15) 0%, rgba(245,158,11,0.08) 100%) !important;
  border: 1px solid rgba(139,92,246,0.20) !important;
  border-radius: 16px !important;
  padding: 14px 16px !important;
  margin-bottom: 12px !important;
  display: flex; align-items: center; justify-content: space-between;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05) !important;
  position: relative; overflow: hidden;
}
.modal-card-name-big {
  font-family: 'Syne', sans-serif; font-size: 0.9rem; font-weight: 800;
  color: #fff; letter-spacing: 1px; text-transform: uppercase;
}
.modal-card-sub {
  font-size: 0.65rem; color: rgba(196,181,253,0.6);
  letter-spacing: 2px; text-transform: uppercase; margin-top: 3px;
  font-family: 'Outfit', sans-serif;
}

/* ── MODAL CONFIRM ── */
.modal-confirm-screen { padding: 0 !important; background: none !important; border: none !important; box-shadow: none !important; border-radius: 0 !important; }
.modal-confirm-icon {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, #059669, #10b981);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; color: #fff; font-weight: 900;
  margin: 0 auto 14px;
  box-shadow: 0 8px 24px rgba(16,185,129,0.4);
}
.modal-confirm-title {
  font-family: 'Syne', sans-serif; font-size: 1.15rem; font-weight: 900;
  color: #fff; text-align: center; letter-spacing: 2px; text-transform: uppercase;
  margin-bottom: 6px;
}
.modal-confirm-sub {
  font-family: 'Outfit', sans-serif; font-size: 0.75rem;
  color: rgba(196,181,253,0.8); text-align: center;
  letter-spacing: 1px; text-transform: uppercase;
  margin-bottom: 14px; font-weight: 600;
}
.modal-confirm-prod { font-family: 'Syne', sans-serif; font-size: 0.9rem; font-weight: 800; color: #fff; letter-spacing: 1px; text-transform: uppercase; }
.modal-confirm-price { font-family: 'Space Mono', monospace; font-size: 1.3rem; font-weight: 900; color: var(--gold2); letter-spacing: 1px; }
.modal-confirm-details {
  background: rgba(255,255,255,0.03) !important;
  border: 1px solid rgba(139,92,246,0.15) !important;
  border-radius: 14px !important;
  padding: 16px !important;
  box-shadow: none !important;
  margin: 12px 0 !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ── MODAL DETAILS BOX ── */
.modal-details-box, .modal-price-row, .modal-data-block, .contact-link {
  background: rgba(255,255,255,0.03) !important;
  border: 1px solid rgba(139,92,246,0.14) !important;
  border-radius: 14px !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}
.modal-detail-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 9px 14px;
  border-bottom: 1px solid rgba(139,92,246,0.08) !important;
}
.modal-detail-row:last-child { border-bottom: none !important; }
.modal-detail-label {
  font-family: 'Outfit', sans-serif; font-size: 0.65rem; font-weight: 700;
  color: rgba(180,150,255,0.65); text-transform: uppercase; letter-spacing: 1.8px;
}
.modal-detail-value {
  font-family: 'Space Mono', monospace; font-weight: 700;
  color: #f0f0ff; letter-spacing: 1.2px; font-size: 0.84rem;
}
.bin-value { background: rgba(109,40,217,0.12); border: 1px solid rgba(139,92,246,0.22) !important; border-radius: 6px; padding: 2px 10px; color: #c4b5fd; font-size: 0.84rem; letter-spacing: 2px; }
.saldo-value { color: #34d399 !important; font-size: 0.96rem; font-family: 'Outfit', sans-serif; font-weight: 800; }

/* ── MODAL PRICE ROW ── */
.modal-price-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 16px; margin-bottom: 10px;
  position: relative; overflow: hidden;
}
.modal-price-label { font-family: 'Outfit', sans-serif; font-size: 0.65rem; font-weight: 700; color: rgba(180,150,255,0.65); text-transform: uppercase; letter-spacing: 1.5px; }
.modal-price-big { font-family: 'Outfit', sans-serif; font-size: 1.6rem; font-weight: 900; color: var(--gold2); }
.modal-price-currency { font-size: 0.75rem; font-weight: 700; vertical-align: super; margin-right: 2px; color: var(--gold); }

/* ── MODAL CONTACT TITLE ── */
.modal-contact-title {
  font-family: 'Outfit', sans-serif; font-size: 0.58rem; font-weight: 800;
  color: rgba(180,150,255,0.55); text-transform: uppercase;
  letter-spacing: 3px; margin: 14px 0 8px; text-align: center;
}

/* ── MODAL PROCEED BTN ── */
.modal-proceed-btn {
  width: 100%;
  background: linear-gradient(135deg, var(--accent) 0%, #7c3aed 40%, #6d28d9 70%, #4c1d95 100%) !important;
  color: #fff !important; border: none !important; border-radius: 14px !important;
  padding: 15px !important; font-family: 'Syne', sans-serif !important;
  font-size: 0.88rem !important; font-weight: 800 !important; cursor: pointer !important;
  letter-spacing: 1.5px !important; text-transform: uppercase !important;
  position: relative !important; overflow: hidden !important;
  box-shadow: 0 8px 32px rgba(109,40,217,0.55), inset 0 1px 0 rgba(255,255,255,0.15) !important;
  transition: all 0.2s !important;
  touch-action: manipulation;
  min-height: 48px;
}
.modal-proceed-btn::after {
  content: ''; position: absolute; top: 0; left: -120%; width: 60%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.18), transparent);
  transform: skewX(-20deg);
  animation: btnSweep 2.8s ease-in-out infinite;
}
@keyframes btnSweep { 0% { left: -120%; } 60% { left: 140%; } 100% { left: 140%; } }
.modal-proceed-btn:hover {
  transform: scale(1.02) translateY(-2px) !important;
  box-shadow: 0 12px 40px rgba(109,40,217,0.70), inset 0 1px 0 rgba(255,255,255,0.2) !important;
}

/* ── MODAL H2 ── */
.modal h2 {
  font-family: 'Syne', sans-serif !important; font-size: 1.15rem !important;
  font-weight: 800 !important; letter-spacing: 2px; text-align: center;
  text-transform: uppercase;
  background: linear-gradient(135deg, #f0f0ff 0%, #c4b5fd 40%, #a78bfa 70%, #fbbf24 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  margin-bottom: 4px !important;
  filter: drop-shadow(0 0 20px rgba(139,92,246,0.4));
}
.modal p { color: rgba(180,160,255,0.65) !important; font-size: 0.78rem !important; text-align: center; margin-bottom: 16px !important; }
.modal-icon { font-size: 1.8rem; text-align: center; display: block; margin-bottom: 4px; }

/* ── CONTACT LINKS (modal) ── */
.contact-link {
  display: flex !important; align-items: center !important; gap: 12px !important;
  border-radius: 14px !important; padding: 12px 14px !important;
  text-decoration: none !important; color: #f0f0ff !important;
  transition: all 0.22s !important; margin-bottom: 6px !important;
}
.contact-link:hover { transform: translateX(4px) !important; background: rgba(139,92,246,0.10) !important; border-color: rgba(139,92,246,0.30) !important; }
.contact-link-icon { width: 36px; height: 36px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; flex-shrink: 0; }
.contact-link-label { font-family: 'Outfit', sans-serif; font-size: 0.68rem; font-weight: 700; color: rgba(180,150,255,0.7); text-transform: uppercase; letter-spacing: 1.5px; }
.contact-link-value { font-family: 'DM Sans', sans-serif; font-size: 0.82rem; color: #f0f0ff; margin-top: 2px; }
.contact-link-arrow { font-size: 0.9rem; color: rgba(180,150,255,0.4); margin-left: auto; }

/* ── MODAL ICON FIRE ── */
#fire-bg-canvas { display: none; }
#fire-canvas { display: none; }
.ember-particle { display: none !important; }
#cart-wrap { background: none !important; }

/* ── HEADER CREDIT CHIP ── */
#header-credit-chip {
  animation: fadeIn 0.5s ease both;
}


/* ══════════════════════════════════════════════════════════════
   FENIX STORE — MELHORIAS 10/10
   Acessibilidade, reduced-motion, focus-visible, print
══════════════════════════════════════════════════════════════ */

/* ── REDUCED MOTION — respeita preferência do sistema ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  #fxWall img { animation: none !important; }
  .fire-letter-group { animation: none !important; }
  .splash-bar { animation: none !important; width: 100% !important; }
}

/* ── FOCUS VISIBLE — acessibilidade teclado ── */
:focus-visible {
  outline: 2px solid var(--accent2) !important;
  outline-offset: 3px !important;
  border-radius: 4px;
}
button:focus:not(:focus-visible),
a:focus:not(:focus-visible),
input:focus:not(:focus-visible) {
  outline: none;
}

/* ── HIGH CONTRAST — suporte a modo alto contraste ── */
@media (forced-colors: active) {
  .buy-btn, .modal-proceed-btn, .btn-primary {
    border: 2px solid ButtonText !important;
  }
  .gift-card {
    border: 1px solid ButtonText !important;
  }
}

/* ── PRINT — ocultar elementos desnecessários ── */
@media print {
  header, .chat-fab, #pwa-install-banner, #lgpd-banner,
  #push-banner, .perfil-overlay, .avatar-picker,
  #flip-overlay, .modal-overlay, #fenix-chat,
  #splash-screen, #fxWall, .orb1, .orb2 {
    display: none !important;
  }
  body { background: white !important; color: black !important; }
  .gift-card { border: 1px solid #ccc !important; break-inside: avoid; }
}

/* ── LAZY IMAGE FADE IN ── */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity 0.4s ease;
}
img[loading="lazy"].loaded {
  opacity: 1;
}

/* ── SCROLLBAR MOBILE — ocultar para UX limpa ── */
@media (max-width: 768px) {
  ::-webkit-scrollbar { display: none; }
  * { -ms-overflow-style: none; scrollbar-width: none; }
}

/* ── SELECTION COLOR ── */
::selection {
  background: rgba(109,40,217,0.4);
  color: #fff;
}
::-moz-selection {
  background: rgba(109,40,217,0.4);
  color: #fff;
}

/* ── TOUCH FEEDBACK MOBILE ── */
@media (hover: none) and (pointer: coarse) {
  .buy-btn:active     { transform: scale(0.95) !important; background: #4c1d95 !important; }
  .gift-card:active   { transform: scale(0.98) !important; }
  .contact-pill:active { opacity: 0.8; }
  .ffilter-btn:active { opacity: 0.7; }
}

/* ── SAFE AREA MELHORADA ── */
.cards-grid {
  padding-bottom: max(120px, calc(120px + env(safe-area-inset-bottom)));
}
footer {
  padding-bottom: max(24px, calc(24px + env(safe-area-inset-bottom)));
}

/* ── CARDS GRID RESPONSIVO ── */
@media (min-width: 1200px) {
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  }
}
@media (min-width: 1600px) {
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 28px;
  }
}

/* ── MODAL MOBILE CENTRALIZADO ── */
@media (max-width: 768px) {
  .modal-overlay {
    align-items: center !important;
  }
  .modal-fire-container {
    max-width: calc(100vw - 32px) !important;
  }
}

/* ── HEADER CREDIT CHIP ANIMADO ── */
#header-credit-chip {
  transition: all 0.3s ease;
}
#header-credit-chip:hover {
  background: rgba(16,185,129,0.2) !important;
  transform: scale(1.02);
}

/* ── FLIP OVERLAY MOBILE FIX (reforço) ── */
@media (max-width: 768px) {
  #flip-overlay {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    will-change: transform;
  }
  #flip-buy-btn {
    position: relative !important;
    z-index: 20 !important;
    touch-action: manipulation !important;
    -webkit-tap-highlight-color: transparent !important;
    min-height: 52px !important;
    font-size: 0.88rem !important;
  }
  #flip-card-3d {
    width: min(340px, 90vw) !important;
  }
}


/* ══════════════════════════════════════════════════════════════
   FENIX STORE — OTIMIZAÇÕES PERFORMANCE MOBILE v2
   Corrige lentidão em celulares mid/low-end
══════════════════════════════════════════════════════════════ */

/* ── Desativar backdrop-filter em todos os elementos no mobile ── */
/* backdrop-filter é MUITO pesado em GPU mobile (Snapdragon 600-700) */
@media (max-width: 768px) {
  .gift-card,
  .stats-bar,
  .input, input.input,
  header, .admin-header,
  .modal-overlay,
  #flip-overlay,
  .perfil-modal,
  .offline-wrap,
  .box {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  /* Reduzir sombras complexas no mobile */
  .gift-card {
    box-shadow: 0 4px 16px rgba(0,0,0,0.5) !important;
  }

  /* Desativar tilt 3D — já feito no JS mas CSS garante */
  .gift-card {
    transform: none !important;
    transition: opacity 0.2s !important;
  }
  .gift-card:hover {
    transform: none !important;
  }

  /* Simplificar animação do wallpaper no mobile */
  #fxWall img {
    animation: none !important;
    filter: saturate(1.1) brightness(0.9) !important;
  }
  #fxWall .fx-colorgrade {
    animation: none !important;
  }

  /* Desativar orbs de gradiente (GPU desnecessário) */
  .orb1, .orb2 {
    display: none !important;
  }

  /* Simplificar animações de cards */
  .gift-card-wrap {
    animation: cardRevealSimple 0.2s ease both !important;
  }
  @keyframes cardRevealSimple {
    from { opacity: 0; }
    to   { opacity: 1; }
  }

  /* Reduzir will-change no mobile (libera memória GPU) */
  .gift-card,
  #fxWall img,
  .fire-letter-group {
    will-change: auto !important;
  }

  /* Header mais leve no mobile */
  header {
    backdrop-filter: none !important;
    background: rgba(5,5,10,0.95) !important;
  }

  /* Splash screen mais rápida */
  #splash-screen {
    animation-duration: 0.5s !important;
  }

  /* Modal sem animação de entrada complexa no mobile */
  .modal {
    animation: modalBlastMobile 0.2s ease both !important;
  }
  @keyframes modalBlastMobile {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
  }
}

/* ── Para celulares MUITO lentos (low-end) ── */
@media (max-width: 768px) and (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
  #fxWall { display: none !important; }
  body { background: #05050a !important; }
}

/* ── Otimizar imagens lazy no CSS ── */
img[loading="lazy"] {
  content-visibility: auto;
}

/* ── Conteúdo abaixo do fold: renderizar só quando visível ── */
.cards-grid .gift-card-wrap {
  content-visibility: auto;
  contain-intrinsic-size: 0 350px;
}


/* ══════════════════════════════════════════════════════════════
   CHAT FAB — Botão flutuante de suporte (FIX DEFINITIVO)
   Força posição e oculta qualquer texto residual
══════════════════════════════════════════════════════════════ */
button#chat-fab,
button.chat-fab,
#chat-fab {
  position: fixed !important;
  bottom: 88px !important;
  right: 28px !important;
  left: auto !important;
  top: auto !important;
  z-index: 9500 !important;
  width: 52px !important;
  height: 52px !important;
  min-width: 52px !important;
  min-height: 52px !important;
  border-radius: 50% !important;
  background: linear-gradient(135deg, #25d366, #128c7e) !important;
  border: none !important;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 8px 24px rgba(37,211,102,0.4) !important;
  transition: transform 0.2s, box-shadow 0.2s !important;
  padding: 0 !important;
  margin: 0 !important;
  /* Ocultar qualquer texto/tooltip visível */
  font-size: 0 !important;
  color: transparent !important;
  text-indent: -9999px !important;
  overflow: hidden !important;
}
/* Restaurar o SVG dentro do botão */
button#chat-fab svg,
button.chat-fab svg,
#chat-fab svg {
  text-indent: 0 !important;
  font-size: 16px !important;
  width: 24px !important;
  height: 24px !important;
  flex-shrink: 0 !important;
  display: block !important;
  color: #fff !important;
}
/* Hover */
button#chat-fab:hover,
button.chat-fab:hover,
#chat-fab:hover {
  transform: scale(1.1) !important;
  box-shadow: 0 12px 32px rgba(37,211,102,0.55) !important;
}
/* Mobile — subir para não cobrir navegação do browser */
@media (max-width: 768px) {
  button#chat-fab,
  button.chat-fab,
  #chat-fab {
    bottom: max(80px, calc(80px + env(safe-area-inset-bottom))) !important;
    right: 16px !important;
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    min-height: 48px !important;
  }
}
