/* LUCIO SIDEBAR DEVICE POLICY V30 · 2026-09-29
   Regla final: escritorio contraible; tablet/movil off-canvas. */
@media (min-width:1101px){
  html body.lucio-home-view .portal-shell,html body:not(.lucio-home-view) .portal-shell{display:grid!important;grid-template-columns:104px minmax(0,1fr)!important}
  html.lucio-sidebar-expanded body.lucio-home-view .portal-shell,html.lucio-sidebar-expanded body:not(.lucio-home-view) .portal-shell{grid-template-columns:284px minmax(0,1fr)!important}
  html body.lucio-home-view .portal-sidebar,html body:not(.lucio-home-view) .portal-sidebar{display:flex!important;flex-direction:column!important;position:sticky!important;left:auto!important;top:0!important;bottom:auto!important;width:104px!important;min-width:104px!important;max-width:104px!important;height:100vh!important;transform:none!important;padding:14px 12px!important;overflow:hidden!important}
  html.lucio-sidebar-expanded body.lucio-home-view .portal-sidebar,html.lucio-sidebar-expanded body:not(.lucio-home-view) .portal-sidebar{width:284px!important;min-width:284px!important;max-width:284px!important}
  html body .lucio-sidebar-toggle{display:grid!important}
  html body .lucio-mobile-menu{display:none!important}
  html body .lucio-brand-copy,html body .lucio-nav-label,html body .lucio-nav-chevron{display:none!important}
  html.lucio-sidebar-expanded body .lucio-brand-copy,html.lucio-sidebar-expanded body .lucio-nav-label,html.lucio-sidebar-expanded body .lucio-nav-chevron{display:inline!important}
  html body .portal-brand{justify-content:center!important}
  html.lucio-sidebar-expanded body .portal-brand{justify-content:flex-start!important}
  html body .lucio-sidebar-head{min-height:112px!important;flex-direction:column!important;justify-content:center!important;padding:2px 0 10px!important}
  html.lucio-sidebar-expanded body .lucio-sidebar-head{min-height:82px!important;flex-direction:row!important;justify-content:space-between!important;padding:0 2px 10px!important}
  html body .lucio-nav>a,html body .lucio-nav-group>summary{justify-content:center!important;font-size:0!important}
  html.lucio-sidebar-expanded body .lucio-nav>a,html.lucio-sidebar-expanded body .lucio-nav-group>summary{justify-content:flex-start!important;font-size:12px!important}
  html body .lucio-nav-children{display:none!important}
  html.lucio-sidebar-expanded body .lucio-nav-group[open]>.lucio-nav-children{display:grid!important;gap:3px!important;margin:2px 0 5px 36px!important}
}
@media (max-width:1100px){
  html body.lucio-home-view .portal-shell,html body:not(.lucio-home-view) .portal-shell{display:block!important;grid-template-columns:none!important}
  html body.lucio-home-view .portal-sidebar,html body:not(.lucio-home-view) .portal-sidebar{display:flex!important;flex-direction:column!important;position:fixed!important;left:0!important;top:0!important;bottom:0!important;width:min(88vw,320px)!important;min-width:0!important;max-width:320px!important;height:100dvh!important;z-index:1000!important;padding:16px!important;background:#fff!important;border-right:1px solid #d8e8f8!important;box-shadow:14px 0 36px rgba(7,29,77,.18)!important;transform:translateX(-105%)!important;transition:transform .22s ease!important;overflow:hidden!important}
  html body.menu-open.lucio-home-view .portal-sidebar,html body.menu-open:not(.lucio-home-view) .portal-sidebar{transform:none!important}
  html body .lucio-sidebar-toggle{display:grid!important;position:absolute!important;right:14px!important;top:18px!important}
  html body .lucio-mobile-menu{display:grid!important;place-items:center!important;width:44px!important;height:44px!important}
  html body .lucio-brand-copy,html body .lucio-nav-label,html body .lucio-nav-chevron{display:inline!important}
  html body .portal-brand{justify-content:flex-start!important}
  html body .lucio-sidebar-head{min-height:76px!important;flex-direction:row!important;justify-content:flex-start!important}
  html body .lucio-nav>a,html body .lucio-nav-group>summary{justify-content:flex-start!important;font-size:12px!important}
  html body .lucio-nav-group[open]>.lucio-nav-children{display:grid!important}
  html body .portal-main,html body .portal-top,html body .portal-content{margin-left:0!important;width:100%!important}
  html body.menu-open #yum-chat-launch{display:none!important}
}

/* V31.1 visual cleanup: remove legacy orange/pseudo artifacts */
@media(min-width:1101px){
html.lucio-sidebar-expanded body .lucio-sidebar-head{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:space-between!important;gap:10px!important}
html.lucio-sidebar-expanded body .portal-brand{display:flex!important;align-items:center!important;justify-content:flex-start!important;gap:10px!important;min-width:0!important;max-width:220px!important;overflow:hidden!important}
html.lucio-sidebar-expanded body .brand-car-mark,html.lucio-sidebar-expanded body .brand-car-mark svg{width:52px!important;height:42px!important;min-width:52px!important}
html.lucio-sidebar-expanded body .lucio-brand-copy{display:block!important;max-width:128px!important;overflow:hidden!important}
html.lucio-sidebar-expanded body .lucio-brand-copy strong{font-size:19px!important;line-height:.9!important;letter-spacing:-.03em!important;white-space:nowrap!important}
html.lucio-sidebar-expanded body .lucio-brand-copy small{display:block!important;margin-top:5px!important;font-size:7px!important;letter-spacing:.16em!important;white-space:nowrap!important}
html body .lucio-sidebar-toggle{display:grid!important;place-items:center!important;width:34px!important;height:34px!important;min-width:34px!important;padding:0!important;border:1px solid #cfe0f2!important;border-radius:10px!important;background:#f5f9ff!important;color:#0b63d8!important;box-shadow:none!important}
html body .lucio-sidebar-toggle:hover{background:#eaf4ff!important;color:#084ea9!important;border-color:#b8d7f6!important}
html body .lucio-nav>a,html body .lucio-nav-group>summary{border-left:1px solid transparent!important}
html body .lucio-nav>a.active,html body .lucio-nav-group[open]>summary{border-left:1px solid #d8e8f8!important;box-shadow:inset 4px 0 0 #0b63d8!important}
}

@media(min-width:1101px){
html body .lucio-nav>a.active{border-left:0!important;box-shadow:inset 4px 0 0 #0b63d8!important}
html body .lucio-nav>a{border-left:0!important}
}

@media(min-width:1101px){
html body .portal-sidebar>.portal-foot{position:absolute!important;left:18px!important;right:18px!important;bottom:14px!important;margin:0!important;padding:0!important;border:0!important;z-index:10!important}
html body .portal-sidebar>.portal-foot .portal-logout{width:100%!important;height:48px!important;min-height:48px!important;padding:0 14px!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;border:1px solid #cfe0f2!important;border-radius:10px!important;background:#fff!important;color:#0b326d!important;font-size:12px!important;font-weight:800!important;box-shadow:none!important}
}

@media(min-width:1101px){
html body .portal-sidebar>.portal-foot,
html body:not(.lucio-home-view) .portal-sidebar>.portal-foot,
html body.lucio-home-view .portal-sidebar>.portal-foot{
  position:absolute!important;
  left:12px!important;right:12px!important;bottom:14px!important;
  margin:0!important;padding:0!important;border:0!important;z-index:20!important
}
}

/* V31.2 responsive QA corrections */
@media(max-width:1100px){
html body:not(.lucio-home-view) .portal-top,html body.lucio-home-view .portal-top{
  display:grid!important;
  grid-template-columns:44px minmax(0,1fr) auto!important;
  grid-template-rows:auto auto auto!important;
  gap:10px 12px!important;
  height:auto!important;
  min-height:0!important;
  padding:14px 18px 16px!important;
  align-items:center!important;
}
html body .lucio-mobile-menu{grid-column:1!important;grid-row:1!important;margin:0!important;align-self:center!important}
html body .ls-global-search{grid-column:2!important;grid-row:1!important;position:relative!important;width:100%!important;max-width:none!important;margin:0!important}
html body .ls-global-search input{width:100%!important;height:44px!important}
html body .ls-top-actions{grid-column:3!important;grid-row:1!important;position:static!important;width:auto!important;margin:0!important;align-self:center!important}
html body .ls-personal-greeting{grid-column:1/4!important;grid-row:2!important;position:static!important;margin:0!important;padding:0 4px!important;align-self:center!important}
html body .global-live-card{
  grid-column:1/4!important;grid-row:3!important;position:relative!important;left:auto!important;right:auto!important;top:auto!important;bottom:auto!important;
  width:100%!important;height:auto!important;min-height:106px!important;margin:0!important;padding:10px 14px!important;
  display:grid!important;grid-template-columns:1.45fr .85fr 1.2fr .85fr!important;gap:0!important;align-items:center!important;overflow:hidden!important
}
html body .live-date-block,html body .live-clock-block,html body .global-live-place,html body .global-live-weather{
  min-width:0!important;height:auto!important;min-height:62px!important;padding:8px 14px!important;margin:0!important;display:flex!important;align-items:center!important;gap:10px!important;border-right:1px solid #cfe0f0!important
}
html body .global-live-weather{border-right:0!important}
}
@media(max-width:600px){
html body:not(.lucio-home-view) .portal-top,html body.lucio-home-view .portal-top{
  grid-template-columns:44px minmax(0,1fr)!important;
  grid-template-rows:auto auto auto!important;
  gap:9px 10px!important;
  padding:12px 14px 14px!important
}
html body .lucio-mobile-menu{grid-column:1!important;grid-row:1!important}
html body .ls-global-search{grid-column:2!important;grid-row:1!important}
html body .ls-global-search kbd{display:none!important}
html body .ls-top-actions{display:none!important}
html body .ls-personal-greeting{grid-column:1/3!important;grid-row:2!important;padding:0!important;font-size:17px!important}
html body .ls-personal-greeting:after{font-size:10px!important;margin-top:3px!important}
html body .global-live-card{
  grid-column:1/3!important;grid-row:3!important;
  grid-template-columns:1fr 1fr!important;
  min-height:0!important;padding:8px!important;border-radius:14px!important
}
html body .live-date-block,html body .live-clock-block,html body .global-live-place,html body .global-live-weather{
  min-height:72px!important;padding:8px 10px!important;border-right:0!important;border-bottom:1px solid #d8e8f8!important
}
html body .live-clock-block,html body .global-live-weather{border-left:1px solid #d8e8f8!important}
html body .global-live-place,html body .global-live-weather{border-bottom:0!important}
html body .live-date-block b{font-size:11px!important;white-space:normal!important;line-height:1.2!important}
html body .live-date-block small{font-size:8px!important;line-height:1.25!important;white-space:normal!important}
html body .live-clock-block strong{font-size:24px!important}
html body .global-live-place b{font-size:10px!important;white-space:normal!important}
html body .global-live-weather strong{font-size:20px!important}
html body .portal-content{padding:12px 14px 28px!important}
html body .fines-breadcrumb{margin-bottom:10px!important}
html body .fines-hero{display:block!important;padding:20px!important;border-radius:16px!important}
html body .fines-hero-icon{width:52px!important;height:52px!important;margin:0 0 12px!important}
html body .fines-hero-copy{width:100%!important;max-width:none!important}
html body .fines-hero-copy h1{margin:5px 0 10px!important;font-size:30px!important;line-height:1.06!important;letter-spacing:-.035em!important}
html body .fines-hero-copy p{font-size:13px!important;line-height:1.5!important;margin:0!important}
html body .fines-hero-mark{display:none!important}
html body .fines-search-card{display:grid!important;grid-template-columns:1fr!important;gap:12px!important;padding:16px!important}
html body .fines-form-actions{display:grid!important;grid-template-columns:1fr 1fr!important;gap:10px!important}
html body .fines-btn{width:100%!important;min-width:0!important}
html body .fines-placeholder{padding:20px 14px!important}
html body .fines-state-grid{grid-template-columns:1fr!important}
html body #yum-chat-launch{width:50px!important;height:50px!important;right:14px!important;bottom:14px!important;border-radius:16px!important}
}

@media(max-width:1100px){
html body .lucio-mobile-menu{position:relative!important;z-index:60!important;pointer-events:auto!important}
html body .ls-global-search{position:relative!important;z-index:1!important;overflow:hidden!important;min-width:0!important}
html body .ls-global-search>span{pointer-events:none!important}
}

/* V31.3 mobile specificity hardening after visual QA */
@media(max-width:600px){
html body:not(.lucio-home-view) .portal-top,html body.lucio-home-view .portal-top{
  display:grid!important;
  grid-template-columns:44px minmax(0,1fr)!important;
  grid-template-rows:auto auto auto!important;
  gap:10px!important;
  padding:12px 14px 14px!important;
  height:auto!important;min-height:0!important
}
html body:not(.lucio-home-view) .lucio-mobile-menu,html body.lucio-home-view .lucio-mobile-menu{grid-column:1!important;grid-row:1!important;align-self:center!important}
html body:not(.lucio-home-view) .ls-global-search,html body.lucio-home-view .ls-global-search{
  display:block!important;grid-column:2!important;grid-row:1!important;position:relative!important;width:100%!important;max-width:none!important;min-width:0!important;margin:0!important;align-self:center!important;overflow:hidden!important
}
html body:not(.lucio-home-view) .ls-global-search input,html body.lucio-home-view .ls-global-search input{display:block!important;width:100%!important;height:44px!important;padding-left:40px!important;padding-right:12px!important}
html body:not(.lucio-home-view) .ls-global-search kbd,html body.lucio-home-view .ls-global-search kbd{display:none!important}
html body:not(.lucio-home-view) .ls-global-search>span,html body.lucio-home-view .ls-global-search>span{position:absolute!important;left:14px!important;top:50%!important;transform:translateY(-50%)!important;pointer-events:none!important;z-index:2!important}
html body:not(.lucio-home-view) .ls-top-actions,html body.lucio-home-view .ls-top-actions{display:none!important}
html body:not(.lucio-home-view) .ls-personal-greeting,html body.lucio-home-view .ls-personal-greeting{
  grid-column:1/3!important;grid-row:2!important;position:static!important;width:100%!important;margin:0!important;padding:0!important;white-space:normal!important;font-size:17px!important
}
html body:not(.lucio-home-view) .global-live-card,html body.lucio-home-view .global-live-card{
  grid-column:1/3!important;grid-row:3!important;position:relative!important;width:100%!important;height:auto!important;min-height:0!important;margin:0!important;padding:8px!important;
  display:grid!important;grid-template-columns:1fr 1fr!important;gap:0!important;align-items:stretch!important
}
html body:not(.lucio-home-view) .live-date-block,html body:not(.lucio-home-view) .live-clock-block,html body:not(.lucio-home-view) .global-live-place,html body:not(.lucio-home-view) .global-live-weather,
html body.lucio-home-view .live-date-block,html body.lucio-home-view .live-clock-block,html body.lucio-home-view .global-live-place,html body.lucio-home-view .global-live-weather{
  position:relative!important;display:flex!important;align-items:center!important;gap:8px!important;width:auto!important;height:auto!important;min-height:74px!important;margin:0!important;padding:9px 10px!important;overflow:hidden!important
}
html body:not(.lucio-home-view) .live-date-block,html body.lucio-home-view .live-date-block{border-right:1px solid #d8e8f8!important;border-bottom:1px solid #d8e8f8!important}
html body:not(.lucio-home-view) .live-clock-block,html body.lucio-home-view .live-clock-block{border-bottom:1px solid #d8e8f8!important}
html body:not(.lucio-home-view) .global-live-place,html body.lucio-home-view .global-live-place{border-right:1px solid #d8e8f8!important}
html body:not(.lucio-home-view) .live-date-block b,html body.lucio-home-view .live-date-block b{font-size:11px!important;line-height:1.2!important;white-space:normal!important;overflow:visible!important}
html body:not(.lucio-home-view) .live-date-block small,html body.lucio-home-view .live-date-block small{font-size:8px!important;line-height:1.25!important;white-space:normal!important}
html body:not(.lucio-home-view) .live-clock-block strong,html body.lucio-home-view .live-clock-block strong{font-size:22px!important}
html body:not(.lucio-home-view) .global-live-place b,html body.lucio-home-view .global-live-place b{font-size:10px!important;line-height:1.2!important;white-space:normal!important;overflow:visible!important}
html body:not(.lucio-home-view) .global-live-place small,html body.lucio-home-view .global-live-place small{font-size:8px!important}
html body:not(.lucio-home-view) .global-live-weather strong,html body.lucio-home-view .global-live-weather strong{font-size:19px!important}
html body:not(.lucio-home-view) .global-live-weather small,html body.lucio-home-view .global-live-weather small{font-size:8px!important;white-space:normal!important}
}

@media(max-width:600px){
html body #yum-chat-launch{width:42px!important;height:42px!important;right:10px!important;bottom:10px!important;border-radius:14px!important}
}

/* FINAL DEVICE POLICY V38 · desktop siempre abierto; touch contraíble */
@media (min-width:1101px) and (hover:hover) and (pointer:fine){
  html body.lucio-home-view .portal-shell,html body:not(.lucio-home-view) .portal-shell{display:block!important;grid-template-columns:none!important}
  html body.lucio-home-view .portal-shell>aside.portal-sidebar[data-lucio-sidebar],
  html body:not(.lucio-home-view) .portal-shell>aside.portal-sidebar[data-lucio-sidebar]{
    position:fixed!important;left:0!important;top:0!important;bottom:0!important;
    width:284px!important;min-width:284px!important;max-width:284px!important;height:100vh!important;
    transform:none!important;padding:14px 12px!important;overflow:hidden!important
  }
  html body.lucio-home-view .portal-shell>main.portal-main,
  html body:not(.lucio-home-view) .portal-shell>main.portal-main{margin-left:284px!important;width:calc(100% - 284px)!important}
  html body .lucio-sidebar-toggle,html body .lucio-mobile-menu{display:none!important}
  html body .lucio-brand-copy,html body .lucio-nav-label,html body .lucio-nav-chevron{display:inline!important}
  html body .portal-brand{justify-content:flex-start!important}
  html body .lucio-sidebar-head{min-height:82px!important;flex-direction:row!important;justify-content:space-between!important;padding:0 2px 10px!important}
  html body .lucio-nav>a,html body .lucio-nav-group>summary{justify-content:flex-start!important;font-size:12px!important}
  html body .lucio-nav-group[open]>.lucio-nav-children{display:grid!important}
}
@media (max-width:1100px),(hover:none),(pointer:coarse){
  html body.lucio-home-view .portal-shell,html body:not(.lucio-home-view) .portal-shell{display:block!important;grid-template-columns:none!important}
  html body.lucio-home-view .portal-sidebar,html body:not(.lucio-home-view) .portal-sidebar{
    position:fixed!important;left:0!important;top:0!important;bottom:0!important;
    width:min(88vw,320px)!important;min-width:0!important;max-width:320px!important;height:100dvh!important;
    transform:translateX(-105%)!important;z-index:1000!important
  }
  html body.menu-open.lucio-home-view .portal-sidebar,html body.menu-open:not(.lucio-home-view) .portal-sidebar{transform:none!important}
  html body .lucio-mobile-menu{display:grid!important}
  html body .lucio-sidebar-toggle{display:grid!important}
  html body .lucio-brand-copy,html body .lucio-nav-label,html body .lucio-nav-chevron{display:inline!important}
  html body .portal-main,html body .portal-top,html body .portal-content{margin-left:0!important;width:100%!important}
}