/* ==========================================
   MOBILE OPTIMIZATION - COMPLETO E FUNCIONAL
   Remodelagem total para mobile
   ========================================== */

/* ===== RESET GLOBAL ===== */
* {
    box-sizing: border-box;
}

/* Botão minimizar - escondido no desktop */
@media (min-width: 769px) {
    .sidebar-toggle-mobile {
        display: none;
    }
}

.sidebar-overlay {
    display: none !important;
}

.mobile-menu-toggle {
    display: none !important;
}

/* ===== MOBILE (<768px) ===== */
@media (max-width: 768px) {
    
    /* Garantir que o botão toggle apareça no mobile */
    .sidebar-toggle-mobile {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    /* FORCE SCROLL GLOBAL */
    * {
        -webkit-overflow-scrolling: touch !important;
    }
    
    /* PREVENIR ELEMENTOS SAINDO DA TELA */
    * {
        max-width: 100vw !important;
        overflow-wrap: break-word !important;
        word-wrap: break-word !important;
    }
    
    /* Containers principais */
    body,
    html,
    .main-content,
    .dashboard-with-sidebar,
    .dashboard-main-content,
    #vendas,
    #cupons,
    #relatorios,
    #configuracoes {
        width: 100% !important;
        max-width: 100vw !important;
        overflow-x: hidden !important;
    }
    
    /* Garantir que todos os elementos clicáveis sejam acessíveis */
    button,
    a,
    input,
    select,
    textarea,
    .clickable,
    [onclick] {
        pointer-events: auto !important;
        touch-action: manipulation !important;
        position: relative;
        z-index: 1;
    }
    
    /* Links e URLs quebrando corretamente */
    a,
    .url,
    .link,
    [href] {
        word-break: break-all !important;
        overflow-wrap: break-word !important;
        max-width: 100% !important;
        display: inline-block !important;
    }
    
    /* Reset body */
    html, body {
        margin: 0;
        padding: 0;
        overflow-x: hidden;
        overflow-y: auto !important;
        width: 100%;
        height: auto;
        min-height: 100vh;
    }
    
    body {
        touch-action: pan-y;
        overscroll-behavior-y: contain;
    }
    
    /* Header fixo */
    .header {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 60px;
        z-index: 1000;
        background: #000;
        box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    }
    
    .header-container {
        padding: 0 16px;
        height: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }
    
    .header .logo {
        height: 35px;
        width: auto;
    }
    
    .header-nav {
        display: none;
    }
    
    .header .btn-logout {
        padding: 8px 12px;
        font-size: 12px;
    }
    
    /* Main content */
    .main-content {
        padding-top: 60px;
        width: 100%;
        height: auto !important;
        min-height: 100vh !important;
        overflow-y: auto !important;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch !important;
        position: relative;
    }
    
    /* Layout dashboard */
    .dashboard-with-sidebar {
        display: flex;
        flex-direction: column;
        width: 100%;
        height: auto !important;
        min-height: 100vh !important;
        overflow-y: auto !important;
        overflow-x: hidden;
        position: relative;
    }
    
    /* ===== SIDEBAR MINIMIZÁVEL ===== */
    .modern-sidebar {
        position: relative !important;
        width: 100% !important;
        background: #000 !important;
        border-bottom: 1px solid #1a1a1a !important;
        max-height: 2000px !important;
        overflow: visible !important;
        transition: max-height 0.3s ease !important;
        z-index: 100 !important;
        margin: 20px 0 0 0 !important;
        padding: 0 !important;
        display: block !important;
        visibility: visible !important;
    }
    
    .modern-sidebar.minimized {
        max-height: 40px !important;
        overflow: hidden !important;
    }
    
    /* Botão toggle - garantir visibilidade */
    .sidebar-toggle-mobile {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100% !important;
        padding: 8px 10px !important;
        background: #000 !important;
        border: none !important;
        color: #fff !important;
        cursor: pointer !important;
        min-height: 40px !important;
        max-height: 40px !important;
        height: 40px !important;
        font-size: 11px !important;
        font-weight: 600 !important;
        margin: 0 !important;
    }
    
    .sidebar-toggle-mobile .toggle-text {
        display: flex !important;
        align-items: center !important;
        gap: 6px !important;
        font-size: 11px !important;
    }
    
    .sidebar-toggle-mobile .toggle-text i {
        font-size: 10px !important;
    }
    
    .sidebar-toggle-mobile i {
        font-size: 10px !important;
    }
    
    .sidebar-toggle-mobile i.fa-chevron-up {
        transition: transform 0.3s ease;
    }
    
    .modern-sidebar.minimized .sidebar-toggle-mobile i.fa-chevron-up {
        transform: rotate(180deg);
    }
    
    /* Conteúdo sidebar */
    .sidebar-content-wrapper {
        padding: 6px !important;
    }
    
    .modern-sidebar.minimized .sidebar-content-wrapper {
        display: none !important;
    }
    
    /* User card */
    .modern-sidebar .sidebar-user-card {
        display: flex !important;
        padding: 6px !important;
        margin-bottom: 6px !important;
        background: rgba(255,255,255,0.05) !important;
        border-radius: 6px !important;
        gap: 8px !important;
    }
    
    .modern-sidebar .user-avatar {
        font-size: 20px !important;
        min-width: 20px !important;
    }
    
    .modern-sidebar .user-avatar i {
        font-size: 20px !important;
    }
    
    .modern-sidebar .user-info {
        flex: 1 !important;
        min-width: 0 !important;
    }
    
    .modern-sidebar .user-name {
        font-size: 11px !important;
        font-weight: 600 !important;
        line-height: 1.3 !important;
        margin: 0 0 2px 0 !important;
    }
    
    .modern-sidebar .user-role {
        font-size: 9px !important;
        opacity: 0.7 !important;
        line-height: 1.3 !important;
        margin: 0 !important;
    }
    
    /* Navegação */
    .modern-sidebar .sidebar-brand {
        display: none !important;
    }
    
    .modern-sidebar .sidebar-section {
        margin: 0 !important;
        padding: 0 !important;
    }
    
    .modern-sidebar .section-label {
        font-size: 9px !important;
        text-transform: uppercase !important;
        opacity: 0.5 !important;
        margin: 6px 0 4px 0 !important;
        letter-spacing: 0.3px !important;
        padding: 0 !important;
    }
    
    .modern-sidebar .sidebar-nav {
        display: flex !important;
        flex-direction: column !important;
        gap: 4px !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    .modern-sidebar .nav-item {
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        padding: 6px 8px !important;
        border-radius: 6px !important;
        background: rgba(255,255,255,0.03) !important;
        cursor: pointer !important;
        transition: all 0.2s ease !important;
        border: none !important;
        color: #fff !important;
        text-align: left !important;
        width: 100% !important;
        margin: 0 !important;
        min-height: 44px !important;
    }
    
    .modern-sidebar .nav-item:active {
        transform: scale(0.98) !important;
    }
    
    .modern-sidebar .nav-item.active {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%) !important;
        border-left: 3px solid #fff !important;
    }
    
    .modern-sidebar .nav-item-icon {
        width: auto !important;
        height: auto !important;
        min-width: 18px !important;
        max-width: 18px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        background: transparent !important;
        border-radius: 0 !important;
        font-size: 14px !important;
        color: rgba(255,255,255,0.9) !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    
    .modern-sidebar .nav-item-icon i {
        font-size: 14px !important;
    }
    
    .modern-sidebar .nav-item.active .nav-item-icon {
        color: #fff !important;
    }
    
    .modern-sidebar .nav-item-content {
        flex: 1 !important;
        margin-left: 0 !important;
        min-width: 0 !important;
        padding: 0 !important;
    }
    
    .modern-sidebar .nav-item-title {
        font-size: 11px !important;
        font-weight: 600 !important;
        margin: 0 0 2px 0 !important;
        line-height: 1.3 !important;
        padding: 0 !important;
        display: block !important;
    }
    
    .modern-sidebar .nav-item-subtitle {
        font-size: 9px !important;
        opacity: 0.6 !important;
        margin: 0 !important;
        line-height: 1.3 !important;
        padding: 0 !important;
        display: block !important;
    }
    
    .modern-sidebar .nav-arrow {
        display: none !important;
    }
    
    /* Footer sidebar */
    .modern-sidebar .sidebar-footer {
        padding: 6px 0 !important;
        margin-top: 6px !important;
        border-top: 1px solid rgba(255,255,255,0.1) !important;
    }
    
    .modern-sidebar .footer-stats {
        display: none !important;
    }
    
    .modern-sidebar .btn-logout-sidebar {
        width: 100% !important;
        padding: 8px !important;
        background: rgba(239, 68, 68, 0.1) !important;
        color: #ef4444 !important;
        border: 1px solid rgba(239, 68, 68, 0.3) !important;
        border-radius: 6px !important;
        font-size: 11px !important;
        cursor: pointer !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 6px !important;
        font-weight: 500 !important;
        margin: 0 !important;
        min-height: 36px !important;
    }
    
    .modern-sidebar .btn-logout-sidebar i {
        font-size: 10px !important;
        margin-right: 0 !important;
    }
    
    /* ===== CONTEÚDO PRINCIPAL ===== */
    .dashboard-main-content {
        width: 100%;
        padding: 10px 10px 100px 10px;
        height: auto !important;
        overflow-y: auto !important;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch !important;
        max-width: 100%;
        position: relative;
    }
    
    /* ===== TODAS AS SEÇÕES ===== */
    #vendas,
    #cupons,
    #relatorios,
    #configuracoes {
        width: 100%;
        max-width: 100%;
        padding: 0 0 80px 0;
        margin: 0;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }
    
    /* ===== DASHBOARD HEADER ===== */
    .dashboard-header {
        padding: 0 0 10px 0;
        margin-bottom: 12px;
        border-bottom: 1px solid #e5e7eb;
    }
    
    .dashboard-header h1 {
        font-size: 16px !important;
        font-weight: 600 !important;
        margin: 0 0 3px 0;
        line-height: 1.3;
    }
    
    .dashboard-header p {
        font-size: 11px;
        margin: 0;
        opacity: 0.7;
    }
    
    /* ===== ANALYTICS CARDS ===== */
    .analytics-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        margin-bottom: 20px;
    }
    
    .analytics-card {
        padding: 16px;
        background: #fff;
        border-radius: 12px;
        box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    }
    
    .analytics-card-header {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 12px;
    }
    
    .analytics-icon {
        width: 40px;
        height: 40px;
        min-width: 40px;
        border-radius: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
    }
    
    .analytics-title {
        font-size: 12px;
        font-weight: 600;
        opacity: 0.7;
        text-transform: uppercase;
    }
    
    .analytics-value {
        font-size: 24px;
        font-weight: 700;
        margin-bottom: 8px;
    }
    
    .analytics-change {
        font-size: 11px;
    }
    
    /* ===== TABS ===== */
    .tabs-container {
        margin: 0 -16px 16px -16px;
        padding: 0 16px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .tabs {
        display: flex;
        gap: 8px;
        border-bottom: 2px solid #e5e7eb;
        min-width: min-content;
        padding-bottom: 0;
    }
    
    .tab-btn {
        padding: 12px 16px;
        font-size: 13px;
        white-space: nowrap;
        background: transparent;
        border: none;
        border-bottom: 2px solid transparent;
        cursor: pointer;
        color: #6b7280;
        font-weight: 500;
        margin-bottom: -2px;
    }
    
    .tab-btn.active {
        color: #1a1a1a;
        border-bottom-color: #1a1a1a;
        font-weight: 600;
    }
    
    /* ===== TABELAS ===== */
    .table-container {
        width: calc(100% + 32px);
        overflow-x: auto;
        overflow-y: visible;
        -webkit-overflow-scrolling: touch;
        margin: 0 -16px;
        padding: 0 16px;
        margin-bottom: 20px;
        position: relative;
    }
    
    .table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    table {
        min-width: 800px;
        width: auto;
        font-size: 12px;
        border-collapse: collapse;
        display: table;
    }
    
    table thead {
        background: #f9fafb;
    }
    
    table th {
        padding: 10px 8px;
        text-align: left;
        font-size: 11px;
        font-weight: 600;
        color: #6b7280;
        text-transform: uppercase;
        white-space: nowrap;
    }
    
    table td {
        padding: 12px 8px;
        border-top: 1px solid #f3f4f6;
        font-size: 12px;
    }
    
    table tbody tr:hover {
        background: #f9fafb;
    }
    
    /* ===== FILTROS ===== */
    .filters-section {
        background: #f9fafb;
        padding: 16px;
        border-radius: 12px;
        margin-bottom: 16px;
    }
    
    .filters-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .filter-group {
        margin-bottom: 0;
    }
    
    .filter-group label {
        display: block;
        font-size: 12px;
        font-weight: 600;
        margin-bottom: 6px;
        color: #374151;
    }
    
    .filter-input,
    .filter-select,
    input[type="text"],
    input[type="email"],
    input[type="number"],
    input[type="date"],
    select {
        width: 100%;
        padding: 10px 12px;
        border: 1px solid #d1d5db;
        border-radius: 8px;
        font-size: 16px !important; /* Evita zoom iOS */
        background: #fff;
    }
    
    .filter-input:focus,
    .filter-select:focus,
    input:focus,
    select:focus {
        outline: none;
        border-color: #1a1a1a;
        box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1);
    }
    
    .filter-actions {
        display: flex;
        gap: 8px;
        margin-top: 12px;
    }
    
    .filter-actions button {
        flex: 1;
    }
    
    /* ===== BUTTONS ===== */
    .btn,
    button:not(.nav-item):not(.sidebar-toggle-mobile) {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        padding: 12px 16px;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.2s ease;
        border: none;
        min-height: 44px;
    }
    
    .btn-primary {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
        color: #fff;
    }
    
    .btn-secondary {
        background: #f3f4f6;
        color: #374151;
    }
    
    .btn-success {
        background: #10b981;
        color: #fff;
    }
    
    .btn-danger {
        background: #ef4444;
        color: #fff;
    }
    
    .btn:active {
        transform: scale(0.98);
    }
    
    /* ===== CUPONS ===== */
    .cupons-container {
        padding: 0;
    }
    
    .cupons-header {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-bottom: 16px;
    }
    
    #criar-cupom-btn {
        width: 100%;
    }
    
    .cupons-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .cupom-card,
    .cupom-card-minimal {
        padding: 16px;
        background: #fff;
        border-radius: 12px;
        box-shadow: 0 1px 3px rgba(0,0,0,0.1);
        border-left: 4px solid #1a1a1a;
    }
    
    .cupom-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        margin-bottom: 12px;
    }
    
    .cupom-code {
        font-size: 16px;
        font-weight: 700;
        color: #1a1a1a;
    }
    
    .cupom-info {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        font-size: 12px;
    }
    
    .cupom-actions {
        display: flex;
        gap: 8px;
        margin-top: 12px;
    }
    
    .cupom-actions button {
        flex: 1;
        padding: 8px;
        font-size: 12px;
        min-height: 36px;
    }
    
    #form-cupom {
        background: #f9fafb;
        padding: 16px;
        border-radius: 12px;
        margin-bottom: 16px;
    }
    
    #form-cupom .form-group {
        margin-bottom: 12px;
    }
    
    #form-cupom label {
        display: block;
        font-size: 12px;
        font-weight: 600;
        margin-bottom: 6px;
    }
    
    #form-cupom input,
    #form-cupom select {
        width: 100%;
    }
    
    #form-cupom .form-actions {
        display: flex;
        gap: 8px;
        margin-top: 16px;
    }
    
    #form-cupom .form-actions button {
        flex: 1;
    }
    
    /* ===== RELATÓRIOS ===== */
    .relatorios-container {
        padding: 0;
    }
    
    .reports-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .report-card {
        padding: 16px;
        background: #fff;
        border-radius: 12px;
        box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    }
    
    .report-card h3 {
        font-size: 16px;
        margin: 0 0 8px 0;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    
    .report-card p {
        font-size: 13px;
        margin: 0 0 12px 0;
        opacity: 0.7;
    }
    
    .btn-report {
        width: 100%;
    }
    
    /* ===== CONFIGURAÇÕES ===== */
    .configuracoes-container {
        padding: 0;
        width: 100%;
        max-width: 100%;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }
    
    /* ===== SEÇÃO CONFIGURAÇÕES ===== */
    #configuracoes {
        padding: 8px;
        width: 100%;
        max-width: 100%;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Header de Configurações */
    #configuracoes > div:first-child {
        padding: 14px 12px !important;
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%) !important;
        border-radius: 10px !important;
        margin: 0 0 14px 0 !important;
        border: none !important;
        box-shadow: 0 4px 15px rgba(26, 26, 26, 0.3) !important;
        position: relative !important;
        overflow: hidden !important;
    }
    
    /* Efeito decorativo */
    #configuracoes > div:first-child::before {
        content: '' !important;
        position: absolute !important;
        top: -50px !important;
        right: -50px !important;
        width: 150px !important;
        height: 150px !important;
        background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%) !important;
        border-radius: 50% !important;
        pointer-events: none !important;
    }
    
    /* Título "Configurações do Evento" */
    #configuracoes > div:first-child h2 {
        font-size: 16px !important;
        font-weight: 600 !important;
        color: #ffffff !important;
        margin: 0 0 4px 0 !important;
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        text-shadow: 0 2px 4px rgba(0,0,0,0.15) !important;
        position: relative !important;
        z-index: 1 !important;
    }
    
    #configuracoes > div:first-child h2 i {
        font-size: 15px !important;
        color: rgba(255, 255, 255, 0.9) !important;
        background: rgba(255, 255, 255, 0.2) !important;
        padding: 6px !important;
        border-radius: 6px !important;
        backdrop-filter: blur(10px) !important;
    }
    
    /* Descrição */
    #configuracoes > div:first-child p {
        font-size: 11px !important;
        color: rgba(255, 255, 255, 0.95) !important;
        margin: 0 0 14px 0 !important;
        font-weight: 400 !important;
        line-height: 1.4 !important;
        position: relative !important;
        z-index: 1 !important;
    }
    
    /* Reduzir TODOS os elementos dentro de configurações */
    #configuracoes * {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
    
    #configuracoes h1,
    #configuracoes h2,
    #configuracoes h3,
    #configuracoes h4,
    #configuracoes h5,
    #configuracoes h6 {
        font-size: 13px !important;
        font-weight: 600 !important;
        margin: 0 0 6px 0 !important;
        line-height: 1.3 !important;
    }
    
    #configuracoes p {
        font-size: 10px !important;
        margin: 0 0 6px 0 !important;
        line-height: 1.3 !important;
    }
    
    #configuracoes button {
        font-size: 11px !important;
        padding: 7px 10px !important;
    }
    
    #configuracoes input,
    #configuracoes select,
    #configuracoes textarea {
        font-size: 13px !important;
        padding: 7px 8px !important;
    }
    
    /* Container das abas - REMOVIDO (já estilizado acima) */
    
    /* Wrapper das abas - VERTICAL NO MOBILE */
    #configuracoes > div:first-child > div:last-child {
        display: flex !important;
        flex-direction: column !important;
        gap: 7px !important;
        border: none !important;
        margin: 0 !important;
        padding: 0 !important;
        width: 100% !important;
        position: relative !important;
        z-index: 1 !important;
    }
    
    /* BOTÕES DAS ABAS - VERTICAL */
    .config-tab-btn {
        width: 100% !important;
        padding: 9px 11px !important;
        margin: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        gap: 9px !important;
        background: rgba(255, 255, 255, 0.15) !important;
        backdrop-filter: blur(10px) !important;
        border: 1.5px solid rgba(255, 255, 255, 0.25) !important;
        border-radius: 8px !important;
        font-size: 11px !important;
        font-weight: 600 !important;
        color: rgba(255, 255, 255, 0.85) !important;
        cursor: pointer !important;
        transition: all 0.3s ease !important;
        text-align: left !important;
        position: static !important;
        top: 0 !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
    }
    
    .config-tab-btn:hover {
        transform: translateY(-1px) !important;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
        background: rgba(255, 255, 255, 0.25) !important;
        border-color: rgba(255, 255, 255, 0.4) !important;
    }
    
    .config-tab-btn i {
        font-size: 13px !important;
        margin: 0 !important;
        color: rgba(255, 255, 255, 0.8) !important;
        min-width: 16px !important;
        text-align: center !important;
        transition: all 0.3s ease !important;
    }
    
    .config-tab-btn.active {
        background: rgba(255, 255, 255, 1) !important;
        color: #1a1a1a !important;
        border-color: rgba(255, 255, 255, 1) !important;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2) !important;
        transform: scale(1.02) !important;
    }
    
    .config-tab-btn.active i {
        color: #1a1a1a !important;
        transform: scale(1.1) !important;
    }
    
    /* Container do conteúdo das abas */
    #configuracoes > div:last-child {
        padding: 0 !important;
        margin: 0 !important;
        max-width: 100% !important;
    }
    
    /* Espaçamento interno das abas */
    .config-tab-content {
        padding: 0 !important;
        margin: 0 !important;
    }
    
    /* Ocultar mensagens de arraste e solte no mobile */
    #configuracoes .info-box,
    #configuracoes [class*="info"],
    #configuracoes p[style*="color: #888"]:first-of-type,
    #config-tab-ingressos > p:first-of-type,
    #config-tab-ofertas > p:first-of-type,
    #config-tab-afiliados > p:first-of-type,
    #config-tab-ingressos p:contains("Arraste"),
    #config-tab-ingressos p:contains("arraste"),
    #config-tab-ingressos .drag-info,
    #config-tab-ingressos .drag-drop-info,
    #config-tab-ingressos p[style*="color: #888"],
    .ingresso-card p:contains("Arraste"),
    .ingresso-card p:contains("arraste"),
    .config-ingressos-grid + p,
    .drag-drop-info-ingressos,
    div[style*="background: linear-gradient(135deg, #f0f9ff"],
    div[style*="border-left: 4px solid #3b82f6"],
    p:contains("Arraste e solte para reordenar") {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
        height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: hidden !important;
    }
    
    /* Arraste e solte - ocultar globalmente */
    #configuracoes p:contains("Arraste e solte"),
    #configuracoes p:contains("arraste"),
    #configuracoes .drag-info,
    .drag-drop-info,
    p[style*="color: #888"]:contains("arraste"),
    p[style*="color: #888"]:contains("Arraste") {
        display: none !important;
    }
    
    /* Títulos de seção dentro das abas */
    .config-tab-content > h3,
    .config-tab-content > div > h3 {
        font-size: 14px !important;
        font-weight: 600 !important;
        color: #1f2937 !important;
        margin: 0 0 10px 0 !important;
        padding: 10px 12px !important;
        background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%) !important;
        border-left: 3px solid #1a1a1a !important;
        border-radius: 8px !important;
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
    }
    
    /* Descrições de seção */
    .config-tab-content > p,
    .config-tab-content > div > p:not([style*="color: #888"]) {
        font-size: 10px !important;
        color: #6b7280 !important;
        margin: 0 0 12px 0 !important;
        line-height: 1.4 !important;
        padding: 0 2px !important;
    }
    
    /* Banner do Evento (card roxo com foto) */
    #config-tab-seu-evento > div:first-child {
        padding: 14px !important;
        margin: 0 0 14px 0 !important;
        border-radius: 10px !important;
        position: relative !important;
        overflow: hidden !important;
        box-shadow: 0 4px 15px rgba(26, 26, 26, 0.25) !important;
    }
    
    #config-tab-seu-evento > div:first-child::before {
        content: '' !important;
        position: absolute !important;
        top: -50% !important;
        right: -20% !important;
        width: 200px !important;
        height: 200px !important;
        background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%) !important;
        border-radius: 50% !important;
    }
    
    #config-tab-seu-evento > div:first-child img {
        width: 55px !important;
        height: 55px !important;
        border-radius: 8px !important;
        box-shadow: 0 4px 12px rgba(0,0,0,0.2) !important;
        border: 2px solid rgba(255,255,255,0.3) !important;
    }
    
    #config-tab-seu-evento > div:first-child h3 {
        font-size: 15px !important;
        margin: 0 0 4px 0 !important;
        font-weight: 600 !important;
        text-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
    }
    
    #config-tab-seu-evento > div:first-child p {
        font-size: 10px !important;
        margin: 0 0 8px 0 !important;
        opacity: 0.95 !important;
    }
    
    #config-tab-seu-evento > div:first-child span {
        font-size: 9px !important;
        padding: 4px 8px !important;
        background: rgba(255, 255, 255, 0.25) !important;
        backdrop-filter: blur(10px) !important;
        border: 1px solid rgba(255, 255, 255, 0.3) !important;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
    }
    
    #config-tab-seu-evento > div:first-child i {
        font-size: 9px !important;
    }
    
    /* ===== TABS DE CONFIGURAÇÃO - MOBILE REDESIGN ===== */
    .config-tabs {
        margin: 0 0 16px 0;
        padding: 0;
        width: 100%;
        overflow: visible;
    }
    
    .config-tabs-nav {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        border: none;
        width: 100%;
        padding: 0;
    }
    
    .config-tab-btn {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 16px;
        font-size: 15px;
        font-weight: 600;
        background: #fff;
        border: 2px solid #e5e7eb;
        border-radius: 12px;
        cursor: pointer;
        color: #374151;
        transition: all 0.2s ease;
        width: 100%;
        text-align: left;
        white-space: normal;
        word-wrap: break-word;
        box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    }
    
    .config-tab-btn::after {
        content: '\f054';
        font-family: 'Font Awesome 6 Free';
        font-weight: 900;
        font-size: 14px;
        color: #9ca3af;
        transition: all 0.2s ease;
    }
    
    .config-tab-btn.active {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
        color: #fff;
        border-color: #1a1a1a;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    }
    
    .config-tab-btn.active::after {
        color: #fff;
        transform: rotate(90deg);
    }
    
    /* ===== CARDS DE CONFIGURAÇÃO ===== */
    .config-cards-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        width: 100%;
        max-width: 100%;
        margin-top: 0;
        padding: 0;
    }
    
    .config-card {
        padding: 12px;
        background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
        border-radius: 10px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        overflow: visible;
        border: 1px solid #e8ebf5;
        transition: all 0.3s ease;
        position: relative;
        margin-bottom: 12px;
    }
    
    .config-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 4px;
        height: 100%;
        background: linear-gradient(180deg, #1a1a1a 0%, #2d2d2d 100%);
        border-radius: 10px 0 0 10px;
    }
    
    .config-card:hover {
        box-shadow: 0 4px 12px rgba(26, 26, 26, 0.12);
        transform: translateY(-2px);
    }
    
    .config-card h3 {
        font-size: 13px;
        font-weight: 600;
        margin: 0 0 4px 0;
        display: flex;
        align-items: center;
        gap: 8px;
        color: #1f2937;
        word-wrap: break-word;
        line-height: 1.3;
    }
    
    .config-card h3 i {
        font-size: 14px;
        color: #1a1a1a;
        background: linear-gradient(135deg, rgba(26, 26, 26, 0.1) 0%, rgba(45, 45, 45, 0.1) 100%);
        padding: 6px;
        border-radius: 6px;
        min-width: 26px;
        text-align: center;
    }
    
    .config-card .card-description {
        font-size: 10px;
        margin: 0 0 10px 0;
        color: #6b7280;
        line-height: 1.4;
        word-wrap: break-word;
    }
    
    .config-card .form-group-modern {
        margin-bottom: 10px;
    }
    
    .config-card .form-group-modern:last-of-type {
        margin-bottom: 12px;
    }
    
    .config-card label {
        display: block;
        font-size: 11px;
        font-weight: 600;
        margin-bottom: 5px;
        color: #374151;
        word-wrap: break-word;
        display: flex;
        align-items: center;
        gap: 5px;
    }
    
    .config-card label i {
        font-size: 10px;
        color: #9ca3af;
    }
    
    .config-card input,
    .config-card select,
    .config-card textarea {
        width: 100%;
        max-width: 100%;
        padding: 8px 10px;
        border: 1.5px solid #e5e7eb;
        border-radius: 7px;
        font-size: 13px !important;
        background: #ffffff;
        box-sizing: border-box;
        -webkit-appearance: none;
        appearance: none;
        transition: all 0.3s ease;
        box-shadow: 0 1px 2px rgba(0,0,0,0.02);
    }
    
    .config-card textarea {
        min-height: 50px;
        max-height: 120px;
        resize: vertical;
        overflow-y: auto;
        line-height: 1.4;
    }
    
    .config-card input:focus,
    .config-card select:focus,
    .config-card textarea:focus {
        outline: none;
        border-color: #1a1a1a;
        background: #f9fafb;
        box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1), 0 2px 4px rgba(0,0,0,0.05);
        transform: translateY(-1px);
    }
    
    .btn-save-config {
        width: 100%;
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
        color: #fff;
        padding: 9px;
        border-radius: 8px;
        border: none;
        font-size: 12px;
        font-weight: 600;
        cursor: pointer;
        box-shadow: 0 3px 10px rgba(26, 26, 26, 0.25);
        transition: all 0.3s ease;
        position: relative;
        overflow: hidden;
    }
    
    .btn-save-config::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 0;
        height: 0;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.2);
        transform: translate(-50%, -50%);
        transition: width 0.6s, height 0.6s;
    }
    
    .btn-save-config:hover::before {
        width: 300px;
        height: 300px;
    }
    
    .btn-save-config:active {
        transform: scale(0.98);
        box-shadow: 0 2px 6px rgba(26, 26, 26, 0.3);
    }
    
    /* ===== INGRESSOS GRID ===== */
    #ingressos-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        margin-bottom: 14px;
        width: 100%;
        max-width: 100%;
        padding: 0;
    }
    
    .ingresso-card {
        padding: 12px;
        background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
        border-radius: 10px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
        border-left: 3px solid transparent;
        border-image: linear-gradient(180deg, #1a1a1a 0%, #2d2d2d 100%) 1;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        overflow: visible;
        border: 1px solid #e8ebf5;
        border-left: 3px solid #1a1a1a;
        transition: all 0.3s ease;
        position: relative;
        margin-bottom: 12px;
    }
    
    .ingresso-card::after {
        content: '🎫';
        position: absolute;
        top: 12px;
        right: 12px;
        font-size: 20px;
        opacity: 0.1;
    }
    
    .ingresso-card:hover {
        box-shadow: 0 4px 12px rgba(26, 26, 26, 0.12);
        transform: translateX(3px);
    }
    
    .ingresso-card h4 {
        font-size: 13px;
        font-weight: 600;
        margin: 0 0 8px 0;
        color: #1f2937;
        word-wrap: break-word;
        padding-bottom: 6px;
        border-bottom: 2px solid #f3f4f6;
        line-height: 1.3;
        display: flex;
        align-items: center;
        gap: 6px;
    }
    
    .ingresso-card h4::before {
        content: '';
        display: none;
    }
    
    .ingresso-card .form-group {
        margin-bottom: 8px;
        width: 100%;
    }
    
    .ingresso-card label {
        display: block;
        font-size: 10px;
        font-weight: 600;
        margin-bottom: 4px;
        color: #374151;
        word-wrap: break-word;
        text-transform: uppercase;
        letter-spacing: 0.3px;
    }
    
    .ingresso-card input,
    .ingresso-card textarea,
    .ingresso-card select {
        width: 100%;
        max-width: 100%;
        padding: 7px 9px;
        font-size: 12px !important;
        border: 1.5px solid #e5e7eb;
        border-radius: 7px;
        box-sizing: border-box;
        background: #ffffff;
        transition: all 0.3s ease;
        box-shadow: 0 1px 2px rgba(0,0,0,0.02);
    }
    
    .ingresso-card input:focus,
    .ingresso-card textarea:focus,
    .ingresso-card select:focus {
        outline: none;
        border-color: #1a1a1a;
        background: #f9fafb;
        box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.1), 0 2px 4px rgba(0,0,0,0.05);
        transform: translateY(-1px);
    }
    
    .ingresso-card textarea {
        min-height: 45px;
        max-height: 100px;
        resize: vertical;
        overflow-y: auto;
        line-height: 1.4;
    }
    
    .ingresso-card .valor-info {
        font-size: 9px;
        margin-top: 3px;
        color: #6b7280;
        word-wrap: break-word;
        font-style: italic;
    }
    
    .ingresso-card .ingresso-actions {
        display: flex;
        flex-direction: column;
        gap: 6px;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 2px solid #f3f4f6;
    }
    
    .ingresso-card .ingresso-actions button {
        width: 100%;
        padding: 8px;
        font-size: 11px;
        font-weight: 600;
        border-radius: 7px;
        border: none;
        cursor: pointer;
        transition: all 0.3s ease;
        box-shadow: 0 2px 4px rgba(0,0,0,0.06);
    }
    
    .ingresso-card .ingresso-actions button:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 8px rgba(0,0,0,0.12);
    }
    
    .ingresso-card .ingresso-actions button:active {
        transform: scale(0.98);
    }
    
    /* ===== OFERTAS E AFILIADOS ===== */
    .ofertas-container,
    .afiliados-container {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        width: 100%;
        max-width: 100%;
        padding: 0;
    }
    
    .oferta-card,
    .afiliado-card {
        padding: 12px;
        background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
        border-radius: 10px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        overflow: visible;
        border: 1px solid #fef3e2;
        transition: all 0.3s ease;
        position: relative;
        margin-bottom: 12px;
    }
    
    .oferta-card::before,
    .afiliado-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 3px;
        background: linear-gradient(90deg, #f59e0b 0%, #d97706 100%);
        border-radius: 10px 10px 0 0;
    }
    
    .oferta-card:hover,
    .afiliado-card:hover {
        box-shadow: 0 4px 12px rgba(245, 158, 11, 0.12);
        transform: translateY(-2px);
    }
    
    .oferta-card h4,
    .afiliado-card h4 {
        font-size: 13px;
        font-weight: 600;
        margin: 0 0 8px 0;
        color: #1f2937;
        word-wrap: break-word;
        display: flex;
        align-items: center;
        gap: 8px;
        padding-bottom: 6px;
        border-bottom: 2px solid #fef3e2;
        line-height: 1.3;
    }
    
    .oferta-card h4 i,
    .afiliado-card h4 i {
        font-size: 14px;
        color: #f59e0b;
        background: rgba(245, 158, 11, 0.1);
        padding: 6px;
        border-radius: 6px;
        min-width: 26px;
        text-align: center;
    }
    
    .oferta-card .oferta-link,
    .afiliado-card .afiliado-link {
        font-size: 9px;
        padding: 8px;
        background: linear-gradient(135deg, #fef3e2 0%, #fef9f0 100%);
        border: 1.5px dashed #f59e0b;
        border-radius: 7px;
        word-break: break-all;
        margin: 8px 0;
        overflow-wrap: break-word;
        max-width: 100%;
        display: block;
        font-family: 'Courier New', monospace;
        color: #92400e;
        line-height: 1.3;
        position: relative;
    }
    
    .oferta-card .oferta-link::before,
    .afiliado-card .afiliado-link::before {
        content: '🔗';
        position: absolute;
        top: 6px;
        right: 6px;
        font-size: 12px;
        opacity: 0.3;
    }
    
    .oferta-card .oferta-actions,
    .afiliado-card .afiliado-actions {
        display: flex;
        flex-direction: column;
        gap: 6px;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 2px solid #fef3e2;
    }
    
    .oferta-card .oferta-actions button,
    .afiliado-card .afiliado-actions button {
        width: 100%;
        padding: 8px;
        font-size: 11px;
        font-weight: 600;
        border-radius: 7px;
        border: none;
        cursor: pointer;
        transition: all 0.3s ease;
        box-shadow: 0 2px 4px rgba(0,0,0,0.06);
    }
    
    .oferta-card .oferta-actions button:hover,
    .afiliado-card .afiliado-actions button:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 8px rgba(0,0,0,0.12);
    }
    
    .oferta-card .oferta-actions button:active,
    .afiliado-card .afiliado-actions button:active {
        transform: scale(0.98);
    }
    
    /* ===== BOTÕES DE ADICIONAR ===== */
    .btn-add,
    button[onclick*="adicionar"],
    button[onclick*="criar"],
    button[onclick*="novo"] {
        width: 100%;
        padding: 8px;
        background: linear-gradient(135deg, #10b981 0%, #059669 100%);
        color: #fff;
        border: none;
        border-radius: 8px;
        font-size: 11px;
        font-weight: 600;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 7px;
        box-shadow: 0 3px 10px rgba(16, 185, 129, 0.25);
        transition: all 0.3s ease;
        margin-bottom: 14px;
        position: relative;
        overflow: hidden;
    }
    
    .btn-add::before,
    button[onclick*="adicionar"]::before,
    button[onclick*="criar"]::before,
    button[onclick*="novo"]::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 0;
        height: 0;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.2);
        transform: translate(-50%, -50%);
        transition: width 0.6s, height 0.6s;
    }
    
    .btn-add:hover::before,
    button[onclick*="adicionar"]:hover::before,
    button[onclick*="criar"]:hover::before,
    button[onclick*="novo"]:hover::before {
        width: 300px;
        height: 300px;
    }
    
    .btn-add i,
    button[onclick*="adicionar"] i,
    button[onclick*="criar"] i,
    button[onclick*="novo"] i {
        font-size: 11px;
        position: relative;
        z-index: 1;
    }
    
    .btn-add:hover,
    button[onclick*="adicionar"]:hover,
    button[onclick*="criar"]:hover,
    button[onclick*="novo"]:hover {
        transform: translateY(-2px);
        box-shadow: 0 5px 15px rgba(16, 185, 129, 0.35);
    }
    
    .btn-add:active,
    button[onclick*="adicionar"]:active,
    button[onclick*="criar"]:active,
    button[onclick*="novo"]:active {
        transform: scale(0.98);
    }
    
    /* ===== MODALS ===== */
    .modal,
    .modal-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 9999;
    }
    
    .modal-overlay {
        background: rgba(0,0,0,0.5);
        backdrop-filter: blur(4px);
    }
    
    .modal-content {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 90%;
        max-width: 400px;
        max-height: 80vh;
        background: #fff;
        border-radius: 12px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    }
    
    .modal-header {
        position: sticky;
        top: 0;
        background: #fff;
        padding: 16px;
        border-bottom: 1px solid #e5e7eb;
        border-radius: 12px 12px 0 0;
        z-index: 10;
        display: flex;
        gap: 12px;
        align-items: center;
    }
    
    .modal-header h2,
    .modal-header h3 {
        font-size: 18px;
        margin: 0;
    }
    
    .modal-header button {
        background: none;
        border: none;
        font-size: 24px;
        cursor: pointer;
        color: #6b7280;
        padding: 0;
        width: 32px;
        height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .modal-body {
        padding: 16px;
    }
    
    .modal-footer {
        position: sticky;
        bottom: 0;
        background: #fff;
        padding: 16px;
        border-top: 1px solid #e5e7eb;
        z-index: 10;
    }
    
    .modal-footer button {
        width: 100%;
        margin-bottom: 8px;
    }
    
    .modal-footer button:last-child {
        margin-bottom: 0;
    }
    
    /* Modal específico de compradores (consulta CPF) */
    #modal-compradores {
        align-items: center;
        justify-content: center;
    }
    
    #modal-compradores[style*="display: block"],
    #modal-compradores[style*="display:block"] {
        display: flex !important;
    }
    
    #modal-compradores .modal-content {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        width: 90%;
        max-width: 500px;
        max-height: 70vh;
        border-radius: 12px;
        padding: 20px;
    }
    
    #modal-compradores .fechar {
        position: absolute;
        top: 10px;
        right: 15px;
        font-size: 28px;
        font-weight: bold;
        color: #666;
        cursor: pointer;
        z-index: 11;
    }
    
    #modal-compradores h2 {
        font-size: 18px;
        margin: 0 0 16px 0;
        padding-right: 30px;
    }
    
    #dados-compradores {
        max-height: 50vh;
        overflow-y: auto;
    }
    
    /* Modal de relatório por email */
    #modal-relatorio.active {
        display: flex !important;
        align-items: center;
        justify-content: center;
    }
    
    #modal-relatorio .modal-content {
        position: relative;
        top: auto;
        left: auto;
        transform: none;
        width: 90%;
        max-width: 400px;
        max-height: 60vh;
        border-radius: 12px;
        padding: 0;
    }
    
    #modal-relatorio .modal-form {
        padding: 20px;
    }
    
    #modal-relatorio .modal-header {
        padding: 20px;
        border-bottom: 1px solid #e5e7eb;
    }
    
    #modal-relatorio .modal-actions {
        display: flex;
        gap: 10px;
        margin-top: 20px;
    }
    
    #modal-relatorio .modal-actions button {
        flex: 1;
        min-height: 44px;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.3s ease;
    }
    
    #modal-relatorio .btn-modal-cancel {
        background: #f3f4f6;
        color: #374151;
        border: none;
    }
    
    #modal-relatorio .btn-modal-confirm {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
        color: white;
        border: none;
    }
    
    /* ===== LOADER ===== */
    #global-page-loader,
    .loader-container {
        position: fixed !important;
        top: 50% !important;
        left: 50% !important;
        transform: translate(-50%, -50%) !important;
        z-index: 99999 !important;
    }
    
    body.loading {
        overflow: hidden !important;
        position: fixed !important;
        width: 100% !important;
        height: 100vh !important;
    }
    
    body:not(.loading) {
        overflow-y: auto !important;
        overflow-x: hidden !important;
        position: relative !important;
        height: auto !important;
    }
    
    /* ===== FOOTER ===== */
    .footer {
        padding: 24px 16px;
        background: #f9fafb;
        border-top: 1px solid #e5e7eb;
        margin-top: 40px;
    }
    
    .footer-content {
        text-align: center;
    }
    
    .footer p {
        font-size: 12px;
        margin: 0 0 12px 0;
    }
    
    .footer-links {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }
    
    .footer-links a {
        font-size: 12px;
        color: #1a1a1a;
    }
    
    /* ===== UTILITIES ===== */
    .hide-mobile {
        display: none !important;
    }
    
    .show-mobile {
        display: block !important;
    }
    
    /* ===== QUICK SEARCH WIDGET ===== */
    .quick-search-widget {
        position: fixed;
        bottom: 20px;
        right: 20px;
        z-index: 999;
    }
    
    .quick-search-btn {
        width: 56px;
        height: 56px;
        border-radius: 50%;
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
        color: #fff;
        border: none;
        box-shadow: 0 4px 12px rgba(26, 26, 26, 0.4);
        font-size: 20px;
        cursor: pointer;
    }
    
    .quick-search-panel {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: #fff;
        transform: translateY(100%);
        transition: transform 0.3s ease;
    }
    
    .quick-search-panel.active {
        transform: translateY(0);
    }
}

/* ===== SMALL DEVICES (<480px) ===== */
@media (max-width: 480px) {
    .analytics-value {
        font-size: 20px;
    }
    
    .dashboard-header h1 {
        font-size: 18px !important;
    }
    
    table {
        font-size: 11px;
    }
    
    table th,
    table td {
        padding: 8px 6px;
    }
}


/* ===== MOBILE ONLY ===== */
@media (max-width: 768px) {
    
    /* Reset básico */
    body {
        margin: 0;
        padding: 0;
        overflow-x: hidden;
    }
    
    /* Header fixo */
    .header {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 60px;
        z-index: 999;
        background: #000;
    }
    
    .header-container {
        padding: 0 16px;
        height: 100%;
    }
    
    /* Main content com padding para header */
    .main-content {
        padding-top: 60px;
    }
    
    /* Layout principal */
    .dashboard-with-sidebar {
        display: flex;
        flex-direction: column;
        width: 100%;
    }
    
    /* ===== SIDEBAR - ABERTO POR PADRÃO ===== */
    .modern-sidebar {
        position: relative;
        width: 100%;
        height: auto;
        background: #000000;
        border-bottom: 1px solid #1a1a1a;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        transition: max-height 0.3s ease;
        max-height: 2000px !important;
        overflow: visible !important;
    }
    
    /* Sidebar MINIMIZADO */
    .modern-sidebar.minimized {
        max-height: 60px !important;
        overflow: hidden !important;
    }
    
    /* Botão de minimizar */
    .sidebar-toggle-mobile {
        display: flex !important;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 16px;
        background: transparent;
        border: none;
        color: #fff;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        min-height: 60px;
    }
    
    .sidebar-toggle-mobile .toggle-text {
        display: flex;
        align-items: center;
        gap: 10px;
    }
    
    .sidebar-toggle-mobile i {
        font-size: 18px;
        transition: transform 0.3s ease;
    }
    
    .modern-sidebar.minimized .sidebar-toggle-mobile i.fa-chevron-up {
        transform: rotate(180deg);
    }
    
    /* Conteúdo do sidebar */
    .sidebar-content-wrapper {
        padding: 0 12px 12px 12px;
        transition: opacity 0.2s ease;
        opacity: 1;
    }
    
    .modern-sidebar.minimized .sidebar-content-wrapper {
        display: none !important;
        opacity: 0;
        height: 0;
    }
    
    /* User card */
    .modern-sidebar .sidebar-user-card {
        display: flex !important;
        margin: 12px 0;
        padding: 12px;
        background: rgba(255,255,255,0.05);
        border-radius: 8px;
    }
    
    /* Brand */
    .modern-sidebar .sidebar-brand {
        display: none !important;
    }
    
    /* Section label */
    .modern-sidebar .section-label {
        font-size: 11px;
        margin: 12px 0 8px 0;
        opacity: 0.6;
    }
    
    /* Navegação */
    .modern-sidebar .sidebar-nav {
        display: flex;
        flex-direction: column;
        gap: 6px;
    }
    
    .modern-sidebar .nav-item {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 12px;
        padding: 14px;
        border-radius: 8px;
        background: rgba(255,255,255,0.03);
        cursor: pointer;
        transition: all 0.2s ease;
    }
    
    .modern-sidebar .nav-item:active {
        transform: scale(0.98);
    }
    
    .modern-sidebar .nav-item.active {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    }
    
    .modern-sidebar .nav-item-icon {
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 16px;
        background: rgba(255,255,255,0.1);
        border-radius: 8px;
    }
    
    .modern-sidebar .nav-item-content {
        flex: 1;
    }
    
    .modern-sidebar .nav-item-title {
        font-size: 14px;
        font-weight: 600;
        margin-bottom: 2px;
    }
    
    .modern-sidebar .nav-item-subtitle {
        font-size: 11px;
        opacity: 0.7;
    }
    
    .modern-sidebar .nav-arrow {
        display: none;
    }
    
    /* Footer */
    .modern-sidebar .sidebar-footer {
        display: flex !important;
        padding: 12px 0;
        border-top: 1px solid rgba(255,255,255,0.1);
        margin-top: 12px;
    }
    
    .modern-sidebar .footer-stats {
        display: none !important;
    }
    
    .modern-sidebar .btn-logout-sidebar {
        width: 100%;
        padding: 12px;
        font-size: 13px;
    }
    
    /* ===== ÁREA DE CONTEÚDO ===== */
    .dashboard-main-content {
        width: 100%;
        padding: 16px;
        padding-top: 8px;
    }
    
    /* Dashboard header */
    .dashboard-header {
        padding: 12px 0;
        margin: 0 0 16px 0;
    }
    
    .dashboard-header h1 {
        font-size: 20px !important;
        margin: 0 0 6px 0;
    }
    
    .dashboard-header p {
        font-size: 13px;
        margin: 0;
    }
    
    /* Analytics cards */
    .analytics-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        margin-bottom: 16px;
    }
    
    .analytics-card {
        padding: 16px;
    }
    
    .analytics-value {
        font-size: 22px;
    }
    
    /* Tabelas */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    table {
        min-width: 600px;
        font-size: 12px;
    }
    
    /* Tabs */
    .tabs-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 16px;
    }
    
    .tabs {
        display: flex;
        gap: 8px;
        min-width: min-content;
    }
    
    .tab-btn {
        white-space: nowrap;
        padding: 10px 16px;
        font-size: 13px;
    }
    
    /* Filtros */
    .filters-section {
        padding: 16px;
    }
    
    .filters-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .filter-input,
    .filter-select {
        font-size: 16px !important; /* Evita zoom no iOS */
        padding: 10px;
    }
    
    /* Buttons */
    .btn {
        min-height: 44px;
        font-size: 14px;
    }
    
    /* Modals */
    .modal-content {
        width: 90%;
        max-width: 400px;
        max-height: 80vh;
        border-radius: 12px;
        margin: 0;
    }
    
    /* Footer */
    .footer {
        padding: 20px 16px;
    }
    
    /* Esconde botão hamburguer do header */
    .mobile-menu-toggle {
        display: none !important;
    }
    
    /* Esconde overlay */
    .sidebar-overlay {
        display: none !important;
    }
    
    /* Margem para formulário de login (quando NÃO tem sidebar) */
    body:not(:has(.modern-sidebar)) .main-content {
        padding-top: 150px !important;
    }
    
    /* ===== EVENT SELECTION CARDS - MOBILE ===== */
    .event-selection-container {
        padding: 16px;
    }
    
    .event-selection-card {
        padding: 20px 16px;
    }
    
    .events-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }
    
    .event-card {
        max-width: 100%;
    }
    
    .event-image,
    .event-image-placeholder {
        height: 200px !important;
    }
    
    .event-details {
        padding: 16px !important;
    }
    
    .event-card h3 {
        font-size: 18px !important;
    }
    
    .event-card p {
        font-size: 13px !important;
    }
    
    .btn-select-event {
        width: 100%;
        padding: 14px 20px !important;
        font-size: 16px !important;
    }
}

/* ===== SMALL MOBILE ===== */
@media (max-width: 480px) {
    .dashboard-header h1 {
        font-size: 18px !important;
    }
    
    .analytics-value {
        font-size: 20px;
    }
    
    .nav-item-title {
        font-size: 13px !important;
    }
    
    /* Event cards em telas muito pequenas */
    .event-image,
    .event-image-placeholder {
        height: 160px !important;
    }
    
    .event-card h3 {
        font-size: 16px !important;
    }
}
