/* Hallmark · macrostructure: Stat-Led · genre: modern-minimal · theme: company brands
 * nav: N9 · footer: Ft2 · audience: internal team · use: monthly revenue goals
 * pre-emit critique: P4 H5 E4 S5 R4 V4 · functional gradients requested for progress only */
* { box-sizing: border-box; }
html, body { margin: 0; overflow-x: clip; }
html { scroll-behavior: smooth; }
body { background: var(--color-paper); color: var(--color-ink); font: 15px/1.5 var(--font-body); -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; }
button, select { font: inherit; }
button, a, select { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .55; }
button, select, a { outline-offset: 5px; }
:focus-visible { outline: 3px solid var(--color-accent); }
a { color: inherit; }
h1, h2, p { margin: 0; }
h1, h2 { font-family: var(--font-display); font-style: normal; min-width: 0; overflow-wrap: anywhere; }
[hidden] { display: none !important; }
.sr-only, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
.skip:focus { position: fixed; z-index: 10; padding: var(--space-md); background: var(--color-surface); }
.topbar { height: 88px; background: var(--color-surface); border-bottom: 1px solid var(--color-rule); padding: 0 max(32px, calc((100vw - 1240px) / 2)); display: flex; align-items: center; justify-content: space-between; gap: var(--space-lg); }
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; font-size: 27px; font-weight: 750; letter-spacing: -1.2px; }
.brand-dot { color: var(--color-accent); }
.brand-lockup { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; }
.brand-name { font-size: 23px; line-height: 24px; font-weight: 750; letter-spacing: -.6px; }
.brand-product { font-size: 18px; line-height: 19px; font-weight: 650; letter-spacing: 0; color: #26b2ce; }
.brand img.brand-mark { width: 34px; height: 34px; object-fit: contain; }
.header-actions { display: grid; grid-auto-flow: column; grid-auto-columns: 148px; align-items: center; gap: 8px; }
.button, .icon-button { border: 1px solid var(--color-rule); background: var(--color-surface); border-radius: 0; color: var(--color-body); transition: background var(--dur-fast), border-color var(--dur-fast); white-space: nowrap; }
.button { padding: 10px 16px; display: inline-flex; align-items: center; justify-content: center; gap: var(--space-sm); font-size: 13px; font-weight: 600; }
.button:hover, .icon-button:hover { background: var(--color-accent-soft); border-color: var(--color-accent); color: var(--color-accent); }
.button:active, .icon-button:active { transform: translateY(1px); }
.primary { background: var(--color-accent); border-color: var(--color-accent); color: var(--color-surface); }
.primary:hover { color: var(--color-surface); background: var(--color-accent-hover); }
.icon-button { height: 36px; width: 36px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; }
main { max-width: 1240px; margin: 0 auto; padding: 40px 0 0; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: var(--space-xl); margin-bottom: 28px; }
.company-picker { display: inline-flex; padding: 4px; border: 1px solid var(--color-rule); border-radius: 0; margin-bottom: 22px; background: var(--color-surface); }
.company { border: 0; border-radius: 0; padding: 7px 16px; font-size: 13px; font-weight: 650; color: var(--color-muted); background: transparent; white-space: nowrap; }
.company.active { color: var(--color-accent); background: var(--color-accent-soft); }
.company:hover { color: var(--color-accent); }
h1 { font-size: clamp(28px, 3vw, 37px); font-weight: 650; line-height: 1.22; letter-spacing: -1.3px; margin-bottom: 9px; }
.page-heading p { color: var(--color-muted); font-size: var(--text-sm); }
.period-controls { display: flex; align-items: center; gap: var(--space-sm); font-size: var(--text-xs); color: var(--color-body); padding-bottom: 3px; white-space: nowrap; }
.period-controls .icon-button { margin-left: var(--space-sm); background: transparent; border-color: transparent; }
.live-dot { display: inline-block; height: 7px; width: 7px; border-radius: 0; background: var(--color-green); flex-shrink: 0; }
.hero { border: 1px solid var(--color-rule); background: var(--color-surface); border-radius: 0; display: grid; grid-template-columns: minmax(0, 1fr) 280px; overflow: clip; box-shadow: 0 8px 32px var(--color-shadow); }
.hero-main { padding: 32px 36px 28px; background: var(--color-hero); min-width: 0; }
.hero-topline { display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); color: var(--color-body); font-size: 13px; font-weight: 550; }
.chip { padding: 5px 10px; border-radius: 0; font-size: 11px; font-weight: 650; color: var(--color-accent); background: var(--color-surface); white-space: nowrap; }
.chip.success { color: var(--color-green-text); background: var(--color-green-soft); }
.amount-row { display: flex; align-items: center; gap: 23px; padding-top: 24px; padding-bottom: 6px; }
.amount { font: 650 clamp(46px, 6.4vw, 88px)/1.17 var(--font-display); letter-spacing: -4.5px; white-space: nowrap; }
.amount > span { font-size: .43em; letter-spacing: -1px; color: var(--color-muted); font-weight: 450; }
.target-caption { display: flex; flex-direction: column; justify-content: center; gap: 3px; padding-top: 8px; color: var(--color-muted); font-size: 13px; }
.target-caption strong { font-weight: 600; }
.target-caption .percentage { color: var(--color-accent); font-size: 24px; font-weight: 650; letter-spacing: -.7px; }
.progress-region { position: relative; padding-top: 67px; }
.no-minimum .progress-region { padding-top: 35px; }
.minimum-flag { position: absolute; top: 17px; left: 78.5714%; transform: translateX(-50%); color: var(--color-body); line-height: 1.3; font-size: 11px; text-align: center; white-space: nowrap; }
.minimum-flag strong { display: block; font-size: 13px; margin-top: 2px; color: var(--color-ink); }
.minimum-flag::after { content: ''; display: block; height: 12px; width: 1px; background: var(--color-muted); margin: 5px auto 0; }
.progress { height: 48px; border-radius: 0; background: var(--color-track); position: relative; isolation: isolate; overflow: clip; }
.progress-fill { width: 0; height: 100%; border-radius: 0; background: linear-gradient(100deg, var(--color-blue), var(--color-cyan) 63%, var(--color-green)); position: relative; z-index: 2; transition: width var(--dur-slow) var(--ease-out); }
.progress-fill::after { content: ''; position: absolute; top: 5px; bottom: 5px; right: 6px; width: 3px; border-radius: 0; background: var(--color-glint); }
.stretch-zone { position: absolute; top: 0; bottom: 0; right: 0; width: 21.4286%; background: repeating-linear-gradient(120deg, transparent, transparent 5px, var(--color-surface) 5px, var(--color-surface) 7px); opacity: .4; }
.minimum-tick { position: absolute; z-index: 3; left: 78.5714%; top: 0; bottom: 0; border-left: 2px solid var(--color-surface); }
.time-marker { position: absolute; z-index: 4; left: 0; top: 14px; bottom: 14px; width: 2px; background: var(--color-ink); opacity: .45; }
.scale { display: flex; justify-content: space-between; font-size: 10px; color: var(--color-muted); margin-top: 9px; }
.scale > :last-child { color: var(--color-ink); font-weight: 600; }
.hero-bottom { display: flex; justify-content: space-between; gap: var(--space-md); align-items: flex-end; margin-top: 30px; }
.hero-bottom p { max-width: 350px; font-size: 14px; font-weight: 550; }
.time-note { font-size: 11px; color: var(--color-muted); white-space: nowrap; }
.milestones { padding: 30px 24px 24px; display: flex; flex-direction: column; gap: 25px; }
.aside-heading { color: var(--color-muted); font-size: 12px; font-weight: 550; }
.milestone { display: flex; gap: 13px; align-items: flex-start; }
.milestone-icon { flex-shrink: 0; border: 1px solid var(--color-rule); border-radius: 0; height: 28px; width: 28px; display: grid; place-items: center; font-size: 11px; font-weight: 600; color: var(--color-muted); }
.milestone-icon.done { color: var(--color-green-text); background: var(--color-green-soft); border-color: var(--color-green-soft); }
.milestone h2 { font-size: 13px; line-height: 1.4; font-weight: 650; margin: 3px 0 4px; }
.milestone p { font-size: 11px; color: var(--color-muted); line-height: 1.5; }
.milestone strong { display: block; margin-top: 9px; font-size: 13px; font-weight: 650; }
.next-step { margin-top: auto; border-top: 1px solid var(--color-rule); padding-top: 18px; color: var(--color-muted); font-size: 12px; line-height: 1.7; }
.pace-section { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-lg); padding: 30px 14px; border-bottom: 1px solid var(--color-rule); }
.pace-summary { display: flex; gap: 14px; align-items: center; }
.pace-symbol { width: 43px; height: 43px; border-radius: 0; background: var(--color-green-soft); color: var(--color-green-text); display: grid; place-items: center; font-size: 25px; flex-shrink: 0; }
.pace-summary h2 { font-size: 14px; font-weight: 650; margin-bottom: 4px; }
.pace-summary p { font-size: 11px; color: var(--color-muted); max-width: 260px; }
.pace-stat { display: flex; flex-direction: column; padding-left: var(--space-xl); border-left: 1px solid var(--color-rule); }
.pace-stat > span { font-size: 11px; color: var(--color-muted); }
.pace-stat strong { font-size: 25px; font-weight: 650; letter-spacing: -.7px; margin: 4px 0 0; line-height: 1.4; }
.pace-stat small { font-size: 10px; color: var(--color-muted); }
.history { margin-top: 38px; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: var(--space-lg); }
.section-heading h2 { font-size: 21px; font-weight: 650; letter-spacing: -.6px; margin-bottom: 4px; }
.section-heading p { font-size: 12px; color: var(--color-muted); }
.year-select { position: relative; }
.year-select select { appearance: none; border: 1px solid var(--color-rule); color: var(--color-body); background: var(--color-surface); padding: 8px 38px 8px 14px; border-radius: 0; font-size: 12px; font-weight: 600; cursor: pointer; }
.year-select > span:last-child { position: absolute; right: 14px; pointer-events: none; top: 5px; }
.chart-legend { display: flex; gap: 22px; justify-content: flex-end; margin-top: 26px; color: var(--color-muted); font-size: 10px; }
.chart-legend > span { display: flex; align-items: center; gap: 6px; }
.legend-dot { display: inline-block; width: 7px; height: 7px; border-radius: 0; }
.target-color { background: var(--color-green); }
.minimum-color { background: var(--color-blue); }
.pending-color { background: var(--color-track); }
.history-chart { position: relative; height: 235px; margin-top: 18px; padding-right: 53px; }
.chart-line { position: absolute; left: 0; right: 0; border-top: 1px dashed var(--color-rule); pointer-events: none; }
.chart-line span { position: absolute; right: 0; top: -8px; padding: 0 0 0 6px; font-size: 9px; color: var(--color-muted); background: var(--color-paper); }
.goal-line { border-color: var(--color-green); }
.months { height: 100%; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 15px; padding-left: 7px; position: relative; }
.month { height: 100%; min-width: 0; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; border: 0; background: transparent; padding: 0 3px; color: var(--color-muted); position: relative; border-radius: 0; }
.month:not(:disabled):hover { background: var(--color-accent-soft); }
.month:disabled { opacity: 1; cursor: default; }
.month-plot { height: 195px; width: 100%; display: flex; align-items: center; justify-content: flex-end; flex-direction: column; position: relative; }
.month-value { font-size: 10px; color: var(--color-body); font-weight: 550; margin-bottom: 7px; white-space: nowrap; }
.month-bar { flex-shrink: 0; width: min(100%, 42px); min-height: 3px; border-radius: 0; background: var(--color-track); transition: height var(--dur-slow) var(--ease-out); }
.month-bar.target-hit { background: var(--color-green); }
.month-bar.minimum-hit { background: var(--color-blue); }
.month-bar.negative { background: var(--color-rose); }
.month-bar.future { background: var(--color-future); height: 3px; }
.month.selected .month-bar { background: linear-gradient(0deg, var(--color-blue), var(--color-cyan)); }
.month.selected .month-label { background: var(--color-accent); color: var(--color-surface); border-radius: 0; }
.month-label { margin-top: 10px; min-height: 26px; font-size: 11px; font-weight: 550; width: 100%; max-width: 48px; display: grid; place-items: center; }
.history-footer { margin-top: 17px; padding-top: 16px; border-top: 1px solid var(--color-rule); display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); }
.history-footer p { font-size: 11px; color: var(--color-muted); margin-right: auto; }
.history-footer p strong { color: var(--color-body); font-weight: 650; }
.text-button { border: 0; background: transparent; padding: 4px 0; color: var(--color-muted); font-size: 11px; white-space: nowrap; }
.text-button:hover { color: var(--color-accent); text-decoration: underline; text-underline-offset: 4px; }
.footer { display: flex; align-items: center; justify-content: space-between; gap: var(--space-lg); padding: 30px 0 24px; margin-top: 25px; border-top: 1px solid var(--color-rule); font-size: 10px; color: var(--color-muted); }
.footer > div { display: flex; align-items: center; gap: var(--space-md); }
.footer-brand { color: var(--color-ink); font-size: 16px; font-weight: 700; letter-spacing: -.6px; }
.connection { display: flex; align-items: center; gap: 7px; font-size: 10px; }
.notice { background: var(--color-amber-soft); border: 1px solid var(--color-amber); color: var(--color-amber); border-radius: 0; padding: 10px 16px; margin-bottom: 22px; font-size: 12px; }
.error-panel { padding: 60px 20px; text-align: center; }
.error-panel p { margin: 16px 0 24px; }
dialog { max-width: 560px; width: calc(100% - 36px); border: 1px solid var(--color-rule); padding: 28px; border-radius: 0; color: var(--color-ink); background: var(--color-surface); max-height: 85dvh; }
dialog::backdrop { background: var(--color-backdrop); }
.dialog-top { display: flex; justify-content: space-between; align-items: center; gap: var(--space-md); }
.dialog-top h2 { font-size: 25px; letter-spacing: -.7px; }
.dialog-lead { font-size: 13px; color: var(--color-muted); margin-top: 8px; }
dl { margin: 24px 0; }
dt { font-size: 13px; font-weight: 650; margin-top: 18px; }
dd { margin: 5px 0 0; font-size: 12px; line-height: 1.7; color: var(--color-body); }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: 24px; z-index: 20; max-width: calc(100% - 32px); width: max-content; padding: 12px 18px; border-radius: 0; background: var(--color-ink); color: var(--color-surface); box-shadow: 0 5px 20px var(--color-shadow); font-size: 13px; }
.confetti { position: fixed; top: -15px; width: 7px; height: 13px; background: var(--color-blue); z-index: 30; pointer-events: none; animation: confetti-fall 1700ms var(--ease-out) var(--delay) both; }
.confetti:nth-of-type(3n) { background: var(--color-cyan); }
.confetti:nth-of-type(3n + 1) { background: var(--color-green); }
@keyframes confetti-fall { to { transform: translate(var(--drift), 90dvh) rotate(480deg); opacity: 0; } }
[aria-busy="true"] .hero { opacity: .55; }
.screen-mode .topbar { height: auto; min-height: 72px; padding-top: 12px; padding-bottom: 12px; }
.screen-mode .history, .screen-mode .footer, .screen-mode .brand-caption { display: none; }
.screen-mode main { max-width: 1450px; padding-top: 5vh; }
.screen-mode .hero-main { padding: 50px; }
.screen-mode .amount { font-size: clamp(70px, 8vw, 130px); }
.screen-mode .progress { height: 70px; }
.screen-mode .hero-bottom { margin-top: 45px; }
@media (min-width: 1600px) { main { padding-top: 52px; } .hero-main { padding: 38px 42px; } .history-chart { height: 260px; } .month-plot { height: 220px; } }
@media (max-width: 1320px) { main { margin: 0 32px; } }
@media (max-width: 1050px) { .hero { grid-template-columns: minmax(0, 1fr) 240px; } .hero-main { padding: 28px; } .amount { letter-spacing: -3px; font-size: 66px; } .amount-row { gap: 16px; } .milestones { padding: 28px 20px; } .hero-topline { align-items: flex-start; } .hero-bottom { flex-direction: column; align-items: flex-start; gap: 8px; } .pace-section { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); } .pace-stat { padding-left: 20px; } .months { gap: 8px; } .brand-caption { display: none; } }
@media (max-width: 800px) { .topbar { padding: 0 24px; height: 76px; } main { margin: 0 24px; padding-top: 28px; } .page-heading { flex-direction: column; align-items: flex-start; gap: 16px; } .company-picker { margin-bottom: 18px; } .period-controls { width: 100%; } .period-controls .icon-button { margin-left: auto; } .hero { grid-template-columns: minmax(0, 1fr); } .amount { font-size: 80px; } .milestones { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; padding: 22px 28px; } .aside-heading, .next-step { display: none; } .hero-main { padding-bottom: 25px; } .hero-bottom { flex-direction: row; align-items: flex-end; } .pace-section { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; padding: 24px 0; } .pace-summary { grid-column: 1 / -1; } .pace-summary p { max-width: none; } .pace-stat { padding-left: 0; border-left: 0; } .pace-stat:last-child { border-left: 1px solid var(--color-rule); padding-left: 24px; } .section-heading { align-items: flex-start; } .chart-legend { justify-content: flex-start; flex-wrap: wrap; gap: 12px; } .history-chart { height: 215px; padding-right: 42px; } .month-plot { height: 175px; } .month-value { font-size: 9px; } .months { gap: 4px; padding-left: 0; } .month { padding: 0 2px; } .month-label { font-size: 10px; } .history-footer { flex-wrap: wrap; } .history-footer p { width: 100%; } .footer { align-items: flex-start; gap: 18px; flex-direction: column; } .screen-mode main { padding-top: 24px; } .screen-mode .hero-main { padding: 28px; } }
@media (max-width: 480px) { .topbar { padding: 0 18px; height: 70px; gap: 10px; } .brand { font-size: 24px; gap: 9px; } .brand img { width: 30px; height: 30px; } .header-actions { gap: 10px; } #screen { font-size: 15px; width: 34px; height: 34px; padding: 0; } #screen > span { display: none; } main { margin: 0 18px; padding-top: 24px; } h1 { font-size: 28px; letter-spacing: -1px; } .page-heading p { font-size: 12px; max-width: 30ch; } .hero { border-radius: 0; } .hero-main { padding: 23px 20px; } .hero-topline { flex-direction: column; gap: 8px; } .chip { font-size: 10px; } .amount-row { gap: 12px; align-items: flex-end; padding-top: 18px; } .amount { font-size: clamp(39px, 12vw, 56px); letter-spacing: -2.6px; } .target-caption { font-size: 10px; padding-bottom: 3px; gap: 0; flex-shrink: 0; } .target-caption .percentage { font-size: 20px; } .progress-region { padding-top: 64px; } .progress { height: 38px; border-radius: 0; } .hero-bottom { flex-direction: column; align-items: flex-start; margin-top: 22px; } .hero-bottom p { font-size: 12px; } .minimum-flag { font-size: 10px; } .minimum-flag strong { font-size: 11px; } .milestones { padding: 22px 20px; gap: 18px; } .milestone { gap: 9px; } .milestone-icon { width: 23px; height: 23px; font-size: 10px; } .milestone h2 { font-size: 11px; margin-top: 2px; } .milestone p { font-size: 10px; } .milestone strong { font-size: 11px; } .pace-stat strong { font-size: 24px; } .pace-stat > span { font-size: 10px; } .pace-summary h2 { font-size: 13px; } .pace-summary p { font-size: 10px; } .history { margin-top: 28px; } .section-heading { flex-direction: column; gap: 14px; } .section-heading h2 { font-size: 20px; max-width: 22ch; } .section-heading p { font-size: 11px; } .chart-legend { gap: 10px; font-size: 9px; margin-top: 18px; } .history-chart { padding-right: 0; height: 185px; margin-top: 36px; } .chart-line span { font-size: 8px; top: -13px; } .month-plot { height: 145px; } .month-value { display: none; } .months { gap: 3px; } .month-label { font-size: 8px; max-width: 24px; } .month { padding: 0 1px; } .month-bar { border-radius: 0; } .history-footer { margin-top: 8px; } .footer { padding-top: 20px; margin-top: 20px; } .screen-mode .amount { font-size: clamp(39px, 12vw, 56px); } .screen-mode .hero-main { padding: 23px 20px; } .screen-mode .progress { height: 42px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; } }
@media (max-width: 480px) {
  .amount-row { flex-direction: column; align-items: flex-start; gap: 6px; }
  .target-caption { flex-direction: row; align-items: center; gap: 12px; padding: 0; }
}
@media (max-width: 800px) { .milestones.single { grid-template-columns: minmax(0, 1fr); } }

/* Las marcas dan identidad; el rojo expresa una meta pendiente. */
.brand-mark { flex-shrink: 0; }
.brand-mark rect { fill: var(--color-brand-ink); }
.brand-mark path { stroke: var(--color-brand-light); }
.brand-dot { color: var(--color-brand); }
.topbar { border-top: 4px solid var(--color-brand); }
.company.active { box-shadow: inset 0 -2px var(--color-brand); }
.hero { transition: border-color 350ms, box-shadow 350ms; }
.hero-main { position: relative; }
.goal-signal { display: flex; align-items: center; gap: 14px; margin: 24px 0 2px; }
.signal-symbol { flex-shrink: 0; width: 42px; height: 42px; border: 1px solid currentColor; border-radius: 0; display: grid; place-items: center; font-size: 25px; font-weight: 650; }
.goal-signal p { font-size: 11px; margin-bottom: 4px; font-weight: 600; }
.goal-signal h2 { font-size: clamp(22px, 2.5vw, 30px); font-weight: 650; letter-spacing: -.85px; line-height: 1.22; }
.progress { height: 56px; }
.progress-fill::before { content: ''; position: absolute; inset: 0; border-radius: 0; background: repeating-linear-gradient(115deg, transparent 0, transparent 18px, var(--color-shine) 19px, var(--color-shine) 32px, transparent 33px, transparent 50px); background-size: 110px 100%; animation: bar-flow 3s linear infinite; }
.progress-fill::after { width: 4px; right: 7px; box-shadow: 0 0 10px var(--color-glint); }
.hero[data-outcome="critical"] { border-color: var(--color-danger-dark); box-shadow: 0 8px 35px var(--color-danger-glow); }
.hero[data-outcome="critical"] .hero-main { background: var(--color-critical-bg); color: var(--color-on-dark); }
.hero[data-outcome="critical"] .hero-topline,
.hero[data-outcome="critical"] .amount > span,
.hero[data-outcome="critical"] .target-caption,
.hero[data-outcome="critical"] .minimum-flag,
.hero[data-outcome="critical"] .time-note,
.hero[data-outcome="critical"] .scale { color: var(--color-on-dark-muted); }
.hero[data-outcome="critical"] .minimum-flag strong,
.hero[data-outcome="critical"] .scale > :last-child { color: var(--color-on-dark); }
.hero[data-outcome="critical"] .goal-signal { color: var(--color-on-dark); }
.hero[data-outcome="critical"] .goal-signal p { color: var(--color-on-dark-muted); }
.hero[data-outcome="critical"] .signal-symbol { background: var(--color-danger); color: var(--color-on-dark); border: 0; box-shadow: 0 0 0 7px var(--color-halo-soft); animation: alarm-breathe 3s ease-in-out infinite; }
.hero[data-outcome="critical"] .target-caption .percentage { color: var(--color-danger-bright); }
.hero[data-outcome="critical"] .chip { color: var(--color-on-dark); background: var(--color-critical-panel); border: 1px solid var(--color-danger); }
.hero[data-outcome="critical"] .minimum-flag::after { background: var(--color-on-dark-muted); }
.hero[data-outcome="critical"] .progress { background: var(--color-critical-track); }
.hero[data-outcome="critical"] .time-marker { background: var(--color-on-dark); opacity: .8; }
.hero[data-outcome="critical"] .milestones { border-left: 1px solid var(--color-danger-border); }
.hero[data-outcome="critical"] .milestone strong { color: var(--color-danger-ink); }
.hero[data-outcome="critical"] .milestone-icon { color: var(--color-danger-ink); background: var(--color-danger-soft); border-color: var(--color-danger-border); }
.hero[data-outcome="critical"] .progress-fill,
.hero[data-outcome="pending"] .progress-fill { background: linear-gradient(100deg, var(--color-danger-dark), var(--color-danger) 65%, var(--color-danger-bright)); box-shadow: 5px 0 20px var(--color-danger-glow); }
.hero[data-outcome="pending"] { border-color: var(--color-danger-border); }
.hero[data-outcome="pending"] .hero-main { background: var(--color-danger-soft); }
.hero[data-outcome="pending"] .goal-signal { color: var(--color-danger-ink); }
.hero[data-outcome="pending"] .signal-symbol { background: var(--color-danger); color: var(--color-on-dark); border-color: var(--color-danger); }
.hero[data-outcome="pending"] .percentage { color: var(--color-danger-ink); }
.hero[data-outcome="pending"] .chip { background: var(--color-surface); color: var(--color-danger-ink); }
.hero[data-outcome="pending"] .chip.success { background: var(--color-green-soft); color: var(--color-green-text); }
.hero[data-outcome="pending"] .target-caption .percentage { color: var(--color-danger-ink); }
.hero[data-outcome="success"] { border-color: var(--color-brand); box-shadow: 0 8px 35px var(--color-brand-glow); }
.hero[data-outcome="success"] .hero-main { background: var(--color-brand-ink); color: var(--color-on-dark); }
.hero[data-outcome="success"] .hero-topline,
.hero[data-outcome="success"] .amount > span,
.hero[data-outcome="success"] .target-caption,
.hero[data-outcome="success"] .minimum-flag,
.hero[data-outcome="success"] .time-note,
.hero[data-outcome="success"] .scale { color: var(--color-on-brand-muted); }
.hero[data-outcome="success"] .minimum-flag strong,
.hero[data-outcome="success"] .scale > :last-child { color: var(--color-on-dark); }
.hero[data-outcome="success"] .goal-signal p,
.hero[data-outcome="success"] .signal-symbol,
.hero[data-outcome="success"] .target-caption .percentage { color: var(--color-gold); }
.hero[data-outcome="success"] .signal-symbol { background: var(--color-halo); border-color: var(--color-gold); }
.hero[data-outcome="success"] .chip { background: var(--color-gold); color: var(--color-brand-ink); }
.hero[data-outcome="success"] .minimum-flag::after { background: var(--color-on-brand-muted); }
.hero[data-outcome="success"] .progress-fill { background: linear-gradient(100deg, var(--color-brand), var(--color-brand-light) 70%, var(--color-gold)); box-shadow: 0 0 24px var(--color-brand-glow); }
.hero[data-outcome="success"] .hero-bottom p { color: var(--color-gold); }
.victory { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 7px; padding-top: 12px; margin-top: auto; border-top: 1px solid var(--color-rule); }
.victory-medal { position: relative; display: grid; place-items: center; width: 100px; height: 100px; border-radius: 0; color: var(--color-brand-ink); background: var(--color-gold-soft); }
.victory-medal::before, .victory-medal::after { content: '✦'; position: absolute; color: var(--color-accent); font-size: 20px; animation: victory-spark 3s ease-in-out infinite; }
.victory-medal::before { top: 0; left: -7px; }
.victory-medal::after { bottom: 8px; right: -10px; animation-delay: 1.5s; }
.victory > strong { font-size: 16px; letter-spacing: -.4px; }
.victory > span { color: var(--color-muted); font-size: 11px; }
.victory-button { margin-top: 7px; background: var(--color-brand-ink); border-color: var(--color-brand-ink); color: var(--color-on-dark); font-size: 11px; }
.hero[data-outcome="success"] .next-step { display: none; }
.pace-section[data-outcome="critical"] .pace-symbol { background: var(--color-danger-soft); color: var(--color-danger-ink); }
.pace-section[data-outcome="pending"] .pace-symbol { background: var(--color-danger-soft); color: var(--color-danger-ink); }
.pace-section[data-outcome="success"] .pace-symbol { background: var(--color-gold-soft); color: var(--color-accent); }
.month-bar.goal-pending, .month-bar.negative { background: var(--color-danger); }
.month-bar.minimum-hit { background: var(--color-danger); border-top: 5px solid var(--color-success); }
.month-bar.target-hit { background: var(--color-success); }
.month.selected .month-bar { background: var(--color-danger); box-shadow: 0 0 0 3px var(--color-surface), 0 0 0 5px var(--color-ink); }
.month.selected .month-bar.target-hit { background: var(--color-success); }
.target-color { background: var(--color-success); }
.pending-color { background: var(--color-danger); }
.minimum-color { background: var(--color-danger); border-top: 3px solid var(--color-success); }

.goal-line { border-color: var(--color-success); }
.confetti { width: 8px; height: 15px; background: var(--color-brand); animation: celebration-rain 3100ms var(--ease-out) var(--delay) both; }
.confetti:nth-of-type(3n) { background: var(--color-gold); border-radius: 0; }
.confetti:nth-of-type(3n + 1) { background: var(--color-brand-light); }
@keyframes bar-flow { to { background-position: 110px 0; } }
@keyframes alarm-breathe { 50% { box-shadow: 0 0 0 12px var(--color-halo-soft), 0 0 25px var(--color-danger-glow); } }
@keyframes victory-spark { 50% { transform: translateY(-5px) rotate(30deg); } }
@keyframes celebration-rain { 0% { transform: translateY(-20px) rotate(0); opacity: 0; } 8% { opacity: 1; } 85% { opacity: 1; } 100% { transform: translate(var(--drift), 105dvh) rotate(var(--rotation)); opacity: 0; } }
@media (max-width: 800px) {
  .hero[data-outcome="critical"] .milestones { border-left: 0; }
  .victory { grid-column: 1 / -1; padding-top: 20px; }
  .victory-medal { width: 86px; height: 86px; }
}
@media (max-width: 480px) {
  .brand-mark { width: 30px; height: 30px; }
  .goal-signal { margin-top: 20px; gap: 10px; align-items: flex-start; }
  .signal-symbol { width: 30px; height: 30px; font-size: 19px; margin-top: 2px; }
  .goal-signal p { font-size: 10px; }
  .goal-signal h2 { font-size: 23px; letter-spacing: -.6px; }
  .progress { height: 45px; }
  .hero[data-outcome="critical"] .chip { white-space: normal; }
  .victory-button { font-size: 11px; }
}

/* Un único lenguaje de progreso para las dos compañías. */
.brand { font-size: 24px; letter-spacing: -1px; white-space: nowrap; font-weight: 450; }
.brand strong { font-weight: 750; }
.hero { box-shadow: none; }
.hero[data-outcome="critical"] { box-shadow: 0 6px 25px var(--color-danger-glow); }
.hero[data-outcome="success"] { border-color: var(--color-success); box-shadow: 0 6px 25px var(--color-success-glow); }
.hero[data-outcome="success"] .hero-main { background: var(--color-success-dark); }
.hero[data-outcome="success"] .hero-topline,
.hero[data-outcome="success"] .amount > span,
.hero[data-outcome="success"] .target-caption,
.hero[data-outcome="success"] .minimum-flag,
.hero[data-outcome="success"] .time-note,
.hero[data-outcome="success"] .scale { color: var(--color-success-muted); }
.hero[data-outcome="success"] .progress-fill { background: linear-gradient(100deg, var(--color-success), var(--color-success-light)); box-shadow: 0 0 24px var(--color-success-glow); }
.confetti, .confetti:nth-of-type(3n + 1) { background: var(--color-success-light); }
.percentage-view .amount { font-size: clamp(80px, 8vw, 128px); line-height: 1.06; letter-spacing: -5px; }
.percentage-view .target-caption .percentage { font-size: 18px; }
.percentage-view .hero-bottom p { max-width: 390px; }
.view-label { color: var(--color-accent); border-left: 1px solid var(--color-rule); padding-left: 16px; }
.login-panel { max-width: 580px; margin: 55px auto 90px; border-top: 4px solid var(--color-brand); padding-top: 30px; }
.login-kicker { color: var(--color-accent); font-size: 13px; }
.login-panel h1 { margin-top: 14px; }
.login-panel p { color: var(--color-body); margin: 16px 0; }
.login-panel form { display: grid; gap: 12px; margin: 26px 0; }
.login-panel label, .access-form label { font-size: 12px; font-weight: 650; }
.login-note { font-size: 12px; }
input, .access-form select { width: 100%; min-width: 0; border: 1px solid var(--color-rule); background: var(--color-surface); color: var(--color-ink); padding: 11px 12px; border-radius: 0; font: inherit; font-size: 13px; }
input:focus-visible, .access-form select:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
#access-dialog { max-width: 620px; }
#access-dialog h3 { margin: 26px 0 12px; font-size: 14px; }
#access-dialog .notice { margin: 20px 0; font-size: 11px; }
.access-form { display: grid; gap: 9px; margin-top: 22px; }
.access-form label:not(:first-child) { margin-top: 7px; }
.access-form button { margin-top: 12px; }
.new-access { padding: 18px; border: 1px solid var(--color-success); background: var(--color-green-soft); margin-top: 24px; }
.new-access p { font-size: 12px; margin: 6px 0 12px; color: var(--color-body); }
.access-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.access-error { color: var(--color-danger-ink); font-size: 12px; margin-top: 15px; }
.access-entry { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 15px 0; border-top: 1px solid var(--color-rule); }
.access-entry > div { min-width: 0; }
.access-entry strong { display: block; font-size: 13px; overflow-wrap: anywhere; }
.access-entry span, .access-list > p { font-size: 11px; color: var(--color-muted); }
.access-entry .button { flex-shrink: 0; font-size: 11px; }
@media (max-width: 1050px) { .brand { font-size: 22px; } .header-actions { gap: 9px; } .header-actions .button { font-size: 11px; padding: 8px 10px; } }
@media (max-width: 800px) {
  .topbar { flex-wrap: wrap; height: auto; min-height: 76px; padding-top: 14px; padding-bottom: 14px; gap: 13px; }
  .header-actions { width: 100%; justify-content: flex-end; }
  .percentage-view .amount { font-size: 100px; }
}
@media (max-width: 480px) {
  .brand { font-size: 23px; }
  .header-actions { justify-content: space-between; gap: 7px; }
  .header-actions .button { font-size: 10px; padding: 7px 8px; }
  .percentage-view .amount { font-size: clamp(62px, 17vw, 88px); letter-spacing: -3px; }
  .percentage-view .target-caption .percentage { font-size: 14px; }
  .footer > div { flex-wrap: wrap; }
  .view-label { padding-left: 10px; }
  .access-actions { flex-direction: column; }
  .login-panel { margin-top: 28px; }
}

/* Compañías como navegación principal, sin cápsulas ni tarjetas pequeñas. */
.brand { font-weight: 750; letter-spacing: -.8px; }
.button { text-decoration: none; }
.company-navigation { border-bottom: 1px solid var(--color-rule); margin-bottom: 28px; }
.company-picker { display: flex; width: 100%; padding: 0; margin: 0; gap: 32px; border: 0; background: transparent; }
.company-picker .company { position: relative; min-width: 170px; padding: 15px 10px 17px; border-bottom: 4px solid transparent; font-size: 20px; line-height: 1.3; font-weight: 550; color: var(--color-muted); background: transparent; }
.company-picker .company.active { border-bottom-color: var(--color-ink); color: var(--color-ink); background: transparent; box-shadow: none; font-weight: 750; }
.company-picker .company:hover { color: var(--color-ink); background: var(--color-ink-soft); }
.page-heading { margin-bottom: 26px; }
.page-heading p, .section-heading p { font-size: 15px; }
.hero-topline, .goal-signal p, .aside-heading, .milestone p, .next-step, .time-note, .scale, .pace-summary p, .pace-stat > span, .pace-stat small, .history-footer p, .text-button, .footer, .connection { font-size: 13px; }
.milestone h2, .milestone strong { font-size: 15px; }
.chip { font-size: 12px; padding: 7px 11px; }
.chart-legend { font-size: 12px; gap: 20px; }
.month-value { font-size: 12px; font-weight: 650; }
.month-label { font-size: 12px; }
.chart-line span { font-size: 11px; }
.target-caption { font-size: 15px; }
.minimum-flag { font-size: 12px; }
.minimum-flag strong { font-size: 14px; }
.victory > span { font-size: 13px; }
.notice, dd { font-size: 14px; }
.year-select select, dt { font-size: 14px; }
.footer > div { flex-wrap: wrap; }
.admin-page main { padding-bottom: 60px; }
.admin-page .header-actions { width: auto; }
.admin-login-panel { max-width: 510px; margin: 36px auto 70px; border-top: 4px solid var(--color-ink); padding-top: 28px; }
.admin-eyebrow { font-size: 14px; font-weight: 650; color: var(--color-accent); margin-bottom: 12px; }
.admin-login-panel h1 { font-size: 38px; margin-bottom: 18px; }
.admin-intro, .admin-help { color: var(--color-body); font-size: 16px; line-height: 1.65; }
.admin-help { font-size: 14px; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--color-rule); }
.admin-page .access-form { gap: 11px; }
.admin-page .access-form label, .admin-page input, .admin-page select, .admin-page .button { font-size: 15px; }
.admin-page .access-form input, .admin-page .access-form select { padding: 13px 12px; }
.admin-page .access-form button { padding: 13px; }
.admin-heading { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-bottom: 28px; }
.admin-heading > div > p:last-child { font-size: 16px; color: var(--color-body); }
.admin-status { padding: 9px 12px; border: 1px solid var(--color-rule); font-size: 14px; white-space: nowrap; }
.admin-layout { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.3fr); gap: 64px; }
.admin-layout h2 { font-size: 23px; margin-bottom: 12px; }
.admin-create { padding-right: 36px; border-right: 1px solid var(--color-rule); }
.admin-existing > p, .access-empty { font-size: 15px; line-height: 1.65; color: var(--color-body); margin-bottom: 22px; }
.admin-page .access-entry strong { font-size: 16px; }
.admin-page .access-entry span { font-size: 14px; }
.admin-page .access-entry .button { font-size: 13px; }
.inactive-accesses { margin-top: 25px; padding-top: 20px; border-top: 1px solid var(--color-rule); }
.inactive-accesses summary { cursor: pointer; font-size: 14px; color: var(--color-body); }
.admin-page .new-access p, .admin-page .access-error { font-size: 14px; }
.admin-page .new-access .button { margin-top: 12px; }
@media (max-width: 800px) {
  .admin-layout { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .admin-create { padding: 0 0 30px; border-right: 0; border-bottom: 1px solid var(--color-rule); }
  .admin-heading { flex-direction: column; align-items: flex-start; }
  .company-picker { gap: 10px; }
  .company-picker .company { flex: 1; min-width: 0; font-size: 19px; }
}
@media (max-width: 480px) {
  .company-picker .company { font-size: 17px; padding: 13px 6px 15px; }
  .company-navigation { margin-bottom: 23px; }
  .hero-topline, .goal-signal p, .milestone p, .time-note, .scale, .pace-summary p, .pace-stat > span, .pace-stat small, .history-footer p { font-size: 12px; }
  .milestone h2, .milestone strong { font-size: 13px; }
  .month-label { font-size: 10.5px; }
  .minimum-flag { font-size: 11px; }
  .minimum-flag strong { font-size: 12px; }
  .chart-legend { font-size: 11px; }
  .admin-login-panel { margin-top: 18px; }
  .admin-login-panel h1 { font-size: 31px; }
  .admin-page .header-actions .button { font-size: 12px; }
}

/* Una medida común para enlaces y botones de la barra superior. */
.topbar .header-actions .button, .topbar #screen, .topbar #info {
  width: 100%; height: 40px; min-width: 0; padding: 0 12px;
  font-size: 13px; line-height: 20px; font-weight: 600;
}
.topbar #screen > span { display: inline; }
.topbar #screen { gap: 7px; }
.history-detail { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; border-top: 1px solid var(--color-rule); padding-top: 22px; margin-top: 18px; }
.history-detail > div { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.history-detail span { font-size: 13px; color: var(--color-muted); }
.history-detail strong { font-size: clamp(18px, 2vw, 25px); color: var(--color-ink); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.history-detail small { font-size: 12px; line-height: 1.45; color: var(--color-muted); }
.history-insight { margin-top: 22px; font-size: 14px; color: var(--color-body); line-height: 1.65; }
@media (max-width: 800px) {
  .history-detail { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 16px; }
  .history-detail strong { font-size: 21px; }
}
.access-duration-help { font-size: 13px; line-height: 1.55; color: var(--color-muted); }
.drafts { margin-top: 24px; padding-top: 18px; border-top: 1px solid currentColor; }
.drafts-heading { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 8px 16px; }
.drafts-heading h2 { font-family: var(--font-body); font-size: 14px; font-weight: 600; }
.drafts-heading strong { font-size: 15px; font-variant-numeric: tabular-nums; }
.drafts-progress { height: 14px; background: var(--color-track); margin: 12px 0; overflow: hidden; }
.drafts-fill { position: relative; overflow: hidden; height: 100%; width: 0; background: repeating-linear-gradient(115deg, var(--color-amber) 0 9px, var(--color-gold) 9px 14px); background-size: 56px 100%; animation: draft-stripes 2.4s linear infinite; transition: width var(--dur-slow) var(--ease-out); }
.drafts-fill::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(110deg, transparent 35%, var(--color-glint) 50%, transparent 65%); transform: translateX(-100%); animation: draft-shine 4.2s ease-in-out infinite; }
@keyframes draft-stripes { to { background-position: 56px 0; } }
@keyframes draft-shine { 0%, 15% { transform: translateX(-100%); } 70%, 100% { transform: translateX(100%); } }
.drafts-projection { font-size: 14px; line-height: 1.5; }
.drafts-note { font-size: 12px; line-height: 1.5; margin-top: 5px; }
.hero[data-outcome="critical"] .drafts, .hero[data-outcome="success"] .drafts { border-color: var(--color-halo); }
.hero[data-outcome="critical"] .drafts-progress, .hero[data-outcome="success"] .drafts-progress { background: var(--color-halo); }
.hero[data-outcome="critical"] .drafts-heading, .hero[data-outcome="success"] .drafts-heading { color: var(--color-gold); }
.hero[data-outcome="critical"] .drafts-note { color: var(--color-on-dark-muted); }
.hero[data-outcome="success"] .drafts-note { color: var(--color-success-muted); }
@media (max-width: 1160px) {
  .topbar { flex-wrap: wrap; height: auto; min-height: 76px; padding-top: 14px; padding-bottom: 14px; gap: 13px; }
  .topbar .header-actions { width: 100%; grid-auto-columns: minmax(0, 1fr); }
}
@media (max-width: 600px) {
  .topbar .header-actions { grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
