:root {
  --brand: #4C7DFF;
  --bg: #0A0A0A;
  --card: rgba(255, 255, 255, 0.045);
  --card-border: rgba(255, 255, 255, 0.09);
  --text: #F8FAFC;
  --text-muted: #9CA3AF;
  --legal-text: #D1D5DB;
  --radius: 22px;
}

/* Tema claro, alternado pelo botão no topo (mesmo par dark/light do app). */
html[data-theme="light"] {
  --bg: #F8FAFC;
  --card: #FFFFFF;
  --card-border: #E5E5E5;
  --text: #171717;
  --text-muted: #737373;
  --legal-text: #404040;
}
html[data-theme="light"] .glass { box-shadow: 0 16px 40px -12px rgba(0,0,0,0.12); }
html[data-theme="light"] .site-bottom-nav { background: rgba(255,255,255,0.85); box-shadow: 0 16px 36px -10px rgba(0,0,0,0.18), 0 4px 14px -2px rgba(0,0,0,0.08); }
html[data-theme="light"] .nav-icon { color: rgba(23,23,23,0.6); }
html[data-theme="light"] .nav-icon.active { background: rgba(23,23,23,0.08); color: #171717; }

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  overflow-x: hidden;
}

body { padding-bottom: 100px; } /* espaço pra pílula flutuante não cobrir conteúdo, igual ao app (pb-20) */

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ---- Liquid glass ---- */
.glass {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  backdrop-filter: blur(24px) saturate(140%);
  -webkit-backdrop-filter: blur(24px) saturate(140%);
  box-shadow: 0 16px 40px -12px rgba(0, 0, 0, 0.6);
}

/* ---- Cabeçalho mínimo (tema + notificações, mesmo visual do Header.tsx do app) ---- */
.site-topbar {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  padding: 16px 20px 0;
}
.site-topbar button {
  display: flex;
  height: 36px;
  width: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  border: none;
  background: var(--card);
  color: var(--text-muted);
  cursor: pointer;
}

.notif-wrapper { position: relative; }
.notif-panel {
  position: absolute;
  right: 0;
  top: 44px;
  z-index: 60;
  width: 260px;
  padding: 16px;
}
.notif-panel p { margin: 0; color: var(--text-muted); font-size: 14px; }

/* ---- Pílula flutuante inferior (mesmo visual do BottomNav.tsx do app) ---- */
.site-bottom-nav {
  position: fixed;
  left: 20px;
  right: 20px;
  bottom: 18px;
  z-index: 50;
  margin: 0 auto;
  max-width: 460px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px;
  border-radius: 9999px;
  background: rgba(22, 24, 34, 0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 16px 36px -10px rgba(0,0,0,0.5), 0 4px 14px -2px rgba(0,0,0,0.3);
}

.nav-icon {
  display: flex;
  height: 42px;
  max-width: 48px;
  flex: 1;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  color: rgba(255,255,255,0.7);
}
.nav-icon:hover { text-decoration: none; }
.nav-icon.active { background: rgba(255,255,255,0.16); color: #fff; }

.nav-center {
  margin-top: -24px;
  flex-shrink: 0;
  height: 64px;
  width: 64px;
  border-radius: 22%;
  box-shadow: 0 8px 20px -4px rgba(0,0,0,0.5);
  overflow: hidden;
}
.nav-center img { width: 100%; height: 100%; object-fit: contain; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--brand);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  padding: 14px 26px;
  border-radius: 16px;
  border: none;
  cursor: pointer;
}
.btn:hover { text-decoration: none; opacity: 0.92; }
.btn.secondary { background: transparent; border: 1px solid var(--card-border); color: var(--text); }

/* ---- Sections ---- */
section.block { padding: 40px 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (max-width: 720px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.feature-card, .product-card { padding: 22px; }
.feature-card h3 { margin: 12px 0 6px; font-size: 16px; }
.feature-card p, .product-card p { color: var(--text-muted); font-size: 14px; margin: 0; }
.feature-icon { width: 40px; height: 40px; border-radius: 12px; background: rgba(76,125,255,0.15); display: flex; align-items: center; justify-content: center; color: var(--brand); font-size: 20px; }

.product-card img { width: 100%; border-radius: 14px; aspect-ratio: 1.4; object-fit: cover; background: rgba(255,255,255,0.04); margin-bottom: 12px; }
.product-card h3 { margin: 0 0 4px; font-size: 15px; }
.product-price { color: var(--brand); font-weight: 700; margin: 8px 0; }

h2.section-title { font-size: 24px; font-weight: 800; margin: 0 0 6px; text-align: center; }
p.section-sub { color: var(--text-muted); text-align: center; margin: 0 0 28px; }

/* ---- Legal / institutional pages ---- */
.legal-page { padding: 40px 20px 80px; }
.legal-page h1 { font-size: 28px; margin-bottom: 4px; }
.legal-page .updated { color: var(--text-muted); font-size: 13px; margin-bottom: 28px; }
.legal-page h2 { font-size: 18px; color: var(--brand); margin-top: 32px; }
.legal-page p, .legal-page li { color: var(--legal-text); line-height: 1.7; font-size: 15px; }
.legal-page .content { padding: 32px; }

/* ---- Forms ---- */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field label { font-size: 13px; font-weight: 600; color: var(--text-muted); }
.field input, .field textarea {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 12px 14px;
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
}
.field textarea { resize: vertical; min-height: 120px; }
.honeypot-field { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

.alert { padding: 14px 16px; border-radius: 12px; font-size: 14px; margin-bottom: 16px; }
.alert.success { background: rgba(34,197,94,0.12); color: #4ADE80; border: 1px solid rgba(34,197,94,0.3); }
.alert.error { background: rgba(239,68,68,0.12); color: #F87171; border: 1px solid rgba(239,68,68,0.3); }

/* ---- Footer ---- */
footer.site-footer { padding: 40px 20px 60px; text-align: center; color: var(--text-muted); font-size: 13px; }
footer.site-footer a { color: var(--text-muted); }
footer.site-footer .links { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-bottom: 16px; }
