body {
  font-family: "Segoe UI", sans-serif;
  background: #c0943399 !important; /* Fondo médico claro */
  margin: 0;
  padding: 0;
  color: #333;
}



/* 🔵 ESTILOS DEL HEADER */
header {
    width: 100%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* 🔵 LOGO */
.logo {
    margin-left: 5%; /* ← solicitado */
    display: flex;
    align-items: center;
   
}

.logo-icon img {
    width: 60px;
    height: 60px;
}

/* 🔵 MENÚ PRINCIPAL */
nav ul {
    display: flex;
    gap: 25px;
    list-style: none;
    margin: 0;
    padding: 0;
    font-weight: bold;
    color: #000000;
}

nav ul a {
    display: flex;
    gap: 25px;
    list-style: none;
    margin: 0;
    padding: 0;
    font-weight: bold;
    text-decoration: none;
    color: #000000;
}

nav ul a:hover {
    display: flex;
    gap: 25px;
    list-style: none;
    margin: 0;
    padding: 0;
    font-weight: bold;
    color: #c09433;
}

/* 🔵 BOTÓN HAMBURGUESA (OCULTO EN PC) */
#menuToggle {
    display: none;
    font-size: 26px;
    cursor: pointer;
}

/* 🔵 RESPONSIVE */
/* 🔶 TABLET (768px - 1024px) */
@media (max-width: 1024px) {
    .logo {
        margin-left: 10%; /* ← TABLET */
    }
}

/* 🔴 MÓVIL (menos de 768px) */
@media (max-width: 768px) {

    .logo {
        margin-left: 15%; /* ← MÓVIL */
    }

    /* Mostrar hamburguesa */
    #menuToggle {
        display: block;
    }


    /* Ocultar menú por defecto en móvil */
    nav {
        position: absolute;
        top: 60px;
        right: 0;
        width: 180px;
        background: #fff;
        box-shadow: 0 2px 10px rgba(0,0,0,0.2);
        display: none;
        border-radius: 8px;
    }

    nav ul {
        flex-direction: column;
        padding: 10px;
        gap: 10px;
    }

    nav.open {
        display: block; /* se muestra cuando se abre */
    }
}

/* CONTENIDO */
.container {
  max-width: 1100px;
  margin: 30px auto;
  padding: 20px;
  background: white;
  border-radius: 16px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.card {
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  margin-bottom: 20px;
  padding: 20px;
}

h1 {
  font-size: 24px;
  color: #c09433;
  margin-bottom: 10px;
  text-align: center;
}

.subtitle {
  color: #666;
  font-size: 14px;
  margin-bottom: 20px;
}

h2 {
  font-size: 18px;
  color: #008061;
  border-bottom: 2px solid #efc859;
  padding-bottom: 5px;
  margin-bottom: 12px;
}

label {
  font-weight: 500;
  display: block;
  margin-bottom: 4px;
}

input, textarea, select {
  width: 100%;
  padding: 8px;
  border-radius: 8px;
  border: 1px solid #ccc;
  margin-bottom: 10px;
  font-family: inherit;
  font-size: 14px;
  transition: border-color 0.3s;
}

input:focus, textarea:focus, select:focus {
  border-color: #00a676;
  outline: none;
}

/* GRID */
.grid {
  display: grid;
  gap: 12px;
}
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.section-title {
  font-weight: 600;
  color: #333;
  margin-bottom: 8px;
}

/* CAJAS DE ORDEN */
.order-box {
  border: 1px solid #cde9df;
  border-radius: 10px;
  padding: 15px;
  background: #f8fcfa;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* BOTONES */
button, .btn, .btn-outline {
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  cursor: pointer;
  font-weight: 500;
  transition: background 0.3s, color 0.3s, border 0.3s;
}

button, .btn {
  background: #c09433; /* Verde médico */
  color: white;
}

button:hover, .btn:hover {
  background: #000000;
}

.btn-outline {
  background: white;
  color: #008061;
  border: 2px solid #008061;
}

.btn-outline:hover {
  background: #008061;
  color: white;
}

/* FOOTER */
footer {
  background: #c09433;
  color: #e6f7f0;
  text-align: center;
  padding: 15px;
  font-size: 14px;
  margin-top: 40px;
}

/* POPUP */
.popup {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.6);
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s;
  z-index: 999;
}

.popup-content {
  background: white;
  padding: 25px;
  border-radius: 15px;
  text-align: center;
  max-width: 500px;
  width: 90%;
  position: relative;
  animation: zoomIn 0.4s;
}

.popup h2, .popup h3 {
  margin-bottom: 15px;
  color: #008061;
}

.organs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.organ {
  background-color: #e2f8eb;
  border: 2px solid #00a676;
  border-radius: 10px;
  padding: 15px;
  cursor: pointer;
  transition: transform 0.3s, background 0.3s;
  font-size: 15px;
}

.organ:hover {
  background-color: #00a676;
  color: white;
  transform: scale(1.05);
}

.close-btn {
  position: absolute;
  top: 10px; right: 15px;
  cursor: pointer;
  color: #888;
  font-size: 18px;
}

.close-btn:hover {
  color: red;
}

/* ANIMACIONES */
@keyframes fadeIn {
  from {opacity: 0;}
  to {opacity: 1;}
}

@keyframes zoomIn {
  from {transform: scale(0.8);}
  to {transform: scale(1);}
}



.tabla-afiliados {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.tabla-afiliados th {
  background: #151d34;
  color: #fff;
  padding: 10px;
  text-align: left;
}

.tabla-afiliados td {
  padding: 10px;
  border-bottom: 1px solid #e3e3e3;
  position: relative;
}

/* Ocultar botones por defecto */
.acciones {
  opacity: 0;
  transition: 0.3s;
}

/* Mostrar botones al pasar el mouse */
.tabla-afiliados tr:hover .acciones {
  opacity: 1;
}

/* Estilos de botones */
.btn-editar,
.btn-eliminar {
  display: inline-block;
  padding: 6px 12px;
  font-size: 13px;
  border-radius: 6px;
  text-decoration: none;
  margin-right: 6px;
}

.btn-editar {
  background: #00aaff;
  color: #fff;
}

.btn-eliminar {
  background: #e63946;
  color: #fff;
}

.tabla-afiliados tr:hover {
  background: #f8faff;
}


  /* Campo búsqueda */
  .buscador-box {
    margin-bottom: 40px;
    text-align: right;
  }
  .buscador-box input {
    width: 300px;
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 15px;
  }

 /* === Acciones al estilo WordPress activadas por hover en la fila === */
  .acciones-hover {
    display: none;
    font-size: 13px;
    margin-top: 4px;
  }
  .acciones-hover a {
    text-decoration: none;
    font-weight: bold;
  }
  .acciones-hover .editar {
    color: #0073aa;
  }
  .acciones-hover .editar:hover {
    color: #135e96;
  }
  .acciones-hover .eliminar {
    color: #c50000;
  }
  .acciones-hover .eliminar:hover {
    color: #ff0000;
  }

  /* cuando el cursor entra a la fila, mostrar acciones */
  tr:hover .acciones-hover {
    display: block;
  }


/* menu side */


    /* MENÚ LATERAL */
    #sidebar {
        height: 100%;
        width: 250px;
        position: fixed;
        top: 0;
        left: -250px;
        background: #1d1d1d;
        padding-top: 60px;
        transition: 0.3s;
        overflow-y: auto;
    }

    #sidebar a {
        padding: 12px 20px;
        text-decoration: none;
        font-size: 16px;
        color: #e0e0e0;
        display: block;
        border-bottom: 1px solid #333;
        transition: background .3s;
    }

    #sidebar a:hover {
        background: #333;
    }

    /* BOTÓN DEL MENÚ */
    #menuBtn {
font-size: 30px;
        padding: 10px 20px;
        cursor: pointer;
        background: #c09433;
        color: #fff;
        border: none;
        position: fixed;
        top: 10px;
        left: 10px;
        border-radius: 5px;
        z-index: 999;
    }


   
    /* Contenedor del menú */
    #sidebar {
        position: fixed;
        left: -260px;
        top: 0;
        width: 250px;
        height: 100%;
        background: #000000;
        color: white;
        padding-top: 20px;
        transition: 0.3s;
        z-index: 1000;
    }

    #sidebar.open {
        left: 0;
    }

    /* Botón X */
    #closeMenuBtn {
        font-size: 28px;
        color: white;
        cursor: pointer;
        margin-left: 200px;
        margin-bottom: 10px;
        display: block;
        font-weight: bold;
    }

    #sidebar a {
        display: block;
        padding: 15px 20px;
        color: white;
        text-decoration: none;
        font-size: 16px;
    }

    #sidebar a:hover {
        background: #efc859;
        color: #000000;
    }

    /* Contenido principal */
    #content {
        margin-left: 20px;
        padding: 30px;
    }



.nav-pills>li.active>a, .nav-pills>li.active>a:hover, .nav-pills>li.active>a:focus {
    color: #ffffff;
    background-color: #cccccc;
}
.form-control[disabled], .form-control[readonly], fieldset[disabled] .form-control {
    cursor: not-allowed;
    background-color: #cccccc !important;
    color: #FB0004 !important;
    font-size: 18px !important;
}
    
.nav-pills>li.active>a, .nav-pills>li.active>a:hover, .nav-pills>li.active>a:focus {
    color: #ffffff;
    background-color: #F1F1F1 !important;
    }


.custom-header {
    background: #ffffff;
    padding: 18px 22px;
    border-radius: 10px;
    border: 1px solid #e0e0e0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
}

.custom-header h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 10px;
}

.custom-header i {
    font-size: 22px;
    color: #007bff;
}

/* Botn BUSQUEDA modernizado */
.btn-busqueda a {
    background: #ff4d4f;
    padding: 6px 14px;
    color: #fff !important;
    border-radius: 6px;
    font-weight: bold;
    margin-left: 15px;
    text-decoration: none;
    transition: 0.3s;
    border: 1px solid #d9363e;
}

.btn-busqueda a:hover {
    background: #d9363e;
    transform: translateY(-1px);
}
#resultadoAfiliados {
  margin-top: 15px;
}

.resultado-item {
  padding: 10px;
  border-bottom: 1px solid #e0e0e0;
  cursor: pointer;
}

.resultado-item:hover {
  background-color: #f5f7fa;
}

.resultado-item b {
  color: #223e8c;
}
   