.sm-shell{--sm-nav:204px;--sm-offset:var(--sm-nav);--sm-tools-top:0px}
.sm-shell.sm-menu-closed{--sm-offset:0px;--sm-tools-top:50px}
.sm-side-toggle,.sm-mobile-filter{width:auto;min-height:36px;padding:5px 10px;border:1px solid #cadbd0;background:#fff;color:#20563d;border-radius:9px;font:700 13px/1.3 system-ui;cursor:pointer}
.sm-side-toggle:hover,.sm-mobile-filter:hover{background:#edf5ee;color:#173e2a;transform:none}
.sm-side-toggle:focus-visible,.sm-nav-link:focus-visible,.sm-mobile-filter:focus-visible{outline:2px solid #1b6b4a;outline-offset:2px}
.sm-mobile-tools,.sm-catalog>.sm-side-toggle{display:flex;align-items:center;gap:5px;position:fixed;left:10px;top:10px;z-index:5501}
.sm-explore:not(.sm-menu-closed) .sm-mobile-filter{display:none}
.sm-explore .map-wrap{margin-left:var(--sm-offset)}
#routeTopbar{box-sizing:border-box;inset:0 auto 0 0;width:var(--sm-nav);height:100dvh;max-height:none;padding:58px 11px 16px;border-right:1px solid #d8e5dc;border-bottom:0;background:#f9fcf9;box-shadow:2px 0 10px #173d2520;display:flex;flex-direction:column;align-items:stretch;gap:4px;overflow:auto}
.sm-menu-closed #routeTopbar,.sm-menu-closed .catalog-sidebar{display:none!important}
#routeTopbar .route-topbar__brand{margin:0 0 10px;padding:4px 6px;color:#1d593d;font-size:16px}
#routeTopbar .route-topbar__brand span:last-child{display:inline}
#routeTopbar .route-topbar__mark{background:#226447}
.sm-nav-link,#routeTopbar .route-menu>button,.planificador-pendiente{box-sizing:border-box;min-height:38px;display:flex;align-items:center;width:100%;gap:6px;padding:8px 9px;color:#254338;border-radius:9px;text-decoration:none;font:700 13px/1.3 system-ui}
.sm-nav-link[aria-current],.sm-nav-link:hover,#routeTopbar .route-menu>button:hover,#routeTopbar .route-menu>button.has-active{background:#e4f0e7;color:#20533a}
.planificador-pendiente{flex-wrap:wrap;background:#f0f2ed;color:#526154;cursor:default}
.planificador-pendiente small{font-size:10px;white-space:nowrap;background:#f8edd2;color:#644c21;border-radius:10px;padding:2px 6px;font-weight:700}
#routeTopbar .route-menu{height:auto;flex:none;display:block}
#routeTopbar .route-menu>button{text-align:left;justify-content:space-between}
#routeTopbar [data-menu="capas-rutas"]{margin:0;padding:0;border:0}
#routeTopbar .route-menu__panel{position:static;min-width:0;max-height:none;box-shadow:none;margin:2px 0 3px;border-radius:9px;padding:4px}
#routeTopbar .route-menu__panel .menu-tool{min-height:33px;padding:4px;gap:5px}
#routeTopbar .menu-tool__icon{width:20px;height:20px;font-size:12px}
#routeTopbar .menu-tool__title{font-size:11px}
#routeTopbar .menu-tool__desc{display:none}
#routeTopbar .route-topbar__spacer{display:none}
#routeTopbar .topbar-municipality-search{display:grid;min-width:0;width:100%;flex:none;padding:10px 0 0;margin:5px 0 0;border:0;border-top:1px solid #d8e5dc}
#routeTopbar .topbar-municipality-search input{min-width:0}
.sm-explore #senderosExplorer,.sm-explore #savedRoutesIndependentPanel{left:calc(var(--sm-offset) + 11px);top:calc(var(--sm-tools-top) + 12px);max-height:calc(100dvh - var(--sm-tools-top) - 24px)}
.sm-explore #senderosExplorer{width:min(285px,27vw)}
.sm-explore .leaflet-top{top:var(--sm-tools-top)!important}
.sm-explore .map-trail-preview{top:calc(var(--sm-tools-top) + 12px);max-height:calc(100dvh - var(--sm-tools-top) - 32px)}
.sm-catalog .catalog-sidebar{width:var(--sm-nav);padding:58px 12px 18px}
.sm-catalog .catalog-main{margin-left:var(--sm-offset);min-width:0}
.sm-catalog.sm-menu-closed .catalog-main{padding-top:45px}
.sm-catalog .catalog-nav{display:grid;grid-template-columns:1fr}
.sm-catalog .catalog-nav small{display:inline;margin-left:0}
.sm-profile{margin:4px 0 0;padding:6px 8px 3px;border-radius:9px;background:#f0f4ef}
.sm-profile figcaption{display:flex;justify-content:space-between;gap:6px;color:#294b38;font-size:11px;font-weight:750}
.sm-profile svg{width:100%;height:47px;display:block}
@media (max-width:900px){
 .sm-shell,.sm-shell.sm-menu-closed{--sm-offset:0px;--sm-tools-top:48px}
 #routeTopbar,.sm-catalog .catalog-sidebar{position:fixed;inset:0 auto 0 0;height:100dvh;width:var(--sm-nav);z-index:5500;overflow:auto}
 .sm-catalog .catalog-main{margin-left:0;padding-top:45px}
 .sm-explore #senderosExplorer{left:8px;right:8px;width:auto}
 .sm-explore .map-trail-preview{top:auto;max-height:min(49dvh,420px)}
 .sm-explore .map-trail-preview__photo{height:clamp(54px,10dvh,90px)}
}
@media (max-width:550px),(max-height:580px){
 .sm-explore .map-trail-preview__photo{display:none}
 .sm-profile svg{height:36px}
}
