/* Shell neutro del portal (marca Grupo Diga). Todo va acotado a #shell, .cmt y .login-* para no chocar con conklave.css. */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@400;500;600&family=Sora:wght@500;600;700&display=swap');

:root { --shell-h: 64px; }
@media (max-width: 719.98px) { :root { --shell-h: 104px; } }

body.pagina-ck { margin: 0; background: #f6f2eb; }

/* ---------- Barra superior ---------- */
#shell {
  position: sticky; top: 0; z-index: 1000; height: var(--shell-h);
  background: #fff; border-bottom: 1px solid #e5e5e5;
  font: 400 14px/1.4 'IBM Plex Sans', system-ui, sans-serif; color: #171717;
}
#shell *, #shell *::before, #shell *::after { box-sizing: border-box; }
#shell .gd-barra { height: 100%; display: flex; align-items: center; gap: 16px; padding: 0 24px; }
#shell a { color: inherit; text-decoration: none; }
#shell .gd-marca { display: flex; align-items: center; gap: 16px; flex: none; border-radius: 6px; }
#shell .gd-marca img { height: 28px; width: auto; display: block; }
#shell .gd-rotulo { padding-left: 16px; border-left: 1px solid #d4d4d4; color: #525252; font-size: 13px; white-space: nowrap; }
#shell .gd-nav { display: flex; gap: 4px; margin-left: 8px; }
#shell .gd-nav a {
  padding: 8px 12px; border-radius: 8px; color: #525252; white-space: nowrap;
  font: 500 14px/1.2 Sora, system-ui, sans-serif;
}
#shell .gd-nav a:hover { background: #f0f0f0; color: #171717; }
#shell .gd-nav a[aria-current='page'] { background: #171717; color: #fff; }
#shell .gd-corto { display: none; }
#shell .gd-usuario { margin-left: auto; display: flex; align-items: center; gap: 12px; min-width: 0; }
#shell .gd-hola { color: #525252; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 220px; }
#shell .gd-hola b { color: #171717; font-weight: 600; }
#shell .gd-salir {
  padding: 6px 12px; border: 1px solid #d4d4d4; border-radius: 8px; background: #fff; color: #171717;
  font: 500 13px/1.2 Sora, system-ui, sans-serif; cursor: pointer;
}
#shell .gd-salir:hover { background: #f0f0f0; }
#shell a:focus-visible, #shell button:focus-visible { outline: 2px solid #171717; outline-offset: 2px; }
#shell .gd-nav a[aria-current='page']:focus-visible { outline-color: #171717; outline-offset: 3px; }

@media (max-width: 1099.98px) { #shell .gd-rotulo { display: none; } }
@media (max-width: 999.98px) {
  #shell .gd-largo { display: none; }
  #shell .gd-corto { display: inline; }
}
@media (max-width: 719.98px) {
  #shell .gd-barra {
    display: grid; grid-template-columns: 1fr auto; grid-template-rows: 56px 48px; gap: 0; padding: 0 16px;
    grid-template-areas: 'marca usuario' 'nav nav';
  }
  #shell .gd-marca { grid-area: marca; }
  #shell .gd-usuario { grid-area: usuario; gap: 8px; }
  #shell .gd-hola { max-width: 38vw; }
  #shell .gd-nav { grid-area: nav; margin: 0 -16px; padding: 0 16px; border-top: 1px solid #eee; gap: 0; }
  #shell .gd-nav a { flex: 1; text-align: center; border-radius: 0; padding: 0 4px; line-height: 47px; font-size: 13px; border-bottom: 3px solid transparent; }
  #shell .gd-nav a:hover { background: none; }
  #shell .gd-nav a[aria-current='page'] { background: none; color: #171717; border-bottom-color: #171717; }
  #shell .gd-inicio { display: none; }
}

/* ---------- Comentarios (neutro: vive dentro de páginas con marca ConKlave) ---------- */
.cmt { box-sizing: border-box; background: #fff; color: #171717; border: 1px solid #e5e5e5; border-radius: 12px; padding: 16px; font-family: inherit; font-size: 14px; line-height: 1.5; text-align: left; }
.cmt *, .cmt *::before, .cmt *::after { box-sizing: border-box; }
.cmt h3.cmt-titulo { margin: 0 0 12px; font-family: inherit; font-size: 15px; font-weight: 600; color: inherit; }
.cmt .cmt-lista { display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.cmt .cmt-estado { margin: 0; color: #737373; }
.cmt .cmt-item { padding-bottom: 12px; border-bottom: 1px solid #efefef; }
.cmt .cmt-item:last-child { padding-bottom: 0; border-bottom: 0; }
.cmt .cmt-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; font-size: 13px; }
.cmt .cmt-autor { font-weight: 600; }
.cmt .cmt-fecha { color: #737373; }
.cmt .cmt-texto { margin: 4px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.cmt textarea {
  display: block; width: 100%; min-height: 76px; padding: 10px 12px; resize: vertical;
  font: inherit; color: #171717; background: #fff; border: 1px solid #d4d4d4; border-radius: 8px;
}
.cmt textarea:disabled { background: #fafafa; }
.cmt .cmt-acciones { display: flex; align-items: center; justify-content: flex-end; gap: 12px; margin-top: 8px; }
.cmt .cmt-error { margin-right: auto; color: #b42318; font-size: 13px; }
.cmt button {
  padding: 8px 16px; font: inherit; font-weight: 600; color: #fff; background: #171717;
  border: 1px solid #171717; border-radius: 8px; cursor: pointer;
}
.cmt button:disabled { opacity: .5; cursor: not-allowed; }
.cmt button.cmt-reintentar { margin-top: 8px; color: #171717; background: #fff; border-color: #d4d4d4; }
.cmt textarea:focus-visible, .cmt button:focus-visible { outline: 2px solid #171717; outline-offset: 2px; }

/* ---------- Login ---------- */
body.login-pagina {
  margin: 0; min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; box-sizing: border-box;
  background: #fafafa; color: #171717; font: 400 16px/1.5 'IBM Plex Sans', system-ui, sans-serif;
}
.login-pagina *, .login-pagina *::before, .login-pagina *::after { box-sizing: border-box; }
.login-tarjeta { width: 100%; max-width: 400px; padding: 32px; background: #fff; border: 1px solid #e5e5e5; border-radius: 16px; box-shadow: 0 1px 2px rgba(0,0,0,.04), 0 8px 24px rgba(0,0,0,.04); }
.login-tarjeta img { display: block; height: 32px; width: auto; margin-bottom: 24px; }
.login-tarjeta h1 { margin: 0 0 4px; font: 600 22px/1.25 Sora, system-ui, sans-serif; }
.login-tarjeta p.login-sub { margin: 0 0 24px; color: #525252; font-size: 14px; }
.login-tarjeta label { display: block; margin-bottom: 16px; font-size: 14px; font-weight: 500; }
.login-tarjeta input {
  display: block; width: 100%; height: 44px; margin-top: 6px; padding: 0 12px;
  font: inherit; color: #171717; background: #fff; border: 1px solid #d4d4d4; border-radius: 10px;
}
.login-tarjeta input:focus-visible, .login-tarjeta button:focus-visible { outline: 2px solid #171717; outline-offset: 2px; }
.login-tarjeta button {
  width: 100%; height: 46px; margin-top: 8px; color: #fff; background: #171717; border: 0; border-radius: 10px;
  font: 600 15px/1 Sora, system-ui, sans-serif; cursor: pointer;
}
.login-tarjeta button:disabled { opacity: .6; cursor: not-allowed; }
.login-tarjeta .login-error { min-height: 20px; margin: 12px 0 0; color: #b42318; font-size: 14px; }
