/* =========================================================
   FOKUS · Estructura de la app y pantallas
   ========================================================= */

/* ---------- Shell ---------- */
.app { display: grid; grid-template-columns: var(--sidebar-w) 1fr; height: 100vh; }

.sidebar {
  display: flex; flex-direction: column; gap: 4px; padding: 18px 14px 16px;
  background: var(--bg); border-right: 1px solid var(--line-soft);
  -webkit-app-region: drag;
}
.sidebar > * { -webkit-app-region: no-drag; }
.brand { display: flex; align-items: center; gap: 10px; padding: 6px 10px 22px; -webkit-app-region: drag; }
.brand svg { width: 30px; height: 30px; flex: none; }
.brand-word { font-weight: 700; letter-spacing: .16em; font-size: 15px; }
.mac .brand { padding-top: 34px; }

.nav { display: grid; gap: 2px; }
.nav-label { padding: 18px 12px 6px; }
.nav a {
  display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 12px;
  border-radius: 11px; color: var(--ink-2); text-decoration: none; font-weight: 540;
  transition: background var(--t-fast), color var(--t-fast);
}
.nav a svg { width: 19px; height: 19px; flex: none; }
.nav a:hover { background: var(--surface-3); color: var(--ink); }
.nav a.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-xs), 0 0 0 1px var(--line-soft); }
.nav a.on svg { color: var(--brand-text); }
.nav a .count { margin-left: auto; font-size: var(--fs-xs); font-weight: 600; color: var(--ink-2); background: var(--surface-3); border-radius: 6px; padding: 1px 7px; }
.nav a.on .count { background: var(--brand-soft); color: var(--brand-ink); }

.focus-cta {
  margin-top: auto; display: grid; gap: 10px; padding: 16px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line-soft); box-shadow: var(--shadow-sm);
}
.focus-cta .mini-timer { font-size: 26px; font-weight: 650; letter-spacing: -.02em; }
.focus-cta .t-meta { margin-top: -6px; }
.focus-cta.running { background: linear-gradient(160deg, var(--violet-500), var(--violet-700)); color: #fff; border-color: transparent; box-shadow: var(--shadow-brand); }
.focus-cta.running .t-meta, .focus-cta.running .t-eyebrow { color: rgba(255,255,255,.8); }
.focus-cta.running .btn { background: rgba(255,255,255,.16); color: #fff; }

.focus-cta[hidden] + .profile { margin-top: auto; }
.profile { display: flex; align-items: center; gap: 10px; padding: 10px; margin-top: 10px; border-radius: 12px; border: 0; background: transparent; text-align: left; width: 100%; }
.profile:hover { background: var(--surface-3); }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand-tint); color: var(--brand-ink); display: grid; place-items: center; font-weight: 650; flex: none; }
.profile b { display: block; font-weight: 600; font-size: var(--fs-md); line-height: 1.2; }

.m-logo { display: none; }
.main { display: flex; flex-direction: column; min-width: 0; height: 100vh; }
.topbar {
  height: var(--topbar-h); flex: none; display: flex; align-items: center; gap: 16px;
  padding: 0 calc(var(--titlebar-safe) + 8px) 0 32px; -webkit-app-region: drag;
}
.topbar > * { -webkit-app-region: no-drag; }
.mac .topbar { padding-right: 32px; }
.search { position: relative; width: min(420px, 40vw); }
.search svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: var(--ink-3); }
.search .input { padding-left: 40px; height: 40px; background: var(--surface); border-color: var(--line-soft); box-shadow: var(--shadow-xs); }
.search kbd { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font: 600 11px var(--font-ui); color: var(--ink-3); border: 1px solid var(--line); border-radius: 6px; padding: 2px 6px; background: var(--surface-2); }
.search-results {
  position: absolute; top: 46px; left: 0; right: 0; z-index: 30; background: var(--surface); border-radius: var(--r-md);
  box-shadow: var(--shadow-lg); border: 1px solid var(--line-soft); padding: 6px; max-height: 420px; overflow: auto;
}
.search-results button { display: flex; width: 100%; align-items: center; gap: 12px; padding: 10px; border: 0; background: none; border-radius: 10px; text-align: left; }
.search-results button:hover, .search-results button.on { background: var(--brand-soft); }
.search-results svg { position: static; transform: none; color: var(--ink-2); }
.search-results .t-meta { margin-left: auto; }
.topbar .today { margin-left: auto; color: var(--ink-2); font-weight: 540; white-space: nowrap; }

.view { flex: 1; overflow: auto; padding: 8px 32px 40px; animation: viewIn var(--t-slow) var(--ease); display: flex; flex-direction: column; }
.view > div { flex: 1; display: flex; flex-direction: column; }
.view > div > * { flex: none; }
.view > div > .focus-screen { flex: 1; }
@keyframes viewIn { from { opacity: 0; transform: translateY(6px); } }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin: 8px 0 24px; }
.page-head h1 { margin: 0; }
.page-head p { margin: 6px 0 0; }
.page-actions { display: flex; gap: 8px; align-items: center; }

/* ---------- Inicio ---------- */
.hello { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 24px; margin: 8px 0 28px; }
.hello h1 { margin: 0; }
.hello h1 em { font-style: italic; color: var(--brand-text); }
.hello p { margin: 8px 0 0; font-size: var(--fs-lg); color: var(--ink-2); }
.hello .t-quote { max-width: 300px; font-size: 17px; line-height: 1.4; text-align: right; margin: 0; }

.kpis { display: grid; grid-template-columns: 1.25fr 1fr 1fr 1fr; gap: 16px; margin-bottom: 20px; }
.kpi { display: flex; align-items: center; gap: 14px; padding: 18px 20px; }
.kpi .ico { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-text); flex: none; }
.kpi .ico svg { width: 21px; height: 21px; }
.kpi b { display: block; font-size: var(--fs-lg); font-weight: 620; letter-spacing: -.01em; line-height: 1.25; }
.kpi .t-meta { line-height: 1.3; }
.kpi .bar { margin-top: 8px; width: 120px; }
.kpi-focus {
  border: 0; text-align: left; cursor: pointer; color: #fff;
  background: radial-gradient(120% 140% at 0% 0%, var(--violet-400), var(--violet-500) 45%, var(--violet-700));
  box-shadow: var(--shadow-brand); transition: transform var(--t-base) var(--ease), box-shadow var(--t-base);
}
.kpi-focus:hover { transform: translateY(-2px); }
.kpi-focus .ico { background: rgba(255,255,255,.18); color: #fff; }
.kpi-focus .t-meta { color: rgba(255,255,255,.82); }
.kpi-focus .play { margin-left: auto; width: 40px; height: 40px; border-radius: 50%; background: #fff; color: var(--brand); display: grid; place-items: center; flex: none; }
.kpi-focus .play svg { width: 16px; height: 16px; margin-left: 2px; }

.home-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 20px; align-items: start; }
.home-col { display: grid; gap: 20px; }

/* Agenda del día (línea temporal) */
.agenda { display: grid; gap: 4px; }
.agenda-item { display: grid; grid-template-columns: 58px 1fr; gap: 14px; align-items: stretch; }
.agenda-time { color: var(--ink-2); font-size: var(--fs-sm); font-weight: 560; padding-top: 12px; text-align: right; }
.agenda-card { border-radius: var(--r-md); padding: 11px 14px; background: var(--sbg); color: var(--sink); border-left: 3px solid var(--sdot); }
.agenda-card b { display: block; font-weight: 600; }
.agenda-card span { font-size: var(--fs-sm); opacity: .9; }
.agenda-now { display: grid; grid-template-columns: 58px 1fr; gap: 14px; align-items: center; margin: 4px 0; }
.agenda-now span { text-align: right; font-size: var(--fs-xs); font-weight: 700; color: var(--brand-text); letter-spacing: .04em; }
.agenda-now i { height: 2px; background: var(--brand); border-radius: 2px; position: relative; }
.agenda-now i::before { content: ''; position: absolute; left: -4px; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }

.reminder { display: flex; align-items: center; gap: 12px; padding: 10px 4px; }
.reminder + .reminder { border-top: 1px solid var(--line-soft); }
.reminder .when { margin-left: auto; color: var(--ink-2); font-size: var(--fs-sm); white-space: nowrap; }
.reminder .when.late { color: var(--danger); font-weight: 560; }

.next-up { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: var(--r-md); background: var(--sbg); color: var(--sink); }
.next-up .date-tile { width: 52px; height: 56px; border-radius: 12px; background: var(--surface); display: grid; place-items: center; align-content: center; color: var(--ink); box-shadow: var(--shadow-xs); flex: none; }
.next-up .date-tile b { font-size: 20px; line-height: 1; }
.next-up .date-tile small { font-size: 11px; font-weight: 600; text-transform: uppercase; color: var(--ink-2); letter-spacing: .06em; }

/* ---------- Tareas ---------- */
.toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar .select { width: auto; height: 38px; }
.quick-add { display: flex; gap: 10px; align-items: center; padding: 6px 6px 6px 16px; border-radius: var(--r-md); background: var(--surface-2); border: 1px dashed var(--line); margin-bottom: 8px; }
.quick-add input { flex: 1; border: 0; background: transparent; outline: none; height: 36px; user-select: text; }
.quick-add svg { width: 18px; height: 18px; color: var(--brand-text); }
.group-label { margin: 18px 10px 4px; }

/* ---------- Calendario ---------- */
.cal { padding: 0; overflow: hidden; }
.cal-head { display: grid; grid-template-columns: 64px repeat(7, 1fr); border-bottom: 1px solid var(--line-soft); position: sticky; top: 0; background: var(--surface); z-index: 2; }
.cal-day { text-align: center; padding: 14px 0 12px; }
.cal-day small { display: block; font-size: var(--fs-sm); color: var(--ink-2); font-weight: 540; }
.cal-day b { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; font-size: 17px; font-weight: 620; margin-top: 2px; }
.cal-day.today b { background: var(--brand); color: #fff; }
.cal-body { display: grid; grid-template-columns: 64px repeat(7, 1fr); position: relative; overflow: auto; max-height: calc(100vh - 250px); }
.cal-hours div:first-child { transform: none; }
.cal-hours div { height: 56px; font-size: var(--fs-xs); color: var(--ink-2); text-align: right; padding-right: 10px; transform: translateY(-7px); }
.cal-col { position: relative; border-left: 1px solid var(--line-soft); background-image: linear-gradient(var(--line-soft) 1px, transparent 1px); background-size: 100% 56px; cursor: copy; }
.cal-col.today { background-color: rgba(109, 92, 232, .025); }
.cal-ev {
  position: absolute; left: 4px; right: 4px; border-radius: 10px; padding: 6px 8px; overflow: hidden; cursor: pointer;
  background: var(--sbg); color: var(--sink); border-left: 3px solid var(--sdot); font-size: var(--fs-sm); line-height: 1.25;
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-fast);
}
.cal-ev:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); z-index: 1; }
.cal-ev b { display: block; font-weight: 600; }
.cal-ev.exam { box-shadow: inset 0 0 0 1.5px var(--sdot); }
.cal-now { position: absolute; left: 0; right: 0; height: 2px; background: var(--brand); z-index: 1; pointer-events: none; }
.cal-now::before { content: ''; position: absolute; left: -4px; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); }

.month { display: grid; grid-template-columns: repeat(7, 1fr); }
.month-dow { padding: 12px; font-size: var(--fs-sm); font-weight: 560; color: var(--ink-2); border-bottom: 1px solid var(--line-soft); }
.month-cell { min-height: 108px; padding: 8px; border-right: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); cursor: copy; display: grid; align-content: start; gap: 4px; }
.month-cell:nth-child(7n) { border-right: 0; }
.month-cell.out { background: var(--surface-2); color: var(--ink-3); }
.month-cell .d { font-weight: 600; font-size: var(--fs-sm); width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; }
.month-cell.today .d { background: var(--brand); color: #fff; }
.month-ev { font-size: 12px; font-weight: 560; padding: 2px 6px; border-radius: 6px; background: var(--sbg); color: var(--sink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: pointer; }

/* ---------- Asignaturas ---------- */
.subjects { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.subject-card { padding: 0; overflow: hidden; cursor: pointer; transition: transform var(--t-base) var(--ease), box-shadow var(--t-base); }
.subject-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.subject-art { height: 112px; position: relative; overflow: hidden; background: var(--sbg); }
.subject-art::before, .subject-art::after { content: ''; position: absolute; border-radius: 50%; }
.subject-art::before { width: 180px; height: 180px; right: -40px; top: -70px; background: radial-gradient(circle at 30% 30%, var(--art-hi), var(--sdot) 70%); opacity: .75; }
.subject-art::after { width: 120px; height: 120px; left: -30px; bottom: -60px; background: radial-gradient(circle at 60% 40%, var(--art-hi), var(--sdot)); opacity: .5; }
.subject-art .initial { position: absolute; left: 18px; bottom: 14px; z-index: 1; font-family: var(--font-display); font-size: 40px; font-weight: 500; color: var(--sink); line-height: 1; }
.subject-body { padding: 16px 18px 18px; }
.subject-body .t-h3 { margin: 0 0 2px; }
.subject-body .bar { margin-top: 14px; }
.subject-body .bar > i { background: var(--sink); opacity: .75; }
.subject-stats { display: flex; justify-content: space-between; margin-top: 8px; font-size: var(--fs-sm); color: var(--ink-2); }
.subject-new { display: grid; place-items: center; align-content: center; gap: 10px; min-height: 236px; border: 1.5px dashed var(--line); background: transparent; box-shadow: none; color: var(--ink-2); font-weight: 560; }
.subject-new:hover { border-color: var(--violet-300); color: var(--brand-text); background: var(--surface); }
.subject-new svg { width: 26px; height: 26px; }

/* ---------- Archivos ---------- */
.files { padding: 8px; }
.file-row { display: grid; grid-template-columns: 40px minmax(0, 1fr) 160px 90px 110px 96px; align-items: center; gap: 14px; padding: 10px 12px; border-radius: var(--r-md); }
.file-row:hover { background: var(--surface-2); }
.file-row.head { color: var(--ink-2); font-size: var(--fs-sm); font-weight: 560; }
.file-row.head:hover { background: none; }
.file-ico { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: var(--surface-3); color: var(--ink-2); font-size: 10px; font-weight: 750; letter-spacing: .04em; }
.file-ico.pdf { background: var(--fi-pdf-bg); color: var(--fi-pdf-ink); }
.file-ico.doc { background: var(--fi-doc-bg); color: var(--fi-doc-ink); }
.file-ico.img { background: var(--fi-img-bg); color: var(--fi-img-ink); }
.file-ico.sheet { background: var(--fi-sheet-bg); color: var(--fi-sheet-ink); }
.file-ico.slide { background: var(--fi-slide-bg); color: var(--fi-slide-ink); }
.file-name { font-weight: 560; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.file-name:hover { color: var(--brand-text); }
.file-row .actions { display: flex; justify-content: flex-end; gap: 2px; opacity: 0; }
.file-row:hover .actions { opacity: 1; }
.drop-hint { margin-top: 12px; padding: 16px; border-radius: var(--r-md); text-align: center; color: var(--ink-2); font-size: var(--fs-sm); }

/* ---------- Concentración ---------- */
.focus-screen {
  position: relative; min-height: 100%; margin: -8px -32px -40px; padding: 28px 32px 40px;
  display: grid; grid-template-rows: auto 1fr auto; overflow: hidden;
  background:
    radial-gradient(60% 50% at 18% 12%, var(--calm-1), transparent 70%),
    radial-gradient(50% 45% at 85% 20%, var(--calm-2), transparent 70%),
    radial-gradient(70% 60% at 50% 110%, var(--calm-3), transparent 70%),
    var(--bg);
}
.focus-screen::before { /* horizonte suave: el "entorno calmado" */
  content: ''; position: absolute; left: -10%; right: -10%; bottom: -38%; height: 70%;
  border-radius: 50%; background: linear-gradient(180deg, var(--horizon), transparent);
  pointer-events: none;
}
.focus-top { display: flex; justify-content: center; position: relative; z-index: 3; margin-bottom: 16px; }
.focus-center { display: grid; place-items: center; align-content: center; gap: 22px; position: relative; z-index: 1; }
.focus-subject { display: grid; justify-items: center; gap: 4px; }
.focus-subject .select { width: auto; min-width: 200px; text-align: center; border: 0; background-color: transparent; font-size: var(--fs-xl); font-weight: 620; height: 40px; letter-spacing: -.01em; }
.ring { position: relative; width: 340px; height: 340px; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.ring .track { stroke: var(--ring-track); }
/* Sin filtros ni transición continua: el anillo solo se repinta una vez por segundo */
.ring .prog { stroke: url(#ringGrad); stroke-linecap: round; }
.ring .face { position: absolute; inset: 34px; border-radius: 50%; background: var(--glass); box-shadow: var(--shadow-md), inset 0 0 0 1px var(--glass-edge); display: grid; place-items: center; align-content: center; gap: 4px; }
.ring .time { font-size: var(--fs-timer); font-weight: 300; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.ring .phase { color: var(--ink-2); font-weight: 560; letter-spacing: .02em; }
.ring .cycles { display: flex; gap: 6px; margin-top: 10px; }
.ring .cycles i { width: 7px; height: 7px; border-radius: 50%; background: var(--violet-200); }
.ring .cycles i.on { background: var(--brand); }
.focus-controls { display: flex; align-items: center; gap: 22px; }
.round-btn { width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--glass); color: var(--ink); display: grid; place-items: center; box-shadow: var(--shadow-sm); transition: transform var(--t-fast) var(--ease-spring), background var(--t-fast); }
.round-btn:hover { background: var(--glass-hover); transform: scale(1.05); }
.round-btn svg { width: 20px; height: 20px; }
.play-btn { width: 76px; height: 76px; border-radius: 50%; border: 0; background: var(--brand); color: #fff; display: grid; place-items: center; box-shadow: var(--shadow-brand); transition: transform var(--t-fast) var(--ease-spring), background var(--t-fast); }
.play-btn:hover { background: var(--brand-hover); transform: scale(1.05); }
.play-btn:active { transform: scale(.96); }
.play-btn svg { width: 28px; height: 28px; }
.play-btn .i-play { margin-left: 4px; }
.focus-side { position: absolute; right: 32px; top: 50%; transform: translateY(-50%); display: grid; gap: 10px; z-index: 2; width: 210px; }
.side-card { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r-md); background: var(--glass); box-shadow: var(--shadow-sm); border: 1px solid var(--glass-edge); }
.side-card svg { width: 18px; height: 18px; color: var(--brand-text); flex: none; }
.side-card b { display: block; font-size: var(--fs-sm); font-weight: 600; line-height: 1.25; }
.side-card span { font-size: var(--fs-sm); color: var(--ink-2); }
.side-card .switch { margin-left: auto; }
.side-card.dim { opacity: .7; }
.focus-bottom { text-align: center; position: relative; z-index: 1; }
.focus-bottom .t-quote { font-size: 18px; margin: 0; }
.focus-custom { display: flex; gap: 10px; align-items: center; justify-content: center; }
.focus-custom .input { width: 76px; text-align: center; height: 36px; }
.zen .sidebar, .zen .topbar { display: none; }
.zen .app { grid-template-columns: 1fr; }
.zen .focus-screen { -webkit-app-region: drag; }
.zen .focus-screen button, .zen .focus-screen select, .zen .focus-screen input { -webkit-app-region: no-drag; }

/* ---------- Estadísticas ---------- */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.stat b { display: block; font-size: 30px; font-weight: 650; letter-spacing: -.03em; line-height: 1.1; margin-top: 6px; }
.chart-row { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; }
.bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 14px; height: 220px; align-items: end; padding-top: 24px; border-bottom: 1px solid var(--line); position: relative; }
.bars .col { position: relative; height: 100%; display: flex; align-items: flex-end; justify-content: center; cursor: default; }
.bars .col i { width: min(36px, 70%); background: var(--brand); border-radius: 4px 4px 0 0; min-height: 0; transition: height var(--t-slow) var(--ease), background var(--t-fast); }
.bars .col.today i { background: var(--violet-700); }
.bars .col:hover i { background: var(--violet-600); }
.bars .col .val { position: absolute; bottom: calc(var(--h) + 6px); font-size: var(--fs-sm); font-weight: 600; color: var(--ink); opacity: 0; transition: opacity var(--t-fast); white-space: nowrap; }
.bars .col:hover .val, .bars .col.today .val { opacity: 1; }
.bars-x { display: grid; grid-template-columns: repeat(7, 1fr); gap: 14px; margin-top: 8px; text-align: center; font-size: var(--fs-sm); color: var(--ink-2); }
.hbar { display: grid; grid-template-columns: 130px 1fr 64px; gap: 12px; align-items: center; padding: 8px 0; }
.hbar .name { display: flex; align-items: center; gap: 8px; font-weight: 540; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.hbar .name .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--sdot); flex: none; }
.hbar .track { height: 10px; background: var(--surface-3); border-radius: 5px; overflow: hidden; }
.hbar .track i { display: block; height: 100%; background: var(--brand); border-radius: 0 4px 4px 0; }
.hbar .v { text-align: right; font-size: var(--fs-sm); color: var(--ink-2); font-variant-numeric: tabular-nums; }

/* ---------- Ajustes ---------- */
.settings { display: grid; gap: 20px; max-width: 760px; }
.set-row { display: flex; align-items: center; gap: 16px; padding: 14px 0; }
.set-row + .set-row { border-top: 1px solid var(--line-soft); }
.set-row > div:first-child { flex: 1; }
.set-row b { display: block; font-weight: 580; }
.set-row .input { width: 90px; text-align: center; }

/* ---------- Onboarding ---------- */
.onboard { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; background:
    radial-gradient(50% 50% at 20% 10%, var(--calm-1), transparent 70%),
    radial-gradient(40% 40% at 90% 90%, var(--calm-2), transparent 70%), var(--bg); -webkit-app-region: drag; }
.onboard-card { width: min(460px, calc(100vw - 48px)); text-align: center; display: grid; justify-items: center; gap: 14px; -webkit-app-region: no-drag; animation: rise var(--t-slow) var(--ease); }
.onboard-card .logo { width: 76px; height: 76px; filter: drop-shadow(0 18px 30px rgba(109, 92, 232, .35)); }
.onboard-card h1 { margin: 6px 0 0; }
.onboard-card .slogan { font-family: var(--font-display); font-style: italic; font-size: 22px; color: var(--brand-text); margin: -6px 0 6px; }
.onboard-card form { display: grid; gap: 12px; width: 100%; margin-top: 8px; }
.onboard-card .input { height: 50px; font-size: var(--fs-lg); text-align: center; border-radius: var(--r-md); }

@media (max-width: 1180px) {
  .kpis { grid-template-columns: 1fr 1fr; }
  .home-grid, .chart-row { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .focus-side { position: static; transform: none; width: auto; grid-auto-flow: column; justify-content: center; margin-top: 8px; }
  .hello { grid-template-columns: 1fr; }
  .hello .t-quote { text-align: left; }
  .file-row { grid-template-columns: 40px minmax(0, 1fr) 140px 96px; }
  .file-row > :nth-child(4), .file-row > :nth-child(5) { display: none; }
}

/* ---------- Permiso de archivos ---------- */
.perm-banner { display: flex; align-items: center; gap: 14px; padding: 16px 18px; margin-bottom: 16px; }
.perm-banner > svg { width: 22px; height: 22px; color: var(--brand-text); flex: none; }
.perm-banner > div { flex: 1; display: grid; gap: 2px; }
.drop-hint { display: flex; align-items: center; justify-content: center; gap: 8px; }
.drop-hint svg { width: 16px; height: 16px; }

/* Capa al arrastrar archivos sobre la ventana */
body.dropping::after {
  content: 'Suelta para añadir a FOKUS'; position: fixed; inset: 12px; z-index: 80; pointer-events: none;
  display: grid; place-items: center; border-radius: var(--r-xl);
  border: 2px dashed var(--brand-text); background: color-mix(in srgb, var(--bg) 82%, transparent);
  font-size: var(--fs-xl); font-weight: 620; color: var(--brand-text);
}
.perm-ico { color: var(--brand-text); flex: none; display: grid; place-items: center; width: 22px; height: 22px; margin-top: 1px; }
.perm-ico svg { width: 20px; height: 20px; }

/* ---------- Actualizaciones ---------- */
.upd { width: min(480px, calc(100vw - 48px)); }
.upd-head { display: flex; gap: 16px; align-items: center; margin-bottom: 18px; }
.upd-logo { flex: none; display: grid; }
.upd-notes { white-space: pre-line; background: var(--surface-2); border: 1px solid var(--line-soft); border-radius: var(--r-md); padding: 12px 14px; font-size: var(--fs-md); color: var(--ink-2); max-height: 180px; overflow: auto; margin-bottom: 12px; }
.upd-safe { display: flex; gap: 8px; align-items: center; margin: 0 0 8px; }
.upd-safe svg { width: 16px; height: 16px; color: var(--brand-text); flex: none; }
.upd-bar { height: 8px; border-radius: 4px; }
.upd-step { display: grid; place-items: center; padding: 8px 0 4px; color: var(--brand-text); }
.upd-step svg { width: 34px; height: 34px; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .45; } }
.upd-danger .upd-head h2 { color: var(--danger); }

/* ---------- Crédito TESSEN ---------- */
.about-card { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.about-brand { display: flex; align-items: center; gap: 14px; }
.about-brand b { display: block; font-size: var(--fs-lg); letter-spacing: .14em; }
.tessen-credit { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: var(--r-md); border: 1px solid var(--line); color: var(--ink); text-decoration: none; transition: border-color var(--t-fast), background var(--t-fast); }
.tessen-credit:hover { border-color: #c6ff00; background: var(--surface-2); }
.tessen-credit b { display: block; letter-spacing: .14em; font-size: var(--fs-md); }
.tessen-credit .t-meta { display: block; font-size: var(--fs-xs); }
.tessen-credit > svg { width: 16px; height: 16px; color: var(--ink-2); }
.tessen-tile { width: 36px; height: 36px; border-radius: 9px; background: #0b0b0d; display: grid; place-items: center; flex: none; }
.tessen-tile img { width: 72%; height: 72%; object-fit: contain; }
.tessen-tile.sm { width: 22px; height: 22px; border-radius: 6px; }
.onboard-by { display: flex; align-items: center; gap: 8px; margin: 18px 0 0; font-size: var(--fs-sm); color: var(--ink-2); font-weight: 520; }
