/* ============================================================
   Bivia — Estilo compartilhado
   Tema: gradiente roxo, glassmorphism, moderno e premium
   ============================================================ */

:root {
    --purple-900: #2a0a4a;
    --purple-700: #5b21b6;
    --purple-600: #7c3aed;
    --purple-500: #8b5cf6;
    --purple-400: #a78bfa;
    --purple-300: #c4b5fd;
    --pink-400: #e879f9;

    --grad-main: linear-gradient(135deg, #7c3aed 0%, #a855f7 45%, #e879f9 100%);
    --grad-soft: linear-gradient(160deg, #faf5ff 0%, #f3e8ff 100%);
    --grad-dark: linear-gradient(160deg, #1a0533 0%, #2a0a4a 55%, #3b0d63 100%);

    --text-main: #1d1d1f;
    --text-muted: #6b6477;
    --text-on-dark: #f5f0ff;
    --text-on-dark-muted: #c4b5fd;

    --bg: #ffffff;
    --card-bg: rgba(255, 255, 255, 0.7);
    --border: rgba(124, 58, 237, 0.14);

    --radius: 24px;
    --shadow-soft: 0 20px 60px -20px rgba(124, 58, 237, 0.35);
    --shadow-card: 0 10px 40px -12px rgba(124, 58, 237, 0.22);

    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    background: var(--grad-soft);
    color: var(--text-main);
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    line-height: 1.6;
}

/* ---------- Fundo decorativo com orbs ---------- */
.orbs {
    position: fixed;
    inset: 0;
    overflow: hidden;
    z-index: -1;
    pointer-events: none;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    animation: float 18s ease-in-out infinite;
}

.orb-1 {
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, #c4b5fd, transparent 70%);
    top: -120px;
    left: -100px;
}

.orb-2 {
    width: 420px;
    height: 420px;
    background: radial-gradient(circle, #e879f9, transparent 70%);
    bottom: -140px;
    right: -120px;
    animation-delay: -6s;
}

.orb-3 {
    width: 360px;
    height: 360px;
    background: radial-gradient(circle, #a78bfa, transparent 70%);
    top: 40%;
    left: 55%;
    animation-delay: -11s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(30px, -40px) scale(1.08); }
}

/* ---------- Cabeçalho / Navbar ---------- */
.navbar {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px clamp(20px, 5vw, 60px);
    background: rgba(255, 255, 255, 0.65);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid var(--border);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.brand img {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    box-shadow: var(--shadow-card);
}

.brand span {
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    background: var(--grad-main);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ---------- Seletor de idioma ---------- */
.lang-switch {
    position: relative;
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.7);
    color: var(--purple-700);
    font-family: var(--font);
    font-weight: 600;
    font-size: 0.9rem;
    padding: 9px 14px;
    border-radius: 999px;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.lang-btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-card);
}

.lang-btn svg {
    width: 14px;
    height: 14px;
}

.lang-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow-soft);
    padding: 6px;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.lang-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-menu button {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    border: none;
    background: none;
    font-family: var(--font);
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-main);
    padding: 10px 12px;
    border-radius: 10px;
    cursor: pointer;
    text-align: left;
    transition: background 0.15s ease;
}

.lang-menu button:hover {
    background: #f3e8ff;
}

.lang-menu button.active {
    background: var(--grad-main);
    color: #fff;
}

.flag {
    font-size: 1.2rem;
    line-height: 1;
}

/* ---------- Botões ---------- */
.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--grad-main);
    color: #fff;
    padding: 16px 34px;
    border-radius: 999px;
    font-size: 1.08rem;
    font-weight: 700;
    text-decoration: none;
    border: none;
    cursor: pointer;
    box-shadow: 0 14px 34px -10px rgba(124, 58, 237, 0.6);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-button:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 20px 44px -10px rgba(124, 58, 237, 0.7);
}

.cta-button svg {
    width: 22px;
    height: 22px;
}

.cta-ghost {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--purple-700);
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid var(--border);
    padding: 15px 28px;
    border-radius: 999px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-ghost:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-card);
}

/* ---------- Hero ---------- */
main {
    flex: 1;
}

.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: clamp(50px, 9vw, 110px) 20px clamp(40px, 6vw, 70px);
    max-width: 900px;
    margin: 0 auto;
}

.hero-logo {
    width: 130px;
    height: 130px;
    border-radius: 32px;
    box-shadow: var(--shadow-soft);
    margin-bottom: 30px;
    animation: pop 0.7s cubic-bezier(.2,.8,.2,1) both;
}

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

.pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid var(--border);
    color: var(--purple-700);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 7px 16px;
    border-radius: 999px;
    margin-bottom: 22px;
}

.hero h1 {
    font-size: clamp(2.6rem, 7vw, 4.6rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.02;
    margin: 0 0 20px;
}

.hero h1 .grad {
    background: var(--grad-main);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    font-size: clamp(1.05rem, 2.4vw, 1.3rem);
    color: var(--text-muted);
    max-width: 580px;
    margin: 0 auto 38px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
}

.stat-row {
    display: flex;
    gap: clamp(28px, 6vw, 60px);
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 56px;
}

.stat strong {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    background: var(--grad-main);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat span {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* ---------- Seção de features ---------- */
.section {
    max-width: 1080px;
    margin: 0 auto;
    padding: clamp(40px, 7vw, 80px) clamp(20px, 5vw, 40px);
}

.section-title {
    text-align: center;
    font-size: clamp(1.8rem, 4.5vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    margin: 0 0 14px;
}

.section-sub {
    text-align: center;
    color: var(--text-muted);
    max-width: 560px;
    margin: 0 auto 50px;
    font-size: 1.05rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 22px;
}

.card {
    background: var(--card-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 30px;
    box-shadow: var(--shadow-card);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-soft);
}

.card-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: var(--grad-main);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
    font-size: 1.7rem;
}

.card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 0 8px;
}

.card p {
    color: var(--text-muted);
    margin: 0;
    font-size: 0.98rem;
}

/* ---------- CTA final ---------- */
.cta-band {
    margin: clamp(30px, 6vw, 60px) clamp(20px, 5vw, 40px);
    max-width: 1080px;
    margin-left: auto;
    margin-right: auto;
    background: var(--grad-dark);
    border-radius: 34px;
    padding: clamp(46px, 7vw, 80px) 30px;
    text-align: center;
    color: var(--text-on-dark);
    box-shadow: var(--shadow-soft);
}

.cta-band h2 {
    font-size: clamp(1.8rem, 4.5vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    margin: 0 0 14px;
}

.cta-band p {
    color: var(--text-on-dark-muted);
    max-width: 520px;
    margin: 0 auto 32px;
    font-size: 1.08rem;
}

/* ---------- Páginas de conteúdo (legal/suporte) ---------- */
.content {
    max-width: 760px;
    margin: 0 auto;
    padding: clamp(40px, 7vw, 70px) clamp(20px, 5vw, 30px);
}

.content-card {
    background: var(--card-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(30px, 5vw, 56px);
    box-shadow: var(--shadow-card);
}

.content h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    margin: 0 0 8px;
}

.content .updated {
    color: var(--purple-600);
    font-weight: 600;
    font-size: 0.9rem;
    margin: 0 0 30px;
}

.content h2 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 36px 0 12px;
    letter-spacing: -0.02em;
}

.content h3 {
    font-size: 1.12rem;
    font-weight: 700;
    color: var(--purple-700);
    margin: 24px 0 8px;
}

.content p, .content li {
    color: #3f3a4a;
    font-size: 1.02rem;
}

.content ul {
    padding-left: 22px;
}

.content li {
    margin-bottom: 8px;
}

.content a {
    color: var(--purple-600);
    font-weight: 600;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--purple-600);
    font-weight: 600;
    text-decoration: none;
    margin-bottom: 26px;
    font-size: 0.95rem;
}

.back-link:hover { text-decoration: underline; }

.contact-box {
    margin-top: 30px;
    padding: 22px 26px;
    background: var(--grad-soft);
    border: 1px solid var(--border);
    border-radius: 18px;
}

.contact-box a { word-break: break-all; }

/* ---------- Rodapé ---------- */
footer {
    margin-top: auto;
    padding: 46px 20px 40px;
    border-top: 1px solid var(--border);
    text-align: center;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
}

.footer-brand img { width: 32px; height: 32px; border-radius: 9px; }

.footer-brand span {
    font-weight: 800;
    font-size: 1.1rem;
    background: var(--grad-main);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 24px;
    margin-bottom: 18px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.footer-links a:hover { color: var(--purple-600); }

.copyright {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0;
}

/* ---------- Animação de entrada ---------- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    *, .orb { animation: none !important; transition: none !important; }
    .reveal { opacity: 1; transform: none; }
}

/* ---------- Botão Android (lista de espera) ---------- */
.cta-android {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.85);
    color: var(--purple-700);
    border: 1.5px solid var(--purple-300);
    padding: 15px 28px;
    border-radius: 999px;
    font-size: 1rem;
    font-weight: 700;
    font-family: var(--font);
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cta-android:hover { transform: translateY(-2px); box-shadow: var(--shadow-card); }
.cta-android svg { width: 20px; height: 20px; }

/* Quando o visitante está no Android, o botão vira destaque */
body.is-android .cta-android {
    background: var(--grad-main);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 14px 34px -10px rgba(124, 58, 237, 0.6);
}

/* ---------- Modal da lista de espera ---------- */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(42, 10, 74, 0.45);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s;
}

.modal-overlay.open { opacity: 1; visibility: visible; }

.modal {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border-radius: 28px;
    padding: clamp(28px, 5vw, 40px);
    box-shadow: var(--shadow-soft);
    transform: translateY(16px) scale(0.97);
    transition: transform 0.25s cubic-bezier(.2,.8,.2,1);
    position: relative;
}

.modal-overlay.open .modal { transform: translateY(0) scale(1); }

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border: none;
    background: #f3e8ff;
    color: var(--purple-700);
    border-radius: 50%;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    transition: background 0.15s ease;
}
.modal-close:hover { background: #e9d5ff; }

.modal-icon {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    background: var(--grad-main);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
}
.modal-icon svg { width: 32px; height: 32px; color: #fff; }

.modal h2 {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0 0 8px;
}
.modal p { color: var(--text-muted); margin: 0 0 22px; }

/* Esconde o conteúdo até o i18n aplicar o idioma (evita flash de idioma). */
html.i18n-loading body { visibility: hidden; }

.waitlist-form { display: flex; flex-direction: column; gap: 12px; }

/* Honeypot anti-spam: fora da tela, invisível para usuários reais */
.hp-field {
    position: absolute !important;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.waitlist-form input {
    width: 100%;
    padding: 14px 16px;
    border: 1.5px solid var(--border);
    border-radius: 14px;
    font-size: 1rem;
    font-family: var(--font);
    background: #faf5ff;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.waitlist-form input:focus {
    outline: none;
    border-color: var(--purple-500);
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.15);
}
/* Campo de telefone internacional (intl-tel-input) ocupa a largura toda. */
.waitlist-form .iti { width: 100%; }
.waitlist-form .iti input[type=tel] { width: 100%; }
.waitlist-form .iti__selected-dial-code { color: var(--ink, #1e1b2e); }

.waitlist-form button {
    margin-top: 6px;
    background: var(--grad-main);
    color: #fff;
    border: none;
    padding: 15px;
    border-radius: 14px;
    font-size: 1.05rem;
    font-weight: 700;
    font-family: var(--font);
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease;
}
.waitlist-form button:hover { transform: translateY(-1px); }
.waitlist-form button:disabled { opacity: 0.6; cursor: default; transform: none; }

.form-message {
    margin: 14px 0 0;
    font-size: 0.95rem;
    font-weight: 600;
    text-align: center;
}
.form-message.ok { color: #16a34a; }
.form-message.err { color: #dc2626; }
.form-note {
    margin-top: 14px;
    font-size: 0.78rem;
    color: var(--text-muted);
    text-align: center;
}

/* ---------- Acessibilidade: foco visível por teclado ---------- */
a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--purple-500);
    outline-offset: 3px;
    border-radius: 6px;
}
