/*
Theme Name:   FlashDash Store
Theme URI:    https://flashdash.ca
Description:  FlashDash Electrical Supplies — Storefront child theme. Circuit-texture ground, navy department nav, parchment delivery ticker, spec-first product cards.
Author:       FlashDash Electrical Supplies Ltd.
Template:     storefront
Version:      1.0.1
Text Domain:  flashdash
*/

/* ==========================================================================
   1. Design tokens
   ========================================================================== */
:root{
  --fd-navy:#0B2240;
  --fd-navy-lift:#123456;
  --fd-blue:#1E6FD9;
  --fd-blue-dark:#0E4F9B;
  --fd-bolt:#D93A2B;
  --fd-amber:#F25C05;
  --fd-amber-ink:#925310;
  --fd-ink:#16202B;
  --fd-steel:#5A6B7B;
  --fd-line:#DCE2E9;
  --fd-panel:#FFFFFF;
  --fd-stock:#177245;
}

/* ==========================================================================
   2. The ground — circuit texture under a white wash, fixed
   ========================================================================== */
body{
  color:var(--fd-ink);
  font-family:Archivo,"Helvetica Neue",Arial,sans-serif;
  background-color:#F7F8FA;
  background-image:
    linear-gradient(180deg, rgba(255,255,255,.62) 0%, rgba(255,255,255,.72) 45%, rgba(252,253,255,.80) 100%),
    url(assets/circuit-bg.jpg);
  background-size:auto, cover;
  background-position:center, center top;
  background-repeat:no-repeat, no-repeat;
  background-attachment:fixed, fixed;
}
body, .site, .site-content{background-color:transparent}
h1,h2,h3,h4,.site-title{font-family:Archivo,Arial,sans-serif;letter-spacing:-.02em;color:var(--fd-navy)}

/* ==========================================================================
   3. Announcement tickers (markup injected by functions.php)
   ========================================================================== */
.fd-ticker{background:var(--fd-bolt);overflow:hidden;padding:9px 0}
.fd-ticker-track{display:flex;width:max-content;animation:fd-roll 30s linear infinite}
.fd-ticker-track span{padding:0 46px;white-space:nowrap;color:#fff;font-size:14px;font-weight:600;letter-spacing:.09em}
.fd-ticker:hover .fd-ticker-track{animation-play-state:paused}

.fd-delivery{
  position:relative;overflow:hidden;font-size:13.5px;
  background:linear-gradient(180deg,#F6EFE2 0%,#EFE7D7 55%,#EAE0CD 100%);
  color:#4A4030;
  border-top:1px solid rgba(255,255,255,.72);
  border-bottom:1px solid rgba(120,100,70,.38);
  box-shadow:inset 0 -5px 12px rgba(120,100,70,.10);
}
.fd-delivery-track{display:flex;width:max-content;animation:fd-roll 42s linear infinite}
.fd-delivery-set{display:flex;flex-shrink:0}
.fd-delivery-track span{display:flex;align-items:center;gap:8px;white-space:nowrap;padding:10px 30px}
.fd-delivery b{color:#241D14;font-weight:600}
.fd-delivery a{
  color:var(--fd-amber-ink);font-weight:600;text-decoration:none;
  font-variant-numeric:tabular-nums;letter-spacing:.02em;
  border-bottom:1px solid rgba(146,83,16,.50);
}
.fd-delivery a:hover{color:#6E3B08;border-bottom-color:#6E3B08}
.fd-delivery svg{width:15px;height:15px;flex-shrink:0;stroke:var(--fd-amber-ink);fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.fd-delivery:hover .fd-delivery-track{animation-play-state:paused}

@keyframes fd-roll{from{transform:translateX(0)}to{transform:translateX(-50%)}}
@media (prefers-reduced-motion:reduce){
  .fd-ticker-track,.fd-delivery-track{animation:none;width:100%;justify-content:center}
  .fd-ticker-track span:not(:first-child),.fd-delivery-set:not(:first-child),.fd-delivery-set span:not(:first-child){display:none}
}

/* ==========================================================================
   4. Header and navigation
   ========================================================================== */
.site-header{
  background:#fff;border-bottom:1px solid var(--fd-line);
  padding-top:14px;padding-bottom:14px;
}
.site-header .custom-logo-link img,.site-header .site-logo-anchor img{max-width:172px;height:auto}
.storefront-primary-navigation{background:var(--fd-navy);margin:0}
.main-navigation ul.menu > li,.main-navigation ul.nav-menu > li{
  border-right:1px solid rgba(255,255,255,.13);
}
.main-navigation ul.menu > li:first-child,.main-navigation ul.nav-menu > li:first-child{
  border-left:1px solid rgba(255,255,255,.13);
}
.main-navigation ul.menu > li > a,.main-navigation ul.nav-menu > li > a{
  color:#C9DCEF;padding:15px 20px;font-size:14px;font-weight:400;letter-spacing:.01em;
}
.main-navigation ul.menu > li > a:hover,.main-navigation ul.nav-menu > li > a:hover{
  background:var(--fd-navy-lift);color:#fff;
}
.main-navigation ul.menu > li.current-menu-item > a,
.main-navigation ul.nav-menu > li.current-menu-item > a{background:var(--fd-bolt);color:#fff;font-weight:500}
.site-header-cart .cart-contents{color:var(--fd-navy)}
.site-header-cart .count{background:var(--fd-bolt);color:#fff;border-radius:9px;padding:1px 7px;font-size:12px;font-weight:600}

/* search field */
.site-search .widget_product_search form input[type="search"],
.woocommerce-product-search input[type="search"]{
  border:1px solid rgba(120,105,85,.34);border-radius:3px 0 0 3px;
  background:rgba(255,255,255,.96);color:var(--fd-ink);height:44px;
}
.woocommerce-product-search button[type="submit"]{
  background:var(--fd-bolt);color:#fff;border:0;border-radius:0 3px 3px 0;height:44px;padding:0 20px;font-weight:500;
}

/* ==========================================================================
   5. Product cards — spec first, price prominent
   ========================================================================== */
ul.products li.product{
  background:var(--fd-panel);border:1px solid var(--fd-line);border-radius:4px;
  padding:14px 15px 15px;
  box-shadow:0 1px 2px rgba(20,35,50,.05), 0 8px 20px rgba(20,35,50,.06);
  transition:box-shadow .16s ease, transform .16s ease, border-color .16s ease;
}
ul.products li.product:hover{
  border-color:#B9C6D3;transform:translateY(-1px);
  box-shadow:0 2px 4px rgba(20,35,50,.07), 0 14px 30px rgba(20,35,50,.11);
}
ul.products li.product img{
  background:#fff;border-radius:3px;margin-bottom:10px;
  max-height:150px;width:auto;object-fit:contain;
}
ul.products li.product .woocommerce-loop-product__title{
  font-size:14.5px;font-weight:500;line-height:1.4;color:var(--fd-ink);padding:0;margin:0 0 9px;
}
ul.products li.product .price{
  color:var(--fd-ink);font-size:26px;font-weight:600;letter-spacing:-.02em;
  font-variant-numeric:tabular-nums;margin:0 0 10px;display:block;
}
ul.products li.product .price .woocommerce-Price-currencySymbol{font-size:15px;vertical-align:top}
ul.products li.product .button{
  width:100%;background:var(--fd-navy);color:#fff;border-radius:3px;
  font-size:14px;font-weight:500;padding:.7em 1em;
}
ul.products li.product .button:hover{background:var(--fd-blue-dark);color:#fff}

/* SKU shown on the card, via functions.php */
.fd-loop-sku{
  display:block;font-size:11.5px;font-weight:500;color:var(--fd-steel);
  font-variant-numeric:tabular-nums;letter-spacing:.02em;margin:0 0 5px;
}
.fd-stock{font-size:12.5px;color:var(--fd-stock);margin:0 0 11px}

/* ==========================================================================
   6. Single product page
   ========================================================================== */
.single-product div.product .woocommerce-product-gallery{
  background:rgba(255,255,255,.52);
  -webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px);
  border:1px solid rgba(180,196,212,.55);border-radius:8px;padding:18px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.7);
}
.single-product div.product .product_title{font-size:23px;font-weight:600;line-height:1.28;color:var(--fd-navy)}
.single-product div.product p.price{font-size:34px;font-weight:600;color:var(--fd-ink);font-variant-numeric:tabular-nums}
.single-product div.product p.price .woocommerce-Price-currencySymbol{font-size:18px;vertical-align:top}
.single-product .sku_wrapper{font-size:13px;color:var(--fd-steel)}
.single-product div.product form.cart .button{
  background:var(--fd-navy);color:#fff;border-radius:4px;height:46px;font-size:15px;font-weight:500;
}
.single-product div.product form.cart .button:hover{background:var(--fd-blue-dark)}
.single-product .quantity .qty{height:46px;border:1px solid #C6D0DA;border-radius:4px;background:rgba(255,255,255,.66)}
.woocommerce-tabs .panel{
  background:rgba(255,255,255,.72);
  -webkit-backdrop-filter:blur(1px);backdrop-filter:blur(1px);
  border:1px solid rgba(180,196,212,.55);border-radius:8px;padding:20px;
}
.shop_attributes th{background:rgba(243,247,251,.72);color:var(--fd-steel);font-weight:500;width:210px}
.shop_attributes td{color:var(--fd-ink)}
.shop_attributes th,.shop_attributes td{border-bottom:1px solid rgba(200,212,224,.55);padding:10px 14px}

/* ==========================================================================
   7. Size finder — [flashdash_size_finder]
   ========================================================================== */
.fd-finder{margin:0 0 34px}
.fd-finder h2{margin:0 0 6px;font-size:29px;font-weight:600;letter-spacing:-.025em;line-height:1.15;color:var(--fd-navy)}
.fd-finder .fd-lede{margin:0 0 20px;color:var(--fd-steel);max-width:56ch;font-size:15.5px}
.fd-sizes{display:grid;grid-template-columns:repeat(auto-fit,minmax(112px,1fr));gap:10px}
.fd-size{
  border:1px solid #A8998A;border-radius:5px;padding:14px 10px 15px;text-align:center;text-decoration:none;
  display:flex;flex-direction:column;align-items:center;gap:8px;
  background:
    radial-gradient(90% 70% at 28% 6%, rgba(255,252,246,.72) 0%, rgba(255,252,246,0) 62%),
    linear-gradient(168deg,#E3D9CA 0%,#D6C9B6 52%,#C8BAA5 100%);
  box-shadow:inset 0 1px 0 rgba(255,255,255,.55);
}
.fd-size:hover{border-color:#9C8A72}
.fd-holder{position:relative;height:74px;display:flex;align-items:center;justify-content:center}
.fd-holder::before{
  content:"";position:absolute;top:50%;left:50%;width:10px;height:10px;transform:translate(-50%,-50%);
  border-radius:50%;pointer-events:none;opacity:0;
  transition:opacity .22s ease,width .22s ease,height .22s ease;
  background:radial-gradient(circle,rgba(255,226,170,.95) 0%,rgba(255,198,110,.55) 38%,rgba(255,180,70,0) 72%);
}
.fd-size:hover .fd-holder::before,.fd-size:focus-visible .fd-holder::before{opacity:1;width:132px;height:132px}
.fd-fx{display:block;width:auto;position:relative;z-index:1;transition:filter .22s ease}
.fd-size:hover .fd-fx,.fd-size:focus-visible .fd-fx{
  filter:brightness(1.16) saturate(1.06) drop-shadow(0 0 10px rgba(255,201,120,.75));
}
.fd-size b{font-size:15px;font-weight:600;color:#241D14;font-variant-numeric:tabular-nums}
.fd-size i{font-style:normal;font-size:12.5px;color:#6B5C48;line-height:1.3}
@media (prefers-reduced-motion:reduce){.fd-holder::before,.fd-fx{transition:none}}

/* ==========================================================================
   8. Footer and buttons
   ========================================================================== */
.site-footer{background:#081A2E;color:#9FB6CE}
.site-footer a{color:#CFE0F2}
.woocommerce-info,.woocommerce-message{border-top-color:var(--fd-amber)}
.woocommerce-info::before,.woocommerce-message::before{color:var(--fd-amber)}
button.alt,.button.alt,input[type="submit"].alt{background:var(--fd-amber);color:#fff}
button.alt:hover,.button.alt:hover{background:#D75104;color:#fff}
a{color:var(--fd-blue-dark)}

/* ==========================================================================
   9. Small screens
   ========================================================================== */
@media (max-width:768px){
  .site-header .custom-logo-link img{max-width:132px}
  .fd-delivery-track span{padding:10px 20px}
  .single-product div.product p.price{font-size:28px}
}

/* ==========================================================================
   10. Front page — category cards, shelf head, trust band
   ========================================================================== */
.fd-front{width:100%}
.fd-aisles{margin:0 0 34px}
.fd-aisles h2,.fd-shelf-head h2{margin:0 0 14px;font-size:19px;font-weight:600;letter-spacing:-.015em}
.fd-aisle-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:10px}
.fd-aisle{
  background:rgba(255,255,255,.92);border:1px solid var(--fd-line);border-radius:4px;
  border-left:4px solid var(--fd-blue);padding:14px 16px;text-decoration:none;
  display:flex;align-items:center;gap:13px;
}
.fd-aisle:hover{background:#fff;border-left-color:var(--fd-bolt)}
.fd-aisle-pic{
  flex:0 0 66px;width:66px;height:58px;border-radius:4px;
  background:#F4F6F9;border:1px solid #E4E9EF;
  display:flex;align-items:center;justify-content:center;overflow:hidden;
}
.fd-aisle-pic img{max-width:84%;max-height:84%;width:auto;height:auto;display:block}
.fd-aisle-txt{min-width:0}
.fd-aisle b{display:block;font-size:15.5px;font-weight:600;color:var(--fd-ink);margin:0 0 2px}
.fd-aisle span span,.fd-aisle-txt > span{display:block;font-size:13px;color:var(--fd-steel)}
.fd-aisle em{font-style:normal;font-variant-numeric:tabular-nums;color:var(--fd-ink);font-weight:500}

.fd-shelf{margin:0 0 34px}
.fd-shelf-head{display:flex;align-items:baseline;justify-content:space-between;gap:16px;flex-wrap:wrap}
.fd-seeall{
  color:var(--fd-navy);background:#FFCE8C;border-radius:3px;
  padding:7px 16px;font-size:14px;font-weight:600;text-decoration:none;
  line-height:1.2;display:inline-block;
}
.fd-seeall:hover{background:#FFE0B0;color:#08192A}

.fd-trust{
  display:grid;grid-template-columns:repeat(auto-fit,minmax(215px,1fr));gap:22px;
  background:var(--fd-navy);color:#DCE7F3;padding:26px 24px;border-radius:6px;margin:0 0 34px;
}
.fd-trust b{display:block;color:#fff;font-size:15px;font-weight:600;margin-bottom:2px}
.fd-trust p{margin:0;font-size:13.5px;line-height:1.5}
@media (max-width:768px){
  .fd-aisle-pic{flex-basis:54px;width:54px;height:50px}
}
