/* --------------------------
    ESTILOS GENERALES
--------------------------- */
body {
    margin: 0;
    padding: 0;
    background: #f4f4f4;
    font-family: Arial, sans-serif;
}

/* Contenedor global */
main, #contenido {
    margin-top: 90px;
    padding: 20px;
    max-width: 900px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.2);
    margin-left: auto;
    margin-right: auto;
}

/* Títulos */
h1, h2 {
    text-align: center;
    color: #333;
}

/* --------------------------
    MENÚ SUPERIOR FIJO
--------------------------- */
nav {
    background: #4CAF50;
    color: white;
    padding: 15px;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 35px;
    z-index: 1000;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
}

nav a:hover {
    text-decoration: underline;
}

/* --------------------------
    FORMULARIOS
--------------------------- */

form {
    background: #fff;
    max-width: 600px;
    margin: 20px auto;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.2);
}

label {
    display: block;
    margin-top: 12px;
    font-weight: bold;
    color: #444;
}

input, select {
    width: 100%;
    padding: 8px;
    margin-top: 6px;
    border-radius: 6px;
    border: 1px solid #aaa;
    background: #fafafa;
}

button, input[type="submit"] {
    margin-top: 20px;
    width: 100%;
    padding: 10px;
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
}

button:hover, input[type="submit"]:hover {
    background: #45a049;
}

/* --------------------------
    TABLAS (buscar.php)
--------------------------- */
table {
    width: 95%;
    margin: 25px auto;
    border-collapse: collapse;
    background: white;
    border-radius: 10px;
    overflow: hidden;
}

th {
    background: #4CAF50;
    color: white;
    padding: 12px;
}

td {
    padding: 10px;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

tr:nth-child(even) {
    background: #f9f9f9;
}

/* Imágenes */
img {
    width: 70px;
    border-radius: 6px;
}

/* Enlaces secundarios */
a.regresar, a.volver-menu {
    text-align: center;
    display: block;
    margin-top: 20px;
    text-decoration: none;
    color: #4CAF50;
    font-weight: bold;
}

a.regresar:hover, a.volver-menu:hover {
    text-decoration: underline;
}

/* --------------------------
    IFRAME PARA index.html
--------------------------- */
iframe {
    width: 100%;
    height: 700px;
    border: none;
    border-radius: 10px;
}

/* --------------------------
    MENSAJES
--------------------------- */
.mensaje-exito {
    color: green;
    font-weight: bold;
    text-align: center;
}

.mensaje-error {
    color: red;
    font-weight: bold;
    text-align: center;
}