/* Shared palette; screen only. Official logos, reports and stock/account data are untouched. */
@media screen {
.ferro-theme-control{display:flex!important;align-items:center;justify-content:center;gap:8px;padding:6px 10px;border:1px solid #49617c;border-radius:12px;background:#142944;color:#eef4ff;flex:0 0 auto;align-self:center;max-width:100%;font:13px/1.4 system-ui;position:relative;z-index:2}
.ferro-theme-control label{display:flex;align-items:center;gap:5px;margin:0!important;font-size:12px!important;color:inherit!important;white-space:nowrap}
.ferro-theme-icon{font-size:20px;line-height:1;color:#a6c9f5}
body .ferro-theme-control select{width:auto!important;min-width:0!important;max-width:150px!important;min-height:34px!important;padding:5px 24px 5px 8px!important;margin:0!important;border-radius:8px!important;background:#0b1e35!important;color:#eef4ff!important;font:13px system-ui!important;box-shadow:none!important}
.ferro-theme-fallback{width:max-content;margin:12px 16px 12px auto}
body.ferro-premium [data-ferro-theme-host]{height:auto!important;min-height:68px;flex-wrap:wrap!important;gap:12px;padding-top:12px;padding-bottom:12px}
html[data-ferro-theme=light]{color-scheme:light;background:#f3f6fa}
html[data-ferro-theme=light] body.ferro-premium,html[data-ferro-theme=light] #ferro-premium-concept{
--fp-page:#f3f6fa!important;--fp-side:#fff!important;--fp-face:#fff!important;--fp-text:#14263d!important;--fp-muted:#516279!important;--fp-line:#d5dfeb!important;--fp-navy:#14263d!important;--fp-bright:#c81b3d!important;
--green:#185f50!important;--dark:#14263d!important;--gold:#bc2443!important;--cream:#f3f6fa!important;--ink:#14263d!important;--muted:#516279!important;--line:#d5dfeb!important;--white:#fff!important;--bg:#f3f6fa!important;--surface:#fff!important;--surface-soft:#edf3f9!important;--navy:#14263d!important;--blue:#285c96!important;--sidebar:#fff!important;--sidebar-2:#edf3f9!important;
--bs-body-bg:#f3f6fa!important;--bs-body-color:#14263d!important;--bs-secondary-color:#516279!important;--bs-tertiary-color:#516279!important;--bs-secondary-bg:#edf3f9!important;--bs-tertiary-bg:#edf3f9!important;--bs-border-color:#d5dfeb!important;--bs-link-color:#24578c!important;--bs-link-hover-color:#14263d!important;
color-scheme:light!important;background:#f3f6fa!important;color:#14263d!important;border-color:#d5dfeb!important}
html[data-ferro-theme=light] body.ferro-premium :is(h1,h2,h3,h4,h5,h6,label,.form-label,.text-dark,.text-body,.text-black){color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium :is(a,.link,.table-link,.panel-heading a){color:#24578c}
html[data-ferro-theme=light] body.ferro-premium :is(small,.muted,.text-muted,.text-secondary,.form-text,.metric-card small,.page-footer,.group-heading small,.card p,.panel p,.product p,.cart-item span,.fp-nav-label,.fp-side-bottom span,.fp-brand small,.fp-user small,.fp-hero-meta,.fp-summary small,.fp-card-index){color:#516279!important}
html[data-ferro-theme=light] body.ferro-premium :is(.eyebrow,.page-title>div>span,.fp-eyebrow){color:#b91c3c!important}
html[data-ferro-theme=light] body.ferro-premium :is(.sidebar,.rh-side,.fp-sidebar){background:#fff!important;color:#14263d!important;border-color:#d5dfeb!important;box-shadow:4px 0 16px #14263d08}
html[data-ferro-theme=light] body.ferro-premium>aside{background:#fff!important;color:#14263d!important;border-color:#d5dfeb!important}
html[data-ferro-theme=light] body.ferro-premium>aside>a{color:#405771!important}
html[data-ferro-theme=light] body.ferro-premium :is(.topbar,.navbar,.main>header,main>header,.fp-topbar,.app-header,.rh-topbar){background:#fff!important;color:#14263d!important;border-color:#d5dfeb!important;box-shadow:0 4px 16px #14263d05;flex-wrap:wrap}
html[data-ferro-theme=light] body.ferro-premium :is(.brand,.navbar-brand,.sidebar-brand,.fp-brand,.fp-brand strong,.fp-topbar>a,.fp-user strong){color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium :is(nav a,.sidebar a,.fp-nav a,.rh-side a){color:#405771!important}
html[data-ferro-theme=light] body.ferro-premium :is(nav a:hover,.sidebar a:hover,.fp-nav a:hover){background:#e9f0f8!important;color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium :is(.card,.panel,.enterprise-panel,.metric-card,.stats article,.summary,.activity,.catalog,.quote,.recent,.login-card,.portal-card,.item-card,.department-card,.payroll-group,.product,.recent-quote,.modal-content,.modal-card,dialog,.payment-method-card,.provider-card,.method-card,.setting-card,.quick-form,.fp-module){background:#fff!important;border-color:#d5dfeb!important;color:#14263d!important;box-shadow:0 5px 18px #14263d08,inset 0 1px #fff}
html[data-ferro-theme=light] body.ferro-premium :is(.hero,.hero-enterprise,.hero-card,.fp-hero){background:linear-gradient(120deg,#eaf2fc,#f8fbff)!important;color:#14263d!important;border-color:#cbdcf0!important;box-shadow:0 6px 18px #14263d08}
html[data-ferro-theme=light] body.ferro-premium :is(.hero p,.hero-enterprise p,.hero small,.fp-greeting,.fp-heading,.fp-heading span,.fp-intro){color:#405771!important}
html[data-ferro-theme=light] body.ferro-premium :is(.quick-action,.account-row,.numbers>div,.group-heading,.expense-total,.batch,.permission-box,.system-note,.conversion-preview,.conversion-preview span,.summary-box,.balance-box,.info-box,.totals,.rate,.bg-light,.bg-white,.bg-body-tertiary,.rate-grid>div,.totals-box,.form-section-title,.receipt-preview,.info,.description,.total,.price-picker-dialog,.price-picker-results,.picker-product,.fp-summary,.ferro-module-banner){background:#edf3f9!important;color:#14263d!important;border-color:#cbd9e9!important}
html[data-ferro-theme=light] body.ferro-premium :is(.rate strong,.rate b,.price strong,.totals strong,.recent-grid strong,.danger-card strong,.rate-grid span,.rate-grid strong,.receipt-preview strong,.receipt-preview span,.stat,.stat strong,.stat p){color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium :is(input:not([type=checkbox]):not([type=radio]):not([type=submit]):not([type=button]),select,textarea,.form-control,.form-select){background:#fff!important;color:#14263d!important;border-color:#9aafc8!important;box-shadow:inset 0 1px 3px #14263d08}
html[data-ferro-theme=light] body.ferro-premium :is(input,select,textarea)::placeholder{color:#667a92!important}
html[data-ferro-theme=light] body.ferro-premium :is(input,select,textarea):disabled{background:#e8edf4!important;color:#53667b!important}
html[data-ferro-theme=light] body.ferro-premium option{background:#fff!important;color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium :is(.btn-secondary,.btn-light,.btn-outline-secondary,.btn-outline-light,.secondary,.secondary-button,.button.ghost,.btn-outline-primary,.btn-outline-success,.btn-outline-warning,.qty button,.remove,.ferro-banner-actions a,.ferro-motion,.fp-motion-toggle,#ferro-enterprise-return){background:#edf3f9!important;color:#24578c!important;border-color:#a7bdd6!important;box-shadow:0 2px 0 #d1dce9!important}
html[data-ferro-theme=light] body.ferro-premium table{--bs-table-color:#14263d;--bs-table-bg:transparent;--bs-table-border-color:#d5dfeb;--bs-table-striped-bg:#f1f5fa;--bs-table-striped-color:#14263d;--bs-table-hover-bg:#e5edf7;--bs-table-hover-color:#14263d;color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium :is(th,thead td){background:#e9f0f8!important;color:#314d70!important;border-color:#cbd9e9!important}
html[data-ferro-theme=light] body.ferro-premium td{color:#14263d!important;border-color:#d5dfeb!important}
html[data-ferro-theme=light] body.ferro-premium tbody tr:nth-child(even){background-color:#f1f5fa!important}
html[data-ferro-theme=light] body.ferro-premium tbody tr:hover{background-color:#e5edf7!important}
html[data-ferro-theme=light] body.ferro-premium :is(.status,.badge,.tags span,.version-badge){background:#e7effa!important;color:#254f80!important;border-color:#abc2df!important}
html[data-ferro-theme=light] body.ferro-premium :is(.status.pagada,.status-pill,.bg-success,.badge-success,.alert-success,.flash.success,.flash.ok,.alert.success,.supplier.preferred,.status.recibido,.status-realizada){background:#e0f3e9!important;color:#15583d!important;border-color:#91c7ad!important}
html[data-ferro-theme=light] body.ferro-premium :is(.status.vencida,.status.anulada,.bg-danger,.badge-danger,.flash.error,.alert-danger,.alert.danger,.status.anulado,.status-anulada){background:#fde8ed!important;color:#9d1838!important;border-color:#e8a1b2!important}
html[data-ferro-theme=light] body.ferro-premium :is(.status.pendiente,.status.parcial,.warning-pill,.bg-warning,.alert-warning){background:#fff2d6!important;color:#775212!important;border-color:#ddc181!important}
html[data-ferro-theme=light] body.ferro-premium :is(.alert-info,.alert-primary,.notice,.flash:not(.error):not(.success):not(.ok),.dropdown-menu,.list-group-item,.accordion-item,.accordion-button,.popover){background:#e9f2fd!important;color:#245481!important;border-color:#aec9e8!important}
html[data-ferro-theme=light] body.ferro-premium .text-danger{color:#a71636!important}
html[data-ferro-theme=light] body.ferro-premium :is(.text-success,.text-primary){color:#215c75!important}
html[data-ferro-theme=light] body.ferro-premium :is(.login,.login-shell,.login form){background:#f3f6fa!important;color:#14263d!important;border-color:#cbd9e9!important}
html[data-ferro-theme=light] body.ferro-premium :is(.login-shell aside,.login-visual){background:#e6effa!important;color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium .login>section{background:linear-gradient(135deg,#e4eefb,#f3f6fa)!important;color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium .login section p{color:#405771!important}
html[data-ferro-theme=light] body.ferro-premium :is(.fp-module p,.fp-summary article span){color:#516279!important}
html[data-ferro-theme=light] body.ferro-premium .fp-summary article strong{color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium .fp-intro h1 span{color:#bf1e3d!important}
html[data-ferro-theme=light] body.ferro-premium :is(.ferro-module-identity small){color:#b91c3c!important}
html[data-ferro-theme=light] body.ferro-premium :is(.fp-open,.fp-module a,.fp-card-bottom){color:#b91c3c!important}
/* Preserve crimson primary actions and active navigation in either palette. */
html[data-ferro-theme=light] body.ferro-premium :is(.fp-home,nav a.active,.sidebar a.active,nav a[aria-current=page],a.primary,a.btn-primary,button.primary,.primary-button,.btn-primary){background:linear-gradient(105deg,#c21738,#ed2943)!important;color:#fff!important;border-color:#ed2943!important}
html[data-ferro-theme=light] .ferro-theme-control{background:#edf3f9!important;color:#14263d!important;border-color:#c7d6e8!important}
html[data-ferro-theme=light] .ferro-theme-icon{color:#9c6500}
html[data-ferro-theme=light] body .ferro-theme-control select{background:#fff!important;color:#14263d!important;border-color:#a7bdd6!important}
/* Complete nested dark-only components, not just their light outer container. */
html[data-ferro-theme=light] #ferro-premium-concept .fp-summary article{background:#fff!important;border-color:#b9cadf!important;color:#14263d!important;box-shadow:0 3px 12px #14263d06}
html[data-ferro-theme=light] #ferro-premium-concept .fp-summary article strong{color:#14263d!important}
html[data-ferro-theme=light] #ferro-premium-concept .fp-summary article span{color:#405771!important}
html[data-ferro-theme=light] #ferro-premium-concept .fp-module b{color:#a61936!important}
html[data-ferro-theme=light] #ferro-premium-concept .fp-card-bottom{border-color:#d5dfeb!important;color:#405771!important}
html[data-ferro-theme=light] #ferro-premium-concept .fp-side-bottom strong{color:#14263d!important}
html[data-ferro-theme=light] #ferro-premium-concept :is(.fp-nav-label,.fp-card-index,.fp-side-bottom span){color:#405771!important}
html[data-ferro-theme=light] body.ferro-premium :is(.fp-module p,.fp-hero-meta,.fp-user small,.ferro-release){color:#405771!important}
html[data-ferro-theme=light] #ferro-recovery{background:#edf5fb!important;color:#14263d!important;border-color:#93b1cd!important}
html[data-ferro-theme=light] #ferro-recovery :is(summary,p){color:#14263d!important}
html[data-ferro-theme=light] #ferro-recovery small{color:#405771!important}
html[data-ferro-theme=light] #ferro-recovery :is(button,a){background:#e2edf9!important;color:#234c77!important;border-color:#9fb8d2!important;box-shadow:none!important}
html[data-ferro-theme=light] #ferro-recovery .fr-delete{background:#a61936!important;color:#fff!important;border-color:#a61936!important}
html[data-ferro-theme=light] #ferro-recovery .fr-draft{border-color:#bdccdc!important}
html[data-ferro-theme=light] #ferro-recovery .fr-warning{color:#775212!important}
html[data-ferro-theme=light] body.ferro-premium :is(.fn-bar,.fn-pop,.fn-notice){background:#fff!important;color:#14263d!important;border-color:#b9cadf!important;box-shadow:0 4px 16px #14263d0b}
html[data-ferro-theme=light] body.ferro-premium :is(.fn-title,.fn-bell summary,.fn-preview,.fn-heading h1,.fn-notice h2){color:#14263d!important}
html[data-ferro-theme=light] body.ferro-premium :is(.fn-pop p,.fn-preview span,.fn-preview small,.fn-heading p,.fn-notice p,.fn-notice small,.fn-state){color:#405771!important}
html[data-ferro-theme=light] body.ferro-premium .fn-preview{border-color:#d5dfeb!important}
html[data-ferro-theme=light] body.ferro-premium :is(.fn-see-all,.fn-pages a){color:#a61936!important}
html[data-ferro-theme=light] body.ferro-premium .fn-warning{background:#fff2d6!important;color:#775212!important}
html[data-ferro-theme=light] body.ferro-premium .fn-actions .secondary{background:#e2edf9!important;color:#234c77!important}
html[data-ferro-theme=light] body.ferro-premium .fn-badge-empty{background:#e2edf9!important;color:#234c77!important}
html[data-ferro-theme=light] body.ferro-premium .fn-card-badge{border-color:#fff!important}
@media(max-width:760px){.ferro-theme-control{gap:6px;padding:4px 7px;margin-top:6px}.ferro-theme-label{display:none}.ferro-theme-control select{font-size:16px!important}.fp-topbar,.topbar,.navbar{flex-wrap:wrap!important}}
}
@media print{.ferro-theme-control{display:none!important}}
