.midee-mis-casos table {
    width: 100%;
    border-collapse: collapse;
}

.midee-mis-casos th,
.midee-mis-casos td {
    padding: 8px;
    border-bottom: 1px solid #ddd;
}

.midee-mis-casos .estado-asignado {
    background: #fffbe6;
}

.midee-mis-casos .estado-cerrado {
    background: #e6ffe6;
}


.midee-ranking table {
    width: 100%;
    border-collapse: collapse;
}

.midee-ranking th,
.midee-ranking td {
    padding: 8px;
    border-bottom: 1px solid #ddd;
}

.midee-ranking .nivel-3 {
    background: #fff2cc; /* Referente */
    font-weight: bold;
}

.midee-ranking .nivel-2 {
    background: #eef6ff; /* Especialista */
}

.midee-ranking .nivel-1 {
    background: #f9f9f9; /* Colaborador */
}

/* =====================================================
   FORMULARIOS (PROYECTOS / MODELOS / UTILIDADES)
   ===================================================== */

   /* Contenedor general */
.midee-new-project-wrapper {
    width: 100%;
}

/* Bloque visible solo para usuarios habilitados */
.midee-new-project-allowed {
    display: flex;
    flex-direction: column;
    gap: 12px; /* espacio entre botones */
}

/* Cada ítem del menú */
.midee-link-item {
    width: 100%;
}

/* Estilo base de los botones */
.midee-link-item a {
    display: block;
    width: 100%;
    padding: 14px 18px;
    text-align: center;
    background-color: #005181; /* color base */
    color: #ffffff;
    font-weight: 600;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.25s ease;
}

/* Hover / Focus */
.midee-link-item a:hover,
.midee-link-item a:focus {
    background-color: #008e9c;
    color: #ffffff;
    transform: translateY(-2px);
}

/* Opcional: estado activo */
.midee-link-item a:active {
    transform: translateY(0);
}

/* Mensaje para usuarios sin permisos */
.midee-new-project-denied {
    padding: 16px;
    background-color: #ffefe6;
    border-left: 4px solid #d67651;
    color: #333;
    font-size: 14px;
    border-radius:6px;
}

.midee-new-project-denied h4 {
    margin-top: 2em;
}


/* Formulario de acceso */
input[type="text"], input[type="email"], input[type="password"] {
  display:block;
  width:100%;
  padding:10px;
  margin:10px;
  border-radius:5px;
}

input[type="submit"]
{
	background-color:#008e9c;
	border-radius:8px;
  border:none;
	cursor:pointer;
	color:#ffffff;
	font-family:Arial;
	font-size:14px;
	padding:12px;
	text-decoration:none;
  display:block;
  margin: 10px auto;
  }

input[type="submit"]:hover
{
	background-color:#005181;
  border:none;
  }


/* =====================================================
   MIDEE – VARIABLES GLOBALES (TOKENS DE DISEÑO)
   ===================================================== */

:root {
  /* Fondo general */
  --midee-bg: #eef3fb;          /* azul claro */

  /* Bordes */
  --midee-border: #cfd8e3;      /* gris técnico */
  --midee-border-focus: #2563eb;

  /* Texto */
  --midee-text: #1f2937;
  --midee-muted: #6b7280;

  /* Acciones */
  --midee-primary: #2563eb;

  /* Estados */
  --midee-danger: #c62828;
  --midee-success: #2e7d32;
}

 /* Fuerza estilos MIDEE por sobre Divi */
.et_pb_module .midee-form .midee-input,
.et_pb_module .midee-form .midee-textarea,
.et_pb_module .midee-form .midee-select,
.et_pb_module .midee-form .midee-file {
  border: 1px solid var(--midee-border);
  background: #fff;
}



.midee-label {
  display: block;
  margin-bottom: 4px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--midee-text);
}

.midee-input,
.midee-textarea,
.midee-select {
  width: 100%;
  padding: 10px 12px;

  font-size: 0.95rem;
  color: var(--midee-text);
  background: #fff;

  border: 1px solid var(--midee-border);
  border-radius: 6px;

  transition:
    border-color .15s ease,
    box-shadow .15s ease,
    background-color .15s ease;
}

/* Placeholder técnico */
.midee-input::placeholder,
.midee-textarea::placeholder {
  color: var(--midee-muted);
  font-style: italic;
}

.midee-input:focus,
.midee-textarea:focus,
.midee-select:focus {
  outline: none;
  border-color: var(--midee-border-focus);
  box-shadow: 0 0 0 2px rgba(37,99,235,0.15);
  background: #ffffff;
}

.midee-textarea {
  min-height: 120px;
  line-height: 1.5;
  resize: vertical;
}

.midee-file {
  width: 100%;
  padding: 10px;

  font-size: 0.85rem;
  color: var(--midee-text);

  border: 1px dashed var(--midee-border);
  border-radius: 6px;
  background: #fafcff;

  cursor: pointer;
}

.midee-file:hover {
  background: #f0f6ff;
  border-color: var(--midee-border-focus);
}

.midee-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 10px 18px;

  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.3px;

  color: #fff;
  background: linear-gradient(
    135deg,
    #4a4b4e,
    #1d202b
  );

  border: none;
  border-radius: 6px;

  cursor: pointer;
  transition:
    transform .1s ease,
    box-shadow .1s ease,
    opacity .15s ease;
}

.midee-btn:hover {
  box-shadow: 0 6px 14px rgba(30,64,175,0.25);
}

.midee-btn:active {
  transform: translateY(1px);
}

.midee-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.midee-btn-secondary {
  background: #e5eaf2;
  color: var(--midee-text);
}

.midee-btn-secondary:hover {
  background: #dbe3ef;
}

.midee-field {
  margin-bottom: 18px;
}

.midee-form {
  background: #ffffff;
  padding: 24px;
  border-radius: 8px;
  border: 1px solid var(--midee-border);
}

/* =====================================================
   FORMULARIOS – CAMPOS OBLIGATORIOS
   ===================================================== */

.midee-label-obligatorio {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.2px;
    color: #1f2937; /* gris técnico */

    position: relative;
}

/* Indicador obligatorio (asterisco técnico) */
.midee-label-obligatorio::after {
    content: "[REQ]";
    font-size: 0.65rem;
    font-weight: 700;
    color: #c62828;
    letter-spacing: 0.5px;
}


/* Línea técnica sutil debajo del label */
.midee-label-obligatorio::before {
    content: "";
    position: absolute;
    left: 0;
    bottom: -3px;
    width: 100%;
    height: 1px;
    background: linear-gradient(
        to right,
        #c62828 0%,
        transparent 70%
    );
}

.midee-label-obligatorio + .midee-input {
  border-left: 4px solid #c62828;
  padding-left: calc(12px - 4px);
}



/* =====================================================
   NORMALIZACIÓN TOTAL DE INPUTS (ANTI-DIVI)
   ===================================================== */

.midee-form input.midee-input,
.midee-form input[type="number"].midee-input,
.midee-form input[type="text"].midee-input,
.midee-form input[type="email"].midee-input,
.midee-form input[type="url"].midee-input,
.midee-form input[type="password"].midee-input {
  padding: 10px 12px;
  line-height: 1.4;
  box-sizing: border-box;
  margin: 0;
}

.midee-form select.midee-select,
.midee-form textarea.midee-textarea {
  padding: 10px 12px;
  line-height: 1.4;
  box-sizing: border-box;
  margin: 0;
}

.midee-form-intervencion {
  margin-top: 12px;
}

.midee-form-intervencion .midee-input,
.midee-form-intervencion .midee-textarea,
.midee-form-intervencion .midee-file {
  width: 100%;
  margin: 0;
}

.midee-form-intervencion .midee-btn {
  margin-top: 8px;
}

.midee-form-intervencion .midee-reglamento-check {
  margin-bottom: 16px;
}

/* =========================
 * Interacciones – estilo
 * ========================= */

.midee-intervencion {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 12px 14px;
    margin: 12px 0;
    line-height: 1.5;
    font-weight: 400;
}

.midee-intervencion.midee {
    background-color: #eaf4ff;
    border-color: #b7d7f4;
}

.midee-intervencion.solicitante {
    background-color: #ffefe6;
    border-color: #f5c7a9;
}

.midee-intervencion.comunidad {
    background-color: #f5f7fa;
    border-color: #d7dee8;
}

.midee-intervencion-asignada {
    background: linear-gradient(180deg, #fff6cc 0%, #fffdf1 100%);
    border-color: #d9b400;
    box-shadow: 0 0 0 2px rgba(217, 180, 0, 0.12);
}

.midee-intervencion strong {
    display: block;
    margin-bottom: 4px;
    font-weight: 700;
}

.midee-intervencion p {
    font-weight: 400;
}

.midee-intervencion small {
    color: #666;
    font-size: 12px;
}

.midee-archivo-adjunto {
    margin-top: 8px;
}

.midee-archivo-pdf {
    display: inline-block;
    padding: 6px 10px;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
}

.midee-archivo-img img {
    max-width: 160px;
    max-height: 160px;
    border-radius: 6px;
    border: 1px solid #ccc;
    cursor: zoom-in;
    display: block;
}

.midee-intervencion {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 12px;
}

.midee-intervencion.midee {
    background: #eaf4ff;
}

.midee-intervencion.solicitante {
    background: #ffefe6;
}

.midee-intervencion.comunidad {
    background: #f5f7fa;
}

.midee-intervencion-archivo {
    margin-top: 8px;
}

.midee-badge-midee,
.midee-badge-asignado,
.midee-badge-comunidad {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.2px;
    vertical-align: middle;
}

.midee-badge-midee {
    background: #dcecff;
    color: #005181;
}

.midee-badge-asignado {
    background: #fff0a8;
    color: #6d5300;
}

.midee-badge-comunidad {
    background: #e8edf3;
    color: #49586a;
}

/* =========================
   LISTADO CONSULTAS MIDEE
   ========================= */

.midee-listado-consultas {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.midee-consulta-card {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
    border-radius: 10px;
    border: 1px solid;
}

/* Alternancia de fondo */
.midee-bg-midee {
    background-color: #eaf4ff;
    border-color: #b7d7f4;
}

.midee-bg-solicitante {
    background-color: #ffefe6;
    border-color: #f5c7a9;
}

/* Avatar */
.midee-consulta-avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

/* Cuerpo */
.midee-consulta-body {
    flex: 1;
}

.midee-consulta-titulo {
    margin: 0 0 4px 0;
    font-size: 18px;
}

.midee-consulta-autor {
    margin: 0 0 8px 0;
    font-size: 13px;
    color: #666;
}

.midee-consulta-resumen {
    margin: 0 0 12px 0;
}

/* CTA */
.midee-cta {
    display: inline-block;
    font-weight: 600;
    color: #1a73e8;
    text-decoration: none;
}

.midee-cta:hover {
    text-decoration: underline;
}

.midee-consulta-actions {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    margin-top: 10px;
    gap: 16px;
}

.midee-consulta-action {
    display: flex !important;
    align-items: center !important;
}

.midee-consulta-action-left {
    justify-content: flex-start !important;
}

.midee-consulta-action-right {
    margin-left: auto !important;
    justify-content: flex-end !important;
    text-align: right;
}

.midee-consulta-actions .midee-cta {
    display: inline-flex !important;
    align-items: center !important;
}

.midee-cta-secondary {
    color: #005181;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.midee-cta-secondary:hover {
    color: #0b6ea8;
}

@media (max-width: 640px) {
    .midee-consulta-actions {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 8px;
    }

    .midee-consulta-action-right {
        margin-left: 0 !important;
        justify-content: flex-start !important;
        text-align: left;
    }
}

/* =========================
   PANEL MIS CONSULTAS
   ========================= */

.midee-mis-consultas-panel {
    background: #fff;
    border: 1px solid #d8e0ea;
    border-radius: 10px;
    padding: 12px;
}

.midee-mis-consultas-panel h3 {
    margin: 0 0 10px 0;
    font-size: 22px;
    color: #005181;
}

.midee-mis-consultas-panel .midee-table {
    width: 100%;
    border-collapse: collapse;
}

.midee-mis-consultas-panel .midee-table th,
.midee-mis-consultas-panel .midee-table td {
    padding: 10px;
    border-bottom: 1px solid #e3e8ef;
    text-align: left;
    vertical-align: top;
    font-size: 14px;
}

.midee-mis-consultas-panel .midee-table th {
    font-weight: 700;
    color: #123b5a;
    background: #f7faff;
}

/* =========================
   CONSULTAS PUBLICAS (NO LOGUEADO)
   ========================= */

.midee-public-recent-consultas {
    margin-top: 16px;
    padding: 12px;
    border: 1px solid #d8e0ea;
    border-radius: 10px;
    background: #ffffff;
}

.midee-public-recent-consultas h4 {
    margin: 0 0 10px 0;
    font-size: 18px;
    color: #005181;
}

.midee-public-recent-consultas ul {
    margin: 0;
    padding-left: 18px;
}

.midee-public-recent-consultas li {
    margin: 0 0 10px 0;
}

.midee-public-recent-consultas li span {
    color: #4b5563;
    font-size: 14px;
}

.midee-reglamento-check {
    margin: 10px 0 12px;
    font-size: 14px;
    color: #1f2937;
}

.midee-reglamento-check label {
    display: inline-flex;
    align-items: flex-start;
    gap: 8px;
    line-height: 1.4;
}

.midee-reglamento-check input[type="checkbox"] {
    margin-top: 2px;
}

.midee-public-response-note {
    margin: 0 0 14px 0;
    padding: 12px;
    border: 1px solid #d8e0ea;
    border-radius: 8px;
    background: #f7faff;
}

.midee-public-response-note p {
    margin: 0 0 6px 0;
}

.midee-public-response-note p:last-child {
    margin-bottom: 0;
}

/* =========================
   CHAT DE CONSULTAS
   ========================= */

.midee-chat-page {
    padding: 18px 0;
}

.midee-chat-shell {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.midee-chat-hero,
.midee-chat-section {
    background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
    border: 1px solid #d7e3ef;
    border-radius: 18px;
    box-shadow: 0 14px 32px rgba(10, 41, 68, 0.08);
}

.midee-chat-hero {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding: 22px;
}

.midee-chat-eyebrow {
    margin: 0 0 8px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #1a6f8b;
}

.midee-detalle-titulo {
    margin: 0 0 6px;
}

.midee-detalle-caso-id {
    margin: 0;
    color: #5d6b7c;
}

.midee-chat-state {
    max-width: 340px;
}

.midee-chat-state p {
    margin: 10px 0 0;
    color: #405264;
    line-height: 1.55;
}

.midee-chat-state-badge {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.midee-chat-state-publicado {
    background: #e2f6f0;
    color: #13654d;
}

.midee-chat-state-asignado {
    background: #fff1cf;
    color: #7a5600;
}

.midee-chat-state-cerrado {
    background: #e5ebf3;
    color: #354b60;
}

.midee-chat-section {
    padding: 20px;
}

.midee-chat-section-private {
    background: linear-gradient(180deg, #fffdf6 0%, #fff8e8 100%);
}

.midee-chat-section-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 16px;
}

.midee-chat-section-head h3 {
    margin: 0 0 6px;
}

.midee-chat-section-head p {
    margin: 0;
    color: #536577;
}

.midee-chat-thread {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.midee-chat-thread-scrollable {
    position: relative;
    max-height: 620px;
    overflow-y: auto;
    padding: 10px 12px 18px;
    border: 1px solid #d7e3ef;
    border-radius: 18px;
    background: linear-gradient(180deg, #fbfdff 0%, #f3f8fc 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
    scrollbar-width: thin;
    scrollbar-color: #8ab3d1 #edf4fa;
}

.midee-chat-thread-scrollable::before,
.midee-chat-thread-scrollable::after {
    content: "";
    position: sticky;
    left: 0;
    display: block;
    height: 20px;
    z-index: 2;
    pointer-events: none;
}

.midee-chat-thread-scrollable::before {
    top: 0;
    margin: -10px -12px 0;
    background: linear-gradient(180deg, rgba(243, 248, 252, 0.95) 0%, rgba(243, 248, 252, 0) 100%);
}

.midee-chat-thread-scrollable::after {
    bottom: 0;
    margin: 0 -12px -18px;
    background: linear-gradient(180deg, rgba(243, 248, 252, 0) 0%, rgba(243, 248, 252, 0.98) 100%);
}

.midee-chat-thread-scrollable::-webkit-scrollbar {
    width: 10px;
}

.midee-chat-thread-scrollable::-webkit-scrollbar-track {
    background: #edf4fa;
    border-radius: 999px;
}

.midee-chat-thread-scrollable::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #9fc4e8 0%, #6f9fca 100%);
    border-radius: 999px;
    border: 2px solid #edf4fa;
}

.midee-chat-thread-scrollable::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #88b4dd 0%, #5f90bd 100%);
}

.midee-chat-message {
    max-width: 92%;
}

.midee-chat-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.midee-chat-time {
    font-size: 12px;
    color: #6d7d8d;
}

.midee-chat-bubble {
    padding: 14px 16px;
    border: 1px solid #d6e0ea;
    border-radius: 16px;
    background: #f8fbff;
    color: #22313f;
}

.midee-chat-message-consultante .midee-chat-bubble {
    background: #fff0e7;
    border-color: #f0c4a6;
}

.midee-chat-message-publico .midee-chat-bubble,
.midee-chat-message-suscriptor .midee-chat-bubble {
    background: #f3f6fa;
    border-color: #d4dde6;
}

.midee-chat-message-midee .midee-chat-bubble {
    background: #e8f4ff;
    border-color: #9ec7ef;
}

.midee-chat-message-assigned .midee-chat-bubble {
    background: linear-gradient(180deg, #fff7d7 0%, #fffdf4 100%);
    border-color: #d9b400;
    box-shadow: 0 0 0 2px rgba(217, 180, 0, 0.1);
}

.midee-chat-role-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.03em;
}

.midee-chat-role-consultante {
    background: #ffe2d4;
    color: #8d4f2f;
}

.midee-chat-role-publico,
.midee-chat-role-suscriptor {
    background: #e7edf4;
    color: #495a6b;
}

.midee-chat-role-midee {
    background: #d8edff;
    color: #005181;
}

.midee-chat-role-assigned {
    background: #fff0a8;
    color: #6d5300;
}

.midee-chat-composer-wrap {
    margin-top: 18px;
}

.midee-chat-composer-wrap-public {
    margin-top: 22px;
    padding: 18px;
    border: 1px solid #9fc4e8;
    border-radius: 20px;
    background: linear-gradient(180deg, #eef7ff 0%, #ffffff 100%);
    box-shadow: 0 18px 38px rgba(0, 81, 129, 0.12);
    scroll-margin-top: 110px;
}

.midee-chat-composer-intro {
    margin-bottom: 16px;
    padding: 14px 16px;
    border-radius: 16px;
    background: linear-gradient(135deg, #005181 0%, #1777a5 100%);
    color: #ffffff;
}

.midee-chat-composer-kicker {
    margin-bottom: 6px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    opacity: 0.85;
}

.midee-chat-composer-intro h4 {
    margin: 0 0 8px;
    color: #ffffff;
}

.midee-chat-composer-intro p {
    margin: 0;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.92);
}

.midee-chat-composer-steps {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.midee-chat-composer-steps span {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    font-size: 12px;
    font-weight: 700;
}

.midee-chat-composer-wrap h4 {
    margin: 0 0 12px;
}

.midee-chat-jump-link {
    text-decoration: none;
}

.midee-chat-floating-reply {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 999;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 18px;
    border-radius: 999px;
    background: linear-gradient(135deg, #005181 0%, #0f88a6 100%);
    color: #ffffff;
    font-weight: 800;
    text-decoration: none;
    box-shadow: 0 14px 28px rgba(0, 81, 129, 0.28);
}

.midee-chat-floating-reply:hover {
    color: #ffffff;
    transform: translateY(-1px);
}

.midee-chat-note,
.midee-chat-empty {
    margin-top: 16px;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px dashed #cad6e2;
    background: #f8fbff;
    color: #466072;
}

.midee-chat-note-private {
    margin-bottom: 12px;
    background: #fff7de;
    border-style: solid;
    border-color: #ecd38c;
}

.midee-chat-private-actions,
.midee-autorizacion-cierre {
    margin-top: 18px;
}

.midee-chat-contact-link {
    font-size: 12px;
    font-weight: 700;
    color: #005181;
    text-decoration: none;
}

.midee-chat-contact-link:hover {
    text-decoration: underline;
}

.midee-consulta-status {
    margin: 0 0 10px;
    font-size: 13px;
    font-weight: 600;
}

.midee-consulta-status-open {
    color: #1b6a57;
}

.midee-consulta-status-private {
    color: #8a5a00;
}

.midee-consulta-status-closed {
    color: #495c70;
}

@media (max-width: 782px) {
    .midee-chat-hero,
    .midee-chat-section-head {
        flex-direction: column;
    }

    .midee-chat-state {
        max-width: none;
    }

    .midee-chat-message {
        max-width: 100%;
    }

    .midee-chat-thread-scrollable {
        max-height: 540px;
    }

    .midee-chat-floating-reply {
        right: 14px;
        left: 14px;
        bottom: 14px;
    }
}

/* =========================
   MODAL PERFIL CONTACTO
   ========================= */

.midee-contact-modal-open {
    overflow: hidden;
}

.midee-contact-modal {
    position: fixed;
    inset: 0;
    z-index: 2147483646;
    isolation: isolate;
}

.midee-contact-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 2147483646;
}

.midee-contact-modal__dialog {
    position: relative;
    z-index: 2147483647;
    width: min(92vw, 760px);
    max-height: 86vh;
    overflow: auto;
    margin: 8vh auto 0;
    background: #fff;
    border-radius: 10px;
    border: 1px solid #d8e0ea;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
    padding: 18px;
}

.midee-contact-modal__close {
    position: absolute;
    top: 8px;
    right: 10px;
    border: 0;
    background: transparent;
    color: #1f2937;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.midee-open-contact-modal {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.2px;
    text-transform: uppercase;
    text-decoration: none;
    color: #005181;
}

.midee-open-contact-modal:hover {
    text-decoration: underline;
}

/* =========================
   TARJETA PERFIL (estilo midee-proyectos)
   ========================= */

.midee-author-card {
    display: flex;
    gap: 16px;
    padding: 16px;
    background: #ffffff;
    border: 1px solid var(--midee-border);
    border-radius: 6px;
    align-items: flex-start;
    font-size: 0.9rem;
    line-height: 1.4;
}

.midee-author-avatar {
    flex: 0 0 72px;
}

.midee-author-photo {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--midee-border);
    background: #f4f6f9;
}

.midee-author-content {
    flex: 1;
    min-width: 0;
}

.midee-author-name {
    margin: 0 0 4px 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--midee-text);
}

.midee-author-profession {
    margin: 0;
    font-size: 0.85rem;
    color: var(--midee-muted);
}

.midee-author-company {
    margin: 0 0 8px 0;
    font-size: 0.85rem;
    color: var(--midee-text);
    font-weight: 500;
}

.midee-author-bio {
    margin: 8px 0;
    font-size: 0.85rem;
    color: var(--midee-text);
}

.midee-author-meta {
    margin: 8px 0 0 0;
    padding: 0;
    list-style: none;
    font-size: 0.8rem;
    color: var(--midee-muted);
}

.midee-author-meta li {
    margin-bottom: 4px;
}

.midee-author-meta strong {
    font-weight: 600;
    color: var(--midee-text);
}

.midee-author-meta a {
    color: var(--midee-primary);
    text-decoration: none;
}

.midee-author-meta a:hover {
    text-decoration: underline;
}

@media (max-width: 640px) {
    .midee-contact-modal__dialog {
        margin-top: 5vh;
        padding: 14px;
    }

    .midee-author-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .midee-author-avatar {
        margin-bottom: 8px;
    }

    .midee-author-meta {
        text-align: left;
    }
}
