/* 1. Estilos Generales y Base */
body { 
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; 
    background-color: #f4f7f6; 
    margin: 0; 
    color: #333;
}

header { 
    background: #003366; 
    color: white; 
    padding: 30px 20px; 
    text-align: center; 
    border-bottom: 5px solid #ffcc00; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.container { 
    width: 90%; 
    max-width: 500px; 
    margin: 30px auto; 
    background: white; 
    padding: 30px; 
    border-radius: 10px; 
    box-shadow: 0px 4px 15px rgba(0,0,0,0.1); 
}

/* Para contenedores más anchos como el de Mensajes o Admin */
.container-wide {
    max-width: 1100px;
}

/* 2. Formularios e Inputs */
label { 
    display: block; 
    margin-top: 15px; 
    font-weight: bold;
    color: #003366; 
}

input, textarea, select { 
    width: 100%; 
    padding: 12px; 
    margin-top: 5px; 
    border: 1px solid #ccc; 
    border-radius: 5px; 
    box-sizing: border-box; 
    font-size: 15px;
}

input:focus, select:focus {
    outline: none;
    border-color: #003366;
    box-shadow: 0 0 5px rgba(0,51,102,0.2);
}

/* 3. Botones */
button { 
    width: 100%; 
    background: #003366; 
    color: white; 
    border: none; 
    padding: 15px; 
    margin-top: 20px; 
    border-radius: 5px; 
    cursor: pointer; 
    font-size: 16px; 
    font-weight: bold;
    transition: background 0.3s ease;
}

button:hover { 
    background: #002244; 
}

/* 4. Tablas (Admin y Mensajes) */
table { 
    width: 100%; 
    border-collapse: collapse; 
    margin-top: 20px; 
    background: white;
}

th, td { 
    padding: 12px; 
    border: 1px solid #ddd; 
    text-align: left; 
}

th { 
    background-color: #003366; 
    color: white; 
    text-transform: uppercase;
    font-size: 13px;
}

tr:nth-child(even) { background-color: #f9f9f9; }
tr:hover { background-color: #f1f1f1; }

/* 5. Botones Sociales (Instagram y Ubicación) */
.botones-sociales {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.btn-social {
    flex: 1;
    padding: 10px;
    text-decoration: none;
    color: white;
    border-radius: 5px;
    text-align: center;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 14px;
}

.instagram { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.ubicacion { background-color: #4285F4; }

.btn-social:hover { opacity: 0.9; transform: scale(1.02); }

/* 6. Utilidades y Alertas */
.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #f5c6cb;
    margin-bottom: 15px;
    text-align: center;
}

.btn-verde {
    background-color: #28a745;
    color: white;
    text-decoration: none;
    padding: 10px 15px;
    border-radius: 5px;
    display: inline-block;
}

.btn-verde:hover { background-color: #218838; }

/* 7. Buscador de Mensajes */
.herramientas {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    background: #fff;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

/* Responsivo para celulares */
@media (max-width: 600px) {
    .container { width: 95%; padding: 15px; }
    .botones-sociales { flex-direction: column; }
    .herramientas { flex-direction: column; align-items: stretch; }
}