[hidden] { display: none !important; }
button, input, select, textarea { font: inherit; }
button { border: 1px solid #ccc6c1; background: white; color: #323232; border-radius: 6px; padding: 7px 11px; cursor: pointer; }
button:hover { border-color: #a53607; color: #a53607; }
button:disabled { opacity: .58; cursor: default; }
:focus-visible { outline: 2px solid #a53607; outline-offset: 3px; }
.lume-sidebar :focus-visible { outline-color: #ffaf85; }
.erp-primary, button[type=submit] { background: #aa3607; border-color: #aa3607; color: white; font-weight: 650; }
.erp-primary:hover, button[type=submit]:hover { background: #882a04; color: white; }
.erp-brand { display: flex; align-items: center; gap: 10px; border: 0; padding: 3px; color: white; background: transparent; font-weight: 650; }
.erp-brand:hover { color: white; }
.erp-brand img { display: block; width: 66px; background: white; border-radius: 5px; padding: 5px; }
.erp-nav { display: grid; gap: 3px; padding: 14px 10px; }
.erp-topbar { gap: 12px; }
#toggle-nav { display: none; }
.erp-main { width: min(100%, 1520px); margin-inline: auto; padding: 24px clamp(14px, 2.6vw, 36px) 36px; }
.erp-page-header { display: flex; gap: 14px; justify-content: space-between; align-items: start; flex-wrap: wrap; padding-bottom: 14px; }
.erp-page-header h1 { font-size: clamp(23px, 2.5vw, 34px); line-height: 1.2; margin: 0 0 5px; }
.erp-page-header p, #login-status { margin: 0; color: #575151; }
.erp-toolbar { display: flex; flex-wrap: wrap; gap: 8px; }
.erp-tabs { display: flex; gap: 5px; flex-wrap: wrap; margin-bottom: 14px; }
.erp-tabs button { background: transparent; border-color: transparent; }
.erp-tabs button[aria-current] { background: #fce8de; color: #882a04; border-color: #dfac93; font-weight: 650; }
.erp-launcher { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(165px, 100%), 1fr)); gap: 12px; margin-bottom: 20px; }
.erp-app { background: white; border: 1px solid #ddd6d0; border-radius: 9px; text-align: left; padding: 14px; display: grid; gap: 9px; align-content: start; min-height: 104px; font-weight: 650; }
.erp-app small { font-weight: 400; color: #575151; }
.erp-app[aria-disabled=true] { border-style: dashed; cursor: default; }
.erp-app .lume-nav-icon { background: #fae4d9; color: #962f06; width: 33px; height: 33px; font-size: 19px; }
.erp-results { display: grid; gap: 12px; min-width: 0; }
.erp-results:empty { display: none; }
.stage-panel { background: white; min-width: 0; border: 1px solid #ddd6d0; border-radius: 9px; padding: clamp(12px, 2vw, 20px); }
.stage-panel h2, .stage-panel h3 { margin: 0 0 10px; }
.erp-operations { margin-top: 14px; }
.erp-operations > summary { font-weight: 650; }
.erp-operations[open] > summary { margin-bottom: 12px; }
.erp-form, .stage-operation-form { display: grid; gap: 12px; }
.erp-form label, .stage-operation-form label { display: grid; gap: 5px; min-width: 0; }
.erp-form input, .stage-panel input, .stage-panel select, .stage-panel textarea, dialog input, dialog select { width: 100%; min-width: 0; color: #323232; background: white; border: 1px solid #a8a09b; border-radius: 6px; padding: 8px; }
.stage-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(210px, 100%), 1fr)); gap: 12px; margin-top: 12px; }
.stage-fields fieldset { grid-column: 1 / -1; min-width: 0; }
.stage-picker { display: grid; gap: 5px; justify-items: start; }
.stage-picker select { width: 100%; }
.stage-line { border: 1px solid #ddd6d0; border-radius: 6px; padding: 10px; margin-block: 8px; }
.stage-warning { background: #fcf0e5; border-left: 3px solid #aa3607; padding: 10px; }
.stage-empty, #sync-status { color: #575151; }
.stage-table { overflow: auto; }
.stage-table table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.stage-table th, .stage-table td { padding: 9px; border-bottom: 1px solid #e8e3df; text-align: left; vertical-align: top; }
.stage-table th { white-space: nowrap; background: #f6f4f2; }
.stage-table td { overflow-wrap: anywhere; }
.stage-list-toolbar, .stage-row-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-block: 8px; }
.stage-list-toolbar input { flex: 1 1 175px; width: auto; }
.stage-list-toolbar select { width: auto; }
.stage-row-actions button { font-size: .8rem; padding: 5px 7px; }
.stage-metrics { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(min(135px, 100%), 1fr)); }
.stage-metric { display: grid; text-align: left; gap: 5px; border: 1px solid #e5ddd7; border-radius: 7px; background: #faf8f6; padding: 10px; }
.stage-metric strong { color: #8c310b; font-size: 1.3rem; }
.stage-panel pre { white-space: pre-wrap; overflow-wrap: anywhere; }
.stage-panel summary { cursor: pointer; }
.erp-backdrop { position: fixed; z-index: 35; inset: 0; background: #18100b80; border: 0; border-radius: 0; }
#profile-dialog { width: min(520px, calc(100% - 24px)); border: 1px solid #bdb4ad; border-radius: 10px; color: #323232; }
#profile-dialog::backdrop { background: #18100b80; }
.erp-dialog-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.erp-dialog-heading h2 { margin: 0; }
#mfa-panel { display: grid; gap: 7px; padding-bottom: 12px; overflow-wrap: anywhere; }
.lume-login-brand span { font-weight: 700; font-size: 1.2rem; }
#login-status { margin-top: 10px; }
@media (max-width: 960px) {
  #toggle-nav { display: inline-flex; }
  .erp-topbar { padding-inline: 12px; }
}
@media (max-width: 560px) {
  .lume-topbar-center { max-width: none; order: 3; flex-basis: 100%; }
  .erp-app { min-height: 80px; }
  .stage-table th, .stage-table td { padding: 7px; }
  .erp-page-header { gap: 7px; }
  #breadcrumb { display: none; }
}

/* Catálogo de andamios */
.lume-catalog-toolbar { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: end; margin-bottom: 12px; }
.lume-catalog-toolbar label { display: grid; gap: 4px; font-size: .85rem; color: #575151; min-width: 180px; flex: 1 1 200px; max-width: 360px; }
.lume-catalog-count { margin-left: auto; color: #575151; font-size: .9rem; }
.lume-catalog-note { color: #575151; font-size: .85rem; margin: 6px 0 12px; }
.lume-catalog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.lume-catalog-card { display: flex; flex-direction: column; gap: 6px; min-width: 0; background: #fff; border: 1px solid #ddd6d0; border-radius: 9px; padding: 12px; }
.lume-catalog-card[hidden] { display: none; }
.lume-catalog-card h3 { margin: 2px 0 0; font-size: 1rem; line-height: 1.25; overflow-wrap: anywhere; }
.lume-catalog-photo { position: relative; flex: 0 0 auto; width: 100%; min-width: 0; margin: 0; aspect-ratio: 4 / 3; display: grid; place-items: center; background: #f0f0f0; border-radius: 7px; overflow: hidden; }
.lume-catalog-photo img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; max-width: 100%; max-height: 100%; box-sizing: border-box; padding: 6px; object-fit: contain; object-position: center; background: #fff; }
.lume-catalog-photo figcaption { color: #575151; font-size: .8rem; padding: 8px; text-align: center; }
.lume-catalog-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.lume-catalog-code { font-family: ui-monospace, Consolas, monospace; font-weight: 700; color: #8c310b; }
.lume-catalog-badge { font-size: .72rem; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.lume-catalog-badge.is-active { background: #e3f3e6; color: #1d5b2c; }
.lume-catalog-badge.is-inactive { background: #f0ece8; color: #575151; }
.lume-catalog-meta { margin: 0; color: #575151; font-size: .82rem; }
.lume-catalog-rates { display: grid; grid-template-columns: auto 1fr; gap: 2px 10px; margin: 4px 0 0; font-size: .85rem; }
.lume-catalog-rates dt { color: #575151; }
.lume-catalog-rates dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.lume-catalog-specs { font-size: .82rem; margin-top: auto; }
.lume-catalog-specs p { white-space: pre-line; overflow-wrap: anywhere; margin: 6px 0 0; color: #323232; }
@media (max-width: 560px) { .lume-catalog-grid { grid-template-columns: 1fr; } .lume-catalog-count { margin-left: 0; } }
.lume-calendar-matrix-option { display: inline-flex; align-items: center; gap: 6px; }
.stage-panel .lume-calendar-matrix-option input { width: auto; }
.lume-daily-availability td[data-state="available"] { background: #e6f5ea; color: #15552b; }
.lume-daily-availability td[data-state="unknown"] { background: #fff2d7; color: #664200; }

.stage-equipment-line { margin-top: 0; }
.stage-equipment-line + p { margin: 6px 0; }
#operations-panel .stage-table caption { text-align: left; font-weight: 650; padding: 8px 0; }
