/* LeonPeru V27 PRO · revisión móvil final */
@media (max-width: 900px){
  html{scroll-padding-top:74px;overflow-x:hidden;}
  body{max-width:100%;overflow-x:hidden;}
  body:not(.admin-open){padding-bottom:calc(82px + env(safe-area-inset-bottom,0px))!important;}
  img,svg,video{max-width:100%;}
  button,a,input,select,textarea{touch-action:manipulation;}
  input,select,textarea{font-size:16px;}

  /* Barra superior + header: en móvil se usa el menú inferior. */
  .topbar{padding:7px 0!important;min-height:29px;}
  .topbar .container{width:100%!important;padding:0 12px!important;justify-content:center!important;text-align:center;}
  .topbar .container>span:first-child{font-size:10px!important;letter-spacing:.055em;white-space:nowrap;}
  .topbar .container>span:last-child{display:none!important;}
  .header{position:sticky!important;top:0!important;z-index:40!important;}
  .header .nav{height:64px!important;min-height:64px!important;width:100%!important;max-width:100%!important;padding:0 14px!important;gap:0!important;justify-content:center!important;overflow:visible!important;}
  .header .links,.header .nav-actions{display:none!important;}
  .header .brand{display:flex!important;position:relative!important;flex:0 0 auto!important;width:auto!important;min-width:0!important;max-width:70vw!important;margin:0 auto!important;justify-content:center!important;overflow:visible!important;transform:none!important;}
  .header .brand-logo-full,.header .brand-logo-clean{display:block!important;width:164px!important;max-width:62vw!important;height:auto!important;max-height:54px!important;margin:0!important;object-fit:contain!important;object-position:center!important;transform:none!important;}
  .header .brand-logo-icon{display:none!important;}

  /* La estrella fugaz se conserva, pero contenida bajo el logo. */
  .header .nav .brand::before{left:8%!important;width:84%!important;bottom:2px!important;}

  /* Portada */
  .hero{min-height:0!important;height:auto!important;display:block!important;overflow:hidden!important;}
  .hero .container{width:100%!important;max-width:100%!important;padding:48px 18px 44px!important;}
  .hero .eyebrow{font-size:10px!important;letter-spacing:.18em!important;}
  .hero h1{font-size:clamp(50px,15.5vw,66px)!important;line-height:.86!important;letter-spacing:-1.8px!important;max-width:100%!important;margin:17px 0 20px!important;}
  .hero p{max-width:100%!important;font-size:15px!important;line-height:1.65!important;margin-right:0!important;}
  .hero .actions{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;margin-top:26px!important;}
  .hero .actions>*{width:100%!important;min-width:0!important;min-height:54px!important;}
  .hero .stats{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:22px 12px!important;margin-top:34px!important;max-width:100%!important;}
  .hero .stat,.hero .stat:first-child{min-width:0!important;min-height:62px!important;padding:0 0 0 12px!important;border-left:2px solid #e50914!important;border-right:0!important;}
  .hero .stat strong{font-size:29px!important;}
  .hero .stat span{font-size:10px!important;letter-spacing:.07em!important;}
  .hero .lan-banner{width:118vw!important;right:-58%!important;top:0!important;bottom:0!important;height:100%!important;opacity:.14!important;pointer-events:none!important;}
  .hero .lan-banner-art{mask-image:linear-gradient(90deg,transparent 0%,rgba(0,0,0,.18) 32%,#000 68%)!important;-webkit-mask-image:linear-gradient(90deg,transparent 0%,rgba(0,0,0,.18) 32%,#000 68%)!important;}

  /* Carrusel de juegos: swipe horizontal sin desperdiciar espacio. */
  .game-strip{padding:11px 0!important;overflow:hidden!important;}
  .game-strip-inner{width:100%!important;max-width:100%!important;padding:0 10px!important;gap:0!important;}
  .game-strip-track{display:flex!important;gap:12px!important;overflow-x:auto!important;overflow-y:hidden!important;scroll-snap-type:x proximity;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch;padding:2px 2px 5px!important;}
  .game-strip-track::-webkit-scrollbar{display:none;}
  .game-chip{flex:0 0 96px!important;min-width:96px!important;max-width:96px!important;min-height:70px!important;padding:6px 2px!important;scroll-snap-align:start;}
  .game-mark{width:92px!important;min-width:92px!important;height:36px!important;padding:0 4px!important;}
  .game-logo-hires{max-width:90px!important;max-height:34px!important;object-fit:contain!important;}
  .game-chip>span:last-child{max-width:92px!important;font-size:10px!important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}

  /* Secciones generales */
  .section{padding:58px 0!important;overflow:hidden;}
  .section>.container,.section .container,.footer-wrap{width:100%!important;max-width:100%!important;padding-left:16px!important;padding-right:16px!important;}
  .section-head{display:block!important;margin-bottom:26px!important;}
  .section-head h2,.section h2{font-size:clamp(40px,12vw,50px)!important;line-height:.9!important;}
  .section-head p{font-size:14px!important;line-height:1.65!important;margin-top:14px!important;}

  /* Sedes */
  .sede-home-detailed{padding:54px 0 64px!important;}
  .sede-home-panel-detailed{gap:22px!important;}
  .sede-home-heading{padding-left:18px!important;}
  .sede-home-panel-detailed h2{font-size:clamp(48px,14vw,62px)!important;}
  .sede-home-copybox{padding:20px 18px!important;}
  .sede-home-copybox p{font-size:14px!important;line-height:1.65!important;}
  .sede-home-detail-grid{gap:16px!important;}
  .sede-home-detail-card{min-height:0!important;padding:24px 20px 22px!important;}
  .sede-home-detail-card h3{font-size:32px!important;}
  .sede-home-detail-card p{font-size:14px!important;min-height:0!important;}
  .sede-detail-meta{margin:17px 0 20px!important;}
  .sede-home-detail-card .btn.primary{min-height:52px!important;}

  /* Torneos / destacados */
  #torneos.lp-content-section{padding:58px 0 70px!important;}
  #torneos.lp-content-section .container{padding:0 16px!important;}
  #torneos .section-head{display:block!important;margin-bottom:28px!important;}
  #torneos .section-head>p{margin:14px 0 0!important;font-size:15px!important;line-height:1.65!important;}
  #torneos .lp-content-slider,#torneos .lp-content-slide{height:auto!important;min-height:0!important;}
  #torneos .lp-content-slide{grid-template-columns:1fr!important;}
  #torneos .lp-reference-art,#torneos .lp-card-art{min-height:220px!important;}
  #torneos .lp-reference-body,#torneos .lp-content-body{padding:28px 24px 76px!important;}
  #torneos .lp-reference-body h3,#torneos .lp-content-body h3{font-size:38px!important;line-height:.92!important;}
  #torneos .lp-reference-body p,#torneos .lp-content-body p{font-size:14px!important;line-height:1.6!important;}
  #torneos .lp-content-arrow{width:42px!important;height:42px!important;}

  /* Ubicación */
  #ubicacion .location{grid-template-columns:1fr!important;gap:16px!important;}
  #ubicacion .location>.card{padding:22px 20px!important;}
  #ubicacion .location>.card h3{font-size:25px!important;}
  #ubicacion .location>.card p{overflow-wrap:anywhere;}
  #ubicacion .location>.card .btn{width:100%!important;}
  #locationPhotoGallery{width:100%!important;min-height:320px!important;height:min(92vw,390px)!important;}
  #locationPhotoGallery .location-photo-caption{padding:68px 16px 18px!important;}
  #locationPhotoGallery .location-photo-caption p{max-width:76%!important;}

  /* Tienda */
  #tienda{padding-top:42px!important;}
  #tienda .store-close{margin-bottom:16px!important;}
  #tienda .store-close button{min-height:44px;}
  .shopbar{position:static!important;display:grid!important;grid-template-columns:1fr!important;gap:10px!important;padding:10px!important;margin:18px 0!important;}
  .filters{width:100%!important;display:flex!important;flex-wrap:nowrap!important;overflow-x:auto!important;overscroll-behavior-x:contain;padding:0 0 4px!important;}
  .filters .filter{flex:0 0 auto!important;min-height:42px!important;}
  .cart-open{width:100%!important;min-height:46px!important;}
  .product-grid{grid-template-columns:1fr!important;gap:14px!important;}
  .product-bottom{align-items:center!important;}
  .add-product{min-height:44px!important;}
  .store-info{grid-template-columns:1fr!important;gap:20px!important;margin-top:34px!important;padding:22px 18px!important;}
  .store-points{grid-template-columns:1fr!important;}

  /* Recargas */
  #recargas.recargas-section{padding:26px 0 72px!important;overflow:hidden!important;}
  #recargas .recargas-pro-container{width:100%!important;padding-left:14px!important;padding-right:14px!important;}
  #recargas .recharge-hero-pro{padding:24px 18px!important;border-radius:20px!important;}
  #recargas .recharge-hero-copy h2{font-size:clamp(48px,14vw,60px)!important;line-height:.9!important;}
  #recargas .recharge-hero-copy>p{font-size:14px!important;line-height:1.65!important;}
  #recargas .recharge-hero-badges{gap:7px!important;}
  #recargas .recharge-toolbar-pro{grid-template-columns:1fr!important;}
  #recargas .recharge-filter-pro{display:flex!important;flex-wrap:nowrap!important;overflow-x:auto!important;overscroll-behavior-x:contain;padding-bottom:4px!important;}
  #recargas .recharge-filter-pro button{flex:0 0 auto!important;min-height:42px!important;}
  #recargas .recharge-trust-strip{grid-template-columns:1fr!important;}
  #recargas .recharge-trust-strip>i{display:none!important;}
  #recargas .recarga-grid-v2{grid-template-columns:1fr!important;}
  #recargas .recarga-card-v2{min-width:0!important;}
  #recargas .recharge-payments-grid-v20{grid-template-columns:1fr!important;}
  #recargas .recharge-payments-safe-v20{min-width:0!important;width:100%!important;}
  .recharge-checkout-layout-v16{grid-template-columns:1fr!important;}
  .recharge-denom-column-v16,.recharge-order-card-v16{padding:18px!important;}
  .recharge-order-card-v16{position:static!important;}

  /* Detalle de sede y selección de PCs */
  .branch-detail-section{padding:26px 0 calc(92px + env(safe-area-inset-bottom,0px))!important;min-height:0!important;}
  .branch-detail-section>.container{width:100%!important;max-width:100%!important;padding:0 12px!important;}
  .branch-backbar{display:flex!important;align-items:center!important;gap:10px!important;flex-wrap:wrap!important;}
  .branch-backbtn{min-height:44px!important;}
  .branch-view-label{font-size:9px!important;}
  .branch-detail-head{grid-template-columns:1fr!important;gap:16px!important;padding:19px 16px!important;}
  .branch-detail-head h2{font-size:clamp(42px,13vw,56px)!important;overflow-wrap:anywhere;}
  .branch-detail-head p{font-size:14px!important;line-height:1.6!important;}
  .branch-total{width:100%!important;height:auto!important;padding:13px 14px!important;}
  .branch-category-header{align-items:flex-start!important;flex-direction:column!important;gap:5px!important;}
  .branch-live-overview{grid-template-columns:1fr!important;gap:12px!important;}
  .client-pc-selector{margin:20px 0!important;padding:18px 12px!important;border-radius:18px!important;}
  .client-pc-selector-head{display:block!important;}
  .client-pc-selector-head h3{font-size:36px!important;}
  .client-pc-selector-head p{font-size:13px!important;line-height:1.55!important;}
  .client-pc-summary{grid-template-columns:repeat(3,minmax(0,1fr))!important;min-width:0!important;max-width:100%!important;width:100%!important;gap:6px!important;margin-top:14px!important;}
  .client-pc-summary div{min-width:0!important;padding:10px 5px!important;}
  .client-pc-summary b{font-size:20px!important;}
  .client-pc-summary span{font-size:7px!important;letter-spacing:.07em!important;}
  .client-pc-toolbar{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;align-items:stretch!important;}
  .client-pc-filters{display:flex!important;flex-wrap:nowrap!important;overflow-x:auto!important;overscroll-behavior-x:contain;padding-bottom:4px!important;}
  .client-pc-filter{flex:0 0 auto!important;min-height:40px!important;}
  .client-pc-refresh{width:100%!important;min-height:42px!important;}
  .client-pc-legend{gap:10px!important;font-size:10px!important;}
  .client-pc-tier-grid{grid-template-columns:1fr!important;gap:12px!important;}
  .client-pc-tile{min-height:198px!important;padding:18px 16px 16px!important;}
  .client-pc-card-top{grid-template-columns:52px minmax(0,1fr)!important;gap:12px!important;}
  .client-pc-device{width:50px!important;height:46px!important;}
  .client-pc-price b{font-size:24px!important;}
  .client-pc-number{margin-top:20px!important;font-size:30px!important;}
  .client-pc-card-footer{left:16px!important;right:16px!important;bottom:14px!important;gap:7px!important;}
  .client-pc-action{font-size:8px!important;padding:7px 8px!important;}
  .client-pc-note{font-size:10px!important;line-height:1.5!important;}
  .branch-address{padding:17px 15px!important;align-items:flex-start!important;}

  /* Carrito, cuenta y modales deben estar sobre el menú inferior. */
  .drawer{z-index:5000!important;}
  .drawer .panel{width:100%!important;max-width:100%!important;padding:20px 16px calc(24px + env(safe-area-inset-bottom,0px))!important;}
  .modal,.login-overlay,.account-overlay{z-index:5200!important;padding:8px!important;}
  .modalbox,.professional-booking,.login-box,.account-box{width:100%!important;max-width:100%!important;max-height:calc(100% - 16px)!important;border-radius:17px!important;overflow:auto!important;padding:20px 15px!important;}
  .professional-booking{padding:20px 14px!important;}
  .booking-hero-head{padding-right:44px!important;}
  .booking-summary,.booking-field-grid,.booking-customer-grid,.booking-category-grid,.professional-pc-picker{grid-template-columns:1fr!important;}
  .booking-step{padding:15px!important;}
  .booking-submit{width:100%!important;}
  .account-overlay .account-box{padding-bottom:24px!important;}
  .account-tabs{display:grid!important;grid-template-columns:1fr 1fr!important;}
  .account-stats{grid-template-columns:1fr!important;}
  .payment-proof-box-v21{width:100%!important;max-height:calc(100% - 16px)!important;}

  /* Menú inferior */
  #lpMobileNav,.lp-mobile-nav{
    position:fixed!important;display:grid!important;grid-template-columns:repeat(6,minmax(0,1fr))!important;
    left:7px!important;right:7px!important;bottom:calc(7px + env(safe-area-inset-bottom,0px))!important;
    z-index:45!important;min-height:64px!important;gap:2px!important;padding:6px!important;
    border:1px solid rgba(209,213,219,.9)!important;border-radius:16px!important;
    background:rgba(255,255,255,.96)!important;color:#7b8491!important;
    box-shadow:0 12px 34px rgba(15,23,42,.18)!important;backdrop-filter:blur(18px)!important;
  }
  #lpMobileNav button,.lp-mobile-nav button{
    display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;
    min-width:0!important;width:100%!important;min-height:50px!important;padding:4px 1px!important;
    border:0!important;border-radius:10px!important;background:transparent!important;color:#7b8491!important;
    font-size:8px!important;font-weight:900!important;line-height:1.05!important;white-space:nowrap!important;overflow:hidden!important;
  }
  #lpMobileNav button span,.lp-mobile-nav button span{font-size:16px!important;line-height:1!important;margin:0 0 4px!important;}
  #lpMobileNav button.active,.lp-mobile-nav button.active{background:#fff1f2!important;color:#d80b16!important;}
  body.admin-open #lpMobileNav,body.admin-open .lp-mobile-nav{display:none!important;}

  /* ADMIN móvil */
  .admin-overlay{z-index:6000!important;padding:0!important;}
  #admin .admin-shell,.admin-overlay .admin-shell{width:100%!important;height:100%!important;max-height:100%!important;border-radius:0!important;}
  #admin .admin-side,.admin-overlay .admin-side{position:sticky!important;top:0!important;z-index:20!important;padding:8px 58px 8px 8px!important;background:#fff!important;}
  #admin .side-item{min-height:42px!important;padding:0 11px!important;font-size:11px!important;}
  #admin .admin-main{padding:14px 12px 50px!important;}
  #admin .admin-top{margin:0 -12px 16px!important;padding:12px!important;}
  #admin .admin-top h2{font-size:34px!important;}
  #admin input,#admin select,#admin textarea{font-size:16px!important;max-width:100%!important;}
  #admin .admin-card,#admin .metric{min-width:0!important;padding:15px!important;}
  #admin .admin-grid,#admin .admin-cards{grid-template-columns:1fr!important;}
  #admin .table-wrap,#admin .admin-table-wrap,#admin .orders-list,#admin .crm-table-wrap{max-width:100%!important;overflow-x:auto!important;-webkit-overflow-scrolling:touch;}
  .admin-exit-fixed{z-index:6050!important;top:7px!important;right:7px!important;min-height:42px!important;}
}

@media (max-width: 520px){
  .header .nav{height:60px!important;min-height:60px!important;}
  .header .brand-logo-full,.header .brand-logo-clean{width:150px!important;max-width:66vw!important;max-height:50px!important;}
  .hero .container{padding:42px 16px 38px!important;}
  .hero h1{font-size:clamp(48px,16vw,60px)!important;}
  .hero .stats{gap:18px 8px!important;}
  .section{padding:50px 0!important;}
  .section>.container,.section .container{padding-left:14px!important;padding-right:14px!important;}
  #torneos.lp-content-section .container{padding:0 14px!important;}
  #torneos .lp-reference-body,#torneos .lp-content-body{padding:26px 20px 72px!important;}
  #torneos .lp-reference-body h3,#torneos .lp-content-body h3{font-size:34px!important;}
  #locationPhotoGallery{height:350px!important;min-height:300px!important;}
  .branch-view-label{display:none!important;}
  .client-pc-selector{padding:16px 10px!important;}
  .client-pc-card-footer{align-items:center!important;}
  .client-pc-state{font-size:9px!important;}
  .client-pc-action{max-width:48%!important;overflow:hidden!important;text-overflow:ellipsis!important;}
  #lpMobileNav button,.lp-mobile-nav button{font-size:7.5px!important;}
}

@media (max-width: 350px){
  .topbar .container>span:first-child{font-size:9px!important;}
  .header .brand-logo-full,.header .brand-logo-clean{width:140px!important;}
  .hero h1{font-size:48px!important;}
  .hero p{font-size:14px!important;}
  .hero .stats{grid-template-columns:1fr 1fr!important;}
  .game-chip{flex-basis:90px!important;min-width:90px!important;max-width:90px!important;}
  #lpMobileNav,.lp-mobile-nav{left:5px!important;right:5px!important;padding:5px 3px!important;}
  #lpMobileNav button,.lp-mobile-nav button{font-size:7px!important;padding-left:0!important;padding-right:0!important;}
  #lpMobileNav button span,.lp-mobile-nav button span{font-size:15px!important;}
}

/* Último ajuste detectado en auditoría 320–430 px */
@media (max-width: 560px){
  #recargas .recharge-hero-stats{grid-template-columns:1fr!important;width:100%!important;min-width:0!important;}
  #recargas .recharge-hero-stats>div{width:100%!important;min-width:0!important;min-height:92px!important;}
}
