/* QR Rapido Custom Theme */
:root {
    --qr-primary: #007BFF;
    --qr-secondary: #28A745;
    --qr-accent: #FF6B35;
    --qr-warning: #FFC107;
    --qr-success: #28A745;
    --qr-danger: #DC3545;
    --qr-dark: #343A40;
    --qr-light: #F8F9FA;
}

/* Global Styles */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
}

.bg-gradient-primary {
    background: linear-gradient(135deg, var(--qr-primary) 0%, #0056B3 100%);
}

/* Generation Timer Styles */
.generation-timer {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    background: #f8f9fa;
    border-radius: 20px;
    border: 2px solid var(--qr-primary);
    transition: all 0.3s ease;
}

.generation-timer.active {
    background: var(--qr-primary);
    color: white;
    animation: pulse 1.5s infinite;
}

/* Speed Badge Animation */
.speed-badge {
    animation: slideInRight 0.5s ease-out;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes slideInRight {
    from {
        transform: translateX(20px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* QR Preview Placeholder - REMOVIDO: Substituído por versão com melhor contraste */

/* Logo and Branding */
.navbar-brand svg {
    filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.1));
    transition: transform 0.3s ease;
}

.navbar-brand:hover svg {
    transform: scale(1.05);
}

/* QR Preview Image */
#qr-preview img {
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    max-width: 100%;
    height: auto;
}

#qr-preview img:hover {
    transform: scale(1.02);
}

/* Card Hover Effects */
.card {
    transition: all 0.3s ease;
    border-radius: 12px;
}

.card:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

/* Button Styles */
.btn-check:checked + .btn {
    background-color: var(--qr-primary);
    border-color: var(--qr-primary);
    color: white;
}

.btn-primary {
    background: linear-gradient(135deg, var(--qr-primary) 0%, #0056B3 100%);
    border: none;
    color: white !important;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0056B3 0%, var(--qr-primary) 100%);
    color: white !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

/* Botões de login específicos - cores sólidas */
.card-body .btn-danger {
    background-color: var(--qr-danger) !important;
    background-image: none !important;
    border-color: var(--qr-danger) !important;
    color: white !important;
}

.card-body .btn-danger:hover {
    background-color: #C82333 !important;
    background-image: none !important;
    border-color: #C82333 !important;
    color: white !important;
}

.card-body .btn-primary {
    background-color: var(--qr-primary) !important;
    background-image: none !important;
    border-color: var(--qr-primary) !important;
    color: white !important;
}

.card-body .btn-primary:hover {
    background-color: #0056B3 !important;
    background-image: none !important;
    border-color: #0056B3 !important;
    color: white !important;
}

/* Form Controls */
.form-control:focus,
.form-select:focus {
    border-color: var(--qr-primary);
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.form-control-lg {
    border-radius: 8px;
}

/* Speed Statistics Cards */
.card.border-success {
    border-color: var(--qr-success) !important;
}

.card.border-primary {
    border-color: var(--qr-primary) !important;
}

.card.border-warning {
    border-color: var(--qr-warning) !important;
}

/* Generation Stats Animation */
.generation-stats {
    animation: slideInRight 0.5s ease-out;
}

/* Ad Container Styles - REMOVIDO: Substituído por versão com melhor contraste */

.ad-free-notice {
    text-align: center;
    border-left: 4px solid var(--qr-success);
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border-radius: 8px;
}

.ad-free-notice .fas {
    color: var(--qr-warning);
}

/* Loading Animations */
.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

/* Progress Bar for QR Generation */
.progress {
    height: 4px;
    border-radius: 2px;
    background-color: #e9ecef;
}

.progress-bar {
    background: linear-gradient(90deg, var(--qr-primary), var(--qr-accent));
}

/* Speed Tips */
.list-unstyled li {
    padding: 0.25rem 0;
    transition: all 0.2s ease;
}

.list-unstyled li:hover {
    padding-left: 0.5rem;
    color: var(--qr-primary);
}

/* Responsive Design */
@media (max-width: 768px) {
    .generation-timer {
        font-size: 0.875rem;
        padding: 0.2rem 0.5rem;
    }
    
    .speed-badge .badge {
        font-size: 0.75rem;
    }
    
    .placeholder-qr {
        padding: 2rem 1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .ad-container {
        margin: 10px 0;
        padding: 10px;
    }
}

/* Premium Features Styling */
.premium-feature {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border-left: 4px solid var(--qr-warning);
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
}

.premium-badge {
    background: linear-gradient(135deg, var(--qr-warning) 0%, #f39c12 100%);
    color: var(--qr-dark);
    border-radius: 20px;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Accordion Customization */
.accordion-button {
    background: var(--qr-light);
    border: none;
    border-radius: 8px !important;
}

.accordion-button:not(.collapsed) {
    background: var(--qr-primary);
    color: white;
}

.accordion-button:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Footer Styling */
footer {
    background: linear-gradient(135deg, var(--qr-dark) 0%, #2c3e50 100%);
}

footer a {
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--qr-primary) !important;
}

/* Language Selector */
.dropdown-toggle::after {
    margin-left: 0.5rem;
}

.dropdown-menu {
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border: none;
}

.dropdown-item {
    transition: all 0.2s ease;
    border-radius: 4px;
    margin: 2px 4px;
}

.dropdown-item:hover {
    background: var(--qr-primary);
    color: white;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--qr-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0056b3;
}

/* =================================
   THEME TOGGLE - BOTÃO ELEGANTE
   ================================= */

.theme-toggle-container {
    margin-left: 8px;
}

#theme-toggle {
    border-color: #6c757d !important;
    color: #6c757d !important;
    transition: all 0.3s ease;
    min-width: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#theme-toggle:hover {
    background-color: #007bff !important;
    border-color: #007bff !important;
    color: white !important;
    transform: translateY(-1px);
}

#theme-toggle:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

#theme-icon {
    font-size: 0.875rem;
    transition: transform 0.3s ease;
}

#theme-toggle:hover #theme-icon {
    transform: rotate(180deg);
}

/* Estados do tema */
[data-theme="light"] #theme-icon {
    color: #ffc107; /* Sol amarelo */
}

[data-theme="dark"] #theme-icon {
    color: #17a2b8; /* Lua azul */
}

/* Responsive - esconder texto em telas pequenas */
@media (max-width: 768px) {
    #theme-text {
        display: none !important;
    }
    
    .theme-toggle-container {
        margin-left: 4px;
    }
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--qr-primary) 0%, var(--qr-accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-custom {
    box-shadow: 0 8px 25px rgba(0, 123, 255, 0.15);
}

.border-gradient {
    border: 2px solid;
    border-image: linear-gradient(135deg, var(--qr-primary) 0%, var(--qr-accent) 100%) 1;
}

/* Print Styles */
@media print {
    .ad-container,
    .btn,
    .navbar,
    footer {
        display: none !important;
    }
    
    #qr-preview img {
        max-width: 300px;
        max-height: 300px;
    }
}

/* =================================
   CORREÇÕES CRÍTICAS DE CONTRASTE E VISIBILIDADE
   QR Rapido - Acessibilidade WCAG 2.1 AA
   ================================= */

/* =================================
   DICAS PARA QR MAIS RÁPIDOS - CORREÇÃO CRÍTICA
   ================================= */

.card.bg-light {
    background-color: #ffffff !important;
    border: 1px solid #dee2e6 !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.card.bg-light .card-header {
    background-color: #f8f9fb !important;
    color: #212529 !important;
    border-bottom: 1px solid #dee2e6;
    font-weight: 600;
}

.card.bg-light .card-body {
    background-color: #ffffff !important;
    color: #212529 !important;
}

.card.bg-light .text-muted {
    color: #495057 !important; /* Mais escuro para melhor contraste */
}

/* =================================
   CONTENT HINTS - VISIBILIDADE GARANTIDA
   ================================= */

#content-hints, .form-text {
    color: #495057 !important;
    font-weight: 500;
    background: rgba(0, 123, 255, 0.05);
    padding: 6px 12px;
    border-radius: 4px;
    border-left: 3px solid #007bff;
    font-size: 0.875rem;
    margin-top: 4px;
    display: block !important;
}

/* =================================
   TEXT MUTED - CONTRASTE GLOBAL
   ================================= */

.text-muted {
    color: #495057 !important; /* Mais escuro que o padrão Bootstrap */
}

/* =================================
   CARDS DE ESTATÍSTICAS - VISIBILIDADE
   ================================= */

.card.border-success, .card.border-primary, .card.border-warning {
    background: #ffffff;
    border-width: 2px !important;
    box-shadow: 0 4px 6px rgba(0,0,0,0.08);
}

.card.border-success .card-body {
    background: linear-gradient(145deg, #ffffff 0%, #f0fff4 100%);
}

.card.border-primary .card-body {
    background: linear-gradient(145deg, #ffffff 0%, #eff6ff 100%);
}

.card.border-warning .card-body {
    background: linear-gradient(145deg, #ffffff 0%, #fffbeb 100%);
}

.card .text-success, .card .text-primary, .card .text-warning {
    font-weight: 700 !important;
}

/* =================================
   AD CONTAINERS - NUNCA INVISÍVEL
   ================================= */

.ad-container {
    background: #ffffff !important;
    border: 1px solid #dee2e6 !important;
    padding: 15px;
    text-align: center;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    margin: 20px 0;
    position: relative;
}

.ad-label {
    color: #495057 !important;
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.affiliate-ad-wide {
    text-align: left;
}

.affiliate-ad-wide .affiliate-ad-card {
    max-width: 100%;
}

.affiliate-ad-wide .affiliate-ad-card .card-body {
    padding: 1.5rem;
}

.affiliate-ad-wide .affiliate-ad-card-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    width: 100%;
}

.affiliate-ad-wide .affiliate-ad-media {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
}

.affiliate-ad-wide .affiliate-ad-media img {
    display: block;
    max-width: 240px;
    width: 100%;
}

.affiliate-ad-wide .affiliate-ad-partner {
    font-weight: 600;
}

.affiliate-ad-wide .affiliate-ad-details {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    text-align: center;
    align-items: center;
}

.affiliate-ad-wide .affiliate-ad-details .card-title {
    font-size: 1rem;
}

.affiliate-ad-wide .affiliate-ad-price {
    font-size: 0.95rem;
}

.affiliate-ad-wide .affiliate-ad-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    width: 100%;
    align-items: stretch;
}

.affiliate-ad-wide .affiliate-ad-cta {
    width: 100%;
}

@media (min-width: 576px) {
    .affiliate-ad-wide .affiliate-ad-actions {
        align-items: center;
    }
}

@media (min-width: 992px) {
    .affiliate-ad-wide .affiliate-ad-card {
        max-width: 1000px;
        margin: 0 auto;
    }

    .affiliate-ad-wide .affiliate-ad-card .card-body {
        padding: 1.75rem 2rem;
    }

    .affiliate-ad-wide .affiliate-ad-card-content {
        display: grid;
        grid-template-columns: minmax(220px, 320px) minmax(0, 1fr);
        align-items: center;
        column-gap: 2.5rem;
    }

    .affiliate-ad-wide .affiliate-ad-media {
        align-items: flex-start;
        text-align: left;
    }

    .affiliate-ad-wide .affiliate-ad-media img {
        max-width: 280px;
    }

    .affiliate-ad-wide .affiliate-ad-details {
        text-align: left;
        align-items: flex-start;
    }

    .affiliate-ad-wide .affiliate-ad-actions {
        flex-direction: row;
        align-items: flex-start;
        width: auto;
        gap: 1rem;
    }

    .affiliate-ad-wide .affiliate-ad-cta {
        width: auto;
    }
}

/* =================================
   PLACEHOLDER QR - CONTRASTE SUPERIOR
   ================================= */

.placeholder-qr {
    border: 2px dashed #007bff !important;
    background: #f8f9fb !important;
    padding: 40px 20px;
    text-align: center;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.placeholder-qr:hover {
    border-color: #0056b3;
    background: #e7f3ff;
}

.placeholder-qr .text-muted {
    color: #495057 !important;
}

/* =================================
   BOTÕES - MANTENDO IDENTIDADE AZUL
   ================================= */

.btn-primary {
    background-color: #007bff !important;
    border-color: #007bff !important;
    font-weight: 600;
}

.btn-primary:hover {
    background-color: #0056b3 !important;
    border-color: #0056b3 !important;
}

.btn-outline-primary {
    color: #007bff !important;
    border-color: #007bff !important;
    font-weight: 600;
}

.btn-outline-primary:hover {
    background-color: #007bff !important;
    border-color: #007bff !important;
    color: #ffffff !important;
}

/* =================================
   THEME SYSTEM - BASEADO EM DATA-THEME
   Tema escuro ativado via data-theme="dark" OU preferência do sistema
   ================================= */

html[data-theme="dark"] {
    /* Base cards */
    .card {
        background-color: #2d3748 !important;
        color: #e2e8f0 !important;
        border-color: #4a5568 !important;
    }
    
    /* Card Dicas para QR Mais Rápidos */
    .card.bg-light {
        background-color: #2d3748 !important;
        border-color: #4a5568 !important;
        color: #e2e8f0 !important;
    }
    
    .card.bg-light .card-header {
        background-color: #4a5568 !important;
        color: #e2e8f0 !important;
        border-bottom-color: #718096;
    }
    
    .card.bg-light .card-body {
        background-color: #2d3748 !important;
        color: #e2e8f0 !important;
    }
    
    .card.bg-light .text-muted {
        color: #cbd5e0 !important;
    }
    
    .card.bg-light .list-unstyled li {
        color: #e2e8f0 !important;
    }
    
    /* Content Hints - Dark Mode */
    #content-hints, .form-text {
        color: #e2e8f0 !important;
        background: rgba(66, 153, 225, 0.15);
        border-left-color: #4dabf7;
    }
    
    /* Text Muted - Dark Mode */
    .text-muted {
        color: #cbd5e0 !important;
    }
    
    .small.text-muted, small.text-muted {
        color: #a0aec0 !important;
    }
    
    /* Cards Estatísticas - Dark Mode */
    .card.border-success, .card.border-primary, .card.border-warning {
        background-color: #2d3748 !important;
        border-color: inherit !important;
        color: #e2e8f0 !important;
    }
    
    .card.border-success .card-body,
    .card.border-primary .card-body,
    .card.border-warning .card-body {
        background: #2d3748 !important;
        color: #e2e8f0 !important;
    }
    
    .card.border-success {
        border-color: #48bb78 !important;
    }
    
    .card.border-primary {
        border-color: #4dabf7 !important;
    }
    
    .card.border-warning {
        border-color: #ed8936 !important;
    }
    
    /* Ad Containers - Dark Mode */
    .ad-container {
        background: #2d3748 !important;
        border-color: #4a5568 !important;
        color: #e2e8f0 !important;
    }

    .ad-label {
        color: #cbd5e0 !important;
    }
    
    /* Placeholder QR - Dark Mode */
    .placeholder-qr {
        background: #4a5568 !important;
        border-color: #4dabf7 !important;
        color: #e2e8f0 !important;
    }
    
    .placeholder-qr:hover {
        background: #2d3748;
        border-color: #63b3ed;
    }
    
    .placeholder-qr .text-muted {
        color: #cbd5e0 !important;
    }
    
    /* Form Controls - Dark Mode Completo */
    .form-control, .form-select {
        background-color: #4a5568 !important;
        border-color: #718096 !important;
        color: #e2e8f0 !important;
    }
    
    .form-control:focus, .form-select:focus {
        background-color: #4a5568 !important;
        border-color: #4dabf7 !important;
        box-shadow: 0 0 0 0.2rem rgba(77, 171, 247, 0.25) !important;
        color: #e2e8f0 !important;
    }
    
    .form-control::placeholder {
        color: #a0aec0 !important;
        opacity: 1;
    }
    
    .form-label {
        color: #e2e8f0 !important;
        font-weight: 600;
    }
    
    /* Botões - Dark Mode */
    .btn-primary {
        background-color: #4dabf7 !important;
        border-color: #4dabf7 !important;
        color: white !important;
    }
    
    .btn-primary:hover {
        background-color: #3182ce !important;
        border-color: #3182ce !important;
        color: white !important;
    }
    
    /* Botões de login específicos - tema escuro */
    .card-body .btn-danger {
        background-color: #f56565 !important;
        background-image: none !important;
        border-color: #f56565 !important;
        color: white !important;
    }
    
    .card-body .btn-danger:hover {
        background-color: #e53e3e !important;
        background-image: none !important;
        border-color: #e53e3e !important;
        color: white !important;
    }
    
    .card-body .btn-primary {
        background-color: #4dabf7 !important;
        background-image: none !important;
        border-color: #4dabf7 !important;
        color: white !important;
    }
    
    .card-body .btn-primary:hover {
        background-color: #3182ce !important;
        background-image: none !important;
        border-color: #3182ce !important;
        color: white !important;
    }
    
    /* Body e elementos base */
    body {
        background-color: #1a202c !important;
        color: #e2e8f0 !important;
    }
    
    /* Navbar dark mode */
    .navbar-light {
        background-color: #2d3748 !important;
        border-bottom-color: #4a5568 !important;
    }
    
    .navbar-light .navbar-brand {
        color: #e2e8f0 !important;
    }
    
    /* Dropdown menus escuro */
    .btn-outline-secondary {
        background-color: #4a5568 !important;
        border-color: #718096 !important;
        color: #e2e8f0 !important;
    }
    
    .btn-outline-secondary:hover {
        background-color: #4dabf7 !important;
        border-color: #4dabf7 !important;
        color: #ffffff !important;
    }
    
    /* Links e textos diversos */
    a {
        color: #4dabf7 !important;
    }
    
    a:hover {
        color: #63b3ed !important;
    }
    
    /* Premium features */
    .premium-feature {
        background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
        border-left-color: #ed8936;
        color: #e2e8f0;
    }
    
    /* Accordion */
    .accordion-button {
        background: #4a5568 !important;
        color: #e2e8f0 !important;
    }
    
    .accordion-button:not(.collapsed) {
        background: #4dabf7 !important;
        color: #ffffff !important;
    }
    
    /* Dropdown menus */
    .dropdown-menu {
        background-color: #2d3748 !important;
        border-color: #4a5568 !important;
    }
    
    .dropdown-item {
        color: #e2e8f0 !important;
    }
    
    .dropdown-item:hover {
        background-color: #4dabf7 !important;
        color: #ffffff !important;
    }
    
    /* Correções adicionais para elementos específicos */
    .small {
        color: #a0aec0 !important;
    }
    
    .badge {
        background-color: #4a5568 !important;
        color: #e2e8f0 !important;
    }
    
    .badge.bg-success {
        background-color: #48bb78 !important;
        color: #ffffff !important;
    }
    
    .badge.bg-primary {
        background-color: #4dabf7 !important;
        color: #ffffff !important;
    }
    
    .badge.bg-warning {
        background-color: #ed8936 !important;
        color: #ffffff !important;
    }
    
    /* Alerts */
    .alert {
        background-color: #4a5568 !important;
        border-color: #718096 !important;
        color: #e2e8f0 !important;
    }
    
    .alert-success {
        background-color: #2f855a !important;
        border-color: #48bb78 !important;
        color: #ffffff !important;
    }
    
    .alert-info {
        background-color: #2b6cb0 !important;
        border-color: #4dabf7 !important;
        color: #ffffff !important;
    }
    
    .alert-warning {
        background-color: #c05621 !important;
        border-color: #ed8936 !important;
        color: #ffffff !important;
    }
    
    /* Tables */
    .table {
        background-color: #2d3748 !important;
        color: #e2e8f0 !important;
    }
    
    .table th, .table td {
        border-color: #4a5568 !important;
        color: #e2e8f0 !important;
    }
    
    .table-hover tbody tr:hover {
        background-color: #4a5568 !important;
    }
    
    /* List groups */
    .list-group-item {
        background-color: #2d3748 !important;
        border-color: #4a5568 !important;
        color: #e2e8f0 !important;
    }
    
    /* Progress bars */
    .progress {
        background-color: #4a5568 !important;
    }
    
    /* Footer */
    footer {
        background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%) !important;
        color: #e2e8f0 !important;
    }
    
    footer a {
        color: #4dabf7 !important;
    }
    
    footer a:hover {
        color: #63b3ed !important;
    }
    
    /* Hero section */
    .bg-gradient-primary {
        background: linear-gradient(135deg, #4dabf7 0%, #3182ce 100%) !important;
    }
    
    /* Generation timer e speed badge */
    .generation-timer {
        background: #4a5568 !important;
        border-color: #4dabf7 !important;
        color: #e2e8f0 !important;
    }
    
    .generation-timer.active {
        background: #4dabf7 !important;
        color: #ffffff !important;
    }
}

/* =================================
   TEMA CLARO EXPLÍCITO
   Forçar tema claro mesmo se o sistema estiver escuro
   ================================= */

html[data-theme="light"] {
    /* Body e elementos base */
    body {
        background-color: #ffffff !important;
        color: #212529 !important;
    }
    
    /* Cards */
    .card {
        background-color: #ffffff !important;
        color: #212529 !important;
        border-color: #dee2e6 !important;
    }
    
    .card.bg-light {
        background-color: #ffffff !important;
        border-color: #dee2e6 !important;
        color: #212529 !important;
    }
    
    .card.bg-light .card-header {
        background-color: #f8f9fb !important;
        color: #212529 !important;
        border-bottom-color: #dee2e6;
    }
    
    .card.bg-light .card-body {
        background-color: #ffffff !important;
        color: #212529 !important;
    }
    
    .card.bg-light .text-muted {
        color: #495057 !important;
    }
    
    /* Text muted */
    .text-muted {
        color: #495057 !important;
    }
    
    .small.text-muted, small.text-muted {
        color: #6c757d !important;
    }
    
    /* Content hints */
    #content-hints, .form-text {
        color: #495057 !important;
        background: rgba(0, 123, 255, 0.05);
        border-left-color: #007bff;
    }
    
    /* Form controls */
    .form-control, .form-select {
        background-color: #ffffff !important;
        border-color: #ced4da !important;
        color: #495057 !important;
    }
    
    .form-control:focus, .form-select:focus {
        border-color: #007bff !important;
        box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25) !important;
        color: #495057 !important;
    }
    
    .form-control::placeholder {
        color: #6c757d !important;
        opacity: 1;
    }
    
    .form-label {
        color: #212529 !important;
        font-weight: 600;
    }
    
    /* Cards de estatísticas */
    .card.border-success, .card.border-primary, .card.border-warning {
        background-color: #ffffff !important;
        color: #212529 !important;
    }
    
    .card.border-success .card-body,
    .card.border-primary .card-body,
    .card.border-warning .card-body {
        background: linear-gradient(145deg, #ffffff 0%, #f8f9fa 100%) !important;
        color: #212529 !important;
    }
    
    /* Ad containers */
    .ad-container {
        background: #ffffff !important;
        border-color: #dee2e6 !important;
        color: #212529 !important;
    }
    
    .ad-label {
        color: #495057 !important;
    }
    
    /* Placeholder QR */
    .placeholder-qr {
        background: #f8f9fb !important;
        border-color: #007bff !important;
        color: #212529 !important;
    }
    
    .placeholder-qr:hover {
        background: #e7f3ff !important;
        border-color: #0056b3 !important;
    }
    
    .placeholder-qr .text-muted {
        color: #495057 !important;
    }
    
    /* Navbar */
    .navbar-light {
        background-color: #ffffff !important;
        border-bottom-color: #dee2e6 !important;
    }
    
    .navbar-light .navbar-brand {
        color: #212529 !important;
    }
    
    /* Hero section */
    .bg-gradient-primary {
        background: linear-gradient(135deg, #007BFF 0%, #0056B3 100%) !important;
    }
    
    /* Links */
    a {
        color: #007bff !important;
    }
    
    a:hover {
        color: #0056b3 !important;
    }
    
    /* Botões */
    .btn-primary {
        background-color: #007bff !important;
        border-color: #007bff !important;
        color: white !important;
    }
    
    .btn-primary:hover {
        background-color: #0056b3 !important;
        border-color: #0056b3 !important;
        color: white !important;
    }
    
    /* Botões de login específicos - tema claro */
    .card-body .btn-danger {
        background-color: #dc3545 !important;
        background-image: none !important;
        border-color: #dc3545 !important;
        color: white !important;
    }
    
    .card-body .btn-danger:hover {
        background-color: #c82333 !important;
        background-image: none !important;
        border-color: #c82333 !important;
        color: white !important;
    }
    
    .card-body .btn-primary {
        background-color: #007bff !important;
        background-image: none !important;
        border-color: #007bff !important;
        color: white !important;
    }
    
    .card-body .btn-primary:hover {
        background-color: #0056b3 !important;
        background-image: none !important;
        border-color: #0056b3 !important;
        color: white !important;
    }
    
    /* Generation timer */
    .generation-timer {
        background: #f8f9fa !important;
        border-color: #007bff !important;
        color: #212529 !important;
    }
    
    .generation-timer.active {
        background: #007bff !important;
        color: #ffffff !important;
    }
    
    /* Footer */
    footer {
        background: linear-gradient(135deg, #343A40 0%, #2c3e50 100%) !important;
        color: #ffffff !important;
    }
    
    footer a {
        color: #007bff !important;
    }
    
    footer a:hover {
        color: #0056b3 !important;
    }
}

/* ============================================ */
/* SISTEMA DE FLUXO ASCENDENTE PROGRESSIVO     */
/* ============================================ */

/* Classe para destacar campo inicial */
.qr-field-highlight {
    border: 2px solid #3B82F6 !important;
    box-shadow: 0 0 5px rgba(59, 130, 246, 0.3) !important;
    transition: all 0.3s ease !important;
}

/* Feedback visual para campos obrigatórios */
.required-field:invalid,
.form-control:invalid {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25) !important;
}

.required-field:valid,
.form-control:valid {
    border-color: #28a745 !important;
    box-shadow: 0 0 0 0.25rem rgba(40, 167, 69, 0.25) !important;
}

/* Estados de campos desabilitados */
.disabled-section {
    opacity: 0.6;
    pointer-events: none;
    transition: all 0.3s ease;
}

/* Transições suaves para seções */
.qr-section {
    transition: all 0.3s ease;
}

/* Tooltip para campos bloqueados */
.field-blocked-hint {
    color: #f59e0b;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    opacity: 0;
    animation: fadeIn 0.3s ease forwards;
}

.field-blocked-hint.show {
    opacity: 1;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Tema escuro - ajustes para sistema de fluxo */
html[data-theme="dark"] .qr-field-highlight {
    border-color: #60A5FA !important;
    box-shadow: 0 0 5px rgba(96, 165, 250, 0.3) !important;
}

html[data-theme="dark"] .required-field:invalid,
html[data-theme="dark"] .form-control:invalid {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 0.25rem rgba(239, 68, 68, 0.25) !important;
}

html[data-theme="dark"] .required-field:valid,
html[data-theme="dark"] .form-control:valid {
    border-color: #22c55e !important;
    box-shadow: 0 0 0 0.25rem rgba(34, 197, 94, 0.25) !important;
}

/* =================================
   UX IMPROVEMENTS - BUTTON READY STATES
   ================================= */

.btn-pulse {
    animation: buttonPulse 1.5s ease-in-out infinite;
    box-shadow: 0 0 10px rgba(0, 123, 255, 0.4) !important;
}

.btn-ready {
    background: linear-gradient(45deg, #007bff, #00d4ff) !important;
    border-color: #007bff !important;
    position: relative;
    overflow: hidden;
    transform: scale(1.02);
    transition: all 0.3s ease;
}

.btn-ready::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.btn-ready:hover::before {
    left: 100%;
}

@keyframes buttonPulse {
    0% { 
        transform: scale(1.02); 
        box-shadow: 0 0 10px rgba(0, 123, 255, 0.4);
    }
    50% { 
        transform: scale(1.05); 
        box-shadow: 0 0 20px rgba(0, 123, 255, 0.6);
    }
    100% { 
        transform: scale(1.02); 
        box-shadow: 0 0 10px rgba(0, 123, 255, 0.4);
    }
}

/* Dark mode adjustments for button ready states */
html[data-theme="dark"] .btn-pulse {
    box-shadow: 0 0 10px rgba(96, 165, 250, 0.4) !important;
}

html[data-theme="dark"] .btn-ready {
    background: linear-gradient(45deg, #3b82f6, #60a5fa) !important;
}

html[data-theme="dark"] @keyframes buttonPulse {
    0% { 
        transform: scale(1.02); 
        box-shadow: 0 0 10px rgba(96, 165, 250, 0.4);
    }
    50% { 
        transform: scale(1.05); 
        box-shadow: 0 0 20px rgba(96, 165, 250, 0.6);
    }
    100% { 
        transform: scale(1.02); 
        box-shadow: 0 0 10px rgba(96, 165, 250, 0.4);
    }
}
