/* LOSTTLOOT V12.6.10 — MOBILE / TABLET FORMATTING PASS
   IMPORTANT: this file contains responsive-only rules. The approved desktop
   layout is intentionally untouched at standard desktop widths.

   Targets:
   - iPhone / small phones: <= 767px
   - iPad / tablets: 768px–1024px
   - iPad Pro landscape / coarse touch displays: <= 1366px
   - safe-area support for notches / home indicators
*/

@media (max-width:1024px), (hover:none) and (pointer:coarse) and (max-width:1366px) {
  :root{
    --mobile-page-pad:clamp(14px,3.2vw,28px);
    --mobile-card-radius:18px;
    --mobile-header-h:68px;
  }

  html{
    width:100%;
    max-width:100%;
    overflow-x:hidden;
    -webkit-text-size-adjust:100%;
    text-size-adjust:100%;
    scroll-padding-top:calc(var(--mobile-header-h) + 12px);
  }
  body,
  body.product-page-body,
  body.account-body,
  body.treasure-hall-page{
    width:100%;
    max-width:100%;
    overflow-x:hidden!important;
    background-attachment:scroll!important;
  }
  *,*::before,*::after{box-sizing:border-box}
  img,video,canvas,svg{max-width:100%;height:auto}
  iframe{max-width:100%}
  button,a,input,select,textarea{touch-action:manipulation}
  button,.button,.account-link,.gold-button,.secondary-button{min-height:44px}
  input,select,textarea{font-size:16px!important}
  :where(h1,h2,h3,h4,p,li,a,button,strong,small,span){overflow-wrap:anywhere}

  /* ---------- Main storefront header ---------- */
  .site-header{
    min-height:var(--mobile-header-h)!important;
    height:auto!important;
    padding-left:max(12px,env(safe-area-inset-left))!important;
    padding-right:max(12px,env(safe-area-inset-right))!important;
    display:flex!important;
    align-items:center!important;
    gap:8px!important;
    backdrop-filter:blur(16px)!important;
  }
  .site-header .brand{
    flex:1 1 auto!important;
    min-width:0!important;
    gap:8px!important;
  }
  .site-header .brand img{flex:0 0 auto}
  .site-header .brand-copy{min-width:0}
  .site-header .brand strong{white-space:nowrap}
  .site-header .menu-toggle{
    order:4!important;
    flex:0 0 44px!important;
    width:44px!important;
    height:44px!important;
    margin:0!important;
    display:block!important;
  }
  .site-header .account-link{
    order:2!important;
    flex:0 0 auto!important;
    margin:0!important;
  }
  .site-header .cart-button,
  .site-header .vault-button{
    order:3!important;
    flex:0 0 auto!important;
    margin:0!important;
  }
  .site-nav{
    position:fixed!important;
    z-index:500!important;
    top:var(--mobile-header-h)!important;
    left:0!important;
    right:0!important;
    bottom:auto!important;
    max-height:calc(100dvh - var(--mobile-header-h))!important;
    padding:14px max(20px,env(safe-area-inset-left)) calc(24px + env(safe-area-inset-bottom))!important;
    overflow-y:auto!important;
    -webkit-overflow-scrolling:touch!important;
    background:rgba(4,6,10,.985)!important;
    border-bottom:1px solid rgba(224,172,65,.24)!important;
    box-shadow:0 28px 70px rgba(0,0,0,.55)!important;
  }
  .site-nav a{
    width:100%!important;
    min-height:50px!important;
    padding:13px 2px!important;
    display:flex!important;
    align-items:center!important;
    font-size:.86rem!important;
    letter-spacing:.04em!important;
  }

  /* ---------- General mobile rhythm ---------- */
  main{min-width:0}
  .section,
  .social-section,
  .site-footer,
  .product-page-footer{
    max-width:100%!important;
  }
  .section{
    width:min(calc(100% - (var(--mobile-page-pad) * 2)),1480px)!important;
    padding-top:64px!important;
    padding-bottom:64px!important;
  }
  .section-heading,
  .split-heading{
    min-width:0!important;
  }
  .split-heading{
    grid-template-columns:1fr!important;
    gap:14px!important;
  }
  .section-heading h2,
  .split-heading h2{
    max-width:100%!important;
    line-height:1.02!important;
  }
  .section-heading p,
  .split-heading p{max-width:760px!important}

  /* Horizontally scroll compact filter/tabs instead of wrapping into tall blocks. */
  .world-switcher,
  .catalog-departments,
  .catalog-subcategories,
  .form-tabs,
  .auth-tabs{
    max-width:100%!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
    -webkit-overflow-scrolling:touch!important;
    scrollbar-width:none!important;
  }
  .world-switcher::-webkit-scrollbar,
  .catalog-departments::-webkit-scrollbar,
  .catalog-subcategories::-webkit-scrollbar,
  .form-tabs::-webkit-scrollbar,
  .auth-tabs::-webkit-scrollbar{display:none}

  /* ---------- Home / treasure map hero ---------- */
  .tv-hero{
    min-height:auto!important;
    padding:92px var(--mobile-page-pad) 58px!important;
    background-size:cover!important;
    background-position:center top!important;
    overflow:hidden!important;
  }
  .tv-hero-inner{
    width:min(100%,960px)!important;
    grid-template-columns:1fr!important;
    gap:20px!important;
    margin-inline:auto!important;
  }
  .tv-copy{
    max-width:820px!important;
    margin-inline:auto!important;
    text-align:center!important;
  }
  .tv-copy h1{
    max-width:100%!important;
    margin-inline:auto!important;
    font-size:clamp(3rem,8vw,5.35rem)!important;
    line-height:.93!important;
  }
  .tv-copy p{max-width:720px!important;margin-inline:auto!important}
  .tv-actions,.hero-actions{justify-content:center!important}
  .tv-showcase{
    width:100%!important;
    max-width:880px!important;
    min-height:590px!important;
    margin-inline:auto!important;
  }
  .tv-featured-card{width:min(420px,58vw)!important}
  .tv-featured-image{height:min(390px,43vw)!important}
  .tv-orbit-card{width:clamp(122px,18vw,185px)!important}
  .tv-vault-rings{max-width:92vw!important;max-height:92vw!important}
  .tv-hero-benefits{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    width:100%!important;
    margin-top:10px!important;
  }
  .tv-hero-benefits>div{min-width:0!important}
  .tv-hero-benefits>div:nth-child(even){border-right:0!important}

  /* ---------- Shop / catalog ---------- */
  .catalog-category-shell{padding:18px!important}
  .shop-toolbar{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:10px!important;
  }
  .shop-toolbar>*{min-width:0!important;width:100%!important}
  .shop-results-line{gap:10px!important}
  .product-grid{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:14px!important;
  }
  .store-product-card{min-width:0!important;width:100%!important}
  .store-product-media,
  .product-image-button{min-width:0!important}
  .store-product-media img,
  .product-image-button img{
    width:100%!important;
    max-width:100%!important;
    object-fit:contain!important;
  }
  .store-product-copy{padding:14px!important}
  .product-title-button{
    min-height:0!important;
    line-height:1.28!important;
  }
  .product-price-row{align-items:flex-end!important;gap:8px!important}

  /* ---------- Reserve ---------- */
  .order-type-grid,
  .reserve-featured-grid{grid-template-columns:1fr!important}
  .reserve-featured-product{
    grid-template-columns:1fr!important;
    gap:18px!important;
    padding:20px!important;
    border-radius:var(--mobile-card-radius)!important;
  }
  .reserve-featured-image{
    width:100%!important;
    min-height:300px!important;
    max-height:520px!important;
  }
  .reserve-featured-image img{max-height:480px!important;object-fit:contain!important}
  .reserve-featured-copy{min-width:0!important}
  .reserve-featured-copy h3{font-size:clamp(2rem,6vw,3.15rem)!important;line-height:1!important}
  .reserve-featured-price{flex-wrap:wrap!important}
  .reserve-featured-copy .gold-button,
  .reserve-featured-copy .button{min-height:50px!important}

  /* ---------- Sell / request / contact forms ---------- */
  .forms-section,
  .contact-section,
  .shipping-card,
  .about-section,
  .social-section{grid-template-columns:1fr!important}
  .form-intro{position:static!important}
  .field-row,
  .shipping-points{grid-template-columns:1fr!important}
  .collector-form,
  .form-shell{min-width:0!important}
  .collector-form input,
  .collector-form select,
  .collector-form textarea,
  .form-shell input,
  .form-shell select,
  .form-shell textarea{width:100%!important;max-width:100%!important}

  /* ---------- Product detail ---------- */
  .standalone-product-main{
    width:100%!important;
    max-width:100%!important;
    padding-left:var(--mobile-page-pad)!important;
    padding-right:var(--mobile-page-pad)!important;
  }
  .product-page-layout,
  .bundle-listing-shell .product-page-layout{
    grid-template-columns:1fr!important;
    gap:20px!important;
    padding:16px!important;
  }
  .standalone-gallery,
  .bundle-listing-shell .standalone-gallery{
    position:static!important;
    top:auto!important;
    min-width:0!important;
  }
  .standalone-main-image,
  .bundle-listing-shell .standalone-main-image{
    width:100%!important;
    min-height:min(58vw,520px)!important;
    max-height:620px!important;
  }
  .standalone-main-image img{object-fit:contain!important}
  .standalone-product-info{min-width:0!important;padding:20px!important}
  .standalone-product-info h1{
    max-width:100%!important;
    font-size:clamp(2.25rem,7vw,4rem)!important;
    line-height:.98!important;
  }
  .standalone-facts{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .product-detail-panels{grid-template-columns:1fr!important}
  .product-page-add,
  .standalone-product-info .button{min-height:54px!important}
  .bundle-gallery-assurance{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .bundle-listing-shell .standalone-thumbnails{grid-template-columns:repeat(5,minmax(56px,1fr))!important}

  /* ---------- Cart / modal / toast ---------- */
  .cart-drawer{
    width:min(480px,100vw)!important;
    max-width:100vw!important;
    padding-bottom:env(safe-area-inset-bottom)!important;
  }
  .drawer-overlay{inset:0!important}
  .modal-backdrop{padding:var(--mobile-page-pad)!important}
  .modal-content,
  .product-detail-modal{
    width:100%!important;
    max-width:100%!important;
    max-height:calc(100dvh - (var(--mobile-page-pad) * 2))!important;
    overflow:auto!important;
  }
  .toast{max-width:calc(100vw - 24px)!important}

  /* ---------- Footer ---------- */
  .footer-links{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .footer-bottom{gap:14px!important}

  /* ---------- Account / sign-in ---------- */
  .account-header{
    padding-left:var(--mobile-page-pad)!important;
    padding-right:var(--mobile-page-pad)!important;
  }
  .account-main,
  .account-body.dashboard-active .account-main{
    width:min(calc(100% - 18px),1540px)!important;
    max-width:100%!important;
  }
  .account-hero{padding-left:var(--mobile-page-pad)!important;padding-right:var(--mobile-page-pad)!important}
  .auth-shell{width:min(100%,720px)!important;margin-inline:auto!important}
  .auth-card{max-width:100%!important}
  .dashboard-shell{grid-template-columns:1fr!important;min-width:0!important}
  .dashboard-nav{
    border-right:0!important;
    border-bottom:1px solid var(--account-line)!important;
  }
  .dashboard-nav-list{grid-template-columns:repeat(3,minmax(0,1fr))!important}
  .dashboard-nav-list button{min-width:0!important}
  .dashboard-content{padding:26px 20px!important;min-width:0!important}
  .dashboard-summary-grid,
  .treasure-quick-grid,
  .address-grid,
  .account-form-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .profile-settings-layout{grid-template-columns:1fr!important}

  /* ---------- Treasure Hall / collector profile ---------- */
  .prestige-shell,
  .collector-profile-shell{
    width:min(calc(100% - 24px),1540px)!important;
    max-width:100%!important;
  }
  .prestige-hero{
    grid-template-columns:1fr!important;
    gap:28px!important;
    padding-top:62px!important;
  }
  .prestige-hero__copy{text-align:center!important}
  .prestige-hero__actions{justify-content:center!important;flex-wrap:wrap!important}
  .prestige-hero__visual{max-width:760px!important;width:100%!important;margin-inline:auto!important}
  .prestige-rank-grid{grid-template-columns:1fr!important}
  .prestige-rank-card,
  .prestige-rank-card--wide{
    grid-template-columns:minmax(180px,240px) minmax(0,1fr)!important;
    min-width:0!important;
  }
  .prestige-purchase-card{
    grid-template-columns:minmax(180px,240px) minmax(0,1fr)!important;
    min-width:0!important;
  }
  .prestige-purchase-card__rank{
    grid-column:1/-1!important;
    border-left:0!important;
    border-top:1px solid rgba(215,164,58,.16)!important;
    padding-top:18px!important;
  }
  .collector-profile-hero{grid-template-columns:160px 1fr!important}
  .collector-profile-rank{grid-column:1/-1!important}
  .collector-stats-premium{grid-template-columns:1fr!important}

  /* ---------- Captain's Chest top bar / landing ---------- */
  body.captains-live-page{overflow-x:hidden!important}
  .topbar{
    min-height:64px!important;
    height:64px!important;
    padding-left:max(12px,env(safe-area-inset-left))!important;
    padding-right:max(12px,env(safe-area-inset-right))!important;
    grid-template-columns:1fr auto!important;
    gap:10px!important;
  }
  .topbar .brand{min-width:0!important;font-size:.8rem!important;letter-spacing:.18em!important}
  .topbar .brand img{width:34px!important;height:34px!important}
  .topbar nav{display:none!important}
  .top-actions{gap:6px!important}
  .top-actions .pill{min-height:38px!important;padding-inline:10px!important}

  #home.approved-first-page{
    min-height:760px!important;
    height:max(760px,100svh)!important;
    padding-top:64px!important;
    overflow:hidden!important;
  }
  #home.approved-first-page .landing-bg{
    background-size:cover!important;
    background-position:58% center!important;
  }
  #home.approved-first-page .landing-content{
    left:var(--mobile-page-pad)!important;
    right:var(--mobile-page-pad)!important;
    top:auto!important;
    bottom:92px!important;
    width:auto!important;
    height:300px!important;
    padding:0!important;
  }
  #home.approved-first-page .reward-rotation{
    width:100%!important;
    height:300px!important;
    max-height:300px!important;
    padding:28px 22px 14px!important;
    margin:0!important;
  }
  #home.approved-first-page .reward-carousel{
    height:100%!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:9px!important;
  }
  #home.approved-first-page .home-reward-card:nth-child(n+4){display:none!important}
  #home.approved-first-page .carousel-arrow{
    width:44px!important;
    height:44px!important;
  }
  #home.approved-first-page .carousel-arrow.left{left:-12px!important}
  #home.approved-first-page .carousel-arrow.right{right:-12px!important}

  /* Keep the Begin Full Opening control visible on tablet/mobile. */
  #home.approved-first-page .start-panel{
    display:block!important;
    position:absolute!important;
    z-index:35!important;
    left:var(--mobile-page-pad)!important;
    right:var(--mobile-page-pad)!important;
    top:auto!important;
    bottom:24px!important;
    width:auto!important;
    height:54px!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
    pointer-events:auto!important;
  }
  #home.approved-first-page .start-panel::before,
  #home.approved-first-page .start-panel h3,
  #home.approved-first-page .start-panel p,
  #home.approved-first-page .start-panel small,
  #home.approved-first-page .start-panel .chest-value{display:none!important}
  #home.approved-first-page #start-experience{
    display:block!important;
    width:100%!important;
    min-height:54px!important;
    height:54px!important;
    pointer-events:auto!important;
    font-size:.72rem!important;
  }

  /* Captain's Chest showcase / prize loading stage */
  .experience-toolbar{
    left:8px!important;
    right:8px!important;
    top:max(8px,env(safe-area-inset-top))!important;
    justify-content:center!important;
    flex-wrap:wrap!important;
  }
  .showcase-title{
    left:var(--mobile-page-pad)!important;
    right:var(--mobile-page-pad)!important;
    top:68px!important;
    width:auto!important;
  }
  .showcase-title h2{font-size:clamp(1.8rem,5.6vw,2.8rem)!important}
  .spotlight-card{
    left:var(--mobile-page-pad)!important;
    right:var(--mobile-page-pad)!important;
    top:165px!important;
    width:auto!important;
    height:43dvh!important;
    min-height:350px!important;
    grid-template-columns:1fr 1fr!important;
    gap:14px!important;
    padding:14px!important;
  }
  .showcase-chest{
    right:-4vw!important;
    top:57dvh!important;
    width:54vw!important;
    height:27dvh!important;
  }
  .reward-strip{
    left:var(--mobile-page-pad)!important;
    right:var(--mobile-page-pad)!important;
    bottom:38px!important;
    height:14dvh!important;
    min-height:108px!important;
  }
  .sequence-status{
    left:var(--mobile-page-pad)!important;
    right:var(--mobile-page-pad)!important;
    bottom:11px!important;
    width:auto!important;
  }

  /* Captain's Chess tablet layout. Desktop composition is untouched. */
  .chess-duel-stage{
    overflow:auto!important;
    -webkit-overflow-scrolling:touch!important;
    padding-bottom:calc(22px + env(safe-area-inset-bottom))!important;
  }
  .duel-left-panel,.duel-right-panel{display:none!important}
  .duel-board-zone{
    position:absolute!important;
    inset:0!important;
    min-height:100dvh!important;
  }
  .duel-board-zone::before,.duel-board-zone::after{display:none!important}
  .duel-turn-banner{
    left:14px!important;
    right:14px!important;
    top:58px!important;
    width:auto!important;
    transform:none!important;
  }
  .duel-match-hud{
    left:14px!important;
    right:14px!important;
    top:103px!important;
    width:auto!important;
    height:auto!important;
    grid-template-columns:1fr minmax(250px,1.3fr) 1fr!important;
    gap:8px!important;
  }
  .duel-match-hud .duel-clock,.duel-inline-difficulty{min-width:0!important}
  .duel-board-frame{
    left:10px!important;
    right:10px!important;
    top:174px!important;
    bottom:82px!important;
    width:auto!important;
    height:auto!important;
  }
  .duel-board{
    width:min(calc(100dvh - 285px),88vw,680px)!important;
    max-width:680px!important;
    transform:none!important;
  }
  .duel-controls{
    left:14px!important;
    right:14px!important;
    bottom:calc(16px + env(safe-area-inset-bottom))!important;
    height:52px!important;
    grid-template-columns:1fr 1.45fr 1fr!important;
  }
  .duel-message{display:none!important}
  .duel-intro-overlay,
  .duel-result-overlay{
    padding:max(14px,env(safe-area-inset-top)) 14px max(14px,env(safe-area-inset-bottom))!important;
  }
  .duel-intro-card,.duel-result-card{
    width:min(760px,calc(100vw - 28px))!important;
    max-height:calc(100dvh - 28px)!important;
    overflow:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }

  /* ---------- Chat widget ---------- */
  .losttloot-chat-shell{
    right:max(12px,env(safe-area-inset-right))!important;
    bottom:max(12px,env(safe-area-inset-bottom))!important;
  }
  .losttloot-chat-panel{
    max-width:calc(100vw - 24px)!important;
    max-height:calc(100dvh - 88px)!important;
  }

  /* ---------- Policy / success pages ---------- */
  .policy-main{
    width:min(calc(100% - (var(--mobile-page-pad) * 2)),1000px)!important;
    padding-left:0!important;
    padding-right:0!important;
  }
  .policy-header{padding-left:var(--mobile-page-pad)!important;padding-right:var(--mobile-page-pad)!important}
}

@media (max-width:767px) {
  :root{--mobile-page-pad:12px;--mobile-header-h:66px}

  /* ---------- Phone header ---------- */
  .site-header{gap:7px!important}
  .site-header .brand img{width:44px!important;height:44px!important}
  .site-header .brand-copy small{display:none!important}
  .site-header .brand strong{font-size:.78rem!important;letter-spacing:.08em!important}
  .site-header .account-link{
    width:44px!important;
    min-width:44px!important;
    padding:0!important;
    font-size:0!important;
  }
  .site-header .account-link::after{content:'Account';font-size:.56rem!important;letter-spacing:0!important}
  .site-header .vault-button{
    min-width:54px!important;
    width:54px!important;
    height:44px!important;
    padding:0!important;
    gap:0!important;
  }
  .site-header .vault-button svg{width:23px!important;height:23px!important}
  .site-header .vault-button b{font-size:0!important;position:static!important}
  .site-header .vault-button b span{
    position:absolute!important;
    top:-6px!important;
    right:-6px!important;
    min-width:18px!important;
    height:18px!important;
    padding:0 4px!important;
    display:grid!important;
    place-items:center!important;
    border-radius:999px!important;
    background:linear-gradient(135deg,#d6a83e,#7d5318)!important;
    color:#090a0d!important;
    font-size:.62rem!important;
    font-family:Inter,system-ui,sans-serif!important;
    font-weight:900!important;
  }

  /* ---------- Phone home ---------- */
  .tv-hero{padding:82px 12px 48px!important}
  .tv-motion-toggle{top:10px!important;right:10px!important;transform:scale(.88);transform-origin:top right}
  .tv-copy h1{font-size:clamp(2.75rem,13vw,4.35rem)!important}
  .tv-copy p{font-size:.94rem!important;line-height:1.6!important}
  .tv-actions,.hero-actions{
    width:100%!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:9px!important;
  }
  .tv-actions a,.tv-actions button,.hero-actions .button{width:100%!important}
  .tv-collector-trust{justify-content:center!important;gap:8px 12px!important}
  .tv-showcase{min-height:480px!important;overflow:visible!important}
  .tv-featured-card{width:min(306px,78vw)!important}
  .tv-featured-image{height:276px!important}
  .tv-orbit-card{width:100px!important;opacity:.78!important}
  .tv-orbit-card.slot-0{left:-1%!important;top:3%!important}
  .tv-orbit-card.slot-1{right:-1%!important;top:5%!important}
  .tv-orbit-card.slot-2{left:-1%!important;bottom:2%!important}
  .tv-orbit-card.slot-3{right:-1%!important;bottom:1%!important}
  .tv-orbit-card.slot-4{display:none!important}
  .tv-vault-rings{width:min(420px,108vw)!important;height:min(420px,108vw)!important}
  .tv-hero-benefits{grid-template-columns:1fr!important}
  .tv-hero-benefits>div{border-right:0!important;border-top:1px solid rgba(224,172,65,.18)!important;min-height:auto!important}
  .tv-hero-benefits>div:first-child{border-top:0!important}

  .section{width:calc(100% - 24px)!important;padding-top:52px!important;padding-bottom:52px!important}
  .section-heading h2,.hall-section-heading h2{font-size:clamp(2rem,10vw,3.35rem)!important}
  .world-feature{padding:18px!important}
  .display-stack{transform:scale(.82)!important;margin-inline:-5%!important}

  /* ---------- Phone catalog ---------- */
  .catalog-category-shell{padding:12px!important}
  .catalog-departments,.catalog-subcategories{display:flex!important;flex-wrap:nowrap!important;gap:7px!important;padding-bottom:4px!important}
  .catalog-department,.catalog-subcategory{flex:0 0 auto!important}
  .shop-toolbar{grid-template-columns:1fr!important}
  .shop-results-line{align-items:flex-start!important;flex-direction:column!important}
  .product-grid{grid-template-columns:1fr!important;gap:14px!important}
  .store-product-card{max-width:560px!important;margin-inline:auto!important}
  .store-product-media{min-height:290px!important}
  .store-product-copy{padding:13px!important}
  .product-price-row{align-items:flex-start!important;flex-direction:column!important;gap:4px!important}

  /* ---------- Phone reserve ---------- */
  .reserve-featured-product{padding:13px!important;border-radius:16px!important}
  .reserve-featured-image{min-height:225px!important}
  .reserve-featured-image img{max-height:360px!important}
  .reserve-featured-price{align-items:flex-start!important;flex-direction:column!important;gap:4px!important}
  .reserve-featured-copy .gold-button,
  .reserve-featured-copy .button{width:100%!important}
  .order-card,.reserve-card{padding:18px!important}

  /* ---------- Phone product detail ---------- */
  .standalone-product-main{padding:80px 8px 32px!important}
  .product-page-layout,.bundle-listing-shell .product-page-layout{
    padding:8px!important;
    gap:12px!important;
    border-radius:14px!important;
  }
  .standalone-main-image,.bundle-listing-shell .standalone-main-image{
    min-height:330px!important;
    max-height:500px!important;
    padding:8px!important;
  }
  .standalone-thumbnails,.bundle-listing-shell .standalone-thumbnails{
    grid-template-columns:repeat(4,minmax(52px,1fr))!important;
    gap:7px!important;
  }
  .standalone-product-info{padding:14px!important}
  .standalone-product-info h1{font-size:clamp(2rem,10.7vw,3.2rem)!important}
  .standalone-facts{grid-template-columns:1fr!important}
  .standalone-price-row,
  .product-page-purchase-card>div{align-items:flex-start!important;flex-direction:column!important}
  .product-page-add{width:100%!important}
  .bundle-gallery-assurance{grid-template-columns:1fr 1fr!important}
  .bundle-info-cards,.bundle-items-grid,.product-assurance-grid{grid-template-columns:1fr!important}

  /* ---------- Phone forms ---------- */
  .form-shell,.collector-form{padding:16px!important}
  .form-tabs,.auth-tabs{justify-content:flex-start!important}
  .form-tab,.auth-tabs button{flex:0 0 auto!important;white-space:nowrap!important}
  .social-buttons{display:grid!important;grid-template-columns:1fr!important}

  /* ---------- Phone footer/cart/chat ---------- */
  .footer-links{grid-template-columns:1fr!important}
  .footer-bottom{flex-direction:column!important;align-items:flex-start!important}
  .cart-drawer{width:100vw!important;border-radius:0!important}
  .losttloot-chat-panel{
    right:0!important;
    bottom:58px!important;
    width:calc(100vw - 24px)!important;
    height:min(650px,calc(100dvh - 84px))!important;
  }
  .losttloot-chat-launcher{min-height:48px!important}

  /* ---------- Phone account ---------- */
  .account-header{min-height:64px!important;gap:8px!important}
  .account-top-nav{gap:6px!important}
  .account-hero{padding-top:38px!important;padding-bottom:28px!important}
  .auth-card{padding:18px 14px!important}
  .social-auth{grid-template-columns:1fr!important}
  .dashboard-nav{padding:12px!important}
  .dashboard-nav-list{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:7px!important}
  .dashboard-nav-list button{min-height:58px!important;padding:8px!important;text-align:center!important;justify-content:center!important}
  .dashboard-content{padding:16px 10px!important}
  .dashboard-discovery{padding:20px 14px!important}
  .dashboard-summary-grid,
  .treasure-quick-grid,
  .address-grid,
  .account-form-grid{grid-template-columns:1fr!important}
  .profile-settings-layout{gap:14px!important}
  .avatar-editor-card{width:calc(100vw - 20px)!important;max-height:calc(100dvh - 20px)!important;overflow:auto!important}

  /* ---------- Phone Treasure Hall ---------- */
  .prestige-shell,.collector-profile-shell{width:calc(100% - 16px)!important}
  .prestige-hero{padding:44px 0 38px!important;min-height:0!important}
  .prestige-hero h1{font-size:clamp(2.8rem,13.5vw,4.35rem)!important}
  .prestige-hero__actions{display:grid!important;grid-template-columns:1fr!important;width:100%!important}
  .prestige-button{width:100%!important}
  .prestige-hero__visual{min-height:230px!important}
  .prestige-hero__visual-frame{min-height:225px!important;border-radius:16px!important}
  .prestige-hero__visual-frame img{min-height:225px!important;object-fit:cover!important}
  .prestige-section{padding:44px 0!important}
  .prestige-rank-card,.prestige-rank-card--wide{
    grid-template-columns:1fr!important;
    padding:16px 10px!important;
    text-align:center!important;
  }
  .prestige-rank-card__facts{grid-template-columns:1fr!important}
  .prestige-crest--large{--crest-size:195px!important}
  .prestige-crest--captain{--crest-size:225px!important}
  .prestige-purchase-card{grid-template-columns:1fr!important;padding:10px!important}
  .prestige-purchase-card__product{height:230px!important}
  .prestige-purchase-card__rank{grid-column:auto!important}
  .prestige-crest--history{--crest-size:145px!important}
  .collector-profile-hero{grid-template-columns:1fr!important;text-align:center!important;justify-items:center!important}
  .collector-profile-avatar{width:130px!important;height:130px!important}

  /* ---------- Phone Captain's Chest home ---------- */
  .topbar{height:60px!important;min-height:60px!important;padding-inline:10px!important}
  .topbar .brand{font-size:.72rem!important;letter-spacing:.13em!important}
  .top-actions .pill:not(.live-account-link){display:none!important}
  .top-actions .live-account-link{min-width:86px!important;padding-inline:9px!important;font-size:.5rem!important}

  #home.approved-first-page{
    min-height:max(820px,100svh)!important;
    height:max(820px,100svh)!important;
    padding-top:60px!important;
  }
  #home.approved-first-page .landing-bg{
    background-size:auto 100%!important;
    background-position:58% center!important;
  }
  #home.approved-first-page .landing-content{
    left:12px!important;
    right:12px!important;
    bottom:92px!important;
    height:314px!important;
  }
  #home.approved-first-page .reward-rotation{
    height:314px!important;
    max-height:314px!important;
    padding:28px 14px 12px!important;
  }
  #home.approved-first-page .reward-carousel{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
  #home.approved-first-page .home-reward-card:nth-child(n+3){display:none!important}
  #home.approved-first-page .home-reward-card .home-media{height:72%!important}
  #home.approved-first-page .panel-heading{max-width:calc(100% - 50px)!important;font-size:.52rem!important}
  #home.approved-first-page .start-panel{left:12px!important;right:12px!important;bottom:22px!important}

  /* ---------- Phone Captain's Chest showcase ---------- */
  .experience-toolbar{left:6px!important;right:6px!important;top:6px!important;gap:4px!important}
  .experience-toolbar button{min-height:34px!important;height:34px!important;padding-inline:7px!important;font-size:.46rem!important}
  .showcase-title{left:12px!important;right:12px!important;top:54px!important}
  .showcase-title h2{font-size:1.65rem!important}
  .showcase-title p{display:none!important}
  .spotlight-card{
    left:10px!important;
    right:10px!important;
    top:126px!important;
    height:48dvh!important;
    min-height:390px!important;
    display:block!important;
    padding:10px!important;
  }
  .spotlight-media{height:64%!important;padding:8px!important}
  .spotlight-copy h3{font-size:1.35rem!important;margin:7px 0 4px!important}
  .spotlight-copy p{display:none!important}
  .showcase-chest{top:58dvh!important;right:-12vw!important;width:76vw!important;height:26dvh!important}
  .reward-strip{left:10px!important;right:10px!important;height:13.5dvh!important;min-height:102px!important;bottom:35px!important;padding:7px!important}
  .strip-card{flex-basis:92px!important}
  .sequence-status{left:10px!important;right:10px!important;bottom:10px!important}

  /* ---------- Phone Captain's Chess ---------- */
  .duel-turn-banner{
    top:50px!important;
    left:8px!important;
    right:8px!important;
    height:34px!important;
    font-size:.62rem!important;
  }
  .duel-match-hud{
    top:91px!important;
    left:8px!important;
    right:8px!important;
    grid-template-columns:1fr 1fr!important;
    gap:6px!important;
  }
  .duel-inline-difficulty{
    grid-column:1/-1!important;
    grid-row:2!important;
    height:50px!important;
    padding:4px!important;
  }
  .duel-match-hud .duel-clock{height:50px!important;padding:4px 6px!important}
  .duel-match-hud .duel-clock b{font-size:1.32rem!important}
  .duel-difficulty-choices{gap:4px!important}
  .duel-difficulty-choice{min-width:0!important;padding:4px 3px!important}
  .duel-difficulty-choice small{display:none!important}
  .duel-board-frame{
    top:202px!important;
    bottom:112px!important;
    left:5px!important;
    right:5px!important;
  }
  .duel-board{
    width:min(94vw,calc(100dvh - 332px),540px)!important;
    border-width:5px!important;
    transform:none!important;
  }
  .duel-piece{font-size:clamp(1.7rem,10vw,3.1rem)!important}
  .duel-controls{
    left:8px!important;
    right:8px!important;
    bottom:calc(8px + env(safe-area-inset-bottom))!important;
    height:94px!important;
    grid-template-columns:1fr 1fr!important;
    gap:6px!important;
  }
  .duel-controls #duel-begin{grid-column:1/-1!important;grid-row:1!important}
  .duel-controls button{min-height:42px!important;font-size:.56rem!important}
  .duel-intro-overlay,.duel-result-overlay{padding:48px 7px 7px!important}
  .duel-intro-card,.duel-result-card{
    width:calc(100vw - 14px)!important;
    max-height:calc(100dvh - 54px)!important;
    padding:15px 11px!important;
  }
  .duel-intro-card h2,.duel-result-card h2{font-size:clamp(1.8rem,8vw,2.55rem)!important}
  .duel-intro-card p,.duel-result-card p{font-size:.79rem!important;line-height:1.5!important}
  .duel-intro-settings{grid-template-columns:1fr!important}
  .duel-intro-difficulty-choices{gap:4px!important}
  .duel-intro-difficulty .duel-difficulty-choice{min-height:50px!important}

  .live-production-badge{width:calc(100% - 20px)!important;min-width:0!important}

  /* ---------- Phone policy pages ---------- */
  .policy-main{width:calc(100% - 24px)!important;padding-top:42px!important;padding-bottom:50px!important}
}

@media (max-width:430px) {
  .site-header .account-link{display:none!important}
  .site-header .brand strong{font-size:.72rem!important}
  .site-header .vault-button{margin-left:auto!important}
  .tv-featured-card{width:82vw!important}
  .tv-orbit-card{width:92px!important}
  .prestige-crest--large{--crest-size:185px!important}
  .prestige-crest--captain{--crest-size:215px!important}
  .duel-board{width:min(96vw,calc(100dvh - 342px),500px)!important}
}

/* iPhone landscape: keep controls visible and use the extra width efficiently. */
@media (max-width:950px) and (max-height:600px) and (orientation:landscape) {
  .site-header{--mobile-header-h:58px;min-height:58px!important}
  .site-header .brand img{width:40px!important;height:40px!important}
  .product-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .store-product-media{min-height:220px!important}
  .duel-turn-banner{top:42px!important}
  .duel-match-hud{top:80px!important}
  .duel-board-frame{top:138px!important;bottom:66px!important}
  .duel-board{width:min(calc(100dvh - 210px),62vw,430px)!important}
  .duel-controls{height:48px!important;grid-template-columns:1fr 1.5fr 1fr!important;bottom:6px!important}
  .duel-controls #duel-begin{grid-column:auto!important;grid-row:auto!important}
}

@media (prefers-reduced-motion:reduce) and (max-width:1366px) {
  html{scroll-behavior:auto!important}
  .tv-particle,.tv-route,.tv-compass,.tv-x-mark path,.tv-vault-rings i,
  .tv-featured-card,.tv-orbit-card,.tv-scroll-cue span,.tv-reserve-track,
  .media-glow,.duel-cinematic-bg::after{animation:none!important}
}

/* ================================================================
   V12.6.10 — CAPTAIN'S CHEST MOBILE USABILITY CORRECTION
   Desktop (>1000px) is intentionally untouched.
   Tablet/phone receive a true vertical composition so the chest,
   reward rotation and game/opening actions never overlap each other.
   ================================================================ */

.mobile-chess-entry{display:none}

@media (max-width:1024px), (hover:none) and (pointer:coarse) and (max-width:1366px) {
  /* Keep the navigation compact while restoring the actual Play Chess control. */
  .captains-live-page .topbar{
    height:64px!important;
    min-height:64px!important;
    grid-template-columns:minmax(0,1fr) auto!important;
    gap:8px!important;
    padding:0 12px!important;
    background:rgba(1,5,8,.97)!important;
    backdrop-filter:blur(12px)!important;
  }
  .captains-live-page .topbar .brand{
    min-width:0!important;
    gap:8px!important;
    font-size:clamp(.66rem,2.6vw,.82rem)!important;
    letter-spacing:.18em!important;
    white-space:nowrap!important;
  }
  .captains-live-page .topbar .brand img{width:36px!important;height:36px!important}
  .captains-live-page .topbar nav{display:none!important}
  .captains-live-page .top-actions{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:0!important;
    min-width:0!important;
  }
  .captains-live-page .top-actions .pill{display:none!important}
  .captains-live-page #skip-to-game{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:auto!important;
    max-width:128px!important;
    min-height:40px!important;
    height:40px!important;
    padding:0 11px!important;
    border:1px solid rgba(229,181,71,.72)!important;
    background:linear-gradient(180deg,rgba(30,21,8,.98),rgba(7,10,13,.98))!important;
    color:#f1c966!important;
    font-size:.52rem!important;
    line-height:1.05!important;
    letter-spacing:.06em!important;
    white-space:nowrap!important;
    box-shadow:0 8px 22px rgba(0,0,0,.35)!important;
  }
  .captains-live-page #skip-to-game:disabled{opacity:.42!important;cursor:not-allowed!important}

  /* Convert the desktop background-overlaid composition to a true mobile flow. */
  #home.approved-first-page{
    display:block!important;
    width:100%!important;
    min-height:0!important;
    height:auto!important;
    padding:64px 0 24px!important;
    overflow:visible!important;
    background:
      radial-gradient(circle at 50% 0,rgba(62,39,9,.14),transparent 44%),
      linear-gradient(180deg,#020509,#03070b 68%,#020509)!important;
  }
  #home.approved-first-page .landing-bg{
    position:relative!important;
    inset:auto!important;
    display:block!important;
    width:100%!important;
    height:clamp(330px,55vw,430px)!important;
    min-height:0!important;
    max-height:none!important;
    transform:none!important;
    background-image:url('assets/captains-chest/luxury-hero-4k.webp')!important;
    background-size:cover!important;
    background-position:70% center!important;
    background-repeat:no-repeat!important;
    border-bottom:1px solid rgba(218,169,65,.38)!important;
    box-shadow:0 18px 46px rgba(0,0,0,.56)!important;
  }
  #home.approved-first-page .landing-bg::before{
    content:"CAPTAIN'S\A CHEST"!important;
    display:block!important;
    position:absolute!important;
    z-index:2!important;
    left:clamp(16px,4vw,34px)!important;
    top:clamp(25px,5vw,44px)!important;
    width:46%!important;
    color:#f7e8c5!important;
    font-family:Georgia,"Times New Roman",serif!important;
    font-size:clamp(2rem,6.8vw,4rem)!important;
    font-weight:700!important;
    line-height:.88!important;
    letter-spacing:.01em!important;
    white-space:pre-line!important;
    text-shadow:0 4px 8px #000,0 0 30px rgba(222,170,63,.25)!important;
    pointer-events:none!important;
  }
  #home.approved-first-page .landing-bg::after{
    content:"THE LOSTTLOOT TREASURE EXPERIENCE"!important;
    display:block!important;
    position:absolute!important;
    z-index:2!important;
    left:clamp(17px,4vw,35px)!important;
    top:clamp(118px,16vw,170px)!important;
    width:44%!important;
    color:#e0ad43!important;
    font-size:clamp(.47rem,1.55vw,.67rem)!important;
    font-weight:900!important;
    line-height:1.4!important;
    letter-spacing:.12em!important;
    text-transform:uppercase!important;
    pointer-events:none!important;
  }

  #home.approved-first-page .landing-content{
    position:relative!important;
    z-index:5!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    bottom:auto!important;
    width:calc(100% - 24px)!important;
    height:auto!important;
    margin:18px auto 0!important;
    padding:0!important;
    display:block!important;
    pointer-events:auto!important;
  }
  #home.approved-first-page .reward-rotation{
    position:relative!important;
    inset:auto!important;
    width:100%!important;
    height:310px!important;
    min-height:310px!important;
    max-height:none!important;
    margin:0!important;
    padding:30px 18px 14px!important;
    overflow:visible!important;
    border-radius:4px!important;
  }
  #home.approved-first-page .reward-carousel{
    height:100%!important;
    min-height:0!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:10px!important;
  }
  #home.approved-first-page .home-reward-card:nth-child(n+4){display:none!important}
  #home.approved-first-page .home-reward-card .home-media{height:auto!important;min-height:0!important}
  #home.approved-first-page .carousel-arrow{width:44px!important;height:44px!important}
  #home.approved-first-page .carousel-arrow.left{left:-8px!important}
  #home.approved-first-page .carousel-arrow.right{right:-8px!important}

  /* Opening and Chess buttons are now in normal flow and cannot be covered. */
  #home.approved-first-page .start-panel{
    display:block!important;
    position:relative!important;
    z-index:60!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    bottom:auto!important;
    width:calc(100% - 24px)!important;
    height:auto!important;
    margin:16px auto 0!important;
    padding:14px!important;
    border:1px solid rgba(216,165,62,.36)!important;
    border-radius:16px!important;
    background:linear-gradient(180deg,rgba(6,12,17,.98),rgba(2,7,11,.98))!important;
    box-shadow:0 18px 42px rgba(0,0,0,.42)!important;
    text-align:center!important;
    pointer-events:auto!important;
  }
  #home.approved-first-page .start-panel::before,
  #home.approved-first-page .start-panel h3,
  #home.approved-first-page .start-panel>p,
  #home.approved-first-page .start-panel small,
  #home.approved-first-page .start-panel .chest-value{display:none!important}
  #home.approved-first-page #start-experience,
  #home.approved-first-page #mobile-chess-entry{
    width:100%!important;
    min-height:54px!important;
    height:auto!important;
    padding:13px 16px!important;
    border-radius:10px!important;
    font-size:.72rem!important;
    font-weight:900!important;
    letter-spacing:.075em!important;
    text-transform:uppercase!important;
    pointer-events:auto!important;
  }
  #home.approved-first-page #start-experience{display:block!important}
  #home.approved-first-page #mobile-chess-entry{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    margin-top:9px!important;
    border:1px solid rgba(226,176,66,.62)!important;
    background:linear-gradient(180deg,#111820,#05090d)!important;
    color:#f1c96b!important;
    box-shadow:inset 0 0 18px rgba(225,171,59,.06)!important;
    cursor:pointer!important;
  }
  #home.approved-first-page #mobile-chess-entry:disabled{opacity:.42!important;cursor:not-allowed!important}
  #home.approved-first-page .captains-live-status{
    display:block!important;
    min-height:0!important;
    margin:10px 3px 0!important;
    font-size:.62rem!important;
    line-height:1.45!important;
  }
  #home.approved-first-page .live-rules-link{margin-top:9px!important}

  /* The verification pill used to sit on top of the action button on iPhone. */
  #home.approved-first-page .live-production-badge{
    position:relative!important;
    z-index:20!important;
    left:auto!important;
    right:auto!important;
    top:auto!important;
    bottom:auto!important;
    transform:none!important;
    width:calc(100% - 24px)!important;
    min-width:0!important;
    min-height:44px!important;
    margin:14px auto 0!important;
    padding:9px 13px!important;
    border-radius:14px!important;
    flex-wrap:wrap!important;
    gap:6px 10px!important;
    font-size:.5rem!important;
  }
}

@media (max-width:680px) {
  #home.approved-first-page .landing-bg{
    height:330px!important;
    background-position:71% center!important;
  }
  #home.approved-first-page .landing-bg::before{
    left:16px!important;
    top:24px!important;
    width:44%!important;
    font-size:clamp(2rem,10vw,2.9rem)!important;
  }
  #home.approved-first-page .landing-bg::after{
    left:17px!important;
    top:118px!important;
    width:42%!important;
    font-size:.46rem!important;
  }
  #home.approved-first-page .landing-content{width:calc(100% - 20px)!important;margin-top:14px!important}
  #home.approved-first-page .reward-rotation{
    height:330px!important;
    min-height:330px!important;
    padding:28px 12px 12px!important;
  }
  #home.approved-first-page .reward-carousel{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
  #home.approved-first-page .home-reward-card:nth-child(n+3){display:none!important}
  #home.approved-first-page .home-reward-card strong{font-size:.68rem!important}
  #home.approved-first-page .home-reward-card small{font-size:.61rem!important}
  #home.approved-first-page .home-reward-card em{font-size:.54rem!important}
  #home.approved-first-page .start-panel,
  #home.approved-first-page .live-production-badge{width:calc(100% - 20px)!important}
}

@media (max-width:430px) {
  .captains-live-page .topbar .brand{font-size:.68rem!important;letter-spacing:.15em!important}
  .captains-live-page .topbar .brand img{width:34px!important;height:34px!important}
  .captains-live-page #skip-to-game{max-width:112px!important;padding:0 8px!important;font-size:.48rem!important}
  #home.approved-first-page .landing-bg{height:310px!important;background-position:72% center!important}
  #home.approved-first-page .landing-bg::before{font-size:2.25rem!important;top:22px!important}
  #home.approved-first-page .landing-bg::after{top:105px!important;width:40%!important}
  #home.approved-first-page .reward-rotation{height:318px!important;min-height:318px!important}
}


/* Losttloot V12.6.18 — phone/tablet badge fitting */
@media (max-width: 900px){
  .prestige-rank-card--legendary .prestige-crest--large{--crest-size:190px!important}
  .prestige-rank-card--legendary .prestige-crest__stage{padding:8px!important}
}
@media (max-width: 640px){
  .prestige-rank-card,.prestige-rank-card--wide{
    gap:12px!important;
  }
  .prestige-rank-card .prestige-crest{
    width:100%!important;
    justify-self:center!important;
  }
  .prestige-crest--large{--crest-size:180px!important}
  .prestige-rank-card--legendary .prestige-crest--large{--crest-size:168px!important}
  .prestige-rank-card--legendary .prestige-crest__ring{inset:16%!important}
  .prestige-rank-card--legendary .prestige-crest__ring--two{inset:8%!important}
  .prestige-crest--captain{--crest-size:210px!important}
  .prestige-rank-card--captain .prestige-crest__stage{
    width:min(100%, 320px)!important;
    min-height:210px!important;
  }
}


/* Losttloot V12.6.19 — legendary badge mobile containment */
@media (max-width: 900px){
  .prestige-rank-card--legendary{padding-left:28px!important}
  .prestige-rank-card--legendary .prestige-crest--large{--crest-size:178px!important}
  .prestige-rank-card--legendary .prestige-crest__stage{
    width:calc(var(--crest-size) + 16px)!important;
    height:calc(var(--crest-size) + 16px)!important;
  }
  .prestige-rank-card--legendary .prestige-crest img{width:87%!important;height:87%!important}
}
@media (max-width: 640px){
  .prestige-rank-card--legendary{padding-left:22px!important}
  .prestige-rank-card--legendary .prestige-crest--large{--crest-size:156px!important}
  .prestige-rank-card--legendary .prestige-crest__stage{
    width:calc(var(--crest-size) + 12px)!important;
    height:calc(var(--crest-size) + 12px)!important;
  }
  .prestige-rank-card--legendary .prestige-crest img{width:85%!important;height:85%!important}
}
