/* style.css - Versão otimizada com Bootstrap */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #ffffff 0%, #e8f5e9 50%, #c8e6c9 100%);
    min-height: 100vh;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 30px;
    padding: 30px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.header h1 {
    color: #2e7d32;
    font-size: 2.5em;
    margin-bottom: 10px;
}

.header p {
    color: #555;
    font-size: 1.1em;
}

/* Cards personalizados */
.card-custom {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: transform 0.3s;
    border: none;
}

.card-custom:hover {
    transform: translateY(-5px);
}

.card-custom h2 {
    color: #2e7d32;
    margin-bottom: 20px;
    border-left: 4px solid #4caf50;
    padding-left: 15px;
    font-size: 1.5rem;
}

/* Área de busca - verde bem fraco */
.busca-area {
    background: #f1f8e9 !important;
    border: 2px solid #c5e1a5;
}

.busca-area:hover {
    background: #e9f5db !important;
}

/* Input para número da OS */
.input-os {
    font-family: monospace;
    font-size: 18px;
    letter-spacing: 1px;
}

/* Botões personalizados */
.btn-custom-primary {
    background: #4caf50;
    color: white;
    padding: 10px 24px;
    border-radius: 8px;
    border: none;
    transition: all 0.3s;
    font-weight: 600;
}

.btn-custom-primary:hover {
    background: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(76,175,80,0.3);
}

.btn-custom-secondary {
    background: #2196f3;
    color: white;
    padding: 10px 24px;
    border-radius: 8px;
    border: none;
    transition: all 0.3s;
    font-weight: 600;
}

.btn-custom-secondary:hover {
    background: #0b7dda;
    transform: translateY(-2px);
}

/* Status badges */
.status-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
}

.status-Aberto { background: #ff9800; color: white; }
.status-Em-andamento { background: #2196f3; color: white; }
.status-Resolvido { background: #4caf50; color: white; }
.status-Cancelado { background: #f44336; color: white; }

/* Resultado da busca */
.resultado {
    margin-top: 20px;
    padding: 20px;
    background: #f5f5f5;
    border-radius: 10px;
    display: none;
}

.resultado.show {
    display: block;
    animation: fadeIn 0.5s;
}

.resultado-item {
    margin: 15px 0;
    padding: 15px;
    background: white;
    border-radius: 10px;
    border-left: 4px solid #4caf50;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.resultado-item strong {
    color: #2e7d32;
    display: inline-block;
    min-width: 140px;
}

/* Informações de localização */
.info-local {
    font-size: 12px;
    margin-top: 8px;
    padding: 8px;
    background: #e8f5e9;
    border-radius: 5px;
    color: #2e7d32;
}

/* Dicas */
.dicas {
    background: #fff3e0;
    border-left: 4px solid #ff9800;
    padding: 15px;
    margin-top: 20px;
    border-radius: 8px;
    font-size: 14px;
}

.dicas h3 {
    color: #e65100;
    margin-bottom: 10px;
    font-size: 16px;
}

.dicas ul {
    margin-left: 20px;
    color: #555;
}

.dicas li {
    margin: 5px 0;
}

/* Botão admin flutuante */
.btn-admin-flutuante {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #2e7d32;
    color: white;
    padding: 12px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    transition: all 0.3s;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-admin-flutuante:hover {
    background: #1b5e20;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    color: white;
}

/* Loading spinner */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #4caf50;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

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

/* Dashboard stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.stat-card:hover {
    transform: translateY(-3px);
}

.stat-number {
    font-size: 2.5em;
    font-weight: bold;
    color: #2e7d32;
}

.stat-label {
    color: #666;
    margin-top: 10px;
}

/* Tabelas responsivas */
.table-responsive-custom {
    overflow-x: auto;
    border-radius: 10px;
}

.table-custom {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 0;
}

.table-custom thead th {
    background: #4caf50;
    color: white;
    border: none;
    padding: 12px;
}

.table-custom tbody tr:hover {
    background: #f5f5f5;
}

.table-custom td, .table-custom th {
    padding: 12px;
    vertical-align: middle;
}

/* Filtros */
.filtros-area {
    background: #f1f8e9;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
}

/* Modal personalizado */
.modal-custom .modal-content {
    border-radius: 15px;
    border: none;
}

.modal-custom .modal-header {
    background: #4caf50;
    color: white;
    border-radius: 15px 15px 0 0;
}

.modal-custom .modal-header .btn-close {
    filter: brightness(0) invert(1);
}

/* Responsividade */
@media (max-width: 768px) {
    .header h1 {
        font-size: 1.5rem;
    }
    
    .header p {
        font-size: 0.9rem;
    }
    
    .card-custom {
        padding: 15px;
    }
    
    .card-custom h2 {
        font-size: 1.2rem;
    }
    
    .btn-admin-flutuante {
        padding: 8px 16px;
        font-size: 12px;
        bottom: 15px;
        right: 15px;
    }
    
    .stat-number {
        font-size: 1.8em;
    }
    
    .table-custom {
        font-size: 12px;
    }
    
    .table-custom td, .table-custom th {
        padding: 8px;
    }
    
    .resultado-item strong {
        min-width: 100px;
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }
    
    .btn-custom-primary, .btn-custom-secondary {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
}