/* ==============================================================================
   IHUBZ API WHATSAPP — 100% RESPONSIVE LOGIN & SHOWCASE DESIGN (PRINT 2 MATCH)
   ============================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    /* Brand Colors */
    --primary-blue: #0284c7;
    --primary-blue-dark: #0369a1;
    --primary-blue-glow: rgba(2, 132, 199, 0.35);

    --primary-green: #22c55e;
    --primary-green-dark: #16a34a;

    --text-dark: #0f172a;
    --text-slate: #334155;
    --text-muted: #64748b;
    --text-dim: #94a3b8;

    --input-bg: #f8fafc;
    --input-border: #e2e8f0;
    --input-focus-border: #0284c7;
    --input-focus-ring: rgba(2, 132, 199, 0.15);

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --radius-card: 26px;

    --transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    min-height: 100vh;
    font-family: 'Sora', 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: #f1f6fb;
    color: var(--text-dark);
    overflow-x: hidden;
}

/* ==============================================================================
   BACKGROUND SHOWCASE (/img/backgroundnovo.png — 3D ARTWORK OFICIAL)
   ============================================================================== */
.bg-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('/img/backgroundnovo.png');
    background-repeat: no-repeat;
    background-position: left center;
    background-size: cover;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

/* ==============================================================================
   MAIN CONTAINER (SPLIT-SCREEN HERO & FLOATING CARD — 100% RESPONSIVO)
   ============================================================================== */
.login-page-container {
    position: relative;
    z-index: 2;
    width: 100%;
    min-height: 100vh;
    max-width: 1600px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 3vh 4.5vw;
    gap: 30px;
    box-sizing: border-box;
}

/* ==============================================================================
   LEFT HERO SECTION (TEXTO ANCORADO NO TOPO LIVRE — NUNCA COBRE A ILUSTRAÇÃO 3D)
   ============================================================================== */
.hero-left-section {
    align-self: stretch;
    flex: 1;
    max-width: 740px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 2vh 0 1.5vh 0;
    box-sizing: border-box;
    z-index: 5;
    transition: padding 0.2s ease;
}

/* Top Block - Centralizado conforme pedido */
.hero-top-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
}

/* Top Platform Pill Badge - Centralizado */
.whatsapp-platform-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.95);
    border: 1.5px solid rgba(226, 232, 240, 0.9);
    padding: 5px 16px;
    border-radius: 999px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    width: fit-content;
    margin-bottom: 12px;
}

.whatsapp-platform-badge .badge-wa-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #22c55e;
    font-size: 16px;
}

.whatsapp-platform-badge .badge-wa-text {
    font-family: 'Sora', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-dark);
    letter-spacing: -0.2px;
}

/* Main Headline - Texto na mesma linha */
.hero-main-title {
    font-family: 'Sora', sans-serif;
    font-size: clamp(19px, 1.85vw, 29px);
    font-weight: 700;
    line-height: 1.25;
    color: var(--text-dark);
    letter-spacing: -0.6px;
    margin-bottom: 8px;
    white-space: nowrap;
    text-align: center;
}

.highlight-whatsapp-wrapper {
    position: relative;
    display: inline-block;
    white-space: nowrap;
    padding-bottom: 3px;
}

.hero-main-title .highlight-whatsapp {
    color: #10d73a;
    background: linear-gradient(90deg, #0ab4fb 0%, #06a6e6 28%, #06bcb6 54%, #10d73a 82%, #16e138 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
    position: relative;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.whatsapp-swoosh {
    position: absolute;
    left: 0;
    bottom: -3px;
    width: 100%;
    height: 9px;
    pointer-events: none;
    overflow: visible;
    filter: drop-shadow(0 2px 4px rgba(85, 238, 6, 0.45));
}

/* Subtitle - Texto na mesma linha */
.hero-subtitle {
    font-family: 'Sora', sans-serif;
    font-size: clamp(12.5px, 0.9vw, 14px);
    line-height: 1.5;
    color: var(--text-muted);
    font-weight: 400;
    white-space: nowrap;
    text-align: center;
}

/* Compact layout mode for low-height screens */
.hero-left-section.compact-view {
    padding-top: 10px;
}

.hero-left-section.compact-view .hero-main-title {
    font-size: 21px;
    margin-bottom: 4px;
}

.hero-left-section.compact-view .whatsapp-platform-badge {
    margin-bottom: 6px;
    padding: 3px 10px;
}

/* ==============================================================================
   BOTTOM FEATURES GRID (MODERNO COM CONEXÃO RÁPIDA, AUTOMAÇÃO, ANTI-BAN)
   ============================================================================== */
.hero-features-grid {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    max-width: 680px;
    padding-top: 15px;
}

.feature-card {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    border-radius: 14px;
    padding: 10px 14px;
    box-shadow: 0 8px 24px -4px rgba(15, 23, 42, 0.06), 0 0 0 1px rgba(226, 232, 240, 0.7);
    flex: 1;
    min-width: 0;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.feature-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px -4px rgba(2, 132, 199, 0.12), 0 0 0 1.5px rgba(2, 132, 199, 0.35);
    background: #ffffff;
}

.feature-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 19px;
    flex-shrink: 0;
}

.feature-icon.icon-lightning {
    color: #16a34a;
    background: rgba(34, 197, 94, 0.14);
}

.feature-icon.icon-robot {
    color: #0284c7;
    background: rgba(2, 132, 199, 0.14);
}

.feature-icon.icon-shield {
    color: #059669;
    background: rgba(16, 185, 129, 0.14);
}

.feature-text-block {
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: left;
    min-width: 0;
}

.feature-title {
    font-family: 'Sora', sans-serif;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.25;
    letter-spacing: -0.2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.feature-sub {
    font-family: 'Sora', sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    line-height: 1.2;
    letter-spacing: -0.2px;
    white-space: nowrap;
}

/* ==============================================================================
   RIGHT AUTH SECTION & FLOATING CARD (MODERNO COM BLUR & CAMPOS MODERNOS)
   ============================================================================== */
.auth-right-section {
    align-self: center;
    flex-shrink: 0;
    width: clamp(350px, 28vw, 420px);
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.auth-card {
    position: relative;
    width: 100%;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(28px) saturate(180%);
    -webkit-backdrop-filter: blur(28px) saturate(180%);
    border-radius: 26px;
    border: 1px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 24px 55px -12px rgba(15, 23, 42, 0.12),
                0 0 0 1px rgba(226, 232, 240, 0.8),
                0 1px 3px rgba(0, 0, 0, 0.04);
    padding: 34px 34px 28px;
    overflow: hidden;
    box-sizing: border-box;
    transition: box-shadow 0.3s ease;
}

/* Brand Logo */
.auth-logo-header {
    text-align: center;
    margin-bottom: 16px;
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
}

.auth-logo-img {
    height: 52px;
    max-width: 82%;
    object-fit: contain;
    filter: none !important;
    box-shadow: none !important;
    background: transparent !important;
    display: inline-block;
}

/* Card Headings */
.auth-headings {
    text-align: center;
    margin-bottom: 22px;
}

.auth-title {
    font-family: 'Sora', sans-serif;
    font-size: 23px;
    font-weight: 700;
    color: var(--text-dark);
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}

.auth-subtitle {
    font-family: 'Sora', sans-serif;
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 400;
}

/* Alerts */
.alert {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: var(--radius-md);
    font-size: 12.5px;
    font-weight: 600;
    margin-bottom: 14px;
    animation: fadeInAlert 0.25s ease-out;
}

.alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
}

.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #15803d;
}

@keyframes fadeInAlert {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Form Styles */
.auth-form {
    display: flex;
    flex-direction: column;
}

.auth-input-group {
    margin-bottom: 14px;
}

.auth-input-wrapper {
    display: flex;
    align-items: center;
    background: rgba(248, 250, 252, 0.85);
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    height: 50px;
    padding: 0 15px;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.auth-input-wrapper:focus-within {
    background: #ffffff;
    border-color: #0284c7;
    box-shadow: 0 0 0 4px rgba(2, 132, 199, 0.14), 0 2px 8px rgba(2, 132, 199, 0.06);
}

.auth-input-wrapper .input-icon {
    font-size: 18px;
    color: #94a3b8;
    margin-right: 12px;
    flex-shrink: 0;
    transition: color 0.2s ease;
}

.auth-input-wrapper:focus-within .input-icon {
    color: #0284c7;
}

.auth-input {
    border: none;
    background: transparent;
    width: 100%;
    height: 100%;
    font-family: 'Sora', sans-serif;
    font-size: 14px;
    color: var(--text-dark);
    font-weight: 500;
    outline: none;
}

.auth-input::placeholder {
    color: #94a3b8;
    font-weight: 400;
    font-size: 13.5px;
}

.btn-toggle-eye {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 18px;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s ease;
}

.btn-toggle-eye:hover {
    color: #0284c7;
}

/* Options Row: Remember Me & Forgot Password */
.auth-options-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    font-size: 12.5px;
}

.remember-label {
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    color: var(--text-slate);
    font-family: 'Sora', sans-serif;
    font-weight: 500;
    user-select: none;
}

.auth-checkbox {
    accent-color: #0284c7;
    width: 16px;
    height: 16px;
    border-radius: 4px;
    cursor: pointer;
}

.forgot-link {
    color: #0284c7;
    text-decoration: none;
    font-family: 'Sora', sans-serif;
    font-weight: 600;
    font-size: 12px;
    transition: color 0.15s ease;
}

.forgot-link:hover {
    color: var(--primary-blue-dark);
    text-decoration: underline;
}

/* Submit Button */
.btn-submit-auth {
    position: relative;
    width: 100%;
    height: 50px;
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    border: none;
    border-radius: 14px;
    font-family: 'Sora', sans-serif;
    font-size: 14.5px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 8px 22px -4px rgba(2, 132, 199, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.25);
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-submit-auth:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px -4px rgba(2, 132, 199, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.3);
    background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
}

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

.btn-submit-auth .btn-icon {
    font-size: 17px;
    transition: transform 0.2s ease;
}

.btn-submit-auth:hover .btn-icon {
    transform: translateX(3px);
}

.btn-spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Divider "ou" */
.auth-divider {
    display: flex;
    align-items: center;
    margin: 16px 0;
    gap: 12px;
}

.auth-divider .divider-line {
    flex: 1;
    height: 1px;
    background: #e2e8f0;
}

.auth-divider .divider-text {
    font-family: 'Sora', sans-serif;
    font-size: 11px;
    color: #94a3b8;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Google Auth Button */
.btn-google-auth {
    width: 100%;
    height: 46px;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    color: #334155;
    font-family: 'Sora', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    cursor: pointer;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-google-auth:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
    transform: translateY(-1px);
}

.google-svg {
    flex-shrink: 0;
}

/* Card Footer */
.auth-card-footer {
    margin-top: 18px;
    text-align: center;
}

.auth-card-footer p {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(241, 245, 249, 0.85);
    border: 1px solid rgba(226, 232, 240, 0.8);
    padding: 5px 14px;
    border-radius: 999px;
    font-family: 'Sora', sans-serif;
    font-size: 11px;
    color: #64748b;
    font-weight: 500;
}

.auth-card-footer .footer-highlight {
    color: var(--text-dark);
    font-weight: 700;
}

/* ==============================================================================
   VALIDATION OVERLAY (INTERACTIVE ANIMATION COM FAVICON 3D MODERNO)
   ============================================================================== */
.validation-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-card);
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.validation-overlay.active {
    opacity: 1;
    visibility: visible;
}

.validation-content {
    text-align: center;
    width: 100%;
    max-width: 300px;
}

.validation-logo-wrapper {
    position: relative;
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.validation-ring {
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 3.5px solid transparent;
    border-top-color: #0284c7;
    border-right-color: #22c55e;
    border-bottom-color: #38bdf8;
    filter: drop-shadow(0 0 10px rgba(2, 132, 199, 0.35));
    animation: ringRotate 1.1s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.validation-ring-glow {
    position: absolute;
    inset: -12px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(2, 132, 199, 0.18) 0%, rgba(34, 197, 94, 0.1) 60%, transparent 80%);
    animation: pulseGlow 2s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
    0% { transform: scale(0.92); opacity: 0.6; }
    100% { transform: scale(1.08); opacity: 1; }
}

@keyframes ringRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.validation-logo-box {
    width: 86px;
    height: 86px;
    background: #ffffff;
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(2, 132, 199, 0.16),
                0 0 0 1px rgba(226, 232, 240, 0.9);
    transition: transform 0.3s ease;
}

.val-logo {
    width: 66px;
    height: 66px;
    object-fit: contain;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.08));
    animation: floatIcon 2.4s ease-in-out infinite alternate;
}

@keyframes floatIcon {
    0% { transform: translateY(0px) scale(1); }
    100% { transform: translateY(-3px) scale(1.03); }
}

.validation-title {
    font-family: 'Sora', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 5px;
    letter-spacing: -0.3px;
}

.validation-status {
    font-family: 'Sora', sans-serif;
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 400;
    margin-bottom: 18px;
    min-height: 18px;
}

.validation-bar-container {
    width: 100%;
    height: 7px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 18px;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.06);
}

.validation-bar-progress {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #0284c7, #22c55e);
    border-radius: 999px;
    box-shadow: 0 0 10px rgba(34, 197, 94, 0.5);
    transition: width 0.35s ease, background 0.3s ease;
}

.validation-bar-progress.success {
    background: #22c55e !important;
}

.validation-bar-progress.error {
    background: #ef4444 !important;
}

.btn-retry {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #fee2e2;
    color: #b91c1c;
    border: 1px solid #fca5a5;
    padding: 8px 18px;
    border-radius: 10px;
    font-family: 'Sora', sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.btn-retry:hover {
    background: #fecaca;
}

/* ==============================================================================
   RESPONSIVE DESIGN (100% RESPONSIVO PARA TODAS AS TELAS)
   ============================================================================== */
@media (max-width: 1250px) {
    .hero-main-title {
        font-size: 24px;
        white-space: normal;
    }

    .hero-subtitle {
        font-size: 13px;
        white-space: normal;
    }
}

@media (max-width: 991px) {
    .login-page-container {
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        min-height: 100vh;
        height: auto;
        padding: 32px 18px 48px;
        gap: 28px;
    }

    /* 1. Login no TOPO no mobile */
    .auth-right-section {
        order: 1;
        align-self: center;
        width: 100%;
        max-width: 440px;
        justify-content: center;
        margin: 0 auto;
    }

    .auth-card {
        width: 100%;
        max-width: 440px;
        margin: 0 auto;
    }

    /* 2. Textos e recursos EMBAIXO no mobile */
    .hero-left-section {
        order: 2;
        width: 100%;
        max-width: 480px;
        align-self: center;
        align-items: center;
        text-align: center;
        padding: 0;
        margin: 0 auto;
        justify-content: flex-start;
        gap: 18px;
    }

    .hero-top-block {
        align-items: center;
        text-align: center;
        width: 100%;
    }

    .whatsapp-platform-badge {
        margin-bottom: 10px;
    }

    .hero-main-title {
        font-size: clamp(20px, 4.2vw, 24px);
        white-space: normal;
        text-align: center;
        line-height: 1.35;
        max-width: 460px;
        margin: 0 auto 8px;
    }

    .highlight-whatsapp-wrapper {
        white-space: normal;
        display: inline;
        position: relative;
    }

    .hero-subtitle {
        font-size: 13px;
        white-space: normal;
        text-align: center;
        max-width: 420px;
        line-height: 1.5;
        margin: 0 auto;
    }

    .hero-features-grid {
        justify-content: center;
        flex-direction: column;
        gap: 10px;
        width: 100%;
        max-width: 440px;
        padding-top: 6px;
        margin: 0 auto;
    }

    .feature-card {
        width: 100%;
        min-width: 0;
        flex: none;
        padding: 12px 16px;
    }

    .feature-title {
        white-space: normal;
        font-size: 13px;
    }

    .feature-sub {
        white-space: normal;
        font-size: 11px;
    }

    .bg-image {
        background-position: center top;
        background-size: cover;
    }
}

@media (max-width: 520px) {
    .login-page-container {
        padding: 20px 14px 36px;
        gap: 22px;
    }

    .auth-card {
        padding: 24px 18px 20px;
        border-radius: 20px;
        width: 100%;
    }

    .auth-title {
        font-size: 20px;
    }

    .auth-subtitle {
        font-size: 12.5px;
        margin-bottom: 14px;
    }

    .hero-main-title {
        font-size: 19px;
        line-height: 1.35;
    }

    .hero-subtitle {
        font-size: 12px;
    }

    .hero-left-section {
        gap: 14px;
    }

    .hero-features-grid {
        gap: 8px;
    }

    .feature-card {
        padding: 10px 14px;
    }
}
