/* Hoja de estilos propia (sin librerías externas). */
* { box-sizing: border-box; }
body { margin: 0; font-family: "Segoe UI", Roboto, Arial, sans-serif; background: #f4f6f9; color: #1f2933; line-height: 1.5; }
a { color: #2f6fb0; }

/* Barra superior y menú */
.barra { background: #1f2a44; color: #fff; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 14px 32px; }
.barra .marca { color: #fff; font-weight: 600; text-decoration: none; font-size: 1.1rem; }
.barra nav { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.barra nav a { color: #d6e2f5; text-decoration: none; }
.barra nav a:hover { color: #fff; text-decoration: underline; }
.barra .usuario { color: #9fb3d1; font-size: .9rem; }
.barra .salir { border: 1px solid #5b6b8c; padding: 3px 10px; border-radius: 4px; }

.contenido { max-width: 1100px; margin: 32px auto; padding: 0 24px; }
.pie { text-align: center; color: #7b8794; font-size: .85rem; padding: 24px; }

h1 { margin: 0 0 6px; font-size: 1.7rem; color: #1f2a44; }
h2 { margin: 32px 0 12px; font-size: 1.25rem; color: #1f2a44; }
.subtitulo { color: #52606d; margin-top: 0; }
.nota { color: #7b8794; font-size: .88rem; }

/* Contenedores */
.tarjeta { background: #fff; border: 1px solid #e1e5eb; border-radius: 8px; padding: 28px; }
.angosta { max-width: 440px; margin: 0 auto; }
.angosta-izq { max-width: 560px; }
.portada { background: #fff; border: 1px solid #e1e5eb; border-radius: 8px; padding: 48px; text-align: center; }
.acciones { display: flex; gap: 12px; justify-content: center; margin-top: 24px; flex-wrap: wrap; }

/* Formularios */
form label { display: block; font-weight: 600; margin: 14px 0 4px; }
input[type=text], input[type=password], textarea, select { width: 100%; padding: 9px 10px; border: 1px solid #c4cdd5; border-radius: 4px; font: inherit; background: #fff; }
textarea { min-height: 90px; resize: vertical; }
button, .boton { display: inline-block; background: #2f6fb0; color: #fff; border: none; border-radius: 4px; padding: 10px 18px; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; }
button:hover, .boton:hover { background: #255a90; }
.boton.secundario { background: #fff; color: #2f6fb0; border: 1px solid #2f6fb0; }
.boton.chico { padding: 5px 12px; font-size: .9rem; white-space: nowrap; }
form button { margin-top: 20px; }
.filtro { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: #fff; border: 1px solid #e1e5eb; border-radius: 8px; padding: 14px 18px; margin: 16px 0; }
.filtro label { margin: 0; font-weight: normal; }
.filtro input.corto { width: 80px; }
.filtro button { margin-top: 0; }

/* Mensajes */
.error { background: #fdecea; color: #a61b1b; border: 1px solid #f5c2c0; padding: 10px 14px; border-radius: 4px; }
.aviso { background: #fff8e1; border: 1px solid #f0d98c; padding: 10px 14px; border-radius: 4px; }

/* Tablas */
table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid #e1e5eb; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid #edf0f3; vertical-align: top; }
th { background: #eef2f7; color: #3e4c59; font-size: .9rem; }
tbody tr:nth-child(even) { background: #fafbfc; }
td.numero, th.numero { text-align: right; }
.etiqueta { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: .8rem; font-weight: 600; }
.etiqueta.abierto { background: #e3f2e8; color: #1e6b3a; }
.etiqueta.cerrado { background: #eceff3; color: #52606d; }

/* Opciones del inicio */
.opciones { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 20px; }
.opcion { display: block; background: #fff; border: 1px solid #e1e5eb; border-radius: 8px; padding: 20px; text-decoration: none; color: inherit; }
.opcion:hover { border-color: #2f6fb0; }
.opcion strong { display: block; color: #1f2a44; font-size: 1.1rem; margin-bottom: 4px; }
.opcion span { color: #52606d; }

/* Detalle de caso */
.grilla { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; margin-top: 16px; }
.ficha { background: #fff; border: 1px solid #e1e5eb; border-radius: 8px; padding: 18px 22px; margin: 0; display: grid; grid-template-columns: 130px 1fr; gap: 8px 12px; }
.ficha dt { font-weight: 600; color: #52606d; }
.ficha dd { margin: 0; }
.recomendacion { background: #fff; border: 1px solid #e1e5eb; border-left: 6px solid #d69e2e; border-radius: 8px; padding: 18px 22px; margin-top: 24px; }
.recomendacion .peso { font-size: 1.6rem; font-weight: 700; color: #1f2a44; }
.recomendacion.baja { border-left-color: #7b8794; }
.recomendacion.media { border-left-color: #d69e2e; }
.recomendacion.alta { border-left-color: #c53030; }
