:root {
  font-family: "Segoe UI Variable", "Segoe UI", Aptos, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  color: #202136;
  background: #f4f5f8;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: #f4f5f8; font-size: 15px; line-height: 1.45; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }

.app-shell { min-height: 100vh; }
.topbar {
  min-height: 76px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  padding: 10px 19px;
  color: #fff;
  background: linear-gradient(92deg, #5149df 0%, #4339ce 56%, #3d32bf 100%);
  box-shadow: 0 3px 16px rgba(49, 43, 144, .26);
  position: sticky;
  top: 0;
  z-index: 30;
}
.brand-button { display: flex; align-items: center; gap: 12px; border: 0; padding: 0; color: inherit; text-align: left; background: transparent; }
.brand-mark { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 14px; color: #493fd1; background: #fff; font-size: 17px; font-weight: 620; letter-spacing: -.04em; box-shadow: 0 8px 20px rgba(27, 22, 101, .2); }
.brand-mark.large { width: 82px; height: 82px; border-radius: 23px; font-size: 28px; }
.brand-copy strong, .brand-copy small { display: block; }
.brand-copy strong { font-size: 18px; font-weight: 650; letter-spacing: -.01em; }
.brand-copy small { margin-top: 1px; color: rgba(255,255,255,.72); font-size: 12px; font-weight: 400; }
.topbar-spacer { min-width: 20px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.organization-control { min-width: 235px; display: flex; align-items: center; gap: 8px; padding-left: 12px; border: 1px solid rgba(255,255,255,.22); border-radius: 12px; background: rgba(255,255,255,.1); }
.organization-control select { width: 100%; border: 0; padding: 10px 34px 10px 0; color: #fff; outline: 0; background: transparent; }
.organization-control option { color: #202136; }
.topbar-icon-button { width: 43px; height: 43px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.24); border-radius: 12px; color: #fff; background: rgba(255,255,255,.09); }
.topbar-icon-button:hover { background: rgba(255,255,255,.17); }
.topbar-divider { width: 1px; height: 35px; background: rgba(255,255,255,.2); }
.user-chip { display: flex; align-items: center; gap: 9px; padding: 5px 8px 5px 5px; border-radius: 12px; background: rgba(255,255,255,.08); }
.user-chip > span { width: 37px; height: 37px; display: grid; place-items: center; border-radius: 10px; color: #fff; background: linear-gradient(145deg, #35c7f0, #148ac6); font-size: 12px; font-weight: 650; }
.user-chip strong, .user-chip small { display: block; max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-chip strong { font-size: 13px; font-weight: 600; }
.user-chip small { color: rgba(255,255,255,.67); font-size: 11px; }

.page-container { width: min(1420px, calc(100% - 36px)); margin: 27px auto 54px; }
.panel, .hero-card, .metric-card {
  border: 1px solid #e3e5ed;
  border-radius: 19px;
  background: #fff;
  box-shadow: 0 9px 27px rgba(36, 38, 74, .055);
}
.hero-card { min-height: 168px; display: flex; justify-content: space-between; align-items: flex-start; gap: 30px; padding: 30px 32px; background: linear-gradient(135deg, #fff 0%, #fbfbff 74%, #f1efff 100%); }
.hero-card h1 { margin: 7px 0 10px; font-size: clamp(29px, 3.2vw, 39px); line-height: 1.12; font-weight: 630; letter-spacing: -.035em; }
.hero-card p { max-width: 820px; margin: 0; color: #707185; line-height: 1.58; }
.eyebrow { color: #5146d8; font-size: 11px; font-weight: 650; letter-spacing: .13em; }
.phase-badge { display: flex; align-items: center; gap: 7px; flex: 0 0 auto; padding: 10px 14px; border-radius: 999px; color: #176c4a; background: #e4f8ef; font-size: 13px; font-weight: 600; }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 17px; margin: 18px 0; }
.metric-card { min-height: 131px; padding: 20px; color: #fff; border: 0; overflow: hidden; position: relative; }
.metric-card::after { content: ''; width: 115px; height: 115px; position: absolute; right: -35px; bottom: -47px; border-radius: 50%; background: rgba(255,255,255,.11); }
.metric-card span, .metric-card small { display: block; position: relative; z-index: 1; }
.metric-card span { color: rgba(255,255,255,.82); font-size: 13px; }
.metric-card strong { display: block; margin: 8px 0 5px; position: relative; z-index: 1; font-size: clamp(23px, 2.4vw, 29px); font-weight: 620; letter-spacing: -.03em; }
.metric-card small { color: rgba(255,255,255,.76); }
.metric-card.violet { background: linear-gradient(135deg, #6660df, #7652b5); }
.metric-card.rose { background: linear-gradient(135deg, #e26182, #bb4b72); }
.metric-card.blue { background: linear-gradient(135deg, #5b7fe7, #27bde1); }
.metric-card.green { background: linear-gradient(135deg, #29ba78, #39d2b5); }

.dashboard-grid { display: grid; grid-template-columns: 1.42fr .58fr; gap: 18px; margin-bottom: 18px; }
.panel { padding: 23px; }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding-bottom: 15px; border-bottom: 1px solid #ececf2; }
.panel-heading.compact { padding-bottom: 13px; }
.panel-heading h2 { margin: 4px 0 0; font-size: 21px; font-weight: 620; letter-spacing: -.02em; }
.panel-heading > span { color: #7c7d90; font-size: 12px; }
.quick-grid { display: grid; grid-template-columns: repeat(4, minmax(120px, 1fr)); gap: 13px; padding-top: 18px; }
.quick-card { min-height: 154px; display: grid; justify-items: center; align-content: center; gap: 6px; border: 1px solid #e8e9f1; border-radius: 16px; padding: 16px 12px; color: #303146; text-align: center; background: #fbfbfe; transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease; }
.quick-card:hover { transform: translateY(-2px); border-color: #c4c0f6; box-shadow: 0 10px 22px rgba(75, 65, 191, .09); }
.quick-card > span { width: 50px; height: 50px; display: grid; place-items: center; border-radius: 15px; color: #5146d8; background: #edecff; }
.quick-card strong { font-weight: 620; }
.quick-card small { color: #85869a; line-height: 1.35; }
.architecture-panel { min-height: 100%; }
.architecture-list { display: grid; gap: 13px; padding-top: 17px; }
.architecture-list > div { display: grid; grid-template-columns: 34px 1fr; gap: 11px; align-items: flex-start; }
.architecture-list > div > span { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; color: #5146d8; background: #efeeff; font-size: 12px; font-weight: 650; }
.architecture-list p { display: grid; gap: 2px; margin: 0; }
.architecture-list strong { font-size: 13px; font-weight: 620; }
.architecture-list small { color: #85869a; line-height: 1.4; }

.table-panel { padding-bottom: 8px; }
.text-button { display: inline-flex; align-items: center; gap: 6px; border: 0; padding: 8px 0; color: #5146d8; background: transparent; font-weight: 600; }
.responsive-table { margin: 0 -23px; overflow-x: auto; }
table { width: 100%; min-width: 880px; border-collapse: collapse; }
th, td { padding: 14px 16px; border-bottom: 1px solid #eeeeF4; text-align: left; vertical-align: middle; }
th { color: #737487; background: #fafafe; font-size: 12px; font-weight: 600; }
td { color: #46475b; font-size: 13px; }
td:first-child, th:first-child { padding-left: 23px; }
td:last-child, th:last-child { padding-right: 23px; }
.customer-cell { display: grid; }
.customer-cell strong { color: #34354a; font-weight: 600; }
.customer-cell small { color: #9293a4; }
.status-pill { display: inline-flex; padding: 6px 9px; border-radius: 999px; font-size: 11px; font-weight: 650; }
.status-pill.open { color: #285c9b; background: #e9f2ff; }
.status-pill.partial { color: #8b5a12; background: #fff3d9; }
.status-pill.overdue { color: #a4334d; background: #ffe9ee; }
.status-pill.paid { color: #176c4a; background: #e4f8ef; }

.launcher-backdrop { position: fixed; inset: 0; z-index: 100; display: flex; justify-content: flex-end; background: rgba(19, 20, 42, .48); backdrop-filter: blur(2px); }
.launcher-panel { width: min(570px, 100%); height: 100%; display: flex; flex-direction: column; background: #f7f7fb; box-shadow: -18px 0 55px rgba(14, 15, 36, .23); animation: slideIn .2s ease-out; }
@keyframes slideIn { from { transform: translateX(35px); opacity: .8; } to { transform: translateX(0); opacity: 1; } }
.launcher-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 24px 24px 18px; background: #fff; border-bottom: 1px solid #e6e7ef; }
.launcher-header h2 { margin: 5px 0 0; font-size: 23px; font-weight: 620; letter-spacing: -.025em; }
.close-button { width: 39px; height: 39px; display: grid; place-items: center; border: 1px solid #e3e4ec; border-radius: 11px; color: #606176; background: #fff; }
.launcher-search { margin: 17px 21px 5px; display: flex; align-items: center; gap: 9px; padding: 0 13px; border: 1px solid #dfe1eb; border-radius: 13px; color: #77788b; background: #fff; }
.launcher-search:focus-within { border-color: #655ae5; box-shadow: 0 0 0 4px rgba(81,70,216,.1); }
.launcher-search input { width: 100%; border: 0; padding: 12px 0; color: #2c2d42; outline: 0; background: transparent; }
.launcher-groups { padding: 13px 21px 28px; overflow-y: auto; }
.launcher-group { margin-bottom: 11px; border: 1px solid #e3e4ec; border-radius: 15px; overflow: hidden; background: #fff; }
.launcher-group-heading { width: 100%; display: grid; grid-template-columns: 29px 1fr auto; align-items: center; gap: 9px; border: 0; padding: 13px 14px; color: #35364b; text-align: left; background: #fff; }
.launcher-group-heading strong { font-weight: 620; }
.launcher-count { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 9px; color: #5146d8; background: #efeeff; font-size: 11px; font-weight: 650; }
.chevron { transition: transform .16s ease; }
.chevron.expanded { transform: rotate(90deg); }
.launcher-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; padding: 1px; background: #ececf2; }
.launcher-item { min-height: 132px; display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto 1fr; column-gap: 10px; align-content: start; border: 0; padding: 16px; color: #333449; text-align: left; background: #fff; position: relative; }
.launcher-item:hover:not(:disabled), .launcher-item.active { background: #f8f7ff; }
.launcher-item.active { box-shadow: inset 3px 0 #5146d8; }
.launcher-item-icon { grid-row: 1 / 4; width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; color: #5146d8; background: #eeedff; }
.launcher-item strong { align-self: end; font-size: 13px; font-weight: 620; }
.launcher-item small { color: #85869a; line-height: 1.35; }
.launcher-item em { position: absolute; right: 10px; bottom: 9px; color: #9a9bad; font-size: 10px; font-style: normal; }
.launcher-item.locked { color: #7f8091; background: #f6f6f9; opacity: .78; }
.launcher-item.locked .launcher-item-icon { color: #9899a8; background: #e9e9ee; }
.empty-state { padding: 30px; color: #85869a; text-align: center; }

.placeholder-page { min-height: 620px; display: grid; place-items: center; align-content: center; text-align: center; }
.placeholder-icon { width: 76px; height: 76px; display: grid; place-items: center; margin-bottom: 16px; border-radius: 22px; color: #5146d8; background: #ecebff; }
.placeholder-page h1 { margin: 7px 0 8px; font-size: 34px; font-weight: 620; letter-spacing: -.03em; }
.placeholder-page > p { max-width: 650px; margin: 0; color: #747589; font-size: 16px; }
.placeholder-note { max-width: 620px; display: grid; gap: 4px; margin: 24px 0; padding: 16px 18px; border: 1px solid #dedcfb; border-radius: 14px; color: #4a4780; background: #f6f5ff; }
.placeholder-note strong { font-weight: 620; }
.placeholder-note span { color: #777594; }
.primary-button { border: 0; border-radius: 12px; padding: 12px 18px; color: #fff; background: linear-gradient(90deg, #5146dd, #4539cf); box-shadow: 0 8px 19px rgba(74, 62, 202, .22); font-weight: 600; }
.message { margin-bottom: 16px; padding: 12px 14px; border-radius: 12px; }
.error-message { color: #9d3049; background: #ffecef; }
.loading-panel { min-height: 260px; display: grid; place-items: center; color: #77788c; }
.loading-screen, .error-screen { min-height: 100vh; display: grid; justify-items: center; align-content: center; gap: 14px; padding: 30px; text-align: center; background: linear-gradient(135deg, #4f46dc, #2c9cd2); color: #fff; }
.error-screen h1 { margin: 8px 0 0; }
.error-screen p { max-width: 580px; margin: 0; }
.error-screen small { color: rgba(255,255,255,.75); }

@media (max-width: 1080px) {
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .quick-grid { grid-template-columns: repeat(2, 1fr); }
  .user-chip div { display: none; }
  .organization-control { min-width: 190px; }
}

@media (max-width: 720px) {
  .topbar { grid-template-columns: 1fr auto; gap: 10px; }
  .topbar-spacer { display: none; }
  .brand-copy small { display: none; }
  .organization-control { min-width: 0; width: 48px; padding: 0; justify-content: center; }
  .organization-control select { position: absolute; width: 1px; height: 1px; opacity: 0; }
  .topbar-divider, .user-chip { display: none; }
  .page-container { width: min(100% - 22px, 1420px); margin-top: 16px; }
  .hero-card { min-height: auto; display: grid; padding: 23px; }
  .phase-badge { justify-self: start; }
  .metric-grid { grid-template-columns: 1fr; gap: 11px; }
  .quick-grid { grid-template-columns: 1fr 1fr; }
  .launcher-grid { grid-template-columns: 1fr; }
}

@media (max-width: 460px) {
  .brand-copy strong { font-size: 15px; }
  .brand-mark { width: 42px; height: 42px; }
  .quick-grid { grid-template-columns: 1fr; }
  .panel { padding: 19px; }
  .responsive-table { margin-left: -19px; margin-right: -19px; }
}


.logout-button { min-height: 42px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid #e1e2eb; border-radius: 11px; padding: 0 12px; color: #5e6074; background: #fff; font-weight: 600; }
.logout-button:hover { color: #4339c5; border-color: #c9c5f5; background: #f8f7ff; }
.compact-hero { min-height: 190px; }
.success-message { color: #176c4a; background: #e4f8ef; }
.secondary-button { border: 1px solid #dcdde7; border-radius: 11px; padding: 10px 14px; color: #4c4d62; background: #fff; font-weight: 600; }
.secondary-button:hover { border-color: #bdb8ef; color: #4b40cf; background: #f8f7ff; }

.auth-layout { min-height: 100vh; display: grid; grid-template-columns: minmax(360px, .9fr) minmax(520px, 1.1fr); background: #f6f6fa; }
.auth-brand-panel { display: grid; align-content: center; justify-items: start; gap: 18px; padding: clamp(42px, 7vw, 100px); color: #fff; background: radial-gradient(circle at 20% 12%, rgba(255,255,255,.18), transparent 32%), linear-gradient(145deg, #5146dd, #4436ba 48%, #218ebd); position: relative; overflow: hidden; }
.auth-brand-panel::after { content: ''; position: absolute; width: 360px; height: 360px; right: -150px; bottom: -150px; border: 1px solid rgba(255,255,255,.16); border-radius: 50%; box-shadow: 0 0 0 70px rgba(255,255,255,.035), 0 0 0 140px rgba(255,255,255,.025); }
.auth-logo { width: 66px; height: 66px; font-size: 19px; background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.28); box-shadow: none; backdrop-filter: blur(8px); }
.eyebrow.light { color: rgba(255,255,255,.72); }
.auth-brand-panel h1 { max-width: 600px; margin: 0; font-size: clamp(38px, 5vw, 66px); line-height: 1.03; font-weight: 620; letter-spacing: -.045em; position: relative; z-index: 1; }
.auth-brand-panel > p { max-width: 560px; margin: 0; color: rgba(255,255,255,.78); font-size: 17px; line-height: 1.65; position: relative; z-index: 1; }
.auth-feature-list { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 10px; position: relative; z-index: 1; }
.auth-feature-list span { padding: 9px 12px; border: 1px solid rgba(255,255,255,.18); border-radius: 999px; color: rgba(255,255,255,.84); background: rgba(255,255,255,.08); font-size: 12px; }
.auth-form-panel { display: grid; place-items: center; padding: 34px; }
.auth-card { width: min(470px, 100%); display: grid; gap: 20px; padding: clamp(28px, 5vw, 46px); border: 1px solid #e2e3ec; border-radius: 25px; background: #fff; box-shadow: 0 24px 70px rgba(38, 39, 70, .09); }
.auth-card h2 { margin: 7px 0 5px; color: #292a40; font-size: 32px; font-weight: 620; letter-spacing: -.035em; }
.auth-card > div > p { margin: 0; color: #7b7c8f; }
.field-label { display: grid; gap: 8px; color: #48495d; font-size: 13px; font-weight: 600; }
.field-label input, .field-label select { width: 100%; border: 1px solid #dfe0e8; border-radius: 12px; padding: 12px 13px; color: #2d2e43; outline: none; background: #fff; font: inherit; font-weight: 400; }
.field-label input:focus, .field-label select:focus { border-color: #6257df; box-shadow: 0 0 0 4px rgba(81,70,216,.1); }
.field-label small { color: #8a8b9c; font-weight: 400; }
.auth-submit { width: 100%; min-height: 48px; }
.auth-submit:disabled, .primary-button:disabled { opacity: .65; cursor: wait; }
.invitation-layout .auth-brand-panel { background: radial-gradient(circle at 20% 12%, rgba(255,255,255,.17), transparent 32%), linear-gradient(145deg, #306f93, #4940c7); }

.security-metric-grid { display: grid; grid-template-columns: repeat(5, minmax(120px, 1fr)); gap: 13px; margin-bottom: 18px; }
.security-metric { display: grid; gap: 6px; padding: 18px; border: 1px solid #e5e5ed; border-radius: 15px; background: #fff; box-shadow: 0 8px 22px rgba(42,43,74,.04); }
.security-metric span { color: #858698; font-size: 12px; }
.security-metric strong { color: #34354b; font-size: 25px; font-weight: 620; }
.invite-panel { margin-bottom: 18px; }
.invite-form { display: grid; grid-template-columns: 1.5fr 1fr auto; align-items: end; gap: 13px; padding-top: 18px; }
.invite-form .primary-button { min-height: 43px; }
.invite-result { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; margin-top: 16px; padding: 12px; border: 1px solid #dddaf7; border-radius: 12px; background: #f8f7ff; }
.invite-result code { min-width: 0; overflow: hidden; color: #514b83; text-overflow: ellipsis; white-space: nowrap; }
.status-pill.active { color: #176c4a; background: #e4f8ef; }
.status-pill.invited { color: #765b18; background: #fff4d7; }
.status-pill.inactive, .status-pill.suspended { color: #6f7081; background: #ececf1; }

.role-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.role-card { padding: 0; overflow: hidden; }
.role-card > header { display: grid; grid-template-columns: auto 1fr auto; gap: 13px; align-items: start; padding: 21px; border-bottom: 1px solid #ececf2; }
.role-icon { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 14px; color: #5146d8; background: #ecebff; }
.role-card h2 { margin: 1px 0 5px; font-size: 19px; font-weight: 620; }
.role-card header p { margin: 0; color: #858699; font-size: 13px; line-height: 1.45; }
.member-count { padding: 6px 9px; border-radius: 999px; color: #5956a2; background: #f0efff; font-size: 11px; font-weight: 600; white-space: nowrap; }
.permission-list { display: grid; max-height: 390px; overflow-y: auto; }
.permission-list > div { display: grid; grid-template-columns: 26px 1fr; gap: 9px; align-items: start; padding: 12px 20px; border-bottom: 1px solid #f0f0f4; }
.permission-list > div:last-child { border-bottom: 0; }
.permission-list > div > span { width: 22px; height: 22px; display: grid; place-items: center; border-radius: 7px; color: #237b5a; background: #e5f8ef; font-size: 11px; font-weight: 620; }
.permission-list p { display: grid; gap: 3px; margin: 0; }
.permission-list strong { color: #45465a; font-size: 13px; font-weight: 600; }
.permission-list small { color: #9495a5; font-size: 10px; }

.audit-list { display: grid; margin: 0 -23px; }
.audit-list article { display: grid; grid-template-columns: auto 1fr minmax(130px, .4fr) auto; gap: 13px; align-items: center; padding: 14px 23px; border-bottom: 1px solid #eeeeF4; }
.audit-dot { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; color: #5146d8; background: #eeedff; }
.audit-list article > div { display: grid; gap: 3px; }
.audit-list strong { color: #404156; font-size: 13px; font-weight: 600; }
.audit-list small { color: #8b8c9d; font-size: 11px; }
.audit-entity span { color: #5f6074; font-size: 12px; }
.audit-list time { color: #77788a; font-size: 11px; white-space: nowrap; }

@media (max-width: 1050px) {
  .auth-layout { grid-template-columns: 1fr; }
  .auth-brand-panel { min-height: 390px; }
  .security-metric-grid { grid-template-columns: repeat(3, 1fr); }
  .role-grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .auth-brand-panel { min-height: 340px; padding: 38px 28px; }
  .auth-form-panel { padding: 20px; }
  .auth-card { padding: 27px 22px; }
  .logout-button span { display: none; }
  .logout-button { width: 42px; justify-content: center; padding: 0; }
  .security-metric-grid { grid-template-columns: repeat(2, 1fr); }
  .invite-form { grid-template-columns: 1fr; }
  .invite-result { grid-template-columns: 1fr; }
  .audit-list article { grid-template-columns: auto 1fr; }
  .audit-entity, .audit-list time { grid-column: 2; }
}

.frontend-error-details {
  width: min(680px, 100%);
  margin: 4px 0 10px;
  padding: 12px 14px;
  border: 1px solid #d9dce8;
  border-radius: 12px;
  background: #fff;
  text-align: left;
}
.frontend-error-details summary { cursor: pointer; font-weight: 600; }
.frontend-error-details code { display: block; margin-top: 10px; white-space: pre-wrap; overflow-wrap: anywhere; }

/* Catálogos y configuración */
.primary-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 11px; padding: 11px 16px; color: #fff; background: linear-gradient(135deg, #584de1, #4337c8); font-weight: 600; box-shadow: 0 8px 18px rgba(70, 58, 199, .17); }
.primary-button:hover { background: linear-gradient(135deg, #4d42d4, #3c31b9); }
.catalog-hero { align-items: center; }
.hero-action { flex: 0 0 auto; }
.catalog-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 18px 0; }
.catalog-summary-grid article { display: grid; gap: 7px; padding: 18px 20px; border: 1px solid #e3e5ed; border-radius: 16px; background: #fff; box-shadow: 0 8px 22px rgba(36,38,74,.04); }
.catalog-summary-grid span { color: #858699; font-size: 12px; }
.catalog-summary-grid strong { color: #34354a; font-size: 23px; font-weight: 620; letter-spacing: -.025em; }
.catalog-panel { overflow: hidden; }
.catalog-toolbar { display: grid; grid-template-columns: minmax(260px, 1fr) 190px; gap: 12px; padding-bottom: 18px; }
.catalog-search { display: flex; align-items: center; gap: 9px; padding: 0 13px; border: 1px solid #dfe1eb; border-radius: 12px; color: #77788b; background: #fff; }
.catalog-search:focus-within { border-color: #655ae5; box-shadow: 0 0 0 4px rgba(81,70,216,.1); }
.catalog-search input { width: 100%; border: 0; padding: 11px 0; outline: 0; background: transparent; }
.catalog-toolbar > select { border: 1px solid #dfe1eb; border-radius: 12px; padding: 10px 12px; color: #45465a; background: #fff; }
.customers-table small, td small { color: #9293a4; }
.icon-action { width: 37px; height: 37px; display: grid; place-items: center; border: 1px solid #e1e2ea; border-radius: 10px; color: #554bd1; background: #fff; }
.icon-action:hover { border-color: #c8c4f2; background: #f7f6ff; }

.modal-backdrop { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; padding: 24px; background: rgba(25,26,48,.55); backdrop-filter: blur(3px); overflow-y: auto; }
.modal-card { width: min(650px, 100%); max-height: calc(100vh - 48px); display: flex; flex-direction: column; border: 1px solid #e1e2ea; border-radius: 20px; background: #fff; box-shadow: 0 30px 90px rgba(22,23,48,.26); overflow: hidden; }
.wide-modal { width: min(1040px, 100%); }
.modal-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; padding: 21px 23px; border-bottom: 1px solid #e9eaf0; }
.modal-header h2 { margin: 5px 0 0; color: #303146; font-size: 23px; font-weight: 620; letter-spacing: -.025em; }
.entity-form { padding: 22px 23px 0; overflow-y: auto; }
.form-message { grid-column: 1 / -1; }
.form-section { padding-bottom: 21px; margin-bottom: 20px; border-bottom: 1px solid #eeeeF4; }
.form-section:last-of-type { margin-bottom: 0; border-bottom: 0; }
.form-section h3 { margin: 0 0 14px; color: #404156; font-size: 15px; font-weight: 620; }
.form-grid { display: grid; gap: 14px; }
.form-grid.two-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid.three-columns { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.span-two { grid-column: span 2; }
.span-three { grid-column: span 3; }
.field-label textarea { width: 100%; resize: vertical; border: 1px solid #dfe0e8; border-radius: 12px; padding: 11px 13px; color: #2d2e43; outline: none; background: #fff; font: inherit; font-weight: 400; }
.field-label textarea:focus { border-color: #6257df; box-shadow: 0 0 0 4px rgba(81,70,216,.1); }
.check-field { min-height: 43px; display: flex; align-items: center; gap: 10px; color: #4c4d60; font-size: 13px; font-weight: 600; }
.check-field input { width: 17px; height: 17px; accent-color: #5146d8; }
.modal-actions { position: sticky; bottom: 0; display: flex; justify-content: flex-end; gap: 10px; margin: 0 -23px; padding: 16px 23px; border-top: 1px solid #e9eaf0; background: #fff; }
.empty-state { padding: 28px; color: #858699; text-align: center; }

.settings-tabs { display: flex; gap: 9px; margin: 18px 0; padding: 7px; border: 1px solid #e1e2ea; border-radius: 15px; background: #fff; overflow-x: auto; }
.settings-tabs button { min-height: 42px; display: inline-flex; align-items: center; gap: 8px; flex: 0 0 auto; border: 0; border-radius: 10px; padding: 0 14px; color: #65667a; background: transparent; font-weight: 600; }
.settings-tabs button:hover { color: #4a40cf; background: #f6f5ff; }
.settings-tabs button.active { color: #fff; background: linear-gradient(135deg, #5b50df, #4439c8); box-shadow: 0 7px 16px rgba(69,58,196,.17); }
.settings-stack { display: grid; gap: 18px; }
.settings-section { padding-bottom: 25px; }
.settings-form-grid { padding-top: 18px; }
.sequence-list { display: grid; gap: 10px; padding-top: 18px; }
.sequence-list article { display: grid; grid-template-columns: minmax(180px, 1.3fr) minmax(100px, .9fr) 110px 90px 130px; gap: 11px; align-items: end; padding: 14px; border: 1px solid #e8e9f0; border-radius: 13px; background: #fbfbfd; }
.sequence-list article > div { display: grid; gap: 3px; align-self: center; }
.sequence-list strong { color: #414257; font-size: 13px; font-weight: 620; }
.sequence-list small { color: #8a8b9c; font-size: 11px; }
.sequence-list label { display: grid; gap: 5px; color: #77788b; font-size: 10px; font-weight: 600; }
.sequence-list input, .sequence-list select { width: 100%; border: 1px solid #dfe0e8; border-radius: 9px; padding: 9px 10px; color: #333449; background: #fff; }
.settings-save-bar { position: sticky; bottom: 14px; z-index: 8; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 14px 16px; border: 1px solid #dcdaf2; border-radius: 14px; color: #68697c; background: rgba(255,255,255,.96); box-shadow: 0 13px 34px rgba(36,38,74,.12); backdrop-filter: blur(10px); font-size: 12px; }

@media (max-width: 1080px) {
  .catalog-summary-grid { grid-template-columns: repeat(2, 1fr); }
  .sequence-list article { grid-template-columns: 1fr 1fr 1fr; }
  .sequence-list article > div { grid-column: span 3; }
}

@media (max-width: 720px) {
  .catalog-hero { align-items: flex-start; }
  .catalog-summary-grid { grid-template-columns: 1fr 1fr; }
  .catalog-toolbar { grid-template-columns: 1fr; }
  .modal-backdrop { padding: 0; place-items: stretch; }
  .modal-card, .wide-modal { width: 100%; min-height: 100vh; max-height: none; border-radius: 0; }
  .form-grid.two-columns, .form-grid.three-columns { grid-template-columns: 1fr; }
  .span-two, .span-three { grid-column: span 1; }
  .sequence-list article { grid-template-columns: 1fr 1fr; }
  .sequence-list article > div { grid-column: span 2; }
  .settings-save-bar { align-items: stretch; flex-direction: column; }
}

@media (max-width: 460px) {
  .catalog-summary-grid { grid-template-columns: 1fr; }
  .sequence-list article { grid-template-columns: 1fr; }
  .sequence-list article > div { grid-column: span 1; }
}

/* Facturas */
.status-pill.void { color: #6c6675; background: #eceaf0; }
.status-pill.draft { color: #5f6074; background: #eeeff4; }
.invoice-summary-grid article small { color: #9293a4; font-size: 11px; }
.invoice-toolbar { grid-template-columns: minmax(300px, 1fr) 180px 190px; }
.invoices-table td { vertical-align: middle; }
.muted-row { opacity: .68; background: #fafafd; }
.modal-subtitle { margin: 6px 0 0; color: #858699; font-size: 12px; }
.invoice-modal { width: min(980px, 100%); }
.invoice-balance-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 15px; }
.invoice-balance-strip span { display: grid; gap: 4px; padding: 12px 14px; border: 1px solid #e5e6ed; border-radius: 12px; color: #858699; background: #fbfbfd; font-size: 11px; }
.invoice-balance-strip strong { color: #34354a; font-size: 16px; font-weight: 620; }
.danger-section { padding: 16px; border: 1px solid #f2cfd7; border-radius: 14px; background: #fff8fa; }
.danger-section p { margin: -5px 0 13px; color: #7f6670; font-size: 12px; }
.danger-button { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; border: 1px solid #e7a9b7; border-radius: 11px; padding: 0 15px; color: #a5324e; background: #fff; font-weight: 600; }
.danger-button:hover { background: #fff4f7; }
.danger-button.solid { border-color: #b53d59; color: #fff; background: #b53d59; }
.danger-button.solid:hover { background: #9f3049; }
.warning-message { border-color: #efd8a7; color: #765914; background: #fff9e9; }
.split-actions { justify-content: space-between; align-items: center; }
.action-group { display: flex; justify-content: flex-end; gap: 10px; }

@media (max-width: 900px) {
  .invoice-toolbar { grid-template-columns: 1fr 1fr; }
  .invoice-toolbar .catalog-search { grid-column: span 2; }
}

@media (max-width: 720px) {
  .invoice-toolbar { grid-template-columns: 1fr; }
  .invoice-toolbar .catalog-search { grid-column: span 1; }
  .invoice-balance-strip { grid-template-columns: 1fr; }
  .split-actions { align-items: stretch; flex-direction: column; }
  .split-actions > div, .action-group { width: 100%; }
  .action-group { flex-direction: column-reverse; }
  .split-actions button { width: 100%; }
}


/* Interfaz compacta para catálogos y formularios */
.page-container { margin-top: 20px; }
.compact-hero {
  min-height: 0;
  align-items: center;
  padding: 20px 26px;
}
.compact-hero h1 {
  margin: 4px 0 5px;
  font-size: clamp(27px, 2.7vw, 34px);
  line-height: 1.08;
}
.compact-hero p { line-height: 1.42; }
.compact-hero .primary-button { min-height: 42px; padding: 0 16px; }
.catalog-summary-grid { gap: 12px; margin: 14px 0; }
.catalog-summary-grid article { gap: 4px; min-height: 88px; padding: 13px 16px; align-content: center; }
.catalog-summary-grid strong { font-size: 21px; }
.catalog-toolbar { gap: 10px; padding-bottom: 14px; }
.catalog-search input { padding: 9px 0; }
.catalog-toolbar > select { min-height: 42px; padding: 0 12px; }
.catalog-panel th, .catalog-panel td { padding-top: 11px; padding-bottom: 11px; }

.modal-backdrop { padding: 14px; }
.modal-card {
  max-height: calc(100vh - 28px);
  border-radius: 18px;
}
.wide-modal { width: min(1000px, calc(100vw - 28px)); }
.invoice-modal { width: min(960px, calc(100vw - 28px)); }
.modal-header {
  flex: 0 0 auto;
  align-items: center;
  padding: 15px 20px;
}
.modal-header h2 { margin-top: 3px; font-size: 22px; }
.modal-subtitle { margin-top: 3px; }
.modal-header .close-button { width: 37px; height: 37px; }
.entity-form {
  min-height: 0;
  padding: 15px 20px 0;
  scrollbar-gutter: stable;
  overscroll-behavior: contain;
}
.form-section { padding-bottom: 15px; margin-bottom: 14px; }
.form-section h3 { margin-bottom: 10px; }
.form-grid { column-gap: 12px; row-gap: 10px; }
.modal-card .field-label { gap: 5px; line-height: 1.25; }
.modal-card .field-label input,
.modal-card .field-label select {
  height: 42px;
  min-height: 42px;
  padding: 0 12px;
  border-radius: 10px;
}
.modal-card .field-label textarea {
  min-height: 58px;
  padding: 9px 12px;
  border-radius: 10px;
  line-height: 1.35;
}
.modal-card .field-label small { min-height: 0; line-height: 1.25; }
.modal-card .check-field { min-height: 42px; }
.invoice-balance-strip { margin-top: 10px; }
.invoice-balance-strip span { padding: 9px 12px; }
.modal-actions {
  margin: 0 -20px;
  padding: 11px 20px;
}
.modal-actions .primary-button,
.modal-actions .secondary-button,
.modal-actions .danger-button { min-height: 40px; padding-top: 0; padding-bottom: 0; }

@media (max-width: 720px) {
  .compact-hero { padding: 18px; }
  .modal-backdrop { padding: 0; }
  .wide-modal, .invoice-modal { width: 100%; }
  .modal-header { padding: 14px 16px; }
  .entity-form { padding: 14px 16px 0; }
  .modal-actions { margin: 0 -16px; padding: 11px 16px; }
}

/* Pagos y aplicaciones */
.payment-toolbar { grid-template-columns: minmax(300px, 1fr) 220px 180px; }
.payments-table { min-width: 1080px; }
.payments-table td { vertical-align: middle; }
.payments-table td small,
.application-table td small { display: block; margin-top: 3px; }
.positive-balance { color: #176c4a; font-weight: 620; }
.payment-modal { width: min(1040px, calc(100vw - 28px)); }
.payment-application-section { padding-bottom: 12px; }
.section-heading-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 10px; }
.section-heading-row h3 { margin: 0 0 4px; }
.section-heading-row p { margin: 0; color: #858699; font-size: 12px; }
.inline-actions { display: flex; align-items: center; gap: 14px; white-space: nowrap; }
.text-button.muted { color: #77788b; }
.empty-inline { padding: 18px; border: 1px dashed #dfe1ea; border-radius: 12px; color: #858699; background: #fbfbfd; text-align: center; font-size: 12px; }
.application-table-wrap { max-height: 250px; overflow: auto; border: 1px solid #e5e6ed; border-radius: 12px; }
.application-table { min-width: 680px; }
.application-table th,
.application-table td { padding: 9px 12px; border-bottom: 1px solid #ececf2; text-align: left; }
.application-table th { position: sticky; top: 0; z-index: 1; color: #6f7081; background: #f8f8fb; font-size: 11px; font-weight: 620; }
.application-table tbody tr:last-child td { border-bottom: 0; }
.allocation-input { width: 130px; height: 38px; min-height: 38px; border: 1px solid #dfe1e9; border-radius: 9px; padding: 0 10px; text-align: right; }
.payment-totals-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 10px; }
.payment-totals-strip span { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 46px; padding: 8px 12px; border: 1px solid #e5e6ed; border-radius: 11px; color: #858699; background: #fbfbfd; font-size: 11px; }
.payment-totals-strip strong { color: #34354a; font-size: 15px; font-weight: 620; }

@media (max-width: 980px) {
  .payment-toolbar { grid-template-columns: 1fr 1fr; }
  .payment-toolbar .catalog-search { grid-column: span 2; }
}

@media (max-width: 720px) {
  .payment-toolbar { grid-template-columns: 1fr; }
  .payment-toolbar .catalog-search { grid-column: span 1; }
  .payment-modal { width: 100%; }
  .section-heading-row { flex-direction: column; }
  .inline-actions { width: 100%; justify-content: space-between; }
  .payment-totals-strip { grid-template-columns: 1fr; }
}

/* Estado de cuenta e historial */
.statement-controls { margin: 14px 0; padding: 16px 18px; }
.statement-mode-tabs { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid #e4e5ed; border-radius: 12px; background: #f8f8fc; }
.statement-mode-tabs button { min-height: 34px; border: 0; border-radius: 9px; padding: 0 14px; color: #696a7e; background: transparent; font-weight: 600; }
.statement-mode-tabs button.active { color: #fff; background: linear-gradient(135deg, #5b50df, #4439c8); box-shadow: 0 6px 14px rgba(69,58,196,.16); }
.statement-filter-grid { display: grid; grid-template-columns: minmax(300px, 1fr) 180px 180px; gap: 12px; align-items: end; margin-top: 14px; }
.statement-filter-grid .field-label input,
.statement-filter-grid .field-label select { height: 42px; min-height: 42px; padding: 0 12px; border-radius: 10px; }
.statement-history-help { min-height: 42px; grid-column: span 2; display: grid; align-content: center; gap: 2px; padding: 7px 12px; border: 1px solid #e6e7ef; border-radius: 10px; color: #4a4b60; background: #fbfbfd; }
.statement-history-help small { color: #858699; }
.statement-summary-grid article { min-height: 88px; }
.statement-summary-grid article small { color: #8c8d9e; font-size: 11px; }
.statement-panel { margin-top: 14px; }
.statement-table { min-width: 1120px; }
.statement-table td small { display: block; margin-top: 3px; color: #9293a4; }
.movement-type { display: inline-flex; padding: 5px 8px; border-radius: 999px; font-size: 11px; font-weight: 650; }
.movement-type.invoice { color: #285c9b; background: #e9f2ff; }
.movement-type.payment { color: #176c4a; background: #e4f8ef; }
.movement-type.credit_note { color: #775319; background: #fff1cf; }
.statement-ending-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding-top: 14px; }
.statement-ending-strip span { min-height: 46px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 12px; border: 1px solid #e5e6ed; border-radius: 11px; color: #858699; background: #fbfbfd; font-size: 11px; }
.statement-ending-strip strong { color: #34354a; font-size: 14px; font-weight: 620; }

/* Mejor distribución del formulario de nota de crédito */
.payment-modal .form-grid.three-columns .span-three { grid-column: 1 / -1; }
.payment-modal .form-grid.three-columns .span-two { grid-column: span 2; }

@media (max-width: 860px) {
  .statement-filter-grid { grid-template-columns: 1fr 1fr; }
  .statement-customer { grid-column: span 2; }
  .statement-history-help { grid-column: span 2; }
  .statement-ending-strip { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .statement-mode-tabs { width: 100%; }
  .statement-mode-tabs button { flex: 1; }
  .statement-filter-grid { grid-template-columns: 1fr; }
  .statement-customer, .statement-history-help { grid-column: span 1; }
}
.row-actions { display: inline-flex; align-items: center; gap: 6px; }

.report-toolbar { display: grid; grid-template-columns: minmax(280px,1fr) auto; align-items: end; gap: 14px; margin-bottom: 16px; padding: 15px 18px; }
.report-toolbar.single-search { grid-template-columns: 1fr; }
.report-toolbar.monthly-toolbar { grid-template-columns: 1fr 180px; align-items: center; }
.report-toolbar.monthly-toolbar > div { display: grid; gap: 3px; }
.report-toolbar.monthly-toolbar small { color: #87889a; }
.commission-toolbar { grid-template-columns: 180px 180px minmax(240px,1fr); }
.inline-field { display: grid; gap: 7px; min-width: 170px; color: #5a5b6e; font-size: 13px; font-weight: 600; }
.inline-field input, .inline-field select { min-height: 42px; border: 1px solid #dfe1eb; border-radius: 12px; padding: 0 12px; color: #3d3e53; background: #fff; font: inherit; font-weight: 400; }
.report-metric-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 14px; margin: 0 0 16px; }
.report-metric-grid article { display: grid; gap: 5px; min-height: 112px; padding: 18px; border: 1px solid #e3e4ec; border-radius: 16px; background: #fff; box-shadow: 0 10px 26px rgba(41,42,74,.045); }
.report-metric-grid span { color: #818295; font-size: 12px; }
.report-metric-grid strong { color: #292b43; font-size: clamp(20px,2vw,27px); font-weight: 620; letter-spacing: -.025em; }
.report-metric-grid small { color: #9293a3; }
.aging-strip { display: grid; grid-template-columns: repeat(5,1fr); margin-bottom: 16px; padding: 0; overflow: hidden; }
.aging-strip > div { display: grid; gap: 5px; padding: 15px 17px; border-right: 1px solid #e7e8ef; }
.aging-strip > div:last-child { border-right: 0; }
.aging-strip span { color: #838497; font-size: 12px; }
.aging-strip strong { color: #313349; font-size: 17px; font-weight: 620; }
.report-table-panel { margin-bottom: 18px; }
.wide-report-table { min-width: 1080px; }
.report-tabs { display: flex; gap: 6px; padding: 7px; margin-bottom: 16px; overflow-x: auto; }
.report-tabs button { flex: 1 0 auto; min-height: 40px; padding: 0 15px; border-radius: 10px; color: #666779; background: transparent; font-weight: 560; }
.report-tabs button:hover { background: #f3f2ff; color: #4f45d7; }
.report-tabs button.active { color: #fff; background: #5044da; box-shadow: 0 7px 17px rgba(80,68,218,.2); }
.monthly-chart-panel { margin-bottom: 16px; }
.monthly-chart { height: 250px; display: flex; align-items: stretch; gap: 7px; padding: 20px 4px 4px; overflow-x: auto; }
.monthly-column { min-width: 54px; flex: 1; display: grid; grid-template-rows: 1fr auto auto; justify-items: center; gap: 5px; color: #727386; }
.monthly-bars { width: 100%; min-height: 150px; display: flex; align-items: end; justify-content: center; gap: 4px; border-bottom: 1px solid #e4e5ed; }
.monthly-bars span { width: min(17px,35%); min-height: 0; border-radius: 7px 7px 2px 2px; transition: height .25s ease; }
.sales-bar, .sales-legend { background: #675ce1; }
.collection-bar, .collection-legend { background: #30b894; }
.monthly-column strong { font-size: 11px; font-weight: 600; text-transform: capitalize; white-space: nowrap; }
.monthly-column small { font-size: 10px; white-space: nowrap; }
.chart-legend { display: flex; justify-content: center; gap: 18px; padding-top: 12px; color: #747587; font-size: 12px; }
.chart-legend span { display: flex; align-items: center; gap: 7px; }
.chart-legend i { width: 10px; height: 10px; border-radius: 3px; }
.dashboard-grid-balanced { grid-template-columns: 1.1fr .9fr; }
.dashboard-quick-grid { grid-template-columns: repeat(3,minmax(110px,1fr)); }
.quick-card.compact { min-height: 120px; padding: 12px 9px; }
.quick-card.compact > span { width: 42px; height: 42px; border-radius: 12px; }
.dashboard-aging-list { display: grid; gap: 12px; padding-top: 10px; }
.dashboard-aging-list > div { display: grid; grid-template-columns: 72px 1fr 118px; align-items: center; gap: 10px; }
.dashboard-aging-list span { color: #747589; font-size: 12px; }
.dashboard-aging-list > div > div { height: 8px; overflow: hidden; border-radius: 999px; background: #eeeef4; }
.dashboard-aging-list i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,#655ae0,#a269de); }
.dashboard-aging-list strong { text-align: right; color: #34364b; font-size: 13px; font-weight: 610; }
.dashboard-net-strip { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; padding: 13px 14px; border-radius: 12px; color: #494a61; background: #f5f4ff; }
.dashboard-net-strip strong { font-size: 18px; }
.dashboard-monthly-chart { height: 205px; display: flex; align-items: stretch; justify-content: space-around; gap: 12px; padding: 15px 12px 0; }
.dashboard-month { flex: 1; min-width: 42px; display: grid; grid-template-rows: 1fr auto; justify-items: center; gap: 7px; }
.dashboard-month > div { width: 100%; display: flex; align-items: end; justify-content: center; gap: 5px; border-bottom: 1px solid #e5e6ee; }
.dashboard-month i { width: min(18px,35%); border-radius: 6px 6px 1px 1px; }
.dashboard-month i.sales { background: #665be0; }
.dashboard-month i.collections { background: #31b894; }
.dashboard-month strong { color: #7b7c8e; font-size: 11px; font-weight: 600; text-transform: capitalize; }
.top-customer-list { display: grid; padding-top: 6px; }
.top-customer-list > div:not(.empty-state) { display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid #ececf2; }
.top-customer-list > div:last-child { border-bottom: 0; }
.top-customer-list > div > span { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 9px; color: #5a50d9; background: #efeeff; font-size: 12px; font-weight: 650; }
.top-customer-list p { display: grid; gap: 2px; margin: 0; }
.top-customer-list p strong { color: #37384d; font-size: 13px; }
.top-customer-list p small { color: #9293a4; }
.top-customer-list b { color: #34354a; font-size: 13px; font-weight: 630; }
.text-button { display: inline-flex; align-items: center; gap: 4px; color: #5146d8; background: transparent; font-weight: 600; }
.text-button:hover { color: #3026b9; }

@media (max-width: 1050px) {
  .report-metric-grid { grid-template-columns: repeat(2,1fr); }
  .aging-strip { grid-template-columns: repeat(3,1fr); }
  .aging-strip > div:nth-child(3) { border-right: 0; }
  .aging-strip > div:nth-child(n+4) { border-top: 1px solid #e7e8ef; }
  .dashboard-grid-balanced { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .report-toolbar, .report-toolbar.monthly-toolbar, .commission-toolbar { grid-template-columns: 1fr; align-items: stretch; }
  .report-metric-grid { grid-template-columns: 1fr 1fr; }
  .aging-strip { grid-template-columns: 1fr 1fr; }
  .aging-strip > div { border-right: 1px solid #e7e8ef; border-top: 1px solid #e7e8ef; }
  .aging-strip > div:nth-child(2n) { border-right: 0; }
  .dashboard-quick-grid { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 500px) {
  .report-metric-grid { grid-template-columns: 1fr; }
  .dashboard-quick-grid { grid-template-columns: 1fr; }
  .dashboard-aging-list > div { grid-template-columns: 62px 1fr; }
  .dashboard-aging-list strong { grid-column: 2; }
}

/* Importación y migración */
.button-link { text-decoration: none; }
.import-layout { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(320px, .92fr); gap: 16px; margin: 16px 0; }
.import-upload-panel, .integrity-panel { min-height: 100%; }
.import-form { display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, .55fr) auto; align-items: end; gap: 12px; padding-top: 16px; }
.file-drop { min-height: 96px; display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; align-content: center; column-gap: 13px; padding: 15px 17px; border: 1.5px dashed #c8cad9; border-radius: 15px; background: #fafaff; cursor: pointer; transition: .16s ease; }
.file-drop:hover { border-color: #7065d9; background: #f7f5ff; }
.file-drop input { position: absolute; inline-size: 1px; block-size: 1px; opacity: 0; pointer-events: none; }
.file-drop svg { grid-row: 1 / span 2; color: #6258cc; }
.file-drop strong { color: #343548; font-size: 14px; font-weight: 620; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-drop span { color: #858699; font-size: 12px; }
.small-button { min-height: 36px; padding: 0 13px; }
.integrity-result { display: grid; gap: 4px; margin-top: 15px; padding: 13px 15px; border-radius: 13px; }
.integrity-result.ok { background: #edf9f2; color: #246845; }
.integrity-result.warning { background: #fff6df; color: #795b17; }
.integrity-result strong { font-size: 15px; font-weight: 620; }
.integrity-result span { font-size: 12px; opacity: .8; }
.integrity-checks { display: grid; gap: 8px; margin-top: 12px; }
.integrity-checks > div { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 9px; min-height: 31px; padding: 0 3px; color: #55566c; font-size: 12px; border-bottom: 1px solid #f0f0f5; }
.integrity-checks > div:last-child { border-bottom: 0; }
.integrity-checks strong { font-weight: 620; }
.compact-empty { min-height: 120px; }
.import-result-panel { margin-bottom: 16px; }
.import-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; padding-top: 15px; }
.import-summary-grid article { min-height: 78px; display: grid; align-content: center; gap: 5px; padding: 12px 14px; border: 1px solid #ececf2; border-radius: 13px; background: #fbfbfe; }
.import-summary-grid span { color: #838497; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; }
.import-summary-grid strong { color: #303146; font-size: 22px; font-weight: 620; }
.import-summary-grid .small-value { font-size: 13px; line-height: 1.35; }
.import-entity-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 9px; margin-top: 12px; }
.import-entity-grid > div { display: grid; gap: 3px; padding: 11px 12px; border-radius: 11px; background: #f6f6fa; }
.import-entity-grid strong { color: #414256; font-size: 12px; font-weight: 620; }
.import-entity-grid span, .import-entity-grid small { color: #818295; font-size: 11px; }
.import-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 14px; }
.import-issues-table { max-height: 420px; margin-top: 14px; border: 1px solid #ececf2; border-radius: 13px; }
.import-issues-table td small, .table-panel td small { display: block; margin-top: 3px; color: #8b8c9d; font-size: 11px; }
.issue-badge { display: inline-flex; min-width: 76px; justify-content: center; padding: 5px 8px; border-radius: 999px; font-size: 10px; font-style: normal; font-weight: 620; text-transform: uppercase; letter-spacing: .04em; }
.issue-badge.error { color: #9b3434; background: #fceaea; }
.issue-badge.warning { color: #7d5f17; background: #fff2ca; }
.status-badge.validated { color: #246845; background: #e9f7ef; }
.status-badge.needs_attention, .status-badge.failed { color: #9b3434; background: #fceaea; }
.status-badge.completed { color: #3d4698; background: #ebecfb; }
.status-badge.cancelled { color: #68697b; background: #eeeeF3; }
.status-badge.importing { color: #7d5f17; background: #fff2ca; }

@media (max-width: 1000px) {
  .import-layout { grid-template-columns: 1fr; }
  .import-form { grid-template-columns: 1fr 1fr; }
  .file-drop { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .import-form, .import-summary-grid { grid-template-columns: 1fr; }
  .import-actions { flex-direction: column; }
  .import-actions button { width: 100%; }
}

/* Fase 11.1: dashboard ejecutivo y sesión demo aislada */
.dashboard-primary-metrics .metric-card { min-height: 124px; padding: 18px 20px; }
.metric-icon { position: absolute !important; top: 16px; right: 17px; width: 34px; height: 34px; display: grid !important; place-items: center; border-radius: 11px; color: #fff !important; background: rgba(255,255,255,.16); }
.dashboard-secondary-metrics { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 12px; margin: -5px 0 18px; }
.dashboard-mini-metric { min-height: 91px; display: grid; align-content: center; gap: 4px; padding: 15px 17px; border: 1px solid #e6e7ee; border-radius: 15px; background: #fff; box-shadow: 0 7px 19px rgba(36,38,74,.04); }
.dashboard-mini-metric span,.dashboard-mini-metric small { color: #828397; font-size: 11px; }
.dashboard-mini-metric strong { color: #303146; font-size: 20px; font-weight: 630; letter-spacing: -.025em; }
.dashboard-main-grid { grid-template-columns: .88fr 1.12fr; }
.dashboard-trend-grid { grid-template-columns: 1.35fr .65fr; }
.aging-donut-layout { display: grid; grid-template-columns: minmax(180px,230px) 1fr; align-items: center; gap: 26px; padding: 22px 4px 5px; }
.aging-donut { width: min(100%,230px); aspect-ratio: 1; display: grid; place-items: center; margin: auto; border-radius: 50%; position: relative; box-shadow: inset 0 0 0 1px rgba(65,66,91,.04); }
.aging-donut::after { content: ''; position: absolute; inset: 22%; border-radius: 50%; background: #fff; box-shadow: 0 3px 17px rgba(49,50,78,.08); }
.aging-donut > div { z-index: 1; display: grid; gap: 3px; text-align: center; }
.aging-donut span,.aging-donut small { color: #85869a; font-size: 11px; }
.aging-donut strong { color: #303146; font-size: 19px; font-weight: 650; }
.aging-legend { display: grid; gap: 8px; }
.aging-legend > div { display: grid; grid-template-columns: 11px 1fr auto; align-items: center; gap: 9px; padding: 8px 0; border-bottom: 1px solid #efeff4; }
.aging-legend > div:last-child { border-bottom: 0; }
.aging-legend i { width: 10px; height: 10px; border-radius: 50%; }
.aging-legend span { display: grid; gap: 1px; }
.aging-legend span strong { color: #45465a; font-size: 12px; font-weight: 610; }
.aging-legend span small { color: #9495a5; font-size: 10px; }
.aging-legend b { color: #34354a; font-size: 12px; font-weight: 630; }
.dashboard-delinquent-table { margin-top: 3px; }
.dashboard-delinquent-table table { min-width: 680px; }
.dashboard-delinquent-table th,.dashboard-delinquent-table td { padding-top: 11px; padding-bottom: 11px; }
.overdue-days { display: grid; gap: 2px; }
.overdue-days strong { color: #a43d55; font-size: 12px; }
.overdue-days small { color: #999aaa; font-size: 10px; }
.dashboard-monthly-chart.expanded { height: 235px; gap: 7px; padding-left: 4px; padding-right: 4px; }
.dashboard-monthly-chart.expanded .dashboard-month > div { gap: 2px; }
.dashboard-monthly-chart .notes { background: #e76f83; }
.notes-legend { background: #e76f83; }
.upcoming-list { display: grid; padding-top: 8px; }
.upcoming-list > div { display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: 11px; padding: 14px 0; border-bottom: 1px solid #ececf2; }
.upcoming-list > div:last-child { border-bottom: 0; }
.upcoming-icon { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; color: #5146d8; background: #efeeff; }
.upcoming-icon.today { color: #a4334d; background: #ffe9ee; }
.upcoming-icon.next7 { color: #8b5a12; background: #fff3d9; }
.upcoming-list p { display: grid; gap: 2px; margin: 0; }
.upcoming-list p strong { color: #3a3b50; font-size: 13px; font-weight: 620; }
.upcoming-list p small { color: #9091a3; font-size: 11px; }
.upcoming-list b { color: #34354a; font-size: 13px; font-weight: 640; }
.demo-session-banner { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 34px; padding: 7px 16px; color: #5d4a17; background: #fff4cf; border-bottom: 1px solid #f0dda0; font-size: 12px; }
.demo-session-banner strong { font-weight: 650; }
.demo-session-banner span { color: #7e6a35; }
.app-shell.demo-mode .page-container { margin-top: 20px; }

@media (max-width: 1120px) {
  .dashboard-secondary-metrics { grid-template-columns: repeat(2,1fr); }
  .dashboard-main-grid,.dashboard-trend-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .dashboard-secondary-metrics { grid-template-columns: 1fr; }
  .aging-donut-layout { grid-template-columns: 1fr; }
  .dashboard-monthly-chart.expanded { overflow-x: auto; justify-content: flex-start; }
  .dashboard-monthly-chart.expanded .dashboard-month { min-width: 44px; }
  .demo-session-banner { align-items: flex-start; text-align: center; }
}
.demo-access-button { width: 100%; border: 1px solid #d8d5fa; border-radius: 12px; padding: 11px 15px; color: #5146d8; background: #f7f6ff; font-weight: 600; }
.demo-access-button:hover { background: #efedff; }

/* Fase 11.2: vendedores opcionales e importación histórica */
.feature-toggle-card { min-height: 72px; display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 12px; padding: 13px 15px; border: 1px solid #e4e5ed; border-radius: 13px; background: #fafafe; cursor: pointer; }
.feature-toggle-card input { width: 18px; height: 18px; margin: 0; accent-color: #5146d8; }
.feature-toggle-card span { display: grid; gap: 3px; color: #38394d; font-size: 13px; font-weight: 620; }
.feature-toggle-card small { color: #898a9b; font-size: 11px; font-weight: 400; line-height: 1.35; }
.import-detected-format { display: grid; grid-template-columns: minmax(0,1fr) minmax(180px,.45fr); gap: 12px; align-items: center; margin: 0 0 14px; padding: 13px 15px; border: 1px solid #e3e1fb; border-radius: 13px; background: #f7f6ff; }
.import-detected-format > div { display: grid; gap: 3px; }
.import-detected-format span { color: #85869a; font-size: 10px; text-transform: uppercase; letter-spacing: .055em; }
.import-detected-format strong { color: #3e3b76; font-size: 13px; font-weight: 650; }
.import-detected-format small { grid-column: 1 / -1; color: #6e6b91; font-size: 11px; }
@media (max-width: 680px) { .import-detected-format { grid-template-columns: 1fr; } .import-detected-format small { grid-column: auto; } }

/* Fase 11.3: reportes y exportaciones */
.hero-actions,.panel-actions { display:flex; align-items:center; justify-content:flex-end; gap:9px; flex-wrap:wrap; }
.hero-actions .secondary-button,.hero-actions .primary-button { min-height:42px; }
.panel-actions .secondary-button,.panel-actions .primary-button { min-height:38px; }
.report-tabs { flex-wrap:wrap; overflow-x:visible; }
.report-tabs button { flex:1 1 170px; }
.report-filter-grid { grid-template-columns: repeat(4,minmax(150px,1fr)); align-items:end; }
.report-filter-grid .report-wide-select { min-width:190px; }
.daily-chart { height:220px; }
.daily-chart .monthly-column { min-width:42px; }
.table-subtext { display:block; margin-top:3px; color:#9293a4; font-size:10px; }
@media (max-width:980px) { .report-filter-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media (max-width:680px) {
  .hero-actions,.panel-actions { width:100%; justify-content:stretch; }
  .hero-actions button,.panel-actions button { flex:1; }
  .report-filter-grid { grid-template-columns:1fr; }
  .report-tabs button { flex:1 1 100%; }
}

/* === FASE 1 · EDICIÓN LOCAL .OFIWORK === */
.workspace-gate { min-height: 100vh; display: grid; grid-template-columns: minmax(390px, 1.05fr) minmax(430px, .95fr); background: #f6f7fb; }
.workspace-brand-panel { position: relative; overflow: hidden; display: grid; align-content: center; gap: 20px; padding: clamp(44px, 7vw, 105px); color: #fff; background: radial-gradient(circle at 18% 12%, rgba(255,255,255,.2), transparent 31%), linear-gradient(145deg, #5146dd, #4437b9 50%, #218dbb); }
.workspace-brand-panel::after { content: ''; position: absolute; width: 420px; height: 420px; right: -180px; bottom: -185px; border: 1px solid rgba(255,255,255,.15); border-radius: 50%; box-shadow: 0 0 0 80px rgba(255,255,255,.035), 0 0 0 160px rgba(255,255,255,.02); }
.workspace-brand-panel > * { position: relative; z-index: 1; }
.workspace-brand-panel h1 { max-width: 720px; margin: 0; font-size: clamp(39px, 5vw, 67px); line-height: 1.02; font-weight: 620; letter-spacing: -.05em; }
.workspace-brand-panel > p { max-width: 620px; margin: 0; color: rgba(255,255,255,.82); font-size: 17px; line-height: 1.7; }
.workspace-feature-list { display: grid; gap: 13px; max-width: 620px; margin-top: 12px; }
.workspace-feature-list > div { display: grid; grid-template-columns: 42px 1fr; gap: 13px; align-items: center; padding: 14px 16px; border: 1px solid rgba(255,255,255,.16); border-radius: 15px; background: rgba(255,255,255,.08); backdrop-filter: blur(8px); }
.workspace-feature-list svg { padding: 9px; width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,.12); }
.workspace-feature-list span { display: grid; gap: 4px; }
.workspace-feature-list small { color: rgba(255,255,255,.7); line-height: 1.4; }
.workspace-action-panel { display: grid; align-content: center; justify-items: center; gap: 16px; padding: clamp(28px, 5vw, 76px); }
.workspace-action-card { width: min(650px, 100%); padding: clamp(27px, 4vw, 45px); border: 1px solid #e0e2ec; border-radius: 24px; background: #fff; box-shadow: 0 24px 70px rgba(38,40,78,.12); }
.workspace-action-card h2 { margin: 7px 0 8px; color: #2e3048; font-size: 29px; letter-spacing: -.035em; }
.workspace-action-card > p { margin: 0 0 22px; color: #737589; line-height: 1.6; }
.workspace-primary-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.workspace-primary-actions button { min-height: 52px; justify-content: center; }
.workspace-primary-actions button:only-child { grid-column: 1 / -1; width: min(100%, 320px); justify-self: center; }
.workspace-form { display: grid; gap: 15px; }
.workspace-buttons { display: flex; justify-content: flex-end; gap: 10px; margin-top: 7px; }
.recent-workspaces { display: grid; gap: 8px; margin-top: 25px; padding-top: 21px; border-top: 1px solid #e9eaf1; }
.recent-heading { display: grid; gap: 3px; margin-bottom: 3px; }
.recent-heading small { color: #898b9d; }
.recent-workspace { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 6px; padding: 7px; border: 1px solid #e5e6ed; border-radius: 14px; background: #fafafd; }
.recent-open { display: grid; grid-template-columns: 42px 1fr auto; align-items: center; gap: 11px; border: 0; padding: 3px; color: #313349; text-align: left; background: transparent; }
.recent-open > span:nth-child(2) { display: grid; gap: 3px; }
.recent-open small { color: #898b9d; }
.recent-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; color: #5146d9; background: #ecebff; }
.workspace-footnote { max-width: 620px; margin: 0; color: #858799; font-size: 12px; text-align: center; }
.local-hero { display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.local-hero h1 { margin: 5px 0 4px; font-size: clamp(28px, 4vw, 42px); }
.local-hero p { margin: 0; color: #78798c; }
.local-metric-grid .metric-card strong { font-size: 18px; line-height: 1.25; }
.local-metric-grid .metric-card p { margin: 7px 0 0; color: #858699; font-size: 12px; line-height: 1.45; }
.local-storage-grid { align-items: stretch; }
.local-action-list { display: grid; margin-top: 4px; }
.local-action-list button { display: grid; grid-template-columns: 42px 1fr auto; align-items: center; gap: 12px; padding: 15px 0; border: 0; border-bottom: 1px solid #ededf2; color: #33354b; text-align: left; background: transparent; }
.local-action-list button:last-child { border-bottom: 0; }
.local-action-list button > span:nth-child(2) { display: grid; gap: 4px; }
.local-action-list small { color: #888a9b; line-height: 1.35; }
.action-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; color: #5146da; background: #eeedff; }
.phase-checklist { display: grid; gap: 10px; padding-top: 17px; }
.phase-checklist > div { display: flex; align-items: center; gap: 10px; padding: 12px 13px; border-radius: 11px; }
.phase-checklist .done { color: #176c4a; background: #e9f8f1; }
.phase-checklist .next { color: #665215; background: #fff7df; }
.local-placeholder { min-height: 540px; display: grid; place-items: center; align-content: center; justify-items: center; gap: 12px; text-align: center; }
.local-placeholder h1 { margin: 0; font-size: 34px; }
.local-placeholder p { max-width: 690px; margin: 0; color: #76788c; line-height: 1.65; }
.local-placeholder .message { max-width: 690px; margin-top: 8px; }
.placeholder-icon { width: 64px; height: 64px; display: grid; place-items: center; border-radius: 18px; color: #5146da; background: #ecebff; }
@media (max-width: 980px) { .workspace-gate { grid-template-columns: 1fr; } .workspace-brand-panel { min-height: 520px; } }
@media (max-width: 620px) { .workspace-brand-panel { min-height: auto; padding: 42px 25px; } .workspace-action-panel { padding: 18px; } .workspace-action-card { padding: 25px 20px; border-radius: 19px; } .workspace-primary-actions { grid-template-columns: 1fr; } .local-hero { align-items: flex-start; flex-direction: column; } .local-hero .hero-actions { width: 100%; } }

/* === FASE 2 · CATÁLOGOS LOCALES === */
.catalog-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:24px; margin-bottom:18px; }
.catalog-heading h1 { margin:5px 0 5px; font-size:clamp(28px,4vw,40px); letter-spacing:-.035em; }
.catalog-heading p { margin:0; color:#77798d; line-height:1.6; }
.catalog-summary-grid { margin-bottom:18px; }
.local-settings-shell { display:grid; gap:14px; }
.local-settings-shell .settings-tabs { display:flex; gap:6px; overflow-x:auto; padding:6px; border:1px solid #e5e6ed; border-radius:14px; background:#fff; }
.local-settings-shell .settings-tabs button { min-height:39px; padding:0 16px; border:0; border-radius:10px; color:#6d6f84; font-weight:620; white-space:nowrap; background:transparent; }
.local-settings-shell .settings-tabs button.active { color:#4f46d9; background:#eeedff; }
.settings-panel,.catalog-panel { overflow:hidden; }
.settings-panel .panel-heading p,.catalog-panel .panel-heading p { margin:5px 0 0; color:#858699; font-size:12px; line-height:1.45; }
.settings-form-grid { padding-top:18px; }
.panel-actions { padding-top:18px; border-top:1px solid #ededf2; margin-top:20px; }
.catalog-panel .panel-heading { align-items:flex-start; gap:20px; }
.catalog-table td > strong { display:block; color:#33354a; }
.catalog-table td > small,.rule-summary small { display:block; margin-top:3px; color:#8b8d9e; font-size:10px; line-height:1.4; }
.catalog-table .table-actions { min-width:150px; }
.table-actions { display:flex; align-items:center; justify-content:flex-end; gap:7px; }
.text-action { border:0; padding:6px 8px; color:#5b55bd; font-size:11px; font-weight:650; background:transparent; }
.status-badge { display:inline-flex; align-items:center; min-height:25px; padding:0 9px; border-radius:999px; font-size:10px; font-weight:620; letter-spacing:.02em; }
.status-badge.active { color:#176c4a; background:#e7f7ef; }
.status-badge.inactive { color:#7f5360; background:#f7ecef; }
.rule-summary { display:grid; gap:2px; min-width:165px; color:#505267; font-size:11px; }
.catalog-modal { width:min(690px,calc(100vw - 28px)); }
.entity-form { padding:0 24px 24px; }
.rule-note { display:flex; align-items:flex-start; gap:9px; margin:17px 0 0; padding:12px 14px; border:1px solid #dddafa; border-radius:12px; color:#5b5790; background:#f6f5ff; font-size:11px; line-height:1.45; }
.sequence-list { display:grid; gap:9px; padding-top:17px; }
.sequence-row { display:grid; grid-template-columns:minmax(170px,1fr) repeat(3,minmax(105px,.45fr)); gap:11px; align-items:end; padding:14px; border:1px solid #e7e8ee; border-radius:13px; background:#fafafd; }
.sequence-row > div { display:grid; gap:4px; align-self:center; }
.sequence-row > div small { color:#858799; }
.sequence-row label { display:grid; gap:5px; color:#77798c; font-size:10px; font-weight:650; }
.sequence-row input { width:100%; min-height:37px; border:1px solid #dfe0e8; border-radius:9px; padding:0 10px; background:#fff; }
.health-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:11px; padding-top:15px; }
.health-grid > div { display:grid; gap:5px; padding:14px; border:1px solid #e8e8ef; border-radius:12px; background:#fafafd; }
.health-grid small { color:#8a8b9d; text-transform:uppercase; letter-spacing:.04em; font-size:9px; }
.health-grid strong { color:#3b3d53; font-size:13px; }
.local-health-panel { margin-top:18px; }
@media (max-width:920px) { .sequence-row { grid-template-columns:1fr 1fr; } .sequence-row > div { grid-column:1/-1; } .health-grid { grid-template-columns:1fr 1fr; } }
@media (max-width:680px) { .catalog-heading { flex-direction:column; } .catalog-heading .heading-actions { width:100%; } .catalog-heading .heading-actions button { width:100%; justify-content:center; } .catalog-panel .panel-heading { flex-direction:column; } .catalog-panel .panel-heading button { width:100%; justify-content:center; } .sequence-row { grid-template-columns:1fr; } .sequence-row > div { grid-column:auto; } .health-grid { grid-template-columns:1fr; } .catalog-table { min-width:760px; } }
.local-metric-grid .metric-card,.catalog-summary-grid .metric-card { min-height:150px; color:#33354b; border:1px solid #e6e7ee; background:#fff; }
.local-metric-grid .metric-card::after,.catalog-summary-grid .metric-card::after { background:rgba(80,70,217,.045); }
.local-metric-grid .metric-card small,.catalog-summary-grid .metric-card small { color:#8b8c9e; }
.local-metric-grid .metric-card strong,.catalog-summary-grid .metric-card strong { color:#33354b; }
.local-metric-grid .metric-card > .metric-icon,.catalog-summary-grid .metric-card > .metric-icon { display:grid; width:40px; height:40px; place-items:center; margin-bottom:13px; border-radius:12px; }
.local-metric-grid .metric-card > .metric-icon.purple,.catalog-summary-grid .metric-card > .metric-icon.purple { color:#5a50d7; background:#efedff; }
.local-metric-grid .metric-card > .metric-icon.blue,.catalog-summary-grid .metric-card > .metric-icon.blue { color:#347bb7; background:#e7f4ff; }
.local-metric-grid .metric-card > .metric-icon.green,.catalog-summary-grid .metric-card > .metric-icon.green { color:#178c62; background:#e6f8f1; }
.local-metric-grid .metric-card > .metric-icon.orange,.catalog-summary-grid .metric-card > .metric-icon.orange { color:#b36a1c; background:#fff2e2; }

/* Fase 3 — clientes, historial de rutas e importación */
.customer-modal{width:min(980px,calc(100vw - 32px));max-height:calc(100vh - 32px);overflow:auto}
.history-modal{width:min(720px,calc(100vw - 32px));max-height:calc(100vh - 32px);overflow:auto}
.row-actions{display:flex;align-items:center;justify-content:flex-end;gap:6px;flex-wrap:wrap}
.muted{color:var(--muted,#718096);font-size:.9rem}
.customers-table td small,.responsive-table td small{display:block;margin-top:4px;color:var(--muted,#718096);line-height:1.35}
.history-timeline{padding:4px 24px 22px;display:grid;gap:0}
.history-timeline article{position:relative;display:grid;grid-template-columns:20px 1fr;gap:14px;padding:0 0 22px}
.history-timeline article:not(:last-child)::before{content:"";position:absolute;left:6px;top:14px;bottom:0;width:2px;background:#e8e5f4}
.history-dot{position:relative;z-index:1;width:14px;height:14px;margin-top:4px;border-radius:50%;background:#6c4ee3;box-shadow:0 0 0 4px #eeeafe}
.history-timeline strong{display:block;color:#24213a}
.history-timeline small{display:block;margin-top:5px;color:#77728b}
.history-timeline p{margin:7px 0 0;color:#4e4962}
.button-link{text-decoration:none;display:inline-flex;align-items:center;justify-content:center}
.status-badge.validated,.status-badge.committed{background:#e8f8ef;color:#166534}
.status-badge.rejected{background:#ffeded;color:#b42318}
.import-result-panel{margin-top:22px}
.import-entity-grid small{display:block}
.file-drop input{position:absolute;opacity:0;pointer-events:none}
.file-drop{position:relative;cursor:pointer}
@media(max-width:780px){.row-actions{justify-content:flex-start}.customer-modal,.history-modal{width:calc(100vw - 16px);max-height:calc(100vh - 16px)}.history-timeline{padding-inline:16px}}

/* Fase 4 — Facturas y transacciones atómicas */
.atomic-banner{display:flex;align-items:center;gap:14px;padding:18px 20px;margin-bottom:18px;border:1px solid rgba(69,181,134,.28);background:linear-gradient(135deg,rgba(69,181,134,.1),rgba(79,70,217,.06))}.atomic-banner>span{width:44px;height:44px;border-radius:14px;display:grid;place-items:center;background:#e9f8f1;color:#16845d}.atomic-banner div{display:grid;gap:4px}.atomic-banner small{color:var(--muted,#667085)}
.invoice-status{display:inline-flex;align-items:center;border-radius:999px;padding:5px 9px;font-size:12px;font-weight:650;white-space:nowrap}.invoice-status.draft{background:#f3f4f6;color:#475467}.invoice-status.issued{background:#eef4ff;color:#2758b8}.invoice-status.partially_paid{background:#fff4e5;color:#9a5b00}.invoice-status.paid{background:#e9f8f1;color:#137a57}.invoice-status.void{background:#fff0f0;color:#b42318}.primary-table-action{color:#4338ca!important;background:#eef2ff!important}
.invoice-form{min-width:min(1000px,92vw)}.invoice-lines-header{display:flex;align-items:center;justify-content:space-between;margin:22px 0 10px}.invoice-lines-header h3{margin:3px 0 0}.compact-button{padding:9px 12px}.invoice-lines{display:grid;gap:10px}.invoice-line{display:grid;grid-template-columns:34px minmax(220px,1fr) 90px 120px 90px 90px 38px;gap:10px;align-items:end;padding:12px;border:1px solid #e7e9f1;border-radius:14px;background:#fbfcff}.invoice-line label{display:grid;gap:6px;font-size:11px;font-weight:600;color:#667085;text-transform:uppercase;letter-spacing:.04em}.invoice-line input{width:100%;padding:10px;border:1px solid #d8dce8;border-radius:10px;background:#fff;font:inherit;color:#1d2939}.line-index{width:28px;height:28px;border-radius:9px;display:grid;place-items:center;background:#eef2ff;color:#4338ca;font-weight:650;margin-bottom:5px}.invoice-live-total{margin-top:12px;text-align:right;font-size:18px;font-weight:650;color:#25236a}.span-three{grid-column:span 3}.issue-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin-bottom:18px}.issue-summary>div{padding:13px;border:1px solid #e7e9f1;border-radius:12px;background:#fbfcff;display:grid;gap:5px}.issue-summary small{color:#667085}.credit-check{padding:14px 16px;border-radius:12px;background:#e9f8f1;color:#137a57;margin:12px 0;display:grid;gap:4px}.credit-check.over{background:#fff4e5;color:#9a5b00}.invoice-detail{padding:0 22px 22px}.invoice-totals{margin:18px 0 0 auto;max-width:360px;display:grid;gap:8px}.invoice-totals span{display:flex;justify-content:space-between;padding:4px 0}.invoice-totals .grand-total{font-size:18px;border-top:1px solid #d8dce8;padding-top:12px}.invoice-table td small,.invoice-table td strong{display:block}.catalog-modal:has(.invoice-form){width:min(1120px,96vw);max-width:1120px}.catalog-modal:has(.invoice-detail){width:min(980px,96vw);max-width:980px}
@media(max-width:900px){.invoice-line{grid-template-columns:30px 1fr 1fr}.invoice-line label:first-of-type{grid-column:span 2}.invoice-line .remove-line{align-self:center}.issue-summary{grid-template-columns:1fr 1fr}.span-three{grid-column:span 2}}
@media(max-width:620px){.invoice-line{grid-template-columns:28px 1fr}.invoice-line label:first-of-type{grid-column:auto}.issue-summary{grid-template-columns:1fr}.span-three{grid-column:span 1}}

/* Fase 5 — Cobros, aplicaciones y referencias centralizadas */
.receipt-applications{display:grid;gap:10px;margin:20px 0;padding:16px;border:1px solid #e7e9f1;border-radius:14px;background:#fbfcff}.receipt-applications h3{margin:0;color:#25236a}.receipt-applications>p{margin:0 0 4px;color:#667085;font-size:12px;line-height:1.5}.application-row-f05{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:12px 14px;border:1px solid #e2e5ef;border-radius:12px;background:#fff}.application-row-f05>span{display:grid;gap:4px}.application-row-f05 small{color:#667085}.application-row-f05 input{width:140px;min-height:40px;padding:0 10px;border:1px solid #d8dce8;border-radius:10px;text-align:right}.receipt-status{display:inline-flex;align-items:center;border-radius:999px;padding:5px 9px;font-size:12px;font-weight:650;white-space:nowrap}.receipt-status.posted{color:#137a57;background:#e9f8f1}.receipt-status.void{color:#b42318;background:#fff0f0}.receipt-status.replaced{color:#7b4d12;background:#fff4e5}.receipt-source{display:inline-flex;align-items:center;padding:4px 8px;border-radius:8px;color:#4338ca;background:#eef2ff;font-size:11px;font-weight:650}.receipt-unapplied{color:#9a5b00;font-weight:650}.receipt-detail{padding:0 22px 22px}.receipt-detail-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.receipt-detail-grid>div{display:grid;gap:5px;padding:13px;border:1px solid #e7e9f1;border-radius:12px;background:#fbfcff}.receipt-detail-grid small{color:#667085}.receipt-application-list{display:grid;gap:8px;margin-top:18px}.receipt-application-list article{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 14px;border:1px solid #e7e9f1;border-radius:12px}.receipt-application-list article>span{display:grid;gap:4px}.receipt-application-list small{color:#667085}.warning-message{border:1px solid #f2d18a;background:#fff8e6;color:#805800}.catalog-modal:has(.receipt-applications){width:min(980px,96vw);max-width:980px}
@media(max-width:720px){.application-row-f05{align-items:stretch;flex-direction:column}.application-row-f05 input{width:100%}.receipt-detail-grid{grid-template-columns:1fr}.receipt-application-list article{align-items:flex-start;flex-direction:column}}
.invoice-editor{padding:20px;margin-bottom:18px}.invoice-editor>form{display:grid;gap:18px}.invoice-editor .panel-heading{margin-bottom:14px}.application-grid{display:grid;gap:10px;padding:16px;border:1px solid #e7e9f1;border-radius:14px;background:#fbfcff}.application-grid h3{margin:0 0 4px;color:#25236a}.application-grid>p{margin:0;color:#667085}.application-row{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:12px 14px;border:1px solid #e2e5ef;border-radius:12px;background:#fff}.application-row>span{display:grid;gap:4px}.application-row small{color:#667085}.application-row input{width:140px;min-height:40px;padding:0 10px;border:1px solid #d8dce8;border-radius:10px;text-align:right}
@media(max-width:720px){.application-row{align-items:stretch;flex-direction:column}.application-row input{width:100%}}


/* Fase 6 — Notas de crédito, estado de cuenta, antigüedad y auditoría */
.page-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:24px;margin-bottom:18px}.page-heading h1{margin:5px 0 5px;font-size:clamp(28px,4vw,40px);letter-spacing:-.035em}.page-heading p{margin:0;color:#77798d;line-height:1.6}.compact-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}.compact-form{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.compact-form label{display:grid;gap:6px;color:#667085;font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.04em}.compact-form input,.compact-form select{width:100%;min-height:42px;padding:0 11px;border:1px solid #d8dce8;border-radius:10px;background:#fff;color:#1d2939;font:inherit}.credit-note-status{display:inline-flex;align-items:center;border-radius:999px;padding:5px 9px;font-size:12px;font-weight:650;white-space:nowrap}.credit-note-status.draft{background:#f3f4f6;color:#475467}.credit-note-status.issued{background:#eef4ff;color:#2758b8}.credit-note-status.partially_applied{background:#fff4e5;color:#9a5b00}.credit-note-status.applied{background:#e9f8f1;color:#137a57}.credit-note-status.void{background:#fff0f0;color:#b42318}.credit-note-form{display:grid;gap:18px;padding:0 24px 24px}.credit-application-grid{display:grid;gap:10px;padding:16px;border:1px solid #e7e9f1;border-radius:14px;background:#fbfcff}.credit-application-grid h3{margin:0;color:#25236a}.credit-application-row{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:12px 14px;border:1px solid #e2e5ef;border-radius:12px;background:#fff}.credit-application-row>span{display:grid;gap:4px}.credit-application-row small{color:#667085}.credit-application-row input{width:140px;min-height:40px;padding:0 10px;border:1px solid #d8dce8;border-radius:10px;text-align:right}.credit-note-detail{padding:0 22px 22px}.detail-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.detail-list p{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin:0;padding:12px 14px;border:1px solid #e7e9f1;border-radius:12px;background:#fbfcff}.detail-list span{color:#667085}.detail-list strong{text-align:right}.aging-grid{grid-template-columns:repeat(6,minmax(0,1fr))}.metric-card.emphasis{border-color:rgba(79,70,217,.28);background:linear-gradient(145deg,#f6f5ff,#fff)}.metric-card.emphasis strong{color:#4338ca}.statement-footer{margin:18px 22px 22px;padding-top:16px;border-top:1px solid #e7e9f1;color:#667085;font-size:12px;line-height:1.6;white-space:pre-line}.audit-json{max-height:360px;overflow:auto;margin:0 22px 22px;padding:16px;border:1px solid #e2e5ef;border-radius:12px;background:#111827;color:#d1fae5;font:12px/1.65 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;white-space:pre-wrap;word-break:break-word}.audit-detail{padding:0 22px 22px}.audit-detail h3{margin:18px 0 10px}.statement-table td,.statement-table th{white-space:nowrap}.statement-table td:nth-child(3){min-width:260px;white-space:normal}.aging-table td:nth-child(2){min-width:210px}.print-only{display:none}
@media(max-width:1100px){.aging-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.compact-form{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){.page-heading{flex-direction:column}.page-heading .heading-actions{width:100%}.compact-metrics,.aging-grid,.compact-form,.detail-list{grid-template-columns:1fr}.credit-application-row{align-items:stretch;flex-direction:column}.credit-application-row input{width:100%}}
@media print{.side-nav,.topbar,.hero-actions,.heading-actions,.secondary-button,.primary-button,.table-action,.catalog-toolbar,.workspace-sync-bar,.no-print{display:none!important}.app-layout,.main-content{display:block!important;margin:0!important;padding:0!important}.panel,.hero-card,.metric-card{box-shadow:none!important;break-inside:avoid}.responsive-table{overflow:visible!important}table{font-size:10px}.print-only{display:block}}

/* Fase 7: dashboard financiero y reportes locales */
.metric-button { width: 100%; border: 0; text-align: left; cursor: pointer; font: inherit; }
.metric-button:hover { transform: translateY(-2px); box-shadow: 0 15px 34px rgba(45,46,88,.12); }
.dashboard-lists-grid { grid-template-columns: 1fr 1fr; }
.dashboard-list { display: grid; padding-top: 4px; }
.dashboard-list > button { width: 100%; display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 16px; padding: 12px 2px; border: 0; border-bottom: 1px solid #ececf2; color: inherit; background: transparent; text-align: left; cursor: pointer; }
.dashboard-list > button:last-child { border-bottom: 0; }
.dashboard-list > button:hover { padding-left: 8px; padding-right: 8px; border-radius: 10px; background: #f8f7ff; }
.dashboard-list > button > span { display: grid; gap: 3px; }
.dashboard-list > button > span:last-child { text-align: right; }
.dashboard-list strong { color: #34354a; font-size: 13px; font-weight: 640; }
.dashboard-list small { color: #9091a3; font-size: 10px; }
.dashboard-list p { color: #858699; }
.dashboard-health { margin-top: 18px; }
.report-controls { margin-bottom: 16px; padding: 8px 16px 16px; }
.report-filter-grid { grid-template-columns: repeat(4,minmax(160px,1fr)); }
.report-filter-grid label { display: grid; gap: 7px; color: #5a5b6e; font-size: 12px; font-weight: 600; }
.report-filter-grid input,.report-filter-grid select { min-height: 42px; border: 1px solid #dfe1eb; border-radius: 12px; padding: 0 12px; color: #3d3e53; background: #fff; font: inherit; font-weight: 400; }
.report-hero .hero-actions { flex-wrap: wrap; }
@media (max-width: 980px) { .dashboard-lists-grid { grid-template-columns: 1fr; } .report-filter-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 620px) { .report-filter-grid { grid-template-columns: 1fr; } .dashboard-list > button { grid-template-columns: 1fr; } .dashboard-list > button > span:last-child { text-align: left; } }

/* Fase 8 — Multiempresa, planes y puente F10/AppHub */
.license-strip{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:9px 28px;background:#eef6ff;border-bottom:1px solid #cfe3f7;color:#284b68;font-size:.84rem}.license-strip button{border:0;background:transparent;color:#0f6cbd;font:inherit;font-weight:600;cursor:pointer}.organization-control{display:flex;align-items:center;gap:8px;min-width:210px;padding:7px 10px;border:1px solid #dce5ee;border-radius:11px;background:#fff;color:#526577}.organization-control select{min-width:150px;border:0;background:transparent;color:#203040;font:inherit;font-weight:620;outline:0}.license-gate .workspace-action-card{max-width:560px}.plan-summary{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:18px 0;padding:13px 15px;border:1px solid #d8e7f5;border-radius:13px;background:#f6faff}.plan-summary strong{color:#173a55}.plan-summary span{color:#5b6d7d;font-size:.87rem}.recovery-link,.link-button{display:block;margin:17px auto 0;border:0;background:transparent;color:#0f6cbd;font:inherit;font-weight:620;text-decoration:underline;cursor:pointer}.license-ok{color:#25895f!important}.license-pending{color:#b07812!important}.license-company-list{display:grid;gap:12px;margin-top:18px}.license-company-card{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:14px;padding:15px;border:1px solid #e0e8ef;border-radius:14px;background:#fff}.license-company-card>div{display:grid;gap:3px;min-width:0}.license-company-card strong{color:#1b3042}.license-company-card small{color:#6e7d8a;overflow-wrap:anywhere}.app-loading{display:grid;place-items:center;min-height:100vh;color:#526577;font-weight:620}.message.info-message{background:#eef7ff;border-color:#beddf5;color:#28536f}.empty-state{padding:28px;border:1px dashed #c9d6e1;border-radius:14px;text-align:center;color:#6c7d89}.workspace-feature-list small{display:block;margin-top:2px}.workspace-feature-list strong{display:block}.user-chip{max-width:260px}.user-chip div{min-width:0}.user-chip strong,.user-chip small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
@media(max-width:980px){.organization-control{min-width:0}.organization-control select{min-width:110px}.user-chip{display:none}.license-strip{padding-inline:18px}}
@media(max-width:680px){.license-strip{align-items:flex-start;flex-direction:column;gap:5px}.organization-control{max-width:180px}.organization-control select{max-width:130px}.license-company-card{grid-template-columns:auto minmax(0,1fr)}.license-company-card .secondary-button{grid-column:1/-1;width:100%}.plan-summary{align-items:flex-start;flex-direction:column}.topbar-actions{gap:6px}}

/* Fase 9: actualización segura, offline y migración cloud */
.ofi-update-banner{position:fixed;left:50%;bottom:22px;transform:translateX(-50%);z-index:99999;max-width:min(760px,calc(100vw - 28px));width:max-content;background:#172554;color:#fff;border:1px solid rgba(255,255,255,.18);box-shadow:0 18px 55px rgba(15,23,42,.35);border-radius:16px;padding:14px 16px;display:flex;gap:22px;align-items:center}.ofi-update-banner>div:first-child{display:grid;gap:3px}.ofi-update-banner span{font-size:13px;color:#dbeafe}.ofi-update-actions{display:flex;gap:8px}.ofi-update-actions button{border:0;border-radius:9px;padding:9px 12px;font-weight:620;cursor:pointer}.ofi-update-actions button:first-child{background:#fff;color:#172554}.ofi-update-actions button:last-child{background:rgba(255,255,255,.12);color:#fff}.offline-license-badge{background:#fff7ed;color:#9a3412;border:1px solid #fed7aa;border-radius:999px;padding:4px 9px;font-size:12px;font-weight:650}.migration-cloud-card{border:1px solid #c7d2fe;background:linear-gradient(135deg,#eef2ff,#fff);border-radius:18px;padding:18px}.migration-cloud-grid{display:grid;grid-template-columns:repeat(5,minmax(120px,1fr));gap:10px}.migration-cloud-grid article{background:#fff;border:1px solid #e2e8f0;border-radius:12px;padding:12px}.migration-cloud-grid span{display:block;color:#64748b;font-size:12px}.migration-cloud-grid strong{display:block;font-size:21px;margin-top:4px}.qa-status-card{display:flex;align-items:center;gap:12px;border:1px solid #bbf7d0;background:#f0fdf4;padding:14px;border-radius:14px}@media(max-width:760px){.ofi-update-banner{width:calc(100vw - 28px);align-items:flex-start;flex-direction:column;gap:10px}.migration-cloud-grid{grid-template-columns:repeat(2,1fr)}}

/* Ajuste UX y empresa demo */
.demo-workspace-banner{display:flex;align-items:center;justify-content:space-between;gap:18px;margin:0 0 14px;padding:16px 18px;border:1px solid #c7d2fe;border-radius:16px;background:linear-gradient(135deg,#eef2ff,#ffffff);box-shadow:0 8px 24px rgba(79,70,229,.08)}.demo-workspace-banner>div{display:grid;gap:4px}.demo-workspace-banner strong{font-size:16px;color:#1e1b4b}.demo-workspace-banner small{color:#64748b;line-height:1.45}.demo-workspace-banner .primary-button{white-space:nowrap}@media(max-width:760px){.demo-workspace-banner{align-items:flex-start;flex-direction:column}.demo-workspace-banner .primary-button{width:100%}}


/* Fase 10.2 — navegación, tablas y acciones */
.categorized-launcher{display:grid;gap:10px;padding-top:12px}
.categorized-launcher .launcher-group{margin:0;border-radius:14px;overflow:hidden}
.categorized-launcher .launcher-group-heading{cursor:default;padding:10px 13px;background:#f9f9fc;border-bottom:1px solid #ececf3}
.categorized-launcher .launcher-grid{display:grid;grid-template-columns:1fr;gap:0;padding:0;background:#fff}
.categorized-launcher .launcher-item{min-height:64px;display:grid;grid-template-columns:42px minmax(0,1fr) 18px;align-items:center;gap:12px;padding:10px 13px;border:0;border-bottom:1px solid #efeff5;border-radius:0;text-align:left;background:#fff;color:#34354a}
.categorized-launcher .launcher-item:last-child{border-bottom:0}
.categorized-launcher .launcher-item:hover{background:#f7f6ff}
.categorized-launcher .launcher-item.active{background:#f0efff}
.categorized-launcher .launcher-item-icon{width:40px;height:40px;display:grid;place-items:center;border-radius:12px;color:#5146d8;background:#eeedff}
.categorized-launcher .launcher-item-copy{display:grid;gap:2px;min-width:0}
.categorized-launcher .launcher-item strong{font-size:13px;font-weight:620}
.categorized-launcher .launcher-item small{color:#85869a;font-size:11px;line-height:1.3}
.row-action-control{display:inline-flex;min-width:132px}
.row-action-select{width:100%;min-width:132px;min-height:36px;border:1px solid #d8dbe7;border-radius:9px;padding:0 30px 0 10px;color:#35364b;background:#fff;font:inherit;font-size:12px;font-weight:650;cursor:pointer;outline:0}
.row-action-select:hover{border-color:#aaa5eb;background:#faf9ff}
.row-action-select:focus{border-color:#655ae5;box-shadow:0 0 0 3px rgba(81,70,216,.1)}
.actions-column,.actions-cell{width:150px;min-width:150px;text-align:right!important}
.actions-cell .row-action-control,.actions-cell .row-action-select{margin-left:auto}
.responsive-table table{min-width:820px}
.responsive-table th{position:sticky;top:0;z-index:1}
.responsive-table tbody tr:hover{background:#fbfbfe}
.responsive-table td{padding-top:11px;padding-bottom:11px}
.catalog-toolbar{align-items:center}
.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
@media(max-width:760px){.launcher-panel{width:min(520px,100%)}.categorized-launcher .launcher-item{min-height:58px}.actions-column,.actions-cell{width:135px;min-width:135px}.row-action-select{min-width:118px}.responsive-table table{min-width:760px}}

/* Fase 10.3 — compactación visual y jerarquía de interfaz */
:root{--ofi-density-gap:10px;--ofi-control-h:38px;--ofi-panel-radius:15px}
body{font-size:14px;line-height:1.4}
.topbar{min-height:60px;gap:14px;padding:7px 14px;box-shadow:0 2px 12px rgba(49,43,144,.22)}
.brand-button{gap:9px}.brand-mark{width:38px;height:38px;border-radius:11px;font-size:14px}.brand-copy strong{font-size:15px}.brand-copy small{font-size:10px}
.topbar-actions{gap:7px}.topbar-icon-button{width:38px;height:38px;border-radius:10px}.topbar-divider{height:28px}.user-chip{gap:7px;padding:3px 6px 3px 3px;border-radius:10px}.user-chip>span{width:32px;height:32px;border-radius:8px}.user-chip strong{font-size:12px}.user-chip small{font-size:10px}
.organization-control{min-width:200px;min-height:38px;padding:4px 8px;border-radius:10px}.organization-control select{padding-top:6px;padding-bottom:6px;font-size:12px}
.logout-button{min-height:38px;padding:0 10px;border-radius:9px;font-size:12px}
.license-strip{min-height:32px;padding:6px 20px;font-size:11px}.license-strip button{font-size:11px}
.demo-session-banner{min-height:30px;padding:5px 12px;font-size:11px}
.page-container{width:min(1480px,calc(100% - 28px));margin:14px auto 36px}
.panel,.hero-card,.metric-card{border-radius:var(--ofi-panel-radius);box-shadow:0 5px 18px rgba(36,38,74,.045)}
.panel{padding:16px}
.hero-card,.compact-hero{min-height:0;padding:14px 18px;gap:18px;align-items:center}
.hero-card h1,.compact-hero h1{margin:2px 0 3px;font-size:clamp(24px,2.35vw,31px);line-height:1.08}
.hero-card p,.compact-hero p{max-width:900px;font-size:12px;line-height:1.38}
.eyebrow{font-size:9px;letter-spacing:.12em}
.hero-actions{gap:7px}.hero-actions .primary-button,.hero-actions .secondary-button,.hero-actions .danger-button{min-height:38px;padding:0 13px;border-radius:10px;font-size:12px;box-shadow:none}
.primary-button,.secondary-button,.danger-button{min-height:38px;padding:0 13px;border-radius:10px;font-size:12px}.text-button{padding:5px 0;font-size:12px}
.metric-grid{gap:10px;margin:10px 0}.metric-card{min-height:98px;padding:13px 14px}.metric-card span{font-size:11px}.metric-card strong{margin:4px 0 2px;font-size:clamp(20px,2vw,25px)}.metric-card small{font-size:10px;line-height:1.3}.metric-card::after{width:92px;height:92px;right:-30px;bottom:-40px}
.local-metric-grid .metric-card,.catalog-summary-grid .metric-card{min-height:92px;padding:13px 14px}.local-metric-grid .metric-card>.metric-icon,.catalog-summary-grid .metric-card>.metric-icon{width:32px;height:32px;margin-bottom:7px;border-radius:9px}.local-metric-grid .metric-card strong,.catalog-summary-grid .metric-card strong{font-size:18px}.local-metric-grid .metric-card p{margin-top:4px;font-size:10px;line-height:1.3}
.catalog-summary-grid{gap:9px;margin:10px 0 12px}.catalog-summary-grid article{min-height:68px;gap:2px;padding:9px 12px;border-radius:12px}.catalog-summary-grid span{font-size:10px}.catalog-summary-grid strong{font-size:18px}
.dashboard-secondary-metrics{gap:9px;margin:0 0 12px}.dashboard-secondary-metrics article{min-height:68px;padding:10px 12px;border-radius:12px}.dashboard-secondary-metrics span,.dashboard-secondary-metrics small{font-size:10px}.dashboard-secondary-metrics strong{font-size:17px}
.dashboard-grid,.dashboard-main-grid,.dashboard-trend-grid,.dashboard-lists-grid{gap:12px;margin-bottom:12px}.panel-heading{gap:12px;padding-bottom:9px}.panel-heading.compact{padding-bottom:8px}.panel-heading h2{margin-top:2px;font-size:17px}.panel-heading>span,.panel-heading p{font-size:10px}
.aging-donut-layout{grid-template-columns:minmax(150px,185px) 1fr;gap:18px;padding:14px 0 2px}.aging-donut{width:min(100%,185px)}.aging-donut strong{font-size:16px}.aging-donut span,.aging-donut small{font-size:9px}.aging-legend{gap:7px}.aging-legend>div{min-height:27px;font-size:11px}
.monthly-chart{min-height:190px}.dashboard-monthly-chart{padding-top:12px}.dashboard-list>button{gap:12px;padding:8px 2px}.dashboard-list strong{font-size:12px}.dashboard-list small{font-size:9px}
.local-action-list{grid-template-columns:repeat(2,minmax(0,1fr));column-gap:18px}.local-action-list button{grid-template-columns:34px 1fr auto;gap:9px;padding:9px 0}.local-action-list button>span:first-child,.local-action-list .action-icon{width:32px;height:32px}.local-action-list button>span:nth-child(2){gap:1px}.local-action-list strong{font-size:12px}.local-action-list small{font-size:9px;line-height:1.25}
.phase-checklist{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;padding-top:10px}.phase-checklist>div{gap:7px;min-height:34px;padding:7px 9px;border-radius:9px;font-size:11px}.phase-checklist .next{grid-column:1/-1}.dashboard-health{margin-top:10px}.health-grid{gap:7px;padding-top:9px}.health-grid>div{gap:2px;padding:8px 9px;border-radius:9px}.health-grid small{font-size:8px}.health-grid strong{font-size:11px}
.message{margin-bottom:10px;padding:8px 11px;border-radius:9px;font-size:12px;line-height:1.35}.message strong{font-weight:650}
.atomic-banner{min-height:44px;gap:9px;padding:7px 10px;margin-bottom:10px;border-radius:11px;box-shadow:none}.atomic-banner>span{width:30px;height:30px;border-radius:9px;flex:0 0 auto}.atomic-banner div{gap:1px}.atomic-banner strong{font-size:12px}.atomic-banner small{font-size:10px;line-height:1.3}
.demo-workspace-banner{gap:12px;margin-bottom:10px;padding:10px 12px;border-radius:12px;box-shadow:none}.demo-workspace-banner>div{gap:1px}.demo-workspace-banner strong{font-size:13px}.demo-workspace-banner small{font-size:10px;line-height:1.3}.demo-workspace-banner .primary-button{min-height:36px}
.catalog-toolbar,.invoice-toolbar,.payment-toolbar{gap:8px;padding-bottom:10px}.catalog-search{min-height:38px;border-radius:10px}.catalog-search input{padding:7px 0;font-size:12px}.catalog-toolbar>select,.invoice-toolbar>select,.payment-toolbar>select{min-height:38px;padding:0 10px;border-radius:10px;font-size:12px}
.responsive-table{margin:0 -16px}.responsive-table td,.responsive-table th{padding:8px 12px}.responsive-table td:first-child,.responsive-table th:first-child{padding-left:16px}.responsive-table td:last-child,.responsive-table th:last-child{padding-right:16px}.responsive-table th{font-size:10px}.responsive-table td{font-size:12px}.responsive-table td small{font-size:9px;margin-top:1px}.customer-cell small{font-size:9px}.status-pill,.receipt-status,.credit-note-status,.movement-type{padding:4px 7px;font-size:10px}
.row-action-select{min-height:34px;font-size:11px;border-radius:8px}.row-action-control,.row-action-select{min-width:122px}.actions-column,.actions-cell{width:138px;min-width:138px}
.settings-tabs,.local-settings-shell .settings-tabs{gap:4px;padding:4px;border-radius:11px}.local-settings-shell .settings-tabs button{min-height:34px;padding:0 12px;border-radius:8px;font-size:11px}.settings-panel .panel-heading p,.catalog-panel .panel-heading p{margin-top:2px;font-size:10px;line-height:1.3}.panel-actions{padding-top:11px;margin-top:12px}
.page-heading{gap:16px;margin-bottom:11px}.page-heading h1{margin:2px 0 3px;font-size:clamp(24px,2.5vw,31px)}.page-heading p{font-size:12px;line-height:1.35}.report-controls{margin-bottom:11px;padding:6px 12px 11px}.report-filter-grid{gap:8px}.report-filter-grid label{gap:4px;font-size:10px}.report-filter-grid input,.report-filter-grid select{min-height:38px;border-radius:9px;font-size:12px}
.statement-controls{margin:10px 0;padding:10px 12px}.statement-mode-tabs button{min-height:31px;padding:0 11px;font-size:11px}.statement-filter-grid{gap:8px;margin-top:9px}.statement-filter-grid .field-label input,.statement-filter-grid .field-label select{height:38px;min-height:38px}.statement-history-help{min-height:38px;padding:5px 9px;font-size:11px}.statement-summary-grid article{min-height:66px}.statement-panel{margin-top:10px}.statement-ending-strip{gap:7px;padding-top:9px}.statement-ending-strip span{min-height:38px;padding:6px 9px}.statement-footer{margin:12px 16px 16px;padding-top:10px;font-size:10px}
.modal-backdrop{padding:10px}.modal-card{max-height:calc(100vh - 20px);border-radius:15px}.wide-modal,.invoice-modal,.payment-modal{width:min(980px,calc(100vw - 20px))}.modal-header{gap:12px;padding:11px 15px}.modal-header h2{margin-top:1px;font-size:19px}.modal-subtitle{font-size:10px}.modal-header .close-button{width:34px;height:34px}.entity-form,.credit-note-form{padding:11px 15px 0}.form-section{padding-bottom:11px;margin-bottom:10px}.form-section h3{margin-bottom:7px;font-size:13px}.form-grid{column-gap:9px;row-gap:8px}.field-label,.modal-card .field-label{gap:4px;font-size:11px}.modal-card .field-label input,.modal-card .field-label select,.field-label input,.field-label select{height:38px;min-height:38px;padding:0 10px;border-radius:9px;font-size:12px}.modal-card .field-label textarea,.field-label textarea{min-height:50px;padding:7px 10px;border-radius:9px;font-size:12px}.modal-card .field-label small,.field-label small{font-size:9px;line-height:1.2}.modal-actions{gap:7px;margin:0 -15px;padding:8px 15px}.modal-actions .primary-button,.modal-actions .secondary-button,.modal-actions .danger-button{min-height:36px}
.invoice-editor{padding:14px;margin-bottom:12px}.invoice-editor>form{gap:12px}.invoice-editor .panel-heading{margin-bottom:9px}.application-grid,.receipt-applications,.credit-application-grid{gap:7px;padding:10px;border-radius:11px}.application-row,.application-row-f05,.credit-application-row{gap:12px;padding:8px 10px;border-radius:9px}.application-row input,.application-row-f05 input,.credit-application-row input,.allocation-input{min-height:36px;height:36px}.payment-totals-strip{gap:7px;margin-top:7px}.payment-totals-strip span{min-height:38px;padding:6px 9px}.payment-totals-strip strong{font-size:13px}.application-table th,.application-table td{padding:7px 9px}.application-table-wrap{max-height:220px}
.receipt-detail,.credit-note-detail,.audit-detail{padding:0 16px 16px}.receipt-detail-grid,.detail-list{gap:7px}.receipt-detail-grid>div,.detail-list p{gap:4px;padding:9px 10px;border-radius:9px}.receipt-application-list{gap:6px;margin-top:11px}.receipt-application-list article{padding:8px 10px;border-radius:9px}.audit-json{max-height:300px;margin:0 16px 16px;padding:11px;font-size:10px;line-height:1.5}
.launcher-header{gap:12px;padding:15px 16px 11px}.launcher-header h2{margin-top:2px;font-size:19px}.launcher-search{margin:10px 14px 3px;padding:0 10px;border-radius:10px}.launcher-search input{padding:8px 0;font-size:12px}.launcher-groups{padding:8px 14px 18px}.categorized-launcher{gap:7px;padding-top:7px}.categorized-launcher .launcher-group{border-radius:11px}.categorized-launcher .launcher-group-heading{padding:8px 10px;font-size:11px}.categorized-launcher .launcher-item{min-height:52px;grid-template-columns:34px minmax(0,1fr) 16px;gap:9px;padding:7px 10px}.categorized-launcher .launcher-item-icon{width:32px;height:32px;border-radius:9px}.categorized-launcher .launcher-item strong{font-size:12px}.categorized-launcher .launcher-item small{font-size:9px}
.empty-state{padding:18px;font-size:12px}.local-placeholder{min-height:420px;gap:8px}.local-placeholder h1{font-size:28px}.local-placeholder p{font-size:12px;line-height:1.4}.placeholder-icon{width:58px;height:58px;border-radius:17px}
.ofi-update-banner{bottom:14px;gap:14px;padding:9px 11px;border-radius:12px}.ofi-update-banner span{font-size:11px}.ofi-update-actions button{padding:7px 9px;font-size:11px}

@media (max-width:1080px){.local-action-list{grid-template-columns:1fr}.phase-checklist{grid-template-columns:1fr}.phase-checklist .next{grid-column:auto}.dashboard-main-grid,.dashboard-trend-grid{grid-template-columns:1fr}.catalog-summary-grid{grid-template-columns:repeat(2,1fr)}}
@media (max-width:720px){body{font-size:14px}.topbar{min-height:56px;padding:6px 9px}.brand-mark{width:36px;height:36px}.brand-copy strong{font-size:14px}.page-container{width:min(100% - 16px,1480px);margin-top:9px}.license-strip{padding:5px 10px}.hero-card,.compact-hero{display:grid;padding:12px 13px;gap:10px}.hero-card h1,.compact-hero h1{font-size:24px}.hero-actions{width:100%;display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.hero-actions .primary-button,.hero-actions .secondary-button{width:100%;justify-content:center;min-height:42px}.panel{padding:13px}.metric-grid,.dashboard-primary-metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.metric-card{min-height:86px;padding:10px}.metric-card strong{font-size:19px}.catalog-summary-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.catalog-summary-grid article{min-height:60px;padding:8px 9px}.dashboard-secondary-metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.dashboard-secondary-metrics article{min-height:58px}.aging-donut-layout{grid-template-columns:1fr;padding-top:10px}.aging-donut{width:165px}.local-action-list{grid-template-columns:1fr}.phase-checklist{grid-template-columns:1fr}.responsive-table{margin:0 -13px}.responsive-table td:first-child,.responsive-table th:first-child{padding-left:13px}.responsive-table td:last-child,.responsive-table th:last-child{padding-right:13px}.message{margin-bottom:7px}.atomic-banner{align-items:flex-start}.modal-backdrop{padding:0}.modal-card,.wide-modal,.invoice-modal,.payment-modal{width:100%;max-height:100vh;border-radius:0}.modal-header{padding:10px 12px}.entity-form,.credit-note-form{padding:10px 12px 0}.modal-actions{margin:0 -12px;padding:8px 12px}.form-grid.two-columns,.form-grid.three-columns,.compact-form,.detail-list{grid-template-columns:1fr}.launcher-panel{width:100%}.demo-workspace-banner{padding:9px 10px}.demo-workspace-banner .primary-button{min-height:40px}.row-action-select{min-height:38px}.report-filter-grid{grid-template-columns:1fr}.statement-filter-grid{grid-template-columns:1fr}.statement-customer,.statement-history-help{grid-column:auto}}
@media (max-width:460px){.brand-copy small{display:none}.topbar-icon-button{width:36px;height:36px}.metric-grid,.dashboard-primary-metrics,.catalog-summary-grid,.dashboard-secondary-metrics{grid-template-columns:1fr}.hero-actions{grid-template-columns:1fr}.metric-card{min-height:78px}.page-heading h1{font-size:23px}.actions-column,.actions-cell{width:128px;min-width:128px}.row-action-control,.row-action-select{min-width:112px}}


/* RC1.1 — acciones visuales y menú acordeón */
.row-action-control{display:inline-flex;justify-content:flex-end;min-width:124px;position:relative}
.row-action-trigger{min-width:124px;height:34px;display:inline-flex;align-items:center;justify-content:space-between;gap:12px;padding:0 10px 0 12px;border:1px solid #d9d9e8;border-radius:9px;background:linear-gradient(180deg,#fff 0%,#fafafe 100%);color:#37384d;font:inherit;font-size:11px;font-weight:620;letter-spacing:.01em;cursor:pointer;box-shadow:0 1px 2px rgba(32,30,92,.04);transition:border-color .16s ease,box-shadow .16s ease,background .16s ease,color .16s ease}
.row-action-trigger:hover{border-color:#aaa5eb;background:#f8f7ff;color:#493ed1;box-shadow:0 4px 12px rgba(81,70,216,.08)}
.row-action-trigger:focus-visible,.row-action-trigger[aria-expanded="true"]{outline:0;border-color:#655ae5;background:#f5f3ff;color:#4338ca;box-shadow:0 0 0 3px rgba(81,70,216,.11)}
.row-action-trigger svg{flex:0 0 auto;transition:transform .16s ease}
.row-action-trigger[aria-expanded="true"] svg{transform:rotate(180deg)}
.row-action-menu{position:fixed;z-index:30000;display:grid;gap:2px;padding:6px;border:1px solid #e1e1ee;border-radius:12px;background:#fff;box-shadow:0 18px 48px rgba(29,26,77,.18),0 3px 10px rgba(29,26,77,.08);animation:ofiActionMenuIn .13s ease-out;transform-origin:top right}
@keyframes ofiActionMenuIn{from{opacity:0;transform:translateY(-4px) scale(.985)}to{opacity:1;transform:translateY(0) scale(1)}}
.row-action-menu-item{width:100%;min-height:35px;display:flex;align-items:center;border:0;border-radius:8px;padding:7px 10px;background:transparent;color:#37384d;font:inherit;font-size:11px;font-weight:650;text-align:left;cursor:pointer;transition:background .12s ease,color .12s ease}
.row-action-menu-item:hover,.row-action-menu-item:focus-visible{outline:0;background:#f4f2ff;color:#4338ca}
.row-action-menu-item.primary{color:#4338ca}
.row-action-menu-item.primary:hover{background:#eeecff}
.row-action-menu-item.danger{color:#b42318}
.row-action-menu-item.danger:hover,.row-action-menu-item.danger:focus-visible{background:#fff1f0;color:#9f1c12}
.row-action-select{display:none!important}
.actions-column,.actions-cell{width:140px;min-width:140px;text-align:right!important}

.categorized-launcher{gap:8px}
.categorized-launcher .launcher-group{border:1px solid #e4e4ee;background:#fff;box-shadow:0 2px 8px rgba(35,31,88,.025);transition:border-color .16s ease,box-shadow .16s ease}
.categorized-launcher .launcher-group.expanded{border-color:#d7d3ff;box-shadow:0 5px 18px rgba(81,70,216,.07)}
.categorized-launcher .launcher-group-heading{cursor:pointer;border:0;border-bottom:0!important;width:100%;grid-template-columns:28px minmax(0,1fr) 24px;min-height:42px;padding:8px 10px;background:#fbfbfd;color:#38394c;transition:background .14s ease,color .14s ease}
.categorized-launcher .launcher-group-heading:hover{background:#f6f5ff;color:#4338ca}
.categorized-launcher .launcher-group.expanded .launcher-group-heading{background:#f4f2ff;color:#4338ca;border-bottom:1px solid #e4e1ff!important}
.categorized-launcher .launcher-count{display:grid;place-items:center;width:24px;height:24px;border-radius:8px;background:#eceaff;color:#5146d8;font-size:10px;font-weight:650}
.categorized-launcher .launcher-group-heading strong{font-size:12px;font-weight:620}
.launcher-chevron{width:24px;height:24px;display:grid;place-items:center;border-radius:7px;color:#77788c;transition:transform .18s ease,background .18s ease,color .18s ease}
.launcher-group.expanded .launcher-chevron{transform:rotate(180deg);background:#e8e5ff;color:#5146d8}
.categorized-launcher .launcher-grid[hidden]{display:none!important}
.categorized-launcher .launcher-grid{animation:ofiAccordionIn .15s ease-out}
@keyframes ofiAccordionIn{from{opacity:.3;transform:translateY(-3px)}to{opacity:1;transform:translateY(0)}}
.launcher-header p{margin:3px 0 0;color:#8a8b9e;font-size:10px;line-height:1.3}
.categorized-launcher .launcher-item-copy{display:flex!important;flex-direction:column;gap:2px;min-width:0}
.categorized-launcher .launcher-item-copy strong,.categorized-launcher .launcher-item-copy small{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis}
@media(max-width:720px){.row-action-trigger{min-width:116px;height:38px}.actions-column,.actions-cell{width:132px;min-width:132px}.row-action-menu{max-width:calc(100vw - 20px)}.categorized-launcher .launcher-group-heading{min-height:44px}.launcher-header p{font-size:9px}}

/* RC1.2 — modales profesionales, diálogos OFI y menú híbrido */
.modal-body{
  flex:1 1 auto;
  min-height:0;
  overflow:auto;
  padding:16px 18px 0;
  scrollbar-gutter:stable;
  overscroll-behavior:contain;
}
.modal-body > .entity-form,
.modal-body > .credit-note-form,
.modal-body > form,
.modal-body > .invoice-detail,
.modal-body > .receipt-detail,
.modal-body > .credit-note-detail,
.modal-body > .audit-detail{
  padding:0;
  overflow:visible;
}
.modal-body .modal-actions{
  margin:16px -18px 0;
  padding:11px 18px;
}
.modal-body .responsive-table{
  margin:0;
}
.modal-body .detail-list,
.modal-detail-grid{
  margin:0;
}
.modal-body > h3{
  margin:16px 0 8px;
  color:#34354a;
  font-size:14px;
}
.modal-section-heading{
  display:flex;
  align-items:end;
  justify-content:space-between;
  gap:12px;
  margin:16px 0 8px;
}
.modal-section-heading h3{
  margin:0;
  color:#303146;
  font-size:14px;
  font-weight:600;
}
.modal-section-heading small{
  color:#8a8b9d;
  font-size:10px;
}
.modal-table-wrap{
  overflow:hidden;
  border:1px solid #e5e6ef;
  border-radius:12px;
  background:#fff;
}
.modal-responsive-table{
  margin:0!important;
  overflow-x:auto;
}
.modal-responsive-table table{
  width:100%;
  min-width:620px;
}
.modal-responsive-table th,
.modal-responsive-table td{
  padding:9px 11px;
}
.modal-responsive-table thead th{
  background:#fafafe;
}
.modal-callout{
  display:flex;
  gap:9px;
  align-items:flex-start;
  margin-bottom:12px;
  padding:9px 11px;
  border:1px solid #dfddfb;
  border-radius:10px;
  color:#56526f;
  background:#f7f6ff;
}
.modal-callout span{
  flex:0 0 auto;
  display:grid;
  place-items:center;
  color:#5146d8;
}
.modal-callout p{
  margin:0;
  font-size:11px;
  line-height:1.45;
}
.modal-body form .form-grid > label:not(.check-field),
.credit-apply-form label{
  display:grid;
  gap:5px;
  color:#646679;
  font-size:11px;
  font-weight:650;
}
.modal-body form .form-grid > label input,
.modal-body form .form-grid > label select,
.modal-body form .form-grid > label textarea,
.modal-money-input{
  width:100%;
  min-height:38px;
  border:1px solid #d9dbe7;
  border-radius:9px;
  padding:0 10px;
  color:#2e3044;
  background:#fff;
  font:inherit;
  outline:0;
  transition:border-color .15s ease,box-shadow .15s ease,background .15s ease;
}
.modal-body form .form-grid > label textarea{
  min-height:58px;
  padding:8px 10px;
  resize:vertical;
}
.modal-body form .form-grid > label input:focus,
.modal-body form .form-grid > label select:focus,
.modal-body form .form-grid > label textarea:focus,
.modal-money-input:focus{
  border-color:#655ae5;
  box-shadow:0 0 0 3px rgba(81,70,216,.10);
}
.money-apply-field{
  display:grid;
  grid-template-columns:auto minmax(100px,130px);
  align-items:center;
  justify-content:end;
  gap:8px;
}
.money-apply-field > span{
  color:#8a8b9d;
  font-size:9px;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.modal-money-input{
  min-height:36px;
  text-align:right;
  font-weight:650;
}

/* Diálogos propios de la aplicación: reemplazan prompt()/confirm() */
.ofi-dialog-backdrop{
  position:fixed;
  inset:0;
  z-index:40000;
  display:grid;
  place-items:center;
  padding:18px;
  background:rgba(25,26,48,.58);
  backdrop-filter:blur(4px);
}
.ofi-dialog-card{
  width:min(470px,calc(100vw - 28px));
  overflow:hidden;
  border:1px solid #e0e1eb;
  border-radius:16px;
  background:#fff;
  box-shadow:0 28px 80px rgba(25,26,48,.28);
}
.ofi-dialog-card header{
  position:relative;
  padding:16px 18px 12px;
  border-bottom:1px solid #ececf2;
}
.ofi-dialog-card header h3{
  margin:3px 44px 0 0;
  color:#2e3045;
  font-size:19px;
  line-height:1.2;
}
.ofi-dialog-card header .close-button{
  position:absolute;
  top:12px;
  right:14px;
  width:34px;
  height:34px;
}
.ofi-dialog-body{
  padding:14px 18px;
}
.ofi-dialog-body > p{
  margin:0;
  color:#696a7d;
  font-size:12px;
  line-height:1.55;
}
.ofi-dialog-field{
  display:grid;
  gap:6px;
  margin-top:12px;
  color:#535568;
  font-size:11px;
  font-weight:620;
}
.ofi-dialog-field input,
.ofi-dialog-field textarea{
  width:100%;
  border:1px solid #d8dae6;
  border-radius:10px;
  padding:10px 11px;
  background:#fff;
  color:#2d2f43;
  font:inherit;
  outline:0;
}
.ofi-dialog-field textarea{
  min-height:92px;
  resize:vertical;
}
.ofi-dialog-field input:focus,
.ofi-dialog-field textarea:focus{
  border-color:#655ae5;
  box-shadow:0 0 0 3px rgba(81,70,216,.10);
}
.ofi-dialog-field small{
  color:#b42318;
  font-size:10px;
}
.ofi-dialog-card footer{
  display:flex;
  justify-content:flex-end;
  gap:8px;
  padding:10px 18px 14px;
}
.danger-button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  min-height:38px;
  border:1px solid #d92d20;
  border-radius:10px;
  padding:0 14px;
  color:#fff;
  background:#d92d20;
  font:inherit;
  font-weight:620;
  cursor:pointer;
}
.danger-button:hover{background:#b42318;border-color:#b42318}

/* Menú híbrido: acordeón + tarjetas visuales */
.launcher-panel{
  width:min(700px,100%);
}
.categorized-launcher{
  gap:10px;
}
.categorized-launcher .launcher-group{
  overflow:hidden;
  border-radius:14px;
}
.categorized-launcher .launcher-group-heading{
  min-height:50px;
  padding:10px 13px;
  grid-template-columns:30px minmax(0,1fr) 28px;
  background:#fff;
  font-size:12px;
}
.categorized-launcher .launcher-group.expanded .launcher-group-heading{
  background:#fff;
  border-bottom:1px solid #e9e8f2!important;
}
.categorized-launcher .launcher-count{
  width:27px;
  height:27px;
  border-radius:9px;
  font-size:11px;
}
.categorized-launcher .launcher-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:1px;
  padding:1px;
  background:#e9e9f1;
}
.categorized-launcher .launcher-item{
  min-height:104px;
  display:grid;
  grid-template-columns:48px minmax(0,1fr) 18px;
  grid-template-rows:auto 1fr;
  align-items:start;
  column-gap:12px;
  row-gap:4px;
  padding:17px 16px;
  border:0!important;
  background:#fff;
  text-align:left;
}
.categorized-launcher .launcher-item:hover{
  background:#faf9ff;
}
.categorized-launcher .launcher-item.active{
  background:#f5f3ff;
  box-shadow:inset 4px 0 #5146d8;
}
.categorized-launcher .launcher-item-icon{
  grid-row:1 / span 2;
  width:46px;
  height:46px;
  border-radius:14px;
  background:#efedff;
}
.categorized-launcher .launcher-item-copy{
  display:grid!important;
  gap:4px;
  align-self:start;
  padding-top:2px;
}
.categorized-launcher .launcher-item-copy strong{
  color:#34354a;
  font-size:13px;
  font-weight:620;
  overflow:visible;
  text-overflow:clip;
  white-space:normal;
}
.categorized-launcher .launcher-item-copy small{
  color:#85869a;
  font-size:10.5px;
  line-height:1.45;
  overflow:visible;
  text-overflow:clip;
  white-space:normal;
}
.categorized-launcher .launcher-item > svg{
  align-self:center;
  color:#646578;
}

@media(max-width:720px){
  .modal-body{padding:13px 12px 0}
  .modal-body .modal-actions{margin:14px -12px 0;padding:9px 12px}
  .modal-section-heading{align-items:flex-start;flex-direction:column;gap:3px}
  .money-apply-field{grid-template-columns:1fr;gap:4px}
  .modal-money-input{width:100%}
  .ofi-dialog-backdrop{padding:10px}
  .ofi-dialog-card{width:min(100%,470px)}
  .launcher-panel{width:100%}
  .categorized-launcher .launcher-grid{grid-template-columns:1fr}
  .categorized-launcher .launcher-item{min-height:82px;padding:13px 14px}
}

/* RC1.2.1.2 — normalización tipográfica de estados y totales */
.invoice-status,
.receipt-status,
.credit-note-status {
  font-weight: 600;
  letter-spacing: 0;
}
.invoice-totals .grand-total {
  font-size: inherit;
  line-height: inherit;
}

/* RC1.2.1.3 — ajuste de legibilidad sin perder la densidad compacta */
body{font-size:15px}
.hero-card p,.compact-hero p{font-size:13px}
.panel-heading>span,.panel-heading p{font-size:11px}
.metric-card span{font-size:12px}.metric-card small{font-size:11px}
.local-metric-grid .metric-card p{font-size:11px}
.catalog-summary-grid span{font-size:11px}
.dashboard-secondary-metrics span,.dashboard-secondary-metrics small{font-size:11px}
.dashboard-list strong{font-size:13px}.dashboard-list small{font-size:10px}
.local-action-list strong{font-size:13px}.local-action-list small{font-size:10px}
.phase-checklist>div{font-size:12px}.health-grid small{font-size:9px}.health-grid strong{font-size:12px}
.message{font-size:13px}.atomic-banner strong{font-size:13px}.atomic-banner small{font-size:11px}
.demo-workspace-banner strong{font-size:14px}.demo-workspace-banner small{font-size:11px}
.catalog-search input,.catalog-toolbar>select,.invoice-toolbar>select,.payment-toolbar>select{font-size:13px}
.responsive-table th{font-size:11px}.responsive-table td{font-size:13px}.responsive-table td small,.customer-cell small{font-size:10px}
.status-pill,.receipt-status,.credit-note-status,.movement-type{font-size:11px}
.row-action-trigger,.row-action-menu-item{font-size:12px}
.local-settings-shell .settings-tabs button{font-size:12px}
.settings-panel .panel-heading p,.catalog-panel .panel-heading p{font-size:11px}
.page-heading p{font-size:13px}
.report-filter-grid label{font-size:11px}.report-filter-grid input,.report-filter-grid select{font-size:13px}
.statement-mode-tabs button{font-size:12px}.statement-history-help{font-size:12px}.statement-footer{font-size:11px}
.field-label,.modal-card .field-label{font-size:12px}
.modal-card .field-label input,.modal-card .field-label select,.field-label input,.field-label select,.modal-card .field-label textarea,.field-label textarea{font-size:13px}
.modal-card .field-label small,.field-label small{font-size:10px}
.form-section h3{font-size:14px}
.modal-subtitle{font-size:11px}
.application-table th{font-size:12px}
.payment-totals-strip span,.statement-ending-strip span{font-size:12px}
.modal-callout p{font-size:12px}
.modal-body form .form-grid > label:not(.check-field),.credit-apply-form label{font-size:12px}
.money-apply-field>span{font-size:10px}
.ofi-dialog-body>p{font-size:13px}.ofi-dialog-field{font-size:12px}.ofi-dialog-field small{font-size:11px}
.categorized-launcher .launcher-group-heading strong{font-size:13px}
.categorized-launcher .launcher-item-copy strong{font-size:14px}
.categorized-launcher .launcher-item-copy small{font-size:11.5px}
.launcher-header p{font-size:11px}
.monthly-column strong{font-size:12px}.monthly-column small{font-size:11px}.chart-legend{font-size:13px}
.dashboard-aging-list span{font-size:13px}
@media(max-width:720px){body{font-size:14px}.responsive-table th{font-size:11px}.responsive-table td{font-size:13px}.responsive-table td small,.customer-cell small{font-size:10px}.categorized-launcher .launcher-item-copy strong{font-size:13px}.categorized-launcher .launcher-item-copy small{font-size:11px}.launcher-header p{font-size:10px}}
/* Controles operativos: un punto más para lectura cómoda en escritorio */
.primary-button,.secondary-button,.danger-button,.hero-actions .primary-button,.hero-actions .secondary-button,.hero-actions .danger-button{font-size:13px}
.text-button{font-size:13px}
.organization-control select,.logout-button{font-size:13px}
.license-strip,.license-strip button{font-size:12px}
.user-chip strong{font-size:13px}.user-chip small{font-size:11px}


/* RC1.2.1.4 — actualización automática y pulido de selector de empresas */
.workspace-brand-panel{padding:clamp(40px,6vw,88px);gap:17px}
.workspace-brand-panel h1{max-width:650px;font-size:clamp(34px,4.15vw,55px);line-height:1.045;letter-spacing:-.042em}
.workspace-brand-panel>p{max-width:590px;font-size:15px;line-height:1.62}
.workspace-brand-panel .eyebrow{font-size:10px;letter-spacing:.14em;color:rgba(255,255,255,.62)}
.workspace-feature-list{gap:11px;max-width:590px;margin-top:9px}
.workspace-feature-list>div{grid-template-columns:40px 1fr;gap:12px;padding:12px 14px;border-radius:14px}
.workspace-feature-list svg{width:40px;height:40px;padding:9px;border-radius:11px}
.workspace-feature-list strong{font-size:14px}
.workspace-feature-list small{font-size:12px;line-height:1.4}
.recent-workspace>.icon-button[data-forget],
.recent-workspace>.icon-button[data-delete-recovery]{
  width:34px;height:34px;display:grid;place-items:center;flex:0 0 34px;
  border:1px solid #dddfea;border-radius:10px;background:#fff;color:#67697c;
  box-shadow:0 2px 8px rgba(43,45,78,.05);cursor:pointer;transition:.18s ease;
}
.recent-workspace>.icon-button[data-forget]:hover,
.recent-workspace>.icon-button[data-delete-recovery]:hover{background:#fff1f2;border-color:#fecdd3;color:#be123c;transform:translateY(-1px)}
.recent-workspace>.icon-button[data-forget]:focus-visible,
.recent-workspace>.icon-button[data-delete-recovery]:focus-visible{outline:3px solid rgba(81,70,217,.16);outline-offset:2px}
@media(max-width:980px){.workspace-brand-panel h1{max-width:610px;font-size:clamp(34px,7vw,52px)}}
@media(max-width:620px){.workspace-brand-panel{padding:36px 25px}.workspace-brand-panel h1{font-size:37px}.workspace-brand-panel>p{font-size:14px}.workspace-feature-list strong{font-size:13px}.workspace-feature-list small{font-size:11px}}

/* RC1.2.1.6 — configuración internacional de moneda */
.currency-custom-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;padding:12px;border:1px solid #e4e4ef;border-radius:12px;background:#fafaff}
.currency-custom-fields[hidden]{display:none!important}
.currency-preview{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 14px;border:1px solid #deddf0;border-radius:12px;background:linear-gradient(135deg,#faf9ff,#f6f8ff)}
.currency-preview>div{display:grid;gap:3px}.currency-preview small{color:#77788c;font-size:11px;font-weight:600}.currency-preview strong{color:#26263a;font-size:18px;letter-spacing:-.01em}.currency-preview>span{color:#66677d;font-size:12px;text-align:right}
@media(max-width:720px){.currency-custom-fields{grid-template-columns:1fr}.currency-preview{align-items:flex-start;flex-direction:column;gap:5px}.currency-preview>span{text-align:left}}

/* Fase 0 — autenticación, cuenta visible y cambio real de sesión */
.license-account-card{display:flex;align-items:center;gap:12px;margin:0 0 16px;padding:12px 14px;border:1px solid #dfe4ee;border-radius:14px;background:#f8f9fd;color:#2f3148}
.license-account-avatar{display:grid;place-items:center;flex:0 0 40px;width:40px;height:40px;border-radius:12px;background:#eceaff;color:#5146d8;font-size:.82rem;font-weight:650;letter-spacing:.02em}
.license-account-card>span:last-child{display:grid;min-width:0;gap:2px}
.license-account-card small{color:#77798c;font-size:.75rem}
.license-account-card strong{overflow:hidden;color:#26283f;font-size:.92rem;text-overflow:ellipsis;white-space:nowrap}
.license-account-card em{overflow:hidden;color:#74768a;font-size:.78rem;font-style:normal;text-overflow:ellipsis;white-space:nowrap}
#license-account-manage{margin-top:14px;margin-bottom:-5px}
#license-account-manage+.recovery-link{margin-top:13px}

/* Fase 0 HF3 — diagnóstico técnico solo bajo ?license_debug=1 */
.license-debug{margin-top:16px;border:1px solid var(--border,#dfe3ee);border-radius:12px;padding:10px 12px;background:#f8fafc;text-align:left}
.license-debug summary{cursor:pointer;font-weight:620;font-size:12px}
.license-debug pre{margin:10px 0 0;max-height:220px;overflow:auto;white-space:pre-wrap;word-break:break-word;font:11px/1.45 ui-monospace,SFMono-Regular,Consolas,monospace;color:#334155}


/* Fase 0 HF5 — cambio de cuenta desde sesión autorizada */
.authorized-account-card{display:grid;grid-template-columns:42px minmax(0,1fr) auto;align-items:center;gap:12px;margin:-4px 0 18px;padding:11px 12px;border:1px solid #e1e5ee;border-radius:13px;background:#fafbfe}
.authorized-account-avatar{display:grid;place-items:center;width:42px;height:42px;border-radius:11px;background:#eceaff;color:#5146d8;font-size:12px;font-weight:650;letter-spacing:.02em}
.authorized-account-copy{display:grid;min-width:0;gap:1px}
.authorized-account-copy small{color:#818395;font-size:10px;font-weight:650;text-transform:uppercase;letter-spacing:.06em}
.authorized-account-copy strong,.authorized-account-copy em{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.authorized-account-copy strong{color:#2d2f45;font-size:13px}
.authorized-account-copy em{color:#7a7c90;font-size:11px;font-style:normal}
.authorized-account-switch{min-height:38px;display:inline-flex;align-items:center;justify-content:center;gap:7px;padding:0 12px;font-size:12px;white-space:nowrap}
.user-chip-button{border:1px solid transparent;color:inherit;font:inherit;text-align:left;cursor:pointer;transition:.16s ease}
.user-chip-button>i{display:grid;place-items:center;margin-left:2px;color:rgba(255,255,255,.72);font-style:normal}
.user-chip-button:hover{border-color:rgba(255,255,255,.2);background:rgba(255,255,255,.14)}
.user-chip-button:focus-visible{outline:2px solid rgba(255,255,255,.85);outline-offset:2px}
@media(max-width:980px){.authorized-account-card{grid-template-columns:42px minmax(0,1fr)}.authorized-account-switch{grid-column:1/-1;width:100%}}
@media(max-width:620px){.authorized-account-card{grid-template-columns:38px minmax(0,1fr)}.authorized-account-avatar{width:38px;height:38px}.authorized-account-switch{min-height:42px}}
\n\n/* Fase Demo 2 — experiencia comercial, CTA y acceso desde el gate */
.demo-commercial-strip{display:flex;align-items:center;justify-content:space-between;gap:16px;min-height:54px;padding:8px clamp(14px,2.6vw,34px);border-bottom:1px solid #d9dcff;background:linear-gradient(90deg,#f4f3ff 0%,#fbfbff 55%,#eef8ff 100%);color:#35364b}
.demo-commercial-copy{display:flex;align-items:center;gap:11px;min-width:0}.demo-commercial-copy>span:last-child{display:grid;gap:1px;min-width:0}.demo-commercial-copy strong{font-size:13px;font-weight:620;color:#292747}.demo-commercial-copy small{font-size:11px;line-height:1.35;color:#6f7188}
.demo-commercial-badge{flex:0 0 auto;padding:5px 8px;border:1px solid #c9c5ff;border-radius:999px;background:#fff;color:#5146d8;font-size:10px;font-weight:650;letter-spacing:.08em}
.demo-commercial-actions{display:flex;align-items:center;gap:8px;flex:0 0 auto}.demo-commercial-link,.demo-commercial-cta{min-height:34px;border-radius:9px;padding:7px 11px;font:inherit;font-size:11px;font-weight:620;cursor:pointer}.demo-commercial-link{border:1px solid transparent;background:transparent;color:#5b5d74}.demo-commercial-link:hover{background:rgba(255,255,255,.75);color:#35364b}.demo-commercial-cta{display:inline-flex;align-items:center;gap:6px;border:1px solid #5146d8;background:#5146d8;color:#fff;box-shadow:0 5px 14px rgba(81,70,216,.16)}.demo-commercial-cta:hover{background:#4338ca}
.demo-gate-entry{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:14px;margin-top:18px;padding:13px;border:1px solid #d9dcff;border-radius:14px;background:linear-gradient(135deg,#f6f5ff,#fff)}.demo-gate-entry>div{display:flex;align-items:flex-start;gap:10px;min-width:0}.demo-gate-entry>div>span:last-child{display:grid;gap:3px}.demo-gate-entry strong{font-size:12px;color:#343249}.demo-gate-entry small{font-size:10px;line-height:1.4;color:#77798e}.demo-gate-icon{width:34px;height:34px;display:grid;place-items:center;flex:0 0 auto;border-radius:10px;background:#ebe9ff;color:#5146d8}.demo-gate-button{white-space:nowrap;min-height:38px}
.app-shell.demo-mode .topbar{box-shadow:none}.app-shell.demo-mode .page-container{margin-top:14px}
@media(max-width:760px){.demo-commercial-strip{align-items:flex-start;flex-direction:column;gap:7px;padding:8px 10px}.demo-commercial-copy{align-items:flex-start}.demo-commercial-copy strong{font-size:12px}.demo-commercial-actions{width:100%;display:grid;grid-template-columns:1fr 1fr}.demo-commercial-link,.demo-commercial-cta{justify-content:center;width:100%}.demo-gate-entry{grid-template-columns:1fr}.demo-gate-button{width:100%;justify-content:center}}
@media(max-width:440px){.demo-commercial-copy small{display:none}.demo-commercial-badge{padding:4px 7px}.demo-commercial-strip{min-height:auto}.demo-commercial-actions{grid-template-columns:1fr}.demo-commercial-link{display:none}}

/* Fase Demo 2 HF2 — simplificación visual del demo + recuperaciones compactas */
.demo-commercial-strip.demo-commercial-strip-hf2{
  display:grid;
  grid-template-columns:auto minmax(280px,1fr) auto;
  align-items:center;
  column-gap:13px;
  min-height:44px;
  padding:5px clamp(14px,2.4vw,32px);
  border-bottom:1px solid #dedfff;
  background:linear-gradient(90deg,#f7f6ff 0%,#fcfcff 56%,#f3f8ff 100%);
}
.demo-commercial-strip-hf2 .demo-commercial-badge{align-self:center;justify-self:start;padding:4px 8px;font-size:9.5px}
.demo-commercial-message{display:flex;align-items:baseline;gap:8px;min-width:0;white-space:nowrap;overflow:hidden}
.demo-commercial-message strong{flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;color:#292747;font-size:12px;font-weight:620}
.demo-commercial-message small{flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis;color:#77798d;font-size:10px;line-height:1.3}
.demo-commercial-strip-hf2 .demo-commercial-actions{display:flex;align-items:center;justify-content:flex-end;gap:12px;min-width:max-content}
.demo-commercial-strip-hf2 .demo-commercial-cta{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:32px;margin:0;padding:6px 11px;border:1px solid #5146d8;border-radius:9px;background:#5146d8;color:#fff;box-shadow:0 5px 14px rgba(81,70,216,.14);white-space:nowrap;font:inherit;font-size:10.5px;font-weight:620;line-height:1;cursor:pointer}
.demo-commercial-strip-hf2 .demo-commercial-cta:hover{background:#4338ca}
.demo-commercial-client-link{display:inline-flex;align-items:baseline;gap:4px;margin:0;padding:4px 1px;border:0;background:transparent;color:#77798d;white-space:nowrap;font:inherit;font-size:10px;line-height:1.2;cursor:pointer}
.demo-commercial-client-link strong{color:#4f46c8;font-size:10px;font-weight:620;text-decoration:underline;text-underline-offset:2px}
.demo-commercial-client-link:hover strong{color:#3730a3}.demo-commercial-client-link:focus-visible{outline:3px solid rgba(81,70,217,.16);outline-offset:3px;border-radius:4px}
.app-shell.demo-mode .page-container{margin-top:12px}

.recovery-summary-card{margin-top:22px;border-top:1px solid #e9eaf1;padding-top:18px}
.recovery-summary-card>summary{display:grid;grid-template-columns:36px minmax(0,1fr) auto;align-items:center;gap:11px;padding:11px 12px;border:1px solid #e2e3ed;border-radius:14px;background:#fafafd;cursor:pointer;list-style:none;transition:border-color .18s ease,background .18s ease,box-shadow .18s ease}
.recovery-summary-card>summary::-webkit-details-marker{display:none}
.recovery-summary-card>summary::marker{content:''}
.recovery-summary-card>summary:hover{border-color:#d4d0ff;background:#f8f7ff}
.recovery-summary-card[open]>summary{border-color:#d4d0ff;background:#f7f6ff;box-shadow:0 5px 16px rgba(81,70,216,.06)}
.recovery-summary-icon{width:34px;height:34px;display:grid;place-items:center;border-radius:10px;background:#ebe9ff;color:#5146d8}
.recovery-summary-copy{display:grid;gap:2px;min-width:0}
.recovery-summary-copy strong{color:#292b43;font-size:12px;font-weight:620}
.recovery-summary-copy small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#85879a;font-size:10px;line-height:1.35}
.recovery-summary-action{display:inline-flex;align-items:center;gap:8px;color:#5146d8;font-size:10.5px;font-weight:620;white-space:nowrap}
.recovery-action-close{display:none}.recovery-summary-card[open] .recovery-action-open{display:none}.recovery-summary-card[open] .recovery-action-close{display:inline}
.recovery-summary-chevron{width:8px;height:8px;border-right:1.7px solid currentColor;border-bottom:1.7px solid currentColor;transform:rotate(45deg) translateY(-2px);transition:transform .18s ease}
.recovery-summary-card[open] .recovery-summary-chevron{transform:rotate(225deg) translate(-1px,-1px)}
.recovery-summary-body{padding:10px 3px 0}
.recovery-summary-body>p{margin:0 3px 8px;color:#898b9d;font-size:10px;line-height:1.45}
.recovery-list-scroll{display:grid;gap:7px;max-height:315px;overflow:auto;padding:1px 3px 3px;scrollbar-gutter:stable}
.recovery-list-scroll .recent-workspace{margin:0;background:#fff}
.recovery-workspace-row .recent-open{min-width:0}

@media(max-width:980px){
  .demo-commercial-strip.demo-commercial-strip-hf2{grid-template-columns:auto minmax(0,1fr);row-gap:4px;padding-block:6px}
  .demo-commercial-strip-hf2 .demo-commercial-actions{grid-column:2;justify-self:start;justify-content:flex-start}
  .demo-commercial-message{white-space:normal;flex-wrap:wrap;gap:1px 8px}
  .demo-commercial-message small{flex-basis:100%;white-space:normal;overflow:visible}
}
@media(max-width:620px){
  .demo-commercial-strip.demo-commercial-strip-hf2{grid-template-columns:auto minmax(0,1fr);column-gap:9px;padding:7px 10px}
  .demo-commercial-message strong{font-size:11.5px;white-space:normal;overflow:visible}
  .demo-commercial-message small{font-size:9.5px}
  .demo-commercial-strip-hf2 .demo-commercial-actions{grid-column:1/-1;width:100%;display:flex;justify-content:space-between;gap:9px}
  .demo-commercial-strip-hf2 .demo-commercial-cta{flex:0 1 auto}
  .demo-commercial-client-link{margin-left:auto}
  .recovery-summary-card>summary{grid-template-columns:34px minmax(0,1fr);padding:10px}
  .recovery-summary-action{grid-column:2;justify-self:start}
  .recovery-list-scroll{max-height:280px}
}
@media(max-width:420px){
  .demo-commercial-message small{display:none}
  .demo-commercial-strip-hf2 .demo-commercial-actions{align-items:center}
  .demo-commercial-client-link span{display:none}
  .recovery-summary-copy small{white-space:normal}
}


/* Fase Final HF1 — Simplificación de pantalla de entrada */
.workspace-overview-card{display:grid;gap:0;margin:18px 0 14px;border:1px solid #e2e5ef;border-radius:15px;background:#fcfcff;overflow:hidden}
.workspace-overview-row{display:grid;gap:3px;padding:13px 14px}
.workspace-overview-label{font-size:11px;font-weight:650;letter-spacing:.08em;text-transform:uppercase;color:#6a7290}
.workspace-overview-row strong{color:#18243f;font-size:18px;line-height:1.15}
.workspace-overview-row small{color:#70758a}
.workspace-overview-divider{height:1px;background:#eceef5}
.workspace-overview-account-row{grid-template-columns:40px minmax(0,1fr) auto;align-items:center;gap:12px}
.authorized-account-avatar.compact{width:40px;height:40px}
.authorized-account-copy.compact{display:grid;gap:2px;min-width:0}
.authorized-account-copy.compact strong,.authorized-account-copy.compact em{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.authorized-account-switch.compact{min-height:38px;padding:0 12px;white-space:nowrap}
.workspace-primary-actions{margin-top:2px}
.workspace-primary-actions .primary-button,.workspace-primary-actions .secondary-button{min-height:50px}
.workspace-secondary-entry{display:grid;gap:8px;margin-top:12px;padding:12px 14px;border:1px dashed #dddff0;border-radius:14px;background:#fbfbfe}
.workspace-secondary-entry>small{color:#6d7289;font-size:11px;font-weight:650;letter-spacing:.03em;text-transform:uppercase}
.workspace-secondary-links{display:flex;flex-wrap:wrap;gap:14px}
.secondary-link-button{display:inline-flex;align-items:center;gap:7px;padding:0;color:#5348da;font-weight:620;text-decoration:none}
.secondary-link-button:hover{text-decoration:underline}
.workspace-support-stack{display:grid;gap:14px;margin-top:20px;padding-top:18px;border-top:1px solid #e9eaf1}
.recent-workspaces.compact{display:grid;gap:9px;margin-top:0;padding-top:0;border-top:0}
.recent-heading.compact{margin-bottom:1px}
.recent-workspace.compact{border-radius:14px}
.workspace-collapsible-card{border:1px solid #e2e3ed;border-radius:14px;background:#fafafd}
.workspace-collapsible-card>summary{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:12px;padding:11px 12px;cursor:pointer;list-style:none}
.workspace-collapsible-card>summary::-webkit-details-marker{display:none}
.workspace-collapsible-card>summary::marker{content:''}
.workspace-collapsible-card[open]>summary{border-bottom:1px solid #ececf6}
.recent-collapsible .recovery-summary-body{padding:10px}
.recent-collapsible .recent-workspace+.recent-workspace{margin-top:8px}
.recovery-summary-card.workspace-collapsible-card{margin-top:0;border-top:0;padding-top:0}
.recovery-summary-card.workspace-collapsible-card>summary{background:#fafafd;border:0;border-radius:14px}
.recovery-summary-card.workspace-collapsible-card[open]>summary{box-shadow:none;background:#f8f7ff}
.recovery-summary-card .recovery-summary-body{padding:10px 10px 12px}
.recovery-summary-card .recovery-list-scroll{margin-top:0}
@media(max-width:980px){.workspace-overview-account-row{grid-template-columns:40px minmax(0,1fr)}.authorized-account-switch.compact{grid-column:1/-1;width:100%}}
@media(max-width:620px){.workspace-secondary-links{display:grid;gap:10px}.workspace-overview-row strong{font-size:17px}.workspace-overview-account-row{grid-template-columns:36px minmax(0,1fr)}.authorized-account-avatar.compact{width:36px;height:36px}}


/* Fase Final HF2 — Refinamiento tipográfico y copy de entrada */
.workspace-gate:not(.license-gate) .workspace-brand-panel h1{font-weight:520}
.workspace-gate:not(.license-gate) .workspace-brand-panel>p{font-weight:400;color:rgba(255,255,255,.80)}
.workspace-gate:not(.license-gate) .workspace-feature-list strong{font-weight:570}
.workspace-gate:not(.license-gate) .workspace-feature-list small{font-weight:400;color:rgba(255,255,255,.68)}
.workspace-gate:not(.license-gate) .workspace-action-card h2{font-weight:570;color:#292b42}
.workspace-gate:not(.license-gate) .workspace-action-card>p{font-weight:400;color:#77798c}
.workspace-gate:not(.license-gate) .workspace-overview-label{font-weight:620;letter-spacing:.075em;color:#737990}
.workspace-gate:not(.license-gate) .workspace-overview-row>strong{font-weight:570}
.workspace-gate:not(.license-gate) .authorized-account-copy.compact>small{font-weight:560;color:#777b91}
.workspace-gate:not(.license-gate) .authorized-account-copy.compact>strong{font-weight:570}
.workspace-gate:not(.license-gate) .authorized-account-copy.compact>em{font-weight:400;color:#828599}
.workspace-gate:not(.license-gate) .workspace-primary-actions .primary-button,
.workspace-gate:not(.license-gate) .workspace-primary-actions .secondary-button{font-weight:570}
.workspace-gate:not(.license-gate) .workspace-secondary-entry>small{font-weight:600;color:#74788b;letter-spacing:.025em}
.workspace-gate:not(.license-gate) .secondary-link-button{font-weight:560}
.workspace-gate:not(.license-gate) .recent-heading strong{font-weight:570;color:#292b40}
.workspace-gate:not(.license-gate) .recent-heading small{font-weight:400}
.workspace-gate:not(.license-gate) .recent-open strong{font-weight:570}
.workspace-gate:not(.license-gate) .recent-open small{font-weight:400}
.workspace-gate:not(.license-gate) .recovery-summary-copy strong{font-weight:570}
.workspace-gate:not(.license-gate) .recovery-summary-copy small{font-weight:400}
.workspace-gate:not(.license-gate) .recovery-summary-action{font-weight:560}
.workspace-gate:not(.license-gate) .authorized-account-switch.compact{font-weight:520}


/* Fase Final HF3 — Microajustes de cuenta, recuperación y exploración */
.workspace-gate:not(.license-gate) .authorized-account-copy.compact>strong{
  font-size:13px;
  line-height:1.25;
  font-weight:550;
  white-space:normal;
  overflow:visible;
  text-overflow:clip;
  overflow-wrap:anywhere;
}
.workspace-gate:not(.license-gate) .authorized-account-copy.compact>em{
  font-size:10.5px;
  line-height:1.3;
}
.workspace-gate:not(.license-gate) .workspace-secondary-entry>small{
  text-transform:none;
  font-size:11px;
  font-weight:520;
  letter-spacing:0;
  color:#777b8e;
}
.workspace-gate:not(.license-gate) .recovery-summary-card.workspace-collapsible-card>summary{
  grid-template-columns:36px minmax(0,1fr) auto;
  align-items:center;
  column-gap:11px;
}
.workspace-gate:not(.license-gate) .recovery-summary-card .recovery-summary-icon{
  grid-column:1;
  grid-row:1;
  align-self:center;
}
.workspace-gate:not(.license-gate) .recovery-summary-card .recovery-summary-copy{
  grid-column:2;
  grid-row:1;
  justify-self:stretch;
  text-align:left;
}
.workspace-gate:not(.license-gate) .recovery-summary-card .recovery-summary-action{
  grid-column:3;
  grid-row:1;
  justify-self:end;
  align-self:center;
}
.workspace-gate:not(.license-gate) .recovery-summary-card .recovery-summary-copy small{
  white-space:normal;
  overflow:visible;
  text-overflow:clip;
}
@media(max-width:620px){
  .workspace-gate:not(.license-gate) .authorized-account-copy.compact>strong{font-size:12.5px}
  .workspace-gate:not(.license-gate) .recovery-summary-card.workspace-collapsible-card>summary{
    grid-template-columns:34px minmax(0,1fr);
    row-gap:5px;
  }
  .workspace-gate:not(.license-gate) .recovery-summary-card .recovery-summary-action{
    grid-column:2;
    grid-row:2;
    justify-self:start;
  }
}


/* Fase Final HF4 — Administración simple de respaldos */
.backup-settings-panel{display:grid;gap:18px}
.backup-settings-heading{align-items:flex-start}
.backup-settings-heading p{max-width:760px}
.backup-settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.backup-setting-card{display:grid;grid-template-columns:auto minmax(0,1fr);gap:13px 14px;align-items:start;padding:17px;border:1px solid #e1e8ef;border-radius:15px;background:#fbfcfe}
.backup-setting-icon{width:38px;height:38px;display:grid;place-items:center;border-radius:11px;background:#eef4fb;color:#355e82}
.backup-setting-card>div{min-width:0;display:grid;gap:5px}
.backup-setting-card small{font-size:10px;letter-spacing:.08em;color:#7b8793;font-weight:620}
.backup-setting-card strong{font-size:14px;color:#263746;overflow-wrap:anywhere}
.backup-setting-card p{margin:0;color:#6d7b87;font-size:11.5px;line-height:1.5}
.backup-setting-card>button{grid-column:2;justify-self:start;margin-top:3px}
.backup-policy-note{display:flex;gap:8px;align-items:flex-start;padding:13px 15px;border-radius:12px;background:#f6f8fb;color:#657381;font-size:11.5px;line-height:1.5}
.backup-policy-note strong{color:#304657;white-space:nowrap}
@media(max-width:820px){.backup-settings-grid{grid-template-columns:1fr}.backup-setting-card>button{grid-column:1 / -1}.backup-policy-note{display:grid;gap:3px}}


/* Fase Final HF5 — Restauración segura de respaldos */
.backup-restore-card{grid-column:1 / -1}
.backup-restore-verified{display:flex;gap:12px;align-items:flex-start;padding:13px 14px;border:1px solid #d8e8dd;border-radius:12px;background:#f5faf7;color:#385b46}
.backup-restore-verified>span{width:34px;height:34px;display:grid;place-items:center;flex:0 0 auto;border-radius:10px;background:#e8f4ec}
.backup-restore-verified strong{display:block;font-size:13px;color:#2d513a}
.backup-restore-verified p{margin:3px 0 0;font-size:11.5px;line-height:1.45;color:#61776a}
.backup-restore-summary{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px 16px;margin-top:14px;padding:14px;border:1px solid #e2e8ee;border-radius:12px;background:#fbfcfd}
.backup-restore-summary p{margin:0;display:grid;gap:3px;min-width:0}
.backup-restore-summary span{font-size:10px;font-weight:620;letter-spacing:.05em;color:#7c8791;text-transform:uppercase}
.backup-restore-summary strong{font-size:12.5px;color:#2f4050;overflow-wrap:anywhere}
.backup-restore-warning{margin-top:14px;padding:13px 14px;border-radius:12px;background:#f7f8fa;border:1px solid #e2e7ec}
.backup-restore-warning strong{font-size:12px;color:#394b59}
.backup-restore-warning p{margin:4px 0 0;font-size:11.5px;line-height:1.5;color:#697783}
.backup-restore-warning.is-danger{background:#fff8f7;border-color:#f0d7d3}
.backup-restore-warning.is-danger strong{color:#8a3f36}
.backup-restore-actions{margin-top:17px;flex-wrap:wrap}
.backup-restore-actions button[disabled]{opacity:.48;cursor:not-allowed}
@media(max-width:680px){.backup-restore-summary{grid-template-columns:1fr}.backup-restore-actions{display:grid;grid-template-columns:1fr}.backup-restore-actions button{width:100%}}

/* Fase Final HF6 — Pantalla inicial inteligente */
.workspace-resume-card{display:grid;grid-template-columns:44px minmax(0,1fr) auto;align-items:center;gap:12px;margin:14px 0 16px;padding:13px 14px;border:1px solid #dcdff0;border-radius:15px;background:linear-gradient(135deg,#f8f7ff,#fff)}
.workspace-resume-icon{width:44px;height:44px;display:grid;place-items:center;border-radius:13px;background:#ecebff;color:#5146d9}
.workspace-resume-card>div{display:grid;gap:3px;min-width:0}
.workspace-resume-card small{color:#737990;font-size:10px;font-weight:620;letter-spacing:.055em}
.workspace-resume-card strong{color:#292b42;font-size:16px;font-weight:580;overflow-wrap:anywhere}
.workspace-resume-card>div>span{color:#818497;font-size:11px;line-height:1.35;overflow-wrap:anywhere}
.workspace-resume-status{padding:6px 9px;border-radius:999px;background:#eaf8f1;color:#247452;font-size:10px;font-weight:650;white-space:nowrap}
.workspace-tertiary-actions{display:flex;justify-content:center;margin-top:10px}
.workspace-new-company-link{display:inline-flex;align-items:center;gap:6px;border:0;padding:6px 10px;background:transparent;color:#5146d9;font:inherit;font-size:12px;font-weight:560;cursor:pointer}
.workspace-new-company-link:hover{text-decoration:underline}
.workspace-file-hint{display:grid;grid-template-columns:34px minmax(0,1fr);align-items:start;gap:10px;margin:14px 0 16px;padding:12px 13px;border:1px solid #e3e5ef;border-radius:13px;background:#fafbfe;color:#596279}
.workspace-file-hint>svg{width:34px;height:34px;padding:8px;border-radius:10px;background:#eef1f8;color:#5967a5}
.workspace-file-hint>span{display:grid;gap:3px}
.workspace-file-hint strong{color:#34384e;font-size:12px;font-weight:580}
.workspace-file-hint small{color:#7d8193;font-size:11px;line-height:1.4}
@media(max-width:620px){.workspace-resume-card{grid-template-columns:40px minmax(0,1fr)}.workspace-resume-icon{width:40px;height:40px}.workspace-resume-status{grid-column:2;justify-self:start}.workspace-resume-card small{white-space:normal}}


/* Fase Final HF7 — recuperación local y retención segura */
.recovery-retention-note{margin:0 3px 9px!important;padding:8px 10px;border-radius:10px;background:#f7f8fb;color:#727b88!important;font-size:10px!important;line-height:1.5!important}
.recovery-more-note{display:block;margin:8px 4px 1px;color:#878d98;font-size:10px;line-height:1.4}
.recovery-policy-card{position:relative}
.recovery-policy-badge{grid-column:2;justify-self:start;display:inline-flex;align-items:center;min-height:26px;padding:5px 9px;border-radius:999px;background:#eef4f1;color:#39705a;font-size:10px;font-weight:620;letter-spacing:.02em}
@media(max-width:820px){.recovery-policy-badge{grid-column:1 / -1}}

/* Fase Final HF8 — rescate de .ofiwork desde Recuperación local */
.local-recovery-rescue-banner{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 14px}
.local-recovery-rescue-banner>div{display:grid;gap:3px;min-width:0}
.local-recovery-rescue-banner>div>strong{color:#6e4e0c;font-size:13px}
.local-recovery-rescue-banner>div>span{color:#805f1d;font-size:11.5px;line-height:1.45}
.local-recovery-rescue-banner .primary-button{flex:0 0 auto;min-height:38px}
@media(max-width:720px){.local-recovery-rescue-banner{display:grid}.local-recovery-rescue-banner .primary-button{width:100%;justify-content:center}}

/* Fase Final HF8 HF2 — gestión de empresa registrada sin archivo */
.registered-recovery-intro{margin:0 0 16px;color:var(--text-muted,#667085);line-height:1.6}
.registered-recovery-list{display:grid;gap:12px}
.registered-recovery-card{border:1px solid var(--border,#dfe3eb);border-radius:16px;padding:14px;background:#fff;display:grid;gap:12px}
.registered-recovery-main{display:flex;align-items:flex-start;gap:12px;min-width:0}
.registered-recovery-main>div{display:grid;gap:3px;min-width:0}
.registered-recovery-main strong{font-size:15px;color:var(--text,#15213a)}
.registered-recovery-main small{color:var(--text-muted,#667085);overflow-wrap:anywhere}
.registered-recovery-actions{display:flex;flex-wrap:wrap;gap:8px;padding-left:48px}
.danger-link-button{border:1px solid #f1b7bd;background:#fff;color:#b42318;border-radius:10px;padding:8px 11px;font:inherit;font-weight:650;cursor:pointer}
.danger-link-button:hover{background:#fff5f5}
@media(max-width:720px){.registered-recovery-actions{padding-left:0}.registered-recovery-actions>*{width:100%;justify-content:center}}

/* HF8 HF3 — Rebalanceo de layout y jerarquía visual de entrada */
@media (min-width:981px){
  .workspace-gate:not(.license-gate){
    grid-template-columns:minmax(330px,.86fr) minmax(540px,1.14fr);
  }
  .workspace-gate:not(.license-gate) .workspace-brand-panel{
    padding:clamp(38px,4.4vw,68px);
    gap:15px;
  }
  .workspace-gate:not(.license-gate) .workspace-brand-panel h1{
    max-width:560px;
    font-size:clamp(32px,3.35vw,47px);
    line-height:1.06;
    letter-spacing:-.038em;
  }
  .workspace-gate:not(.license-gate) .workspace-brand-panel>p{
    max-width:540px;
    font-size:14.5px;
    line-height:1.58;
  }
  .workspace-gate:not(.license-gate) .workspace-feature-list{
    max-width:540px;
    gap:9px;
    margin-top:5px;
  }
  .workspace-gate:not(.license-gate) .workspace-feature-list>div{
    grid-template-columns:38px minmax(0,1fr);
    gap:11px;
    padding:10px 12px;
    border-radius:13px;
  }
  .workspace-gate:not(.license-gate) .workspace-feature-list svg{
    width:38px;
    height:38px;
    padding:8px;
    border-radius:10px;
  }
  .workspace-gate:not(.license-gate) .workspace-feature-list strong{font-size:13px}
  .workspace-gate:not(.license-gate) .workspace-feature-list small{font-size:11.25px;line-height:1.35}
  .workspace-gate:not(.license-gate) .workspace-action-panel{
    padding:clamp(28px,3.8vw,58px);
  }
  .workspace-gate:not(.license-gate) .workspace-action-card{
    width:min(720px,100%);
  }
  .workspace-gate:not(.license-gate) .workspace-footnote{max-width:720px}
}
@media (max-width:980px){
  .workspace-gate:not(.license-gate){grid-template-columns:1fr}
}

/* OFI CxC 1.1 Performance & Archive Research — F1 */
.perf-lab{max-width:1440px;margin:0 auto;padding:30px;display:grid;gap:20px;min-height:100vh;background:#f6f8fc}.perf-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;padding:10px 2px}.perf-hero h1{margin:5px 0 8px;font-size:clamp(30px,4vw,48px);letter-spacing:-.04em}.perf-hero p{margin:0;max-width:780px;color:var(--muted,#64748b);font-size:15px;line-height:1.65}.perf-research-badge{white-space:nowrap;border:1px solid #d8dcff;background:#eef0ff;color:#3730a3;border-radius:999px;padding:9px 13px;font-size:12px;font-weight:650;letter-spacing:.05em}.perf-warning{border-left:4px solid #4f46d9;padding:18px 20px}.perf-warning p{margin:5px 0 0;color:#64748b}.perf-layout{display:grid;grid-template-columns:minmax(0,1.05fr) minmax(360px,.95fr);gap:20px}.perf-controls,.perf-environment{padding:24px}.perf-controls{display:grid;gap:16px}.perf-controls .primary-button{justify-content:center;min-height:46px}.perf-preview{display:grid;grid-template-columns:auto 1fr;align-items:baseline;gap:4px 12px;border:1px solid #e4e7ef;background:#f8f9fd;border-radius:14px;padding:14px 16px}.perf-preview span{color:#64748b;font-size:12px;text-transform:uppercase;letter-spacing:.05em}.perf-preview strong{font-size:22px;grid-column:2}.perf-preview small{grid-column:1/-1;color:#64748b}.perf-progress{display:grid;gap:8px}.perf-progress>div:first-child{display:flex;justify-content:space-between;color:#64748b;font-size:12px}.perf-progress-track{height:8px;border-radius:999px;background:#e8ebf4;overflow:hidden}.perf-progress-track span{display:block;width:0;height:100%;background:#4f46d9;transition:width .2s ease}.perf-env-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.perf-env-grid div{border:1px solid #e5e8ef;border-radius:12px;padding:13px;display:grid;gap:4px}.perf-env-grid span{font-size:11px;color:#64748b;text-transform:uppercase}.perf-env-grid strong{font-size:15px}.perf-ua{font-size:11px;line-height:1.5;color:#94a3b8;overflow-wrap:anywhere}.perf-results{padding:22px}.perf-summary-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin-bottom:18px}.perf-summary-grid article{padding:13px;border:1px solid #e6e9f0;border-radius:12px;background:#fbfcfe;display:grid;gap:4px}.perf-summary-grid span{font-size:10px;text-transform:uppercase;color:#64748b}.perf-summary-grid strong{font-size:17px}.perf-results-table table{min-width:720px}.perf-results-table td:nth-child(3),.perf-results-table td:nth-child(4){font-variant-numeric:tabular-nums;white-space:nowrap}.perf-result-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}.perf-footnote{font-size:11px;color:#94a3b8;margin:10px 0 0}.perf-footnote code{font-size:11px}.perf-lab .empty-state{padding:34px;text-align:center}.perf-lab .empty-state p{max-width:720px;margin:6px auto 0;color:#64748b}@media(max-width:980px){.perf-layout{grid-template-columns:1fr}.perf-summary-grid{grid-template-columns:repeat(3,1fr)}}@media(max-width:640px){.perf-lab{padding:16px}.perf-hero{align-items:flex-start;flex-direction:column}.perf-env-grid,.perf-summary-grid{grid-template-columns:1fr 1fr}.perf-result-actions{display:grid}.perf-result-actions button{width:100%}}@media(max-width:420px){.perf-summary-grid,.perf-env-grid{grid-template-columns:1fr}}
/* OFI CxC 1.1 Research F5 — Archive & Period Rollover Lab */
.perf-contract-list{display:grid;gap:10px}.perf-contract-list article{display:grid;gap:4px;padding:13px 14px;border:1px solid #e5e8ef;border-radius:12px;background:#fbfcfe}.perf-contract-list article strong{font-size:13px}.perf-contract-list article span{font-size:12px;line-height:1.5;color:#64748b}.perf-result-header{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;margin-bottom:18px}.perf-result-header h2{margin:4px 0 6px}.perf-result-header p{margin:0;color:#64748b}.perf-health-badge{white-space:nowrap;border-radius:999px;padding:9px 13px;font-size:11px;font-weight:650;letter-spacing:.04em}.perf-health-badge.success{background:#ecfdf3;color:#166534;border:1px solid #bbf7d0}.perf-health-badge.warning{background:#fffbeb;color:#92400e;border:1px solid #fde68a}.perf-summary-grid article small{font-size:10px;line-height:1.35;color:#94a3b8}.perf-export-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}.perf-results>.responsive-table{margin-top:14px}@media(max-width:640px){.perf-result-header{flex-direction:column}.perf-export-actions{display:grid}.perf-export-actions button{width:100%}}


/* === Research F6 · Archive production integration === */
.historical-workspace-banner{display:flex;align-items:center;justify-content:space-between;gap:18px}
.historical-workspace-banner>div{display:flex;flex-direction:column;gap:4px}
.historical-mode .brand-copy small::after{content:' · Histórico';font-weight:620;color:#5f56df}
.archive-settings-stack{display:grid;gap:18px;padding:18px}
.archive-health-card{border-left:4px solid #4fa772}
.archive-health-card.suggest{border-left-color:#d6a331}.archive-health-card.watch{border-left-color:#d77857}.archive-health-card.historical{border-left-color:#5f56df}
.archive-health-grid,.archive-summary-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:14px 0}
.archive-health-grid article,.archive-summary-grid article{border:1px solid var(--line,#e6e8ef);border-radius:12px;padding:13px;background:#fbfbfd;display:flex;flex-direction:column;gap:4px}
.archive-health-grid span,.archive-summary-grid span{font-size:11px;font-weight:650;letter-spacing:.05em;color:#777b88;text-transform:uppercase}
.archive-health-grid strong,.archive-summary-grid strong{font-size:17px;color:#222736}
.archive-health-grid small,.archive-summary-grid small{color:#6f7380}
.archive-safety-list{display:grid;gap:7px;margin:14px 0;padding:13px 15px;border-radius:12px;background:#f7f8fb;font-size:13px;color:#545967}
.archive-history-list{display:grid;gap:10px}
.archive-history-row{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:13px;padding:13px 0;border-bottom:1px solid #eceef3}
.archive-history-row:last-child{border-bottom:0}
.archive-history-icon{width:38px;height:38px;border-radius:11px;background:#f0efff;color:#5f56df;display:grid;place-items:center}
.archive-history-row>div:nth-child(2){display:flex;flex-direction:column;gap:3px;min-width:0}.archive-history-row small{color:#747986;overflow-wrap:anywhere}
.archive-history-actions{display:flex;align-items:center;gap:7px;flex-wrap:wrap;justify-content:flex-end}
.archive-current-historical{margin:18px}.archive-prepared-card{border:1px solid #d8eadd;background:#fbfefc}
.compact-empty{padding:28px 16px}
@media(max-width:760px){.archive-health-grid,.archive-summary-grid{grid-template-columns:1fr}.archive-history-row{grid-template-columns:auto 1fr}.archive-history-actions{grid-column:1/-1;justify-content:flex-start}.historical-workspace-banner{align-items:flex-start;flex-direction:column}}
.archive-heading-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
@media(max-width:760px){.archive-heading-actions{justify-content:flex-start}}

/* === F6 HF3 · Historical Workspace UX + Operational Rollover QA === */
.historical-readonly-chip{display:inline-flex;align-items:center;gap:6px;min-height:38px;padding:8px 12px;border:1px solid #d8dcf4;border-radius:10px;background:#f5f6ff;color:#5146c9;font-size:12px;font-weight:600;white-space:nowrap}
.historical-mode button[hidden]{display:none!important}
.historical-mode .hero-actions:has(.historical-readonly-chip){align-items:center}
.hf3-qa-card{border:1px solid #deddf8;background:linear-gradient(135deg,#fbfbff 0%,#f6f7ff 100%)}
.hf3-qa-card .panel-heading{align-items:flex-start}.hf3-qa-card .panel-heading p{max-width:720px;margin:5px 0 0;color:#687085}
.hf3-qa-badge{display:inline-flex;align-items:center;min-height:28px;padding:6px 10px;border:1px solid #d8d7ff;border-radius:999px;background:#eeedff;color:#4f46c7;font-size:10px;font-weight:650;letter-spacing:.08em;white-space:nowrap}
.hf3-qa-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:14px 0}
.hf3-qa-grid article{display:grid;gap:4px;padding:12px 13px;border:1px solid #e3e4f2;border-radius:12px;background:#fff}
.hf3-qa-grid span{font-size:10px;font-weight:650;letter-spacing:.05em;text-transform:uppercase;color:#74798b}.hf3-qa-grid strong{font-size:18px;color:#20253a}.hf3-qa-grid small{font-size:10.5px;color:#7c8294}
.hf3-qa-actions{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.hf3-qa-actions .text-action{font-size:12px}.hf3-qa-note{display:block;margin-top:10px;color:#8a90a0;font-size:10.5px}
@media(max-width:720px){.hf3-qa-grid{grid-template-columns:1fr}.hf3-qa-actions{display:grid}.hf3-qa-actions>*{width:100%;justify-content:center}.historical-readonly-chip{width:100%;justify-content:center}}

/* F2/7 — Configuración y administración visual de Grupos/Proyectos */
.project-feature-settings{display:grid;gap:12px;padding:14px 15px;border:1px solid #e4e6ef;border-radius:14px;background:#fafbff}
.project-feature-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:18px}
.project-feature-heading h3{margin:3px 0 4px;font-size:15px;color:#34354a}
.project-feature-heading p{max-width:780px;margin:0;color:#777a8f;font-size:11px;line-height:1.5}
.project-feature-toggle{display:inline-flex;align-items:center;gap:8px;min-height:36px;padding:0 11px;border:1px solid #dedfea;border-radius:10px;background:#fff;color:#4f5064;font-size:11px;font-weight:620;white-space:nowrap;cursor:pointer}
.project-feature-toggle input{width:16px;height:16px;margin:0;accent-color:#5147d8}
.project-terminology-fields{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) minmax(220px,.85fr);gap:12px;padding-top:12px;border-top:1px solid #e6e7ef}
.project-terminology-fields[hidden]{display:none!important}
.project-label-preview{display:grid;align-content:center;gap:3px;padding:11px 13px;border:1px solid #e0e1ee;border-radius:11px;background:#fff}
.project-label-preview small{color:#8b8d9e;font-size:9px;font-weight:600;letter-spacing:.07em;text-transform:uppercase}
.project-label-preview strong{color:#4f46d9;font-size:15px;font-weight:620}
.project-label-preview span{color:#85879a;font-size:10px;line-height:1.35}
.project-catalog-summary{display:flex;flex-wrap:wrap;gap:8px;padding:0 0 12px}
.project-catalog-summary>span{display:inline-flex;align-items:center;gap:5px;padding:6px 9px;border:1px solid #e5e6ed;border-radius:999px;background:#fafbff;color:#77798e;font-size:10px}
.project-catalog-summary strong{color:#3f4155}
.project-table td:nth-child(4){white-space:nowrap}
@media(max-width:820px){.project-terminology-fields{grid-template-columns:1fr 1fr}.project-label-preview{grid-column:1/-1}.project-feature-heading{flex-direction:column}.project-feature-toggle{align-self:flex-start}}
@media(max-width:560px){.project-terminology-fields{grid-template-columns:1fr}.project-label-preview{grid-column:auto}.project-feature-settings{padding:11px 12px}}

/* F3/7 — Integración operativa de Grupos/Proyectos y pagador de cobros */
.invoice-project-field-f3 small{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.project-use-suggested-f3{appearance:none;border:0;background:transparent;color:#5147d8;padding:0;font:inherit;font-size:10.5px;font-weight:600;text-decoration:underline;text-underline-offset:2px;cursor:pointer}
.project-use-suggested-f3:hover{color:#3328b8}
.issue-summary>div>span{display:block;margin-top:2px;color:#8a8d9d;font-size:10px;font-weight:650}
@media(max-width:620px){.invoice-project-field-f3 small{align-items:flex-start;flex-direction:column;gap:4px}}

/* F4 — Reporte universal por Grupos/Proyectos */
.project-report-metrics-f4{grid-template-columns:repeat(5,minmax(0,1fr))}
.project-report-heading-f4{margin-bottom:10px;padding:14px 16px}
.project-report-heading-f4 .panel-heading{margin-bottom:4px}
.project-report-heading-f4 p{margin:0;color:#7b7c8e;font-size:12px;line-height:1.5}
.project-report-hint-f4{margin-top:10px;padding:10px 12px;border:1px solid #e5e6ee;border-radius:11px;background:#fafafe;color:#707184;font-size:11px;line-height:1.45}
.project-report-hint-f4 strong{color:#4b4c61}
@media (max-width:1180px){.project-report-metrics-f4{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media (max-width:760px){.project-report-metrics-f4{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:520px){.project-report-metrics-f4{grid-template-columns:1fr}.project-report-heading-f4{padding:12px 13px}}

/* === F7 — Subscription Access Control === */
.subscription-access-banner-f7{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:18px}.subscription-access-banner-f7>div{display:grid;gap:4px}.subscription-access-banner-f7 span{line-height:1.45}.subscription-access-banner-f7.read-only{border-left:4px solid currentColor}.subscription-access-banner-f7.grace{border-left:4px solid currentColor}.license-strip.read-only-f7,.license-strip.grace-f7{font-weight:600}.license-strip.read-only-f7 strong,.license-strip.grace-f7 strong{font-weight:620}.f7-entitlement-summary{display:grid;gap:18px}.f7-entitlement-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.f7-entitlement-grid article{border:1px solid var(--border-color,#dfe3ea);border-radius:14px;padding:16px;display:grid;gap:5px;background:var(--surface,#fff)}.f7-entitlement-grid span{font-size:.78rem;text-transform:uppercase;letter-spacing:.04em;opacity:.72}.f7-entitlement-grid strong{font-size:1rem}.f7-entitlement-grid small{line-height:1.4;opacity:.78}button[aria-disabled="true"],input[aria-disabled="true"],select[aria-disabled="true"],textarea[aria-disabled="true"]{cursor:not-allowed}.subscription-access-banner-f7 .f7-entitlement-action{flex:0 0 auto}@media(max-width:760px){.subscription-access-banner-f7{align-items:flex-start;flex-direction:column}.subscription-access-banner-f7 .f7-entitlement-action{width:100%}.f7-entitlement-grid{grid-template-columns:1fr}}
.f7-entitlement-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap}@media(max-width:760px){.f7-entitlement-actions{width:100%;display:grid;grid-template-columns:1fr}.f7-entitlement-actions .f7-entitlement-action{width:100%}}


/* F8 R1 — Configuración organizada y Rutas opcionales */
.company-settings-panel-f18{padding-bottom:0}
.company-settings-tabs-f18{display:flex;gap:6px;margin:14px 0 0;padding:5px;border:1px solid #e5e6ed;border-radius:12px;background:#f7f8fc;overflow-x:auto}
.company-settings-tabs-f18 button{flex:0 0 auto;min-height:36px;padding:0 13px;border:0;border-radius:8px;background:transparent;color:#686b80;font:inherit;font-size:12px;font-weight:620;white-space:nowrap;cursor:pointer}
.company-settings-tabs-f18 button:hover{background:#fff;color:#4f46d9}
.company-settings-tabs-f18 button.active{background:#fff;color:#4f46d9;box-shadow:0 1px 4px rgba(34,35,58,.10)}
.company-settings-panels-f18{min-height:270px}
.company-settings-panel[hidden]{display:none!important}
.company-settings-panel{padding-top:2px}
.settings-feature-stack{display:grid;gap:14px;padding-top:18px}
.route-feature-fields-f18{padding-top:12px;border-top:1px solid #e7e8f0}
.route-feature-fields-f18[hidden]{display:none!important}
.invoice-header-grid-f18>.span-two,.invoice-header-grid-f18>.span-three{grid-column:1 / -1}
@media(max-width:720px){.company-settings-tabs-f18{margin-top:10px}.company-settings-panels-f18{min-height:0}.invoice-header-grid-f18>.span-two,.invoice-header-grid-f18>.span-three{grid-column:auto}}


/* F8 R1 HF1 — arranque visible y recuperación de caché */
.ofi-startup-placeholder{min-height:100vh;display:grid;place-content:center;gap:8px;text-align:center;color:#32344a;background:#f7f8fc;font-family:"Segoe UI Variable", "Segoe UI", Aptos, system-ui, -apple-system, BlinkMacSystemFont, sans-serif}.ofi-startup-placeholder strong{font-size:20px}.ofi-startup-placeholder span{font-size:13px;color:#777b91}.ofi-startup-recovery{min-height:100vh;display:grid;place-items:center;padding:24px;background:#f7f8fc;font-family:"Segoe UI Variable", "Segoe UI", Aptos, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;color:#2f3148}.ofi-startup-recovery section{width:min(620px,100%);background:#fff;border:1px solid #e4e6ef;border-radius:18px;padding:28px;box-shadow:0 12px 40px rgba(31,34,65,.08)}.ofi-startup-recovery section>strong{font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:#5f56df}.ofi-startup-recovery h1{font-size:24px;margin:8px 0}.ofi-startup-recovery p,.ofi-startup-recovery small{display:block;line-height:1.55;color:#696d82}.ofi-startup-recovery small{margin-top:12px;font-family:ui-monospace,SFMono-Regular,Consolas,monospace;font-size:11px}.ofi-startup-recovery section>div{display:flex;gap:10px;flex-wrap:wrap;margin-top:20px}.ofi-startup-recovery button{min-height:40px;padding:0 15px;border-radius:10px;border:1px solid #d9dce8;background:#fff;color:#3a3d55;font:inherit;font-weight:650;cursor:pointer}.ofi-startup-recovery #ofi-boot-repair{background:#5148dc;border-color:#5148dc;color:#fff}.ofi-startup-recovery button:disabled{opacity:.6;cursor:wait}

/* F9 — Tipos de documento y correlativo interno OFI */
.document-types-settings-f9{display:grid;gap:14px;padding:18px 0 4px}
.document-types-heading-f9{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;padding-bottom:14px;border-bottom:1px solid #e7e8ef}
.document-types-heading-f9 h3{margin:3px 0 5px}
.document-types-heading-f9 p{max-width:760px;margin:0;color:#858699;font-size:11px;line-height:1.5}
.document-types-settings-f9 .catalog-table small{display:block;margin-top:3px;color:#858699}
.document-footer-settings-f9{margin-top:8px;padding-top:18px;border-top:1px solid #e7e8ef}
@media(max-width:720px){.document-types-heading-f9{display:grid}.document-types-heading-f9>.secondary-button{justify-self:start}.document-types-settings-f9{padding-top:14px}}


/* F9 HF1 / Fase 1 — formulario de documentos compacto y alineado */
.invoice-header-grid-f9-compact{
  display:grid;
  grid-template-columns:repeat(12,minmax(0,1fr));
  column-gap:10px;
  row-gap:8px;
  align-items:start;
}
.invoice-header-grid-f9-compact>.field-label{min-width:0;align-self:start}
.invoice-header-grid-f9-compact .invoice-field-customer-f9{grid-column:span 5}
.invoice-header-grid-f9-compact .invoice-field-sale-type-f9{grid-column:span 2}
.invoice-header-grid-f9-compact .invoice-field-document-type-f9{grid-column:span 5}
.invoice-header-grid-f9-compact .invoice-field-seller-f11{grid-column:span 3}
.invoice-header-grid-f9-compact.has-seller .invoice-field-customer-f9{grid-column:span 4}
.invoice-header-grid-f9-compact.has-seller .invoice-field-sale-type-f9{grid-column:span 2}
.invoice-header-grid-f9-compact.has-seller .invoice-field-document-type-f9{grid-column:span 3}
.invoice-header-grid-f9-compact .invoice-field-document-number-f9{grid-column:span 4}
.invoice-header-grid-f9-compact .invoice-field-route-f9{grid-column:span 4}
.invoice-header-grid-f9-compact .invoice-field-project-f9{grid-column:span 4}
.invoice-header-grid-f9-compact .invoice-field-issue-date-f9,
.invoice-header-grid-f9-compact .invoice-field-due-date-f9{grid-column:span 2}
.invoice-header-grid-f9-compact .invoice-field-internal-number-f9{grid-column:span 3}
.invoice-header-grid-f9-compact .invoice-field-notes-f9{grid-column:span 9}
.invoice-header-grid-f9-compact.no-route.no-project .invoice-field-document-number-f9{grid-column:span 5}
.invoice-header-grid-f9-compact.no-route.no-project .invoice-field-internal-number-f9{grid-column:span 3}
.invoice-header-grid-f9-compact.no-route.no-project .invoice-field-notes-f9{grid-column:1 / -1}
.invoice-header-grid-f9-compact.has-route.has-project .invoice-field-document-number-f9{grid-column:span 3}
.invoice-header-grid-f9-compact.has-route.has-project .invoice-field-route-f9{grid-column:span 2}
.invoice-header-grid-f9-compact.has-route.has-project .invoice-field-project-f9{grid-column:span 3}
.invoice-header-grid-f9-compact .invoice-field-notes-f9 textarea{min-height:48px;height:48px;resize:vertical}
.invoice-header-grid-f9-compact .invoice-field-internal-number-f9 input{font-variant-numeric:tabular-nums}
.invoice-form-compact-f9 .invoice-lines-header{margin:14px 0 8px}
.invoice-form-compact-f9 .invoice-lines-header h3{margin-top:2px}
.invoice-form-compact-f9 .invoice-lines{gap:8px}
.invoice-form-compact-f9 .invoice-line{padding:10px;gap:8px}
.invoice-form-compact-f9 .invoice-live-total{margin-top:9px}
@media(max-width:980px){
  .invoice-header-grid-f9-compact{grid-template-columns:repeat(6,minmax(0,1fr))}
  .invoice-header-grid-f9-compact .invoice-field-customer-f9{grid-column:span 4}
  .invoice-header-grid-f9-compact .invoice-field-sale-type-f9{grid-column:span 2}
  .invoice-header-grid-f9-compact .invoice-field-document-type-f9{grid-column:span 3}
  .invoice-header-grid-f9-compact .invoice-field-seller-f11{grid-column:span 3}
  .invoice-header-grid-f9-compact .invoice-field-document-number-f9{grid-column:span 3}
  .invoice-header-grid-f9-compact .invoice-field-route-f9,
  .invoice-header-grid-f9-compact .invoice-field-project-f9{grid-column:span 3}
  .invoice-header-grid-f9-compact .invoice-field-issue-date-f9,
  .invoice-header-grid-f9-compact .invoice-field-due-date-f9{grid-column:span 3}
  .invoice-header-grid-f9-compact .invoice-field-internal-number-f9{grid-column:span 3}
  .invoice-header-grid-f9-compact .invoice-field-notes-f9{grid-column:span 3}
  .invoice-header-grid-f9-compact.no-route.no-project .invoice-field-document-number-f9,
  .invoice-header-grid-f9-compact.no-route.no-project .invoice-field-internal-number-f9{grid-column:span 3}
  .invoice-header-grid-f9-compact.no-route.no-project .invoice-field-notes-f9{grid-column:span 6}
  .invoice-header-grid-f9-compact.has-route.has-project .invoice-field-document-number-f9,
  .invoice-header-grid-f9-compact.has-route.has-project .invoice-field-route-f9,
  .invoice-header-grid-f9-compact.has-route.has-project .invoice-field-project-f9{grid-column:span 2}
}
@media(max-width:720px){
  .invoice-header-grid-f9-compact{grid-template-columns:1fr}
  .invoice-header-grid-f9-compact>.field-label,
  .invoice-header-grid-f9-compact.no-route.no-project>.field-label,
  .invoice-header-grid-f9-compact.has-route.has-project>.field-label{grid-column:auto}
  .invoice-header-grid-f9-compact .invoice-field-notes-f9 textarea{height:56px}
}


/* F9 HF1 / Fase 2 — formulario de cobros compacto y sin espacios vacíos */
.receipt-form-compact-f9{padding-top:10px}
.receipt-header-grid-f9-compact{
  display:grid;
  grid-template-columns:repeat(12,minmax(0,1fr));
  column-gap:10px;
  row-gap:8px;
  align-items:start;
}
.receipt-header-grid-f9-compact>.field-label{min-width:0;align-self:start}
.receipt-header-grid-f9-compact .receipt-field-customer-f9{grid-column:span 4}
.receipt-header-grid-f9-compact .receipt-field-received-from-f9{grid-column:span 5}
.receipt-header-grid-f9-compact .receipt-field-amount-f9{grid-column:span 3}
.receipt-header-grid-f9-compact.no-route .receipt-field-datetime-f9{grid-column:span 3}
.receipt-header-grid-f9-compact.no-route .receipt-field-method-f9{grid-column:span 4}
.receipt-header-grid-f9-compact.no-route .receipt-field-bank-receiver-f9{grid-column:span 5}
.receipt-header-grid-f9-compact.has-route .receipt-field-datetime-f9,
.receipt-header-grid-f9-compact.has-route .receipt-field-method-f9,
.receipt-header-grid-f9-compact.has-route .receipt-field-bank-receiver-f9,
.receipt-header-grid-f9-compact.has-route .receipt-field-route-f9{grid-column:span 3}
.receipt-header-grid-f9-compact .receipt-field-reference-f9,
.receipt-header-grid-f9-compact .receipt-field-check-f9,
.receipt-header-grid-f9-compact .receipt-field-bank-issuer-f9{grid-column:span 4}
.receipt-header-grid-f9-compact .receipt-field-notes-f9,
.receipt-header-grid-f9-compact .receipt-field-correction-f9{grid-column:1 / -1}
.receipt-header-grid-f9-compact .receipt-field-notes-f9 textarea{min-height:44px;height:44px;resize:vertical}
.receipt-form-compact-f9 .receipt-applications-compact-f9{gap:7px;margin:12px 0 10px;padding:11px 12px;border-radius:11px}
.receipt-form-compact-f9 .receipt-applications-compact-f9 h3{font-size:17px;line-height:1.2}
.receipt-form-compact-f9 .receipt-applications-compact-f9>p{margin-bottom:1px;line-height:1.4}
.receipt-form-compact-f9 .receipt-live-summary-compact-f9 .issue-summary{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:8px 0}
.receipt-form-compact-f9 .receipt-live-summary-compact-f9 .issue-summary>div{padding:9px 11px;border-radius:10px}
.receipt-form-compact-f9 .receipt-live-summary-compact-f9 .issue-summary strong{font-size:14px}
.receipt-form-compact-f9 .receipt-live-summary-compact-f9 .message{margin-bottom:8px}
.receipt-form-compact-f9 .receipt-verification-message-f9{margin-bottom:8px}
@media(max-width:980px){
  .receipt-header-grid-f9-compact{grid-template-columns:repeat(6,minmax(0,1fr))}
  .receipt-header-grid-f9-compact .receipt-field-customer-f9{grid-column:span 3}
  .receipt-header-grid-f9-compact .receipt-field-received-from-f9{grid-column:span 3}
  .receipt-header-grid-f9-compact .receipt-field-amount-f9,
  .receipt-header-grid-f9-compact .receipt-field-datetime-f9,
  .receipt-header-grid-f9-compact .receipt-field-method-f9,
  .receipt-header-grid-f9-compact .receipt-field-bank-receiver-f9,
  .receipt-header-grid-f9-compact .receipt-field-route-f9,
  .receipt-header-grid-f9-compact .receipt-field-reference-f9,
  .receipt-header-grid-f9-compact .receipt-field-check-f9,
  .receipt-header-grid-f9-compact .receipt-field-bank-issuer-f9{grid-column:span 3}
  .receipt-header-grid-f9-compact .receipt-field-notes-f9,
  .receipt-header-grid-f9-compact .receipt-field-correction-f9{grid-column:1 / -1}
}
@media(max-width:720px){
  .receipt-header-grid-f9-compact{grid-template-columns:1fr}
  .receipt-header-grid-f9-compact>.field-label,
  .receipt-header-grid-f9-compact.no-route>.field-label,
  .receipt-header-grid-f9-compact.has-route>.field-label{grid-column:auto}
  .receipt-header-grid-f9-compact .receipt-field-notes-f9 textarea{height:54px}
  .receipt-form-compact-f9 .receipt-live-summary-compact-f9 .issue-summary{grid-template-columns:1fr}
}
\n\n/* F9 HF1 / Fase 3 — Detalle del documento compacto */\n.invoice-detail-compact-f9 .invoice-detail-summary-f9{\n  grid-template-columns:repeat(4,minmax(0,1fr));\n  gap:8px;\n  margin-bottom:11px;\n  align-items:start;\n  grid-auto-flow:row dense;\n}\n.invoice-detail-compact-f9 .invoice-detail-summary-f9>.issue-card-f9{\n  min-height:0;\n  align-self:start;\n  align-content:start;\n  gap:3px;\n  padding:9px 11px;\n  border-radius:10px;\n}\n.invoice-detail-compact-f9 .invoice-detail-summary-f9>.issue-card-f9 small{\n  margin:0;\n  font-size:11px;\n  line-height:1.2;\n}\n.invoice-detail-compact-f9 .invoice-detail-summary-f9>.issue-card-f9 strong{\n  min-width:0;\n  font-size:14px;\n  line-height:1.3;\n  overflow-wrap:anywhere;\n}\n.invoice-detail-compact-f9 .invoice-detail-summary-f9>.issue-card-f9>span{\n  margin-top:0;\n  font-size:10px;\n  line-height:1.25;\n}\n.invoice-detail-compact-f9 .issue-card-sale-f9,\n.invoice-detail-compact-f9 .issue-card-status-f9{\n  padding-top:8px;\n  padding-bottom:8px;\n}\n.invoice-detail-compact-f9 .issue-card-status-f9 strong{\n  display:flex;\n  align-items:center;\n  min-height:24px;\n}\n.invoice-detail-compact-f9 .issue-card-status-f9 .status-pill{\n  padding:4px 8px;\n  font-size:10px;\n}\n.invoice-detail-compact-f9 .invoice-detail-table-f9 th,\n.invoice-detail-compact-f9 .invoice-detail-table-f9 td{\n  padding-top:7px;\n  padding-bottom:7px;\n}\n.invoice-detail-compact-f9 .invoice-detail-totals-f9{\n  max-width:340px;\n  gap:4px;\n  margin-top:10px;\n}\n.invoice-detail-compact-f9 .invoice-detail-totals-f9 span{padding:2px 0}\n.invoice-detail-compact-f9 .invoice-detail-totals-f9 .grand-total{\n  padding-top:8px;\n  font-size:17px;\n}\n.invoice-detail-compact-f9 .invoice-detail-message-f9{margin-top:10px;margin-bottom:0}\n.invoice-detail-compact-f9 .modal-actions{margin-top:10px}\n@media(max-width:900px){\n  .invoice-detail-compact-f9 .invoice-detail-summary-f9{grid-template-columns:repeat(2,minmax(0,1fr))}\n}\n@media(max-width:560px){\n  .invoice-detail-compact-f9 .invoice-detail-summary-f9{grid-template-columns:1fr}\n}\n

/* === F9 HF1 · Fase 4 · Normalización tipográfica global === */
/* Mantiene Segoe UI Variable y una jerarquía más ligera, cercana al lenguaje visual de OFI Cloud. */
body,button,input,select,textarea{font-family:"Segoe UI Variable", "Segoe UI", Aptos, system-ui, -apple-system, BlinkMacSystemFont, sans-serif}
h1,h2,h3,h4,h5,h6{font-weight:620}
strong,b{font-weight:620}

/* === F12 HF1 · Refinamiento tipográfico del formulario de corrección === */
/* Mantiene la jerarquía visual ligera de F9 sin alterar la lógica de F12. */
.catalog-modal:has(.invoice-correction-form-f12) .modal-header h2{
  font-weight:580;
}
.invoice-correction-form-f12 .message{
  font-weight:400;
}
.invoice-correction-form-f12 .message strong{
  font-weight:600;
}
.invoice-correction-form-f12 .field-label,
.invoice-correction-form-f12 .invoice-line label{
  font-weight:560;
}
.invoice-correction-form-f12 .invoice-lines-header h3{
  font-weight:580;
}
.invoice-correction-form-f12 .invoice-live-total{
  font-weight:620;
}
.invoice-correction-form-f12 > .field-label > strong{
  font-weight:560;
}

/* === F12 HF2 · Controles del formulario de corrección más ligeros === */
/* Ajuste exclusivamente visual: baja el peso percibido de labels y valores, incluso en controles disabled. */
.invoice-correction-form-f12 .field-label,
.invoice-correction-form-f12 .invoice-line label{
  font-weight:520;
}
.invoice-correction-form-f12 .field-label input,
.invoice-correction-form-f12 .field-label select,
.invoice-correction-form-f12 .field-label textarea,
.invoice-correction-form-f12 .invoice-line input{
  font-weight:380 !important;
  color:#414457;
}
.invoice-correction-form-f12 .field-label input:disabled,
.invoice-correction-form-f12 .field-label select:disabled,
.invoice-correction-form-f12 .field-label textarea:disabled{
  opacity:1;
  color:#5c6072;
  -webkit-text-fill-color:#5c6072;
  font-weight:380 !important;
}
.invoice-correction-form-f12 .field-label select option{
  font-weight:400;
}
.invoice-correction-form-f12 .field-label small{
  font-weight:400;
}

/* === F12 HF3 · Formulario Nuevo documento con tipografía ligera === */
/* Replica la jerarquía aprobada en Corregir documento sin alterar layout ni lógica. */
.catalog-modal:has(.invoice-form-compact-f9:not(.invoice-correction-form-f12)) .modal-header h2{
  font-weight:580;
}
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label,
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .invoice-line label{
  font-weight:520;
}
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label input,
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label select,
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label textarea,
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .invoice-line input{
  font-weight:380 !important;
  color:#414457;
}
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label input:disabled,
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label select:disabled,
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label textarea:disabled{
  opacity:1;
  color:#5c6072;
  -webkit-text-fill-color:#5c6072;
  font-weight:380 !important;
}
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label select option{
  font-weight:400;
}
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .field-label small{
  font-weight:400;
}
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .invoice-lines-header h3{
  font-weight:580;
}
.invoice-form-compact-f9:not(.invoice-correction-form-f12) .invoice-live-total{
  font-weight:620;
}

/* OFI CxC 2.1.0 F2 — Centro de protección de datos */
.protection-center-f22{gap:16px}
.protection-status-pill{display:inline-flex;align-items:center;min-height:28px;padding:6px 10px;border-radius:999px;font-size:10.5px;font-weight:650;white-space:nowrap}
.protection-status-pill.success{background:#eaf8f1;color:#247452}.protection-status-pill.info{background:#eef4fb;color:#355e82}.protection-status-pill.warning{background:#fff7e8;color:#8a641a}.protection-status-pill.danger{background:#fff0ee;color:#9b4038}
.protection-advice-f22{display:grid;grid-template-columns:36px minmax(0,1fr) auto;align-items:center;gap:12px;padding:13px 14px;border:1px solid #dde5ec;border-radius:13px;background:#f8fafc}
.protection-advice-f22>span{width:36px;height:36px;display:grid;place-items:center;border-radius:10px;background:#eef4fb;color:#355e82}.protection-advice-f22>div{display:grid;gap:3px}.protection-advice-f22 strong{font-size:13px;color:#2d4050}.protection-advice-f22 p{margin:0;font-size:11.5px;line-height:1.45;color:#687785}.protection-advice-f22.success{background:#f5faf7;border-color:#d8e8dd}.protection-advice-f22.success>span{background:#e8f4ec;color:#39705a}.protection-advice-f22.warning{background:#fffaf0;border-color:#f0e1bc}.protection-advice-f22.warning>span{background:#fff2ce;color:#8a641a}.protection-advice-f22.danger{background:#fff7f5;border-color:#efd4cf}.protection-advice-f22.danger>span{background:#fee9e5;color:#9b4038}
.protection-metrics-f22{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.protection-metrics-f22 article{display:grid;gap:4px;min-height:92px;padding:13px;border:1px solid #e2e8ee;border-radius:12px;background:#fff}.protection-metrics-f22 small{font-size:9.5px;font-weight:650;letter-spacing:.07em;color:#7b8793}.protection-metrics-f22 strong{font-size:13px;color:#2f4050;overflow-wrap:anywhere}.protection-metrics-f22 span{font-size:10.5px;line-height:1.4;color:#74818c;overflow-wrap:anywhere}
.protection-actions-f22 .backup-restore-card{grid-column:auto}.protection-health-f22{display:flex;flex-wrap:wrap;gap:8px 14px;padding:11px 13px;border-radius:11px;background:#f6f8fb;color:#677785;font-size:11px}.protection-health-f22 span.ok{color:#39705a}.protection-health-f22 span.attention{color:#8a641a}
.protection-reminder-f22{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:0 0 10px;padding:11px 13px;border:1px solid #dfe6ed;border-radius:12px;background:#f8fafc}.protection-reminder-f22>div{display:grid;gap:2px;min-width:0}.protection-reminder-f22 strong{font-size:12.5px;color:#2f4050}.protection-reminder-f22 small{font-size:10.5px;line-height:1.4;color:#74818c}.protection-reminder-f22.warning{background:#fffaf0;border-color:#f0e1bc}.protection-reminder-f22.danger{background:#fff7f5;border-color:#efd4cf}.protection-reminder-f22.info{background:#f5f8fc}
@media(max-width:980px){.protection-metrics-f22{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){.protection-advice-f22{grid-template-columns:34px minmax(0,1fr)}.protection-advice-f22>button{grid-column:1 / -1;width:100%;justify-content:center}.protection-metrics-f22{grid-template-columns:1fr}.protection-reminder-f22{display:grid}.protection-reminder-f22>button{width:100%;justify-content:center}.protection-status-pill{justify-self:start}}

/* OFI CxC 2.1.0 F3 — Attachment Vault */
.attachment-vault-f23{display:grid;gap:16px}.attachment-vault-summary-f23{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.attachment-vault-summary-f23 article{display:grid;gap:4px;min-height:92px;padding:13px;border:1px solid #e2e8ee;border-radius:12px;background:#fff}.attachment-vault-summary-f23 small{font-size:9.5px;font-weight:650;letter-spacing:.07em;color:#7b8793}.attachment-vault-summary-f23 strong{font-size:13px;color:#2f4050;overflow-wrap:anywhere}.attachment-vault-summary-f23 span{font-size:10.5px;line-height:1.4;color:#74818c}.attachment-vault-actions-f23{display:flex;gap:9px;flex-wrap:wrap}.attachment-scan-result-f23{padding:11px 13px;border:1px solid #dde5ec;border-radius:12px;background:#f8fafc}.attachment-scan-metrics-f23{display:flex;gap:8px 16px;flex-wrap:wrap;font-size:11px;color:#6c7985}.attachment-scan-metrics-f23 strong{color:#2f4050}.attachment-review-f23,.attachment-links-f23{display:grid;gap:10px}.attachment-review-f23>header,.attachment-links-f23>header{display:flex;align-items:end;justify-content:space-between;gap:12px}.attachment-review-f23 h3,.attachment-links-f23 h3{margin:2px 0 0;font-size:15px;color:#2f4050}.attachment-review-list-f23{display:grid;gap:7px}.attachment-review-list-f23>div{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border:1px solid #e4e9ee;border-radius:10px;background:#fff}.attachment-review-list-f23>div>span{display:grid;gap:2px;min-width:0}.attachment-review-list-f23 strong{font-size:12px;color:#344451;overflow-wrap:anywhere}.attachment-review-list-f23 small{font-size:10.5px;color:#74818c}.receipt-attachments-f23{display:grid;gap:9px;margin-top:14px;padding-top:13px;border-top:1px solid #e6ebef}.attachment-chip-list-f23{display:flex;gap:7px;flex-wrap:wrap}.attachment-chip-f23{display:inline-flex;align-items:center;gap:6px;max-width:100%;padding:7px 9px;border:1px solid #dbe4eb;border-radius:9px;background:#f8fafc;color:#35536b;font:inherit;font-size:11px;cursor:pointer}.attachment-chip-f23:hover{background:#eef5fa}.attachment-chip-f23 span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.attachment-links-f23 .status-badge{display:inline-flex;padding:4px 7px;border-radius:999px;font-size:10px;font-weight:650}.attachment-links-f23 .status-badge.success{background:#eaf8f1;color:#247452}.attachment-links-f23 .status-badge.danger{background:#fff0ee;color:#9b4038}
@media(max-width:980px){.attachment-vault-summary-f23{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){.attachment-vault-summary-f23{grid-template-columns:1fr}.attachment-vault-actions-f23{display:grid}.attachment-vault-actions-f23 button{width:100%;justify-content:center}.attachment-review-list-f23>div{align-items:flex-start;flex-direction:column}.attachment-review-list-f23 button{width:100%;justify-content:center}}

/* OFI CxC 2.1.0 F4 — Volume & History Intelligence */
.volume-intelligence-f24{display:grid;gap:12px;padding:14px;border:1px solid #dfe6ed;border-radius:13px;background:#fbfcfd}.volume-intelligence-f24>header{display:flex;align-items:flex-start;justify-content:space-between;gap:14px}.volume-intelligence-f24>header h3{margin:2px 0 4px;font-size:15px;color:#2f4050}.volume-intelligence-f24>header p{margin:0;max-width:760px;font-size:11px;line-height:1.5;color:#6f7c87}.volume-status-pill-f24{display:inline-flex;align-items:center;min-height:27px;padding:5px 9px;border-radius:999px;background:#edf4f8;color:#416275;font-size:10px;font-weight:650;white-space:nowrap}.volume-status-pill-f24.success{background:#eaf8f1;color:#247452}.volume-status-pill-f24.warning{background:#fff7e5;color:#8a6421}.volume-status-pill-f24.info{background:#eef4fa;color:#3f627c}.volume-metrics-f24{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.volume-metrics-f24 article{display:grid;gap:4px;min-height:91px;padding:12px;border:1px solid #e3e8ed;border-radius:11px;background:#fff}.volume-metrics-f24 small{font-size:9.5px;font-weight:650;letter-spacing:.07em;color:#7b8793}.volume-metrics-f24 strong{font-size:13px;color:#2f4050}.volume-metrics-f24 span{font-size:10.5px;line-height:1.4;color:#74818c}.volume-health-f24{display:flex;gap:8px 16px;flex-wrap:wrap;padding-top:2px;font-size:10.5px;color:#697783}.volume-health-f24 .ok{color:#2e7355}.volume-health-f24 .attention{color:#9a5d34}.volume-reminder-f24{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:0 0 10px;padding:11px 13px;border:1px solid #dce7ef;border-radius:12px;background:#f5f9fc}.volume-reminder-f24>div{display:grid;gap:2px;min-width:0}.volume-reminder-f24 strong{font-size:12.5px;color:#2f4050}.volume-reminder-f24 small{font-size:10.5px;line-height:1.4;color:#74818c}
@media(max-width:900px){.volume-metrics-f24{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){.volume-intelligence-f24>header{display:grid}.volume-status-pill-f24{justify-self:start}.volume-metrics-f24{grid-template-columns:1fr}.volume-reminder-f24{display:grid}.volume-reminder-f24>button{width:100%;justify-content:center}}

/* OFI CxC 2.1.0 F7 — Trabajo entre equipos */
.roaming-banner-f27{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:14px 16px;margin:0 0 16px;border:1px solid var(--border-color,#d9e0e7);border-radius:14px;background:var(--surface,#fff)}
.roaming-banner-f27>div:first-child{display:grid;gap:3px;min-width:0}.roaming-banner-f27 strong{font-size:14px}.roaming-banner-f27 small{color:var(--muted,#667085);line-height:1.45}.roaming-banner-f27.success{border-color:#b7dfc6}.roaming-banner-f27.warning{border-color:#ead7a2}.roaming-banner-f27.danger{border-color:#e7b8b8}.roaming-banner-f27.info{border-color:#bdd6ea}.roaming-actions-f27{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}.roaming-actions-f27 .primary-button,.roaming-actions-f27 .secondary-button{white-space:nowrap}
@media(max-width:760px){.roaming-banner-f27{align-items:flex-start;flex-direction:column}.roaming-actions-f27{width:100%;justify-content:flex-start}.roaming-actions-f27 button{flex:1}}

/* === 2.1.0 Stable HF1 — OFI DB UX cleanup === */
.dashboard-title-row-hf1{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.dashboard-title-row-hf1 h1{margin:0}
.company-context-badge-hf1{font-size:10px;line-height:1;padding:6px 9px;letter-spacing:.02em;white-space:nowrap}


/* Stable HF7 — UX Refinement */
.license-strip{position:relative}
.license-strip-plan-f7{min-width:0;white-space:nowrap}
.license-strip-notice-f7{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);display:inline-flex;align-items:center;justify-content:center;gap:6px;max-width:min(52vw,760px);min-height:28px;padding:4px 11px;border:1px solid #bfe4cf;border-radius:999px;background:#f0fbf5;color:#18704d;font-size:12px;font-weight:620;line-height:1.25;box-shadow:0 2px 8px rgba(24,112,77,.06);transition:opacity .18s ease,transform .18s ease;z-index:1}
.license-strip-notice-f7>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.license-strip-notice-f7.is-hiding{opacity:0;transform:translate(-50%,-56%)}
.gate-entry-busy-f7{pointer-events:none;min-width:190px}
.button-spinner-f7{width:16px;height:16px;border:2px solid rgba(255,255,255,.42);border-top-color:#fff;border-radius:50%;animation:ofi-spin-f7 .72s linear infinite;flex:0 0 auto}
@keyframes ofi-spin-f7{to{transform:rotate(360deg)}}
@media(max-width:980px){.license-strip-notice-f7{max-width:42vw}}
@media(max-width:680px){.license-strip{position:static}.license-strip-plan-f7{white-space:normal}.license-strip-notice-f7{position:static;transform:none;order:3;width:100%;max-width:none;justify-content:flex-start;border-radius:10px}.license-strip-notice-f7.is-hiding{transform:none}.license-strip>button{align-self:flex-end}.gate-entry-busy-f7{min-width:0}}


/* Stable HF7 RC2 — Customer Form Layout */
.catalog-modal:has(.customer-form-f7){width:min(920px,96vw);max-width:920px}
.customer-form-f7{padding-top:8px}
.customer-form-grid-f7{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));column-gap:12px;row-gap:9px;align-items:start}
.customer-form-grid-f7>.field-label{min-width:0;align-self:start}
.customer-span-2{grid-column:span 2}
.customer-span-3{grid-column:span 3}
.customer-span-4{grid-column:span 4}
.customer-span-6{grid-column:1 / -1}
.customer-section-f7{display:flex;align-items:center;gap:10px;margin-top:3px;padding-top:9px;border-top:1px solid #eceef5;color:#6257df;font-size:10px;font-weight:750;letter-spacing:.08em;text-transform:uppercase;line-height:1}
.customer-section-f7:first-child{margin-top:0;padding-top:0;border-top:0}
.customer-section-f7::after{content:"";height:1px;flex:1;background:#f1f2f7}
.customer-code-hint-f7{margin-top:0;color:#7d8190}
.customer-form-grid-f7 textarea{min-height:58px}
@media(max-width:840px){
  .catalog-modal:has(.customer-form-f7){width:min(760px,96vw)}
  .customer-form-grid-f7{grid-template-columns:repeat(2,minmax(0,1fr))}
  .customer-span-2,.customer-span-3,.customer-span-4{grid-column:span 1}
  .customer-span-6,.customer-section-f7{grid-column:1 / -1}
}
@media(max-width:620px){
  .customer-form-grid-f7{grid-template-columns:1fr}
  .customer-span-2,.customer-span-3,.customer-span-4,.customer-span-6,.customer-section-f7{grid-column:1 / -1}
}


/* Stable HF7 RC3 — Form alignment, customer-facing copy and close feedback */
/* Checkboxes inside modal grids must not inherit full-width text-input sizing. */
.modal-body form .form-grid > label.check-field input[type="checkbox"]{width:18px;height:18px;min-height:0;padding:0;flex:0 0 18px;border-radius:4px}

/* Viajes / proyectos: intentional six-column rhythm instead of equal halves. */
.catalog-modal:has(.project-form-hf7){width:min(900px,96vw);max-width:900px}
.project-form-grid-hf7{grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}
.project-span-2-hf7{grid-column:span 2}
.project-span-3-hf7{grid-column:span 3}
.project-span-4-hf7{grid-column:span 4}
.project-span-6-hf7{grid-column:span 6}
.project-form-grid-hf7>.field-label{align-content:start}
.project-form-grid-hf7>.field-label small{line-height:1.35}

/* Métodos de pago: balanced primary fields + compact option cards. */
.catalog-modal:has(.payment-method-form-hf7){width:min(880px,96vw);max-width:880px}
.payment-method-grid-hf7{grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}
.payment-span-2-hf7{grid-column:span 2}
.payment-span-3-hf7{grid-column:span 3}
.payment-span-4-hf7{grid-column:span 4}
.payment-span-6-hf7{grid-column:span 6}
.payment-method-options-hf7{margin:1px 0 0;padding:11px 12px 12px;border:1px solid #e3e4ed;border-radius:11px;background:#fbfbfd}
.payment-method-options-hf7 legend{padding:0 6px;color:#646679;font-size:11px;font-weight:700}
.payment-method-options-grid-hf7{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 10px}
.payment-option-hf7{min-height:42px;padding:9px 11px;border:1px solid #e3e4ed;border-radius:9px;background:#fff;gap:9px}
.payment-option-hf7:hover{border-color:#cbc8f6;background:#faf9ff}
.payment-option-hf7 span{line-height:1.3}
.payment-state-help-hf7{align-self:end;min-height:42px;display:flex;align-items:center;padding:8px 10px;color:#858699;font-size:10px;line-height:1.4}

/* Closing a workspace gets the same immediate affordance as Continue working. */
.logout-button.close-company-busy-f7{pointer-events:none;opacity:.82;min-width:142px}
.logout-button.close-company-busy-f7 .button-spinner-f7{border-color:rgba(81,70,216,.20);border-top-color:#5146d8}

@media(max-width:760px){
  .project-form-grid-hf7,.payment-method-grid-hf7{grid-template-columns:repeat(2,minmax(0,1fr))}
  .project-span-2-hf7,.project-span-3-hf7,.project-span-4-hf7,.payment-span-2-hf7,.payment-span-3-hf7,.payment-span-4-hf7{grid-column:span 1}
  .project-span-6-hf7,.payment-span-6-hf7{grid-column:span 2}
  .payment-method-options-grid-hf7{grid-template-columns:1fr 1fr}
}
@media(max-width:520px){
  .project-form-grid-hf7,.payment-method-grid-hf7,.payment-method-options-grid-hf7{grid-template-columns:1fr}
  .project-span-2-hf7,.project-span-3-hf7,.project-span-4-hf7,.project-span-6-hf7,.payment-span-2-hf7,.payment-span-3-hf7,.payment-span-4-hf7,.payment-span-6-hf7{grid-column:span 1}
  .payment-state-help-hf7{min-height:0;padding:2px 0 4px}
}

/* OFI CxC 3.0.0 HF8 — Protection overview visual spacing
   UI-only hotfix: no database, protection, roaming or backup logic changes. */
.protection-overview-f22{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:12px;
}
.protection-overview-f22>article{
  display:grid;
  align-content:start;
  gap:6px;
  min-width:0;
  min-height:108px;
  padding:14px 15px;
  border:1px solid #e2e8ee;
  border-radius:12px;
  background:#fff;
}
.protection-overview-f22>article>small{
  display:block;
  margin:0;
  font-size:9.5px;
  line-height:1.35;
  font-weight:650;
  letter-spacing:.07em;
  color:#7b8793;
}
.protection-overview-f22>article>strong{
  display:block;
  margin:0;
  font-size:13px;
  line-height:1.38;
  font-weight:650;
  color:#2f4050;
  overflow-wrap:anywhere;
  word-break:normal;
}
.protection-overview-f22>article>span{
  display:block;
  margin:0;
  font-size:10.5px;
  line-height:1.5;
  color:#74818c;
  overflow-wrap:anywhere;
  word-break:normal;
}
@media(max-width:980px){
  .protection-overview-f22{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:620px){
  .protection-overview-f22{grid-template-columns:1fr}
  .protection-overview-f22>article{min-height:0}
}

/* OFI CxC 3.0.0 HF9 — compact workspace + searchable relational selectors
   UI-only: native selects remain authoritative; no data/schema/roaming behavior changes. */
.page-container{margin-top:10px}
.roaming-banner-f27{gap:12px;padding:9px 12px;margin-bottom:10px;border-radius:12px}
.roaming-banner-f27>div:first-child{gap:1px}
.roaming-banner-f27 .eyebrow{font-size:9px}
.roaming-banner-f27 strong{font-size:12.5px}
.roaming-banner-f27 small{font-size:10.5px;line-height:1.3}
.roaming-actions-f27 .primary-button,.roaming-actions-f27 .secondary-button{min-height:36px;padding:0 12px;font-size:11px}
.hero-card,.compact-hero{padding:10px 14px;gap:14px}
.hero-card h1,.compact-hero h1{margin:1px 0 2px;font-size:clamp(23px,2.1vw,29px)}
.hero-card p,.compact-hero p{font-size:11.5px;line-height:1.32}
.hero-actions .primary-button,.hero-actions .secondary-button{min-height:38px;padding:0 13px;font-size:11px}
.panel{padding:13px}
.compact-form{gap:8px;align-items:end}
.compact-form label{gap:4px;font-size:10px}
.compact-form input,.compact-form select{min-height:38px;height:38px;padding:0 10px;border-radius:9px;font-size:11.5px}
.panel:has(> .compact-form){padding:10px 12px}
.catalog-summary-grid{margin:8px 0 10px}
.catalog-summary-grid article{min-height:60px;padding:8px 11px}
.catalog-summary-grid strong{font-size:17px}

.ofi-search-select-hf9{position:relative;width:100%;min-width:0}
.ofi-search-input-hf9{width:100%;height:38px;min-height:38px;padding:0 34px 0 10px;border:1px solid #d8dce8;border-radius:9px;background:#fff;color:#1d2939;font:inherit;font-size:11.5px;outline:0;text-overflow:ellipsis}
.ofi-search-input-hf9::-webkit-search-cancel-button{display:none}
.ofi-search-select-hf9:focus-within .ofi-search-input-hf9{border-color:#655ae5;box-shadow:0 0 0 3px rgba(81,70,216,.10)}
.ofi-search-arrow-hf9{position:absolute;right:10px;top:50%;transform:translateY(-50%);display:grid;place-items:center;color:#76798e;pointer-events:none;transition:transform .16s ease}
.ofi-search-select-hf9.is-open .ofi-search-arrow-hf9{transform:translateY(-50%) rotate(180deg)}
.ofi-search-native-hf9{position:absolute!important;left:0!important;bottom:0!important;width:1px!important;height:1px!important;min-height:1px!important;padding:0!important;margin:0!important;opacity:0!important;pointer-events:none!important;border:0!important}
.ofi-search-menu-hf9{position:absolute;z-index:140;left:0;right:0;top:calc(100% + 5px);max-height:250px;overflow:auto;padding:5px;border:1px solid #dfe2eb;border-radius:10px;background:#fff;box-shadow:0 14px 36px rgba(35,38,67,.16)}
.ofi-search-option-hf9{width:100%;min-height:34px;display:flex;align-items:center;border:0;border-radius:7px;padding:6px 9px;color:#33364b;text-align:left;background:transparent;font:inherit;font-size:11.5px;line-height:1.25;cursor:pointer}
.ofi-search-option-hf9:hover,.ofi-search-option-hf9.is-active{background:#f1efff;color:#4439c9}
.ofi-search-option-hf9.is-selected{font-weight:650;background:#f7f6ff}
.ofi-search-option-hf9:disabled{opacity:.45;cursor:not-allowed}
.ofi-search-empty-hf9{padding:10px 9px;color:#85889a;font-size:11px;text-align:center}
.ofi-search-select-hf9.is-disabled .ofi-search-input-hf9{background:#f5f6f8;color:#9295a5;cursor:not-allowed}
.catalog-toolbar .ofi-search-select-hf9{min-width:170px}
.modal-card .ofi-search-input-hf9,.field-label .ofi-search-input-hf9{height:38px;min-height:38px;font-size:12px}

@media(max-width:720px){
  .page-container{margin-top:7px}
  .roaming-banner-f27{padding:8px 10px;margin-bottom:8px}
  .hero-card,.compact-hero{padding:10px 12px;gap:9px}
  .panel{padding:11px}
  .panel:has(> .compact-form){padding:9px 10px}
  .ofi-search-menu-hf9{max-height:220px}
}

/* HF9.4 — recuperación de acceso online desde autorización local */
.license-strip-actions-f94{display:inline-flex;align-items:center;gap:12px;flex:0 0 auto}
.workspace-offline-access-f94{display:flex;align-items:center;gap:10px;margin-top:5px}
.workspace-offline-access-f94 .text-button{min-height:0;padding:2px 0;border:0;background:transparent;color:#4f46e5;font:inherit;font-size:12px;font-weight:620;cursor:pointer}
@media(max-width:680px){.license-strip-actions-f94{width:100%;justify-content:flex-end}.workspace-offline-access-f94{align-items:flex-start;flex-direction:column;gap:5px}}

/* F1/6 — Functional Hardening: inline modal errors, dynamic payment requirements, portal dropdowns */
.modal-inline-error-f1{
  position:sticky;
  top:0;
  z-index:12;
  margin:0 0 10px;
  box-shadow:0 5px 18px rgba(180,35,24,.08);
}
.modal-inline-error-f1[hidden]{display:none!important}
.field-error-f1,
.modal-card .field-error-f1,
.ofi-search-input-hf9.field-error-f1{
  border-color:#d92d20!important;
  box-shadow:0 0 0 3px rgba(217,45,32,.10)!important;
}
.field-title-f1{display:inline-flex;align-items:center;gap:2px;min-width:0}
.dynamic-required-f1::after{content:''}
.field-required-f1 .dynamic-required-f1::after{content:'*';color:#b42318;font-weight:700}
.payment-field-inactive-f1{opacity:.52}
.payment-field-inactive-f1 .field-title-f1{color:#85889a}
.ofi-search-menu-hf9.is-portal-f1{z-index:10020!important;margin:0!important;box-sizing:border-box}
.catalog-modal[data-pending="1"]{cursor:progress}

/* F2/6 — Compact Forms & Uniform UX
   Visual/interaction layer only: compact density, required-field clarity,
   textarea alignment, safe close affordance and consistent modal rhythm. */
.modal-ux-f2 .modal-body{padding-top:12px}
.modal-ux-f2 .compact-form-f2{position:relative}
.modal-required-note-f2{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:4px;
  min-height:18px;
  margin:0 0 6px;
  color:#7b7e91;
  font-size:10px;
  line-height:1.2;
}
.modal-required-note-f2>span,.required-mark-f2{color:#b42318;font-weight:700}
.field-title-f2{display:inline-flex;align-items:center;gap:3px;min-width:0}
.modal-ux-f2 .field-label,
.modal-ux-f2 .form-grid>label:not(.check-field){
  align-content:start;
  min-width:0;
  font-weight:520;
}
.modal-ux-f2 .field-label input,
.modal-ux-f2 .field-label select,
.modal-ux-f2 .form-grid>label:not(.check-field)>input,
.modal-ux-f2 .form-grid>label:not(.check-field)>select{
  font-weight:380;
  color:#414457;
}
.modal-ux-f2 textarea.compact-textarea-f2{
  min-height:38px!important;
  max-height:132px;
  padding:8px 10px!important;
  resize:none;
  line-height:1.35;
  font-weight:380;
  color:#414457;
  transition:height .08s ease,border-color .12s ease,box-shadow .12s ease;
}
.modal-ux-f2 .invoice-field-notes-f9 textarea.compact-textarea-f2,
.modal-ux-f2 .receipt-field-notes-f9 textarea.compact-textarea-f2,
.modal-ux-f2 .credit-notes-field-f2 textarea.compact-textarea-f2{
  min-height:38px!important;
}
.modal-ux-f2 .modal-actions{
  z-index:14;
  margin-top:12px;
  padding-top:9px;
  padding-bottom:9px;
  background:rgba(255,255,255,.97);
  box-shadow:0 -8px 20px rgba(31,34,65,.035);
}
.modal-ux-f2 .modal-actions .primary-button,
.modal-ux-f2 .modal-actions .secondary-button,
.modal-ux-f2 .modal-actions .danger-button{min-height:36px;padding:0 13px}
.modal-ux-f2 input:disabled,
.modal-ux-f2 select:disabled,
.modal-ux-f2 textarea:disabled{
  opacity:1;
  color:#686b7d;
  -webkit-text-fill-color:#686b7d;
  background:#f5f6f8;
}
.modal-ux-f2 .message{line-height:1.4}

/* Invoice/correction: Notes starts at the same control height as adjacent fields and grows with content. */
.invoice-header-grid-f9-compact .invoice-field-notes-f9 textarea{min-height:38px!important;height:38px}

/* Payment form: keep the header dense while giving applications a clear visual hierarchy. */
.receipt-form-compact-f9 .receipt-applications-compact-f9{
  border-color:#e4e6ef;
  background:#fafbfe;
}
.receipt-form-compact-f9 .application-row-f05{min-height:48px;padding:9px 11px}
.receipt-form-compact-f9 .application-row-f05 input{min-height:36px;height:36px}
.receipt-customer-step-f2 .message{margin-top:8px;margin-bottom:4px}
.catalog-modal:has(.receipt-customer-step-f2){width:min(620px,96vw);max-width:620px}

/* Credit note form: two-column compact layout with a single aligned notes row. */
.catalog-modal:has(.credit-form-compact-f2){width:min(760px,96vw);max-width:760px}
.credit-form-compact-f2{padding-top:4px}
.credit-form-grid-f2{grid-template-columns:repeat(2,minmax(0,1fr));column-gap:10px;row-gap:8px;align-items:start}
.credit-form-grid-f2>.full-field{grid-column:1 / -1}
.credit-form-grid-f2>.field-label{min-width:0}

/* Cash-sale issue confirmation gets enough width to avoid cramped two-column controls. */
.catalog-modal:has(.issue-form-compact-f2){width:min(780px,96vw);max-width:780px}
.issue-form-compact-f2 .issue-summary{gap:8px;margin-bottom:12px}
.issue-form-compact-f2 .issue-summary>div{padding:9px 11px;border-radius:10px}
.issue-form-compact-f2 .form-grid{column-gap:10px;row-gap:8px}
.issue-form-compact-f2 .message{margin-bottom:8px}

/* Catalog forms: denser textarea and section spacing without changing data contracts. */
.catalog-modal:has(#bank-form) .form-grid,
.catalog-modal:has(#route-form) .form-grid,
.catalog-modal:has(#seller-form) .form-grid,
.catalog-modal:has(#document-type-form) .form-grid{column-gap:10px;row-gap:8px}
.catalog-modal:has(#bank-form){width:min(720px,96vw);max-width:720px}
.catalog-modal:has(#route-form),
.catalog-modal:has(#seller-form),
.catalog-modal:has(#document-type-form){width:min(680px,96vw);max-width:680px}

@media(max-width:720px){
  .modal-required-note-f2{justify-content:flex-start;margin-bottom:7px}
  .credit-form-grid-f2{grid-template-columns:1fr}
  .credit-form-grid-f2>.full-field{grid-column:auto}
  .catalog-modal:has(.credit-form-compact-f2),
  .catalog-modal:has(.issue-form-compact-f2),
  .catalog-modal:has(.receipt-customer-step-f2),
  .catalog-modal:has(#bank-form),
  .catalog-modal:has(#route-form),
  .catalog-modal:has(#seller-form),
  .catalog-modal:has(#document-type-form){width:100%;max-width:none}
}

/* F3/6 — Tables, records, pagination & consolidated balance reports */
.table-pager-f3{
  display:grid;
  grid-template-columns:minmax(180px,1fr) auto minmax(180px,1fr);
  align-items:center;
  gap:12px;
  margin:0 -13px -13px;
  padding:9px 13px;
  border-top:1px solid #e7e9f1;
  border-radius:0 0 12px 12px;
  background:#fafbfe;
  color:#6f7285;
  font-size:11px;
}
.table-pager-range-f3{display:flex;align-items:baseline;gap:5px;min-width:0}
.table-pager-range-f3 strong{color:#34374b;font-size:12px;font-variant-numeric:tabular-nums}
.table-pager-range-f3 span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.table-pager-page-f3{display:inline-flex;align-items:center;gap:6px;padding:4px 9px;border:1px solid #e2e5ee;border-radius:999px;background:#fff;color:#777a8d;white-space:nowrap}
.table-pager-page-f3 strong{color:#35384d;font-size:12px;font-variant-numeric:tabular-nums}
.table-pager-actions-f3{display:flex;justify-content:flex-end;gap:6px}
.table-pager-button-f3{min-height:32px;display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:0 10px;border:1px solid #dfe2ec;border-radius:8px;background:#fff;color:#484b60;font:inherit;font-weight:600;cursor:pointer}
.table-pager-button-f3 span{font-size:18px;line-height:1;color:#676a80}
.table-pager-button-f3:hover:not(:disabled){border-color:#c9c8f5;background:#f7f6ff;color:#4038b7}
.table-pager-button-f3:disabled{opacity:.42;cursor:not-allowed;background:#f5f6f8}

/* Group/Project consolidated sheet: summary first, audit detail secondary. */
.project-balance-metrics-f3{grid-template-columns:repeat(4,minmax(0,1fr))}
.project-balance-heading-f3{padding:11px 13px;margin-bottom:9px}
.project-balance-heading-f3 .panel-heading{margin:0}
.project-balance-heading-f3 .panel-heading p{margin:3px 0 0;color:#74778b;font-size:11px;line-height:1.4}
.project-balance-row-f3 td{vertical-align:middle}
.project-balance-row-f3 td:nth-child(n+3){font-variant-numeric:tabular-nums;text-align:right}
.project-balance-cell-f3 strong{color:#25236a;font-size:13.5px}
.project-detail-drawer-f3{margin:10px 0 0;border:1px solid #e3e6ef;border-radius:12px;background:#fff;overflow:hidden}
.project-detail-drawer-f3>summary{min-height:48px;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:9px 13px;background:#fafbfe;cursor:pointer;list-style:none}
.project-detail-drawer-f3>summary::-webkit-details-marker{display:none}
.project-detail-drawer-f3>summary>span:first-child{display:grid;gap:2px}
.project-detail-drawer-f3>summary strong{color:#34374b;font-size:12.5px}
.project-detail-drawer-f3>summary small{color:#828598;font-size:10px}
.project-detail-chevron-f3{color:#777a8d;font-size:17px;transition:transform .15s ease}
.project-detail-drawer-f3[open] .project-detail-chevron-f3{transform:rotate(180deg)}
.project-detail-body-f3{padding:10px}
.project-detail-body-f3 .report-table-panel{margin-bottom:0}

/* Statement: clearer movement hierarchy without adding vertical bulk. */
.statement-table-wrap-f3{border-top:1px solid #eef0f5}
.statement-table-f3 td,.statement-table-f3 th{vertical-align:middle}
.statement-table-f3 .money-column-f3{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap}
.statement-opening-row-f3{background:#f8f9fc}
.statement-movement-row-f3.is-reversal{background:#fffaf5}
.statement-kind-f3{display:inline-flex;align-items:center;margin-right:7px;padding:3px 6px;border-radius:999px;font-size:9px;font-weight:650;line-height:1;text-transform:uppercase;letter-spacing:.035em;vertical-align:middle}
.statement-kind-f3.opening{background:#eef0f5;color:#626579}
.statement-kind-f3.debit{background:#eef4ff;color:#315da8}
.statement-kind-f3.credit{background:#eaf8f1;color:#137a57}
.statement-kind-f3.reversal{background:#fff1e8;color:#a45516}
.statement-description-f3{vertical-align:middle}
.statement-debit-f3{color:#394d78}
.statement-credit-f3{color:#176d51}
.statement-balance-f3 strong{color:#29275f}

.report-table-panel .responsive-table td,.report-table-panel .responsive-table th{padding-top:7px;padding-bottom:7px}
.report-table-panel .responsive-table th{background:#fafbfe}

@media(max-width:760px){
  .table-pager-f3{grid-template-columns:1fr auto;margin-left:-11px;margin-right:-11px;margin-bottom:-11px;padding:8px 11px}
  .table-pager-page-f3{grid-column:1 / -1;grid-row:1;justify-self:center}
  .table-pager-range-f3{grid-column:1;grid-row:2}
  .table-pager-actions-f3{grid-column:2;grid-row:2}
  .table-pager-button-f3{width:34px;padding:0;font-size:0;gap:0}
  .table-pager-button-f3 span{font-size:20px}
  .project-balance-metrics-f3{grid-template-columns:repeat(2,minmax(0,1fr))}
  .project-detail-body-f3{padding:7px}
}
.project-balance-total-f3{background:#f5f6fb;border-top:2px solid #dfe2ec}
.project-balance-total-f3 td{font-variant-numeric:tabular-nums;text-align:right}
.project-balance-total-f3 td:first-child,.project-balance-total-f3 td:nth-child(2){text-align:left}

/* F4/6 RC1 — OFI Contextual Help */
.help-topbar-button-f4{position:relative}
.modal-help-button-f4{margin-left:auto;min-height:34px;display:inline-flex;align-items:center;gap:6px;padding:0 10px;border:1px solid #dfe2eb;border-radius:9px;background:#f8f9fc;color:#4b4e68;font:inherit;font-size:11px;font-weight:650;cursor:pointer}
.modal-help-button-f4:hover{background:#f0f1f7;color:#34375d;border-color:#d3d7e4}
.modal-help-button-f4>span:first-child{width:18px;height:18px;display:grid;place-items:center;border-radius:999px;background:#ecebff;color:#4a42c7;font-size:11px;font-weight:750}
.launcher-help-item-f4 .launcher-item-icon{background:#f1f0ff;color:#5147cf}
.ofi-help-backdrop-f4{position:fixed;inset:0;z-index:1800;display:flex;justify-content:flex-end;background:rgba(22,23,48,.28);backdrop-filter:blur(1px)}
.ofi-help-panel-f4{width:min(470px,100vw);height:100vh;display:flex;flex-direction:column;background:#fff;border-left:1px solid #e1e3ec;box-shadow:-24px 0 64px rgba(22,23,48,.20);animation:ofiHelpInF4 .18s ease-out}
@keyframes ofiHelpInF4{from{transform:translateX(18px);opacity:.6}to{transform:translateX(0);opacity:1}}
.ofi-help-header-f4{display:flex;align-items:flex-start;gap:12px;padding:18px 18px 13px;border-bottom:1px solid #ececf2;background:#fbfbfe}
.ofi-help-header-f4>div:first-child{min-width:0;flex:1}
.ofi-help-header-f4 h2{margin:3px 0 0;color:#2f3149;font-size:20px;line-height:1.15;font-weight:680;letter-spacing:-.02em}
.ofi-help-header-actions-f4{display:flex;align-items:center;gap:7px}
.ofi-help-index-button-f4{height:34px;padding:0 10px;border:1px solid #dfe2eb;border-radius:9px;background:#fff;color:#55586c;font:inherit;font-size:11px;font-weight:650;cursor:pointer}
.ofi-help-index-button-f4:hover{background:#f4f5f9}
.ofi-help-search-wrap-f4{display:flex;align-items:center;gap:8px;margin:13px 16px 10px;padding:0 11px;border:1px solid #dfe2eb;border-radius:10px;background:#fff}
.ofi-help-search-wrap-f4:focus-within{border-color:#655ae5;box-shadow:0 0 0 3px rgba(81,70,216,.09)}
.ofi-help-search-wrap-f4>span{color:#777a8c;font-size:20px;line-height:1}
.ofi-help-search-wrap-f4 input{width:100%;height:39px;border:0;outline:0;background:transparent;color:#303246;font:inherit;font-size:12px}
.ofi-help-body-f4,.ofi-help-results-f4{flex:1;min-height:0;overflow:auto;padding:4px 16px 18px;overscroll-behavior:contain}
.ofi-help-article-heading-f4{padding:12px 13px 13px;border:1px solid #e6e7ef;border-radius:12px;background:#fafaff}
.ofi-help-article-heading-f4>span{color:#5d55cf;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.06em}
.ofi-help-article-heading-f4 h3{margin:4px 0 6px;color:#292b42;font-size:20px;line-height:1.2}
.ofi-help-article-heading-f4 p{margin:0;color:#65687b;font-size:12px;line-height:1.55}
.ofi-help-article-f4 section{margin-top:16px}
.ofi-help-article-f4 section h4{margin:0 0 8px;color:#34364b;font-size:12px;font-weight:700}
.ofi-help-article-f4 ol{display:grid;gap:8px;margin:0;padding-left:23px;color:#4d5064;font-size:12px;line-height:1.5}
.ofi-help-article-f4 li::marker{color:#5b53d2;font-weight:700}
.ofi-help-tips-f4{padding:12px 13px;border:1px solid #e2e4ef;border-radius:11px;background:#f8f9fc}
.ofi-help-tips-f4 p{margin:0;color:#56596d;font-size:11.5px;line-height:1.5}
.ofi-help-tips-f4 p+p{margin-top:8px;padding-top:8px;border-top:1px solid #e5e7ef}
.ofi-help-category-f4{margin:8px 0 14px}
.ofi-help-category-f4>h4{margin:0 0 6px;padding:0 2px;color:#73768a;font-size:10px;text-transform:uppercase;letter-spacing:.06em}
.ofi-help-result-f4{width:100%;display:grid;gap:3px;margin-bottom:6px;padding:10px 11px;border:1px solid #e5e7ef;border-radius:10px;background:#fff;color:#303247;text-align:left;cursor:pointer}
.ofi-help-result-f4:hover{border-color:#d2d0f5;background:#f9f8ff}
.ofi-help-result-f4>span{color:#6b63d4;font-size:9px;font-weight:700;text-transform:uppercase;letter-spacing:.05em}
.ofi-help-result-f4 strong{font-size:12px}
.ofi-help-result-f4 small{color:#777a8c;font-size:10.5px;line-height:1.35}
.ofi-help-empty-f4{display:grid;gap:5px;margin-top:18px;padding:16px;border:1px dashed #d8dbe6;border-radius:12px;color:#66697b;text-align:center}
.ofi-help-empty-f4 strong{color:#3d4055;font-size:13px}
.ofi-help-empty-f4 span{font-size:11px;line-height:1.45}
.ofi-help-footer-f4{padding:9px 16px 12px;border-top:1px solid #ececf2;background:#fbfbfd;color:#85889a;font-size:9.5px;line-height:1.35}
@media(max-width:720px){
  .ofi-help-panel-f4{width:100%;border-left:0}
  .ofi-help-header-f4{padding:13px 12px 10px}
  .ofi-help-search-wrap-f4{margin:10px 12px 8px}
  .ofi-help-body-f4,.ofi-help-results-f4{padding:3px 12px 16px}
  .modal-help-button-f4{padding:0 8px}
  .modal-help-label-f4{display:none}
}
@media(max-width:460px){
  .ofi-help-index-button-f4{padding:0 8px}
  .ofi-help-header-f4 h2{font-size:18px}
}


/* F5/6 — compact shell + Trabajo entre equipos in topbar.
   Presentation only: existing Roaming/lease/Change Journal contracts remain authoritative. */
.roaming-topbar-wrap-f5{position:relative;flex:0 0 auto}
.roaming-topbar-chip-f5{
  min-height:38px;display:inline-flex;align-items:center;gap:7px;padding:0 10px;
  border:1px solid rgba(255,255,255,.25);border-radius:10px;color:#fff;background:rgba(255,255,255,.10);
  font:inherit;font-size:11px;font-weight:650;white-space:nowrap;box-shadow:none
}
.roaming-topbar-chip-f5:hover,.roaming-topbar-chip-f5.is-open{background:rgba(255,255,255,.18)}
.roaming-topbar-chip-f5:focus-visible{outline:2px solid rgba(255,255,255,.94);outline-offset:2px}
.roaming-dot-f5{width:8px;height:8px;flex:0 0 8px;border-radius:50%;background:#cbd5e1;box-shadow:0 0 0 3px rgba(255,255,255,.10)}
.roaming-topbar-chip-f5.success .roaming-dot-f5{background:#6ee7a7}.roaming-topbar-chip-f5.info .roaming-dot-f5{background:#7dd3fc}.roaming-topbar-chip-f5.warning .roaming-dot-f5{background:#fcd34d}.roaming-topbar-chip-f5.danger .roaming-dot-f5{background:#fda4af}
.roaming-topbar-chip-f5.needs-attention{background:rgba(255,255,255,.17)}
.roaming-chip-revision-f5{padding-left:7px;border-left:1px solid rgba(255,255,255,.22);color:rgba(255,255,255,.76);font-weight:560}
.roaming-chip-chevron-f5{font-size:13px;color:rgba(255,255,255,.72);transition:transform .15s ease}.roaming-topbar-chip-f5.is-open .roaming-chip-chevron-f5{transform:rotate(180deg)}
.roaming-topbar-panel-f5{position:absolute;z-index:95;top:calc(100% + 8px);right:0;width:min(390px,calc(100vw - 20px));padding:14px;border:1px solid #dde2ea;border-radius:14px;background:#fff;color:#273142;box-shadow:0 20px 55px rgba(23,31,53,.24)}
.roaming-topbar-panel-f5[hidden]{display:none!important}
.roaming-topbar-panel-f5 header{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding-bottom:9px;border-bottom:1px solid #edf0f4}
.roaming-topbar-panel-f5 header>div{display:grid;gap:2px}.roaming-topbar-panel-f5 header strong{font-size:14px}.roaming-topbar-panel-f5 .eyebrow{font-size:9px}
.roaming-panel-tone-f5{width:10px;height:10px;margin-top:4px;border-radius:50%;background:#94a3b8}.roaming-panel-tone-f5.success{background:#22a06b}.roaming-panel-tone-f5.info{background:#1689c9}.roaming-panel-tone-f5.warning{background:#d69e19}.roaming-panel-tone-f5.danger{background:#d14343}
.roaming-topbar-panel-f5>p{margin:10px 0;color:#667085;font-size:11.5px;line-height:1.45}
.roaming-panel-meta-f5{display:grid;grid-template-columns:1.2fr .65fr 1.15fr;gap:7px;margin:10px 0}
.roaming-panel-meta-f5>span{min-width:0;padding:8px 9px;border:1px solid #e7eaf0;border-radius:9px;background:#fafbfc}.roaming-panel-meta-f5 small,.roaming-panel-meta-f5 strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.roaming-panel-meta-f5 small{color:#8992a1;font-size:9px;text-transform:uppercase;letter-spacing:.04em}.roaming-panel-meta-f5 strong{margin-top:2px;font-size:10.5px;font-weight:650}
.roaming-panel-notice-f5,.roaming-panel-error-f5{margin-top:8px;padding:8px 10px;border-radius:9px;font-size:10.5px;line-height:1.35}.roaming-panel-notice-f5{border:1px solid #e8d59f;background:#fff8e7;color:#775600}.roaming-panel-error-f5{border:1px solid #e7bcbc;background:#fff1f1;color:#9e3030}
.roaming-panel-actions-f5{display:flex;justify-content:flex-end;gap:7px;flex-wrap:wrap;margin-top:11px;padding-top:10px;border-top:1px solid #edf0f4}.roaming-panel-actions-f5 .primary-button,.roaming-panel-actions-f5 .secondary-button{min-height:34px;padding:0 11px;border-radius:8px;font-size:10.5px}
.roaming-attention-f5{box-shadow:0 6px 20px rgba(30,41,59,.055)}
@media(max-width:1180px){.roaming-chip-label-f5{display:none}.roaming-topbar-chip-f5{padding-inline:9px}.roaming-chip-revision-f5{border-left:0;padding-left:0}}
@media(max-width:840px){.roaming-chip-revision-f5{display:none}.roaming-topbar-chip-f5{width:38px;justify-content:center;padding:0}.roaming-chip-chevron-f5{display:none}.roaming-dot-f5{width:9px;height:9px;flex-basis:9px}.roaming-topbar-panel-f5{position:fixed;top:62px;right:8px}}
@media(max-width:520px){.roaming-topbar-panel-f5{left:8px;right:8px;width:auto}.roaming-panel-meta-f5{grid-template-columns:1fr 1fr}.roaming-panel-meta-f5>span:last-child{grid-column:1/-1}.roaming-panel-actions-f5{display:grid;grid-template-columns:1fr}.roaming-panel-actions-f5 button{width:100%}}
@media print{.roaming-topbar-wrap-f5,.roaming-attention-f5{display:none!important}}

/* F6/6 RC4 — Physical test fixes & final UX polish */
/* Aging cards: the first five cards previously inherited white text without a colored background. */
.aging-grid .metric-card:not(.emphasis){
  color:#292b3f;
  border:1px solid #e4e6ef;
  background:#fff;
}
.aging-grid .metric-card:not(.emphasis)::after{background:rgba(79,70,217,.045)}
.aging-grid .metric-card:not(.emphasis) small{color:#777a8f}
.aging-grid .metric-card:not(.emphasis) strong{color:#22243b}
.aging-grid .metric-card.emphasis small{color:#777a8f}

/* Financial tables: fixed numeric columns keep headers and values on the same right edge. */
.statement-table-f3{width:100%;table-layout:fixed}
.statement-table-f3 th:first-child,.statement-table-f3 td:first-child{width:130px}
.statement-table-f3 th:nth-child(2),.statement-table-f3 td:nth-child(2){width:165px}
.statement-table-f3 th:nth-last-child(-n+3),.statement-table-f3 td:nth-last-child(-n+3){width:150px;text-align:right;font-variant-numeric:tabular-nums}
.statement-table-f3 th:nth-last-child(-n+3){padding-right:18px}
.statement-table-f3 td:nth-last-child(-n+3){padding-right:18px}
.project-balance-heading-f3 + .report-table-panel table th:nth-child(n+3){text-align:right}
.project-balance-heading-f3 + .report-table-panel table td:nth-child(n+3){text-align:right;font-variant-numeric:tabular-nums}
.project-balance-heading-f3 + .report-table-panel table th:nth-child(n+5),
.project-balance-heading-f3 + .report-table-panel table td:nth-child(n+5){min-width:145px}

/* Quick Add next to catalog-backed dropdowns. */
.catalog-select-row-f4{display:grid;grid-template-columns:minmax(0,1fr) 38px;gap:6px;align-items:center;width:100%}
.catalog-select-row-f4>.ofi-search-select-hf9,.catalog-select-row-f4>select{min-width:0;width:100%}
.catalog-quick-add-button-f4{width:38px;height:38px;display:grid;place-items:center;border:1px solid #d8dce8;border-radius:9px;background:#f8f8ff;color:#4f46d9;cursor:pointer;transition:.15s ease}
.catalog-quick-add-button-f4:hover{border-color:#b9b4f4;background:#efedff;color:#3f36c8}
.ofi-quick-add-backdrop-f4{position:fixed;inset:0;z-index:11050;display:grid;place-items:center;padding:18px;background:rgba(24,25,45,.34);backdrop-filter:blur(2px)}
.ofi-quick-add-card-f4{width:min(620px,calc(100vw - 28px));max-height:calc(100vh - 36px);overflow:auto;border:1px solid #e1e3ec;border-radius:16px;background:#fff;box-shadow:0 26px 80px rgba(25,27,55,.26)}
.ofi-quick-add-card-f4 header{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;padding:16px 18px 12px;border-bottom:1px solid #eceef4}
.ofi-quick-add-card-f4 header h3{margin:3px 0 0;font-size:21px}
.ofi-quick-add-body-f4{padding:16px 18px}
.ofi-quick-add-card-f4 footer{display:flex;justify-content:flex-end;gap:8px;padding:11px 18px;border-top:1px solid #eceef4;background:#fbfbfe}
.quick-add-help-f4{margin:12px 0 0;color:#777a8e;font-size:11px;line-height:1.45}
.quick-add-check-f4{align-self:end;min-height:38px}

/* Backups: user-first layout, technical diagnostics remain available on demand. */
.backup-user-center-f4{display:grid;gap:12px}
.backup-user-heading-f4{margin:0}
.backup-user-summary-f4{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}
.backup-user-summary-f4 article{min-width:0;padding:12px 13px;border:1px solid #e5e7ef;border-radius:11px;background:#fff;display:grid;gap:4px}
.backup-user-summary-f4 small{color:#777a8f;font-size:9px;font-weight:700;letter-spacing:.06em}
.backup-user-summary-f4 strong{font-size:14px;color:#292b3f}
.backup-user-summary-f4 span{color:#777a8f;font-size:10px;line-height:1.4}
.backup-user-explainer-f4{padding:11px 13px;border:1px solid #d9e9e2;border-radius:11px;background:#f4fbf8}
.backup-user-explainer-f4>div{display:flex;gap:10px;align-items:flex-start}
.backup-user-explainer-f4 strong{display:block;margin-bottom:3px;color:#245d49}
.backup-user-explainer-f4 p{margin:0;color:#527263;font-size:11px;line-height:1.5}
.backup-primary-actions-f4{margin-top:0}
.backup-technical-details-f4{border:1px solid #e5e7ef;border-radius:11px;background:#fbfcff;overflow:hidden}
.backup-technical-details-f4 summary{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:11px 13px;cursor:pointer;color:#4a4d64;list-style:none}
.backup-technical-details-f4 summary::-webkit-details-marker{display:none}
.backup-technical-details-f4 summary span{display:flex;align-items:center;gap:7px;font-weight:650}
.backup-technical-details-f4 summary small{color:#898c9e}
.backup-technical-body-f4{padding:0 13px 13px;border-top:1px solid #e8eaf1}
.backup-technical-body-f4 .volume-metrics-f24{margin-top:12px}
.backup-technical-action-f4{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-top:10px;padding:10px 11px;border-radius:9px;background:#fff}
.backup-technical-action-f4 p{margin:0;color:#777a8f;font-size:10px;line-height:1.45}
@media(max-width:980px){.backup-user-summary-f4{grid-template-columns:repeat(2,minmax(0,1fr))}.statement-table-f3{table-layout:auto}}
@media(max-width:720px){.backup-user-summary-f4{grid-template-columns:1fr}.catalog-select-row-f4{grid-template-columns:minmax(0,1fr) 40px}.ofi-quick-add-backdrop-f4{padding:0}.ofi-quick-add-card-f4{width:100%;max-height:100vh;border-radius:0}.backup-technical-action-f4{align-items:stretch;flex-direction:column}}

/* F6-P1 RC1 — Configuración, recuperación, Adjuntos e Historial orientados al usuario */
.recovery-checkpoint-meta-p1{display:flex;gap:7px 14px;flex-wrap:wrap;margin-top:7px;color:#6e7884;font-size:10.5px}
.recovery-checkpoint-meta-p1 span{display:inline-flex;gap:4px;align-items:center}
.recovery-checkpoint-feedback-p1{margin:9px 0 0!important;padding:9px 11px!important}
.recovery-checkpoint-feedback-p1 p{margin:2px 0 0!important}
.attachment-user-center-p1 .panel-heading{align-items:flex-start}
.attachment-user-explainer-p1,.archive-safety-note-p1{display:flex;align-items:flex-start;gap:12px;padding:13px 14px;border:1px solid #dde8ef;border-radius:12px;background:#f8fbfd}
.attachment-user-explainer-p1>div,.archive-safety-note-p1>div{display:grid;gap:3px;min-width:0}
.attachment-user-explainer-p1 strong,.archive-safety-note-p1 strong{color:#2c4051;font-size:12.5px}
.attachment-user-explainer-p1 p,.archive-safety-note-p1 p{margin:0;color:#6e7b86;font-size:11px;line-height:1.5}
.attachment-tech-copy-p1{margin:10px 0 0;color:#777a8f;font-size:10.5px;line-height:1.5}
.archive-user-center-p1{gap:14px}
.archive-overview-p1 .panel-heading,.archive-rollover-user-p1 .panel-heading,.archive-history-user-p1 .panel-heading{align-items:flex-start}
.archive-overview-p1 .panel-heading p,.archive-rollover-user-p1 .panel-heading p,.archive-history-user-p1 .panel-heading p{margin:4px 0 0;color:#6f7884;font-size:11.5px;line-height:1.5}
.archive-user-metrics-p1{grid-template-columns:repeat(4,minmax(0,1fr))}
.archive-user-metrics-p1 article{min-height:88px}
.archive-user-metrics-p1 small{text-transform:none;letter-spacing:0;font-weight:400}
.archive-technical-details-p1{margin-top:12px}
.archive-technical-grid-p1{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 16px;margin-top:11px;font-size:10.5px;color:#6e7784}
.archive-technical-details-p1 p{margin:10px 0 0;color:#777a8f;font-size:10.5px;line-height:1.45}
.archive-date-grid-p1{margin-top:13px}
.archive-carry-summary-p1{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin:12px 0}
.archive-carry-summary-p1 article{display:grid;gap:3px;padding:11px 12px;border:1px solid #e1e7ed;border-radius:11px;background:#fbfcfe}
.archive-carry-summary-p1 small{font-size:9.5px;letter-spacing:.06em;color:#7c8793;font-weight:650}
.archive-carry-summary-p1 strong{font-size:15px;color:#283b4a}
.archive-carry-summary-p1 span{font-size:10.5px;color:#74808b}
.archive-review-button-p1{margin-top:2px}
.archive-empty-p1{padding:28px 18px}
.archive-preview-p1{border-left:4px solid #4fa772}
@media(max-width:980px){.archive-user-metrics-p1{grid-template-columns:repeat(2,minmax(0,1fr))}.archive-carry-summary-p1{grid-template-columns:1fr}}
@media(max-width:720px){.archive-user-metrics-p1,.archive-technical-grid-p1{grid-template-columns:1fr}.attachment-user-explainer-p1,.archive-safety-note-p1{padding:11px}.recovery-checkpoint-meta-p1{display:grid;gap:4px}}

/* F6-P2 — adjuntos integrados en documentos */
.entity-attachments-p2{display:grid;gap:9px;margin-top:14px;padding-top:13px;border-top:1px solid #e6ebef}
.attachment-heading-p2{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;margin:0}
.attachment-heading-p2>div{display:grid;gap:2px;min-width:0}
.attachment-heading-p2 h3{margin:0;font-size:15px;color:#2f4050}
.attachment-heading-p2 small{font-size:10.5px;line-height:1.4;color:#74818c}
.attachment-count-p2{display:inline-grid;place-items:center;min-width:25px;height:25px;padding:0 7px;border-radius:999px;background:#eef2ff;color:#5146d8;font-size:10.5px;font-weight:700}
.attachment-file-list-p2{display:grid;gap:7px}
.attachment-file-row-p2{display:grid;grid-template-columns:minmax(0,1fr) 32px;align-items:center;gap:6px;padding:5px;border:1px solid #e0e7ed;border-radius:10px;background:#fbfcfd}
.attachment-file-open-p2{min-width:0;display:flex;align-items:center;gap:8px;border:0;background:transparent;padding:5px 7px;text-align:left;color:#35536b;font:inherit;cursor:pointer}
.attachment-file-open-p2:hover{background:#f0f6fa;border-radius:7px}
.attachment-file-open-p2>span{display:grid;gap:1px;min-width:0}
.attachment-file-open-p2 strong{font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.attachment-file-open-p2 small{font-size:9.5px;color:#7b8793}
.attachment-file-unlink-p2{width:30px;height:30px;display:grid;place-items:center;border:0;border-radius:7px;background:transparent;color:#7b8793;cursor:pointer}
.attachment-file-unlink-p2:hover{background:#fff0ee;color:#a74239}
.attachment-actions-p2{display:flex;align-items:center;gap:7px;flex-wrap:wrap}
.attachment-actions-p2>small{margin-left:auto;color:#7b8793;font-size:9.5px}
.attachment-actions-p2>small strong{color:#4c5b67}
.attachment-empty-p2{padding:12px!important;min-height:0!important}
.attachment-feedback-p2,.attachment-note-p2{margin:0!important}
@media(max-width:720px){.attachment-actions-p2>small{width:100%;margin-left:0}.attachment-file-row-p2{grid-template-columns:minmax(0,1fr) 36px}.attachment-heading-p2{align-items:flex-start}}

/* F6-P3 RC2 — recovery restore + attachment reconciliation polish */
.recovery-checkpoint-actions-p3rc2{grid-column:2;display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.recovery-checkpoint-actions-p3rc2>button{margin-top:3px}
.recovery-points-panel-p3rc2{display:grid;gap:12px}
.recovery-points-list-p3rc2{display:grid;gap:8px}
.recovery-points-list-p3rc2 article{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:11px 12px;border:1px solid #e2e8ee;border-radius:11px;background:#fbfcfe}
.recovery-points-list-p3rc2 article>div{display:grid;gap:3px;min-width:0}
.recovery-points-list-p3rc2 strong{font-size:12.5px;color:#2f4050}
.recovery-points-list-p3rc2 small{font-size:10.5px;color:#74818c}
@media(max-width:720px){.recovery-checkpoint-actions-p3rc2{grid-column:1 / -1;display:grid}.recovery-checkpoint-actions-p3rc2 button{width:100%;justify-content:center}.recovery-points-list-p3rc2 article{align-items:flex-start;flex-direction:column}.recovery-points-list-p3rc2 button{width:100%;justify-content:center}}

/* F3/5 — Saldos por viaje: resumen + detalle por pasajero */
.project-report-view-panel-f3{padding:12px 13px;margin-bottom:10px}
.project-report-view-heading-f3{display:flex;align-items:center;justify-content:space-between;gap:16px}
.project-report-view-heading-f3 h2{margin:2px 0 0;font-size:18px}
.project-report-view-panel-f3>p{margin:7px 0 0;color:#73768a;font-size:11px;line-height:1.45}
.project-report-view-toggle-f3{display:inline-flex;gap:4px;padding:4px;border:1px solid #e0e2ec;border-radius:11px;background:#f7f8fb}
.project-report-view-toggle-f3 button{min-height:34px;padding:0 12px;border:0;border-radius:8px;background:transparent;color:#65687b;font:inherit;font-size:11px;font-weight:650;cursor:pointer;white-space:nowrap}
.project-report-view-toggle-f3 button:hover{background:#fff;color:#4b43c8}
.project-report-view-toggle-f3 button.active{background:#fff;color:#4038b7;box-shadow:0 2px 8px rgba(45,43,94,.12)}
.project-passenger-toolbar-f3{display:grid;grid-template-columns:minmax(260px,1fr) auto auto;gap:12px;align-items:center;padding:10px 12px;margin-bottom:10px}
.project-passenger-search-f3{margin:0}
.project-zero-toggle-f3{display:inline-flex;align-items:center;gap:8px;min-height:36px;color:#55586d;font-size:11px;font-weight:600;white-space:nowrap;cursor:pointer}
.project-zero-toggle-f3 input{width:15px;height:15px;accent-color:#5044da}
.project-passenger-result-f3{display:flex;align-items:baseline;justify-content:flex-end;gap:5px;color:#777a8e;white-space:nowrap}
.project-passenger-result-f3 strong{color:#34364c;font-size:15px}
.project-passenger-result-f3 span{font-size:10.5px}
.project-passenger-heading-f3{padding:11px 13px;margin-bottom:9px}
.project-passenger-heading-f3 .panel-heading{margin:0}
.project-passenger-heading-f3 .panel-heading p{margin:3px 0 0;color:#74778b;font-size:11px;line-height:1.4}
.project-passenger-metrics-f3{margin-bottom:10px}
.project-passenger-group-f3 td{padding-top:10px!important;padding-bottom:8px!important;border-top:2px solid #dddfea;background:#f7f8fc!important}
.project-passenger-group-f3 td>div{display:inline-grid;gap:1px;margin-right:12px}
.project-passenger-group-f3 td>div strong{color:#2e3050;font-size:12.5px}
.project-passenger-group-f3 td>div small{color:#777a8d;font-size:9.5px}
.project-passenger-group-f3 td>span{color:#6f7285;font-size:10.5px;font-weight:600}
.project-passenger-row-f3 td{vertical-align:middle}
.project-passenger-row-f3 td:nth-child(n+3){text-align:right;font-variant-numeric:tabular-nums}
.project-passenger-row-f3 td:first-child strong{color:#56596c;font-size:11px}
.project-passenger-row-f3 td:first-child small,.project-passenger-row-f3 td:nth-child(2) small{display:block;margin-top:2px;color:#85889a;font-size:9.5px}
.project-passenger-subtotal-f3{background:#fbfbfe;border-top:1px solid #e7e8f0;border-bottom:1px solid #dfe1ea}
.project-passenger-subtotal-f3 td{font-variant-numeric:tabular-nums;text-align:right}
.project-passenger-subtotal-f3 td:first-child{text-align:left;color:#4d5067}
.project-passenger-grand-total-f3{border-top:2px solid #cfd2df!important;background:#f1f2f8!important}
.project-passenger-grand-total-f3 td:first-child{text-align:left}
.project-passenger-heading-f3 + .report-table-panel table th:nth-child(n+3){text-align:right}
.project-passenger-heading-f3 + .report-table-panel table th:nth-child(n+4),
.project-passenger-heading-f3 + .report-table-panel table td:nth-child(n+4){min-width:140px}

@media(max-width:760px){
 .project-report-view-heading-f3{align-items:stretch;flex-direction:column}
 .project-report-view-toggle-f3{display:grid;grid-template-columns:1fr 1fr;width:100%}
 .project-report-view-toggle-f3 button{white-space:normal;line-height:1.25;padding:7px 9px}
 .project-passenger-toolbar-f3{grid-template-columns:1fr;gap:8px}
 .project-passenger-result-f3{justify-content:flex-start}
 .project-zero-toggle-f3{white-space:normal}
}

/* OFI CxC 3.2.0 F3 — Correcciones simplificadas */
.correction-choice-grid-f3{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin:16px 0}
.correction-choice-card-f3{appearance:none;border:1px solid var(--border,#dfe3ee);background:var(--surface,#fff);border-radius:14px;padding:18px;text-align:left;display:flex;flex-direction:column;gap:6px;cursor:pointer;color:inherit;min-height:112px;transition:border-color .15s ease,box-shadow .15s ease,transform .15s ease}
.correction-choice-card-f3:hover,.correction-choice-card-f3:focus-visible{border-color:var(--primary,#5046e5);box-shadow:0 8px 24px rgba(45,55,110,.12);transform:translateY(-1px);outline:none}
.correction-choice-card-f3.emphasized{background:linear-gradient(180deg,rgba(79,70,229,.08),rgba(79,70,229,.025));border-color:rgba(79,70,229,.34)}
.correction-choice-card-f3 strong{font-size:1rem}.correction-choice-card-f3 span{font-size:.86rem;line-height:1.45;color:var(--muted,#667085)}
.danger-table-action{color:#b42318;border-color:rgba(180,35,24,.26)}
.danger-table-action:hover{background:rgba(180,35,24,.06);border-color:rgba(180,35,24,.45)}
.modal-section-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:14px;margin:18px 0 8px}.modal-section-heading h3{margin:0}.modal-section-heading small{color:var(--muted,#667085);text-align:right}
@media(max-width:720px){.correction-choice-grid-f3{grid-template-columns:1fr}.modal-section-heading{align-items:flex-start;flex-direction:column}.modal-section-heading small{text-align:left}}


/* OFI CxC 3.2.0 F4 — clean statement / correction history */
.statement-filter-panel-f4{display:grid;gap:12px}
.statement-history-toggle-f4{display:flex;align-items:flex-start;gap:10px;padding:11px 13px;border:1px solid #e3e4ed;border-radius:11px;background:#fafafe;color:#53566a;cursor:pointer}
.statement-history-toggle-f4 input{width:16px;height:16px;margin:2px 0 0;accent-color:#5044da;flex:0 0 16px}
.statement-history-toggle-f4 span{display:grid;gap:2px}
.statement-history-toggle-f4 strong{font-size:12px;color:#393c50}
.statement-history-toggle-f4 small{font-size:11px;line-height:1.35;color:#85889a;font-weight:450}
.statement-history-notice-f4{display:flex;align-items:center;gap:10px;margin:0 0 12px;padding:10px 13px;border:1px solid #e8dfc5;border-radius:10px;background:#fffaf0;color:#696044;font-size:11px}
.statement-history-notice-f4 strong{color:#5a5137;white-space:nowrap}
.statement-history-notice-f4 span{line-height:1.4}
@media(max-width:720px){.statement-history-notice-f4{align-items:flex-start;flex-direction:column;gap:3px}.statement-history-toggle-f4{padding:11px}}


/* OFI CxC 3.2.0 F5 — Centro de Auditoría */
.audit-topbar-f5{display:inline-flex;align-items:center;gap:7px;height:36px;padding:0 11px;border:1px solid #d9dcf0;border-radius:10px;background:#fff;color:#3730a3;font:inherit;font-size:12px;font-weight:650;cursor:pointer;white-space:nowrap}.audit-topbar-f5:hover{border-color:#a9a5ef;background:#f7f6ff}.audit-hero-f5 p{max-width:760px}.audit-summary-f5{grid-template-columns:repeat(3,minmax(0,1fr))}.audit-filter-panel-f5{padding:16px 18px}.audit-filter-grid-f5{display:grid;grid-template-columns:minmax(240px,1.7fr) repeat(4,minmax(145px,1fr));gap:11px;align-items:end}.audit-filter-grid-f5 label{display:grid;gap:6px;color:#667085;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.045em}.audit-filter-grid-f5 input,.audit-filter-grid-f5 select{width:100%;min-height:40px;padding:0 10px;border:1px solid #d8dce8;border-radius:10px;background:#fff;color:#1d2939;font:inherit;font-size:12px;text-transform:none;letter-spacing:0}.audit-search-wide-f5{grid-column:span 1}.audit-filter-actions-f5{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-top:12px;padding-top:12px;border-top:1px solid #eceef5;color:#7b7d90;font-size:11px}.audit-center-table-f5 td{vertical-align:top}.audit-center-table-f5 td small{display:block;margin-top:4px;color:#8a8c9e;font-size:10px}.audit-reason-cell-f5{max-width:240px;white-space:normal!important;line-height:1.45}.audit-action-pill-f5{display:inline-flex;padding:5px 8px;border-radius:999px;font-size:11px;font-weight:700;line-height:1.2;background:#f3f4f6;color:#475467}.audit-action-pill-f5.success{background:#eaf8f1;color:#137a57}.audit-action-pill-f5.warning{background:#fff5e6;color:#9a5b00}.audit-action-pill-f5.danger{background:#fff0f0;color:#b42318}.audit-detail-f5{padding:0 20px 20px}.audit-detail-summary-f5{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.audit-detail-summary-f5 p{display:grid;gap:4px;margin:0;padding:11px 12px;border:1px solid #e6e8f1;border-radius:11px;background:#fbfcff}.audit-detail-summary-f5 span{font-size:10px;font-weight:700;color:#7b7d90;text-transform:uppercase;letter-spacing:.04em}.audit-detail-summary-f5 strong{color:#252638;font-size:12px;word-break:break-word}.audit-detail-summary-f5 small{color:#8a8c9e;font-size:10px;word-break:break-all}.audit-reason-card-f5{grid-column:1/-1;background:#fffdf6!important;border-color:#eee4bd!important}.audit-detail-section-f5{margin-top:17px}.audit-diff-table-f5{border:1px solid #e4e6ef;border-radius:12px;overflow:hidden}.audit-diff-head-f5,.audit-diff-row-f5{display:grid;grid-template-columns:minmax(140px,.8fr) minmax(160px,1fr) minmax(160px,1fr)}.audit-diff-head-f5{background:#f6f7fb;color:#65677a;font-size:10px;font-weight:750;text-transform:uppercase;letter-spacing:.04em}.audit-diff-head-f5 span,.audit-diff-row-f5>*{padding:9px 11px;border-right:1px solid #eceef4}.audit-diff-head-f5 span:last-child,.audit-diff-row-f5>*:last-child{border-right:0}.audit-diff-row-f5{border-top:1px solid #eceef4;font-size:11px}.audit-diff-row-f5 strong{background:#fbfcff;color:#4a4c60}.audit-diff-row-f5 span{white-space:normal;word-break:break-word}.audit-subactions-f5{display:grid;gap:7px}.audit-subactions-f5 article{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:10px;padding:10px 12px;border:1px solid #e6e8f1;border-radius:10px;background:#fff}.audit-subaction-index-f5{display:grid;place-items:center;width:26px;height:26px;border-radius:8px;background:#efefff;color:#5146d8;font-size:11px;font-weight:750}.audit-subactions-f5 article div{display:grid;gap:2px}.audit-subactions-f5 small{color:#8a8c9e;font-size:10px}.audit-subactions-f5 b{color:#252638;font-size:12px}.audit-empty-detail-f5{padding:12px;border:1px dashed #d8dce8;border-radius:10px;color:#77798d;font-size:11px;background:#fafbfe}.audit-technical-f5{margin-top:16px;border:1px solid #e4e6ef;border-radius:11px;background:#fafbfe}.audit-technical-f5>summary{padding:11px 13px;cursor:pointer;color:#5a5c70;font-size:11px;font-weight:700}.audit-technical-f5 .detail-list{padding:0 12px 12px}.audit-technical-f5 .audit-json{margin:0 12px 12px}
@media(max-width:1180px){.audit-filter-grid-f5{grid-template-columns:repeat(3,minmax(150px,1fr))}.audit-search-wide-f5{grid-column:span 2}}
@media(max-width:760px){.audit-topbar-f5 span{display:none}.audit-topbar-f5{width:36px;padding:0;justify-content:center}.audit-summary-f5{grid-template-columns:1fr}.audit-filter-grid-f5{grid-template-columns:1fr 1fr}.audit-search-wide-f5{grid-column:1/-1}.audit-detail-summary-f5{grid-template-columns:1fr}.audit-reason-card-f5{grid-column:auto}.audit-diff-head-f5,.audit-diff-row-f5{grid-template-columns:1fr}.audit-diff-head-f5{display:none}.audit-diff-row-f5>*{border-right:0;border-top:1px solid #eceef4}.audit-diff-row-f5 strong{border-top:0}.audit-filter-actions-f5{align-items:flex-start;flex-direction:column}.audit-subactions-f5 article{grid-template-columns:auto 1fr}.audit-subactions-f5 b{grid-column:2}}


.audit-detail-button-f6{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:34px;
  padding:0 12px;
  border:1px solid #d9dcf0;
  border-radius:9px;
  background:#fff;
  color:#3730a3;
  font:inherit;
  font-size:11px;
  font-weight:700;
  cursor:pointer;
  transition:background .15s ease,border-color .15s ease,box-shadow .15s ease;
}
.audit-detail-button-f6:hover{
  background:#f7f6ff;
  border-color:#aaa5ef;
  box-shadow:0 3px 10px rgba(67,56,202,.08);
}


/* F6 RC11 — Rebalanceo visual del título de acceso/licencia */
@media (min-width:981px){
  .license-gate .workspace-brand-panel h1{
    max-width:610px;
    font-size:clamp(35px,3.25vw,46px);
    line-height:1.07;
    letter-spacing:-.036em;
  }
}
@media (min-width:621px) and (max-width:980px){
  .license-gate .workspace-brand-panel h1{
    max-width:600px;
    font-size:clamp(33px,5.3vw,43px);
    line-height:1.07;
    letter-spacing:-.035em;
  }
}
@media (max-width:620px){
  .license-gate .workspace-brand-panel h1{
    font-size:34px;
    line-height:1.08;
    letter-spacing:-.032em;
  }
}
