
/* FIX: Home jump + nav matches top content width */
html{
  overflow-y:scroll !important;
  scrollbar-gutter:stable both-edges;
}
body{
  overflow-x:hidden;
}
/* Same width as .app (max 1180) — centered, no full-bleed stretch */
.bottom-nav{
  /* width/position finalized at end of file — avoid transform containing-block bugs */
  box-sizing:border-box !important;
}
.bottom-nav .nav-item{
  padding-top:6px !important;
  padding-bottom:6px !important;
}
.cart-bar{
  left:50% !important;
  right:auto !important;
  transform:translateX(-50%) !important;
  width:min(710px, calc(100% - 24px)) !important;
  max-width:710px !important;
  margin:0 !important;
}
html,body,.content,.screen{overflow-anchor:none}

    :root{
      /* Brand — kept for backward compat; design-system.css provides full scale */
      --navy:#0b2e6f;
      --navy-2:#15448d;
      --orange:#ff8a00;
      --orange-2:#ffb12a;
      --bg:#f6f7fa;
      --card:#ffffff;
      --text:#15233a;
      --muted:#6f7c91;
      --line:#e6e9ef;
      --success:#16894f;
      --danger:#d83a3a;
      --shadow:0 10px 28px rgba(18,38,72,.08);
      --radius:18px;
      --radius-sm:12px;
      --radius-md:16px;
      --space:4px;
    }
    *{box-sizing:border-box}
    html,body{margin:0;background:var(--bg);color:var(--text);font-family:"Noto Sans Myanmar","Inter","Plus Jakarta Sans",system-ui,-apple-system,"Segoe UI",Arial,sans-serif}
    body{min-height:100vh;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}
    button,input,textarea,select{font:inherit}
    button{border:0;cursor:pointer;transition:background-color .2s cubic-bezier(.22,1,.36,1),color .2s cubic-bezier(.22,1,.36,1),box-shadow .2s cubic-bezier(.22,1,.36,1),transform .15s cubic-bezier(.22,1,.36,1)}
    button:active:not(:disabled){transform:scale(.98)}
    .app{width:100%;max-width:1180px;margin:0 auto;min-height:100vh;background:var(--bg)}
    .top{position:sticky;top:0;z-index:40;background:rgba(255,255,255,.92);backdrop-filter:blur(14px) saturate(1.2);-webkit-backdrop-filter:blur(14px) saturate(1.2);border-bottom:1px solid var(--line)}
    .top-inner{padding:14px 22px 12px}
    .brand-row{display:flex;align-items:center;gap:14px}
    .brand{display:flex;align-items:center;gap:10px;min-width:220px;flex:0 0 auto}
    .brand img{width:54px;height:54px;object-fit:contain;border-radius:12px;background:#fff}
    .brand-copy{line-height:1.15}
    .brand-name{font-family:"Plus Jakarta Sans","Noto Sans Myanmar","Inter",system-ui,sans-serif;font-size:20px;font-weight:800;letter-spacing:.02em;color:var(--navy)}
    .brand-sub{font-size:10px;color:var(--orange);font-weight:700;margin-top:3px;letter-spacing:.03em}
    .location{font-size:13px;color:var(--navy);white-space:nowrap;font-weight:800;display:flex;align-items:center;gap:5px;margin-left:auto}
    .icon-btn{width:42px;height:42px;border-radius:13px;background:#fff;border:1px solid var(--line);display:grid;place-items:center;color:var(--navy);font-size:20px;position:relative}
    .badge{position:absolute;right:-2px;top:-2px;min-width:18px;height:18px;padding:0 5px;border-radius:999px;background:var(--danger);color:#fff;font-size:10px;font-weight:800;display:grid;place-items:center}
    .search-row{display:flex;gap:8px;margin:0;flex:1;max-width:620px}
    .search{flex:1;display:flex;align-items:center;gap:8px;padding:11px 13px;border:1px solid var(--line);border-radius:15px;background:#f8fafc}
    .search input{width:100%;border:0;outline:0;background:transparent;color:var(--text);font-size:14px}
    .content{padding:18px 22px 94px}
    .screen{display:none}.screen.active{display:block}
    .hero{border-radius:22px;color:#fff;box-shadow:var(--shadow);overflow:hidden;position:relative;min-height:250px;background:#0b2e6f}
    .hero-track{display:flex;width:100%;transition:transform .82s cubic-bezier(.22,.61,.36,1);will-change:transform}.hero-slide.has-image{background-size:cover;background-position:center}.hero-slide.has-image:before{content:"";position:absolute;inset:0;background:linear-gradient(90deg,rgba(5,29,74,.88) 0%,rgba(5,29,74,.58) 48%,rgba(5,29,74,.08) 100%);z-index:0}
    .hero-slide{min-width:100%;min-height:250px;padding:30px 54px;position:relative;display:flex;align-items:center;overflow:hidden;background:linear-gradient(120deg,#0b2e6f,#154d98 54%,#ff9a13)}
    .hero-slide:after{content:"";position:absolute;right:-70px;bottom:-100px;width:260px;height:260px;border-radius:50%;background:rgba(255,255,255,.12)}
    .hero-copy{position:relative;z-index:2;max-width:55%}.hero h1{margin:0;font-size:30px;line-height:1.25}.hero p{margin:10px 0 0;font-size:14px;opacity:.95}.hero .hero-btn{margin-top:16px;background:#ffbf19;color:#111;font-weight:900;padding:11px 18px;border-radius:13px}
    .hero-art{position:absolute;right:3%;bottom:0;font-size:120px;opacity:.96;z-index:1}.hero-arrow{position:absolute;top:50%;transform:translateY(-50%);z-index:4;width:38px;height:38px;border-radius:50%;background:#fff;color:var(--navy);font-size:24px;box-shadow:0 5px 16px rgba(0,0,0,.15)}.hero-arrow.prev{left:10px}.hero-arrow.next{right:10px}.hero-dots{position:absolute;bottom:12px;left:50%;transform:translateX(-50%);z-index:4;display:flex;gap:7px}.hero-dot{width:9px;height:9px;border-radius:50%;background:rgba(255,255,255,.65);padding:0}.hero-dot.active{background:#fff;transform:scale(1.2)}
    .section-head{display:flex;align-items:center;justify-content:space-between;margin:24px 2px 14px}.section-head h2{margin:0;font-size:18px;font-family:"Plus Jakarta Sans",Inter,system-ui,sans-serif;font-weight:800;letter-spacing:-.01em;line-height:1.25}.section-head button{background:transparent;color:var(--navy);font-weight:600;font-size:12px}
    .cat-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:14px}
    .cat{background:var(--card);border:1px solid var(--line);border-radius:16px;padding:12px 8px;text-align:center;min-height:116px;box-shadow:0 5px 18px rgba(10,33,69,.04);position:relative}.cat-image{display:block;width:100%;height:72px;object-fit:cover;object-position:center;border-radius:12px;margin:0 auto;overflow:hidden}.cat span{line-height:1.2}.cat-arrow{position:absolute!important;right:9px;bottom:9px;margin:0!important;width:22px;height:22px;border-radius:50%;background:#eaf2ff;color:#1761c7;font-size:13px!important;display:grid!important;place-items:center;font-weight:900!important}
    .cat .emoji{width:58px;height:58px;margin:0 auto;display:grid;place-items:center;border-radius:18px;background:linear-gradient(145deg,#f7fbff,#e8f0fb);box-shadow:inset 0 1px 0 rgba(255,255,255,.9),0 7px 18px rgba(19,55,105,.08);font-size:0;position:relative;overflow:hidden}.cat .emoji:after{content:"";position:absolute;inset:auto -10px -18px;width:72px;height:38px;border-radius:50%;background:rgba(255,167,42,.10)}.cat .emoji svg{width:34px;height:34px;position:relative;z-index:1}.cat span{display:block;margin-top:7px;font-size:12px;font-weight:800}.cat small{display:block;color:var(--muted);font-size:9px;margin-top:3px}
    .more-row{display:grid;grid-template-columns:repeat(5,1fr);gap:12px;margin-top:12px}
    .more{padding:11px;background:#eef3fb;border:1px solid #dce5f2;border-radius:14px;font-size:12px;font-weight:800;color:var(--navy);text-align:center}
    .banner-row{display:grid;grid-template-columns:1.2fr .8fr;gap:10px;margin-top:14px}.banner{border-radius:18px;padding:15px;min-height:130px;color:#fff;position:relative;overflow:hidden}.banner h3{margin:0;font-size:16px;max-width:76%}.banner p{font-size:11px;margin:7px 0 0;max-width:76%;opacity:.92}.banner button{margin-top:10px;background:rgba(255,255,255,.96);color:var(--navy);padding:8px 10px;border-radius:10px;font-weight:800;font-size:11px}.banner-a{background:linear-gradient(135deg,#0b2e6f,#215da6)}.banner-b{background:linear-gradient(135deg,#ff8a00,#ffbb35)}
    .shop-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px}.shop-card{background:#fff;border:1px solid var(--line);border-radius:18px;overflow:hidden;box-shadow:0 8px 24px rgba(10,33,69,.06);transition:box-shadow .22s cubic-bezier(.22,1,.36,1),transform .2s cubic-bezier(.22,1,.36,1)}.shop-card:hover{box-shadow:0 12px 32px rgba(10,33,69,.09)}
    .shop-thumb,.prod-thumb{background:linear-gradient(135deg,#eaf0f8,#dfe7f4);display:grid;place-items:center;color:var(--navy);font-size:34px}.shop-thumb{height:120px}.prod-thumb{width:76px;height:76px;border-radius:14px;flex:none}
    .shop-body{padding:11px}.shop-name{font-size:14px;font-weight:900}.shop-meta{font-size:11px;color:var(--muted);margin-top:4px}.rating{color:#d98100;font-weight:800;font-size:11px}.shop-actions{display:flex;justify-content:space-between;align-items:center;margin-top:8px}.open{font-size:10px;color:var(--success);font-weight:800}
    .screen-title{display:flex;align-items:center;gap:8px;margin:2px 0 14px}.screen-title button{width:38px;height:38px;border-radius:12px;background:#fff;border:1px solid var(--line);color:var(--navy)}.screen-title h2{margin:0;font-size:20px}.subtle{font-size:11px;color:var(--muted);margin:-7px 0 14px 46px}
    .list{display:flex;flex-direction:column;gap:10px}.shop-row{display:flex;align-items:center;gap:10px;padding:12px;background:#fff;border:1px solid var(--line);border-radius:16px}.shop-avatar{width:62px;height:62px;border-radius:14px;background:linear-gradient(135deg,#e7eef9,#d1ddf0);display:grid;place-items:center;font-size:26px;flex:none}.shop-row-main{min-width:0;flex:1}.shop-row-main b{font-size:14px}.shop-row-main p{margin:4px 0 0;color:var(--muted);font-size:11px}.shop-row-right{text-align:right}.chev{color:var(--muted);font-size:18px}
    .chips{display:flex;gap:7px;overflow:auto;padding-bottom:4px;margin-bottom:12px}.chip{white-space:nowrap;padding:8px 11px;border-radius:999px;border:1px solid var(--line);background:#fff;color:var(--muted);font-size:11px;font-weight:800}.chip.active{background:var(--navy);color:#fff;border-color:var(--navy)}
    #shopChips{display:flex;flex-wrap:nowrap;overflow-x:auto;overflow-y:hidden;scrollbar-width:thin;-webkit-overflow-scrolling:touch;touch-action:pan-x;padding:4px 2px 10px;gap:8px;white-space:nowrap}#shopChips .chip{flex:0 0 auto}#shopChips::-webkit-scrollbar{height:5px}
    .buyer-limit-card{background:#fff;border:1px solid var(--line);border-radius:15px;padding:12px;margin:0 0 12px}.buyer-limit-row{display:flex;justify-content:space-between;gap:10px;padding:8px 10px;border-radius:10px;margin-bottom:6px;font-size:12px}.buyer-limit-row.normal{background:#edf9f0}.buyer-limit-row.verified{background:#fff8dc}.buyer-limit-card small{display:block;color:var(--muted);font-size:10px;line-height:1.5}.rider-payment-card{background:#f4f8ff;border:1px solid #d7e4f7;border-radius:14px;padding:12px;font-size:12px}.rider-payment-card b{display:block;margin-bottom:7px}.rider-payment-card .payment-line{padding:5px 0}.rider-payment-card .payment-line strong{margin-right:6px}
    .product-list{display:flex;flex-direction:column;gap:10px}.product-row{display:flex;gap:10px;padding:12px;background:#fff;border:1px solid var(--line);border-radius:16px}.product-main{flex:1;min-width:0}.product-main b{font-size:14px}.price{margin-top:4px;font-weight:900;color:var(--navy);font-size:14px}.desc{font-size:10px;color:var(--muted);margin-top:3px}.qty{display:flex;align-items:center;gap:8px;margin-top:9px}.qty button{width:30px;height:30px;border-radius:10px;background:#f2f5f9;border:1px solid var(--line);color:var(--navy);font-weight:900}.qty span{min-width:18px;text-align:center;font-weight:800}
    .shop-head{background:#fff;border:1px solid var(--line);border-radius:18px;padding:14px}.shop-head-top{display:flex;gap:10px;align-items:center}.shop-logo{width:62px;height:62px;border-radius:14px;background:linear-gradient(135deg,var(--navy),#3d6bb6);color:#fff;display:grid;place-items:center;font-size:26px;font-weight:900}.shop-head h3{margin:0;font-size:18px}.shop-head p{margin:4px 0 0;color:var(--muted);font-size:11px}.shop-head-bottom{display:flex;gap:12px;margin-top:10px;flex-wrap:wrap}.mini{font-size:10px;color:var(--muted)}
    .cart-bar{position:fixed;left:50%;bottom:70px;transform:translateX(-50%);width:min(710px,calc(100% - 24px));background:var(--navy);color:#fff;border-radius:16px;padding:12px 14px;display:flex;align-items:center;justify-content:space-between;box-shadow:0 12px 32px rgba(11,46,111,.26);z-index:45;display:none}.cart-bar.visible{display:flex}.cart-bar button{background:var(--navy-2);color:#fff;font-weight:900;padding:10px 14px;border-radius:11px}
    .empty{padding:36px 18px;text-align:center;color:var(--muted)}
    .cart-items{display:flex;flex-direction:column;gap:10px}.cart-item{display:flex;gap:10px;padding:12px;background:#fff;border:1px solid var(--line);border-radius:16px}.cart-info{flex:1;min-width:0}.cart-info b{font-size:13px}.line-total{font-weight:900;color:var(--navy);margin-top:5px}.remove{background:transparent;color:var(--danger);font-size:18px}.totals{margin-top:14px;background:#fff;border:1px solid var(--line);border-radius:16px;padding:14px}.total-row{display:flex;justify-content:space-between;margin:8px 0;font-size:12px;color:var(--muted)}.total-row.total{font-size:16px;color:var(--navy);font-weight:900;padding-top:8px;border-top:1px solid var(--line)}.primary{width:100%;padding:12px;border-radius:13px;background:var(--navy);color:#fff;font-weight:900;margin-top:12px}
    .account-card{background:#fff;border:1px solid var(--line);border-radius:18px;padding:16px}.profile{display:flex;gap:12px;align-items:center}.avatar{width:58px;height:58px;border-radius:50%;background:var(--navy);color:#fff;display:grid;place-items:center;font-weight:900;font-size:20px}.account-card h3{margin:0;font-size:17px}.account-card p{margin:4px 0 0;color:var(--muted);font-size:11px}.account-list{display:flex;flex-direction:column;margin-top:12px}.account-btn{display:flex;justify-content:space-between;align-items:center;padding:14px 4px;border-top:1px solid var(--line);background:#fff;color:var(--text);font-size:13px}.account-btn span:last-child{color:var(--muted)}
    .feature-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin-top:18px}.feature-card{border:1px solid var(--line);border-radius:18px;padding:18px;background:#fff;box-shadow:0 5px 18px rgba(10,33,69,.05);text-align:left}.feature-card.buyer{background:linear-gradient(135deg,#0b5bc7,#2147a4);color:#fff}.feature-card.support{background:linear-gradient(135deg,#7b3fd2,#9d5be7);color:#fff}.feature-card h3{margin:0;font-size:17px}.feature-card p{margin:6px 0 12px;font-size:11px;opacity:.9}.feature-card button{padding:9px 12px;border-radius:10px;background:#fff;color:var(--navy);font-weight:900}.feature-icon{font-size:30px;margin-bottom:8px}.service-form{display:grid;gap:11px}.service-form label{font-size:12px;font-weight:800}.service-form input,.service-form textarea,.service-form select{width:100%;padding:11px;border:1px solid var(--line);border-radius:11px;background:#fff}.service-form textarea{min-height:100px;resize:vertical}.support-list{display:grid;gap:10px}.support-option{display:flex;gap:12px;align-items:center;padding:14px;border:1px solid var(--line);background:#fff;border-radius:15px;text-align:left}.support-option .ico{width:42px;height:42px;border-radius:12px;background:#eef3fb;display:grid;place-items:center;font-size:20px}.support-option b{display:block;font-size:13px}.support-option small{color:var(--muted);font-size:10px}
    .bottom-nav{position:fixed;left:50%;bottom:0;transform:translateX(-50%);width:min(1180px,100%);height:68px;background:#fff;border-top:1px solid var(--line);display:grid;grid-template-columns:repeat(4,1fr);z-index:44}.nav-item{background:#fff;color:var(--muted);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;font-size:10px;font-weight:800;position:relative}.nav-item .nav-icon{font-size:21px}.nav-item.active{color:var(--navy)}
    .toast{position:fixed;left:50%;bottom:calc(96px + env(safe-area-inset-bottom,0px));transform:translateX(-50%) translateY(12px);background:#0f172a;color:#fff;padding:12px 16px;border-radius:14px;font-size:13px;font-weight:600;opacity:0;pointer-events:none;transition:.22s cubic-bezier(.22,1,.36,1);z-index:100050;max-width:min(92vw,360px);box-shadow:0 12px 40px rgba(15,23,42,.28);text-align:center}.toast.show{opacity:1;transform:translateX(-50%) translateY(0)}.toast.is-success{background:#0f766e}.toast.is-error{background:#b91c1c}.toast.is-info{background:#0b2e6f}
    @media (max-width:900px){.top-inner{padding:10px 14px}.brand{min-width:190px}.content{padding:14px 14px 94px}.cat-grid{grid-template-columns:repeat(4,1fr)}.cat-image{height:68px}.shop-grid{grid-template-columns:repeat(3,1fr)}.hero-slide{padding:26px 46px}.hero-copy{max-width:62%}.hero-art{font-size:90px}}
    @media (max-width:700px){.brand-row{flex-wrap:wrap}.brand{min-width:0;flex:1}.search-row{order:3;flex-basis:100%;max-width:none}.location{margin-left:0}.cat-grid{grid-template-columns:repeat(3,1fr)}.cat-image{height:64px}.shop-grid{grid-template-columns:repeat(2,1fr)}.hero-slide{min-height:230px;padding:24px 38px}.hero h1{font-size:22px}.hero p{font-size:12px}.hero-art{font-size:72px;right:1%}.feature-grid{grid-template-columns:1fr}.top-inner{padding-bottom:8px}}
    @media (max-width:480px){.brand img{width:46px;height:46px}.brand-name{font-size:18px}.brand-sub{font-size:9px}.location{font-size:11px;padding:7px 8px}.icon-btn{width:38px;height:38px}.content{padding:10px 10px 88px}.cat-grid{grid-template-columns:repeat(2,1fr);gap:8px}.cat{min-height:92px;padding:8px 6px}.cat-image{height:60px;border-radius:10px}.cat span{font-size:11px}.shop-grid{grid-template-columns:1fr 1fr;gap:8px}.shop-thumb{height:82px}.shop-body{padding:8px}.shop-name{font-size:12px}.shop-meta{font-size:9px}.hero{min-height:165px;border-radius:18px}.hero-slide{min-height:165px;padding:18px 30px}.hero-copy{max-width:74%}.hero h1{font-size:18px;line-height:1.2}.hero p{font-size:10px;margin-top:6px}.hero .hero-btn{margin-top:9px;padding:8px 11px;font-size:11px}.hero-art{font-size:45px;right:-5%}.hero-arrow{width:31px;height:31px;font-size:20px}.hero-arrow.prev{left:5px}.hero-arrow.next{right:5px}.hero-dots{bottom:8px;gap:5px}.hero-dot{width:7px;height:7px}.section-head{margin:12px 1px 7px}.section-head h2{font-size:15px}.feature-grid{grid-template-columns:1fr 1fr;gap:8px;margin-top:12px}.feature-card{padding:13px;border-radius:15px;min-height:72px;display:flex;align-items:center;gap:8px}.feature-icon{font-size:23px;margin:0}.feature-card h3{font-size:12px}.feature-card p,.feature-card span{display:none}.bottom-nav{height:62px}}
    .notification-screen{display:flex;flex-direction:column;gap:10px}.notification-item{display:flex;gap:12px;align-items:flex-start;padding:14px 16px;background:#fff;border:1px solid var(--line);border-radius:16px;text-align:left;box-shadow:0 4px 14px rgba(18,38,72,.04);transition:box-shadow .2s ease,border-color .2s ease}.notification-item.unread{border-left:4px solid var(--orange)}.notification-icon{width:38px;height:38px;border-radius:12px;background:#eef3fb;display:grid;place-items:center;flex:none}.notification-copy{flex:1;min-width:0}.notification-copy b{display:block;font-size:13px}.notification-copy p{margin:4px 0 0;color:var(--muted);font-size:11px;line-height:1.45}.notification-copy small{display:block;margin-top:6px;color:#9aa5b5;font-size:9px}.notification-empty{padding:45px 18px;text-align:center;color:var(--muted);background:#fff;border:1px solid var(--line);border-radius:18px}.terms-modal[hidden]{display:none}.terms-modal{position:fixed;inset:0;z-index:100001;display:grid;place-items:center}.terms-backdrop{position:absolute;inset:0;background:rgba(7,20,42,.55)}.terms-dialog{position:relative;width:min(94vw,720px);max-height:88vh;background:#fff;border-radius:20px;padding:20px;box-shadow:0 20px 70px rgba(0,0,0,.25);display:flex;flex-direction:column}.terms-body{overflow:auto;line-height:1.7;font-size:13px;border:1px solid var(--line);border-radius:14px;padding:16px;background:#fbfcfe}.terms-footer{display:flex;justify-content:flex-end;gap:8px;margin-top:12px}.terms-agree{background:var(--navy);color:#fff;padding:10px 16px;border-radius:11px;font-weight:800}.terms-note{font-size:11px;color:var(--muted);margin:0 0 10px}.oauth-row{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:8px}.auth-secondary{width:100%;padding:10px;border:1px solid var(--line);border-radius:11px;background:#fff;color:var(--navy);font-weight:800}.auth-link{background:transparent;color:var(--navy);text-decoration:underline;padding:2px 0;font-size:12px}.terms-check{display:flex!important;align-items:flex-start;gap:8px;font-size:11px!important;font-weight:600!important;margin-top:2px}.terms-check input{width:16px!important;height:16px!important;margin:1px 0 0!important;flex:none}.terms-read{background:transparent;color:var(--navy);text-decoration:underline;padding:0;font-weight:800}.auth-hint{font-size:10px;color:var(--muted);margin-top:-5px}.auth-divider{display:flex;align-items:center;gap:8px;color:#9aa5b5;font-size:10px;margin:8px 0}.auth-divider:before,.auth-divider:after{content:"";height:1px;background:var(--line);flex:1}

    .location-modal[hidden]{display:none}.location-modal{position:fixed;inset:0;z-index:100000;display:grid;place-items:center}.location-backdrop{position:absolute;inset:0;background:rgba(7,20,42,.48)}.location-dialog{position:relative;width:min(92vw,420px);max-height:82vh;overflow:hidden;background:#fff;border:1px solid #e7ebf2;border-radius:20px;padding:18px;box-shadow:0 24px 80px rgba(0,0,0,.22)}.location-dialog h3{margin:0 0 5px;color:var(--navy);font-size:18px}.location-dialog>small{display:block;color:var(--muted);font-size:10px;margin-bottom:12px}.location-picker{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:0 0 10px}.location-picker select{width:100%;padding:9px 10px;border:1px solid var(--line);border-radius:11px;background:#f8fafc;color:var(--navy);font-size:11px;font-weight:800}.location-list{display:grid;gap:7px;max-height:52vh;overflow:auto}.location-option{width:100%;padding:10px 12px;border:1px solid var(--line);border-radius:12px;background:#fbfcfe;text-align:left;color:var(--text);font-size:11px;font-weight:800}.location-option.active{background:#eef5ff;border-color:#9dbced;color:var(--navy)}.location-coming{text-align:center;padding:24px 12px}.location-coming .coming-icon{font-size:34px}.location-coming h4{margin:10px 0 7px;color:var(--navy);font-size:14px}.location-coming p{margin:0;color:var(--muted);font-size:11px;line-height:1.6}.location-compact{font-size:12px!important;padding:8px 9px!important;border:1px solid var(--line)!important;border-radius:12px!important;background:#fff!important}
    .account-card{box-shadow:0 8px 24px rgba(10,33,69,.05)}.account-list{display:grid;gap:8px;margin-top:14px}.account-list.account-main{margin-bottom:0}.account-join{margin-top:22px;padding-top:16px;border-top:1px solid var(--line)}.account-join-title{font-size:13px;font-weight:900;color:var(--navy);margin:0 0 9px}.account-join-list{margin-top:0}.account-btn{display:flex!important;align-items:center;justify-content:space-between;padding:12px 13px!important;border:1px solid var(--line)!important;border-radius:13px!important;background:#fff!important;font-size:12px!important;font-weight:800!important;box-shadow:0 2px 8px rgba(10,33,69,.025)}.account-btn:hover{background:#f7faff!important;border-color:#cbdaf1!important}.auth-dialog{border:1px solid #e7ebf2}.auth-fields label{display:grid;gap:6px;padding:9px 10px;border:1px solid #edf0f5;border-radius:12px;background:#fbfcfe}.auth-fields input,.auth-fields select,.auth-fields textarea{background:#fff}.auth-submit{margin-top:4px}.auth-role-note{font-size:10px;color:var(--muted);padding:9px 10px;border-radius:11px;background:#f7f9fc;border:1px solid var(--line)}

    .auth-choice-modal[hidden]{display:none}.auth-choice-modal{position:fixed;inset:0;z-index:100000;display:grid;place-items:center}.auth-choice-backdrop{position:absolute;inset:0;background:rgba(7,20,42,.5)}.auth-choice-dialog{position:relative;width:min(92vw,390px);background:#fff;border-radius:22px;padding:24px;box-shadow:0 24px 80px rgba(0,0,0,.24);text-align:center;border:1px solid #e7ebf2}.auth-choice-icon{width:54px;height:54px;border-radius:17px;background:#eef5ff;display:grid;place-items:center;margin:0 auto 12px;font-size:25px}.auth-choice-dialog h3{margin:0;color:var(--navy);font-size:19px}.auth-choice-dialog p{color:var(--muted);font-size:12px;line-height:1.6;margin:8px 0 18px}.auth-choice-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px}.auth-choice-actions button{width:100%;padding:11px 12px;border-radius:12px;font-weight:900}.auth-choice-actions .auth-secondary{border:1px solid var(--line);background:#fff;color:var(--navy)}
    .delivery-form-section{border:1px solid var(--line);border-radius:16px;background:#fff;padding:13px;display:grid;gap:10px}.delivery-form-section h4{margin:0;color:var(--navy);font-size:14px}.delivery-form-section>p{margin:-4px 0 0;color:var(--muted);font-size:10px;line-height:1.5}.delivery-grid{display:grid;grid-template-columns:1fr 1fr;gap:9px}.delivery-form-section label{display:grid;gap:6px;font-size:11px;font-weight:800}.delivery-form-section input,.delivery-form-section select,.delivery-form-section textarea{width:100%;padding:10px;border:1px solid var(--line);border-radius:11px;background:#fff;font:inherit}.delivery-form-section textarea{min-height:78px;resize:vertical}.delivery-checks{display:flex;flex-wrap:wrap;gap:7px}.delivery-check{display:flex!important;grid-template-columns:none!important;align-items:center;gap:7px;padding:8px 10px;border:1px solid var(--line);border-radius:10px;background:#f8fafc;font-size:10px!important;font-weight:700!important}.delivery-check input{width:16px!important;height:16px;padding:0!important}.rider-team{display:grid;gap:8px}.rider-row{display:grid;grid-template-columns:1.1fr 1fr .9fr 1fr auto;gap:7px;align-items:end;padding:9px;background:#f8fafc;border:1px solid var(--line);border-radius:12px}.rider-row label{font-size:9px}.rider-row input,.rider-row select{padding:8px!important;font-size:11px}.remove-rider{width:34px;height:34px;border-radius:9px;background:#fff1f1;color:var(--danger);font-weight:900}.upload-preview-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.upload-preview{border:1px solid var(--line);border-radius:11px;padding:6px;background:#fbfcfe;min-height:76px;display:grid;place-items:center;overflow:hidden}.upload-preview img{width:100%;height:76px;object-fit:cover;border-radius:8px}.delivery-submit{position:sticky;bottom:0;background:linear-gradient(180deg,rgba(255,255,255,0),#fff 22%);padding-top:14px}.delivery-success{display:none}.delivery-success.show{display:block;text-align:center;padding:18px;border-radius:16px;background:#effaf3;border:1px solid #bfe8cd;color:#156a3c}.delivery-status{display:inline-block;margin-top:8px;padding:6px 10px;border-radius:999px;background:#fff3d9;color:#9b6500;font-size:10px;font-weight:900}.delivery-terms-row{display:grid;gap:8px;padding:10px;border:1px solid var(--line);border-radius:12px;background:#fbfcfe}.delivery-terms-row label{display:flex!important;grid-template-columns:none!important;align-items:flex-start;gap:7px;font-size:10px!important;font-weight:700!important}.delivery-terms-row input{width:16px!important;height:16px;padding:0!important;flex:none}.delivery-form-section .required-note{font-size:9px;color:var(--muted);font-weight:600}
    .auth-window-controls{position:absolute;right:12px;top:9px;display:flex;gap:4px;z-index:2}.auth-window-controls button{width:30px;height:30px;border:1px solid var(--line);border-radius:9px;background:#fff;color:var(--navy);font-size:20px;line-height:1;cursor:pointer;font-weight:900}.auth-window-controls button:hover{background:#f4f7fb}.auth-minimized-tray{position:fixed;right:18px;bottom:78px;z-index:100001;display:flex;align-items:center;max-width:min(92vw,320px);background:#fff;border:1px solid #dfe5ee;border-radius:14px;box-shadow:0 12px 35px rgba(0,0,0,.18);overflow:hidden}.auth-minimized-restore{border:0;background:#fff;color:var(--navy);padding:11px 13px;font-weight:900;cursor:pointer;flex:1;text-align:left}.auth-minimized-restore span{float:right;font-size:18px}.auth-minimized-close{width:38px;height:42px;border:0;border-left:1px solid #e6ebf2;background:#fff;color:#6b778a;font-size:21px;cursor:pointer}.auth-close-confirm{position:fixed;inset:0;z-index:100003;display:grid;place-items:center}.auth-close-confirm-backdrop{position:absolute;inset:0;background:rgba(7,20,42,.58)}.auth-close-confirm-dialog{position:relative;width:min(92vw,390px);background:#fff;border-radius:20px;padding:24px;box-shadow:0 25px 80px rgba(0,0,0,.28);text-align:center;border:1px solid #e5eaf1}.auth-close-confirm-icon{font-size:28px;margin-bottom:8px}.auth-close-confirm-dialog h3{margin:0;color:var(--navy);font-size:20px}.auth-close-confirm-dialog p{margin:9px 0 20px;color:var(--muted);font-size:13px}.auth-close-confirm-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px}.auth-close-confirm-actions button{min-height:42px;border-radius:11px;padding:9px;font-weight:900;cursor:pointer}.auth-close-confirm-actions .auth-secondary{border:1px solid var(--line);background:#fff;color:var(--navy)}.auth-danger{border:0;background:#fff1f1;color:#b42318}.auth-modal[hidden]{display:none}.auth-modal{position:fixed;inset:0;z-index:99999;display:grid;place-items:center}.auth-backdrop{position:absolute;inset:0;background:rgba(7,20,42,.45)}.auth-dialog{position:relative;width:min(92vw,420px);max-height:88vh;overflow:auto;background:#fff;border-radius:20px;padding:22px;box-shadow:0 20px 70px rgba(0,0,0,.2)}.auth-close{position:absolute;right:14px;top:10px;border:0;background:transparent;font-size:26px;cursor:pointer}.auth-dialog h3{margin:0 0 5px}.auth-message{color:var(--muted);font-size:12px;line-height:1.5}.auth-fields{display:grid;gap:10px;margin:14px 0}.auth-fields label{font-size:12px;font-weight:700}.auth-fields input,.auth-fields select,.auth-fields textarea{width:100%;box-sizing:border-box;padding:11px;border:1px solid var(--line);border-radius:10px;font:inherit}.auth-fields textarea{min-height:90px}.auth-submit{width:100%}


/* H MARKET Customer Home UI Correction V2 */
.home-section{margin:0 0 22px}.home-section[hidden]{display:none!important}
.section-head{align-items:flex-end;margin:0 2px 11px}.section-head h2{font-size:18px;letter-spacing:-.02em;color:var(--navy)}.section-head>button{display:inline-flex;align-items:center;gap:4px;font-size:12px}.section-kicker{margin:3px 0 0;color:var(--muted);font-size:10px}
.hero-section{margin-bottom:20px}.hero{min-height:260px;border-radius:24px;background:#0b2e6f;box-shadow:0 14px 38px rgba(8,35,84,.14)}.hero-track{height:100%}.hero-slide{min-height:260px;height:100%;padding:32px 56px;background:linear-gradient(120deg,#0b2e6f 0%,#1754a7 55%,#f0a21d 130%)}.hero-slide.has-image{background-size:cover;background-position:center}.hero-slide.has-image:before{background:linear-gradient(90deg,rgba(3,19,49,.9) 0%,rgba(4,24,58,.7) 45%,rgba(4,24,58,.12) 90%)}.hero-copy{max-width:min(560px,65%)}.hero-label{display:inline-flex;padding:5px 9px;border-radius:999px;background:rgba(255,193,28,.16);color:#ffd768;font-size:9px;font-weight:900;letter-spacing:.12em}.hero h1{font-size:31px;line-height:1.18;margin-top:10px}.hero p{font-size:13px;line-height:1.55;max-width:500px}.hero-btn{display:inline-flex!important;align-items:center;gap:8px;margin-top:16px!important;padding:11px 16px!important;border-radius:12px!important;background:#ffc21c!important;color:#15233a!important;font-size:12px!important;box-shadow:0 8px 20px rgba(255,194,28,.18)}.hero-arrow{width:40px;height:40px;background:rgba(255,255,255,.94);box-shadow:0 8px 20px rgba(3,18,45,.16)}.hero-dots{bottom:14px}.hero-dot{width:8px;height:8px}.hero-dot.active{background:#ffc21c}
.cat-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:12px}.cat{min-height:112px;padding:9px 9px 10px;border-radius:17px;display:flex;align-items:center;gap:10px;text-align:left;box-shadow:0 7px 20px rgba(10,33,69,.045);overflow:hidden}.cat-image-wrap{width:62px;height:62px;min-width:62px;border-radius:15px;overflow:hidden;background:#eef4fb}.cat-image{width:100%;height:100%;margin:0;display:block;object-fit:cover;border-radius:0}.cat-fallback-icon{width:100%;height:100%;display:grid;place-items:center;font-size:27px;color:var(--navy);background:#eef4fb}.cat-copy{min-width:0;display:flex;flex-direction:column;align-items:flex-start;gap:3px;padding-right:18px}.cat-copy strong{font-size:12px;line-height:1.2;color:var(--text)}.cat-copy small{font-size:9px;line-height:1.35;color:var(--muted)}.cat-arrow{right:8px;bottom:8px;width:24px;height:24px;background:#edf4ff;color:#1761c7}
.home-carousel{display:flex;gap:12px;overflow-x:auto;overflow-y:hidden;padding:1px 2px 7px;scroll-snap-type:x proximity;-webkit-overflow-scrolling:touch;scrollbar-width:none}.home-carousel::-webkit-scrollbar{display:none}.market-card{flex:0 0 210px;max-width:210px;background:#fff;border:1px solid #e5eaf2;border-radius:18px;overflow:hidden;text-align:left;box-shadow:0 8px 22px rgba(10,33,69,.05);scroll-snap-align:start}.market-card-media{position:relative;overflow:hidden;height:142px;background:linear-gradient(135deg,#edf3fa,#dce6f3)}.market-card-media img{display:block;width:100%;height:100%;object-fit:cover}.shop-thumb-fallback{display:grid;place-items:center;width:100%;height:100%;font-size:38px;color:var(--navy)}.market-card-badge{position:absolute;left:9px;top:9px;padding:4px 7px;border-radius:999px;background:rgba(255,255,255,.94);color:var(--success);font-size:9px;font-weight:900}.market-card-body{padding:11px}.market-card-title{font-size:13px;font-weight:900;color:var(--text);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.market-card-meta{display:flex;align-items:center;gap:4px;margin-top:6px;color:var(--muted);font-size:10px}.market-card-meta .rating{font-size:11px}.market-card-sub{margin-top:6px;color:var(--muted);font-size:10px;line-height:1.35;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.market-card-price{margin-top:6px;color:var(--navy);font-size:13px;font-weight:900}.food-market-card{flex-basis:190px;max-width:190px}.food-market-card .market-card-media{height:132px}
.home-feature-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-top:0}.home-feature-grid .feature-card{position:relative;display:grid;grid-template-columns:auto 1fr auto;gap:12px;align-items:center;min-height:116px;padding:16px 17px;border:1px solid rgba(255,255,255,.3);border-radius:20px;box-shadow:0 10px 28px rgba(10,33,69,.09);overflow:hidden}.home-feature-grid .feature-card:after{content:"";position:absolute;width:120px;height:120px;right:-48px;bottom:-62px;border-radius:50%;background:rgba(255,255,255,.12)}.home-feature-grid .feature-card-icon{width:52px;height:52px;border-radius:17px;display:grid;place-items:center;background:rgba(255,255,255,.16);font-size:27px;z-index:1}.home-feature-grid .feature-card-copy{min-width:0;z-index:1}.feature-eyebrow{font-size:8px;font-weight:900;letter-spacing:.12em;opacity:.78}.home-feature-grid .feature-card h3{margin:3px 0 0;font-size:17px}.home-feature-grid .feature-card p{margin:5px 0 0;font-size:10px;line-height:1.45}.home-feature-grid .feature-arrow{font-size:18px;font-weight:900;z-index:1}.home-feature-grid .buyer{background:linear-gradient(135deg,#0b5bc7,#1d4db0);color:#fff}
.compact-empty{padding:14px 0;text-align:left}.market-card:focus-visible,.cat:focus-visible,.feature-card:focus-visible,.section-head button:focus-visible{outline:3px solid rgba(23,97,199,.2);outline-offset:2px}
.location-single{display:grid;grid-template-columns:auto 1fr auto;gap:10px;align-items:center;padding:13px;border:1px solid #dfe6f1;border-radius:14px;background:#f8fbff}.location-single-icon{width:42px;height:42px;border-radius:13px;background:#eaf2ff;display:grid;place-items:center;font-size:20px}.location-single strong{display:block;color:var(--navy);font-size:13px}.location-single small{display:block;color:var(--muted);font-size:10px;margin-top:3px}.location-check{width:23px;height:23px;border-radius:50%;display:grid;place-items:center;background:#e9f8ef;color:var(--success);font-weight:900}
@media (max-width:1020px){.cat-grid{grid-template-columns:repeat(5,minmax(0,1fr))}.cat{min-height:102px}.cat-image-wrap{width:56px;height:56px;min-width:56px}.market-card{flex-basis:200px;max-width:200px}.home-feature-grid .feature-card h3{font-size:15px}}
@media (max-width:760px){.content{padding:12px 12px 92px}.top-inner{padding:9px 12px 9px}.brand-row{gap:8px}.brand{min-width:0}.brand-copy{display:none}.brand img{width:45px;height:45px}.search-row{order:3;flex-basis:100%;max-width:none}.search{padding:9px 11px;border-radius:12px}.search input{font-size:12px}.location-compact{max-width:150px;overflow:hidden;text-overflow:ellipsis}.hero{min-height:205px;border-radius:19px}.hero-slide{min-height:205px;padding:22px 34px}.hero-copy{max-width:75%}.hero h1{font-size:22px}.hero p{font-size:11px}.hero-btn{margin-top:11px!important;padding:9px 12px!important}.hero-arrow{width:33px;height:33px;font-size:21px}.cat-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.cat{min-height:88px;padding:8px;border-radius:15px}.cat-image-wrap{width:54px;height:54px;min-width:54px;border-radius:13px}.cat-copy strong{font-size:11px}.cat-copy small{font-size:8px}.section-head{margin-bottom:9px}.section-head h2{font-size:15px}.section-kicker{display:none}.home-section{margin-bottom:18px}.home-carousel{gap:9px}.market-card{flex-basis:172px;max-width:172px;border-radius:15px}.market-card-media{height:114px}.food-market-card{flex-basis:166px;max-width:166px}.food-market-card .market-card-media{height:108px}.market-card-body{padding:9px}.market-card-title{font-size:12px}.market-card-meta{font-size:9px}.market-card-sub{font-size:9px}.home-feature-grid{grid-template-columns:1fr;gap:9px}.home-feature-grid .feature-card{min-height:108px;padding:14px}.home-feature-grid .feature-card h3{font-size:15px}.home-feature-grid .feature-card p{font-size:9px}.home-feature-grid .feature-card-icon{width:46px;height:46px;border-radius:15px;font-size:23px}}
@media (max-width:420px){.location-compact{max-width:128px}.location-compact span{max-width:88px;overflow:hidden;text-overflow:ellipsis}.hero{min-height:185px}.hero-slide{min-height:185px;padding:18px 30px}.hero h1{font-size:19px}.hero p{font-size:10px;line-height:1.4}.hero-label{font-size:8px}.hero-btn{font-size:10px!important}.market-card{flex-basis:164px;max-width:164px}.food-market-card{flex-basis:158px;max-width:158px}.market-card-media{height:104px}.food-market-card .market-card-media{height:100px}}


/* H MARKET Customer Home Final Architecture */
.home-sections-container{display:flex;flex-direction:column;gap:0}.home-sections-container .home-section{margin:0 0 28px}
.account-header-btn{font-size:16px}.buyer-home-card{width:100%;border:0;cursor:pointer;text-align:left}
.featured-page-list{margin-top:6px}.featured-page-list .market-card{flex-basis:220px;max-width:220px}
.dynamic-service-section .section-head{margin-bottom:10px}.dynamic-service-card{display:flex;align-items:center;gap:14px;padding:15px 16px;border:1px solid #e4e9f1;border-radius:18px;background:#fff;box-shadow:0 8px 24px rgba(10,33,69,.05)}.dynamic-service-icon{width:46px;height:46px;border-radius:15px;display:grid;place-items:center;background:#edf4ff;font-size:22px}.dynamic-service-card strong{font-size:13px;color:var(--navy)}.dynamic-service-card p{margin:4px 0 0;color:var(--muted);font-size:10px;line-height:1.45}
#featuredEmpty{margin-top:8px}.bottom-nav .nav-item[hidden]{display:none}.bottom-nav .nav-item{min-width:0}
@media(max-width:760px){.account-header-btn{font-size:15px}.home-sections-container .home-section{margin-bottom:18px}.featured-page-list .market-card{flex-basis:172px;max-width:172px}.buyer-home-card{min-height:112px!important}}

/* Final bottom navigation: service destinations are conditionally shown by Customer Home capability data. */
.bottom-nav{grid-template-columns:repeat(5,minmax(0,1fr))}
@media(max-width:480px){.bottom-nav{grid-template-columns:repeat(5,minmax(0,1fr))}.bottom-nav .nav-item{font-size:9px}.bottom-nav .nav-item .nav-icon{font-size:19px}}


/* Home visual correction: compact search + equal-width bottom navigation. */
.search-row{position:relative;display:flex;align-items:center;justify-content:flex-start;flex:0 0 auto;max-width:none;margin:0}
.search-row .search{display:none}
.search-row.is-open .search{display:flex;position:absolute;left:0;top:0;width:min(420px,42vw);z-index:60;box-shadow:0 10px 28px rgba(10,33,69,.12);transform-origin:left center;animation:searchExpand .28s ease}
@keyframes searchExpand{from{width:0;opacity:.2}to{width:min(420px,42vw);opacity:1)}}
.social-links{display:flex;align-items:center;gap:6px;margin-left:8px}
.social-links a{width:28px;height:28px;border-radius:50%;display:grid;place-items:center;background:#edf4ff;color:#0b57d0;text-decoration:none;font-weight:900;font-size:14px}

.bottom-nav{grid-template-columns:repeat(var(--nav-count,4),minmax(0,1fr))}
.bottom-nav .nav-item{width:100%;min-width:0;justify-content:center;white-space:nowrap}
@media(max-width:760px){
  .search-row{order:initial;flex:0 0 auto;max-width:none}
  .search-row.is-open{position:absolute;left:0;right:150px;top:0;z-index:70}
  .search-row.is-open .search{position:relative;left:0;top:auto;width:100%;box-shadow:0 12px 30px rgba(10,33,69,.14)}
  .top{position:sticky}
  .bottom-nav{grid-template-columns:repeat(var(--nav-count,4),minmax(0,1fr))}
  .bottom-nav .nav-item{font-size:10px;padding-left:2px;padding-right:2px}
}
@media(max-width:420px){
  .search-row.is-open{top:57px}
  .bottom-nav .nav-item{font-size:9px}
}


/* H MARKET responsive container/layout stabilization. Keep existing visual design. */
.app{width:100%;max-width:1180px;margin:0 auto;min-height:100vh;overflow-x:clip}
.top-inner,.content{width:100%;max-width:none;margin:0}
.content{padding-left:22px;padding-right:22px;padding-bottom:calc(94px + env(safe-area-inset-bottom))}
.home-sections-container,.home-sections-container>.home-section{width:100%;max-width:none;min-width:0}
.home-sections-container .hero,.home-sections-container .cat-grid,.home-sections-container .home-carousel,.home-sections-container .home-feature-grid,.home-sections-container .dynamic-service-card{width:100%;max-width:none;min-width:0}

/* Main Categories: responsive grid; Home selection is controlled by home_sections.item_ids. */
.cat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-auto-rows:112px;gap:12px;width:100%}
.cat{width:100%;min-width:0;height:112px;min-height:112px;max-height:112px;padding:9px;display:flex;align-items:center;gap:10px;overflow:hidden}
.cat-image-wrap{width:62px;min-width:62px;height:62px;flex:0 0 62px}
.cat-copy{min-width:0;flex:1 1 auto}
.cat-copy strong,.cat-copy small{max-width:100%;overflow:hidden;text-overflow:ellipsis}

/* Bottom navigation: HOME / SHOP / CART / ACCOUNT. */
.bottom-nav{width:min(1180px,100%);grid-template-columns:repeat(4,minmax(0,1fr)) !important;padding-bottom:env(safe-area-inset-bottom);height:calc(68px + env(safe-area-inset-bottom))}
.bottom-nav .nav-item{min-width:0;width:100%}

@media (max-width:1020px){
  .content{padding-left:16px;padding-right:16px}
  .cat-grid{grid-template-columns:repeat(3,minmax(0,1fr));grid-auto-rows:104px;gap:10px}
  .cat{height:104px;min-height:104px;max-height:104px}
  .cat-image-wrap{width:56px;min-width:56px;height:56px;flex-basis:56px}
}
@media (max-width:760px){
  .app{width:100%;max-width:none}
  .content{padding:12px 12px calc(82px + env(safe-area-inset-bottom));overflow-x:clip}
  .top-inner{padding-left:12px;padding-right:12px}
  .cat-grid{grid-template-columns:repeat(2,minmax(0,1fr));grid-auto-rows:96px;gap:9px}
  .cat{height:96px;min-height:96px;max-height:96px;padding:8px;border-radius:15px;gap:8px}
  .cat-image-wrap{width:52px;min-width:52px;height:52px;flex-basis:52px;border-radius:13px}
  .cat-copy strong{font-size:11px}.cat-copy small{font-size:8px}
  .cat-arrow{right:7px;bottom:7px;width:21px;height:21px}
  .bottom-nav{left:0;right:0;transform:none;width:100%;height:calc(62px + env(safe-area-inset-bottom))}
}
@media (min-width:761px){body{overflow-x:hidden}.app{margin-left:auto;margin-right:auto}}
@media (max-width:430px){
  .content{padding-left:10px;padding-right:10px}
  .cat-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  .cat{height:94px;min-height:94px;max-height:94px;padding:7px}
  .cat-image-wrap{width:50px;min-width:50px;height:50px;flex-basis:50px}
}

/* Premium header social + account polish */
.social-links a:nth-child(1){background:#1877f2;color:#fff}
.social-links a:nth-child(2){background:#111;color:#fff}
.social-links a:nth-child(3){background:#ff0000;color:#fff}
.social-links a{box-shadow:0 4px 12px rgba(10,33,69,.12);transition:.2s ease}
.social-links a:hover{transform:translateY(-2px) scale(1.08)}
.premium-account-icon{display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:linear-gradient(135deg,#0b2e6f,#ffc21c);color:#fff;font-size:14px;box-shadow:0 4px 12px rgba(11,46,111,.25)}
.search-row .search{transition:width .28s ease,opacity .2s ease}

/* H MARKET premium header refinements */
.search-toggle{
  color:#c28a16!important;
  border-color:#d8b45c!important;
  background:linear-gradient(135deg,#fff,#fff8df);
  box-shadow:0 4px 14px rgba(194,138,22,.18);
}
.social-links a:nth-child(1){background:#1877f2;color:#fff}
.social-links a:nth-child(2){background:#111;color:#fff}
.social-links a:nth-child(3){background:#ff0000;color:#fff}
.premium-account-icon{
  background:linear-gradient(145deg,#0b2e6f,#5579b8)!important;
  color:#fff!important;
  font-size:20px!important;
}
.search-row.is-open{
  flex:1 1 auto;
  max-width:none;
  margin-right:8px;
}
.search-row.is-open .search{
  width:100%;
}
/* keep bottom navigation visible on every customer screen */
.bottom-nav{display:grid!important;}

.service-mini-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px}
.service-mini-card{display:flex;align-items:center;gap:12px;background:#fff;border:1px solid #e6eaf2;border-radius:16px;padding:16px;text-align:left;box-shadow:0 4px 14px rgba(0,0,0,.05)}
.service-mini-card span{font-size:24px;flex:0 0 auto}
.service-mini-card .service-mini-img{width:48px;height:48px;object-fit:cover;border-radius:12px;flex:0 0 48px}
.service-mini-card b{display:block;color:#123b78;font-size:15px}
.service-mini-card small{display:block;color:#667085;font-size:12px;margin-top:4px}
@media(max-width:700px){.service-mini-grid{grid-template-columns:repeat(2,1fr)}.service-mini-card .service-mini-img{width:40px;height:40px;flex-basis:40px}}
\n\n/* =========================================================\n   H MARKET HOME UI — requested final layout\n   Banner -> Categories 5x2 -> Popular Shops -> Popular Food\n   -> 4 service cards -> Buy-for-Me\n   ========================================================= */\n@media (min-width:1021px){\n  .home-sections-container .cat-grid{\n    grid-template-columns:repeat(5,minmax(0,1fr));\n    grid-template-rows:repeat(2,112px);\n    grid-auto-rows:112px;\n    gap:12px;\n  }\n}\n@media (min-width:761px) and (max-width:1020px){\n  .home-sections-container .cat-grid{\n    grid-template-columns:repeat(4,minmax(0,1fr));\n    grid-auto-rows:104px;\n    gap:10px;\n  }\n}\n\n.home-sections-container .cat{\n  width:100%;\n  height:112px;\n  min-height:112px;\n  max-height:112px;\n  display:flex;\n  align-items:center;\n  overflow:hidden;\n}\n.home-sections-container .cat-image-wrap{\n  flex:0 0 62px;\n  width:62px;\n  height:62px;\n}\n.home-sections-container .cat-image{\n  width:100%;\n  height:100%;\n  object-fit:cover;\n  object-position:center;\n}\n.home-sections-container .cat-copy{\n  min-width:0;\n  flex:1 1 auto;\n  overflow:hidden;\n}\n.home-sections-container .cat-copy strong,\n.home-sections-container .cat-copy small{\n  display:block;\n  overflow:hidden;\n  text-overflow:ellipsis;\n  white-space:nowrap;\n}\n\n.service-feature-row .service-mini-grid{\n  display:grid;\n  grid-template-columns:repeat(4,minmax(0,1fr));\n  grid-auto-rows:96px;\n  gap:12px;\n}\n.service-feature-row .service-mini-card{\n  width:100%;\n  height:96px;\n  min-width:0;\n  display:flex;\n  align-items:center;\n  overflow:hidden;\n  padding:14px;\n}\n.service-feature-row .service-mini-card>div{\n  min-width:0;\n}\n.service-feature-row .service-mini-card b,\n.service-feature-row .service-mini-card small{\n  overflow:hidden;\n  text-overflow:ellipsis;\n  white-space:nowrap;\n}\n\n@media (max-width:760px){\n  .home-sections-container .cat-grid{\n    grid-template-columns:repeat(2,minmax(0,1fr));\n    grid-template-rows:none;\n    grid-auto-rows:94px;\n    gap:8px;\n  }\n  .home-sections-container .cat{\n    height:94px;\n    min-height:94px;\n    max-height:94px;\n    padding:7px;\n  }\n  .home-sections-container .cat-image-wrap{\n    flex-basis:50px;\n    width:50px;\n    height:50px;\n  }\n  .home-sections-container .cat-copy strong{font-size:11px}\n  .home-sections-container .cat-copy small{font-size:8px}\n  .service-feature-row .service-mini-grid{\n    grid-template-columns:repeat(2,minmax(0,1fr));\n    grid-auto-rows:86px;\n    gap:8px;\n  }\n  .service-feature-row .service-mini-card{\n    height:86px;\n    padding:10px;\n    gap:8px;\n    border-radius:14px;\n  }\n  .service-feature-row .service-mini-card span{font-size:21px}\n  .service-feature-row .service-mini-card b{font-size:11px}\n  .service-feature-row .service-mini-card small{font-size:8px}\n}\n

/* H MARKET CUSTOMER HOME UI FIX V2
   Only home layout adjustment - no logic/database changes
*/

#homeSectionsContainer .cat-grid{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:12px;
}

#homeSectionsContainer .cat{
  height:112px;
  min-height:112px;
  width:100%;
}

#homeSectionsContainer .cat-image-wrap{
  width:62px;
  height:62px;
  flex:0 0 62px;
}

#homeSectionsContainer .home-carousel{
  display:flex;
  gap:16px;
}

#homeSectionsContainer .market-card{
  flex:0 0 210px;
  height:auto;
}

#homeSectionsContainer .market-card img,
#homeSectionsContainer .market-card .card-image{
  height:150px;
  width:100%;
  object-fit:cover;
}

#homeSectionsContainer .service-feature-row .service-mini-grid{
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:12px;
}

@media(max-width:900px){
  #homeSectionsContainer .cat-grid{
    grid-template-columns:repeat(3,minmax(0,1fr));
  }
}

@media(max-width:600px){
  #homeSectionsContainer .cat{
    height:96px;
    min-height:96px;
    padding:8px;
  }

  #homeSectionsContainer .cat-image-wrap{
    width:48px;
    height:48px;
    flex-basis:48px;
  }

  #homeSectionsContainer .service-feature-row .service-mini-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}


/* H MARKET HOME FINAL ALIGNMENT PATCH
   Only layout override - keeps existing data/render logic */

#popularShops,
#popularFood,
#homeFeaturedShops,
.home-carousel{
  display:grid !important;
  grid-template-columns:repeat(4,minmax(0,1fr)) !important;
  gap:12px !important;
  overflow:visible !important;
}

.home-carousel .market-card{
  width:100% !important;
  max-width:none !important;
  flex:none !important;
}

.service-mini-grid{
  display:grid !important;
  grid-template-columns:repeat(4,minmax(0,1fr)) !important;
  gap:12px !important;
  overflow:visible !important;
}

.service-mini-card{
  width:100% !important;
}

@media(max-width:760px){
  #popularShops,
  #popularFood,
  #homeFeaturedShops,
  .home-carousel{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    gap:8px !important;
  }

  .service-mini-grid{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
}


/* Network-safe customer state: never leave Home silently blank when Supabase is unreachable. */
.connection-notice{
  display:flex;align-items:center;gap:10px;margin:10px 0 14px;padding:11px 12px;
  border:1px solid #f1d28a;border-radius:14px;background:#fff9e9;box-shadow:0 5px 18px rgba(11,46,111,.06);
}
.connection-notice[hidden]{display:none}
.connection-notice-icon{font-size:20px;line-height:1}
.connection-notice-copy{display:flex;flex-direction:column;gap:2px;min-width:0;flex:1}
.connection-notice-copy strong{font-size:12px;color:#0b2e6f}
.connection-notice-copy span{font-size:10px;color:#6f7c91;line-height:1.4}
.connection-notice button{border:0;border-radius:9px;background:#0b2e6f;color:#fff;padding:8px 12px;font-size:11px;font-weight:800;cursor:pointer}
.connection-notice button:disabled{opacity:.6;cursor:wait}
@media(max-width:600px){.connection-notice{align-items:flex-start}.connection-notice button{padding:7px 10px}}

[data-supabase-status]{display:none!important}

/* ===== Premium category cards: photo top, text below ===== */
.cat-grid{
  display:grid !important;
  grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  gap:12px !important;
  grid-auto-rows:auto !important;
}
.cat{
  display:flex !important;
  flex-direction:column !important;
  align-items:stretch !important;
  gap:0 !important;
  height:auto !important;
  min-height:0 !important;
  max-height:none !important;
  padding:0 !important;
  overflow:hidden !important;
  border-radius:18px !important;
  background:#fff !important;
  border:1px solid rgba(15,35,70,.08) !important;
  box-shadow:0 8px 24px rgba(10,33,69,.06) !important;
  text-align:left !important;
}
.cat-image-wrap{
  width:100% !important;
  min-width:0 !important;
  height:118px !important;
  flex:none !important;
  border-radius:0 !important;
  overflow:hidden !important;
  background:linear-gradient(135deg,#eef3fb,#dfe9f8) !important;
  display:block !important;
}
.cat-image{
  width:100% !important;
  height:118px !important;
  object-fit:cover !important;
  border-radius:0 !important;
  margin:0 !important;
  display:block !important;
}
.cat-fallback-icon{
  width:100%;
  height:118px;
  display:grid;
  place-items:center;
  font-size:34px;
  background:linear-gradient(135deg,#eef3fb,#dfe9f8);
}
.cat-copy{
  display:flex !important;
  flex-direction:column !important;
  gap:2px !important;
  padding:10px 12px 12px !important;
  min-width:0 !important;
  flex:none !important;
}
.cat-copy strong{
  font-size:13px !important;
  font-weight:800 !important;
  color:#0b2e6f !important;
  line-height:1.25 !important;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.cat-copy small{
  font-size:10px !important;
  color:#6f7c91 !important;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.cat-arrow{display:none !important}

@media (min-width:900px){
  .cat-grid{grid-template-columns:repeat(4,minmax(0,1fr)) !important;gap:14px !important}
  .cat-image-wrap,.cat-image,.cat-fallback-icon{height:130px !important}
}
@media (max-width:420px){
  .cat-image-wrap,.cat-image,.cat-fallback-icon{height:104px !important}
  .cat-copy{padding:8px 10px 10px !important}
  .cat-copy strong{font-size:12px !important}
}

/* Hide social links if any remain */
.social-links{display:none !important}


/* Primary actions: navy only (login, cart CTA, submit) */
.primary,
button.primary,
.btn.primary,
.auth-submit{
  background:var(--navy) !important;
  color:#fff !important;
  border:0 !important;
}
.primary:hover,
button.primary:hover,
.btn.primary:hover,
.auth-submit:hover{
  background:var(--navy-2) !important;
  color:#fff !important;
}


/* Hotel / Bus list screens (Popular Shop-style header + card grid) */
.service-list-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(240px,1fr));
  gap:12px;
  margin-top:8px;
}
.service-list-card{
  background:#fff;
  border:1px solid var(--line);
  border-radius:18px;
  overflow:hidden;
  box-shadow:0 8px 22px rgba(10,33,69,.05);
  display:flex;
  flex-direction:column;
}
.service-list-media{
  height:140px;
  background:linear-gradient(135deg,#edf3fa,#dce6f3);
  display:grid;
  place-items:center;
  font-size:42px;
}
.service-list-media img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.service-list-body{padding:12px 14px 14px}
.service-list-title{font-size:14px;font-weight:900;color:var(--text)}
.service-list-sub{margin-top:6px;font-size:11px;color:var(--muted);line-height:1.4}
.service-list-meta{margin-top:8px;font-size:11px;color:var(--muted);line-height:1.45}
.service-list-price{margin-top:10px;font-size:14px;font-weight:900;color:var(--navy)}
.service-list-actions{display:flex;gap:8px;margin-top:12px}
.service-list-actions .btn-outline{
  flex:1;padding:10px;border-radius:12px;border:1px solid var(--line);
  background:#fff;color:var(--navy);font-weight:800;font-size:12px;
}
.service-list-actions .btn-navy{
  flex:1;padding:10px;border-radius:12px;border:0;
  background:var(--navy);color:#fff;font-weight:800;font-size:12px;
}
.chip-soft{
  display:inline-block;padding:2px 8px;border-radius:999px;
  background:#eef3fb;color:var(--navy);font-size:10px;font-weight:800;
}
@media (max-width:760px){
  .service-list-grid{grid-template-columns:1fr;gap:10px}
  .service-list-media{height:120px}
}

/* nav jump dampen */
html{scroll-behavior:auto!important}
.screen.active{min-height:50vh}



/* ===== New Account Dashboard (mobile-first + tablet/desktop) ===== */
#accountDash.screen.active{display:block}
#accountDash{background:#f4f6fb;min-height:100%;padding:0}

.new-dash{
  width:100%;
  max-width:100%;
  margin:0 auto;
  padding:12px 0 100px;
  display:flex;
  flex-direction:column;
  gap:14px;
  box-sizing:border-box;
}

/* Profile Card */
.nd-profile-card{
  display:flex;
  align-items:center;
  gap:14px;
  padding:18px 16px;
  border-radius:18px;
  background:linear-gradient(135deg,#0b2e6f 0%,#1a5bb8 55%,#2563eb 100%);
  color:#fff;
  box-shadow:0 8px 24px rgba(11,46,111,.25);
}
.nd-avatar-wrap{
  position:relative;
  flex:0 0 auto;
  width:58px;height:58px;
}
.nd-avatar{
  width:58px;height:58px;
  border-radius:50%;
  background:rgba(255,255,255,.22);
  display:grid;place-items:center;
  font-size:24px;font-weight:900;
  flex:0 0 auto;
  overflow:hidden;
  border:2px solid rgba(255,255,255,.35);
  padding:0;
}
.nd-avatar img{width:100%;height:100%;object-fit:cover;border-radius:50%;display:block}
.nd-profile-info{min-width:0;flex:1}
.nd-name{
  margin:0 0 4px;
  font-size:18px;
  font-weight:800;
  line-height:1.2;
  display:flex;
  align-items:center;
  gap:6px;
}
.nd-verified{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:18px;height:18px;
  border-radius:50%;
  background:#3b82f6;
  color:#fff;
  font-size:11px;
  font-weight:900;
  flex:0 0 auto;
}
.nd-email{
  margin:0 0 6px;
  font-size:12px;
  opacity:.92;
  display:flex;
  align-items:center;
  gap:5px;
  word-break:break-all;
}
.nd-meta{
  display:flex;
  flex-wrap:wrap;
  gap:8px 14px;
  font-size:11px;
  opacity:.9;
}
.nd-meta-item{display:inline-flex;align-items:center;gap:4px}
.nd-ico{font-size:12px;opacity:.95}

/* Stats */
.nd-stats{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:8px;
}
.nd-stat{
  background:#fff;
  border-radius:14px;
  padding:12px 6px 10px;
  text-align:center;
  border:1px solid #e8eef6;
  box-shadow:0 2px 8px rgba(15,30,60,.04);
}
.nd-stat-icon{
  width:36px;height:36px;
  border-radius:50%;
  display:grid;place-items:center;
  margin:0 auto 6px;
  font-size:16px;
}
.nd-stat-total{background:#fce7f3}
.nd-stat-pending{background:#fee2e2}
.nd-stat-shipping{background:#ffedd5}
.nd-stat-done{background:#d1fae5}
.nd-stat b{
  display:block;
  font-size:18px;
  font-weight:800;
  color:#0b2e6f;
  line-height:1.15;
}
.nd-stat small{
  display:block;
  margin-top:2px;
  font-size:10px;
  font-weight:700;
  color:#6b7a90;
}

/* Menu groups */
.nd-menu-group{
  background:#fff;
  border-radius:16px;
  border:1px solid #e8eef6;
  overflow:hidden;
  box-shadow:0 2px 8px rgba(15,30,60,.03);
}
.nd-group-title{
  padding:12px 14px 6px;
  font-size:11px;
  font-weight:800;
  color:#5b6b82;
  letter-spacing:.02em;
}
.nd-menu-item{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:13px 14px;
  border:0;
  background:transparent;
  border-top:1px solid #f0f3f8;
  font-size:14px;
  font-weight:700;
  color:#1a2433;
  cursor:pointer;
  text-align:left;
}
.nd-menu-item:first-of-type{border-top:0}
#dashPartnerServices .nd-menu-item:first-child{border-top:0}
#ndJoinGroup .nd-group-title{border-bottom:0}
.nd-menu-item:active{background:#f5f8fc}
.nd-menu-item:hover{background:#f8fafc}
.nd-menu-left{
  display:flex;
  align-items:center;
  gap:10px;
}
.nd-menu-ico{
  width:28px;height:28px;
  border-radius:8px;
  background:#f0f4fa;
  display:grid;place-items:center;
  font-size:14px;
  flex:0 0 auto;
}
.nd-chevron{
  color:#a0aec0;
  font-size:18px;
  font-weight:400;
}

/* Logout */
.nd-logout{
  width:100%;
  margin-top:4px;
  border:0;
  border-radius:14px;
  padding:14px;
  background:#fff1f2;
  color:#e11d48;
  font-weight:800;
  font-size:14px;
  cursor:pointer;
  border:1px solid #fecdd3;
}
.nd-logout:active,
.nd-logout:hover{background:#ffe4e6}

/* Sub panels */
.dash-panel{display:none}
.dash-panel.active{display:block}
.nd-subhead{
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:12px;
}
.nd-subhead h3{
  margin:0;
  font-size:16px;
  font-weight:800;
  color:#0b2e6f;
}
.nd-back{
  border:0;
  background:#fff;
  border:1px solid #e2e8f0;
  border-radius:10px;
  padding:8px 12px;
  font-weight:800;
  font-size:13px;
  color:#0b2e6f;
  cursor:pointer;
}
.nd-back:active,
.nd-back:hover{background:#f1f5f9}

/* Keep useful shared styles for sub-panels */
.dash-card{
  background:#fff;
  border:1px solid #e8eef6;
  border-radius:16px;
  padding:14px 16px;
}
.dash-empty{
  text-align:center;
  padding:28px 10px;
  color:#94a3b8;
  font-size:28px;
}
.dash-empty p{
  margin:6px 0 0;
  font-size:13px;
  font-weight:700;
  color:#64748b;
}
.dash-form{display:grid;gap:12px;max-width:400px}
.dash-form label{display:grid;gap:6px;font-size:13px;font-weight:800;color:#1e293b}
.dash-form input{
  padding:12px 14px;
  border:1px solid #e2e8f0;
  border-radius:12px;
  font-size:14px;
}
.dash-form input:focus{
  outline:none;
  border-color:#3b82f6;
  box-shadow:0 0 0 3px rgba(59,130,246,.15);
}

/* ===== Small phones ===== */
@media (max-width:380px){
  .nd-stats{gap:6px}
  .nd-stat{padding:10px 4px 8px}
  .nd-stat b{font-size:16px}
  .nd-stat small{font-size:9px}
  .nd-stat-icon{width:32px;height:32px;font-size:14px}
  .nd-name{font-size:16px}
  .nd-profile-card{padding:14px 12px}
}

/* ===== Tablet (portrait / landscape) ===== */
@media (min-width:600px){
  .new-dash{
    max-width:100%;
    padding:18px 0 110px;
    gap:16px;
  }
  .nd-profile-card{
    padding:22px 20px;
    gap:18px;
  }
  .nd-avatar{
    width:68px;height:68px;
    font-size:28px;
  }
  .nd-name{font-size:20px}
  .nd-email{font-size:13px}
  .nd-meta{font-size:12px}
  .nd-stats{gap:12px}
  .nd-stat{padding:16px 10px 14px;border-radius:16px}
  .nd-stat-icon{width:42px;height:42px;font-size:18px;margin-bottom:8px}
  .nd-stat b{font-size:22px}
  .nd-stat small{font-size:11px}
  .nd-menu-item{padding:15px 16px;font-size:15px}
  .nd-menu-ico{width:32px;height:32px;font-size:15px;border-radius:9px}
  .nd-group-title{padding:14px 16px 8px;font-size:12px}
  .nd-logout{padding:15px;font-size:15px;border-radius:16px}
}

/* ===== Desktop / large tablet landscape ===== */
@media (min-width:900px){
  .new-dash{
    max-width:100%;
    padding:24px 0 120px;
    gap:18px;
  }
  .nd-profile-card{
    padding:24px 28px;
  }
  .nd-avatar{
    width:72px;height:72px;
    font-size:30px;
  }
  .nd-name{font-size:22px}
  .nd-email{font-size:14px}
  .nd-meta{font-size:13px;gap:10px 18px}
  .nd-stats{
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:14px;
  }
  .nd-stat{padding:18px 12px 16px}
  .nd-stat b{font-size:24px}
  .nd-stat small{font-size:12px}
  .nd-stat-icon{width:46px;height:46px;font-size:20px}
  .nd-menu-group{border-radius:18px}
  .nd-menu-item{padding:16px 18px;font-size:15px}
  .nd-menu-item:hover{background:#f1f5f9}
  .nd-logout{max-width:320px}
}

/* ===== Wide desktop (optional more room) ===== */
@media (min-width:1200px){
  .new-dash{
    max-width:100%;
  }
}

.dash-avatar-upload{display:flex;flex-direction:column;align-items:flex-start;gap:10px;margin-bottom:14px}
.dash-avatar-preview{width:72px;height:72px;border-radius:50%;background:#e8eef8;display:grid;place-items:center;font-size:28px;font-weight:900;color:var(--navy);overflow:hidden;border:2px solid #dbe4f3}
.dash-avatar-preview img{width:100%;height:100%;object-fit:cover}
.dash-avatar-actions{display:flex;gap:8px;flex-wrap:wrap}
.dash-av-btn{border:1px solid var(--line);background:#fff;border-radius:11px;padding:9px 12px;font-weight:800;font-size:12px;cursor:pointer;color:var(--navy)}
.dash-av-btn:active{background:#f3f6fb}


/* Verify Customer panel */
.nd-verify-card{padding:18px}
.nd-verify-hero{display:flex;gap:14px;align-items:flex-start;margin-bottom:12px}
.nd-verify-icon{
  width:48px;height:48px;border-radius:14px;
  background:linear-gradient(135deg,#fef3c7,#fde68a);
  display:grid;place-items:center;font-size:24px;flex:0 0 auto;
}
.nd-verify-hero h4{margin:0 0 4px;font-size:16px;color:#0b2e6f}
.nd-verify-hero p{margin:0;font-size:12px;color:#64748b;line-height:1.45}
.nd-verify-benefits{
  margin:0 0 8px;padding:10px 12px 10px 28px;
  background:#f8fafc;border-radius:12px;border:1px solid #e8eef6;
  font-size:13px;color:#334155;line-height:1.7;
}
.nd-verify-status{
  margin-top:10px;padding:10px 14px;border-radius:12px;
  font-size:13px;font-weight:800;text-align:center;
}
.nd-verify-status.is-pending{background:#fff7ed;color:#c2410c;border:1px solid #fed7aa}
.nd-verify-status.is-verified{background:#ecfdf5;color:#047857;border:1px solid #a7f3d0}
.nd-verified[hidden]{display:none!important}



/* Verify photo capture */
.nd-verify-photo-block{margin-top:6px}
.nd-verify-photo-label{font-size:13px;font-weight:800;color:#1e293b;margin-bottom:8px}
.nd-verify-photo-label small{font-weight:600;color:#64748b;margin-left:4px}
.nd-verify-photo-row{display:flex;align-items:center;gap:14px;flex-wrap:wrap}
.nd-verify-photo-thumb{
  width:88px;height:88px;border-radius:16px;border:2px dashed #cbd5e1;
  background:#f8fafc;display:grid;place-items:center;overflow:hidden;
  cursor:pointer;padding:0;position:relative;
}
.nd-verify-photo-thumb:active{background:#f1f5f9}
.nd-verify-photo-ph{font-size:28px;opacity:.7}
.nd-verify-photo-thumb img{
  width:100%;height:100%;object-fit:cover;display:block;
}
.nd-verify-photo-actions{display:flex;flex-direction:column;gap:8px}
.nd-verify-del{color:#e11d48!important;border-color:#fecdd3!important}
#dashVerifyPhotoHint{margin-top:8px;font-size:11px;line-height:1.4}

/* Photo preview modal */
.nd-photo-modal{
  position:fixed;inset:0;z-index:100050;
  display:flex;align-items:center;justify-content:center;padding:16px;
}
.nd-photo-modal[hidden]{display:none!important}
.nd-photo-backdrop{
  position:absolute;inset:0;background:rgba(15,23,42,.72);
}
.nd-photo-dialog{
  position:relative;z-index:1;background:#fff;border-radius:18px;
  max-width:min(420px,100%);width:100%;padding:14px;
  box-shadow:0 20px 50px rgba(0,0,0,.25);
  display:flex;flex-direction:column;gap:12px;
}
.nd-photo-dialog img{
  width:100%;max-height:min(60vh,420px);object-fit:contain;
  border-radius:12px;background:#0f172a;
}
.nd-photo-close{
  position:absolute;top:8px;right:10px;z-index:2;
  width:36px;height:36px;border:0;border-radius:50%;
  background:rgba(255,255,255,.95);font-size:20px;cursor:pointer;
  box-shadow:0 2px 8px rgba(0,0,0,.12);
}
.nd-photo-modal-actions{
  display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end;
}


.nd-stats-extra{grid-template-columns:repeat(2,minmax(0,1fr));margin-top:0}
.nd-stat-wide{padding:14px 10px}
.nd-stat-points{background:#fef3c7}
.nd-stat-fav{background:#fce7f3}

.dash-form textarea{
  padding:12px 14px;
  border:1px solid #e2e8f0;
  border-radius:12px;
  font-size:14px;
  font-family:inherit;
  resize:vertical;
  min-height:64px;
}
.dash-form textarea:focus{
  outline:none;
  border-color:#3b82f6;
  box-shadow:0 0 0 3px rgba(59,130,246,.15);
}

/* Success toast after save / verify */
.nd-success-toast{
  position:fixed;inset:0;z-index:100080;
  display:flex;align-items:center;justify-content:center;
  background:rgba(15,23,42,.35);
  opacity:0;pointer-events:none;transition:opacity .2s ease;
}
.nd-success-toast.show{opacity:1;pointer-events:auto}
.nd-success-toast[hidden]{display:none!important}
.nd-success-card{
  background:#fff;border-radius:20px;padding:28px 32px;text-align:center;
  box-shadow:0 20px 50px rgba(0,0,0,.2);min-width:220px;max-width:90vw;
  animation:ndPop .28s ease;
}
.nd-success-check{
  width:64px;height:64px;border-radius:50%;margin:0 auto 12px;
  background:linear-gradient(135deg,#22c55e,#16a34a);color:#fff;
  font-size:32px;font-weight:900;display:grid;place-items:center;
  box-shadow:0 8px 20px rgba(22,163,74,.35);
}
.nd-success-card h4{margin:0 0 4px;font-size:18px;color:#0f172a}
.nd-success-card p{margin:0;font-size:13px;color:#64748b}
@keyframes ndPop{
  from{transform:scale(.85);opacity:0}
  to{transform:scale(1);opacity:1}
}

/* Profile avatar button on dashboard */
.nd-avatar-btn{
  border:2px solid rgba(255,255,255,.35);
  cursor:pointer;
  padding:0;
}
.nd-avatar-btn:active{transform:scale(.97)}

/* Nav account photo */
#navAccountIcon{
  overflow:hidden;
  display:grid;
  place-items:center;
}
#navAccountIcon.has-photo{
  background:transparent;
  box-shadow:0 0 0 2px #0b2e6f;
}
#navAccountIcon img{
  width:100%;
  height:100%;
  object-fit:cover;
  border-radius:50%;
  display:block;
}

/* Snappier nav press */
.nav-item:active{opacity:.75}
.nd-menu-item:active{background:#eef2f7}

/* Faster image paint */
.cat-image,.market-card-media img,.shop-thumb img,.hero-slide.has-image{
  content-visibility:auto;
}

.nd-fav-list{display:flex;flex-direction:column;gap:10px}
.nd-fav-item{
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:12px;border:1px solid #e8eef6;border-radius:14px;background:#f8fafc;
}
.nd-fav-main{display:flex;align-items:center;gap:10px;min-width:0}
.nd-fav-ico{font-size:22px}
.nd-fav-main b{display:block;font-size:13px;text-transform:capitalize}
.nd-fav-main small{display:block;font-size:11px;color:#64748b;word-break:break-all}
.fav-heart{
  border:0;background:transparent;font-size:18px;cursor:pointer;line-height:1;padding:2px;
}
.fav-heart.is-fav{filter:none}

.points-redeem-box{margin:10px 0;padding:12px;border-radius:12px;background:#f8fafc;border:1px solid #e8eef6}
.points-redeem-label{display:flex;align-items:center;gap:8px;font-weight:800;font-size:13px;color:#0b2e6f}
.points-redeem-box small{display:block;margin-top:6px;font-size:11px;color:#64748b}



/* ===== Language + Theme toggles ===== */
.nd-prefs-bar{
  margin:12px 0 8px;padding:8px;
  background:var(--card);
  border:1px solid var(--line);
  border-radius:16px;
  box-shadow:0 6px 18px rgba(18,38,72,.05);
}
.nd-lang-theme-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
}
.nd-seg{
  display:inline-flex;
  align-items:center;
  background:#eef2f7;
  border-radius:999px;
  padding:3px;
  gap:4px;
  flex:0 0 auto;
}
.nd-seg-lang{flex:1 1 auto;min-width:200px;max-width:320px}
.nd-seg-theme{flex:0 0 auto}
.nd-seg-btn{
  appearance:none;
  border:0;
  cursor:pointer;
  background:transparent;
  color:#5b6577;
  font-size:13px;
  font-weight:800;
  line-height:1.2;
  padding:10px 16px;
  border-radius:999px;
  white-space:nowrap;
  min-width:0;
  flex:1 1 0;
  transition:background .15s ease,color .15s ease,box-shadow .15s ease;
}
.nd-seg-lang .nd-seg-btn{flex:1 1 50%}
.nd-seg-theme .nd-seg-btn{
  flex:0 0 auto;
  width:44px;
  height:40px;
  padding:0;
  display:grid;
  place-items:center;
  font-size:16px;
}
.nd-seg-btn.active{
  background:#0b2e6f;
  color:#fff;
  box-shadow:0 4px 12px rgba(11,46,111,.25);
}
.nd-seg-btn:not(.active):hover{
  background:rgba(255,255,255,.9);
  color:#0b2e6f;
}
html[data-theme="dark"] .nd-prefs-bar{
  background:var(--card);border-color:var(--line);
}
html[data-theme="dark"] .nd-seg{background:#0f141c}
html[data-theme="dark"] .nd-seg-btn{color:#9aa6b8}
html[data-theme="dark"] .nd-seg-btn.active{
  background:#3b82f6;color:#fff;
  box-shadow:0 4px 12px rgba(37,99,235,.35);
}
html[data-theme="dark"] .nd-seg-btn:not(.active):hover{
  background:#1c2533;color:#e8eef8;
}

/* Lists (orders / addresses / payments) */
.nd-list{display:flex;flex-direction:column;gap:10px}
.nd-item{
  display:flex;gap:12px;align-items:flex-start;padding:12px;
  border:1px solid var(--line);border-radius:14px;background:var(--bg);
}
.nd-item-ico{font-size:22px;line-height:1;flex:0 0 auto}
.nd-item-body{min-width:0;flex:1}
.nd-item-title{font-size:13px;font-weight:900;color:var(--text)}
.nd-item-sub{font-size:11px;color:var(--muted);margin-top:3px;line-height:1.4}
.nd-item-meta{display:flex;flex-wrap:wrap;gap:6px;margin-top:6px}
.nd-chip{
  display:inline-flex;align-items:center;padding:3px 8px;border-radius:999px;
  font-size:10px;font-weight:800;background:#edf4ff;color:var(--navy);
}
.nd-chip.is-pending{background:#fff4e5;color:#b86a00}
.nd-chip.is-shipping{background:#e8f6ff;color:#0b6e99}
.nd-chip.is-done{background:#e7f8ee;color:var(--success)}
.nd-chip.is-other{background:#f1f3f7;color:var(--muted)}
.nd-item-actions{display:flex;flex-direction:column;gap:6px;flex:0 0 auto}
.nd-item-actions button{
  padding:7px 10px;border-radius:10px;border:1px solid var(--line);
  background:var(--card);color:var(--navy);font-size:11px;font-weight:800;
}
.nd-item-actions button.danger{color:var(--danger);border-color:#f5c6c6;background:#fff5f5}
.nd-security-box,.nd-help-box{padding:6px 2px}
.nd-security-box p,.nd-help-box p{font-size:13px;color:var(--muted);line-height:1.45;margin:0 0 12px}

/* Dark theme */
html[data-theme="dark"]{
  --bg:#0f141c;
  --card:#171e2a;
  --text:#e8eef8;
  --muted:#9aa6b8;
  --line:#2a3444;
  --shadow:0 10px 30px rgba(0,0,0,.35);
  --navy:#6ea8ff;
  --navy-2:#8bbcff;
  color-scheme:dark;
}
html[data-theme="dark"] body,
html[data-theme="dark"] .app{background:var(--bg);color:var(--text)}
html[data-theme="dark"] .top{
  background:rgba(23,30,42,.96);border-bottom-color:var(--line)
}
html[data-theme="dark"] .search,
html[data-theme="dark"] .icon-btn,
html[data-theme="dark"] .nd-profile-card,
html[data-theme="dark"] .nd-menu-group,
html[data-theme="dark"] .dash-card,
html[data-theme="dark"] .account-card,
html[data-theme="dark"] .nd-item{
  background:var(--card);border-color:var(--line);color:var(--text)
}
html[data-theme="dark"] .nd-seg{background:#121821;border-color:var(--line)}
html[data-theme="dark"] .nd-seg-btn.active{background:#3b82f6;color:#fff}
html[data-theme="dark"] .nd-menu-item,
html[data-theme="dark"] .nd-stat,
html[data-theme="dark"] .nd-group-title{color:var(--text)}
html[data-theme="dark"] .bottom-nav{
  background:rgba(23,30,42,.98);border-top-color:var(--line)
}
html[data-theme="dark"] .primary{background:#3b82f6;color:#fff}
html[data-theme="dark"] input,
html[data-theme="dark"] textarea,
html[data-theme="dark"] select{
  background:#121821;color:var(--text);border-color:var(--line)
}
html[data-theme="dark"] .nd-chip{background:#1e2a3d;color:#9ec1ff}
html[data-theme="dark"] .nd-chip.is-pending{background:#3a2e14;color:#ffc46b}
html[data-theme="dark"] .nd-chip.is-shipping{background:#123040;color:#7dd3fc}
html[data-theme="dark"] .nd-chip.is-done{background:#143024;color:#6ee7a8}
html[data-theme="dark"] .dash-empty{color:var(--muted)}
html[data-theme="dark"] .market-card,
html[data-theme="dark"] .cat{background:var(--card);border-color:var(--line)}
html[data-theme="dark"] .brand-name{color:#9ec1ff}


/* verified badge blue */
.nd-verified{
  display:inline-flex;align-items:center;justify-content:center;
  width:18px;height:18px;margin-left:6px;border-radius:50%;
  background:#2563eb;color:#fff;font-size:11px;font-weight:900;
  vertical-align:middle;
}


/* Verified mark — sits on the photo circle rim (bottom-right) */
.nd-avatar-wrap{
  position:relative;
  flex:0 0 auto;
  width:58px;
  height:58px;
  overflow:visible;
}
.nd-verified-on-avatar{
  position:absolute;
  right:0;
  bottom:0;
  transform:translate(15%, 15%);
  width:20px;
  height:20px;
  margin:0;
  padding:0;
  border-radius:50%;
  background:#2563eb;
  color:#fff;
  font-size:11px;
  font-weight:900;
  display:grid;
  place-items:center;
  border:2.5px solid #fff;
  box-shadow:0 1px 4px rgba(0,0,0,.2);
  z-index:5;
  line-height:1;
  pointer-events:none;
  box-sizing:border-box;
}
.nd-verified-on-avatar[hidden]{
  display:none !important;
}
.nd-profile-card{
  overflow:visible;
}

/* Verify form sections — premium order */
.nd-verify-form .nd-form-section{
  margin: 0 0 18px;
  padding: 0 0 14px;
  border-bottom: 1px solid #f1f5f9;
}
.nd-verify-form .nd-form-section:last-of-type{border-bottom:0}
.nd-form-section-title{
  font-size: 12px;
  font-weight: 800;
  color: #0b2e6f;
  letter-spacing: .04em;
  text-transform: uppercase;
  margin: 0 0 12px;
}
.nd-verify-form label{
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: #334155;
  margin: 0 0 12px;
}
.nd-verify-form label small{font-weight:600;color:#94a3b8;margin-left:4px}
.nd-verify-form label input,
.nd-verify-form label textarea{
  display: block;
  width: 100%;
  margin-top: 6px;
  box-sizing: border-box;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 11px 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  color: #0f172a;
  background: #fff;
}
.nd-verify-form label input:focus,
.nd-verify-form label textarea:focus{
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
@media (max-width:560px){
  .nd-verify-card{padding:14px}
  .nd-verify-form .nd-form-section{margin-bottom:14px;padding-bottom:12px}
}


/* ===== Premium Payment Methods ===== */
.pay-page{display:flex;flex-direction:column;gap:14px;max-width:560px}
.pay-hero{
  display:flex;gap:12px;align-items:flex-start;
  background:linear-gradient(135deg,#0b2e6f 0%,#1d4ed8 55%,#3b82f6 100%);
  color:#fff;border-radius:18px;padding:16px 18px;
  box-shadow:0 10px 28px rgba(29,78,216,.22);
}
.pay-hero-icon{
  width:44px;height:44px;border-radius:14px;
  background:rgba(255,255,255,.16);display:grid;place-items:center;
  font-size:22px;flex-shrink:0;
}
.pay-hero h4{margin:0 0 4px;font-size:16px;font-weight:800}
.pay-hero p{margin:0;font-size:12px;line-height:1.45;opacity:.9}

.pay-section{
  background:#fff;border:1px solid #e8eef8;border-radius:18px;
  padding:16px;box-shadow:0 4px 16px rgba(15,23,42,.04);
}
.pay-section-head{
  display:flex;align-items:center;justify-content:space-between;
  margin:0 0 12px;font-size:12px;font-weight:800;color:#0b2e6f;
  letter-spacing:.04em;text-transform:uppercase;
}

.pay-saved-list{display:flex;flex-direction:column;gap:10px;min-height:48px}
.pay-saved-empty{
  text-align:center;padding:22px 12px;color:#94a3b8;
  border:1.5px dashed #e2e8f0;border-radius:14px;background:#f8fafc;
}
.pay-saved-empty .ico{font-size:28px;display:block;margin-bottom:6px}
.pay-saved-empty p{margin:0;font-size:13px;font-weight:700}

.pay-saved-card{
  display:flex;align-items:center;gap:12px;
  border:1px solid #e8eef8;border-radius:14px;padding:12px 14px;
  background:linear-gradient(180deg,#fff,#f8fafc);
}
.pay-saved-card .logo{
  width:42px;height:42px;border-radius:12px;display:grid;place-items:center;
  color:#fff;font-weight:900;font-size:16px;flex-shrink:0;
}
.pay-saved-card .logo.kpay{background:linear-gradient(135deg,#16a34a,#15803d)}
.pay-saved-card .logo.wave{background:linear-gradient(135deg,#2563eb,#1d4ed8)}
.pay-saved-card .meta{flex:1;min-width:0}
.pay-saved-card .meta strong{display:block;font-size:14px;color:#0f172a}
.pay-saved-card .meta small{display:block;font-size:12px;color:#64748b;margin-top:2px}
.pay-saved-card .badge{
  font-size:10px;font-weight:800;padding:4px 8px;border-radius:999px;
  background:#eff6ff;color:#1d4ed8;border:1px solid #bfdbfe;
}

.pay-method-grid{
  display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:14px;
}
.pay-method{
  position:relative;display:flex;align-items:center;gap:10px;
  border:1.5px solid #e2e8f0;background:#fff;border-radius:16px;
  padding:14px 12px;cursor:pointer;text-align:left;
  transition:border-color .15s, box-shadow .15s, transform .12s;
}
.pay-method:hover{border-color:#93c5fd}
.pay-method.is-on{
  border-color:#2563eb;
  background:linear-gradient(180deg,#eff6ff,#fff);
  box-shadow:0 0 0 3px rgba(37,99,235,.12);
}
.pay-method-logo{
  width:40px;height:40px;border-radius:12px;display:grid;place-items:center;
  color:#fff;font-weight:900;font-size:16px;flex-shrink:0;
}
.pay-method-logo.pay-kpay{background:linear-gradient(135deg,#16a34a,#15803d)}
.pay-method-logo.pay-wave{background:linear-gradient(135deg,#2563eb,#1d4ed8)}
.pay-method-meta{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.pay-method-meta strong{font-size:13px;color:#0f172a}
.pay-method-meta small{font-size:11px;color:#64748b;font-weight:600}
.pay-method-check{
  width:22px;height:22px;border-radius:50%;border:1.5px solid #cbd5e1;
  display:grid;place-items:center;font-size:12px;color:transparent;flex-shrink:0;
  background:#fff;
}
.pay-method.is-on .pay-method-check{
  background:#2563eb;border-color:#2563eb;color:#fff;
}

.pay-fields{display:flex;flex-direction:column;gap:12px}
.pay-field{display:block;font-size:12px;font-weight:700;color:#334155}
.pay-field input{
  display:block;width:100%;margin-top:6px;box-sizing:border-box;
  border:1px solid #e2e8f0;border-radius:12px;padding:12px 14px;
  font:inherit;font-size:14px;font-weight:600;color:#0f172a;background:#fff;
}
.pay-field input:focus{
  outline:none;border-color:#2563eb;
  box-shadow:0 0 0 3px rgba(37,99,235,.12);
}
.pay-msg{margin:10px 0 0;font-size:12px;font-weight:700;color:#64748b;min-height:18px}
.pay-msg.is-error{color:#e11d48}
.pay-msg.is-ok{color:#047857}
.pay-submit{
  width:100%;margin-top:14px;border:0;border-radius:14px;padding:14px 16px;
  background:linear-gradient(135deg,#0b2e6f,#1d4ed8);color:#fff;
  font:inherit;font-size:14px;font-weight:800;cursor:pointer;
  box-shadow:0 8px 20px rgba(29,78,216,.25);
}
.pay-submit:active{transform:translateY(1px)}
.pay-secure{
  margin:10px 0 0;text-align:center;font-size:11px;font-weight:600;color:#94a3b8;
}

@media (max-width:560px){
  .pay-method-grid{grid-template-columns:1fr}
  .pay-hero{padding:14px}
}


/* ===== Security Settings ===== */
.sec-page{display:flex;flex-direction:column;gap:14px;max-width:560px}
.sec-hero{
  display:flex;gap:12px;align-items:flex-start;
  background:linear-gradient(135deg,#0f172a 0%,#1e293b 50%,#334155 100%);
  color:#fff;border-radius:18px;padding:16px 18px;
  box-shadow:0 10px 28px rgba(15,23,42,.2);
}
.sec-hero-icon{
  width:44px;height:44px;border-radius:14px;background:rgba(255,255,255,.12);
  display:grid;place-items:center;font-size:22px;flex-shrink:0;
}
.sec-hero h4{margin:0 0 4px;font-size:16px;font-weight:800}
.sec-hero p{margin:0;font-size:12px;opacity:.9;line-height:1.45}

.sec-card{
  background:#fff;border:1px solid #e8eef8;border-radius:18px;padding:16px 18px;
  box-shadow:0 4px 16px rgba(15,23,42,.04);
}
.sec-card-muted{background:#f8fafc}
.sec-card-head{display:flex;gap:12px;align-items:flex-start;margin-bottom:14px}
.sec-card-ico{
  width:40px;height:40px;border-radius:12px;background:#eff6ff;display:grid;place-items:center;
  font-size:18px;flex-shrink:0;
}
.sec-card-head strong{display:block;font-size:14px;color:#0f172a}
.sec-card-head small{display:block;font-size:12px;color:#64748b;margin-top:2px;font-weight:600}

.sec-form{display:flex;flex-direction:column;gap:12px}
.sec-field{display:block;font-size:12px;font-weight:700;color:#334155}
.sec-field input{
  display:block;width:100%;margin-top:6px;box-sizing:border-box;
  border:1px solid #e2e8f0;border-radius:12px;padding:12px 14px;
  font:inherit;font-size:14px;font-weight:600;color:#0f172a;background:#fff;
}
.sec-field input:focus{outline:none;border-color:#2563eb;box-shadow:0 0 0 3px rgba(37,99,235,.12)}
.sec-hints{display:flex;flex-wrap:wrap;gap:8px 14px;font-size:11px;font-weight:700;color:#94a3b8}
.sec-hints .ok{color:#047857}
.sec-hints .bad{color:#e11d48}

.sec-alert{
  border-radius:12px;padding:12px 14px;font-size:13px;font-weight:700;line-height:1.4;
}
.sec-alert.is-ok{background:#ecfdf5;color:#047857;border:1px solid #a7f3d0}
.sec-alert.is-error{background:#fef2f2;color:#b91c1c;border:1px solid #fecaca}
.sec-alert.is-info{background:#eff6ff;color:#1d4ed8;border:1px solid #bfdbfe}
.sec-alert.is-wait{background:#fff7ed;color:#c2410c;border:1px solid #fed7aa}

.sec-btn{
  width:100%;border:0;border-radius:14px;padding:14px 16px;
  background:linear-gradient(135deg,#0b2e6f,#1d4ed8);color:#fff;
  font:inherit;font-size:14px;font-weight:800;cursor:pointer;
  box-shadow:0 8px 20px rgba(29,78,216,.22);
}
.sec-btn:disabled{opacity:.65;cursor:not-allowed;box-shadow:none}
.sec-btn-secondary{
  background:#fff;color:#0b2e6f;border:1.5px solid #cbd5e1;box-shadow:none;
}
.sec-btn-secondary:hover{border-color:#2563eb;background:#f8fbff}
.sec-email-line{margin:0 0 12px;font-size:13px;color:#475569;font-weight:600}
.sec-email-line b{color:#0f172a}
.sec-cooldown{margin:10px 0 0;font-size:12px;font-weight:700;color:#c2410c}

.sec-link-btn{
  display:block;width:100%;margin-top:8px;border:0;background:none;
  color:#1d4ed8;font:inherit;font-size:13px;font-weight:800;cursor:pointer;
  text-align:center;padding:8px;
}
.sec-link-btn:hover{text-decoration:underline}
.sec-card.is-focus{box-shadow:0 0 0 3px rgba(37,99,235,.18);border-color:#93c5fd}

.sec-otp-step{display:flex;flex-direction:column;gap:12px}
#dashOtpCode{
  letter-spacing:0.35em;font-size:20px;font-weight:800;text-align:center;
}


/* ===== FIXED bottom nav — no jump on mobile scroll / browser chrome ===== */
.app{
  overflow-x: hidden; /* was clip — clip breaks position:fixed children in some WebKit */
  overflow-y: visible;
  transform: none !important;
  filter: none;
  perspective: none;
}
.bottom-nav{
  position: fixed !important;
  left: 50% !important;
  right: auto !important;
  bottom: 0 !important;
  top: auto !important;
  transform: translateX(-50%) !important;
  width: min(1180px, 100%) !important;
  max-width: 1180px !important;
  margin: 0 !important;
  z-index: 1000 !important;
  height: calc(58px + env(safe-area-inset-bottom, 0px)) !important;
  padding-bottom: env(safe-area-inset-bottom, 0px) !important;
  box-sizing: border-box !important;
  background: #fff !important;
  border-top: 1px solid #e6e9ef !important;
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}
@media (max-width: 760px){
  .bottom-nav{
    left: 0 !important;
    right: 0 !important;
    transform: none !important;
    width: 100% !important;
    max-width: none !important;
  }
}
.bottom-nav .nav-item{
  background: transparent !important;
}
.cart-bar{
  position: fixed !important;
  left: 50% !important;
  right: auto !important;
  bottom: calc(66px + env(safe-area-inset-bottom, 0px)) !important;
  transform: translateX(-50%) !important;
  z-index: 1001 !important;
}
/* content clearance so last cards not hidden under nav */
.content,
main.content,
#home,
.screen{
  padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px)) !important;
}
html[data-theme="dark"] .bottom-nav{
  background: #0f141c !important;
  border-top-color: #243041 !important;
}

/* Help Center Phase 1 */
.hc-page{display:flex;flex-direction:column;gap:14px;max-width:560px}
.hc-search-wrap{position:relative}
.hc-search{
  width:100%;box-sizing:border-box;border:1px solid #e2e8f0;border-radius:14px;
  padding:12px 14px;font:inherit;font-size:14px;font-weight:600;background:#fff;
}
.hc-search:focus{outline:none;border-color:#2563eb;box-shadow:0 0 0 3px rgba(37,99,235,.12)}
.hc-section-title{
  font-size:12px;font-weight:800;color:#0b2e6f;letter-spacing:.04em;
  text-transform:uppercase;margin:0 0 10px;
}
.hc-section{background:#fff;border:1px solid #e8eef8;border-radius:16px;padding:14px 16px}
.hc-contact-card{display:flex;flex-direction:column;gap:8px;margin-bottom:12px}
.hc-contact-row{display:flex;justify-content:space-between;gap:12px;font-size:13px}
.hc-contact-row span{color:#64748b;font-weight:600}
.hc-contact-row b{color:#0f172a;font-weight:800;text-align:right}
.hc-btn{
  width:100%;border:0;border-radius:14px;padding:13px 16px;
  background:linear-gradient(135deg,#0b2e6f,#1d4ed8);color:#fff;
  font:inherit;font-size:14px;font-weight:800;cursor:pointer;
}
.hc-orders{display:flex;flex-direction:column;gap:8px}
.hc-order-row{
  display:flex;align-items:center;gap:10px;padding:10px 12px;
  border:1px solid #e8eef8;border-radius:12px;background:#f8fafc;
}
.hc-order-row .meta{flex:1;min-width:0}
.hc-order-row strong{display:block;font-size:13px;color:#0f172a}
.hc-order-row small{display:block;font-size:11px;color:#64748b;margin-top:2px}
.hc-order-row button{
  border:1px solid #cbd5e1;background:#fff;border-radius:10px;
  padding:8px 12px;font-size:12px;font-weight:800;color:#0b2e6f;cursor:pointer;
}
.hc-empty{text-align:center;color:#94a3b8;font-size:13px;font-weight:600;padding:12px}
.hc-faq{display:flex;flex-direction:column;gap:8px}
.hc-faq-item{border:1px solid #e8eef8;border-radius:12px;overflow:hidden;background:#fff}
.hc-faq-item[hidden]{display:none}
.hc-faq-q{
  width:100%;text-align:left;border:0;background:#fff;padding:12px 14px;
  font:inherit;font-size:13px;font-weight:800;color:#0f172a;cursor:pointer;
  display:flex;justify-content:space-between;gap:10px;align-items:center;
}
.hc-faq-q::after{content:"＋";color:#94a3b8;font-weight:900}
.hc-faq-item.open .hc-faq-q::after{content:"－"}
.hc-faq-a{display:none;padding:0 14px 12px;font-size:12px;line-height:1.5;color:#475569;font-weight:600}
.hc-faq-item.open .hc-faq-a{display:block}
.hc-tickets{margin-top:12px;display:flex;flex-direction:column;gap:8px}
.hc-ticket{
  border:1px solid #e8eef8;border-radius:12px;padding:12px;background:#fff;
}
.hc-ticket strong{display:block;font-size:13px}
.hc-ticket small{display:block;color:#64748b;margin-top:4px;font-size:11px}
.hc-badge{
  display:inline-block;margin-top:8px;font-size:10px;font-weight:800;
  padding:3px 8px;border-radius:999px;background:#eff6ff;color:#1d4ed8;
}
.hc-badge.pending{background:#fff7ed;color:#c2410c}
.hc-badge.solved{background:#ecfdf5;color:#047857}

/* Premium Create Ticket modal */
.support-modal{position:fixed;inset:0;z-index:100060;display:grid;place-items:center;padding:16px}
.support-modal[hidden]{display:none!important}
.support-backdrop{position:absolute;inset:0;background:rgba(15,23,42,.48);backdrop-filter:blur(4px)}
.tk-dialog{
  position:relative;width:min(440px,100%);max-height:min(92vh,720px);overflow:auto;
  background:#fff;border-radius:22px;padding:0;
  box-shadow:0 24px 64px rgba(15,23,42,.28);
  border:1px solid rgba(255,255,255,.7);
}
.tk-head{
  display:flex;align-items:flex-start;justify-content:space-between;gap:12px;
  padding:18px 18px 12px;border-bottom:1px solid #eef2f7;
  background:linear-gradient(180deg,#f8fbff 0%,#fff 100%);
  border-radius:22px 22px 0 0;
}
.tk-kicker{display:block;font-size:10px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:#64748b;margin-bottom:4px}
.tk-head h3{margin:0;font-size:18px;font-weight:900;color:#0f172a}
.tk-close{
  width:36px;height:36px;border-radius:12px;border:1px solid #e2e8f0;background:#fff;
  color:#475569;display:grid;place-items:center;cursor:pointer;flex-shrink:0;
  box-shadow:0 2px 8px rgba(15,23,42,.04);
}
.tk-close:hover{border-color:#cbd5e1;color:#0f172a;background:#f8fafc}
.tk-form{padding:16px 18px 18px;display:flex;flex-direction:column;gap:12px}
.tk-field{display:flex;flex-direction:column;gap:6px;font-size:12px;font-weight:700;color:#334155}
.tk-field input,.tk-field select,.tk-field textarea{
  width:100%;box-sizing:border-box;border:1px solid #e2e8f0;border-radius:12px;
  padding:12px 14px;font:inherit;font-size:14px;font-weight:600;color:#0f172a;background:#fff;
}
.tk-field textarea{resize:vertical;min-height:100px}
.tk-field input:focus,.tk-field select:focus,.tk-field textarea:focus{
  outline:none;border-color:#2563eb;box-shadow:0 0 0 3px rgba(37,99,235,.12);
}
.tk-row{display:grid;grid-template-columns:1fr 1fr;gap:10px}
@media(max-width:480px){.tk-row{grid-template-columns:1fr}}
.tk-file-box{
  border:1.5px dashed #cbd5e1;border-radius:14px;padding:16px;text-align:center;
  background:#f8fafc;position:relative;cursor:pointer;
}
.tk-file-box input{position:absolute;inset:0;opacity:0;cursor:pointer}
.tk-file-label{font-size:13px;font-weight:700;color:#64748b}
.tk-submit{
  width:100%;border:0;border-radius:14px;padding:14px 16px;margin-top:4px;
  background:linear-gradient(135deg,#0b2e6f,#1d4ed8);color:#fff;
  font:inherit;font-size:14px;font-weight:800;cursor:pointer;
  box-shadow:0 10px 24px rgba(29,78,216,.25);
}
.tk-submit:disabled{opacity:.65;cursor:not-allowed;box-shadow:none}
.tk-msg{margin:0;font-size:12px;font-weight:700;color:#b91c1c}

/* =========================================================
   HELP CENTER — Phase 2 (chat, tickets, chatbot, seller chat)
   International-grade polish. Does not alter other UI.
   ========================================================= */
.hc-quick{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
  margin-bottom:4px;
}
.hc-quick-card{
  position:relative;
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:8px;
  padding:14px 12px;
  border:1px solid #e8eef8;
  border-radius:16px;
  background:linear-gradient(180deg,#ffffff 0%,#f7faff 100%);
  box-shadow:0 6px 18px rgba(15,37,74,.05);
  text-align:left;
  cursor:pointer;
  transition:transform .15s ease, box-shadow .15s ease;
}
.hc-quick-card:hover{
  transform:translateY(-1px);
  box-shadow:0 10px 24px rgba(15,37,74,.08);
}
.hc-quick-ico{
  width:36px;height:36px;border-radius:12px;
  display:grid;place-items:center;
  background:#eef4ff;font-size:18px;
}
.hc-quick-copy strong{
  display:block;font-size:12px;font-weight:800;color:#0b2e6f;line-height:1.2;
}
.hc-quick-copy small{
  display:block;font-size:10px;color:#64748b;font-weight:600;margin-top:2px;line-height:1.3;
}
.hc-unread-badge{
  position:absolute;top:8px;right:8px;
  min-width:18px;height:18px;padding:0 5px;
  border-radius:999px;background:#e11d48;color:#fff;
  font-size:10px;font-weight:800;
  display:grid;place-items:center;
}
@media(max-width:480px){
  .hc-quick{grid-template-columns:1fr;gap:8px}
  .hc-quick-card{flex-direction:row;align-items:center;gap:12px;padding:12px 14px}
}

/* Ticket cards Phase 2 */
.hc-tickets{margin-top:12px;display:flex;flex-direction:column;gap:10px}
.hc-ticket{
  border:1px solid #e8eef8;border-radius:14px;padding:12px 14px;
  background:#fff;display:grid;gap:6px;cursor:pointer;
  transition:border-color .15s ease, box-shadow .15s ease;
}
.hc-ticket:hover{border-color:#c7d7f5;box-shadow:0 6px 16px rgba(15,37,74,.06)}
.hc-ticket strong{font-size:13px;color:#0f172a;font-weight:800}
.hc-ticket small{font-size:11px;color:#64748b;font-weight:600}
.hc-ticket-row{display:flex;align-items:center;justify-content:space-between;gap:8px}
.hc-badge{
  display:inline-flex;align-items:center;gap:4px;
  padding:3px 8px;border-radius:999px;font-size:10px;font-weight:800;
  background:#f1f5f9;color:#475569;
}
.hc-badge.pending{background:#fff7ed;color:#c2410c}
.hc-badge.in_progress,.hc-badge.open{background:#eff6ff;color:#1d4ed8}
.hc-badge.solved{background:#ecfdf5;color:#047857}

/* Chat dialog */
.hm-chat-dialog,.hm-ticket-dialog{
  display:flex;flex-direction:column;max-height:min(86vh,640px);padding:0;overflow:hidden;
}
.hm-chat-head{
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:14px 16px;border-bottom:1px solid #eef2f7;
  background:linear-gradient(180deg,#f8fbff,#fff);
}
.hm-chat-head-left{display:flex;align-items:center;gap:10px;min-width:0}
.hm-chat-avatar{
  width:40px;height:40px;border-radius:14px;
  display:grid;place-items:center;background:#eef4ff;font-size:18px;flex:0 0 auto;
}
.hm-chat-head h3{margin:0;font-size:15px;font-weight:900;color:#0f172a}
.support-status{display:block;font-size:11px;font-weight:700;color:#16a34a;margin-top:2px}
.hm-chat-ticket-bar{
  display:flex;align-items:center;justify-content:space-between;gap:8px;
  padding:8px 14px;background:#f8fafc;border-bottom:1px solid #eef2f7;
  font-size:11px;font-weight:700;color:#64748b;
}
.hm-chat-ticket-bar strong{color:#0b2e6f;font-weight:800}
.hm-chat-note{
  padding:8px 14px;font-size:11px;font-weight:600;color:#64748b;
  background:#f8fafc;border-bottom:1px solid #eef2f7;
}
.chat-box{
  flex:1;overflow:auto;padding:14px;display:flex;flex-direction:column;gap:10px;
  background:#f4f7fb;min-height:220px;
}
.chat-msg{
  max-width:86%;padding:10px 12px;border-radius:14px;
  font-size:13px;line-height:1.45;font-weight:600;white-space:pre-wrap;word-break:break-word;
}
.chat-msg.support,.chat-msg.bot{
  align-self:flex-start;background:#fff;border:1px solid #e8eef8;color:#0f172a;
  border-bottom-left-radius:6px;
}
.chat-msg.customer,.chat-msg.user{
  align-self:flex-end;background:linear-gradient(135deg,#0b2e6f,#1d4ed8);color:#fff;
  border-bottom-right-radius:6px;
}
.chat-msg.system{
  align-self:center;background:transparent;color:#64748b;font-size:11px;
  border:0;padding:4px 8px;max-width:100%;text-align:center;
}
.chat-msg .chat-meta{display:block;font-size:10px;opacity:.7;margin-top:4px;font-weight:700}
.hm-chat-suggestions{
  display:flex;flex-wrap:wrap;gap:6px;padding:8px 12px;border-top:1px solid #eef2f7;background:#fff;
}
.hm-suggest{
  border:1px solid #dbe4f3;background:#f8fafc;border-radius:999px;
  padding:6px 10px;font-size:11px;font-weight:700;color:#0b2e6f;cursor:pointer;
}
.hm-suggest:hover{background:#eef4ff;border-color:#bfdbfe}
.chat-compose{
  display:flex;gap:8px;padding:10px 12px 12px;border-top:1px solid #eef2f7;background:#fff;
}
.chat-compose input{
  flex:1;border:1px solid #e2e8f0;border-radius:12px;padding:11px 12px;
  font:inherit;font-size:13px;font-weight:600;background:#f8fafc;
}
.chat-compose input:focus{outline:none;border-color:#2563eb;box-shadow:0 0 0 3px rgba(37,99,235,.12);background:#fff}
.chat-compose button{
  border:0;border-radius:12px;padding:0 16px;
  background:linear-gradient(135deg,#0b2e6f,#1d4ed8);color:#fff;
  font:inherit;font-size:13px;font-weight:800;cursor:pointer;
}

/* Ticket detail */
.hm-status-pill{
  display:inline-flex;align-items:center;padding:2px 8px;border-radius:999px;
  font-size:10px;font-weight:800;background:#fff7ed;color:#c2410c;margin-top:3px;
}
.hm-status-pill.in_progress{background:#eff6ff;color:#1d4ed8}
.hm-status-pill.solved{background:#ecfdf5;color:#047857}
.hm-td-meta{
  padding:10px 14px;font-size:12px;color:#64748b;font-weight:600;
  border-bottom:1px solid #eef2f7;background:#fafbfd;
  display:flex;flex-wrap:wrap;gap:8px 14px;
}
.hm-td-meta b{color:#0f172a}
.hm-td-thread{
  flex:1;overflow:auto;padding:14px;display:flex;flex-direction:column;gap:10px;
  background:#f4f7fb;min-height:200px;
}

/* Order row: add seller chat button space */
.hc-order-row .hc-order-actions{display:flex;gap:6px;flex-shrink:0}
.hc-order-row .hc-order-actions button{
  border:1px solid #cbd5e1;background:#fff;border-radius:10px;
  padding:8px 10px;font-size:11px;font-weight:800;color:#0b2e6f;cursor:pointer;
}
.hc-order-row .hc-order-actions button.hc-shop-chat{
  border-color:#fde68a;background:#fffbeb;color:#92400e;
}

/* =========================================================
   SEARCH + HEADER LAYOUT FIX (final, minimal)
   
   Desired closed state:
   [Logo] [Search icon]  ........  [Location] [Bell]
   
   - Search icon tightly next to logo
   - Location + Notification stay on the right (original places)
   - On open: search input expands inward from the icon (same row, no drop)
   ========================================================= */

/* Brand + search icon stick together on the left */
.brand-row{
  display: flex !important;
  align-items: center !important;
  flex-wrap: nowrap !important;
  gap: 8px !important;
}
.brand{
  flex: 0 0 auto !important;
  min-width: 0 !important;
  margin: 0 !important;
}
.search-row{
  position: relative !important;
  order: 0 !important;
  flex: 0 0 auto !important;
  flex-basis: auto !important;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  margin-right: auto !important;   /* pushes Location + Bell to the right */
  display: flex !important;
  align-items: center !important;
}

/* Only the icon is visible when closed */
.search-row .search{
  display: none !important;
}

/* Location & notification stay on the right */
.location,
.location-compact{
  margin-left: 0 !important;
  flex: 0 0 auto !important;
}
#notificationBtn{
  flex: 0 0 auto !important;
}

/* Open state: do not change the size of search-row (so right icons stay put) */
.search-row.is-open{
  position: relative !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  flex: 0 0 auto !important;
  width: auto !important;
  margin-right: auto !important;
  z-index: 80;
}

/* Keep toggle on top */
.search-row .search-toggle{
  position: relative;
  z-index: 95 !important;
}

/* Expand input from the icon, to the right (inward), overlay style */
.search-row.is-open .search{
  display: flex !important;
  position: absolute !important;
  left: 0 !important;
  top: 50% !important;
  transform: translateY(-50%);
  width: min(280px, 58vw) !important;
  max-width: 360px;
  z-index: 90;
  box-shadow: 0 10px 28px rgba(10,33,69,.14);
  background: #f8fafc;
  border: 1px solid var(--line, #e6e9ef);
  border-radius: 13px;
  padding: 9px 12px;
  padding-right: 46px;
  animation: none !important;
}

/* Kill every old rule that forced search to a second line or full width */
@media (max-width: 760px){
  .brand-row{
    flex-wrap: nowrap !important;
  }
  .search-row{
    order: 0 !important;
    flex: 0 0 auto !important;
    flex-basis: auto !important;
    margin-right: auto !important;
  }
  .search-row.is-open{
    top: auto !important;
  }
  .search-row.is-open .search{
    width: min(240px, 55vw) !important;
  }
}
@media (max-width: 420px){
  .search-row.is-open{
    top: auto !important;
  }
  .search-row.is-open .search{
    width: min(200px, 52vw) !important;
  }
}

/* =========================================================
   SUPPORT + LIVE CHAT — production polish (phone / tablet / desktop)
   ========================================================= */
.support-modal{
  position:fixed !important;
  inset:0 !important;
  z-index:100080 !important;
  display:grid !important;
  place-items:center;
  padding:12px;
  margin:0;
}
.support-modal[hidden]{display:none !important}
.support-backdrop{
  position:absolute;
  inset:0;
  background:rgba(15,23,42,.55);
  backdrop-filter:blur(6px);
  -webkit-backdrop-filter:blur(6px);
}
.support-dialog,
.hm-chat-dialog,
.hm-ticket-dialog,
.tk-dialog{
  position:relative;
  z-index:1;
  width:min(440px,100%);
  max-height:min(92vh,720px);
  background:#fff !important;
  border-radius:22px;
  box-shadow:0 24px 64px rgba(15,23,42,.32);
  border:1px solid rgba(226,232,240,.9);
  overflow:hidden;
  display:flex;
  flex-direction:column;
  padding:0;
}
.hm-chat-dialog,
.hm-ticket-dialog{
  max-height:min(88vh,640px);
  min-height:min(70vh,520px);
}
.support-close,
.hm-chat-head .support-close{
  width:36px;height:36px;border-radius:12px;
  border:1px solid #e2e8f0;background:#fff;color:#475569;
  display:grid;place-items:center;cursor:pointer;font-size:18px;line-height:1;
  flex-shrink:0;
}
.support-close:hover{background:#f8fafc;color:#0f172a}

/* Mobile / tablet: bottom sheet style for chat */
@media (max-width:760px){
  .support-modal{
    place-items:end center;
    padding:0;
  }
  .support-dialog,
  .hm-chat-dialog,
  .hm-ticket-dialog{
    width:100%;
    max-width:100%;
    max-height:92vh;
    min-height:72vh;
    border-radius:20px 20px 0 0;
    box-shadow:0 -8px 40px rgba(15,23,42,.2);
  }
  .tk-dialog{
    width:100%;
    max-width:100%;
    max-height:94vh;
    border-radius:20px 20px 0 0;
    margin:0;
  }
  .chat-box{min-height:40vh}
}
@media (max-width:420px){
  .hm-chat-suggestions{gap:5px;padding:8px 10px}
  .hm-suggest{font-size:10px;padding:6px 9px}
  .chat-compose{padding:8px 10px 10px}
  .chat-compose input{font-size:16px} /* prevent iOS zoom */
  .chat-compose button{padding:0 14px;min-height:44px}
  .hm-chat-head{padding:12px 12px}
}

/* Contact Support screen polish */
#support .hc-page{max-width:560px;margin:0 auto;padding-bottom:24px}
#support .support-list{gap:12px}
#support .support-option{
  width:100%;
  border:1px solid #e8eef8;
  background:#fff;
  box-shadow:0 6px 18px rgba(15,37,74,.04);
  transition:transform .15s ease, box-shadow .15s ease;
}
#support .support-option:active{transform:scale(.99)}
#support .hc-contact-card{
  background:#fff;
  border:1px solid #e8eef8;
  border-radius:16px;
  padding:14px 16px;
  margin-bottom:14px;
}

/* Prevent parent overflow from clipping modals */
body.hm-modal-open,
html.hm-modal-open{
  overflow:hidden !important;
}

.hc-need-more-text{
  margin:0 0 12px;font-size:13px;font-weight:600;color:#64748b;line-height:1.45;
}
.hc-need-more .hc-btn{margin-top:4px}

/* ——— Premium polish layer (safe, non-breaking) ——— */
.shop-card, .prod-card, .notification-item, .cat, .banner {
  transition: box-shadow .22s cubic-bezier(.22,1,.36,1), transform .18s cubic-bezier(.22,1,.36,1), border-color .2s ease;
}
.icon-btn {
  transition: background .2s ease, border-color .2s ease, box-shadow .2s ease, transform .15s ease;
}
.icon-btn:hover {
  box-shadow: 0 4px 12px rgba(11,46,111,.08);
}
.icon-btn:active {
  transform: scale(.96);
}
.search {
  transition: border-color .2s ease, box-shadow .2s ease;
}
.search:focus-within {
  border-color: #c5d4ef;
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
.bottom-nav .nav-item {
  transition: color .18s ease, background .18s ease, transform .15s ease;
}
.bottom-nav .nav-item:active {
  transform: scale(.96);
}
.cat:hover {
  box-shadow: 0 8px 22px rgba(10,33,69,.08);
}
/* Slightly more breathing room on content sections */
.content, .screen {
  /* keep existing padding; visual density reduced via card gaps/shadows */
}


/* ——— Premium V2.8 customer ——— */
.section-head h2,
.screen-title h2,
.brand-name {
  font-family: "Plus Jakarta Sans", "Noto Sans Myanmar", "Inter", system-ui, sans-serif;
  font-weight: 800;
  letter-spacing: -0.01em;
}
body, p, .shop-row-main p, .notification-copy p, .muted {
  font-weight: 500;
  line-height: 1.55;
}

/* More breathing room on home lists */
.shop-grid { gap: 16px; }
.cat-grid { gap: 14px; }
.home-carousel { gap: 12px; }

/* Card hover lift */
.shop-card:hover,
.market-card:hover,
.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(10, 33, 69, 0.1);
}

/* Empty states — premium */
.empty,
.compact-empty,
.notification-empty {
  padding: 40px 20px !important;
  text-align: center;
  color: var(--muted);
  background: #fff;
  border: 1px dashed var(--line);
  border-radius: 18px;
  font-weight: 500;
  line-height: 1.55;
  box-shadow: none;
}
.empty::before,
.compact-empty::before {
  content: "◇";
  display: block;
  width: 56px;
  height: 56px;
  margin: 0 auto 14px;
  border-radius: 18px;
  background: linear-gradient(145deg, #eef3fb, #e2eaf6);
  color: var(--navy);
  font-size: 22px;
  line-height: 56px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9);
}

/* Skeleton (use class hm-skeleton from design-system; local helpers) */
.skeleton-shop-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  padding: 0 0 12px;
}
.skeleton-shop-card .hm-skeleton-thumb { border-radius: 0; height: 120px; }
.skeleton-row {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  margin-bottom: 10px;
}

/* Content safe area — reinforce */
.content {
  padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px));
}

/* Soft page enter for main screens */
.screen.active,
.home-section {
  animation: hm-fade-in 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
}
@keyframes hm-fade-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 700px) {
  .section-head { margin: 20px 0 12px; }
  .home-sections-container .home-section { margin: 0 0 22px; }
  .shop-grid { gap: 12px; }
  .cat-grid { gap: 10px; }
  .content {
    padding-left: 14px;
    padding-right: 14px;
    padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px));
  }
}

@media (prefers-reduced-motion: reduce) {
  .screen.active,
  .home-section,
  .shop-card:hover,
  .market-card:hover {
    animation: none;
    transform: none;
  }
}

/* ——— Banner / hero text always readable ——— */
.hero,
.hero-slide,
.banner {
  color: #fff !important;
}
.hero-copy,
.hero-copy h1,
.hero-copy p,
.hero-label,
.banner h3,
.banner p {
  color: #fff !important;
  text-shadow: 0 1px 2px rgba(0,0,0,.45), 0 4px 16px rgba(0,0,0,.25);
}
.hero-slide.has-image:before {
  background: linear-gradient(90deg, rgba(5,29,74,.92) 0%, rgba(5,29,74,.62) 50%, rgba(5,29,74,.2) 100%) !important;
}
.hero .hero-btn {
  background: #ffbf19 !important;
  color: #0b1220 !important;
  text-shadow: none !important;
  font-weight: 800;
}
.banner-b h3,
.banner-b p {
  color: #fff !important;
  text-shadow: 0 1px 3px rgba(0,0,0,.35);
}

/* Profile card text must stay white on blue gradient */
.nd-profile-card,
.nd-profile-card * {
  color: #fff;
}
.nd-profile-card .nd-name,
.nd-profile-card h2.nd-name,
.nd-profile-card #dashName {
  color: #fff !important;
  text-shadow: 0 1px 2px rgba(0,0,0,.25);
}
.nd-profile-card .nd-email,
.nd-profile-card .nd-meta,
.nd-profile-card .nd-meta-item,
.nd-profile-card p {
  color: rgba(255,255,255,.95) !important;
}

/* V2.9 image blur + skeleton cat + form focus */
.hm-img-wrap { display:block; width:100%; height:100%; border-radius:inherit; }
.hm-img-wrap img.cat-image,
.cat-image-wrap-inner img {
  width:100%; height:100%; object-fit:cover; opacity:0; transition:opacity .35s ease;
}
.hm-img-wrap img.is-loaded,
.cat-image-wrap-inner img.is-loaded { opacity:1; }
.skeleton-cat {
  background:#fff; border:1px solid var(--line); border-radius:16px; padding:12px 8px; min-height:116px;
}
.auth-card input:focus,
.auth-card textarea:focus,
.auth-card select:focus,
.dash-form input:focus,
.dash-form textarea:focus,
.dash-form select:focus,
.search:focus-within {
  border-color:#c5d4ef !important;
  box-shadow:0 0 0 3px rgba(11,46,111,.14);
}
.bottom-nav .nav-item .hm-icon { stroke: currentColor; }
.bottom-nav .nav-item.active .hm-icon { stroke: var(--navy); }

html[data-theme="dark"] .nd-profile-card {
  background:linear-gradient(135deg,#0b2e6f 0%,#1a5bb8 55%,#15448d 100%) !important;
  color:#fff !important;
}
html[data-theme="dark"] .nd-profile-card .nd-name,
html[data-theme="dark"] .nd-profile-card h2,
html[data-theme="dark"] .nd-profile-card .nd-email,
html[data-theme="dark"] .nd-profile-card .nd-meta { color:#fff !important; }


/* Home first-paint skeleton (avoid empty flash) */
.hm-home-skeleton{padding:4px 0 24px;display:flex;flex-direction:column;gap:22px}
.hm-skel-banner{height:160px;border-radius:20px;width:100%}
.hm-skel-section{display:flex;flex-direction:column;gap:10px}
.hm-skel-cats{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}
.hm-skel-cat{height:96px;border-radius:16px}
.hm-skel-shops{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
.hm-skel-shop{height:140px;border-radius:16px}
@media(max-width:700px){
  .hm-skel-banner{height:130px}
  .hm-skel-cats{grid-template-columns:repeat(2,1fr)}
  .hm-skel-shops{grid-template-columns:repeat(2,1fr)}
  .hm-skel-shop{height:120px}
}


/* ========== Premium Shop Storefront ========== */
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}
.sf-head{padding:0;border:0;background:transparent;box-shadow:none}
.sf-hero{margin:0 0 4px;background:#fff;border-radius:0 0 20px 20px;overflow:visible;box-shadow:0 8px 28px rgba(15,23,42,.06)}
.sf-cover{position:relative;height:200px;overflow:hidden;background:linear-gradient(135deg,#0b2e6f,#1a5bb8)}
.sf-cover img{width:100%;height:100%;object-fit:cover;display:block}
.sf-cover-fallback{width:100%;height:100%;background:linear-gradient(135deg,#0b2e6f 0%,#1e4a9a 55%,#ff8a00 160%)}
.sf-cover-grad{position:absolute;inset:0;background:linear-gradient(180deg,rgba(0,0,0,.12) 0%,rgba(0,0,0,.35) 100%);pointer-events:none}
.sf-back{position:absolute;left:12px;top:12px;z-index:2;width:36px;height:36px;border-radius:50%;border:0;background:rgba(255,255,255,.95);color:#0b2e6f;font-size:18px;font-weight:800;cursor:pointer;box-shadow:0 4px 14px rgba(0,0,0,.15)}
.sf-status{position:absolute;right:12px;top:12px;z-index:2;padding:6px 12px;border-radius:999px;font-size:11px;font-weight:800;background:#16a34a;color:#fff;box-shadow:0 4px 12px rgba(22,163,74,.35)}
.sf-status.is-closed{background:#94a3b8;box-shadow:none}
.sf-identity{display:grid;grid-template-columns:72px 1fr;gap:12px;align-items:start;padding:0 16px;margin-top:-36px;position:relative;z-index:3}
.sf-logo{width:72px;height:72px;border-radius:18px;border:3px solid #fff;background:#fff;overflow:hidden;flex:none;box-shadow:0 8px 20px rgba(15,23,42,.14);display:grid;place-items:center;font-weight:900;font-size:22px;color:#0b2e6f}
.sf-logo img{width:100%;height:100%;object-fit:cover}
.sf-id-text{min-width:0;padding:40px 0 0 0;background:transparent;border:0;box-shadow:none;border-radius:0}
.sf-name{margin:0;font-size:20px;font-weight:800;color:#0f172a;line-height:1.25;letter-spacing:-.02em}
.sf-meta{display:flex;flex-wrap:wrap;gap:6px 10px;margin-top:6px;font-size:12px;color:#64748b;font-weight:600;align-items:center}
.sf-verified{color:#0b2e6f;background:#eef4ff;padding:2px 8px;border-radius:999px;font-size:11px}
.sf-desc{margin:8px 0 0;font-size:13px;color:#64748b;line-height:1.45;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.sf-actions{display:grid;grid-template-columns:1fr 1fr 1.2fr;gap:8px;padding:12px 16px 14px}
.sf-act{flex:1;height:40px;border-radius:12px;border:1px solid #e2e8f0;background:#fff;font-size:12px;font-weight:700;color:#0f172a;cursor:pointer}
.sf-act-primary{background:#0b2e6f;color:#fff;border-color:#0b2e6f}
.sf-act:active{transform:scale(.98)}
.sf-chips{padding:8px 10px 4px;position:sticky;top:0;z-index:5;background:linear-gradient(#f4f7fb,#f4f7fb 80%,transparent)}
.sf-products{padding:4px 12px 100px;gap:12px}
.sf-products.is-food,.sf-products.is-cosmetic,.sf-products.is-market,.sf-products.is-default{
  display:grid;grid-template-columns:1fr 1fr;gap:12px;
}
.sf-card{background:#fff;border:1px solid #e8eef6;border-radius:16px;overflow:hidden;box-shadow:0 4px 16px rgba(15,23,42,.04);display:flex;flex-direction:column}
.sf-card-media{aspect-ratio:1;background:linear-gradient(135deg,#e8eef8,#dfe7f4);position:relative}
.sf-card-media img{width:100%;height:100%;object-fit:cover;opacity:1;transition:opacity .35s ease}
.sf-card-media img.is-loaded{opacity:1}
.sf-ph{display:grid;place-items:center;height:100%;font-size:28px}
.sf-card-body{padding:10px;display:flex;flex-direction:column;gap:4px;flex:1}
.sf-card-top{display:flex;justify-content:space-between;gap:6px;align-items:flex-start}
.sf-card-top b{font-size:13px;font-weight:800;color:#0f172a;line-height:1.25}
.sf-card-sub{font-size:10px;color:#94a3b8}
.sf-card .desc{font-size:10px;color:#64748b;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.sf-card-row{display:flex;align-items:center;justify-content:space-between;gap:6px;margin-top:auto;padding-top:6px}
.sf-card .price{font-size:13px;font-weight:800;color:#0b2e6f}
.sf-qty button{width:28px;height:28px;border-radius:9px}
.sf-qty .sf-add,.sf-qty button[data-plus]{background:#ff8a00;border-color:#ff8a00;color:#fff}
.sf-products.is-electronics,.sf-products.is-pharmacy,.sf-products.is-fashion{
  display:flex;flex-direction:column;gap:10px;
}
.sf-row{display:flex;gap:12px;padding:12px;background:#fff;border:1px solid #e8eef6;border-radius:16px;box-shadow:0 2px 10px rgba(15,23,42,.03)}
.sf-row-media{width:88px;height:88px;border-radius:14px;overflow:hidden;flex:none;background:#e8eef8}
.sf-row-media img{width:100%;height:100%;object-fit:cover}
.sf-row-body{flex:1;min-width:0;display:flex;flex-direction:column}
.sf-row .sf-card-top b{font-size:14px}
@media(max-width:480px){
  .sf-cover{height:160px}
  .sf-identity{grid-template-columns:64px 1fr;padding:0 12px;margin-top:-32px}
  .sf-logo{width:64px;height:64px;border-radius:16px}
  .sf-id-text{padding-top:36px}
  .sf-name{font-size:17px}
  .sf-actions{grid-template-columns:1fr 1fr 1fr;padding:10px 12px 12px}
}
#shopDetail .screen-title{display:none}


/* Shop chat modal + follow state */
.sf-act.is-on{background:#fff1f2;border-color:#fecdd3;color:#be123c}
.sf-chat-modal{position:fixed;inset:0;z-index:100060;background:rgba(15,23,42,.45);display:grid;place-items:end center;padding:12px}
.sf-chat-modal[hidden]{display:none!important}
.sf-chat-sheet{width:min(100%,420px);max-height:min(78vh,560px);background:#fff;border-radius:18px 18px 14px 14px;display:flex;flex-direction:column;box-shadow:0 20px 50px rgba(0,0,0,.25);overflow:hidden}
.sf-chat-head{display:flex;align-items:center;justify-content:space-between;padding:14px 16px;border-bottom:1px solid #e8eef6;font-weight:800}
.sf-chat-head button{border:0;background:#f1f5f9;width:32px;height:32px;border-radius:10px;cursor:pointer}
.sf-chat-messages{flex:1;overflow:auto;padding:14px;display:flex;flex-direction:column;gap:8px;background:#f8fafc}
.sf-chat-bubble{max-width:85%;padding:10px 12px;border-radius:14px;font-size:13px;line-height:1.4}
.sf-chat-bubble.me{align-self:flex-end;background:#0b2e6f;color:#fff;border-bottom-right-radius:4px}
.sf-chat-bubble.them{align-self:flex-start;background:#fff;border:1px solid #e2e8f0;border-bottom-left-radius:4px}
.sf-chat-empty{text-align:center;color:#94a3b8;font-size:12px;padding:24px}
.sf-chat-form{display:flex;gap:8px;padding:10px 12px;border-top:1px solid #e8eef6;background:#fff}
.sf-chat-form input{flex:1;height:42px;border-radius:12px;border:1px solid #e2e8f0;padding:0 12px;font:inherit}
.sf-chat-form button{height:42px;padding:0 16px;border-radius:12px;border:0;background:#ff8a00;color:#fff;font-weight:800;cursor:pointer}

/* Role dashboard switch (between language & theme) */
.nd-lang-theme-row{display:flex;flex-wrap:wrap;align-items:center;gap:8px;justify-content:space-between}
.nd-role-dash-btn{
  display:inline-flex;align-items:center;gap:6px;
  height:36px;padding:0 14px;border-radius:999px;
  background:linear-gradient(135deg,#0b2e6f,#1e4a9a);color:#fff!important;
  font-size:12px;font-weight:800;text-decoration:none;
  box-shadow:0 4px 14px rgba(11,46,111,.28);
  white-space:nowrap;
}
.nd-role-dash-btn:hover{filter:brightness(1.08)}
.nd-role-dash-btn[hidden]{display:none!important}

.sf-hours{display:inline-flex;align-items:center;gap:4px;font-size:12px;color:#475569;margin-top:6px;margin-right:10px;font-weight:600}
.sf-status.is-open{background:#16a34a;color:#fff}
.sf-status.is-closed{background:#94a3b8;color:#fff}

.sf-contact-row{display:flex;flex-wrap:wrap;gap:4px 12px;margin-top:6px}


/* Shop reviews */
.sf-reviews{margin:12px 14px 28px}
.sf-reviews-inner{background:#fff;border:1px solid #e8eef6;border-radius:16px;padding:14px 16px}
.sf-reviews-head{display:flex;align-items:center;gap:8px;margin-bottom:10px;font-size:15px}
.sf-review-form{display:flex;flex-direction:column;gap:8px;margin-bottom:14px;padding-bottom:14px;border-bottom:1px solid #f1f5f9}
.sf-star-pick{display:flex;gap:4px}
.sf-star-pick button{border:0;background:transparent;font-size:22px;color:#cbd5e1;cursor:pointer;padding:2px 4px;line-height:1}
.sf-star-pick button.is-on{color:#f59e0b}
.sf-review-form textarea{width:100%;border:1px solid #e2e8f0;border-radius:12px;padding:10px 12px;font:inherit;resize:vertical;min-height:64px}
.sf-review-form .btn{align-self:flex-start;height:40px;padding:0 16px;border-radius:12px;border:0;background:#0b2e6f;color:#fff;font-weight:700;cursor:pointer}
.sf-review-item{padding:10px 0;border-bottom:1px solid #f1f5f9}
.sf-review-item:last-child{border-bottom:0}
.sf-review-stars{color:#f59e0b;letter-spacing:1px;font-size:14px}
.sf-review-body{font-size:13px;color:#334155;margin-top:4px;line-height:1.45}
.sf-review-meta{font-size:11px;color:#94a3b8;margin-top:4px}

/* 5-tab bottom nav */
.bottom-nav{grid-template-columns:repeat(5,minmax(0,1fr)) !important}
.nav-item.nav-post .nav-post-icon{
  width:36px;height:36px;border-radius:12px;
  display:inline-flex;align-items:center;justify-content:center;
  background:linear-gradient(135deg,#0b2e6f,#1d4ed8);color:#fff;
}
.nav-item.nav-post .nav-post-icon .hm-icon{stroke:#fff;color:#fff;width:18px;height:18px}
.nav-item.nav-post.active .nav-post-icon{box-shadow:0 4px 14px rgba(11,46,111,.35)}

/* Posts feed */
.posts-top{display:flex;align-items:center;justify-content:space-between;padding:12px 14px 6px}
.posts-top h2{margin:0;font-size:18px;font-weight:800;color:#0f172a}
.posts-compose-btn{border:0;background:#0b2e6f;color:#fff;border-radius:12px;padding:8px 14px;font-weight:800;font-size:13px;cursor:pointer}
.posts-compose{margin:0 14px 12px;background:#fff;border:1px solid #e8eef6;border-radius:16px;padding:12px}
.posts-compose textarea{width:100%;border:1px solid #e2e8f0;border-radius:12px;padding:10px 12px;font:inherit;resize:vertical;min-height:72px}
.posts-compose-actions{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:8px}
.posts-compose-actions .btn{height:40px;padding:0 16px;border:0;border-radius:12px;background:#0b2e6f;color:#fff;font-weight:800;cursor:pointer}
.posts-feed{padding:0 14px 24px;display:flex;flex-direction:column;gap:12px}
.posts-card{background:#fff;border:1px solid #e8eef6;border-radius:16px;padding:14px;box-shadow:0 4px 16px rgba(15,23,42,.04)}
.posts-card-head{display:flex;align-items:center;gap:10px;margin-bottom:8px}
.posts-avatar{width:40px;height:40px;border-radius:999px;background:#e8eef8;color:#0b2e6f;display:flex;align-items:center;justify-content:center;font-weight:800;overflow:hidden;flex-shrink:0}
.posts-avatar img{width:100%;height:100%;object-fit:cover}
.posts-author{font-weight:800;font-size:14px;color:#0f172a}
.posts-time{font-size:11px;color:#94a3b8;margin-top:2px}
.posts-body{font-size:14px;line-height:1.5;color:#334155;white-space:pre-wrap;word-break:break-word}
.posts-verified{display:inline-flex;align-items:center;gap:4px;font-size:10px;font-weight:800;color:#0b2e6f;background:#eef4ff;border-radius:999px;padding:2px 8px;margin-left:6px}


/* FB-style composer */
.posts-composer-trigger{
  margin:0 14px 12px;width:calc(100% - 28px);display:flex;align-items:center;gap:12px;
  border:1px solid #e8eef6;background:#fff;border-radius:16px;padding:12px 14px;
  text-align:left;cursor:pointer;box-shadow:0 2px 10px rgba(15,23,42,.04);
}
.posts-composer-av{
  width:40px;height:40px;border-radius:999px;background:#e8eef8;color:#0b2e6f;
  display:inline-flex;align-items:center;justify-content:center;font-weight:800;overflow:hidden;flex-shrink:0;
}
.posts-composer-av img{width:100%;height:100%;object-fit:cover}
.posts-composer-placeholder{color:#94a3b8;font-weight:600;font-size:14px}
.posts-gate{margin:0 14px 12px}
.posts-gate-card{
  background:#fff;border:1px solid #e8eef6;border-radius:16px;padding:20px 16px;text-align:center;
  box-shadow:0 4px 16px rgba(15,23,42,.05);
}
.posts-gate-icon{font-size:28px;margin-bottom:8px}
.posts-gate-card strong{display:block;font-size:15px;color:#0f172a;margin-bottom:6px}
.posts-gate-card p{margin:0 0 14px;color:#64748b;font-size:13px;line-height:1.45}
.posts-gate-card .btn{height:42px;padding:0 18px;border:0;border-radius:12px;background:#0b2e6f;color:#fff;font-weight:800;cursor:pointer}
.posts-meta{min-width:0}
.posts-feed{padding-bottom:90px}

.posts-compose-tools{display:flex;flex-wrap:wrap;gap:10px;margin-top:10px;align-items:center}
.posts-vis-select{font-size:12px;font-weight:700;color:#475569;display:flex;align-items:center;gap:8px}
.posts-vis-select select{height:36px;border-radius:10px;border:1px solid #e2e8f0;padding:0 10px;font:inherit}
.posts-image-btn{display:inline-flex;align-items:center;gap:6px;height:36px;padding:0 12px;border-radius:10px;border:1px solid #e2e8f0;background:#f8fafc;font-size:12px;font-weight:800;cursor:pointer}
.posts-image-preview{display:block;max-width:100%;max-height:220px;border-radius:12px;margin-top:10px;object-fit:cover}
.posts-image{margin-top:10px;border-radius:14px;overflow:hidden;background:#f1f5f9}
.posts-image img{display:block;width:100%;max-height:360px;object-fit:cover}
.posts-actions{display:flex;flex-wrap:wrap;gap:6px;margin-top:12px;padding-top:10px;border-top:1px solid #f1f5f9}
.posts-act{border:0;background:#f8fafc;border-radius:999px;padding:7px 12px;font-size:12px;font-weight:700;color:#475569;cursor:pointer}
.posts-act.is-on{background:#eef4ff;color:#0b2e6f}
.posts-owner-actions{margin-left:auto;display:flex;gap:6px}
.posts-owner-actions button{border:0;background:transparent;color:#64748b;font-size:12px;font-weight:700;cursor:pointer}
.posts-vis{font-size:10px;color:#64748b;font-weight:700;margin-left:4px}
.posts-comments{margin-top:10px;padding-top:10px;border-top:1px solid #f1f5f9}
.posts-comment{font-size:13px;color:#334155;padding:6px 0;line-height:1.4}
.posts-comment b{color:#0f172a;margin-right:6px}
.posts-comment-form{display:flex;gap:8px;margin-top:8px}
.posts-comment-form input{flex:1;height:38px;border-radius:12px;border:1px solid #e2e8f0;padding:0 12px;font:inherit}
.posts-comment-form button{height:38px;padding:0 14px;border:0;border-radius:12px;background:#0b2e6f;color:#fff;font-weight:800;cursor:pointer}

#dashAvatar img, #dashAvatarPreview img, .nd-avatar img, .nd-avatar-btn img,
.posts-composer-av img, .posts-avatar img {
  width:100% !important; height:100% !important; object-fit:cover !important;
  border-radius:inherit; display:block;
}
#dashAvatar, #dashAvatarPreview, .nd-avatar-btn {
  overflow:hidden; border-radius:999px;
}





/* ===== Posts = same full width as Home ===== */
body.hm-posts-on{
  background:var(--bg, #f6f7fa) !important;
}
body.hm-posts-on .app{
  background:var(--bg, #f6f7fa) !important;
}

#posts.screen.active{
  display:block !important;
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 !important;
  background:transparent !important;
  min-height:calc(100vh - 120px);
}

/* Use the SAME content width as Home — no nested phone column */
.posts-shell{
  width:100% !important;
  max-width:none !important;
  margin:0 !important;
  padding:0 0 24px !important;
  box-sizing:border-box;
}
.posts-top{ display:none !important; }

.posts-composer-trigger{
  width:100%;
  box-sizing:border-box;
  display:flex;
  align-items:center;
  gap:12px;
  border:1px solid var(--line, #e6e9ef);
  background:#fff;
  border-radius:16px;
  padding:12px 14px;
  margin:0 0 12px;
  text-align:left;
  cursor:pointer;
  box-shadow:var(--shadow, 0 10px 28px rgba(18,38,72,.06));
}
.posts-composer-av{
  width:42px; height:42px; border-radius:50%;
  background:#e8eef8; overflow:hidden; flex-shrink:0;
  display:inline-flex; align-items:center; justify-content:center; font-weight:800; color:var(--navy,#0b2e6f);
}
.posts-composer-av img{ width:100%; height:100%; object-fit:cover; display:block; }
.posts-composer-placeholder{
  flex:1; color:#94a3b8; font-size:14px; font-weight:600;
  background:#f8fafc; border-radius:999px; padding:10px 14px;
}

.posts-compose{
  width:100%; box-sizing:border-box;
  background:#fff; border:1px solid var(--line,#e6e9ef);
  border-radius:16px; padding:14px; margin:0 0 12px;
  box-shadow:var(--shadow, 0 10px 28px rgba(18,38,72,.06));
}
.posts-compose textarea{
  width:100%; border:0; outline:none; resize:vertical; min-height:80px;
  font:inherit; font-size:15px; line-height:1.5; color:#15233a; background:transparent;
}
.posts-compose-tools{
  display:flex; flex-wrap:wrap; gap:8px; margin-top:10px;
  padding-top:10px; border-top:1px solid #eef2f7; align-items:center;
}
select.posts-vis-select{
  height:36px; border-radius:10px; border:1px solid #e2e8f0;
  padding:0 10px; font:inherit; background:#f8fafc; font-weight:700; font-size:12px;
}
.posts-image-btn{
  display:inline-flex; align-items:center; height:36px; padding:0 12px;
  border-radius:10px; border:1px solid #e2e8f0; background:#f8fafc;
  font-size:12px; font-weight:800; cursor:pointer; color:#16894f;
}
.posts-image-preview-grid{
  display:grid; grid-template-columns:repeat(auto-fill,minmax(96px,1fr));
  gap:8px; margin-top:10px;
}
.posts-image-preview-grid img{
  width:100%; aspect-ratio:1; object-fit:cover; border-radius:12px; background:#eef2f7;
}
.posts-compose-actions{ display:flex; justify-content:flex-end; margin-top:12px; }
.posts-compose-actions .btn{
  height:40px; padding:0 18px; border:0; border-radius:12px;
  background:var(--navy,#0b2e6f); color:#fff; font-weight:800; cursor:pointer;
}
#postsComposeHint{ display:none; }

.posts-feed{
  width:100%;
  display:flex; flex-direction:column; gap:12px;
  padding:0; margin:0;
}
.posts-card{
  width:100%; box-sizing:border-box;
  background:#fff;
  border:1px solid var(--line,#e6e9ef);
  border-radius:16px;
  padding:14px;
  box-shadow:var(--shadow, 0 10px 28px rgba(18,38,72,.06));
}
.posts-card-head{ display:flex; align-items:flex-start; gap:10px; margin-bottom:10px; }
.posts-avatar{
  width:44px; height:44px; border-radius:50%; background:#e8eef8;
  overflow:hidden; flex-shrink:0;
  display:flex; align-items:center; justify-content:center; font-weight:800; color:var(--navy,#0b2e6f);
}
.posts-avatar img{ width:100%; height:100%; object-fit:cover; display:block; }
.posts-meta{ flex:1; min-width:0; }
.posts-author{
  font-weight:800; font-size:15px; color:#15233a;
  display:flex; gap:6px; flex-wrap:wrap; align-items:center;
}
.posts-time{ font-size:12px; color:#6f7c91; margin-top:2px; }
.posts-verified{
  font-size:10px; font-weight:800; color:var(--navy,#0b2e6f);
  background:#eef4ff; border-radius:999px; padding:2px 8px;
}
.posts-body{
  font-size:14px; line-height:1.5; color:#15233a;
  white-space:pre-wrap; word-break:break-word;
}
.posts-body:empty{ display:none; }

.posts-image-grid{
  margin-top:12px; display:grid; gap:4px;
  border-radius:14px; overflow:hidden;
}
.posts-image-grid.g1{ grid-template-columns:1fr; }
.posts-image-grid.g2,
.posts-image-grid.g3,
.posts-image-grid.g4{ grid-template-columns:1fr 1fr; }
.posts-image-grid img{
  width:100%; max-height:420px; object-fit:cover; background:#eef2f7; display:block;
}

.posts-actions{
  display:flex; align-items:center; gap:4px;
  margin-top:12px; padding-top:10px;
  border-top:1px solid #eef2f7;
}
.posts-act{
  flex:1; border:0; background:#f8fafc; border-radius:10px;
  padding:10px 6px; font-size:12px; font-weight:700; color:#6f7c91;
  cursor:pointer; text-align:center;
}
.posts-act:hover{ background:#f1f5f9; }
.posts-act.is-on{ color:var(--navy,#0b2e6f); background:#eef4ff; }
.posts-owner-actions{ display:flex; gap:4px; }
.posts-owner-actions button{
  border:0; background:transparent; color:#6f7c91;
  font-size:12px; font-weight:700; cursor:pointer; padding:6px 8px; border-radius:8px;
}
.posts-owner-actions button:hover{ background:#f8fafc; color:#15233a; }

#postsGate.posts-gate{
  position:fixed !important; inset:0 !important; z-index:10060 !important;
  margin:0 !important; padding:20px !important;
  background:rgba(15,23,42,.45) !important;
  display:flex !important; align-items:center !important; justify-content:center !important;
}
#postsGate.posts-gate[hidden]{ display:none !important; }
#postsGate .posts-gate-card{
  background:#fff; border-radius:16px; padding:24px 20px;
  text-align:center; width:min(400px,100%);
  box-shadow:0 20px 50px rgba(15,23,42,.2);
}
#postsGate .posts-gate-card .btn{
  height:42px; padding:0 18px; border:0; border-radius:12px;
  background:var(--navy,#0b2e6f); color:#fff; font-weight:800; cursor:pointer;
}
#postsGate .posts-gate-card{ position:relative; }
#postsGate .posts-gate-x{
  position:absolute; top:10px; right:10px;
  width:34px; height:34px; border:0; border-radius:10px;
  background:#f1f5f9; color:#475569; font-size:20px; line-height:1;
  cursor:pointer; display:flex; align-items:center; justify-content:center;
}
#postsGate .posts-gate-x:hover{ background:#e2e8f0; color:#0f172a; }
#postsGate .posts-gate-close-link{
  border:0; background:transparent; color:#65676b; font-weight:600; cursor:pointer;
  padding:6px 10px; border-radius:8px;
}
#postsGate .posts-gate-close-link:hover{ background:#f1f5f9; color:#0f172a; }

.posts-comments{ margin-top:10px; padding-top:10px; border-top:1px solid #eef2f7; }
.posts-comment{ font-size:13px; padding:6px 0; line-height:1.45; color:#15233a; }
.posts-comment-form{ display:flex; gap:8px; margin-top:8px; }
.posts-comment-form input{
  flex:1; height:40px; border-radius:12px; border:1px solid #e2e8f0;
  padding:0 12px; background:#f8fafc; font:inherit;
}
.posts-comment-form button{
  height:40px; padding:0 14px; border:0; border-radius:12px;
  background:var(--navy,#0b2e6f); color:#fff; font-weight:800; cursor:pointer;
}
.posts-feed .empty, .posts-feed .hm-empty{
  background:#fff; border:1px solid var(--line,#e6e9ef); border-radius:16px;
  padding:40px 16px; text-align:center; color:#6f7c91;
}

/* Custom delete post modal */
.posts-del-modal{
  position:fixed; inset:0; z-index:10070;
  display:flex; align-items:center; justify-content:center;
  padding:20px;
}
.posts-del-modal[hidden]{ display:none !important; }
.posts-del-backdrop{
  position:absolute; inset:0; background:rgba(15,23,42,.5);
}
.posts-del-card{
  position:relative; z-index:1;
  width:min(360px,100%);
  background:#fff; border-radius:18px;
  padding:24px 20px 18px; text-align:center;
  box-shadow:0 20px 50px rgba(15,23,42,.25);
}
.posts-del-icon{ font-size:32px; margin-bottom:8px; }
.posts-del-card strong{
  display:block; font-size:17px; color:#15233a; margin-bottom:6px;
}
.posts-del-card p{
  margin:0 0 18px; font-size:13.5px; color:#6f7c91; line-height:1.45;
}
.posts-del-actions{
  display:flex; gap:10px; justify-content:center;
}
.posts-del-cancel{
  flex:1; height:42px; border-radius:12px;
  border:1px solid #e2e8f0; background:#f8fafc;
  color:#334155; font-weight:800; font-size:14px; cursor:pointer;
}
.posts-del-confirm{
  flex:1; height:42px; border-radius:12px; border:0;
  background:#dc2626; color:#fff; font-weight:800; font-size:14px; cursor:pointer;
}
.posts-del-confirm:hover{ background:#b91c1c; }
.posts-vis{ font-size:11px; font-weight:700; color:#6f7c91; background:#f1f5f9; border-radius:999px; padding:2px 8px; }

/* Premium action bar */
.posts-actions{
  display:flex; align-items:stretch; gap:6px;
  margin-top:12px; padding-top:10px;
  border-top:1px solid #eef2f7;
}
.posts-act{
  flex:1; display:inline-flex; align-items:center; justify-content:center; gap:6px;
  border:0; background:transparent; border-radius:10px;
  padding:10px 6px; font-size:12px; font-weight:700; color:#64748b;
  cursor:pointer; transition: background .15s, color .15s, transform .1s;
}
.posts-act svg{ flex-shrink:0; }
.posts-act:hover{ background:#f1f5f9; color:#0f172a; }
.posts-act:active{ transform:scale(.97); }
.posts-act.is-like.is-on{ color:#2563eb; background:#eff6ff; }
.posts-act.is-like.is-on svg{ fill:#2563eb; stroke:#2563eb; }
.posts-act.is-dislike.is-on{ color:#dc2626; background:#fef2f2; }
.posts-act.is-dislike.is-on svg{ fill:#dc2626; stroke:#dc2626; }

/* Photo collage templates (1–10) */
.posts-collage{
  margin-top:12px;
  display:grid;
  gap:3px;
  border-radius:14px;
  overflow:hidden;
  background:#e2e8f0;
  max-height:520px;
}
.posts-collage-cell{
  position:relative; min-height:0; overflow:hidden; background:#cbd5e1;
}
.posts-collage-cell img{
  width:100%; height:100%; object-fit:cover; display:block;
}

/* 1 photo */
.posts-collage.t1{ grid-template-columns:1fr; max-height:520px; }
.posts-collage.t1 .c1{ aspect-ratio:16/10; max-height:520px; }
.posts-collage.t1 .c1 img{ max-height:520px; }

/* 2 photos */
.posts-collage.t2{ grid-template-columns:1fr 1fr; }
.posts-collage.t2 .posts-collage-cell{ aspect-ratio:1/1.1; }

/* 3 photos — large left, two stacked right */
.posts-collage.t3{
  grid-template-columns:1.2fr 1fr;
  grid-template-rows:1fr 1fr;
  height:min(420px, 55vw);
}
.posts-collage.t3 .c1{ grid-row:1 / span 2; }

/* 4 photos — 2×2 */
.posts-collage.t4{
  grid-template-columns:1fr 1fr;
  grid-template-rows:1fr 1fr;
  height:min(440px, 60vw);
}

/* 5 photos — 2 top + 3 bottom */
.posts-collage.t5{
  grid-template-columns:repeat(6, 1fr);
  grid-template-rows:1.1fr 1fr;
  height:min(460px, 62vw);
}
.posts-collage.t5 .c1{ grid-column:1 / span 3; }
.posts-collage.t5 .c2{ grid-column:4 / span 3; }
.posts-collage.t5 .c3{ grid-column:1 / span 2; }
.posts-collage.t5 .c4{ grid-column:3 / span 2; }
.posts-collage.t5 .c5{ grid-column:5 / span 2; }

/* 6 photos — 3×2 */
.posts-collage.t6{
  grid-template-columns:1fr 1fr 1fr;
  grid-template-rows:1fr 1fr;
  height:min(420px, 58vw);
}

/* 7 photos */
.posts-collage.t7{
  grid-template-columns:repeat(6, 1fr);
  grid-template-rows:1.15fr 1fr 1fr;
  height:min(480px, 68vw);
}
.posts-collage.t7 .c1{ grid-column:1 / span 3; grid-row:1; }
.posts-collage.t7 .c2{ grid-column:4 / span 3; grid-row:1; }
.posts-collage.t7 .c3{ grid-column:1 / span 2; grid-row:2; }
.posts-collage.t7 .c4{ grid-column:3 / span 2; grid-row:2; }
.posts-collage.t7 .c5{ grid-column:5 / span 2; grid-row:2; }
.posts-collage.t7 .c6{ grid-column:1 / span 3; grid-row:3; }
.posts-collage.t7 .c7{ grid-column:4 / span 3; grid-row:3; }

/* 8 photos — 4×2 */
.posts-collage.t8{
  grid-template-columns:repeat(4, 1fr);
  grid-template-rows:1fr 1fr;
  height:min(400px, 55vw);
}

/* 9 photos — 3×3 */
.posts-collage.t9{
  grid-template-columns:1fr 1fr 1fr;
  grid-template-rows:1fr 1fr 1fr;
  height:min(480px, 70vw);
}

/* 10 photos */
.posts-collage.t10{
  grid-template-columns:repeat(6, 1fr);
  grid-template-rows:1.1fr 1fr 1fr;
  height:min(500px, 72vw);
}
.posts-collage.t10 .c1{ grid-column:1 / span 3; }
.posts-collage.t10 .c2{ grid-column:4 / span 3; }
.posts-collage.t10 .c3,
.posts-collage.t10 .c4,
.posts-collage.t10 .c5,
.posts-collage.t10 .c6,
.posts-collage.t10 .c7,
.posts-collage.t10 .c8,
.posts-collage.t10 .c9,
.posts-collage.t10 .c10{ grid-column:span 1.5; }
.posts-collage.t10 .c3{ grid-column:1 / span 2; }
.posts-collage.t10 .c4{ grid-column:3 / span 2; }
.posts-collage.t10 .c5{ grid-column:5 / span 2; }
.posts-collage.t10 .c6{ grid-column:1 / span 2; }
.posts-collage.t10 .c7{ grid-column:3 / span 2; }
.posts-collage.t10 .c8{ grid-column:5 / span 1; }
.posts-collage.t10 .c9{ grid-column:1 / span 3; grid-row:3; }
.posts-collage.t10 .c10{ grid-column:4 / span 3; grid-row:3; }

/* Composer preview collage */
.posts-composer-collage{
  margin-top:12px;
  position:relative;
}
.posts-img-remove{
  position:absolute; top:6px; right:6px; z-index:2;
  width:28px; height:28px; border-radius:999px; border:0;
  background:rgba(15,23,42,.72); color:#fff;
  font-size:16px; line-height:1; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
}
.posts-img-remove:hover{ background:#dc2626; }
.posts-compose-tools .posts-image-btn{
  background:linear-gradient(135deg,#ecfdf5,#f0fdf4);
  border-color:#bbf7d0; color:#15803d;
}

/* Navy action icons */
.posts-act{
  color:#0b2e6f !important;
}
.posts-act svg{ color:#0b2e6f; fill:#0b2e6f; }
.posts-act:hover{
  background:#eef4ff !important;
  color:#0b2e6f !important;
}
.posts-act.is-like.is-on{
  color:#0b2e6f !important;
  background:#e0eaff !important;
}
.posts-act.is-like.is-on svg{ fill:#0b2e6f; }
.posts-act.is-dislike.is-on{
  color:#0b2e6f !important;
  background:#e0eaff !important;
}
.posts-act.is-dislike.is-on svg{ fill:#0b2e6f; }

/* Edit modal */
.posts-edit-modal{
  position:fixed; inset:0; z-index:10070;
  display:flex; align-items:center; justify-content:center;
  padding:20px;
}
.posts-edit-modal[hidden]{ display:none !important; }
.posts-edit-backdrop{
  position:absolute; inset:0; background:rgba(15,23,42,.5);
}
.posts-edit-card{
  position:relative; z-index:1;
  width:min(440px,100%);
  background:#fff; border-radius:18px;
  padding:18px 18px 16px;
  box-shadow:0 20px 50px rgba(15,23,42,.25);
}
.posts-edit-head{
  display:flex; align-items:center; justify-content:space-between;
  margin-bottom:12px;
}
.posts-edit-head strong{ font-size:16px; color:#15233a; }
.posts-edit-x{
  width:34px; height:34px; border:0; border-radius:10px;
  background:#f1f5f9; color:#475569; font-size:20px; cursor:pointer;
}
.posts-edit-card textarea{
  width:100%; box-sizing:border-box;
  min-height:120px; border:1px solid #e2e8f0; border-radius:12px;
  padding:12px; font:inherit; font-size:14px; line-height:1.5;
  color:#15233a; resize:vertical; outline:none;
}
.posts-edit-card textarea:focus{ border-color:#0b2e6f; box-shadow:0 0 0 3px rgba(11,46,111,.12); }
.posts-edit-msg{ margin:8px 0 0; font-size:12px; color:#dc2626; }
.posts-edit-actions{
  display:flex; gap:10px; justify-content:flex-end; margin-top:14px;
}
.posts-edit-cancel{
  height:40px; padding:0 16px; border-radius:12px;
  border:1px solid #e2e8f0; background:#f8fafc;
  color:#334155; font-weight:800; cursor:pointer;
}
.posts-edit-save{
  height:40px; padding:0 18px; border-radius:12px; border:0;
  background:#0b2e6f; color:#fff; font-weight:800; cursor:pointer;
}
.posts-edit-save:hover{ background:#0a275f; }

/* Unified compose box */
.posts-compose{
  display:flex; flex-direction:column; gap:0;
}
.posts-compose textarea{
  border:0 !important; box-shadow:none !important;
  min-height:90px; padding:4px 2px;
}
.posts-compose-tools{
  border-top:1px solid #eef2f7;
  margin-top:4px; padding-top:10px;
}

.posts-edit-card-lg{ width:min(520px,100%); max-height:min(92vh,720px); overflow:auto; }
.posts-edit-box{
  border:1px solid #e2e8f0; border-radius:14px; padding:12px;
  background:#fff;
}
.posts-edit-box textarea{
  border:0 !important; box-shadow:none !important; padding:4px 2px;
  min-height:90px; width:100%; resize:vertical; font:inherit; font-size:15px;
  outline:none;
}
.posts-edit-box #postsEditPreview{
  margin-top:10px;
}
.posts-edit-box #postsEditPreview:not([hidden]){
  display:grid !important;
}
.posts-edit-box #postsEditLayoutPicker{
  margin-top:8px;
}
.posts-edit-tools{ margin-top:8px; padding-top:8px; border-top:1px solid #eef2f7; }

.posts-share-modal{
  position:fixed; inset:0; z-index:10070;
  display:flex; align-items:center; justify-content:center; padding:20px;
}
.posts-share-modal[hidden]{ display:none !important; }
.posts-share-backdrop{ position:absolute; inset:0; background:rgba(15,23,42,.5); }
.posts-share-card{
  position:relative; z-index:1; width:min(400px,100%);
  background:#fff; border-radius:18px; padding:18px;
  box-shadow:0 20px 50px rgba(15,23,42,.25);
}
.posts-share-card input{
  width:100%; box-sizing:border-box; height:42px;
  border:1px solid #e2e8f0; border-radius:12px; padding:0 12px;
  font:inherit; font-size:13px; margin:8px 0 12px; background:#f8fafc;
}
.posts-share-copy{
  width:100%; height:42px; border:0; border-radius:12px;
  background:#0b2e6f; color:#fff; font-weight:800; cursor:pointer;
}
.posts-comment-err{
  font-size:12px; color:#dc2626; margin-bottom:8px;
}

/* Single photo — full width, no gray side */
.posts-collage.t1{
  grid-template-columns:1fr !important;
  max-height:none !important;
  height:auto !important;
}
.posts-collage.t1 .c1,
.posts-collage.t1 .posts-collage-cell{
  aspect-ratio:auto !important;
  max-height:none !important;
  height:auto !important;
}
.posts-collage.t1 img{
  width:100% !important;
  height:auto !important;
  max-height:640px !important;
  object-fit:contain !important;
  background:#000;
}

/* FB-style compose actions */
.posts-compose-actions{
  display:flex !important;
  justify-content:flex-end !important;
  align-items:center;
  margin-top:10px;
  padding-top:10px;
  border-top:1px solid #eef2f7;
}
.posts-compose-actions .btn,
#postsSubmitBtn{
  width:auto !important;
  min-width:96px;
  height:36px !important;
  padding:0 20px !important;
  border-radius:8px !important;
  font-size:14px !important;
}

.posts-layout-picker{
  display:flex; flex-wrap:wrap; gap:6px; align-items:center;
  margin-top:10px; padding:8px 0 0;
}
.posts-tpl-label{
  font-size:12px; font-weight:800; color:#64748b; margin-right:4px;
}
.posts-tpl-btn{
  width:32px; height:32px; border-radius:8px;
  border:1px solid #e2e8f0; background:#f8fafc;
  font-size:12px; font-weight:800; color:#0b2e6f; cursor:pointer;
}
.posts-tpl-btn.is-on{
  background:#0b2e6f; color:#fff; border-color:#0b2e6f;
}

/* FB-style compose bottom bar */
.posts-compose-bar{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
  margin-top:10px;
  padding-top:10px;
  border-top:1px solid #e4e6eb;
}
.posts-compose-grow{ flex:1; min-width:8px; }
.posts-compose-bar .posts-vis-select{
  height:36px;
  border-radius:8px;
  border:1px solid #ccd0d5;
  padding:0 10px;
  background:#f0f2f5;
  font-size:13px;
  font-weight:600;
}
.posts-compose-bar .posts-image-btn{
  height:36px;
  padding:0 12px;
  border-radius:8px;
  border:0;
  background:#e7f8ed;
  color:#045c32;
  font-size:13px;
  font-weight:700;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
}
.posts-submit-btn{
  height:36px;
  padding:0 18px;
  border:0;
  border-radius:8px;
  background:#0b2e6f;
  color:#fff;
  font-weight:800;
  font-size:14px;
  cursor:pointer;
}
.posts-submit-btn:disabled{ opacity:.55; cursor:default; }
.posts-compose-msg{
  margin-top:8px;
  font-size:12px;
  color:#65676b;
}
.posts-compose-msg:not([hidden]){ display:block; }

/* Visual layout picker */
.posts-layout-picker{
  display:flex; flex-wrap:wrap; gap:8px; align-items:center;
  margin-top:10px;
}
.posts-tpl-btn{
  width:44px; height:36px; padding:4px;
  border-radius:8px; border:2px solid #e2e8f0;
  background:#fff; cursor:pointer;
  display:inline-flex; align-items:center; justify-content:center;
}
.posts-tpl-btn.is-on{
  border-color:#0b2e6f; background:#eef4ff;
}
.posts-tpl-ico{
  display:grid; gap:2px; width:100%; height:100%;
}
.posts-tpl-ico.t-t2{ grid-template-columns:1fr 1fr; }
.posts-tpl-ico.t-t3{ grid-template-columns:1.2fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.t-t3 i:first-child{ grid-row:span 2; }
.posts-tpl-ico.t-t4{ grid-template-columns:1fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.t-t5{ grid-template-columns:1fr 1fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.t-t5 i:nth-child(1),
.posts-tpl-ico.t-t5 i:nth-child(2){ grid-column:span 1; }
.posts-tpl-ico.t-t6{ grid-template-columns:1fr 1fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico i{
  display:block; background:#94a3b8; border-radius:2px; min-height:6px;
}
.posts-tpl-btn.is-on .posts-tpl-ico i{ background:#0b2e6f; }

/* Comment delete */
.posts-comment{
  display:flex; align-items:flex-start; gap:8px;
  justify-content:space-between;
}
.posts-comment-main{ flex:1; min-width:0; }
.posts-cmt-del{
  border:0; background:transparent; color:#94a3b8;
  font-size:16px; line-height:1; cursor:pointer;
  padding:2px 6px; border-radius:6px; flex-shrink:0;
}
.posts-cmt-del:hover{ background:#fef2f2; color:#dc2626; }

/* Layout switch animation */
.posts-collage-anim{
  animation: postsCollageIn .28s ease;
}
@keyframes postsCollageIn{
  from{ opacity:.35; transform:scale(.985); }
  to{ opacity:1; transform:scale(1); }
}
.posts-collage-cell{
  transition: transform .25s ease, opacity .25s ease;
}
.posts-composer-collage .posts-collage-cell img,
.posts-collage .posts-collage-cell img{
  cursor:pointer;
}

/* 10 layout icon buttons */
.posts-layout-picker{
  display:flex; flex-wrap:wrap; gap:6px; align-items:center;
  margin-top:10px; padding:4px 0;
}
.posts-tpl-btn{
  width:40px; height:32px; padding:3px;
  border-radius:8px; border:2px solid #e2e8f0;
  background:#fff; cursor:pointer;
}
.posts-tpl-btn.is-on{
  border-color:#0b2e6f; background:#eef4ff;
  box-shadow:0 0 0 2px rgba(11,46,111,.12);
}
.posts-tpl-ico{
  display:grid; gap:2px; width:100%; height:100%;
  grid-template-columns:1fr 1fr; grid-auto-rows:1fr;
}
.posts-tpl-ico i{
  display:block; background:#94a3b8; border-radius:2px; min-height:4px;
}
.posts-tpl-btn.is-on .posts-tpl-ico i{ background:#0b2e6f; }
.posts-tpl-ico .wide{ grid-column: span 2; }
.posts-tpl-ico .tall{ grid-row: span 2; }
.posts-tpl-ico .hero{ grid-column: span 2; grid-row: span 2; }
.posts-tpl-ico.ico-L2{ grid-template-columns:1.2fr 1fr; }
.posts-tpl-ico.ico-L5,
.posts-tpl-ico.ico-L8{ grid-template-columns:1fr 1fr 1fr; }

/* Simple image viewer (composer + feed) — no zoom chrome */
.posts-lightbox{
  position:fixed; inset:0; z-index:10080;
  background:rgba(15,23,42,.92);
  display:flex; align-items:center; justify-content:center;
  padding:48px 56px 56px;
}
.posts-lightbox[hidden]{ display:none !important; }
.posts-lightbox img{
  max-width:min(920px,100%); max-height:min(86vh,100%);
  object-fit:contain; border-radius:10px;
  background:#0b1220;
  box-shadow:0 16px 48px rgba(0,0,0,.4);
}
.posts-lightbox-x{
  position:absolute; top:14px; right:14px;
  width:40px; height:40px; border:0; border-radius:999px;
  background:rgba(255,255,255,.14); color:#fff;
  font-size:24px; line-height:1; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
}
.posts-lightbox-x:hover{ background:rgba(255,255,255,.28); }
.posts-lightbox-nav{
  position:absolute; top:50%; transform:translateY(-50%);
  width:44px; height:44px; border:0; border-radius:999px;
  background:rgba(255,255,255,.14); color:#fff;
  font-size:28px; line-height:1; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
}
.posts-lightbox-nav:hover{ background:rgba(255,255,255,.28); }
.posts-lightbox-nav.prev{ left:12px; }
.posts-lightbox-nav.next{ right:12px; }
.posts-lightbox-nav[hidden]{ display:none !important; }
.posts-lightbox-count{
  position:absolute; bottom:16px; left:50%; transform:translateX(-50%);
  color:rgba(255,255,255,.85); font-size:13px; font-weight:600;
  background:rgba(0,0,0,.35); padding:6px 12px; border-radius:999px;
}

/* Comment edit/delete */
.posts-cmt-acts{
  display:flex; gap:4px; flex-shrink:0;
}
.posts-cmt-edit, .posts-cmt-del{
  border:0; background:transparent; color:#64748b;
  font-size:11px; font-weight:700; cursor:pointer;
  padding:4px 8px; border-radius:6px;
}
.posts-cmt-edit:hover{ background:#eef4ff; color:#0b2e6f; }
.posts-cmt-del:hover{ background:#fef2f2; color:#dc2626; }
.posts-cmt-editor{
  margin-top:6px; width:100%;
}
.posts-cmt-editor input{
  width:100%; box-sizing:border-box; height:36px;
  border:1px solid #e2e8f0; border-radius:10px; padding:0 10px; font:inherit;
}
.posts-cmt-editor-actions{
  display:flex; gap:8px; margin-top:6px;
}
.posts-cmt-editor-actions button{
  height:32px; padding:0 12px; border-radius:8px; border:0;
  font-weight:800; font-size:12px; cursor:pointer;
}
.posts-cmt-editor-actions [data-cmt-save]{ background:#0b2e6f; color:#fff; }
.posts-cmt-editor-actions [data-cmt-cancel]{ background:#f1f5f9; color:#334155; }

/* ===== 10 distinct collage layouts ===== */
.posts-collage{
  display:grid !important;
  gap:4px;
  border-radius:14px;
  overflow:hidden;
  background:#0f172a10;
}
.posts-collage .posts-collage-cell{
  min-height:0; overflow:hidden; background:#cbd5e1;
  transition: all .28s ease;
}
.posts-collage .posts-collage-cell img{
  width:100%; height:100%; object-fit:cover; display:block;
}

/* layout-1: single / stacked full */
.posts-collage.layout-1{ grid-template-columns:1fr; }
.posts-collage.layout-1 .posts-collage-cell{ max-height:520px; }
.posts-collage.layout-1.n1 img{ height:auto; max-height:560px; object-fit:contain; background:#000; }

/* layout-2: equal columns */
.posts-collage.layout-2{ grid-template-columns:1fr 1fr; }
.posts-collage.layout-2 .posts-collage-cell{ aspect-ratio:1; }

/* layout-3: left tall + right stack */
.posts-collage.layout-3{
  grid-template-columns:1.3fr 1fr;
  grid-auto-rows:1fr;
  min-height:280px; max-height:480px;
}
.posts-collage.layout-3 .c1{ grid-row:1 / span 2; min-height:280px; }
.posts-collage.layout-3.n3 .c1{ grid-row:1 / span 2; }
.posts-collage.layout-3.n4 .c1{ grid-row:1 / span 3; }

/* layout-4: 2x2 */
.posts-collage.layout-4{
  grid-template-columns:1fr 1fr;
  grid-auto-rows:minmax(140px,1fr);
  max-height:480px;
}

/* layout-5: top wide + bottom row */
.posts-collage.layout-5{
  grid-template-columns:1fr 1fr 1fr;
  grid-template-rows:1.3fr 1fr;
  max-height:480px;
}
.posts-collage.layout-5 .c1{ grid-column:1 / -1; }

/* layout-6: 3 columns */
.posts-collage.layout-6{
  grid-template-columns:1fr 1fr 1fr;
  grid-auto-rows:minmax(120px,1fr);
  max-height:460px;
}

/* layout-7: left tall + 2x2 right */
.posts-collage.layout-7{
  grid-template-columns:1.2fr 1fr 1fr;
  grid-template-rows:1fr 1fr;
  max-height:460px;
}
.posts-collage.layout-7 .c1{ grid-row:1 / span 2; }

/* layout-8: two wide rows + grid */
.posts-collage.layout-8{
  grid-template-columns:1fr 1fr 1fr;
  grid-template-rows:1.1fr 1fr 1fr;
  max-height:500px;
}
.posts-collage.layout-8 .c1{ grid-column:1 / span 2; }
.posts-collage.layout-8 .c2{ grid-column:3; }

/* layout-9: hero top + strip */
.posts-collage.layout-9{
  grid-template-columns:1fr 1fr 1fr 1fr;
  grid-template-rows:1.6fr 1fr;
  max-height:500px;
}
.posts-collage.layout-9 .c1{ grid-column:1 / -1; }

/* layout-10: mosaic */
.posts-collage.layout-10{
  grid-template-columns:1.2fr 1fr 1fr;
  grid-template-rows:1fr 1fr 1fr;
  max-height:520px;
}
.posts-collage.layout-10 .c1{ grid-row:1 / span 2; }
.posts-collage.layout-10 .c2{ grid-column:2 / span 2; }

.posts-collage-anim{
  animation: postsCollageIn .42s cubic-bezier(.22,1,.36,1);
}
@keyframes postsCollageIn{
  0%{ opacity:0; transform:scale(.94); filter:blur(2px); }
  55%{ opacity:1; filter:blur(0); }
  100%{ opacity:1; transform:scale(1); filter:blur(0); }
}

/* cells glide into new grid slots */
.posts-composer-collage .posts-collage-cell{
  transition: transform .4s cubic-bezier(.22,1,.36,1), opacity .35s ease, grid-area .4s ease;
}
.posts-composer-collage.posts-collage-anim .posts-collage-cell{
  animation: postsCellIn .4s cubic-bezier(.22,1,.36,1) both;
}
.posts-composer-collage.posts-collage-anim .c1{ animation-delay:.02s; }
.posts-composer-collage.posts-collage-anim .c2{ animation-delay:.05s; }
.posts-composer-collage.posts-collage-anim .c3{ animation-delay:.08s; }
.posts-composer-collage.posts-collage-anim .c4{ animation-delay:.11s; }
.posts-composer-collage.posts-collage-anim .c5{ animation-delay:.14s; }
.posts-composer-collage.posts-collage-anim .c6{ animation-delay:.17s; }
.posts-composer-collage.posts-collage-anim .c7{ animation-delay:.2s; }
.posts-composer-collage.posts-collage-anim .c8{ animation-delay:.23s; }
.posts-composer-collage.posts-collage-anim .c9{ animation-delay:.26s; }
.posts-composer-collage.posts-collage-anim .c10{ animation-delay:.29s; }
@keyframes postsCellIn{
  from{ opacity:0; transform:scale(.92) translateY(6px); }
  to{ opacity:1; transform:scale(1) translateY(0); }
}

/* ===== Layout picker icon grids (composer) ===== */
.posts-tpl-ico.ico-L1{ grid-template-columns:1fr; }
.posts-tpl-ico.ico-L2{ grid-template-columns:1fr 1fr; }
.posts-tpl-ico.ico-L3{ grid-template-columns:1.3fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.ico-L3 i.tall{ grid-row:1 / span 2; }
.posts-tpl-ico.ico-L4{ grid-template-columns:1fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.ico-L5{ grid-template-columns:1fr 1fr 1fr; grid-template-rows:1.2fr 1fr; }
.posts-tpl-ico.ico-L5 i.wide{ grid-column:1 / -1; }
.posts-tpl-ico.ico-L6{ grid-template-columns:1fr 1fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.ico-L7{ grid-template-columns:1.2fr 1fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.ico-L7 i.tall{ grid-row:1 / span 2; }
.posts-tpl-ico.ico-L8{ grid-template-columns:1fr 1fr 1fr; grid-template-rows:1.1fr 1fr; }
.posts-tpl-ico.ico-L8 i.wide{ grid-column:1 / span 2; }
.posts-tpl-ico.ico-L9{ grid-template-columns:1fr 1fr 1fr 1fr; grid-template-rows:1.4fr 1fr; }
.posts-tpl-ico.ico-L9 i.hero{ grid-column:1 / -1; }
.posts-tpl-ico.ico-L10{ grid-template-columns:1.2fr 1fr 1fr; grid-template-rows:1fr 1fr; }
.posts-tpl-ico.ico-L10 i.tall{ grid-row:1 / span 2; }
.posts-tpl-ico.ico-L10 i.wide{ grid-column:2 / span 2; }
.posts-tpl-ico i{ min-height:5px; }

/* Composer: multi-image layout-1 stacks visibly (no hard clip of lower cells) */
.posts-composer-collage.layout-1{
  max-height:none;
  overflow:visible;
}
.posts-composer-collage.layout-1 .posts-collage-cell{
  max-height:280px;
  aspect-ratio:16/10;
}
.posts-composer-collage.layout-1.n1 .posts-collage-cell{
  max-height:520px;
}
/* Ensure cells always have size during layout switch */
.posts-composer-collage .posts-collage-cell{
  min-height:72px;
}
.posts-composer-collage{
  transition: max-height .28s ease;
}
