:root {
    --lp-laranja-primaria: #FB370D;
    --lp-laranja-secundaria: #FF680D;
    --lp-azul-escuro: #004DE1;
    --lp-azul: #0068C7;
    --lp-cinza-escuro: #4E5359;
    --lp-cinza-medio: #B0BBC8;
    --lp-bg-escuro: #272C32;
}

/* ========== BASE GERAL ========== */
* {
    box-sizing: border-box;
}

body {
    background: var(--lp-bg-escuro);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    margin: 0;
    color: #f5f5f5;
}

/* ========== LOGIN ========== */
.login-wrapper {
    width: 100%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 320px;
}

.login-logo {
    text-align: center;
    margin-bottom: 24px;
}

.login-logo img {
    max-width: 130px;
    height: auto;
}

.login-box {
    background: #1F242B;
    border: 1px solid #333a42;
    padding: 26px 24px 24px;
    border-radius: 12px;
}

.login-box h1 {
    font-size: 20px;
    margin: 0 0 16px;
    font-weight: 600;
    color: #ffffff;
}

.login-box label {
    font-size: 13px;
    color: #d0d4da;
    display: block;
    margin-bottom: 4px;
}

.login-box input[type="email"],
.login-box input[type="password"] {
    width: 100%;
    padding: 8px 10px;
    font-size: 14px;
    border: 1px solid #3a414a;
    border-radius: 8px;
    margin-bottom: 12px;
    background: #15191f;
    color: #f5f5f5;
}

.login-box input[type="email"]:focus,
.login-box input[type="password"]:focus {
    border-color: var(--lp-azul);
    outline: none;
    box-shadow: 0 0 0 1px var(--lp-azul);
}

.login-box button[type="submit"] {
    width: 100%;
    background: var(--lp-laranja-primaria);
    color: #fff;
    border: none;
    padding: 10px 0;
    font-size: 14px;
    font-weight: 600;
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.05s ease;
}

.login-box button[type="submit"]:hover {
    background: var(--lp-laranja-secundaria);
    box-shadow: 0 6px 14px rgba(0,0,0,0.35);
    transform: translateY(-1px);
}

.login-error {
    background: #3b181b;
    color: #f3b2b9;
    border: 1px solid #7c2430;
    padding: 8px 10px;
    font-size: 13px;
    border-radius: 8px;
    margin-bottom: 12px;
}

.login-footer {
    margin-top: 16px;
    text-align: center;
    font-size: 12px;
    color: #8a919c;
}

.btn-google-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    border-radius: 999px;
    border: 1px solid #3a414a;
    background: #15191f;
    color: #e2e6ee;
    text-decoration: none;
    font-size: 13px;
    padding: 9px 0;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.05s ease;
}

.btn-google-login:hover {
    background: #1f2530;
    border-color: #4c5562;
    box-shadow: 0 6px 14px rgba(0,0,0,0.35);
    transform: translateY(-1px);
}

.google-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border-radius: 50%;
    padding: 2px;
}

.google-text {
    font-weight: 500;
}

/* espaço entre botão normal e Google */
.login-box .divider-text {
    text-align: center;
    margin: 12px 0;
    font-size: 12px;
    color: #8a919c;
}

/* ========== DASHBOARD HEADER ========== */
.app-header {
    background: #1F242B;
    border-bottom: 1px solid #333a42;
    padding: 12px 20px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.header-content h1 {
    margin: 0;
    font-size: 22px;
    color: #ffffff;
    font-weight: 600;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: #d0d4da;
}

.btn-logout {
    background: transparent;
    border: 1px solid #3a414a;
    color: #e2e6ee;
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.btn-logout:hover {
    background: #15191f;
    border-color: var(--lp-laranja-primaria);
    color: var(--lp-laranja-primaria);
}

/* ========== CONTAINER PRINCIPAL ========== */
.app-container {
    display: flex;
    max-width: 1400px;
    margin: 0 auto;
    gap: 24px;
    padding: 24px 20px;
}

/* ========== SIDEBAR ========== */
.sidebar {
    width: 280px;
    background: #1F242B;
    border: 1px solid #333a42;
    border-radius: 12px;
    padding: 20px;
    height: fit-content;
    position: sticky;
    top: 88px;
}

.sidebar-logo {
    text-align: center;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid #333a42;
}

.sidebar-logo img {
    max-width: 140px;
    height: auto;
}

.sidebar-section {
    margin-bottom: 24px;
}

.sidebar-section h3 {
    font-size: 13px;
    font-weight: 600;
    color: #8a919c;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 12px;
}

.form-select,
.form-input {
    width: 100%;
    padding: 8px 10px;
    font-size: 14px;
    border: 1px solid #3a414a;
    border-radius: 8px;
    margin-bottom: 10px;
    background: #15191f;
    color: #f5f5f5;
}

.form-select:focus,
.form-input:focus {
    border-color: var(--lp-azul);
    outline: none;
    box-shadow: 0 0 0 1px var(--lp-azul);
}

.form-range {
    width: 100%;
    margin-bottom: 8px;
    accent-color: var(--lp-laranja-primaria);
}

.range-value {
    display: block;
    font-size: 13px;
    color: #d0d4da;
    text-align: center;
}

.btn-primary-full {
    width: 100%;
    background: var(--lp-laranja-primaria);
    color: #fff;
    border: none;
    padding: 10px 0;
    font-size: 14px;
    font-weight: 600;
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.05s ease;
}

.btn-primary-full:hover {
    background: var(--lp-laranja-secundaria);
    box-shadow: 0 6px 14px rgba(0,0,0,0.35);
    transform: translateY(-1px);
}

/* ========== CONTEÚDO PRINCIPAL ========== */
.main-content {
    flex: 1;
    min-width: 0;
}

/* ========== TABS ========== */
.tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    border-bottom: 1px solid #333a42;
}

.tab {
    padding: 12px 20px;
    font-size: 15px;
    font-weight: 500;
    color: #8a919c;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: color 0.15s ease, border-color 0.15s ease;
    cursor: pointer;
}

.tab:hover {
    color: #d0d4da;
}

.tab.active {
    color: var(--lp-laranja-primaria);
    border-bottom-color: var(--lp-laranja-primaria);
}

/* ========== TAB CONTENT ========== */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.tab-content h2 {
    font-size: 20px;
    margin: 0 0 20px;
    color: #ffffff;
    font-weight: 600;
}

/* ========== STATS GRID (Oportunidades) ========== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.stat-card {
    background: #1F242B;
    border: 1px solid #333a42;
    border-radius: 12px;
    padding: 20px;
    transition: border-color 0.15s ease, transform 0.05s ease;
}

.stat-card:hover {
    border-color: var(--lp-azul);
    transform: translateY(-2px);
}

.stat-card h3 {
    margin: 0 0 12px;
    font-size: 15px;
    color: #d0d4da;
    font-weight: 500;
}

.stat-number {
    font-size: 32px;
    font-weight: 700;
    color: var(--lp-laranja-primaria);
    margin-bottom: 8px;
}

.stat-label {
    font-size: 13px;
    color: #8a919c;
}

/* ========== LEADS HEADER ========== */
.leads-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 16px;
}

.leads-header h2 {
    margin: 0;
}

.leads-controls {
    display: flex;
    gap: 12px;
    align-items: center;
}

/* ========== TOGGLE ========== */
.toggle {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.toggle input[type="checkbox"] {
    display: none;
}

.toggle-slider {
    background: #15191f;
    border: 1px solid #3a414a;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 13px;
    color: #d0d4da;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.toggle input[type="checkbox"]:checked + .toggle-slider {
    background: var(--lp-azul);
    border-color: var(--lp-azul);
    color: #ffffff;
}

/* ========== BOTÕES ========== */
.btn-secondary {
    background: transparent;
    border: 1px solid #3a414a;
    color: #e2e6ee;
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.btn-secondary:hover {
    background: #15191f;
    border-color: var(--lp-azul);
    color: var(--lp-azul);
}

/* ========== LEADS GRID ========== */
.leads-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 16px;
}

.lead-card {
    background: #1F242B;
    border: 1px solid #333a42;
    border-radius: 12px;
    padding: 20px;
    transition: border-color 0.15s ease, transform 0.05s ease;
}

.lead-card:hover {
    border-color: var(--lp-azul);
    transform: translateY(-2px);
}

.lead-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 12px;
}

.lead-header h3 {
    margin: 0;
    font-size: 16px;
    color: #ffffff;
    font-weight: 600;
}

/* ========== CHECKBOX ========== */
.checkbox {
    position: relative;
    display: inline-block;
    cursor: pointer;
}

.checkbox input[type="checkbox"] {
    display: none;
}

.checkmark {
    display: block;
    width: 20px;
    height: 20px;
    border: 2px solid #3a414a;
    border-radius: 4px;
    background: #15191f;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.checkbox input[type="checkbox"]:checked + .checkmark {
    background: var(--lp-laranja-primaria);
    border-color: var(--lp-laranja-primaria);
}

.checkbox input[type="checkbox"]:checked + .checkmark::after {
    content: "✓";
    display: block;
    color: #ffffff;
    font-size: 14px;
    text-align: center;
    line-height: 16px;
}

/* ========== LEAD META ========== */
.lead-meta {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.meta-label,
.meta-location {
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #15191f;
}

.meta-label {
    color: var(--lp-azul);
    border: 1px solid var(--lp-azul);
}

.meta-location {
    color: #d0d4da;
    border: 1px solid #3a414a;
}

/* ========== LEAD STATUS ========== */
.lead-status {
    font-size: 13px;
    color: #8a919c;
    margin-bottom: 16px;
    padding: 8px 0;
    border-top: 1px solid #333a42;
    border-bottom: 1px solid #333a42;
}

/* ========== LEAD ACTIONS ========== */
.lead-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.btn-icon {
    background: transparent;
    border: 1px solid #3a414a;
    color: #e2e6ee;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 16px;
    text-decoration: none;
    transition: background 0.15s ease, border-color 0.15s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-icon:hover {
    background: #15191f;
    border-color: var(--lp-azul);
}

.btn-whatsapp {
    background: #25D366;
    border: none;
    color: #ffffff;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s ease, transform 0.05s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-whatsapp:hover {
    background: #20BA5A;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

/* ========== RESPONSIVO ========== */
@media (max-width: 992px) {
    .app-container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        position: static;
    }
    
    .stats-grid,
    .leads-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .header-content {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }
    
    .leads-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .tabs {
        flex-wrap: wrap;
    }
}
