/* =========================================================
   Kimo-ish Theme (cps_eshop)
   - Inspired by kimostore.net structure (utility bar + mega menu + product cards)
   - Colors are driven by CSS variables injected from CPS Eshop Settings
   ========================================================= */

:root{
  --kimo-primary: var(--cps-primary, #111827);
  --kimo-primary-dark: var(--cps-primary-dark, var(--kimo-primary));
  --kimo-primary-light: var(--cps-primary-light, var(--kimo-primary));
  --kimo-secondary: var(--cps-secondary, #0f172a);
  --kimo-accent: var(--cps-accent, #ef4444);
  --kimo-bg: var(--cps-bg, #ffffff);

  /* New customizable tokens */
  --kimo-surface: var(--cps-surface, #ffffff);
  --kimo-text: var(--cps-text, #0f172a);
  --kimo-muted: var(--cps-muted, rgba(15,23,42,.7));
  --kimo-border: var(--cps-border, rgba(15,23,42,.12));
  --kimo-shadow: var(--cps-shadow, 0 8px 26px rgba(15,23,42,.10));

  --kimo-success: var(--cps-success, #16a34a);
  --kimo-danger: var(--cps-danger, #ef4444);
  --kimo-link: var(--cps-link, var(--kimo-primary));
  --kimo-focus: var(--cps-focus, var(--kimo-accent));

  --kimo-header-bg: var(--cps-header-bg, var(--kimo-surface));
  --kimo-header-text: var(--cps-header-text, var(--kimo-text));
  --kimo-topbar-bg: var(--cps-topbar-bg, var(--kimo-primary-dark));
  --kimo-topbar-text: var(--cps-topbar-text, #ffffff);

  --kimo-footer-bg: var(--cps-footer-bg, var(--cps-bg-dark, #0f172a));
  --kimo-footer-surface: var(--cps-footer-surface, #1E293B);
  --kimo-footer-text: var(--cps-footer-text, #E2E8F0);
  --kimo-footer-muted: var(--cps-footer-muted, #94A3B8);
  --kimo-footer-border: var(--cps-footer-border, #334155);

  --kimo-radius: var(--cps-card-radius, 14px);
  --kimo-button-radius: var(--cps-button-radius, 999px);
  --kimo-input-radius: var(--cps-input-radius, 999px);
}

html, body{background:var(--kimo-bg); color:var(--kimo-text);}

body.cps-eshop{
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

/* RTL: apply to whole storefront, not only the header */
body.cps-eshop.rtl{direction:rtl;}
body.cps-eshop.rtl .kimo-actions-row{flex-direction:row-reverse;}
body.cps-eshop.rtl .kimo-price del{margin-left:0; margin-right:10px;}

/* ------------------------
   Layout fixes (Frappe v14)
   - Ensure full-width canvas, and let .kimo-wrap control max width
   - Prevent "partial screen" issues caused by nested .container
------------------------ */
body.cps-eshop .page_content,
body.cps-eshop .page-content{
  padding: 0 !important;
}

body.cps-eshop .page_content > .container,
body.cps-eshop .page-content > .container{
  max-width: 100% !important;
  width: 100% !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

body.cps-eshop .page_content .container,
body.cps-eshop .page-content .container{
  max-width: 100% !important;
}

body.cps-eshop .web-form,
body.cps-eshop .web-form .container{
  max-width: 100% !important;
}

body.cps-eshop .page-container,
body.cps-eshop .web-page-content{
  max-width: 100% !important;
  width: 100% !important;
}


/* ------------------------
   Header
------------------------ */
.kimo-header{position:sticky; top:0; z-index:2000; background:var(--kimo-header-bg); color:var(--kimo-header-text); border-bottom:1px solid var(--kimo-border);} 
.kimo-utility{background:var(--kimo-topbar-bg); color:var(--kimo-topbar-text); font-size:13px;}
.kimo-utility .kimo-wrap{display:flex; align-items:center; justify-content:space-between; gap:12px; padding:8px 0;}
.kimo-utility a{color:var(--kimo-topbar-text); text-decoration:none; opacity:.95;}
.kimo-utility a:hover{opacity:1;}
.kimo-utility .kimo-left,.kimo-utility .kimo-right{display:flex; align-items:center; gap:14px; flex-wrap:wrap;}
.kimo-pill{display:inline-flex; align-items:center; gap:8px; padding:6px 10px; border-radius:var(--kimo-button-radius); background:rgba(255,255,255,.14); border:1px solid rgba(255,255,255,.18);} 

.kimo-mainbar .kimo-wrap{display:flex; align-items:center; justify-content:space-between; gap:14px; padding:14px 0;}
.kimo-brand{display:flex; align-items:center; gap:10px; text-decoration:none; color:inherit; min-width:180px;}
.kimo-brand img{height:44px; width:auto; object-fit:contain;}
.kimo-brand .kimo-brand-text{display:flex; flex-direction:column; line-height:1.05;}
.kimo-brand .kimo-brand-text strong{font-weight:900; font-size:16px;}
.kimo-brand .kimo-brand-text span{font-weight:700; font-size:12px; color:var(--kimo-muted);}

.kimo-search{flex:1; max-width:720px; position:relative;}
.kimo-search input{width:100%; height:44px; border-radius:var(--kimo-input-radius); border:1px solid var(--kimo-border); padding:0 46px 0 16px; background:var(--kimo-surface);}
.kimo-search button{position:absolute; right:10px; top:50%; transform:translateY(-50%); border:none; background:var(--kimo-primary); color:#fff; width:34px; height:34px; border-radius:var(--kimo-button-radius); font-weight:900;}

.kimo-actions{display:flex; align-items:center; gap:10px;}
.kimo-icbtn{position:relative; display:inline-flex; align-items:center; justify-content:center; width:44px; height:44px; border-radius:var(--kimo-button-radius); border:1px solid var(--kimo-border); background:var(--kimo-surface); text-decoration:none; color:var(--kimo-text);} 
.kimo-icbtn:hover{box-shadow:var(--kimo-shadow);} 
.kimo-badge{position:absolute; top:-6px; right:-6px; min-width:18px; height:18px; padding:0 6px; border-radius:var(--kimo-button-radius); background:var(--kimo-accent); color:#fff; font-size:10px; display:flex; align-items:center; justify-content:center; font-weight:900;}

.kimo-nav{border-top:1px solid var(--kimo-border);}
.kimo-nav .kimo-wrap{display:flex; align-items:center; justify-content:flex-start; gap:12px; width:100%;}
.kimo-nav-list{display:flex; align-items:center; gap:14px; width:100%; margin:0; padding:12px 0; list-style:none; overflow:auto hidden; scrollbar-width:thin;}
.kimo-nav-link{display:inline-flex; align-items:center; gap:8px; min-height:44px; padding:12px 16px; border-radius:var(--kimo-button-radius); text-decoration:none; color:var(--kimo-text); font-weight:900; font-size:14px; white-space:nowrap;}
.kimo-nav-link:hover{background:rgba(0,0,0,.04);} 
.kimo-nav-link.kimo-hot{background:rgba(239,68,68,.10); background:color-mix(in srgb, var(--kimo-accent) 14%, transparent); color:var(--kimo-accent);} 

.kimo-mega{position:absolute; left:0; right:0; top:100%; background:var(--kimo-surface); border-top:1px solid var(--kimo-border); box-shadow:var(--kimo-shadow); display:none;}
.kimo-nav-item{position:relative;}
.kimo-nav-item:hover .kimo-mega{display:block;}
.kimo-mega-inner{max-width:1320px; margin:0 auto; padding:18px 20px; display:grid; grid-template-columns:repeat(4, minmax(0,1fr)); gap:16px;}
.kimo-mega h6{margin:0 0 10px; font-weight:1000;}
.kimo-mega a{display:block; padding:8px 10px; border-radius:10px; text-decoration:none; color:var(--kimo-text); font-weight:800;}
.kimo-mega a:hover{background:rgba(0,0,0,.04);} 

/* Mobile menu */
.kimo-mtoggle{display:none;}
.kimo-mobile{display:none; position:fixed; inset:0; background:var(--kimo-surface); z-index:3000; overflow:auto;}
.kimo-mobile-head{display:flex; align-items:center; justify-content:space-between; padding:14px 16px; border-bottom:1px solid var(--kimo-border);} 
.kimo-mobile-close{border:1px solid var(--kimo-border); width:44px; height:44px; border-radius:999px; background:var(--kimo-surface); font-size:20px;}
.kimo-mobile-body{padding:14px 16px 24px;}
.kimo-mitem{display:flex; align-items:center; justify-content:space-between; width:100%; padding:14px 14px; border-radius:14px; border:1px solid var(--kimo-border); background:var(--kimo-surface); font-weight:900; text-decoration:none; color:var(--kimo-text); margin-bottom:10px;}
.kimo-mitem:hover{box-shadow:var(--kimo-shadow);} 
.kimo-mback{display:none; margin-bottom:12px;}
.kimo-mback button{border:none; background:transparent; font-weight:1000;}

@media (max-width: 992px){
  .kimo-search{display:none;}
  .kimo-mtoggle{display:inline-flex;}
  .kimo-mega{display:none !important;}
}

@media (max-width: 768px){
  .kimo-utility{font-size:12px;}
  .kimo-nav-list{gap:10px;}
}

/* ------------------------
   Containers
------------------------ */
.kimo-wrap{max-width:var(--cps-container-max-width, 1320px); margin:0 auto; padding:0 16px;}

/* Make header full-width as requested (logo/search/actions + categories) */
body.cps-eshop .kimo-mainbar .kimo-wrap,
body.cps-eshop .kimo-nav .kimo-wrap{
  max-width: none;
  width: 100%;
}

/* User requirement: storefront pages + header should be full width */
body.cps-eshop .kimo-wrap{max-width:none; width:100%;}

/* Hide ERPNext default breadcrumbs on store pages (we render our own) */
.cps-eshop .breadcrumb{display:none !important;}

/* Product details page */
.kimo-pdp .kimo-pdp-media{
  /* Prevent "No image" placeholder from taking the whole viewport */
  height: clamp(320px, 42vw, 540px);
}
@media (max-width: 900px){
  .kimo-pdp .kimo-pdp-media{height: clamp(260px, 70vw, 420px);}
}

/* ------------------------
   Product cards + grids
------------------------ */
.kimo-section{padding:22px 0;}
.kimo-section h2{font-weight:1000; font-size:22px; margin:0 0 12px;}
.kimo-grid{display:grid; grid-template-columns:repeat(auto-fill, minmax(240px, 1fr)); gap:14px;}
@media (max-width: 420px){.kimo-grid{grid-template-columns:1fr;}}

.kimo-card{border:1px solid var(--kimo-border); border-radius:var(--kimo-radius); background:var(--kimo-surface); overflow:hidden; position:relative; transition:transform .15s ease, box-shadow .15s ease;}
.kimo-card:hover{transform:translateY(-2px); box-shadow:var(--kimo-shadow);} 
.kimo-card-img{display:block; aspect-ratio:1/1; background:rgba(0,0,0,.03);} 
.kimo-card-img img{width:100%; height:100%; object-fit:contain; padding:14px;}
.kimo-card-body{padding:12px 12px 10px;}
.kimo-card-title{font-weight:900; font-size:13.5px; line-height:1.35; margin:0 0 10px; height:36px; overflow:hidden;}
.kimo-price{display:flex; align-items:baseline; gap:8px;}
.kimo-price strong{font-weight:1000;}
.kimo-price del{color:var(--kimo-muted); font-weight:800; font-size:12px;}
.kimo-stock{margin-top:8px; font-size:12px; font-weight:900; color:var(--kimo-success);} 
.kimo-stock.out{color:var(--kimo-danger);} 
.kimo-actions-row{display:flex; gap:8px; margin-top:10px;}
.kimo-actions-row .kimo-btn{white-space:nowrap; font-size:12px; line-height:1;}
.kimo-actions-row .kimo-btn-primary{flex:1.45;}
.kimo-actions-row .kimo-btn-ghost{flex:1;}
.kimo-actions-row .kimo-btn-ghost:last-child{flex:0 0 42px; padding:0;}

/* Pager (avoid full-width stretched buttons) */
.kimo-pager{display:flex; align-items:center; justify-content:center; gap:12px;}
.kimo-pager-btn{height:38px; padding:0 14px; border-radius:var(--kimo-button-radius); border:1px solid var(--kimo-border); background:var(--kimo-surface); font-weight:900;}
.kimo-pager-btn:hover{box-shadow:var(--kimo-shadow);}
.kimo-pager-btn:disabled{opacity:.45; cursor:not-allowed; box-shadow:none;}
.kimo-pager-mid{font-weight:1000; color:var(--kimo-muted); padding:0 2px;}

/* Filters layout */
.kimo-layout{display:grid; grid-template-columns: 280px 1fr; gap:18px; align-items:start;}
@media (max-width: 980px){
  .kimo-layout{grid-template-columns:1fr;}
}
.kimo-filters{border:1px solid var(--kimo-border); background:var(--kimo-surface); border-radius:var(--kimo-radius); padding:14px;}
.kimo-filters h3{margin:0 0 10px; font-size:14px; font-weight:1000;}
.kimo-filter-row{display:flex; gap:10px; align-items:center; justify-content:space-between; margin-top:10px;}
.kimo-filter-input{width:100%; height:40px; border-radius:var(--kimo-input-radius); border:1px solid var(--kimo-border); padding:0 12px; font-weight:800;}
.kimo-filter-small{width:100%; height:40px; border-radius:var(--kimo-input-radius); border:1px solid var(--kimo-border); padding:0 10px; font-weight:800;}
.kimo-filter-actions{display:flex; gap:10px; margin-top:12px; flex-wrap:wrap;}
.kimo-filter-actions .kimo-btn{flex:0 0 auto; padding:0 14px;}

/* Hide Frappe default breadcrumbs inside CPS shop pages (we render our own) */
body.cps-eshop .breadcrumb,
body.cps-eshop .page-breadcrumbs,
body.cps-eshop nav[aria-label="breadcrumb"]{display:none !important;}
.kimo-btn{flex:1; height:38px; border-radius:var(--kimo-button-radius); border:1px solid var(--kimo-border); background:var(--kimo-surface); font-weight:900; color:var(--kimo-text);}
.kimo-btn-primary{background:var(--kimo-primary); border-color:var(--kimo-primary); color:#fff;}
.kimo-btn-primary:hover{background:var(--kimo-primary-dark);} 
.kimo-btn-ghost{background:transparent;}
.kimo-btn-ghost:hover{box-shadow:var(--kimo-shadow);} 

.kimo-tag{position:absolute; top:10px; left:10px; padding:6px 10px; border-radius:var(--kimo-button-radius); background:rgba(239,68,68,.10); background:color-mix(in srgb, var(--kimo-accent) 14%, transparent); color:var(--kimo-accent); font-weight:1000; font-size:11px; border:1px solid rgba(239,68,68,.18); border-color:color-mix(in srgb, var(--kimo-accent) 28%, transparent);} 

/* ------------------------
   Listing controls
------------------------ */
.kimo-controls{display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; padding:14px 0 10px;}
.kimo-controls .kimo-left{color:var(--kimo-muted); font-weight:800;}
.kimo-controls .kimo-right{display:flex; align-items:center; gap:10px; flex-wrap:wrap;}
.kimo-select{height:38px; border-radius:var(--kimo-input-radius); border:1px solid var(--kimo-border); padding:0 12px; background:var(--kimo-surface); font-weight:900; color:var(--kimo-text);}

/* ------------------------
   Quick view modal
------------------------ */
.kimo-modal{display:none; position:fixed; inset:0; background:rgba(15,23,42,.55); z-index:4000; padding:18px;}
.kimo-modal.open{display:flex; align-items:center; justify-content:center;}
.kimo-modal-card{max-width:980px; width:100%; background:var(--kimo-surface); border-radius:18px; overflow:hidden; box-shadow:0 30px 90px rgba(0,0,0,.25);}
.kimo-modal-card{max-height: calc(100vh - 36px); display:flex; flex-direction:column;}
.kimo-modal-head{display:flex; align-items:center; justify-content:space-between; padding:12px 14px; border-bottom:1px solid var(--kimo-border);} 
.kimo-modal-close{border:none; background:transparent; font-size:22px; font-weight:1000;}
.kimo-modal-body{display:grid; grid-template-columns:1fr 1fr; gap:0; overflow:auto;}
.kimo-modal-body .img{background:rgba(0,0,0,.03); aspect-ratio:1/1; display:flex; align-items:center; justify-content:center;}

/* ------------------------
   Home hero (store_home)
------------------------ */
.kimo-hero-track{display:flex; gap:12px; overflow:auto; scroll-snap-type:x mandatory; -webkit-overflow-scrolling:touch; padding-bottom:0;}
.kimo-hero-slide{flex:0 0 86%; scroll-snap-align:start; border-radius:18px; overflow:hidden; border:1px solid var(--kimo-border); background:var(--kimo-surface);}
@media (min-width: 900px){.kimo-hero-slide{flex-basis:56%;}}
@media (min-width: 1200px){.kimo-hero-slide{flex-basis:44%;}}
.kimo-hero-slide img{width:100%; height:260px; object-fit:cover; display:block;}
@media (max-width: 900px){.kimo-hero-slide img{height:220px;}}
.kimo-hero-caption{padding:12px 14px; display:flex; align-items:center; justify-content:space-between; gap:10px;}
.kimo-hero-caption strong{font-weight:1000;}
.kimo-hero-caption span{color:var(--kimo-muted); font-weight:800;}

/* Utility: muted text */
.kimo-muted{color:var(--kimo-muted);}

/* Utility: neutral pills */
.kimo-pill-soft{background:rgba(0,0,0,.04); border-color:rgba(0,0,0,.08);}
.kimo-modal-body .img img{max-width:100%; max-height:100%; object-fit:contain; padding:18px;}
.kimo-modal-body .info{padding:16px;}
.kimo-modal-body .info h3{font-weight:1000; margin:0 0 10px;}
.kimo-modal-body .info p{color:var(--kimo-muted); font-weight:700;}
@media (max-width: 900px){
  .kimo-modal-body{grid-template-columns:1fr;}
}

/* Wishlist modal layout polish */
#kimoWishlistModal .kimo-modal-body{grid-template-columns:1fr !important;}
#kimoWishlistModal [data-wishlist-body]{max-height: calc(100vh - 140px); overflow:auto;}

/* Hide any default Frappe pagers inside our storefront pages to avoid duplicates */
body.cps-eshop .kimo-wrap .pagination,
body.cps-eshop .kimo-wrap .pager{
  display:none !important;
}


/* Global link color within storefront */
body.cps-eshop a{color:var(--kimo-link);}
body.cps-eshop a:hover{color:var(--kimo-accent);}


/* Focus styles */
body.cps-eshop :focus-visible{outline: 3px solid color-mix(in srgb, var(--kimo-focus) 55%, transparent); outline-offset: 2px;}
/* =========================================================
   Kimo-ish Footer (cps_eshop)
   - Colors driven by CPS Eshop Settings via CSS variables
   ========================================================= */

.kimo-footer{
  background: var(--kimo-footer-bg);
  color: var(--kimo-footer-text);
  border-top: 1px solid var(--kimo-footer-border);
}

.kimo-footer a{
  color: var(--kimo-footer-text);
  text-decoration: none;
  opacity: .92;
}

.kimo-footer a:hover{opacity: 1; color: var(--kimo-accent);}

.kimo-footer-top{padding: 26px 0;}

.kimo-footer-grid{
  display:grid;
  grid-template-columns: 2fr 1fr 1fr 1.4fr;
  gap: 16px;
}

@media (max-width: 992px){
  .kimo-footer-grid{grid-template-columns: 1fr 1fr;}
}

@media (max-width: 560px){
  .kimo-footer-grid{grid-template-columns: 1fr;}
}

.kimo-footer-brand{
  display:flex;
  flex-direction:column;
  gap: 12px;
}

.kimo-footer-logo{
  display:flex;
  align-items:center;
  gap: 12px;
}

.kimo-footer-logo img{height: 44px; width: auto; object-fit: contain; background: #fff; border-radius: 10px; padding: 6px;}
.kimo-footer-mark{font-size: 34px;}

.kimo-footer-brandtext{display:flex; flex-direction:column; line-height:1.2;}
.kimo-footer-brandtext strong{font-weight: 1000; font-size: 16px;}

.kimo-footer-muted{color: var(--kimo-footer-muted); font-weight: 700;}

.kimo-footer-social{display:flex; flex-wrap:wrap; gap: 10px;}
.kimo-footer-social a{background: color-mix(in srgb, var(--kimo-footer-surface) 85%, transparent); border: 1px solid var(--kimo-footer-border); padding: 6px 10px; border-radius: var(--kimo-button-radius);}

.kimo-footer-col{display:flex; flex-direction:column; gap: 10px;}
.kimo-footer-title{font-weight: 1000; margin-bottom: 2px;}

.kimo-footer-line{display:flex; gap: 8px; align-items:flex-start; color: var(--kimo-footer-muted); font-weight: 700;}
.kimo-footer-line span{color: var(--kimo-footer-text); opacity: .92;}

.kimo-footer-lang{display:flex; gap: 10px; margin-top: 12px; flex-wrap:wrap;}
.kimo-footer-lang .kimo-pill{background: color-mix(in srgb, var(--kimo-footer-surface) 85%, transparent); border-color: var(--kimo-footer-border); color: var(--kimo-footer-text);}

.kimo-footer-pay{border-top: 1px solid var(--kimo-footer-border); border-bottom: 1px solid var(--kimo-footer-border); background: var(--kimo-footer-surface);}
.kimo-footer-payrow{display:flex; align-items:center; justify-content:space-between; gap: 12px; padding: 12px 0; flex-wrap:wrap;}

.kimo-footer-bottom{padding: 12px 0;}
.kimo-footer-bottomrow{display:flex; align-items:center; justify-content:space-between; gap: 12px; flex-wrap:wrap; color: var(--kimo-footer-muted); font-weight: 800;}

.kimo-footer-topbtn{border: 1px solid var(--kimo-footer-border); background: transparent; color: var(--kimo-footer-text); padding: 8px 12px; border-radius: var(--kimo-button-radius); font-weight: 900;}
.kimo-footer-topbtn:hover{box-shadow: var(--kimo-shadow);}

/* RTL tweaks */
body.cps-eshop.rtl .kimo-footer-payrow,
body.cps-eshop.rtl .kimo-footer-bottomrow{flex-direction: row-reverse;}


/* No-image placeholder (no external asset) */
.kimo-noimg{width:100%; height:100%; min-height:160px; background:var(--kimo-bg); border:1px dashed var(--kimo-border); border-radius:inherit; display:flex; align-items:center; justify-content:center; position:relative; overflow:hidden;}
.kimo-noimg:before{content:""; width:72px; height:54px; border:2px solid var(--kimo-border); border-radius:10px; opacity:.75; display:block;}
.kimo-noimg:after{content:""; position:absolute; width:24px; height:24px; border-radius:50%; background:var(--kimo-border); opacity:.8; top:22%; left:32%;}
.kimo-hero-slide .kimo-noimg{min-height:240px;}

/* Hero (banners) */
.kimo-hero{position:relative; border-radius:var(--kimo-radius); overflow:hidden; border:1px solid var(--kimo-border); background:var(--kimo-surface);}
.kimo-hero-track{display:flex; overflow:auto; scroll-snap-type:x mandatory; -webkit-overflow-scrolling:touch; scrollbar-width:none;}
.kimo-hero-track::-webkit-scrollbar{display:none;}
.kimo-hero-slide{min-width:100%; scroll-snap-align:start; position:relative; display:block; aspect-ratio: 16/6; background:rgba(0,0,0,.03);}
.kimo-hero-slide img{width:100%; height:100%; object-fit:cover; display:block;}
.kimo-hero-nav{position:absolute; top:50%; transform:translateY(-50%); border:none; width:42px; height:42px; border-radius:999px; background:rgba(255,255,255,.86); color:#111827; font-weight:1000; box-shadow: var(--kimo-shadow); cursor:pointer; display:flex; align-items:center; justify-content:center; z-index:3;}
.kimo-hero-nav.prev{left:12px;}
.kimo-hero-nav.next{right:12px;}
.kimo-hero-dots{position:absolute; left:0; right:0; bottom:10px; display:flex; gap:8px; justify-content:center; z-index:3;}
.kimo-hero-dot{width:10px; height:10px; border-radius:999px; border:1px solid rgba(255,255,255,.9); background:rgba(255,255,255,.35); cursor:pointer;}
.kimo-hero-dot.active{background:rgba(255,255,255,.95);}
@media (max-width: 768px){
  .kimo-hero-slide{aspect-ratio: 16/9;}
  .kimo-hero-nav{width:38px; height:38px;}
}


/* Full-width layout helpers (scoped to storefront) */
body.cps-eshop .page-content,
body.cps-eshop .page-content-wrapper,
body.cps-eshop .page-container,
body.cps-eshop .container,
body.cps-eshop .container-fluid{
  max-width: none !important;
}
body.cps-eshop .page-container,
body.cps-eshop .page-content,
body.cps-eshop .page-content .container,
body.cps-eshop .page-content .container-fluid{
  width: 100% !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}
.kimo-fullbleed{
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  padding-left: 16px;
  padding-right: 16px;
}
body.cps-eshop.rtl .kimo-fullbleed{
  left: auto;
  right: 50%;
  margin-right: -50vw;
  margin-left: -50vw;
}

.kimo-pdp-desc img{max-width:100%; height:auto;}


/* ===== CPS Eshop v6 fixes ===== */
body.cps-eshop .kimo-wrap{max-width:none;width:100%;}
body.cps-eshop .kimo-header .kimo-wrap,
body.cps-eshop .kimo-mainbar .kimo-wrap,
body.cps-eshop .kimo-nav .kimo-wrap{max-width:none;width:100%;}
/* Hide any default Frappe pager on our pages */
body.cps-eshop .pagination,
body.cps-eshop .pager{display:none!important;}

/* Hero banner sizing */
body.cps-eshop .kimo-hero{position:relative;overflow:hidden;}
body.cps-eshop .kimo-hero-slide{position:relative;display:block;}
body.cps-eshop .kimo-hero-slide img{width:100%;height:360px;object-fit:cover;display:block;}
@media (max-width: 768px){
  body.cps-eshop .kimo-hero-slide img{height:240px;}
}
body.cps-eshop .kimo-hero-caption{position:absolute;left:0;right:0;bottom:0;padding:18px 18px 22px;background:linear-gradient(180deg, transparent 0%, rgba(0,0,0,.45) 55%, rgba(0,0,0,.55) 100%);color:#fff;}
body.cps-eshop .kimo-hero-caption strong{display:block;font-size:28px;line-height:1.15;}
body.cps-eshop .kimo-hero-caption .sub{margin-top:6px;opacity:.95;font-weight:600;}
body.cps-eshop .kimo-hero-nav{position:absolute;top:50%;transform:translateY(-50%);width:44px;height:44px;border-radius:999px;background:rgba(255,255,255,.88);display:flex;align-items:center;justify-content:center;text-decoration:none;font-size:28px;color:#111;box-shadow:0 6px 18px rgba(0,0,0,.12);}
body.cps-eshop .kimo-hero-nav.prev{left:14px;}
body.cps-eshop .kimo-hero-nav.next{right:14px;}
body.cps-eshop .kimo-hero-dots{position:absolute;left:0;right:0;bottom:10px;display:flex;gap:8px;justify-content:center;}
body.cps-eshop .kimo-hero-dot{width:10px;height:10px;border-radius:999px;background:rgba(255,255,255,.55);display:inline-block;}
body.cps-eshop .kimo-hero-dot.active{background:rgba(255,255,255,.95);}

/* Product page image sizing */
body.cps-eshop .kimo-pdp-media{min-height:360px;}
body.cps-eshop .kimo-pdp-img{max-width:100%;max-height:360px;object-fit:contain;padding:14px!important;}
@media (max-width: 992px){
  body.cps-eshop .kimo-pdp-grid{grid-template-columns:1fr!important;}
  body.cps-eshop .kimo-pdp-img{max-height:280px;}
}

/* Modals (quick view & wishlist) */
body.cps-eshop .kimo-modal{position:fixed;inset:0;display:none;align-items:center;justify-content:center;background:rgba(0,0,0,.45);padding:14px;z-index:9999;}
body.cps-eshop .kimo-modal.open{display:flex;}
body.cps-eshop .kimo-modal-card{max-width:920px;width:100%;max-height:86vh;overflow:hidden;border-radius:18px;background:var(--kimo-surface);border:1px solid var(--kimo-border);box-shadow:0 14px 40px rgba(0,0,0,.18);}
body.cps-eshop .kimo-modal-body{display:grid;grid-template-columns: 360px 1fr;gap:14px;padding:14px;max-height:calc(86vh - 56px);overflow:auto;}
body.cps-eshop .kimo-modal-body .img img{width:100%;height:320px;object-fit:contain;background:color-mix(in srgb, var(--kimo-text) 4%, transparent);border-radius:14px;border:1px solid var(--kimo-border);}
@media (max-width: 820px){
  body.cps-eshop .kimo-modal-body{grid-template-columns:1fr;}
  body.cps-eshop .kimo-modal-body .img img{height:240px;}
}


/* Header full width (Frappe web.html wraps navbar in a container) */
body.cps-eshop .kimo-header{
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  padding-left: 16px;
  padding-right: 16px;
}
body.cps-eshop.rtl .kimo-header{
  left: auto;
  right: 50%;
  margin-right: -50vw;
  margin-left: -50vw;
}

/* PDP main image sizing */
body.cps-eshop .kimo-pdp .kimo-pdp-media{
  height: clamp(240px, 30vw, 420px);
}
@media (max-width: 900px){
  body.cps-eshop .kimo-pdp .kimo-pdp-media{height: clamp(200px, 60vw, 320px);}
}
body.cps-eshop .kimo-pdp .kimo-pdp-media img{
  width: 100%;
  height: 100%;
  object-fit: contain;
  display:block;
}

/* =========================================================
   CPS Eshop refresh: white product media, PDP gallery, optional listing carousel
   ========================================================= */
body.cps-eshop .kimo-card-img,
body.cps-eshop .kimo-pdp-gallery,
body.cps-eshop .kimo-gallery-main,
body.cps-eshop .kimo-gallery-thumb{
  background:#fff;
}

body.cps-eshop .kimo-card-img{
  border-bottom:1px solid var(--kimo-border);
}

body.cps-eshop .kimo-list-mode-nav{
  display:flex;
  justify-content:flex-end;
  gap:10px;
  margin:0 0 12px;
}

body.cps-eshop .kimo-grid-carousel{
  display:flex;
  gap:14px;
  overflow:auto;
  scroll-snap-type:x proximity;
  padding-bottom:10px;
  grid-template-columns:none !important;
  scrollbar-width:thin;
}
body.cps-eshop .kimo-grid-carousel > .kimo-card{
  flex:0 0 clamp(220px, 24vw, 290px);
  scroll-snap-align:start;
}
@media (max-width: 768px){
  body.cps-eshop .kimo-grid-carousel > .kimo-card{
    flex-basis: clamp(220px, 72vw, 280px);
  }
}

body.cps-eshop .kimo-gallery{
  border:1px solid var(--kimo-border);
  border-radius:var(--kimo-radius);
  background:var(--kimo-surface);
  overflow:hidden;
  box-shadow:var(--kimo-shadow);
}
body.cps-eshop .kimo-gallery-main{
  position:relative;
  min-height:clamp(320px, 42vw, 540px);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}
body.cps-eshop .kimo-gallery-track{
  width:100%;
  height:100%;
  position:relative;
}
body.cps-eshop .kimo-gallery-slide{
  display:none;
  width:100%;
  height:100%;
  align-items:center;
  justify-content:center;
  padding:20px;
}
body.cps-eshop .kimo-gallery-slide.is-active{
  display:flex;
}
body.cps-eshop .kimo-gallery-slide img{
  width:100%;
  height:100%;
  max-height:480px;
  object-fit:contain;
  transition:transform .28s ease;
  transform-origin:center center;
}
body.cps-eshop .kimo-gallery-main:hover .kimo-gallery-slide.is-active img{
  transform:scale(1.34);
}
body.cps-eshop .kimo-gallery-nav{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:42px;
  height:42px;
  border-radius:999px;
  border:1px solid var(--kimo-border);
  background:rgba(255,255,255,.92);
  color:var(--kimo-text);
  font-size:26px;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:var(--kimo-shadow);
  z-index:2;
}
body.cps-eshop .kimo-gallery-nav.prev{left:14px;}
body.cps-eshop .kimo-gallery-nav.next{right:14px;}
body.cps-eshop .kimo-gallery-thumbs{
  display:flex;
  gap:10px;
  padding:12px;
  overflow:auto;
  border-top:1px solid var(--kimo-border);
  background:color-mix(in srgb, #fff 86%, var(--kimo-background) 14%);
}
body.cps-eshop .kimo-gallery-thumb{
  flex:0 0 72px;
  width:72px;
  height:72px;
  border-radius:14px;
  border:1px solid var(--kimo-border);
  padding:6px;
  overflow:hidden;
  transition:border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
body.cps-eshop .kimo-gallery-thumb.is-active{
  border-color:var(--kimo-primary);
  box-shadow:0 0 0 3px color-mix(in srgb, var(--kimo-primary) 18%, transparent);
  transform:translateY(-1px);
}
body.cps-eshop .kimo-gallery-thumb img{
  width:100%;
  height:100%;
  object-fit:contain;
}
body.cps-eshop .kimo-gallery-source-image{
  display:none !important;
}
@media (max-width: 900px){
  body.cps-eshop .kimo-gallery-main{
    min-height:clamp(250px, 72vw, 390px);
  }
  body.cps-eshop .kimo-gallery-slide img{
    max-height:340px;
  }
  body.cps-eshop .kimo-gallery-thumb{
    flex-basis:60px;
    width:60px;
    height:60px;
  }
}
