/**
 * Estilos para a parte pública do plugin (shortcode)
 */

 .leitor-editais-container {
    max-width: 800px;
    margin: 30px auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.leitor-editais-box {
    background: #ffffff;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07), 0 2px 4px rgba(0, 0, 0, 0.05);
}

.leitor-editais-title {
    font-size: 25px;
    font-weight: 700;
    color: #5500c3;
    margin: 0 0 15px 0;
    text-align: center;
}

.leitor-editais-description {
    font-size: 16px;
    color: #666;
    text-align: center;
    margin: 0 0 30px 0;
    line-height: 1.6;
}

/* Alertas */
.leitor-editais-alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin: 20px 0;
    font-size: 14px;
    line-height: 1.6;
}

.leitor-editais-alert-warning {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    color: #856404;
}

.leitor-editais-alert-error {
    background: #f8d7da;
    border-left: 4px solid #dc3545;
    color: #721c24;
}

.leitor-editais-alert a {
    color: inherit;
    text-decoration: underline;
    font-weight: 600;
}

/* Formulário */
.leitor-editais-form {
    margin: 30px 0;
}

.leitor-editais-upload-area {
    position: relative;
    margin-bottom: 25px;
}

.leitor-editais-file-label {
    display: block;
    padding: 10px 30px;
    border: 3px dashed #d0d5dd;
    border-radius: 10px;
    background: #f9fafb;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.leitor-editais-file-label:hover {
    border-color: #2271b1;
    background: #f0f6fc;
}

.leitor-editais-file-label.has-file {
    border-color: #059669;
    background: #ecfdf5;
}

.leitor-editais-icon {
    display: block;
    font-size: 48px;
    margin-bottom: 15px;
}

.leitor-editais-text {
    display: block;
    font-size: 16px;
    color: #666;
    font-weight: 500;
}

.leitor-editais-file-name {
    display: none;
    margin-top: 10px;
    font-size: 14px;
    color: #059669;
    font-weight: 600;
}

.leitor-editais-file-label.has-file .leitor-editais-file-name {
    display: block;
}

#leitor-editais-file {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Botão */
.leitor-editais-btn {
    width: 100%;
    padding: 18px 30px;
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    background: #5500c3!important;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(34, 113, 177, 0.3);
}

.leitor-editais-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(34, 113, 177, 0.4);
}

.leitor-editais-btn:active:not(:disabled) {
    transform: translateY(0);
}

.leitor-editais-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.leitor-editais-btn .btn-loading {
    display: none;
}

.leitor-editais-btn.loading .btn-text {
    display: none;
}

.leitor-editais-btn.loading .btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

/* Spinner */
.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Resultado */
.leitor-editais-result {
    margin-top: 30px;
    padding: 30px;
    background: #f0f6fc;
    border-radius: 10px;
    border-left: 4px solid #2271b1;
    animation: fadeIn 0.5s ease;
}

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

.result-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 20px 0;
}

.result-content {
    font-size: 16px;
    line-height: 1.8;
    color: #333;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Responsivo */
@media (max-width: 768px) {
    .leitor-editais-box {
        padding: 25px 20px;
    }
    
    .leitor-editais-title {
        font-size: 24px;
    }
    
    .leitor-editais-description {
        font-size: 14px;
    }
    
    .leitor-editais-file-label {
        padding: 40px 20px;
    }
    
    .leitor-editais-btn {
        font-size: 16px;
        padding: 16px 25px;
    }
}
/* Loading Overlay */
.leitor-editais-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.leitor-editais-loading-overlay.active {
    opacity: 1;
}

.leitor-editais-loading-box {
    background: #ffffff;
    border-radius: 16px;
    padding: 40px 50px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    text-align: center;
    max-width: 500px;
    width: 90%;
    animation: slideUp 0.4s ease;
}

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

.leitor-editais-big-spinner {
    width: 60px;
    height: 60px;
    border: 5px solid #e0e0e0;
    border-top-color: #2271b1;
    border-radius: 50%;
    margin: 0 auto 25px;
    animation: spin 1s linear infinite;
}

.loading-title {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 15px 0;
}

.loading-status {
    font-size: 16px;
    color: #666;
    margin: 0 0 30px 0;
    min-height: 24px;
}

.loading-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    text-align: left;
}

.loading-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    background: #f5f5f5;
    transition: all 0.3s ease;
    opacity: 0.5;
}

.loading-step.active {
    background: #e3f2fd;
    opacity: 1;
    transform: scale(1.02);
    box-shadow: 0 2px 8px rgba(34, 113, 177, 0.2);
}

.loading-step.completed {
    background: #e8f5e9;
    opacity: 0.8;
}

.loading-step .step-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.loading-step .step-text {
    font-size: 15px;
    font-weight: 500;
    color: #333;
}

.loading-step.active .step-text {
    color: #2271b1;
    font-weight: 600;
}

.loading-step.completed .step-text {
    color: #2e7d32;
}

/* Chat Interativo */
.leitor-editais-chat-container {
    margin-top: 30px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07), 0 2px 4px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    animation: fadeIn 0.5s ease;
}

.chat-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    padding: 25px 30px;
    text-align: center;
}

.chat-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 8px 0;
}

.chat-subtitle {
    font-size: 14px;
    margin: 0;
    opacity: 0.95;
}

.chat-messages {
    max-height: 500px;
    overflow-y: auto;
    padding: 25px;
    background: #f9fafb;
    scroll-behavior: smooth;
}

.chat-welcome-message {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 15px 20px;
    background: #e3f2fd;
    border-radius: 12px;
    margin-bottom: 15px;
    border-left: 4px solid #2196f3;
}

.chat-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.chat-welcome-message p {
    margin: 0;
    color: #1565c0;
    font-size: 15px;
    line-height: 1.6;
}

.chat-message {
    margin-bottom: 15px;
    animation: slideInMessage 0.3s ease;
}

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

.chat-message-user .message-content {
    background: #667eea;
    color: #ffffff;
    padding: 12px 18px;
    border-radius: 18px 18px 4px 18px;
    display: inline-block;
    max-width: 80%;
    float: right;
    clear: both;
    word-wrap: break-word;
    box-shadow: 0 2px 4px rgba(102, 126, 234, 0.3);
}

.chat-message-bot .message-content {
    background: #ffffff;
    color: #333;
    padding: 12px 18px;
    border-radius: 18px 18px 18px 4px;
    display: inline-block;
    max-width: 80%;
    float: left;
    clear: both;
    word-wrap: break-word;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border: 1px solid #e0e0e0;
}

.chat-message-error .message-content {
    background: #fee;
    color: #c62828;
    padding: 12px 18px;
    border-radius: 12px;
    display: inline-block;
    max-width: 80%;
    margin: 0 auto;
    text-align: center;
    border: 1px solid #ef9a9a;
}

.chat-message-typing .message-content {
    background: #f0f0f0;
    color: #666;
    padding: 12px 18px;
    border-radius: 18px 18px 18px 4px;
    display: inline-block;
    max-width: 80%;
    float: left;
    clear: both;
    border: 1px solid #e0e0e0;
}

.typing-dots {
    display: inline-block;
    margin-left: 5px;
}

.typing-dots span {
    animation: typingDot 1.4s infinite;
    opacity: 0;
}

.typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingDot {
    0%, 60%, 100% {
        opacity: 0;
    }
    30% {
        opacity: 1;
    }
}

.message-content {
    font-size: 15px;
    line-height: 1.6;
}

.message-content strong {
    display: block;
    margin-bottom: 5px;
    font-size: 13px;
}

.chat-message::after {
    content: "";
    display: table;
    clear: both;
}

.chat-input-area {
    padding: 20px 25px;
    background: #ffffff;
    border-top: 1px solid #e0e0e0;
}

.chat-form {
    display: grid;
    gap: 12px;
    align-items: center;
}

.chat-input {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 25px;
    font-size: 15px;
    outline: none;
    transition: all 0.3s ease;
    font-family: inherit;
}

.chat-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.chat-input:disabled {
    background: #f5f5f5;
    cursor: not-allowed;
}

.chat-send-btn {
    padding: 14px 28px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
    border: none;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.chat-send-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
}

.chat-send-btn:active:not(:disabled) {
    transform: translateY(0);
}

.chat-send-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.send-icon {
    font-size: 18px;
}

/* Scrollbar personalizada para o chat */
.chat-messages::-webkit-scrollbar {
    width: 8px;
}

.chat-messages::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 10px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Responsivo */
@media (max-width: 768px) {
    .leitor-editais-box {
        padding: 25px 20px;
    }
    
    .leitor-editais-title {
        font-size: 24px;
    }
    
    .leitor-editais-description {
        font-size: 14px;
    }
    
    .leitor-editais-file-label {
        padding: 40px 20px;
    }
    
    .leitor-editais-btn {
        font-size: 16px;
        padding: 16px 25px;
    }
    
    .leitor-editais-loading-box {
        padding: 30px 25px;
        width: 95%;
    }
    
    .loading-title {
        font-size: 20px;
    }
    
    .loading-status {
        font-size: 14px;
    }
    
    .loading-step {
        padding: 10px 12px;
    }
    
    .loading-step .step-icon {
        font-size: 20px;
    }
    
    .loading-step .step-text {
        font-size: 14px;
    }
    
    /* Chat responsivo */
    .chat-header {
        padding: 20px 20px;
    }
    
    .chat-title {
        font-size: 18px;
    }
    
    .chat-subtitle {
        font-size: 13px;
    }
    
    .chat-messages {
        padding: 15px;
        max-height: 400px;
    }
    
    .chat-message-user .message-content,
    .chat-message-bot .message-content {
        max-width: 90%;
        font-size: 14px;
    }
    
    .chat-input-area {
        padding: 15px;
    }
    
    .chat-input {
        padding: 12px 16px;
        font-size: 14px;
    }
    
    .chat-send-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
    
    .send-text {
        display: none;
    }
}


