/* ============================================
   KIFRA V2 - CSS Auth PREMIUM (Simplificado)
   ============================================ */

* {
    -webkit-tap-highlight-color: transparent;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    color: #0f172a;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.auth-page {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 24px 20px;
    max-width: 420px;
    margin: 0 auto;
    width: 100%;
    animation: fadeInUp 0.5s ease;
}

/* Header */
.auth-header {
    text-align: center;
    margin-bottom: 32px;
    padding-top: 16px;
}

.auth-logo {
    margin-bottom: 28px;
    display: flex;
    justify-content: center;
}

.auth-logo-img {
    height: 56px;
    width: auto;
    display: block;
}

.auth-tagline {
    font-size: 26px;
    font-weight: 600;
    line-height: 1.3;
    color: #0f172a;
    text-align: center;
    letter-spacing: -0.5px;
}

.auth-tagline span {
    color: #22c55e;
    position: relative;
}

.auth-tagline span::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 0;
    width: 100%;
    height: 8px;
    background: rgba(34, 197, 94, 0.15);
    border-radius: 4px;
    z-index: -1;
}

/* Card */
.auth-card {
    background: #ffffff;
    border-radius: 24px;
    padding: 32px 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08), 0 16px 40px rgba(0,0,0,0.06);
    position: relative;
    overflow: hidden;
    animation: slideIn 0.4s ease 0.1s both;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #22c55e, #16a34a);
}

.auth-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 6px;
    color: #0f172a;
}

.auth-emoji {
    display: inline-block;
    animation: wave 2s ease infinite;
}

.auth-subtitle {
    font-size: 15px;
    color: #64748b;
    margin-bottom: 28px;
    line-height: 1.5;
}


/* Alertas */
.auth-alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 20px;
    padding: 12px 14px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.4;
    animation: fadeInUp 0.3s ease;
}

.auth-alert i {
    flex-shrink: 0;
    margin-top: 2px;
    font-size: 16px;
}

.auth-alert span {
    flex: 1;
}

.auth-alert-error {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fecaca;
}

.auth-alert-error i {
    color: #dc2626;
}

.auth-alert-success {
    color: #166534;
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.auth-alert-success i {
    color: #16a34a;
}

.auth-alert-warning {
    color: #92400e;
    background: #fffbeb;
    border-color: #fde68a;
}

.auth-alert-warning i {
    color: #d97706;
}

.auth-alert-info {
    color: #1e40af;
    background: #eff6ff;
    border-color: #bfdbfe;
}

.auth-alert-info i {
    color: #2563eb;
}


/* Inputs */
.input-group {
    margin-bottom: 16px;
    position: relative;
}

.input-group:focus-within {
    transform: translateY(-1px);
    transition: transform 0.2s ease;
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 18px;
    z-index: 2;
    transition: color 0.2s ease;
}

.input-group:focus-within .input-icon {
    color: #22c55e;
}

.input-field {
    width: 100%;
    padding: 15px 16px 15px 48px;
    border: 2px solid #e2e8f0;
    border-radius: 14px;
    font-size: 16px;
    color: #0f172a;
    background: #f8fafc;
    transition: all 0.2s ease;
    outline: none;
}

.input-field:hover {
    border-color: #cbd5e1;
    background: #ffffff;
}

.input-field:focus {
    border-color: #22c55e;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.08);
}

.input-field::placeholder {
    color: #94a3b8;
}

.input-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 18px;
    padding: 6px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.input-toggle:hover {
    color: #64748b;
    background: #f1f5f9;
}

/* Options */
.auth-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    font-size: 14px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    color: #475569;
    font-weight: 500;
}

.remember-me input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: #22c55e;
    cursor: pointer;
}

.forgot-link {
    color: #22c55e;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
}

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

/* Button */
.btn-primary {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #22c55e, #16a34a);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(34, 197, 94, 0.35);
}

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


.btn-primary:disabled {
    cursor: not-allowed;
    opacity: 0.8;
    transform: none;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.18);
}

.btn-primary:disabled:hover {
    transform: none;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.18);
}

/* Divider */
.auth-divider {
    display: flex;
    align-items: center;
    margin: 10px 0;
    color: #94a3b8;
    font-size: 13px;
    font-weight: 500;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, #e2e8f0, transparent);
}

.auth-divider span {
    padding: 0 16px;
}

/* Cadastro */
.auth-register {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-top: 22px;
    font-size: 14px;
    color: #64748b;
}

.auth-register-link {
    color: #22c55e;
    font-weight: 600;
    text-decoration: none;
}

.auth-register-link:hover {
    text-decoration: underline;
}

/* Footer */
.auth-footer {
    margin-top: 24px;
}

/* Social */
.social-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.btn-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 13px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #ffffff;
    color: #475569;
    font-size: 14px;
    font-weight: 500;
}

.btn-social-disabled {
    opacity: .42;
    cursor: not-allowed;
    filter: grayscale(.35);
}

.btn-social-disabled:hover {
    border-color: #e2e8f0;
    background: #ffffff;
    transform: none;
}

.social-caption {
    margin: 10px 0 0;
    text-align: center;
    color: #94a3b8;
    font-size: 12px;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes wave {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(20deg); }
    75% { transform: rotate(-10deg); }
}

/* Responsive */
@media (min-width: 480px) {
    .auth-page {
        padding: 40px 32px;
        justify-content: center;
    }
    
    .auth-tagline {
        font-size: 32px;
    }
    
    .auth-header {
        padding-top: 0;
    }
}



/* ============================================
   CADASTRO - Plano Selecionado (Card)
   ============================================ */

.plano-card-selecionado {
    background: #ffffff;
    border-radius: 24px;
    margin: 0 16px 24px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08), 0 16px 40px rgba(0,0,0,0.06);
    position: relative;
}

.plano-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px 12px;
}

.plano-card-tag {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
    color: #94a3b8;
}

.plano-card-trocar {
    font-size: 0.8rem;
    color: var(--plano-cor, #22c55e);
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: opacity 0.2s;
}

.plano-card-trocar:hover {
    opacity: 0.7;
}

.plano-card-body {
    padding: 0 20px 20px;
    text-align: center;
}

.plano-card-nome {
    font-size: 1.3rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 4px;
}

.plano-card-descricao {
    font-size: 0.85rem;
    color: #64748b;
    margin-bottom: 12px;
    line-height: 1.4;
}

.plano-card-preco {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
}

.plano-card-preco .preco-gratis {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--plano-cor, #22c55e);
}

.plano-card-preco .preco-moeda {
    font-size: 1rem;
    font-weight: 600;
    color: #64748b;
}

.plano-card-preco .preco-valor {
    font-size: 2.2rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1;
}

.plano-card-preco .preco-periodo {
    font-size: 0.9rem;
    color: #64748b;
}

.plano-card-barra {
    width: 100%;
    height: 4px;
    background: var(--plano-cor, #22c55e);
}

/* ============================================
   CADASTRO - Complementos
   ============================================ */

.cadastro-header-subtitle {
    margin: 8px 0 0;
    color: #64748b;
    font-size: 0.9rem;
    line-height: 1.5;
}

.cadastro-senha-aviso {
    min-height: 18px;
    margin: -6px 0 14px;
    font-size: 0.78rem;
}

.cadastro-senha-aviso.erro {
    color: #dc2626;
}

.cadastro-senha-aviso.sucesso {
    color: #16a34a;
}

.cadastro-termos {
    margin-bottom: 20px;
}

.cadastro-termos .remember-me {
    align-items: flex-start;
    color: #64748b;
    font-size: 0.82rem;
    line-height: 1.45;
}

.cadastro-termos-link {
    color: var(--color-primary, #22c55e);
    font-weight: 600;
    text-decoration: none;
}

.cadastro-termos-link:hover {
    text-decoration: underline;
}

.btn-cadastro-conteudo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.cadastro-footer {
    padding-bottom: 20px;
}

.cadastro-footer-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #64748b;
    font-size: 0.9rem;
}

.cadastro-footer-login a {
    color: #22c55e;
    font-weight: 600;
    text-decoration: none;
}

.cadastro-footer-login a:hover {
    text-decoration: underline;
}