:root{--blue:#176b50;--navy:#184d40;--red:#397ea4;--pale:#eff8f3;--ink:#193e35}
body{background:#f3f8f5;color:#193e35}
.sidebar{background:#145940}.sidebar .nav.active{background:#327b62;border-color:#b7e3f5}.sidebar-note{color:#d1ece1}
.holding-wordmark{font-size:29px;font-weight:800;letter-spacing:-1px;display:block;padding:12px 0}.holding-wordmark span{font-weight:400}.sidebar .holding-wordmark{color:white;margin-bottom:32px}
.holding-toolbar{background:white;border:1px solid #d6e7df;border-radius:16px;padding:20px;margin:20px 0}
#company-tabs{display:flex;gap:10px;flex-wrap:wrap;margin-bottom:16px}#company-tabs button{padding:12px 18px;border:1px solid #cce2d6;border-radius:10px;background:#f0f8f3;color:#225642;font:inherit;font-weight:600;cursor:pointer}#company-tabs button[aria-pressed=true]{background:#176b50;color:white;border-color:#176b50}
.holding-toolbar label{display:flex;align-items:center;gap:12px}.holding-toolbar select{max-width:260px}.holding-toolbar #holding-summary{background:#e9f5fc;padding:16px;border-radius:10px;margin:16px 0;color:#285872;font-weight:600}
.holding-links{display:flex;flex-wrap:wrap;gap:12px 22px}.holding-links a{color:#176b50;font-size:13px}
.holding-fields{border:1px solid #d6e7df;border-radius:10px;padding:16px;margin:0 0 18px}.holding-fields legend{font-weight:700}.holding-fields input[type=checkbox]{width:auto;margin:0 8px 0 0}.holding-fields label:has(input){display:flex;align-items:center;margin:12px 0}
.metrics .available{background:#176b50}.primary,#confirm{background:#176b50!important}.brand-tag{display:block;color:#327659;background:#edf7f0;padding:6px 9px;border-radius:6px;align-self:start}
.demo-strip{background:#145940}.product-card button[data-add]{background:#176b50}.product-card button:disabled{opacity:.5}#advisor-filter-label[hidden]{display:none}
html,body{max-width:100%;overflow-x:clip}main,.holding-toolbar{min-width:0}
@media(max-width:650px){.holding-toolbar{padding:14px}#company-tabs{display:grid;grid-template-columns:1fr 1fr}#company-tabs button{padding:12px 8px;font-size:13px}.holding-wordmark{font-size:24px}.holding-links{gap:12px}.holding-toolbar label{flex-wrap:wrap}}

.catalog-empty{grid-column:1/-1;padding:30px;border:1px dashed #b9d9c8;border-radius:12px;background:#f4faf6;color:#466b59}.sidebar .nav.active{border-left-color:#b7e3f5}.holding-fields select{width:100%}
.holding-system-logo{display:block;width:190px;height:90px;object-fit:contain;filter:brightness(0) invert(1);margin:0 auto 24px}
.sidebar{overflow-y:auto}.sidebar #company-tabs{display:flex;flex-direction:column;gap:9px;margin:0 0 24px}.sidebar #company-tabs button{width:100%;height:66px;min-height:66px;padding:9px 16px;background:#fff;border:2px solid transparent;display:flex;align-items:center;justify-content:center;color:#175b44}.sidebar #company-tabs button:first-child{height:44px;min-height:44px;background:#ffffff15;color:white}.sidebar #company-tabs button img{display:block;width:100%;height:44px;object-fit:contain}.sidebar #company-tabs button[aria-pressed=true]{border-color:#a9e4c5;background:#e1f5e9;box-shadow:0 0 0 2px #a9e4c530}.sidebar #company-tabs button:first-child[aria-pressed=true]{background:#e1f5e9;color:#175b44}.sidebar .workspace-label{margin-bottom:14px}.sidebar-note{margin-top:24px}.store-company-logo{width:210px;height:90px;object-fit:contain}.login-system-logo{width:230px;height:110px;object-fit:contain}
@media(max-width:720px){.sidebar .holding-system-logo{width:150px;height:60px;margin-bottom:10px}.sidebar #company-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:100%;margin-bottom:12px}.sidebar #company-tabs button:first-child{grid-column:1/-1}.sidebar #company-tabs button{height:59px;min-height:59px}.sidebar #company-tabs button img{height:35px}.store-company-logo{width:160px;height:70px}}

/* Keep sidebar navigation scrollable without visible scrollbar tracks. */
.sidebar{overflow-x:hidden;overflow-y:auto;scrollbar-width:none;-ms-overflow-style:none}
.sidebar::-webkit-scrollbar{display:none;width:0;height:0}
.sidebar>*{min-width:0;max-width:100%;flex-shrink:0}
.sidebar .holding-system-logo{max-width:100%}
.sidebar #company-tabs button{min-width:0}
.sidebar #company-tabs button img{max-width:100%}

.overview-panel{margin:22px 0 28px}.overview-panel h2,.product-detail-heading{font-size:19px;margin:0 0 14px}.overview-panel .metrics{margin:0}.reservation-item li{margin:8px 0;line-height:1.5}

.general-reservations-list{display:grid;gap:12px;margin-top:16px;max-height:440px;overflow:auto}.general-reservations-list .reservation-item{background:white;border:1px solid #d4e5df;border-radius:12px;padding:16px}.product-metrics{grid-column:1;grid-row:2}.product-metrics article{padding:14px}.product-metrics strong{font-size:28px}.inventory-grid>.simulator{grid-column:2;grid-row:1}@media(max-width:800px){.inventory-grid>.simulator{grid-column:1;grid-row:3}.product-metrics{grid-column:1;grid-row:2}}

/* El producto ocupa toda la sección; sus métricas son bajas, no estrechas. */
.inventory-grid{grid-template-columns:minmax(0,1fr)}
.inventory-grid>.product{grid-column:1;grid-row:1}
.inventory-grid>.product-metrics{grid-column:1/-1;grid-row:2;margin:0;gap:16px}
.product-metrics article{padding:10px 18px;gap:2px}
.product-metrics strong{font-size:27px;line-height:1.1}
.product-metrics small{font-size:12px}
.product-metrics #open-reservations{padding:0;gap:2px;min-height:0}
.product-entry{border-top:1px solid #d4e5df;margin-top:20px;padding-top:16px}
.product-entry h2{font-size:18px;margin:0 0 12px}
.product-entry .input-row{display:flex;gap:10px;max-width:none}
.product-entry .input-row input{min-width:0;flex:1;width:100%}
.product-entry .input-row button{flex-shrink:0}
.entry-strategy-fields{display:grid;grid-template-columns:1fr 1fr;gap:10px}.entry-strategy-fields label{margin:0}.entry-strategy-fields input{width:100%;margin-top:7px}.entry-total{display:flex;justify-content:space-between;align-items:center;margin:10px 0;padding:9px 12px;background:#edf7f0;border-radius:8px;font-size:13px}.entry-total strong{font-size:21px}.product-entry form>button{width:100%}
@media(max-width:600px){.product-entry .input-row{flex-direction:column}.entry-strategy-fields{grid-template-columns:1fr}.product-metrics article{padding:10px 8px}.inventory-grid>.product-metrics{gap:7px}.product-metrics strong{font-size:24px}}
.strategy-allocation{margin-top:22px;padding:22px}.strategy-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:18px}.strategy-heading h2{margin-bottom:5px}.strategy-heading p{margin:0;max-width:650px;font-size:14px}.strategy-heading>strong{background:#edf7f0;color:#176b50;border-radius:999px;padding:9px 14px;white-space:nowrap}.strategy-cards{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:18px}.strategy-card{border:1px solid #cbded7;border-radius:12px;padding:18px;background:#f8fcfa}.strategy-card.digital{border-top:4px solid #2d83c5}.strategy-card.commercial{border-top:4px solid #176b50}.strategy-card label{font-size:18px;margin:0 0 3px}.strategy-card>small{display:block;color:#5b6a7b;min-height:38px}.strategy-card input{width:100%;margin:13px 0 10px;font-size:26px;font-weight:700}.strategy-card>div{display:flex;justify-content:space-between;gap:12px;font-size:13px;color:#536879}.strategy-card b{color:#183d35;font-size:16px}.strategy-footer{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-top:14px}.strategy-footer p{margin:0;color:#176b50}.strategy-footer p.error{color:#b61d30}.stock-row{grid-template-columns:48px minmax(210px,1fr) repeat(5,minmax(72px,auto))}.stock-row>span{white-space:nowrap}@media(max-width:1000px){.stock-row{grid-template-columns:48px 1fr repeat(3,auto)}.stock-row>span:nth-last-child(-n+2){display:none}}@media(max-width:720px){.strategy-heading,.strategy-footer{align-items:stretch;flex-direction:column}.strategy-heading>strong{align-self:flex-start}.strategy-cards{grid-template-columns:1fr}.strategy-footer button{width:100%}}
.strategy-summary{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:14px}.strategy-summary article{display:flex;flex-direction:column;gap:5px;background:#fff;border:1px solid #d4e5df;border-radius:12px;padding:16px 20px}.strategy-summary article.digital{border-left:5px solid #2d83c5}.strategy-summary article.commercial{border-left:5px solid #176b50}.strategy-summary span{font-size:14px;font-weight:600}.strategy-summary strong{font-size:32px;line-height:1.1}.strategy-summary small{color:#5b6a7b;font-size:12px}.strategy-unallocated{margin:8px 2px 0;color:#8a6415;font-size:12px}.inventory-grid>.product-strategies{grid-column:1/-1;grid-row:3;margin-top:0}.inventory-grid>#product-unallocated{grid-column:1/-1;grid-row:4}.overview-strategies{margin-top:14px}@media(max-width:600px){.strategy-summary{grid-template-columns:1fr}.strategy-summary article{padding:13px 15px}.strategy-summary strong{font-size:27px}}
.reserved-card.digital-reserved>button{box-shadow:inset 5px 0 #2d83c5}.reserved-card.commercial-reserved>button{box-shadow:inset 5px 0 #176b50}.overview-panel>.metrics{margin-bottom:0}.overview-strategies article,.product-strategies article{padding:12px 18px}.overview-strategies strong,.product-strategies strong{font-size:28px}.general-reservations-list:empty{display:none}
.product-metrics .digital-product{border-left:5px solid #2d83c5}.product-metrics .commercial-product{border-left:5px solid #176b50}.product-metrics .digital-product strong,.product-metrics .commercial-product strong{font-size:32px}
.strategy-channel-row{margin-bottom:14px}.strategy-channel-row h3{font-size:15px;margin:0 0 7px;color:#31564b}.strategy-channel-row .metrics{margin:0;gap:12px}.strategy-channel-row .metrics article{padding:13px 18px}.strategy-channel-row .metrics strong{font-size:31px}.strategy-channel-row .reserved-card>button{padding:13px 18px}.strategy-channel-row .digital-available{background:#276f9f;border-color:#276f9f}.strategy-channel-row .commercial-available{background:#176b50;border-color:#176b50}@media(max-width:720px){.strategy-channel-row .metrics{grid-template-columns:repeat(3,1fr)}.strategy-channel-row .metrics article,.strategy-channel-row .reserved-card>button{padding:11px 8px}.strategy-channel-row .metrics strong{font-size:26px}}

.product-search{margin:0 0 20px;padding:18px;background:#fff;border:1px solid #d4e5df;border-radius:12px}
.product-search label{display:block;font-weight:600;margin-bottom:10px}.product-search-row{display:flex;gap:10px}.product-search-row input{flex:1;min-width:0;width:100%}.product-search>small{display:block;margin-top:8px;color:#61776e}.product-search p:empty{display:none}
#product-search-results{max-height:300px;overflow:auto;display:grid;gap:6px}.product-search-result{display:flex;align-items:center;justify-content:space-between;gap:14px;text-align:left;background:#eff7f3;color:#184d3e;width:100%}.product-search-result small{display:block;margin-top:5px;font-size:11px;font-weight:400}.product-search-result:hover{background:#deeee6}.search-presentation{display:block;margin-top:4px;color:#173f35;font-size:14px;font-weight:700}.search-open{flex-shrink:0;color:#176b50;font-size:10px;font-weight:650}
@media(max-width:480px){.product-search{padding:12px}.product-search-result{flex-direction:column;gap:5px}}

.product-create-action{display:flex;justify-content:flex-start;margin:4px 0 16px}
.catalog-toolbar{display:flex;align-items:end;justify-content:space-between;gap:18px;margin:-4px 0 12px;padding:14px 16px;border:1px solid #d4e5df;border-radius:11px;background:#fff}.catalog-toolbar label{margin:0;min-width:260px;font-weight:700}.catalog-toolbar select{width:100%;margin-top:6px}.catalog-toolbar p{margin:0;color:#557068;font-size:13px;font-weight:600}

/* Product detail and catalog navigation */
.inventory-grid>.product{align-items:flex-start;padding:22px;gap:24px}
.inventory-grid>.product .product-image{align-self:flex-start;aspect-ratio:1;background:#fff;border:1px solid #e1ebe6;display:grid;place-items:center}
.inventory-grid>.product .product-image>img{width:100%;height:100%;max-height:none;object-fit:contain}
.inventory-grid>.product .product-details{min-width:0;padding:2px 0 0}
.stock-row{transition:background .16s,border-color .16s,box-shadow .16s;outline:none}
.stock-row:hover{background:#f3faf6;border-color:#a9cfc0}
.stock-row.selected{background:#eaf7f0;box-shadow:inset 4px 0 #176b50}
.stock-view{display:flex;align-items:flex-start;gap:14px;flex:1;min-width:220px;padding:3px;background:transparent;color:inherit;text-align:left}
.stock-view:hover strong{color:#176b50}.stock-view:focus-visible{outline:3px solid #d89914;outline-offset:2px}
.stock-view>span{min-width:0}.stock-view strong{display:-webkit-box;line-height:1.25;overflow:hidden;overflow-wrap:anywhere;-webkit-box-orient:vertical;-webkit-line-clamp:2}.stock-view small{display:block;line-height:1.4;overflow-wrap:anywhere}.stock-view em{display:block;color:#176b50;font-size:11px;font-style:normal;font-weight:600;margin-top:7px}
.stock-presentation{display:block;margin:4px 0;color:#183f35;font-size:14px;font-weight:750}.stock-prices{display:grid;gap:5px;min-width:128px;padding-left:10px;border-left:1px solid #d7e5df}.stock-prices span{display:flex;justify-content:space-between;gap:8px;color:#597069;font-size:10px}.stock-prices b{color:#183f35;font-size:12px}
.stock-edit{min-height:28px;padding:3px 10px;border:1px solid #a9c9bc;border-radius:7px;background:#fff;color:#155b46;font-size:11px}
.stock-edit:hover{background:#176b50;color:#fff}
.stock-row{display:grid;grid-template-columns:minmax(310px,1.7fr) repeat(5,minmax(62px,.45fr)) minmax(128px,.7fr) auto;gap:10px;align-items:center;padding:13px 14px}
.stock-row .stock-view{min-width:0;width:100%;border:0}
.stock-row>span{display:grid;gap:2px;justify-items:center;font-size:11px;color:#5a6f67}
.stock-row>span b{display:block;font-size:18px;color:#193e35}
@media(max-width:1350px){.stock-row{grid-template-columns:minmax(270px,1fr) repeat(3,minmax(62px,auto)) minmax(128px,auto) auto}.stock-row>span:nth-of-type(4),.stock-row>span:nth-of-type(5){display:none}}
@media(max-width:1100px){.stock-row{grid-template-columns:minmax(240px,1fr) repeat(3,minmax(48px,54px)) minmax(108px,118px) 48px;gap:6px}.stock-view{min-width:0}.stock-prices{min-width:0;padding-left:6px}.stock-edit{min-width:0;padding:3px 5px}.stock-row>span{font-size:10px}.stock-row>span b{font-size:16px}}
@media(max-width:900px){.inventory-grid>.product{gap:16px}.inventory-grid>.product .product-image{width:35%;max-width:260px}}
@media(max-width:720px){.inventory-grid>.product{padding:16px}.inventory-grid>.product .product-image{width:100%;max-width:240px;margin:0 auto 18px}.catalog-toolbar{align-items:stretch;flex-direction:column}.catalog-toolbar label{min-width:0}.stock-row{grid-template-columns:repeat(3,1fr);gap:9px}.stock-view{grid-column:1/-1}.stock-prices{grid-column:1/-1;display:flex;justify-content:space-between;padding:8px 0 0;border-left:0;border-top:1px solid #dbe8e2}.stock-prices span{gap:6px}.stock-edit{grid-column:1/-1;width:100%;min-height:34px}.stock-row>span{padding-top:6px;border-top:1px solid #dbe8e2}}

/* Menú compacto de teléfono: al seleccionar una sección quedan los accesos siempre disponibles. */
#sidebar-expand{display:none}
@media(max-width:720px){
 body.holding-app.sidebar-compact{display:block;padding-left:64px}
 body.holding-app.sidebar-compact .sidebar{position:fixed;z-index:30;inset:0 auto 0 0;width:64px;height:100dvh;min-height:100dvh;padding:9px 7px;overflow-y:auto;box-shadow:2px 0 14px #0d352826}
 body.holding-app.sidebar-compact main{width:100%;padding:20px 14px}
 body.holding-app.sidebar-compact .holding-system-logo,body.holding-app.sidebar-compact .workspace-label,body.holding-app.sidebar-compact #company-tabs,body.holding-app.sidebar-compact .sidebar-note,body.holding-app.sidebar-compact .nav-group-title{display:none}
 body.holding-app.sidebar-compact #sidebar-expand{display:grid;place-items:center;width:48px;height:44px;min-height:44px;margin:0 auto 9px;padding:0;border:1px solid #ffffff55;border-radius:10px;background:#ffffff18;color:#fff;font-size:22px}
 body.holding-app.sidebar-compact .sidebar nav{display:flex;flex-direction:column;gap:7px;flex-wrap:nowrap}
 body.holding-app.sidebar-compact .sidebar .nav{position:relative;display:grid;place-items:center;flex:none;width:48px;min-width:48px;height:48px;min-height:48px;margin:0;padding:0;font-size:0;border-radius:10px}
 body.holding-app.sidebar-compact .sidebar .nav::before{font-size:21px;line-height:1}
 body.holding-app.sidebar-compact .sidebar .nav[data-view="inventory"]::before{content:"▦"} body.holding-app.sidebar-compact .sidebar .nav[data-view="traditional"]::before{content:"⌁"} body.holding-app.sidebar-compact .sidebar .nav[data-view="reseller"]::before{content:"♜"} body.holding-app.sidebar-compact .sidebar .nav[data-view="reports"]::before{content:"▤"} body.holding-app.sidebar-compact .sidebar .nav[data-view="clients"]::before{content:"♟"} body.holding-app.sidebar-compact .sidebar .nav[data-view="cartera"]::before{content:"$";font-weight:800} body.holding-app.sidebar-compact .sidebar .nav[data-view="zones"]::before{content:"⌖"} body.holding-app.sidebar-compact .sidebar .nav[data-view="users"]::before{content:"⚙"}
 body.holding-app.sidebar-compact .sidebar .nav span{display:none} body.holding-app.sidebar-compact .sidebar .nav.active{box-shadow:inset 3px 0 #ef4f54,0 4px 10px #0a392a40}
}

/* Ventana de usuarios estable en Safari, iPad y teléfono. */
#user-dialog.dialog-fallback{display:block;position:fixed;z-index:1100;inset:10px;margin:auto;width:min(560px,calc(100vw - 20px));max-width:calc(100vw - 20px);max-height:calc(100dvh - 20px);overflow:auto;border:0;border-radius:16px;background:#fff;box-shadow:0 18px 55px #102e2888}
@media(max-width:620px){#user-dialog[open]{width:calc(100vw - 20px);max-width:calc(100vw - 20px);max-height:calc(100dvh - 20px);padding:0;overflow:auto}#user-dialog .crm-heading{padding:16px;position:sticky;top:0;background:#fff;z-index:1}#user-dialog form{padding:16px}#user-dialog form input,#user-dialog form select{font-size:16px}}

/* En móvil el menú abierto conserva el panel lateral; no se convierte en una franja superior. */
@media(max-width:720px){
 body.holding-app:not(.sidebar-compact){display:block;padding-left:222px}
 body.holding-app:not(.sidebar-compact) .sidebar{position:fixed;z-index:30;inset:0 auto 0 0;width:222px;height:100dvh;min-height:100dvh;padding:20px 16px;overflow-y:auto;box-shadow:2px 0 16px #0d35282b}
 body.holding-app:not(.sidebar-compact) main{width:100%;padding:22px 18px}
 body.holding-app:not(.sidebar-compact) .sidebar .holding-system-logo{width:170px;height:70px;margin:0 auto 12px;display:block}
 body.holding-app:not(.sidebar-compact) .sidebar .workspace-label{display:block}
 body.holding-app:not(.sidebar-compact) .sidebar #company-tabs{display:flex;flex-direction:column;gap:9px;width:100%;margin-bottom:20px}
 body.holding-app:not(.sidebar-compact) .sidebar #company-tabs button,body.holding-app:not(.sidebar-compact) .sidebar #company-tabs button:first-child{display:flex;grid-column:auto;width:100%;height:58px;min-height:58px}
 body.holding-app:not(.sidebar-compact) .sidebar #company-tabs button:first-child{height:46px;min-height:46px}
 body.holding-app:not(.sidebar-compact) .sidebar #company-tabs button img{height:36px}
 body.holding-app:not(.sidebar-compact) .sidebar nav{display:block}
 body.holding-app:not(.sidebar-compact) .sidebar .nav{display:flex;width:100%;min-width:0;margin:7px 0;padding:12px 10px;font-size:13px;justify-content:flex-start;min-height:44px}
 body.holding-app:not(.sidebar-compact) .sidebar .nav-group-title{display:block}
 body.holding-app:not(.sidebar-compact) .sidebar-note{display:block}
}

/* Catálogo compacto en teléfono: tocar una referencia abre su edición. */
@media(max-width:720px){
 .stock-row{grid-template-columns:1fr;gap:8px;padding:14px 12px}
 .stock-row .stock-view{grid-column:1/-1;min-height:0;padding:3px 0;background:transparent}
 .stock-row>span,.stock-row .stock-edit{display:none!important}
 .stock-row .stock-prices{grid-column:1/-1;display:flex;justify-content:space-between;gap:12px;margin:0;padding:8px 0 0;border-top:1px solid #dbe8e2;border-left:0}
 .stock-row .stock-prices span{flex:1;font-size:11px}.stock-row .stock-prices b{font-size:14px}
}

/* Operación completa desde la ficha del producto. */
.editor-inventory-actions{margin:0 22px 22px;padding:18px;border:1px solid #cfe0d8;border-radius:12px;background:#f7fbf8}.editor-inventory-actions h3{margin:0 0 14px;color:#194637}.editor-stock-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin-bottom:15px}.editor-stock-summary>div{padding:10px;border:1px solid #d8e6df;border-radius:9px;background:white;text-align:center}.editor-stock-summary span{display:block;font-size:11px;color:#61796e}.editor-stock-summary strong{display:block;margin-top:4px;font-size:20px;color:#194637}.editor-entry-fields{display:grid;grid-template-columns:1fr 1fr;gap:12px}.editor-entry-fields label{display:grid;gap:6px;font-size:12px;font-weight:700;color:#315b4b}.editor-entry-fields input{width:100%;margin:0}.editor-inventory-actions>#editor-receive{width:100%;margin-top:12px}.editor-product-actions{display:flex;gap:10px;margin-top:12px}.editor-product-actions button{flex:1}.editor-inventory-actions .note{margin:10px 0 0;font-size:12px}@media(max-width:620px){.editor-inventory-actions{margin:0 16px 16px;padding:14px}.editor-stock-summary{gap:6px}.editor-stock-summary>div{padding:8px 5px}.editor-stock-summary strong{font-size:17px}.editor-entry-fields{grid-template-columns:1fr}.editor-product-actions{flex-direction:column}.editor-product-actions button{width:100%}}
