/* Identidad INDI compartida por el portal y el acceso. */
:root {
    --blue: #0066f9;
    --navy: #142643;
    --text: #243651;
    --muted: #63738a;
    --line: #e1e7f0;
    --light: #f5f7fb;
    --portal-blue: #0066f9;
    --portal-navy: #142643;
    --portal-ink: #142643;
    --portal-muted: #63738a;
    --portal-line: #e1e7f0;
    --portal-bg: #f5f7fb;
}
body { line-height: 1.5; -webkit-font-smoothing: antialiased; }
.shell { grid-template-columns: 264px minmax(0, 1fr); }
.shell > aside { position: sticky; top: 0; align-self: start; height: 100dvh; box-sizing: border-box; overflow-y: auto; background: #fff; color: var(--text); border-right: 1px solid var(--line); padding: 30px 18px; }
.brand { display: flex; align-items: center; gap: 14px; padding: 0 8px 30px; text-decoration: none; letter-spacing: normal; }
.brand img { display: block; width: 48px; height: 60px; object-fit: contain; flex-shrink: 0; }
.brand .brand-copy { display: grid; gap: 5px; color: var(--navy); }
.brand-copy strong { font-size: 13px; font-weight: 750; }
.brand-copy .brand-name { font-size: 20px; font-weight: 800; letter-spacing: -.035em; white-space: nowrap; }
.brand-copy small { font-size: 11px; color: var(--muted); font-weight: 450; }
.shell > aside .nav-group { margin: 26px 12px 10px; font-size: 10px; letter-spacing: .13em; text-transform: uppercase; font-weight: 750; color: var(--muted); }
.shell > aside nav a { padding: 13px 14px; margin: 5px 0; color: #53637b; border-radius: 10px; font-weight: 550; transition: background .15s, color .15s; }
.shell > aside nav a:hover { background: #f0f5ff; color: #0055d1; }
.shell > aside nav a.active { background: var(--blue); color: #fff; box-shadow: 0 5px 14px #0066f926; }
.shell > main { min-width: 0; padding: 24px 32px 40px; }
.shell > main > header { min-height: 58px; padding-bottom: 20px; margin-bottom: 30px; border-bottom: 1px solid var(--line); gap: 16px; }
.user { gap: 14px; font-size: 13px; }
.user .label { font-size: 12px; }
.avatar { width: 40px; height: 40px; border: 4px solid #e6efff; box-sizing: content-box; }
h1, .workspace-header h2, .project-hero h2 { letter-spacing: -.035em; line-height: 1.25; }
.workspace-header h2, .project-hero h2 { font-size: 28px; }
.workspace-header, .project-hero { margin-bottom: 28px; }
button, .button-link { border-radius: 9px; min-height: 38px; transition: background .15s, box-shadow .15s; }
.button-link:hover { background: #0055d1; }
.button-link.secondary-link, button.ghost { background: #fff; border: 1px solid #d7e2f2; color: #334967; }
.button-link.secondary-link:hover, button.ghost:hover { background: #eaf2ff; border-color: #a9c9ff; color: #0055d1; }
:where(a, button, input, select, textarea):focus-visible { outline: 3px solid #0066f970; outline-offset: 3px; }
input, select, textarea { accent-color: var(--blue); }
.card, .metric-card, .project-portfolio-card, .documents-filters, .documents-main, .documents-preview { border-radius: 14px; box-shadow: 0 4px 20px #14264305; }
.documents-explorer { gap: 18px; grid-template-columns: 190px minmax(0, 1fr) 260px; }
.documents-main { overflow: hidden; }
.documents-filters { padding: 14px 10px; }
.documents-filters > strong { letter-spacing: .08em; margin: 4px 10px 14px; font-size: 10px; }
.documents-filters button { padding: 10px; font-size: 12px; }
.documents-filters button.active { background: #eaf2ff; color: #0055d1; font-weight: 750; }
.documents-filters button:hover { background: #f0f5ff; color: #0055d1; }
.documents-filters button.active span { background: #d6e6ff; }
.documents-toolbar { padding: 18px; gap: 12px; }
.documents-toolbar input { padding: 12px; background: #f8faff; border-color: var(--line); border-radius: 9px; font-size: 13px; color: var(--text); }
.project-chip, .project-code { background: #eaf2ff; color: #0055d1; }
.discipline-row { padding: 18px; }
.discipline-row span { background: #fafbfe; border-radius: 8px; }
.documents-list-title { padding: 16px 18px; background: #fafbfe; }
.explorer-list > button { padding: 18px; gap: 12px; }
.explorer-list > button.selected { background: #eff5ff; box-shadow: inset 3px 0 var(--blue); }
.file-icon { display: grid; place-items: center; width: 32px; height: 38px; border-radius: 8px; background: #fff0f0; color: #d94646; }
.file-data { min-width: 0; overflow-wrap: anywhere; }
.file-data small { color: var(--muted); line-height: 1.6; }
.documents-preview { padding: 20px; gap: 16px; color: var(--text); }
.documents-preview h3 { color: var(--navy); line-height: 1.45; overflow-wrap: anywhere; }
.preview-facts > div { background: #f3f6fb; padding: 11px; }
.preview-facts strong { color: var(--text); }
.preview-facts span { color: #63738a; font-size: 11px; }
.documents-preview .button-link { box-shadow: 0 4px 12px #0066f920; }
.preview-meta { line-height: 1.8; }
.login-page { min-height: 100vh; display: grid; place-items: center; padding: 28px; background: radial-gradient(ellipse at top left, #cfe0ff, transparent 55%), #f3f6fc; }
.login-card { width: min(440px, 100%); padding: 40px; background: #fff; border: 1px solid #e1e7f0; border-radius: 22px; box-shadow: 0 24px 80px #123e7a14; border-top: 4px solid var(--blue); }
.login-card .brand { padding: 0; }
.login-card button { min-height: 46px; }
@media (max-width: 1250px) {
    .documents-explorer { grid-template-columns: 180px minmax(0, 1fr); }
    .documents-preview { grid-column: 1 / -1; }
}
@media (max-width: 1100px) {
    .shell { grid-template-columns: 1fr; }
    .shell > aside { position: static; height: auto; overflow-y: visible; display: block; padding: 16px 24px; border-right: 0; border-bottom: 1px solid var(--line); }
    .shell > aside .brand { padding-bottom: 8px; }
    .shell > aside nav { display: flex; gap: 8px; overflow-x: auto; }
    .shell > aside nav a { flex-shrink: 0; }
    .shell > aside .nav-group { display: none; }
}
@media (max-width: 820px) {
    .shell > main { padding: 20px 16px; }
    .shell > main > header { flex-wrap: wrap; margin-bottom: 24px; }
    .user { flex-wrap: wrap; }
    .documents-explorer { grid-template-columns: minmax(0, 1fr); }
    .workspace-header h2, .project-hero h2 { font-size: 24px; }
    .documents-toolbar label { min-width: 0; flex-basis: 100%; }
    .login-card { padding: 28px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; }
}
