/*
Theme Name: Storefront Child
Theme URI: https://shohanmotors.com/
Author: Shohan Motors
Author URI: https://shohanmotors.com/
Template: storefront
Version: 1.3
Description: Lightweight child theme for Shohan Motors with sticky CTA, optimized mobile menu, and performance-focused CSS.
*/

/* -----------------------------
   Global Typography & Base
------------------------------ */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

body {
  font-family: 'Roboto', Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #222;
  background: #fff;
  overflow-x: hidden;
  padding-bottom: 70px; /* prevent overlap with sticky bar */
}

/* -----------------------------
   Header & Navigation
------------------------------ */
.storefront-primary-navigation,
.storefront-handheld-navigation {
  position: relative;
  z-index: 10000;
}

button.menu-toggle {
  position: relative;
  z-index: 10001;
}

/* Handheld Navigation */
.storefront-handheld-navigation {
  display: none;
  background: #111;
  color: #fff;
  position: absolute;
  top: 60px; /* adjust to header height */
  left: 0;
  right: 0;
  z-index: 9999;
  overflow: hidden;
  max-height: 0;
  padding: 0;
  transition: max-height 0.4s ease, padding 0.3s ease;
}

.storefront-handheld-navigation.toggled-on {
  display: block !important;
  max-height: 500px; /* enough to show menu */
  padding: 15px 0;
}

.storefront-handheld-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.storefront-handheld-navigation li {
  margin: 10px 0;
  text-align: center;
}

.storefront-handheld-navigation a {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  display: block;
  padding: 10px;
  transition: background 0.3s ease;
}

.storefront-handheld-navigation a:hover {
  background: #e63946;
  color: #fff;
}

/* -----------------------------
   Product Page Contact Buttons
------------------------------ */
.sm-contact-buttons {
  margin-top: 15px;
}

.sm-contact-btn {
  display: inline-block;
  padding: 10px 15px;
  border-radius: 4px;
  font-weight: 600;
  text-decoration: none;
  margin: 5px 8px 0 0;
  font-size: 15px;
  transition: background 0.3s ease, opacity 0.2s ease;
}

.sm-btn-whatsapp {
  background: #1D4E89;
  color: #fff;
}
.sm-btn-whatsapp:hover {
  background: #163a66;
}

.sm-btn-call {
  background: #E63946;
  color: #fff;
}
.sm-btn-call:hover {
  background: #b52c36;
}

@media (min-width: 768px) {
  .sm-btn-call { display: none; }
}

/* -----------------------------
   Sticky Contact Bar
------------------------------ */
#sm-cta {
  position: fixed !important;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex !important;
  justify-content: center;
  align-items: center;
  gap: 16px;
  padding: 12px;
  background: #1D4E89;
  color: #fff;
  z-index: 2147483647;
  box-shadow: 0 -4px 12px rgba(0,0,0,0.08);
}

#sm-cta a {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  padding: 10px 14px;
  border-radius: 6px;
  background: rgba(255,255,255,0.08);
  transition: background 0.25s ease;
}

#sm-cta a:hover {
  background: rgba(255,255,255,0.18);
}

@media (max-width: 767px) {
  #sm-cta { font-size: 16px; padding: 12px 8px; }
  #sm-cta a { font-size: 15px; padding: 10px 12px; }
}

/* -----------------------------
   Hero Section
------------------------------ */
#hero {
  position: relative;
  text-align: center;
  overflow: hidden;
}

#hero img {
  width: 100%;
  height: auto;
  display: block;
}

#hero .hero-btn {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: #e63946;
  color: #fff;
  padding: 15px 30px;
  border-radius: 4px;
  text-decoration: none;
  font-weight: bold;
  font-size: 18px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  transition: background 0.3s ease;
}

#hero .hero-btn:hover {
  background: #c72f3a;
}

/* -----------------------------
   Why Choose Us Section
------------------------------ */
#why-choose-us {
  padding: 40px 20px;
  background: #f9f9f9;
}

#why-choose-us .container {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}

#why-choose-us h2 {
  font-size: 2em;
  margin-bottom: 40px;
}

#why-choose-us .features {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  gap: 20px;
}

#why-choose-us .feature {
  flex: 1 1 200px;
  max-width: 220px;
  text-align: justify;
}

#why-choose-us .feature h3 {
  text-align: center;
  margin-bottom: 10px;
}

#why-choose-us .feature p {
  font-size: 15px;
  line-height: 1.6;
}

@media (max-width: 767px) {
  #why-choose-us .features {
    flex-direction: column;
    align-items: center;
  }
  #why-choose-us .feature {
    max-width: 100%;
    margin-bottom: 20px;
  }
}

/* -----------------------------
   Footer
------------------------------ */
#site-footer {
  background: #0B1C2C;
  color: #fff;
  padding: 40px 20px 90px;
  font-size: 15px;
}

#site-footer .footer-columns {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 30px;
}

#site-footer h3 {
  color: #F4A261;
  margin-bottom: 15px;
  font-size: 18px;
}

#site-footer p,
#site-footer a {
  color: #ddd;
  line-height: 1.6;
  text-decoration: none;
}

#site-footer a:hover {
  color: #fff;
}

#site-footer .footer-bottom {
  text-align: center;
  margin-top: 30px;
  font-size: 13px;
  color: #aaa;
}

@media (max-width: 767px) {
  #site-footer .footer-columns {
    flex-direction: column;
    text-align: center;
  }
}

/* 3. Reserve space for sticky CTA bar */
body::after {
  content: "";
  display: block;
  height: 70px; /* matches sticky bar height */
}

/* 5. Prevent pagination jump */
.woocommerce-pagination {
  min-height: 50px;
}

/* Ensure product images don’t cause shifts */
.woocommerce ul.products li.product img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1; /* keeps square ratio */
  object-fit: contain;
}
