body {

}

.tool-card {
    background: white;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    padding: 30px 20px;
    text-align: center;
    height: 100%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.tool-card:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.tool-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
}

.tool-title {
    font-size: 18px;
    font-weight: 700;
    font-family: 'Bitter', serif;
    color: #212529;
    margin-bottom: 15px;
}

.tool-description {
    color: #6c757d;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 25px;
}

.tool-button {
    border-radius: 6px;
    font-weight: 500;
    font-family: 'Roboto', sans-serif;
    padding: 10px 20px;
    border: none;
    color: white;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
}

.tool-button:hover {
    transform: translateY(-1px);
    color: white;
}

/* Cores específicas para cada ferramenta */
.icon-merge { background: linear-gradient(45deg, #4285f4, #6c5ce7); }
.btn-merge { background: #4285f4; }
.btn-merge:hover { background: #3367d6; }

.icon-split { background: linear-gradient(45deg, #00d084, #00b894); }
.btn-split { background: #00d084; }
.btn-split:hover { background: #00b894; }

.icon-rotate { background: linear-gradient(45deg, #fdcb6e, #f39c12); }
.btn-rotate { background: #fdcb6e; color: #333; }
.btn-rotate:hover { background: #f39c12; color: white; }

.icon-bookmark { background: linear-gradient(45deg, #48cae4, #0077be); }
.btn-bookmark { background: #48cae4; }
.btn-bookmark:hover { background: #0077be; }

.icon-insert { background: linear-gradient(45deg, #4285f4, #3367d6); }
.btn-insert { background: #4285f4; }
.btn-insert:hover { background: #3367d6; }

.icon-extract { background: linear-gradient(45deg, #6c757d, #495057); }
.btn-extract { background: #6c757d; }
.btn-extract:hover { background: #495057; }

.icon-ocr { background: linear-gradient(45deg, #17a2b8, #138496); }
.btn-ocr { background: #17a2b8; }
.btn-ocr:hover { background: #138496; }

.icon-summary { background: linear-gradient(45deg, #6f42c1, #563d7c); }
.btn-summary { background: #6f42c1; }
.btn-summary:hover { background: #563d7c; }

.icon-markdown { background: linear-gradient(45deg, #495057, #343a40); }
.btn-markdown { background: #495057; }
.btn-markdown:hover { background: #343a40; }

.icon-mindmap { background: linear-gradient(45deg, #fd7e14, #e8590c); }
.btn-mindmap { background: #fd7e14; }
.btn-mindmap:hover { background: #e8590c; }

.icon-docx { background: linear-gradient(45deg, #2b579a, #1e4074); }
.btn-docx { background: #2b579a; }
.btn-docx:hover { background: #1e4074; }

.icon-xlsx { background: linear-gradient(45deg, #107c41, #0e5c31); }
.btn-xlsx { background: #107c41; }
.btn-xlsx:hover { background: #0e5c31; }

.icon-csv { background: linear-gradient(45deg, #17a2b8, #138496); }
.btn-csv { background: #17a2b8; }
.btn-csv:hover { background: #138496; }

.container-pdf-center {
    max-width: 1200px;
    padding: 40px 15px;
}

/* Responsividade */
@media (max-width: 768px) {
    .container-pdf-center {
        padding: 20px 15px;
    }
    
    .tool-card {
        padding: 25px 15px;
    }
    
    .tool-icon {
        width: 50px;
        height: 50px;
        font-size: 20px;
        margin-bottom: 15px;
    }
    
    .tool-title {
        font-size: 16px;
        margin-bottom: 12px;
    }
    
    .tool-description {
        font-size: 13px;
        margin-bottom: 20px;
    }

    .tool-button {
        padding: 8px 16px;
        font-size: 14px;
    }
}

    /* ==========================================================================
       COMPARAÇÃO DE IMAGENS COM IA - SISTEMAS POLICIAIS
       ========================================================================== */

    /* Container principal */
    .comparison-container {
        max-width: 1200px;
        margin: 0 auto;
        padding: 40px 0;
    }

    /* Título principal */
    .main-title {
        display: flex;
        align-items: center;
        font-size: 28px;
        font-weight: 700;
        font-family: 'Bitter', serif;
        color: #212529;
        margin-bottom: 40px;
        gap: 15px;
    }

    .main-title i {
        color: #ff4757;
        font-size: 32px;
    }

    /* Títulos de seção */
    .section-title {
        display: flex;
        align-items: center;
        font-size: 18px;
        font-weight: 600;
        color: #495057;
        margin-bottom: 25px;
        gap: 10px;
    }

    .section-title i {
        color: #ff4757;
    }

    /* Cards de upload */
    .upload-card {
        background: white;
        border-radius: 12px;
        border: 2px dashed #e9ecef;
        padding: 40px 20px;
        text-align: center;
        height: 300px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: all 0.3s ease;
        cursor: pointer;
        position: relative;
        overflow: hidden;
        box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    }

    .upload-card:hover {
        border-color: #ff4757;
        background-color: #fff5f5;
        box-shadow: 0 8px 25px rgba(0,0,0,0.1);
        transform: translateY(-2px);
    }

    .upload-card.dragover {
        border-color: #ff4757;
        background-color: #fff5f5;
        transform: scale(1.02);
        box-shadow: 0 8px 25px rgba(255, 71, 87, 0.2);
    }

    .upload-card.has-file {
        border: 2px solid #28a745;
        background-color: #f8fff9;
    }

    .upload-card.has-file:hover {
        border-color: #28a745;
        background-color: #f8fff9;
    }

    /* Botão de upload */
    .upload-btn {
        background: #ff4757;
        color: white;
        border: none;
        border-radius: 8px;
        padding: 12px 24px;
        font-weight: 500;
        font-size: 16px;
        font-family: 'Roboto', sans-serif;
        transition: all 0.3s ease;
        cursor: pointer;
    }

    .upload-btn:hover {
        background: #ff3742;
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(255, 71, 87, 0.3);
    }

    /* Input de arquivo oculto */
    .file-input {
        display: none;
    }

    /* Texto do upload */
    .upload-text {
        color: #6c757d;
        margin-top: 15px;
        font-size: 14px;
        font-family: 'Roboto', sans-serif;
    }

    /* Informações do arquivo */
    .file-info {
        display: none;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .file-info.show {
        display: flex;
    }

    /* Preview da imagem */
    .file-preview {
        max-width: 200px;
        max-height: 150px;
        border-radius: 8px;
        box-shadow: 0 4px 8px rgba(0,0,0,0.1);
        object-fit: cover;
    }

    /* Nome do arquivo */
    .file-name {
        font-weight: 500;
        color: #28a745;
        font-size: 14px;
        font-family: 'Roboto', sans-serif;
        text-align: center;
        word-break: break-word;
        max-width: 200px;
    }

    /* Botão remover arquivo */
    .remove-file {
        background: #dc3545;
        color: white;
        border: none;
        border-radius: 50%;
        width: 30px;
        height: 30px;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .remove-file:hover {
        background: #c82333;
        transform: scale(1.1);
    }

    .remove-file i {
        font-size: 12px;
    }

    /* Informações de formato */
    .format-info {
        text-align: center;
        color: #6c757d;
        font-size: 12px;
        font-family: 'Roboto', sans-serif;
        margin-top: 15px;
        line-height: 1.4;
    }

    /* Seção de comparação */
    .compare-section {
        margin-top: 40px;
        text-align: center;
    }

    /* Botão de comparar */
    .compare-btn {
        background: #28a745;
        color: white;
        border: none;
        border-radius: 8px;
        padding: 15px 30px;
        font-weight: 600;
        font-size: 18px;
        font-family: 'Roboto', sans-serif;
        display: inline-flex;
        align-items: center;
        gap: 10px;
        transition: all 0.3s ease;
        cursor: pointer;
        margin-right: 20px;
    }

    .compare-btn:hover:not(:disabled) {
        background: #218838;
        transform: translateY(-2px);
        box-shadow: 0 8px 25px rgba(40, 167, 69, 0.3);
    }

    .compare-btn:disabled {
        background: #6c757d;
        cursor: not-allowed;
        transform: none;
        box-shadow: none;
        opacity: 0.6;
    }

    .compare-btn i {
        font-size: 16px;
    }

    /* Link voltar */
    .back-link {
        color: #6c757d;
        text-decoration: none;
        font-weight: 500;
        font-family: 'Roboto', sans-serif;
        transition: color 0.3s ease;
    }

    .back-link:hover {
        color: #495057;
        text-decoration: none;
    }

    /* Spinner de loading */
    .loading-spinner {
        display: none;
        width: 20px;
        height: 20px;
        border: 2px solid transparent;
        border-top: 2px solid currentColor;
        border-radius: 50%;
        animation: spin 1s linear infinite;
    }

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

    /* Barra de progresso */
    .progress-bar {
        width: 100%;
        height: 4px;
        background: #e9ecef;
        border-radius: 2px;
        overflow: hidden;
        margin-top: 10px;
        display: none;
    }

    .progress-fill {
        height: 100%;
        background: #28a745;
        width: 0%;
        transition: width 0.3s ease;
        border-radius: 2px;
    }

    /* Seção de resultados */
    .result-section {
        margin-top: 40px;
        padding: 30px;
        background: white;
        border-radius: 12px;
        box-shadow: 0 4px 8px rgba(0,0,0,0.1);
        border: 1px solid #e9ecef;
        display: none;
    }

    .result-section.show {
        display: block;
        animation: fadeInUp 0.5s ease;
    }

    @keyframes fadeInUp {
        from {
            opacity: 0;
            transform: translateY(20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* Título do resultado */
    .result-title {
        font-size: 24px;
        font-weight: 700;
        font-family: 'Bitter', serif;
        color: #212529;
        margin-bottom: 20px;
        text-align: center;
    }

    /* Conteúdo do resultado */
    .result-content {
        font-size: 16px;
        line-height: 1.6;
        color: #495057;
        font-family: 'Roboto', sans-serif;
    }

    /* Score de similaridade */
    .similarity-score {
        text-align: center;
        margin: 20px 0;
    }

    .score-circle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 100px;
        height: 100px;
        border-radius: 50%;
        font-size: 24px;
        font-weight: 700;
        font-family: 'Bitter', serif;
        color: white;
        margin: 0 auto;
        box-shadow: 0 4px 12px rgba(0,0,0,0.15);
        transition: transform 0.3s ease;
    }

    .score-circle:hover {
        transform: scale(1.05);
    }

    .score-high {
        background: linear-gradient(45deg, #28a745, #20c997);
    }

    .score-medium {
        background: linear-gradient(45deg, #ffc107, #fd7e14);
        color: #333;
    }

    .score-low {
        background: linear-gradient(45deg, #dc3545, #e74c3c);
    }

    .similarity-score p {
        margin-top: 15px;
        font-weight: 500;
        font-family: 'Roboto', sans-serif;
        color: #495057;
    }

    /* Mensagens de erro */
    .error-message {
        background: #f8d7da;
        color: #721c24;
        border: 1px solid #f5c6cb;
        border-radius: 8px;
        padding: 15px;
        margin: 20px 0;
        font-family: 'Roboto', sans-serif;
        text-align: center;
    }

    .success-message {
        background: #d4edda;
        color: #155724;
        border: 1px solid #c3e6cb;
        border-radius: 8px;
        padding: 15px;
        margin: 20px 0;
        font-family: 'Roboto', sans-serif;
        text-align: center;
    }

    /* ==========================================================================
       RESPONSIVIDADE
       ========================================================================== */

    /* Tablets */
    @media (max-width: 768px) {
        .comparison-container {
            padding: 20px 0;
        }

        .main-title {
            font-size: 22px;
            margin-bottom: 30px;
        }

        .upload-card {
            height: 250px;
            padding: 30px 15px;
        }

        .upload-btn {
            padding: 10px 20px;
            font-size: 14px;
        }

        .compare-btn {
            padding: 12px 24px;
            font-size: 16px;
            margin-right: 0;
            margin-bottom: 15px;
            width: 100%;
            justify-content: center;
        }

        .file-preview {
            max-width: 150px;
            max-height: 100px;
        }

        .result-section {
            padding: 20px;
        }

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

        .score-circle {
            width: 80px;
            height: 80px;
            font-size: 20px;
        }
    }

    /* Smartphones */
    @media (max-width: 576px) {
        .main-title {
            font-size: 20px;
            flex-direction: column;
            text-align: center;
            gap: 10px;
        }

        .main-title i {
            font-size: 28px;
        }

        .section-title {
            font-size: 16px;
            justify-content: center;
            text-align: center;
        }

        .upload-card {
            height: 200px;
            padding: 20px 10px;
        }

        .upload-btn {
            padding: 8px 16px;
            font-size: 13px;
        }

        .file-preview {
            max-width: 120px;
            max-height: 80px;
        }

        .file-name {
            font-size: 12px;
            max-width: 150px;
        }

        .format-info {
            font-size: 11px;
        }

        .compare-btn {
            padding: 10px 20px;
            font-size: 14px;
        }

        .result-section {
            padding: 15px;
            margin-top: 30px;
        }

        .result-title {
            font-size: 18px;
        }

        .result-content {
            font-size: 14px;
        }

        .score-circle {
            width: 70px;
            height: 70px;
            font-size: 18px;
        }
    }

    /* Smartphones pequenos */
    @media (max-width: 480px) {
        .comparison-container {
            padding: 15px 0;
        }

        .upload-card {
            height: 180px;
            padding: 15px 5px;
        }

        .main-title {
            font-size: 18px;
            margin-bottom: 25px;
        }

        .section-title {
            font-size: 14px;
            margin-bottom: 20px;
        }

        .compare-btn {
            padding: 8px 16px;
            font-size: 13px;
        }
    }

    /* ==========================================================================
       ESTADOS ESPECIAIS E INTERAÇÕES
       ========================================================================== */

    /* Prevenção de seleção de texto durante drag */
    .upload-card.dragover * {
        pointer-events: none;
    }

    /* Foco acessível */
    .upload-btn:focus,
    .compare-btn:focus,
    .remove-file:focus {
        outline: 2px solid #007bff;
        outline-offset: 2px;
    }

    /* Transições suaves para todos os elementos */
    .upload-card *,
    .compare-btn *,
    .result-section * {
        transition: all 0.3s ease;
    }

    /* Estado de carregamento global */
    .loading .upload-card {
        pointer-events: none;
        opacity: 0.7;
    }

    /* Print styles */
    @media print {
        .upload-card,
        .compare-section {
            display: none;
        }

        .result-section {
            box-shadow: none;
            border: 1px solid #000;
        }
    }

    /* Resetar alguns estilos conflitantes do WordPress */
    .comparison-container * {
        box-sizing: border-box;
    }

    .comparison-container .row {
        display: flex;
        flex-wrap: wrap;
        margin-left: -15px;
        margin-right: -15px;
    }

    .comparison-container .col-lg-6,
    .comparison-container .col-md-6,
    .comparison-container .col-sm-12 {
        position: relative;
        width: 100%;
        padding-left: 15px;
        padding-right: 15px;
    }

    @media (min-width: 768px) {
        .comparison-container .col-md-6 {
            flex: 0 0 50%;
            max-width: 50%;
        }
    }

    @media (min-width: 992px) {
        .comparison-container .col-lg-6 {
            flex: 0 0 50%;
            max-width: 50%;
        }
    }

    /* Garantir que o upload-card funcione corretamente */
    .comparison-container .upload-card {
        position: relative;
        cursor: pointer;
        min-height: 300px;
        display: flex !important;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }

    .comparison-container .upload-content {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }

    .comparison-container .file-info {
        display: none;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 15px;
    }

    .comparison-container .file-info.show {
        display: flex !important;
    }

    /* Corrigir botões */
    .comparison-container .upload-btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        white-space: nowrap;
    }

    .comparison-container .compare-btn {
        display: inline-flex;
        align-items: center;
        gap: 10px;
    }

    /* Ocultar spinner por padrão */
    .comparison-container .loading-spinner {
        display: none !important;
    }

    /* Mostrar spinner quando ativo */
    .comparison-container .compare-btn.loading .loading-spinner {
        display: inline-block !important;
    }

    /* Garantir que a seção de resultados fique oculta inicialmente */
    .comparison-container .result-section {
        display: none !important;
    }

    .comparison-container .result-section.show {
        display: block !important;
    }

    /* Corrigir margem dos elementos */
    .comparison-container .mb-4 {
        margin-bottom: 1.5rem;
    }

    /* Garantir que os inputs de arquivo fiquem ocultos */
    .comparison-container .file-input {
        display: none !important;
        position: absolute;
        left: -9999px;
        opacity: 0;
    }

    /* Correção específica para conflitos do WordPress */
    .comparison-container input[type="file"] {
        display: none !important;
    }

    /* Melhorar o visual do preview */
    .comparison-container .file-preview {
        max-width: 180px;
        max-height: 120px;
        object-fit: cover;
        border-radius: 8px;
        box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    }

    /* Corrigir o nome do arquivo */
    .comparison-container .file-name {
        max-width: 200px;
        word-break: break-word;
        text-align: center;
        line-height: 1.3;
    }

    /* Melhorar responsividade em telas pequenas */
    @media (max-width: 576px) {
        .comparison-container .upload-card {
            min-height: 200px;
            padding: 20px 10px;
        }

        .comparison-container .file-preview {
            max-width: 140px;
            max-height: 100px;
        }

        .comparison-container .compare-btn {
            width: 100%;
            justify-content: center;
            margin-bottom: 15px;
        }
    }

    /* Garantir z-index adequado para elementos importantes */
    .comparison-container .remove-file {
        z-index: 10;
        position: relative;
    }

    /* Corrigir alinhamento do título */
    .comparison-container .main-title {
        margin-bottom: 2rem;
        line-height: 1.2;
    }

    /* Espaçamento adequado para seções */
    .comparison-container .compare-section {
        margin-top: 2.5rem;
        margin-bottom: 2rem;
    }

    /* Corrigir mensagens de sistema */
    .comparison-container #systemMessages {
        margin: 20px 0;
    }

    .comparison-container .error-message,
    .comparison-container .success-message {
        padding: 15px;
        border-radius: 8px;
        margin: 15px 0;
        text-align: center;
        font-weight: 500;
    }

    .comparison-container .error-message {
        background-color: #f8d7da;
        color: #721c24;
        border: 1px solid #f5c6cb;
    }

    .comparison-container .success-message {
        background-color: #d4edda;
        color: #155724;
        border: 1px solid #c3e6cb;
    }