/* css/style.css */
:root {
    --primary-color: #3498db;
    --secondary-color: #2980b9;
    --danger-color: #e74c3c;
    --success-color: #2ecc71;
    --warning-color: #f39c12;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    background-color: var(--primary-color);
    color: white;
    padding: 20px 0;
    text-align: center;
    border-radius: 8px 8px 0 0;
    margin-bottom: 30px;
    position: relative;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
}

.admin-link, .admin-actions {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
}

.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 30px;
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

input, select, textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border 0.3s;
}

input:focus, select:focus, textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

textarea {
    min-height: 150px;
    resize: vertical;
}

.btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: background-color 0.3s;
    text-decoration: none;
}

.btn:hover {
    background-color: var(--secondary-color);
}

.btn-danger {
    background-color: var(--danger-color);
}

.btn-danger:hover {
    background-color: #c0392b;
}

.btn-success {
    background-color: var(--success-color);
}

.btn-success:hover {
    background-color: #27ae60;
}

.btn-secondary {
    background-color: #6c757d;
}

.btn-secondary:hover {
    background-color: #545b62;
}

.alert {
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.tabs {
    display: flex;
    margin-bottom: 20px;
    border-bottom: 1px solid #ddd;
}

.tab {
    padding: 12px 20px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
}

.tab.active {
    border-bottom-color: var(--primary-color);
    color: var(--primary-color);
    font-weight: bold;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.ticket-details, .ticket-detail-card {
    margin-top: 20px;
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.ticket-id {
    font-weight: bold;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.ticket-status {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
}

.status-pending {
    background-color: #fff3cd;
    color: #856404;
}

.status-in-progress {
    background-color: #cce7ff;
    color: #004085;
}

.status-resolved {
    background-color: #d4edda;
    color: #155724;
}

.ticket-info p {
    margin-bottom: 10px;
}

.priority-high {
    color: var(--danger-color);
    font-weight: bold;
}

.priority-medium {
    color: var(--warning-color);
    font-weight: bold;
}

.priority-low {
    color: var(--success-color);
    font-weight: bold;
}

/* Estilos del panel de administración */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-align: center;
}

.stat-card h3 {
    color: #6c757d;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.stat-number {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
}

.filters {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.filters select, .filters input {
    flex: 1;
    min-width: 150px;
}

.complaints-list {
    display: grid;
    gap: 15px;
}

.complaint-item {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: transform 0.2s;
}

.complaint-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.complaint-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

.complaint-subject {
    font-weight: bold;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.complaint-meta {
    color: #6c757d;
    font-size: 0.9rem;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
}

.close {
    position: absolute;
    right: 15px;
    top: 15px;
    font-size: 24px;
    cursor: pointer;
}

.status-update {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.status-update select {
    width: auto;
    margin: 0 10px;
}

footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    color: #6c757d;
    font-size: 14px;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .card {
        padding: 20px;
    }
    
    .admin-link, .admin-actions {
        position: static;
        transform: none;
        margin-top: 15px;
    }
    
    .ticket-header, .complaint-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .ticket-status {
        margin-top: 5px;
    }
    
    .filters {
        flex-direction: column;
    }
    
    .filters select, .filters input {
        width: 100%;
    }
}


/* Estilos para el Manual de Usuario */
.manual-section {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.manual-section:last-child {
    border-bottom: none;
}

.manual-section h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.manual-section h4 {
    color: var(--secondary-color);
    margin: 15px 0 10px 0;
    font-size: 1.1rem;
}

.step {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    border-left: 4px solid var(--primary-color);
}

.step h4 {
    margin-top: 0;
    color: var(--primary-color);
}

.status-info {
    background: white;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.status-item {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
    margin-right: 15px;
    min-width: 100px;
    text-align: center;
}

.status-badge.pending {
    background-color: #fff3cd;
    color: #856404;
}

.status-badge.in-progress {
    background-color: #cce7ff;
    color: #004085;
}

.status-badge.resolved {
    background-color: #d4edda;
    color: #155724;
}

.tips {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.tip-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.tip-item strong {
    color: var(--primary-color);
    display: block;
    margin-bottom: 10px;
}

.manual-section.warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
}

.manual-section.warning h3 {
    color: #856404;
    margin-top: 0;
}

.manual-contact {
    background: var(--primary-color);
    color: white;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin-top: 30px;
}

.manual-contact h3 {
    color: white;
    margin-top: 0;
}

.manual-contact p {
    margin-bottom: 0;
    opacity: 0.9;
}

.manual-section ul, 
.manual-section ol {
    margin-left: 20px;
    margin-bottom: 15px;
}

.manual-section li {
    margin-bottom: 8px;
    line-height: 1.5;
}

/* Responsive */
@media (max-width: 768px) {
    .tips {
        grid-template-columns: 1fr;
    }
    
    .status-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .status-badge {
        margin-right: 0;
        margin-bottom: 8px;
    }
    
    .tip-item {
        margin-bottom: 15px;
    }
    
    .manual-section {
        padding: 15px;
    }
    
    .step {
        padding: 12px;
    }
}
