* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
:root {
  /* Colores base: de celestes claros a azules oscuros */
  --c1: #E6F6FF;  /* celeste muuuy claro (podés aclararlo más si querés) */
  --c2: #1D9DD9;  /* celeste de tu paleta */
  --c3: #006AA0;  /* azul medio de tu paleta */
  --c4: #020A19;  /* azul oscuro de tu paleta */
  --angle: 175deg; /* dirección del gradiente */
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(
    var(--angle),
    var(--c1) 0%,
    var(--c2) 18%,
    var(--c3) 35%,
    var(--c4) 100%
  );
  min-height: 100vh;
  padding: 20px;
}




.container {
  max-width: 600px;
  margin: 0 auto;
  background: white;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}



.header {
    background: linear-gradient(135deg, #1a2838 0%, #0f1419 100%);
    padding: 40px 20px;
    text-align: center;
    color: white;
}

.header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.header p {
    font-size: 1.1em;
    opacity: 0.9;
}

.form-content {
    padding: 40px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
    font-size: 0.95em;
}

.form-group input {
    width: 100%;
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1em;
    transition: all 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #ff9500;
    box-shadow: 0 0 0 3px rgba(255, 149, 0, 0.1);
}

.btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #ff9500 0%, #e68600 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 149, 0, 0.4);
}

.btn:active {
    transform: translateY(0);
}

.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.alert {
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: none;
}

.alert.show {
    display: block;
    animation: slideDown 0.3s ease;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Estilos para Admin */
.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.admin-header {
    background: linear-gradient(135deg, #1a2838 0%, #0f1419 100%);
    padding: 30px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.admin-header h1 {
    font-size: 2em;
}

.btn-download {
    padding: 12px 25px;
    background: linear-gradient(135deg, #ff9500, #e68600);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
}

.btn-download:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.admin-content {
    padding: 30px;
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: linear-gradient(135deg, #ff9500 0%, #e68600 50%, #c5705e 100%);
    color: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
}

.stat-card h3 {
    font-size: 2.5em;
    margin-bottom: 5px;
}

.stat-card p {
    opacity: 0.9;
}

.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

table thead {
    background: #f8f9fa;
}

table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #dee2e6;
}

table td {
    padding: 15px;
    border-bottom: 1px solid #dee2e6;
}

table tbody tr:hover {
    background: #f8f9fa;
}

.no-records {
    text-align: center;
    padding: 40px;
    color: #666;
    font-size: 1.1em;
}

/* ========================================
   RESPONSIVE PARA TABLETS
   ======================================== */
@media (max-width: 768px) {
    body {
        padding: 15px;
    }
    
    .container, 
    .admin-container {
        margin: 0;
        border-radius: 15px;
    }
    
    .header {
        padding: 30px 20px;
    }
    
    .header h1 {
        font-size: 2em;
    }
    
    .header p {
        font-size: 1em;
    }
    
    .form-content, 
    .admin-content {
        padding: 30px 25px;
    }
    
    .admin-header {
        padding: 25px 20px;
        flex-direction: column;
        text-align: center;
    }
    
    .admin-header h1 {
        font-size: 1.6em;
    }
    
    .admin-header > div {
        width: 100%;
    }
    
    .admin-header > div:last-child {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-download {
        width: 100%;
        text-align: center;
    }
    
    .stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    table {
        font-size: 0.9em;
    }
    
    table th, 
    table td {
        padding: 12px 10px;
    }
}

/* ========================================
   RESPONSIVE PARA MÓVILES
   ======================================== */
@media (max-width: 480px) {
    body {
        padding: 10px;
    }
    
    .container,
    .admin-container {
        border-radius: 12px;
    }
    
    .header {
        padding: 25px 15px;
    }
    
    .header h1 {
        font-size: 1.5em;
        margin-bottom: 8px;
    }
    
    .header p {
        font-size: 0.9em;
    }
    
    .form-content {
        padding: 25px 20px;
    }
    
    .form-group {
        margin-bottom: 20px;
    }
    
    .form-group label {
        font-size: 0.9em;
        margin-bottom: 6px;
    }
    
    .form-group input {
        padding: 12px;
        font-size: 16px; /* Previene zoom en iOS */
        border-radius: 8px;
    }
    
    .btn {
        padding: 14px;
        font-size: 1em;
        border-radius: 8px;
    }
    
    .alert {
        padding: 12px;
        font-size: 0.9em;
        border-radius: 8px;
    }
    
    /* Admin responsive */
    .admin-content {
        padding: 20px 15px;
    }
    
    .admin-header {
        padding: 20px 15px;
    }
    
    .admin-header h1 {
        font-size: 1.4em;
    }
    
    .admin-header p {
        font-size: 0.85em;
    }
    
    .stat-card {
        padding: 15px;
    }
    
    .stat-card h3 {
        font-size: 2em;
    }
    
    .stat-card p {
        font-size: 0.9em;
    }
    
    .btn-download {
        padding: 10px 20px;
        font-size: 0.9em;
    }
    
    table {
        font-size: 0.8em;
    }
    
    table th,
    table td {
        padding: 10px 8px;
    }
    
    /* Hacer tabla scrolleable en móvil */
    .table-container {
        margin: 0 -20px;
        padding: 0 20px;
    }
}

/* ========================================
   RESPONSIVE PARA MÓVILES PEQUEÑOS
   ======================================== */
@media (max-width: 360px) {
    .header h1 {
        font-size: 1.3em;
    }
    
    .form-content {
        padding: 20px 15px;
    }
    
    .form-group input {
        padding: 10px;
    }
    
    .btn {
        padding: 12px;
        font-size: 0.95em;
    }
    
    table {
        font-size: 0.75em;
    }
    
    table th,
    table td {
        padding: 8px 6px;
    }
}

/* ========================================
   MEJORAS DE ACCESIBILIDAD
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}

/* Mejorar legibilidad en pantallas pequeñas */
@media (max-width: 480px) {
    body {
        font-size: 14px;
    }
}

/* Ajustes para modo landscape en móviles */
@media (max-height: 500px) and (orientation: landscape) {
    .header {
        padding: 20px 15px;
    }
    
    .header h1 {
        font-size: 1.3em;
    }
    
    .form-content {
        padding: 20px;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
}