/* ==========================================================
   Innova Global — panel (ingreso, repositorio, usuarios)
   Se carga encima de styles.css
   ========================================================== */

.panel-body { background: var(--bg-soft); min-height: 100vh; }
.panel-header { background: var(--navy-950); border-bottom: 1px solid rgba(255,255,255,.06); }
.panel-nav { display: flex; align-items: center; gap: 28px; min-height: 68px; flex-wrap: wrap; padding: 8px 0; }
.panel-links { display: flex; gap: 4px; flex: 1; }
.panel-links a { color: #c9d3f5; font-weight: 600; font-size: .94rem; padding: 8px 14px; border-radius: 10px; }
.panel-links a:hover, .panel-links a.on { background: rgba(255,255,255,.08); color: #fff; }
.panel-user { display: flex; align-items: center; gap: 14px; color: #c9d3f5; font-size: .9rem; }
.panel-user em { font-style: normal; font-size: .75rem; color: var(--cyan); margin-left: 6px; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; font-weight: 600; color: var(--blue); cursor: pointer; }
.panel-user .link-btn { color: #fff; }
.link-btn:hover { text-decoration: underline; }
.panel-user form, .actions form { display: inline; }

.panel-main { padding: 40px 0 72px; }
.panel-title { font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: 4px; }
.panel-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 24px; }
.panel-cards { margin-top: 28px; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.nowrap { white-space: nowrap; }

.search { display: flex; gap: 8px; }
.search input { font: inherit; padding: 11px 14px; border-radius: 12px; border: 1px solid var(--line); min-width: 260px; background: #fff; }
.search input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(59,130,246,.15); }
.btn--sm { padding: 8px 16px; font-size: .85rem; }

.alert { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--blue); border-radius: 12px; padding: 16px 18px; margin: 0 0 20px; }
.alert.ok { border-left-color: var(--green); }
.alert.warn { border-left-color: #f59e0b; }
.alert p { margin: 0 0 10px; }
.copy-row { display: flex; gap: 8px; }
.copy-row input { flex: 1; font: inherit; font-size: .85rem; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-soft); }
.error { color: #dc2626; font-size: .9rem; margin: -4px 0 12px; }

/* Tarjeta de ingreso */
.auth-card { max-width: 420px; margin: 40px auto; background: #fff; border-radius: 20px; padding: 36px; box-shadow: var(--shadow); }
.auth-card h1 { font-size: 1.7rem; margin-bottom: 6px; }
.auth-card form { margin-top: 22px; }
.auth-card .btn { width: 100%; margin-top: 6px; }
.auth-card .small { margin-top: 18px; text-align: center; }
.check { display: flex; gap: 8px; align-items: center; font-size: .9rem; color: var(--muted); margin-bottom: 14px; }
.field small { font-size: .8rem; }

/* Cajas y tablas */
.box { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 24px; }
.box h2 { font-size: 1.1rem; margin-bottom: 16px; }
.panel-split { display: grid; grid-template-columns: 340px 1fr; gap: 24px; align-items: start; }
.panel-split .box .btn { width: 100%; }
.field select { font: inherit; padding: 13px 15px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg-soft); }

.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); }
.table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.table td strong, .table td > .muted { display: block; }
.table tr.off td { opacity: .55; }
.fname { word-break: break-word; }
.actions { text-align: right; white-space: nowrap; }
.actions form + form { margin-left: 14px; }

.tag { display: inline-block; font-size: .75rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: var(--bg-soft); }
.tag.ok { background: #dcfce7; color: #166534; }
.tag.warn { background: #fef3c7; color: #92400e; }
.tag.off { background: #e5e7eb; color: #4b5563; }

/* Repositorio tipo Explorador */
.explorer { padding: 8px 12px; margin-bottom: 12px; }
.ex-name { display: flex; gap: 12px; align-items: flex-start; }
.ex-ico { flex: none; width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; background: #eef3ff; color: var(--blue); }
.ex-ico svg { width: 20px; height: 20px; }
.ex-ico.folder { background: #fff6dc; color: #f2b51d; }

/* Repositorio */
.repo-group { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 8px 12px 4px; margin-bottom: 20px; }
.repo-group h2 { display: flex; align-items: center; gap: 10px; font-size: 1.05rem; margin: 12px 12px 6px; }
.repo-group h2 svg { width: 20px; height: 20px; color: var(--blue); }
.repo-group h2 span { font-size: .75rem; font-weight: 700; background: var(--bg-soft); color: var(--muted); padding: 3px 9px; border-radius: 999px; }
.sha { margin-top: 6px; font-size: .78rem; color: var(--muted); }
.sha summary { cursor: pointer; }
.sha code { display: block; word-break: break-all; font-size: .75rem; margin-top: 4px; }

nav[role="navigation"] { margin-top: 18px; }

@media (max-width: 860px) {
  .panel-split { grid-template-columns: 1fr; }
  .search { width: 100%; }
  .search input { min-width: 0; flex: 1; }
  .panel-links { order: 3; width: 100%; flex: none; overflow-x: auto; }
  .auth-card { padding: 26px; margin: 16px auto; }
}
