/* ==================== CONFIGURAÇÕES TEMA MÍSTICO ==================== */
:root {
    --mystic-purple: #2e1065;
    --magic-gold: #fbbf24;
    --magic-gold-dark: #d97706;
    --deep-indigo: #1e1b4b;
    --dark-purple: #4c1d95;
    --text-light: #f8fafc;
    --text-muted: #94a3b8;
    --shadow-magic: 0 0 20px rgba(251, 191, 36, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

body {
    background: radial-gradient(circle at center, #4c1d95 0%, #1e1b4b 100%);
    background-attachment: fixed;
    color: var(--text-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 1.5rem;
}

.container {
    max-width: 500px;
    width: 100%;
}

/* ==================== TIPOGRAFIA ==================== */
.title-wrapper { 
    text-align: center; 
    margin-bottom: 2rem;
}

.title {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #fbbf24 0%, #d97706 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.3);
}

.subtitle { 
    color: #a78bfa; 
    font-weight: 500; 
    margin-top: 0.5rem;
}

/* ==================== CARDS ==================== */
.stats-card, .form-card {
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(12px);
    border-radius: 1.5rem;
    padding: 1.5rem;
    border: 1px solid rgba(251, 191, 36, 0.2);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    margin-bottom: 1.5rem;
}

.stat-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.75rem;
    border-radius: 1rem;
    text-align: center;
    border: 1px solid rgba(251, 191, 36, 0.1);
}

.stat-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.stat-value { 
    font-size: 1.75rem; 
    font-weight: 800; 
    color: var(--magic-gold);
}

/* Barra de Progresso */
.progress-container {
    width: 100%;
    background: rgba(0,0,0,0.3);
    height: 8px;
    border-radius: 10px;
    margin: 1rem 0;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #fbbf24, #f59e0b);
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
    transition: width 0.5s ease;
}

/* ==================== CARD 3D ==================== */
.card-3d { 
    perspective: 1200px; 
    height: 300px; 
    margin-bottom: 2rem;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
    cursor: pointer;
}

.card-inner.flipped { transform: rotateY(180deg); }

.card-front, .card-back {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    border-radius: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    text-align: center;
}

.card-front {
    background: #fef3c7;
    border: 3px double #d97706;
    color: #451a03;
}

.card-back {
    background: linear-gradient(135deg, #4338ca, #2e1065);
    color: white;
    transform: rotateY(180deg);
    border: 2px solid var(--magic-gold);
}

.card-question {
    font-size: 1.2rem;
    font-weight: 600;
    line-height: 1.5;
    margin-top: 1rem;
}

.card-answer {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--magic-gold);
    margin-top: 1rem;
}

/* ==================== BOTÕES ==================== */
.btn {
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-primary { 
    background: var(--magic-gold); 
    color: var(--mystic-purple); 
    width: 100%; 
    margin-bottom: 10px;
}

.btn-success { 
    background: #10b981; 
    color: white; 
    flex: 1;
}

.btn-danger { 
    background: #ef4444; 
    color: white; 
    flex: 1;
}

.btn:hover { 
    transform: translateY(-2px); 
    filter: brightness(1.05);
}

.btn:active {
    transform: translateY(0);
}

/* ==================== FORMULÁRIO ==================== */
.input-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--magic-gold);
}

.input-field {
    width: 100%;
    padding: 0.8rem;
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-radius: 0.8rem;
    color: white;
    margin-top: 0.25rem;
    margin-bottom: 1rem;
    transition: all 0.2s;
}

.input-field:focus { 
    outline: none; 
    border-color: var(--magic-gold); 
    box-shadow: var(--shadow-magic);
}

.input-field::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

/* Tip Box */
.tip-box {
    background: rgba(251, 191, 36, 0.1) !important;
    border-left: 3px solid var(--magic-gold);
}

/* Links */
.btn-link, .btn-back {
    text-decoration: none;
    color: var(--magic-gold);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: inline-block;
    transition: all 0.2s;
}

.btn-link:hover, .btn-back:hover {
    color: #fef08a;
    transform: translateX(-3px);
}

/* Botão resetar */
#btn-resetar {
    background: none;
    border: none;
    color: #6b7280;
    width: 100%;
    margin-top: 20px;
    cursor: pointer;
    padding: 0.5rem;
    transition: all 0.2s;
}

#btn-resetar:hover {
    color: #f87171;
}

/* ==================== RESPONSIVIDADE ==================== */
@media (max-width: 640px) {
    body {
        padding: 1rem;
    }
    
    .title {
        font-size: 1.8rem;
    }
    
    .card-3d {
        height: 260px;
    }
    
    .card-question {
        font-size: 1rem;
    }
    
    .card-answer {
        font-size: 1.1rem;
    }
    
    .stats-card, .form-card {
        padding: 1rem;
    }
    
    .stat-value {
        font-size: 1.25rem;
    }
}

/* ==================== UTILITÁRIOS ==================== */
.scale-95 {
    transform: scale(0.95);
}

.bg-emerald-500 { background: #10b981; }
.bg-yellow-500 { background: #f59e0b; }
.bg-red-500 { background: #ef4444; }

.fixed {
    position: fixed;
}

.animate-bounce {
    animation: bounce 0.5s ease;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(-10px); }
}