/* =====================================================================
   portal.css  ·  estilos de la portada / indice (html/portal.css)
   Se carga DESPUES de filemanager/styles/style.css para armonizar.
   ===================================================================== */

:root {
  --portal-bg: #0f172a;
  --portal-bg2: #1e293b;
  --portal-card: #ffffff;
  --portal-accent: #2563eb;
  --portal-accent-soft: #dbeafe;
  --portal-text: #0f172a;
  --portal-muted: #64748b;
  --portal-border: #e2e8f0;
}

.portal-page {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(160deg, var(--portal-bg) 0%, var(--portal-bg2) 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: #e2e8f0;
}

/* --- Barra superior --- */
.portal-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: 960px;
  margin: 0 auto;
}
.portal-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: .2px;
}
.portal-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--portal-accent);
  color: #fff;
}
.portal-user {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 14px;
  color: #cbd5e1;
}
.portal-logout {
  color: #fff;
  text-decoration: none;
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .18);
  padding: 6px 14px;
  border-radius: 8px;
  transition: background .15s ease;
}
.portal-logout:hover { background: rgba(255, 255, 255, .16); }

/* --- Rejilla de tarjetas --- */
.portal-main {
  max-width: 960px;
  margin: 0 auto;
  padding: 24px 24px 48px;
}
.portal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}
.portal-cat-title {
  max-width: 960px;
  margin: 26px auto 12px;
  padding: 0 4px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: #94a3b8;
}
.portal-cat-title:first-child { margin-top: 6px; }

.portal-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: var(--portal-card);
  border: 1px solid var(--portal-border);
  border-radius: 14px;
  text-decoration: none;
  color: var(--portal-text);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

/* --- Indicador de estado --- */
.portal-dot {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #cbd5e1;                     /* gris: comprobando */
  box-shadow: 0 0 0 3px rgba(203, 213, 225, .25);
}
.portal-dot.up {
  background: #22c55e;                      /* verde: en linea */
  box-shadow: 0 0 0 3px rgba(34, 197, 94, .22);
}
.portal-dot.down {
  background: #ef4444;                      /* rojo: sin respuesta */
  box-shadow: 0 0 0 3px rgba(239, 68, 68, .22);
}
.portal-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, .18);
  border-color: var(--portal-accent);
}
.portal-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
  border-radius: 12px;
  background: var(--portal-accent-soft);
  color: var(--portal-accent);
}
.portal-card-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 auto;
  min-width: 0;
}
.portal-card-name {
  font-size: 16px;
  font-weight: 600;
}
.portal-card-desc {
  font-size: 13px;
  color: var(--portal-muted);
}
.portal-card-arrow {
  color: var(--portal-muted);
  flex: 0 0 auto;
}
.portal-card:hover .portal-card-arrow { color: var(--portal-accent); }

.portal-card-static { cursor: default; }
.portal-card-static:hover {
  transform: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
  border-color: var(--portal-border);
}

@media (max-width: 520px) {
  .portal-topbar { padding: 14px 16px; }
  .portal-main { padding: 16px 16px 40px; }
  .portal-grid { grid-template-columns: 1fr; }
}


/* Footer / Status bar fixed at bottom */
.status-bar {
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 32px !important;
  background: #1e293b !important;
  color: #94a3b8 !important;
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 16px !important;
  font-size: 12px !important;
  border-top: 1px solid #334155 !important;
  z-index: 99999 !important;
  gap: 20px !important;
  box-sizing: border-box !important;
}

.status-bar .status-item {
  display: flex !important;
  align-items: center !important;
  gap: 6px !important;
}

.status-bar .status-dot {
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background: #22c55e !important;
}

.status-bar .status-dot.offline {
  background: #ef4444 !important;
}

.status-bar strong {
  color: #f8fafc !important;
}

/* holgura status-bar */
.portal-main{padding-bottom:56px;}
