/* =====================================================================
   PRODUCT DETAIL TEMPLATE (single-faito_product.php) — ported from
   product-brake-pad-set.html. Everything shared (tokens, nav, buttons,
   mobile nav, footer, search field, focus states) lives in
   faito-shared.css instead.
===================================================================== */

.product-page{padding:calc(var(--nav-h) + 34px) 0 0;}
.breadcrumb{font-size:12px; letter-spacing:0.06em; color:var(--muted); margin-bottom:36px;}
.breadcrumb a:hover{color:var(--scooter-cyan);}
.breadcrumb span{opacity:0.5; margin:0 4px;}

/* ===== PRODUCT HERO ===== */
.product-hero{display:grid; grid-template-columns:1.1fr 1fr; gap:64px; padding-bottom:90px;}
@media(max-width:900px){.product-hero{grid-template-columns:1fr; gap:34px;}}

.gallery-main{
  aspect-ratio:1/1; border-radius:2px; overflow:hidden;
  display:flex; align-items:center; justify-content:center;
  background:linear-gradient(135deg, rgba(70,184,218,0.16), rgba(41,87,164,0.26));
  transition:background .3s ease;
}
.gallery-main svg{width:120px; height:120px; opacity:0.85;}
.gallery-main img{width:100%; height:100%; object-fit:cover;}
.gallery-main model-viewer{width:100%; height:100%; --poster-color:transparent;}
.gallery-thumbs{display:flex; gap:10px; margin-top:12px; flex-wrap:wrap;}
.gallery-thumb{
  width:64px; height:64px; border-radius:2px; flex:none; cursor:pointer;
  display:flex; align-items:center; justify-content:center; overflow:hidden;
  background:linear-gradient(135deg, rgba(70,184,218,0.12), rgba(41,87,164,0.2));
  border:1px solid var(--line); transition:border-color .2s ease;
}
.gallery-thumb.active{border-color:var(--scooter-cyan);}
.gallery-thumb svg{width:30px; height:30px; opacity:0.8;}
.gallery-thumb img{width:100%; height:100%; object-fit:cover;}

.product-info .p-category{
  font-size:11.5px; letter-spacing:0.12em; font-weight:600; color:var(--scooter-cyan);
  text-transform:uppercase; margin-bottom:12px;
}
.product-info h1{font-size:clamp(28px,3.6vw,42px); text-transform:uppercase; margin-bottom:14px; line-height:1.05;}
.product-info .p-price{font-family:'Rajdhani'; font-weight:700; font-size:26px; color:var(--white); margin-bottom:18px;}
.product-info .p-price span{font-size:13px; color:var(--muted); font-weight:500; margin-left:8px;}
.product-info .p-desc{color:var(--muted); font-size:15px; line-height:1.7; max-width:460px; margin-bottom:28px;}

.spec-badges{list-style:none; display:flex; flex-wrap:wrap; gap:18px; padding:0; margin:-8px 0 28px;}
/* Per-product override: --badge-w / --badge-h are set inline from the Badge Size fields */
.spec-badge{width:var(--badge-w,95px); height:var(--badge-h,95px);}
.spec-badge img{width:100%; height:100%; object-fit:contain; display:block;}

.fitment{
  background:var(--panel); border:1px solid var(--line); border-radius:2px;
  padding:22px; margin-bottom:26px;
}
.fitment-label{font-size:12px; letter-spacing:0.08em; font-weight:600; color:var(--white); margin-bottom:14px;}
.fitment-list{
  list-style:none; padding:0; margin:0; font-size:14px; color:var(--muted); line-height:1.8;
  display:grid; grid-template-columns:1fr 1fr; column-gap:20px;
}
@media(max-width:420px){.fitment-list{grid-template-columns:1fr;}}
.fitment-list strong{color:var(--white);}
.fitment-note{font-size:12px; color:var(--muted); margin-top:12px;}

.product-actions{display:flex; gap:14px; flex-wrap:wrap; margin-bottom:10px;}
.product-actions .btn{height:48px; display:inline-flex; align-items:center; padding:0 26px;}
.p-availability{font-size:12.5px; color:var(--muted); display:flex; align-items:center; gap:8px; margin-top:16px;}
.p-availability::before{content:''; width:8px; height:8px; border-radius:50%; background:var(--scooter-cyan);}

/* ===== SPEC ACCORDION ===== */
.specs{padding:0 0 110px;}
.specs-wrap{max-width:820px;}
.accordion-item{border-top:1px solid var(--line);}
.accordion-item:last-child{border-bottom:1px solid var(--line);}
.accordion-trigger{
  width:100%; display:flex; align-items:center; justify-content:space-between;
  background:none; border:none; color:var(--white); text-align:left; cursor:pointer;
  padding:22px 4px; font-family:'Rajdhani'; font-weight:600; font-size:18px; text-transform:uppercase;
}
.accordion-trigger svg{width:16px; height:16px; flex:none; transition:transform .25s ease; opacity:0.7;}
.accordion-item.open .accordion-trigger svg{transform:rotate(45deg);}
.accordion-panel{max-height:0; overflow:hidden; transition:max-height .35s ease;}
.accordion-panel-inner{padding:0 4px 24px; color:var(--muted); font-size:14.5px; line-height:1.75;}
.accordion-panel-inner ul{padding-left:18px; margin-top:8px;}

/* Optional boxed treatment for a block/group of Overview copy that should
   read as its own card rather than sitting directly in the accordion text —
   same panel look as the "Confirmed Fitment" box (see .fitment in this
   file), reused here under its own name since this isn't fitment-specific.
   Applied via the block editor's "Faito: … (Boxed)" patterns/Additional
   CSS Class field — see inc/block-editor.php. */
.accordion-panel-inner .content-box{
  background:var(--panel); border:1px solid var(--line); border-radius:2px;
  padding:22px; margin:0 0 20px;
}
.accordion-panel-inner .content-box > *:last-child{margin-bottom:0;}

/* Spacing between repeated "Faito: Advantage Item" blocks (see
   faito_advantage_item_block_markup() in inc/block-editor.php) — each item
   is its own Group so it can be duplicated as a single unit; this just
   keeps stacked items readable, whether sitting directly in the page or
   nested inside a .content-box. */
.accordion-panel-inner .advantage-item{margin-bottom:20px;}
.accordion-panel-inner .advantage-item:last-child{margin-bottom:0;}
.accordion-panel-inner .advantage-item h4{margin-bottom:4px;}

/* Section title above a run of "Faito: Advantage Item" blocks (see
   faito_register_block_patterns() in inc/block-editor.php). */
.accordion-panel-inner .advantages-title{margin:10px 0 15px;}
.accordion-panel-inner li{margin-bottom:6px;}
.accordion-panel-inner li .spec-fitment-list,
.accordion-panel-inner .spec-fitment-list{margin-top:8px; margin-bottom:0;}
.accordion-panel-inner .spec-fitment-list li{font-size:13.5px; opacity:0.9;}
.accordion-panel-inner p{margin-bottom:12px;}

/* ===== RELATED PRODUCTS ===== */
.related{padding:0 0 110px;}
.section-head{display:flex; justify-content:space-between; align-items:flex-end; margin-bottom:36px; gap:20px;}
.section-head h2{font-size:clamp(26px,3.6vw,36px); text-transform:uppercase;}
.section-head p{color:var(--muted); font-size:14.5px; max-width:340px;}
.product-rail{
  display:flex; gap:1px; overflow-x:auto; scroll-snap-type:x mandatory;
  background:var(--line); border-top:1px solid var(--line); border-bottom:1px solid var(--line);
  -ms-overflow-style:none; scrollbar-width:none; cursor:grab; user-select:none;
}
.product-rail.dragging{cursor:grabbing; scroll-snap-type:none;}
.product-rail::-webkit-scrollbar{display:none;}
.product-card{
  scroll-snap-align:start; flex:0 0 220px; background:var(--near-black);
  display:flex; flex-direction:column; transition:background .3s ease;
}
.product-card:hover{background:var(--panel);}
.product-thumb{
  height:160px; display:flex; align-items:center; justify-content:center;
  background:linear-gradient(135deg, rgba(70,184,218,0.16), rgba(41,87,164,0.24));
  overflow:hidden;
}
.product-thumb svg{width:44px; height:44px; opacity:0.8;}
.product-thumb img{width:100%; height:100%; object-fit:cover;}
.product-info-mini{padding:18px 20px 22px;}
.product-cat{font-size:10.5px; letter-spacing:0.1em; color:var(--scooter-cyan); text-transform:uppercase; margin-bottom:6px;}
.product-name{font-family:'Rajdhani'; font-weight:600; font-size:16px; margin-bottom:6px; color:var(--white);}
.product-price{font-size:13px; color:var(--muted);}

/* ===== CTA BAND ===== */
.cta-band{padding:90px 0; text-align:center; background:var(--paper); color:var(--paper-ink);}
.cta-band h2{font-size:clamp(26px,3.6vw,38px); margin-bottom:14px;}
.cta-band p{color:#41403A; font-size:15px; max-width:460px; margin:0 auto 28px;}
.cta-buttons{display:flex; gap:16px; justify-content:center; flex-wrap:wrap;}
.cta-band .btn.cyan{border-color:var(--faito-blue); color:var(--paper-ink);}
.cta-band .btn.cyan:hover{background:rgba(41,87,164,0.08);}
