/*------------------------------------------------------------------
[Table of contents]

1. Import libraries
2. Custom properties
3. General Styles
4. Typography
5. Navs and Tabs
6. Breadcrumb
7. Buttons
8. Utilities
9. Sections
10.Boxes and Cards
11.Accordion
12.Form
13.Responsive Layouts

-------------------------------------------------------------------*/

/* ---------------------------- */
/* Import libraries             */
/* ---------------------------- */
/* Using system UI font stack for a modern, Apple-like feel */
/* Webfont for consistent loopless Thai on Windows/Android */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@300;400;500;600;700&display=swap');
@import url('../css/vendor/bootstrap.min.css');

/* ---------------------------- */
/* Custom properties            */
/* ---------------------------- */
:root {
  --primary-color:#ed2024;
  --secondary-color:#1E1E1E;
  --text-color:#FFFFFF;
  --text-color-2:#AAAAAA;
  --accent-color:#111111;
  --accent-color-2:#444444;
  /* Modern system font stack with Noto Sans Thai primary for cross-platform consistency */
  --font-sans: "Noto Sans Thai",
               -apple-system, BlinkMacSystemFont,
               /* Thai-first to keep glyphs consistent */
               "Sukhumvit Set", Thonburi, "Leelawadee UI",
               /* Cross-platform UI sans */
               "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", Tahoma,
               /* Emoji */
               "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji",
               sans-serif;
  --font-1: var(--font-sans);
  --font-2: var(--font-sans);
}
/* Desktop equalized logos for a tidy look */
@media (min-width: 992px) {
  .partner-logos-multirow {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 22px 32px;
    max-width: 1100px;
  }
  .partner-logos-multirow img,
  .partner-logos-multirow img[src$="carpro.png"],
  .partner-logos-multirow img[src$="adam's.png"],
  .partner-logos-multirow img[src$="spieshecker.png"],
  .partner-logos-multirow img[src$="spanesi.png"],
  .partner-logos-multirow img[src$="llumar.png"],
  .partner-logos-multirow img[src$="rupes.png"] {
    height: auto !important;
    max-height: 110px !important;
    width: auto !important;
    max-width: 100% !important; /* prevent wide logos overflowing cell */
    object-fit: contain;
  }
}

/* ---------------------------- */
/* General Styles               */
/* ---------------------------- */
body {
  font-family: var(--font-1);
  color: var(--text-color);
  background-color: var(--accent-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.bg-primary-color {
  background-color: var(--primary-color) !important;
}

.bg-secondary-color {
  background-color: var(--secondary-color) !important;
}

.bg-accent-color {
  background-color: var(--accent-color) !important;
}

.bg-accent-color-2 {
  background-color: var(--accent-color-2) !important;
}

.text-primary-color {
  color: var(--primary-color) !important;
}

.text-color {
  color: var(--text-color) !important;
}

.text-color-2 {
  color: var(--text-color-2) !important;
}

.font-1 {
  font-family: var(--font-1);
}

.font-2 {
  font-family: var(--font-2);
}

.lang-th, .lang-en { display: inline-block; }
/* Language Switch Toggle Styles */
.lang-switch-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 70px;
  height: 36px;
  background: #23233a;
  border: 2.5px solid #ed2024;
  border-radius: 22px;
  padding: 0 6px;
  cursor: pointer;
  position: relative;
  gap: 4px;
  overflow: hidden;
  transition: border 0.2s, box-shadow 0.2s, background 0.2s;
  box-shadow: 0 0 0 3px rgba(237, 32, 36, 0.18);
}
.lang-switch-toggle:hover, .lang-switch-toggle:focus {
  border-color: #ed2024;
  background: #191933;
  box-shadow: 0 0 0 5px rgba(237, 32, 36, 0.25);
}
.flag {
  transition: all 0.25s cubic-bezier(.4,2.08,.55,.44);
  border-radius: 6px;
  object-fit: cover;
  box-shadow: 0 1px 4px rgba(0,0,0,0.10);
  border: 1.5px solid transparent;
  background: #fff;
}
.flag-th, .flag-en {
  width: 22px;
  height: 16px;
  opacity: 0.5;
  filter: grayscale(40%);
  border-radius: 6px;
  object-fit: cover;
  box-shadow: 0 1px 4px rgba(0,0,0,0.10);
  border: 1.5px solid transparent;
  background: #fff;
  display: inline-block;
}
.lang-switch-toggle[data-lang="th"] .flag-th {
  width: 32px;
  height: 22px;
  opacity: 1;
  filter: none;
  border: 2px solid #ed2024;
  z-index: 2;
}
.lang-switch-toggle[data-lang="th"] .flag-en {
  width: 16px;
  height: 12px;
  opacity: 0.35;
  filter: grayscale(70%);
  z-index: 1;
}
.lang-switch-toggle[data-lang="en"] .flag-en {
  width: 32px;
  height: 22px;
  opacity: 1;
  filter: none;
  border: 2px solid #ed2024;
  z-index: 2;
}
.lang-switch-toggle[data-lang="en"] .flag-th {
  width: 16px;
  height: 12px;
  opacity: 0.35;
  filter: grayscale(70%);
  z-index: 1;
}
.lang-switch-label {
  font-size: 1em; /* ลดขนาดฟอนต์ */
  font-weight: bold;
  line-height: 1;
}
/* ซ่อน pseudo-element ธงที่ซ้อนกับ <img> */
.lang-switch-bg::before,
.lang-switch-bg::after {
  display: none !important;
}
.lang-switch-toggle[data-lang="en"] .lang-switch-bg::before {
  opacity: 0.5;
  color: #fff;
}
.lang-switch-toggle[data-lang="en"] .lang-switch-bg::after {
  opacity: 1;
  color: #ed2024;
}
.lang-switch-toggle[data-lang="th"] .lang-switch-bg::before {
  opacity: 1;
  color: #1ba8f8;
}
.lang-switch-toggle[data-lang="th"] .lang-switch-bg::after {
  opacity: 0.5;
  color: #fff;
}
/* แสดงชื่อภาษาใต้ปุ่ม (optional) */
.lang-switch-active-label {
  position: absolute;
  left: 50%;
  bottom: -22px;
  transform: translateX(-50%);
  font-size: 0.95em;
  color: #ed2024;
  font-weight: bold;
  letter-spacing: 0.5px;
  pointer-events: none;
  opacity: 0.85;
  transition: color 0.2s;
}
.lang-switch-toggle[data-lang="th"] .lang-switch-active-label::after {
  content: "ภาษาไทย";
}
.lang-switch-toggle[data-lang="en"] .lang-switch-active-label::after {
  content: "ENGLISH";
}

.section {
  padding: 6em 2em 6em 2em;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}

.b-container {
  max-width: 1240px;
  margin-right: auto;
  margin-left: auto;
}

img {
  object-fit: cover;
}

.heading {
  font-family: var(--font-2);
  font-weight: 600;
}

/* ---------------------------- */
/* Typography                   */
/* ---------------------------- */
h1 {
  font-size: 72px;
}

h2 {
  font-size: 48px;
}

h3 {
  font-size: 36px;
}

h4 {
  font-size: 25px;
}

h5 {
  font-size: 22px;
}

h6 {
  font-size: 20px;
}

/* Responsive heading sizes to free space on smaller screens */
@media (max-width: 991.98px) {
  h1 { font-size: 48px; }
}
@media (max-width: 600px) {
  h1 { font-size: 38px; line-height: 1.15; }
}
/* Desktop: slightly smaller hero heading to showcase logos */
@media (min-width: 992px) {
  h1 { font-size: 60px; line-height: 1.1; }
  /* Nudge hero heading further up to left area */
  .hero [style*="padding-top"] { padding-top: 15vh !important; }
  .hero h1 { max-width: 18ch; letter-spacing: -0.2px; }
}

p, a {
  font-size: 18px;
}

/* ---------------------------- */
/* Navs and Tabs                */
/* ---------------------------- */
.nav-link {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-color);
  font-family: var(--font-2);
}

.nav-link:hover,
.nav-link:focus {
  color: var(--primary-color) !important;
}

.nav-link.active {
  color: var(--primary-color) !important;
}

.nav-link.dropdown-toggle:hover,
.nav-link.dropdown-toggle:focus,
.nav-link.dropdown-toggle.show {
  color: var(--primary-color) !important;
}

.dropdown-menu {
  background-color: var(--secondary-color);
  border: none;
  border-radius: 15px;
  padding: 15px 0;
  width: 220px;
}

.dropdown-item {
  color: var(--text-color);
  font-size: 18px;
  font-weight: 600;
  font-family: var(--font-2);
  margin: 15px 0;
}

.dropdown-item:hover,
.dropdown-item:focus {
  color: var(--primary-color) !important;
  background-color: transparent;
}

.dropdown-item.active {
  color: var(--primary-color) !important;
  background-color: transparent;
}

.nav-pills .nav-link {
  padding: 10px 0;
  font-size: 22px;
  font-weight: bolder;
  text-align: end;
}

.nav-pills .nav-link.active {
  background-color: transparent;
  color: var(--text-color);
}

/* ---------------------------- */
/* Breadcrumb                   */
/* ---------------------------- */
.breadcrumb {
  font-size: 18px;
}

.breadcrumb .breadcrumb-item>a {
  color: var(--primary-color);
  text-decoration: none;
}

.breadcrumb-item + .breadcrumb-item::before {
  color: var(--text-color) !important;
}

.breadcrumb-item a:hover,
.breadcrumb-item.active {
  color: var(--text-color) !important;
}

/* ---------------------------- */
/* Buttons                      */
/* ---------------------------- */
.btn-cta-primary {
  background-color: var(--primary-color);
  color: var(--secondary-color);
  border: #ed2024 1px solid;
  padding: 13px 30px;
  font-size: 18px;
  border-radius: 30px;
  font-weight: 600;
  font-family: var(--font-2);
  transition: transform 0.3s ease, background-color 0.3s ease, color 0.3s ease, border 0.3s ease;
}

.btn-cta-primary:hover {
  background-color: var(--secondary-color) !important;
  color: var(--text-color);
  border: #FFFFFF 1px solid;
  transform: scale(1.05);
}

.btn-cta-secondary {
  background-color: var(--secondary-color);
  color: var(--text-color);
  border: none;
  padding: 13px 30px;
  font-size: 18px;
  border: #FFFFFF 1px solid;
  border-radius: 30px;
  font-weight: 600;
  font-family: var(--font-2);
  transition: transform 0.3s ease, background-color 0.3s ease, color 0.3s ease, border 0.3s ease;
}

.btn-cta-secondary:hover {
  background-color: var(--primary-color) !important;
  color: var(--accent-color);
  border: #ed2024 1px solid;
  transform: scale(1.05);
}

/* ---------------------------- */
/* Utilities                    */
/* ---------------------------- */
.bg-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(17, 17, 17, 0.58);
  z-index: 1;
  pointer-events: none;
  inset: 0;
}

.img-wrapper {
  width: 100%;
  max-width: 1000px;
}

.img-ratio-321 {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
}

.img-ratio-121 {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}

.img-ratio-113 {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}

.links-primary {
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease;
}

.links-primary:hover,
.links-primary.active {
  color: var(--primary-color) !important;
}

.bg-wrapper {
  position: relative;
}

.bg-grayscale {
  filter: grayscale(100%);
  transition: filter 0.5s ease;
  display: block;
  width: 100%;
  height: 350px;
  pointer-events: auto;
}

.bg-wrapper:hover .bg-grayscale  {
  filter: grayscale(0%);
}

/* ---------------------------- */
/* Sections                     */
/* ---------------------------- */
.hero {
  font-family: var(--font-2);
  height: 90vh;
}
/* Ensure hero has enough space for logos on smaller screens */
@media (max-width: 991.98px) {
  .hero { height: auto; min-height: 108vh; padding-bottom: 1rem; }
  /* Override inline padding that pushes heading too far down */
  .hero [style*="padding-top"] { padding-top: 10vh !important; }
}
@media (max-width: 600px) {
  .hero { height: auto; min-height: 155vh; padding-bottom: 1.25rem; }
  .hero [style*="padding-top"] { padding-top: 8vh !important; }
}

.feature {
  margin-top: -125px;
  z-index: 2;
}

/* Avoid overlapping hero logos on tablets/mobiles */
@media (max-width: 991.98px) {
  .feature { margin-top: 0; }
}
@media (max-width: 768px) {
  .feature { margin-top: 0; }
}
@media (max-width: 576.98px) {
  .feature { margin-top: -8px; }
}

.warranty {
  padding: 15vh 0;
}

.info-lb-overlay {
  width: 75%;
  background-color: rgba(17, 17, 17, 0.8);
  left: 8%;
  bottom: 8%;
  border-radius: 24px;
}

.reviews {
  overflow: hidden;
}

/* ---------------------------- */
/* Boxes and Cards              */
/* ---------------------------- */
.logo-box {
  max-width: 160px;
}

.feature-box-wrapper {
  background: transparent;
}

.feature-box {
  padding: 20px;
  color: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  width: 285px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.feature-title {
  font-weight: 700;
  font-size: 1.25rem;
  margin-bottom: 15px;
  font-family: var(--font-2);
}

.feature-box:not(:last-child) {
  margin-bottom: 0;
}

.service-box {
  background-color: var(--secondary-color);
  width: 100%;
  border-radius: 25px;
  padding: 30px;
  z-index: 2;
  transition: all 0.3s ease;
}

.service-box.top-left {
  top: -75%;
  left: -10%;
}

.service-box.top-right {
  top: -75%;
  right: -10%;
}

.service-icon {
  top: 1px;
  left: 1px;
  background-color: var(--primary-color);
  width: 65px;
  height: 65px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0px 0 15px var(--accent-color);
}

.service-icon i {
  color: var(--accent-color);
  font-size: 50px;
  font-weight:900;
}

.step-number {
  background-color: var(--secondary-color);
  color: var(--text-color);
  font-weight: 700;
  font-size: 25px;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.card {
  background-color: var(--secondary-color);
  color: var(--text-color);
  border: 0;
}

.blogs {
  transition: all 0.3s ease;
}

.blogs-title {
  transition: color 0.3s ease;
  color: var(--text-color);
  text-decoration: none;
}

.blogs:hover .blogs-title {
  color: var(--primary-color);
}

.blogs-cover {
  transition: transform 0.5s ease;
  transform-origin: center center;
}

.blogs:hover .blogs-cover {
  transform: scale(1.05) rotate(1deg);
}

.social-box {
  display: flex;
  gap: 16px;
}

.social-box a {
  background-color: var(--secondary-color);
  color: var(--primary-color);
  align-content: center;
  text-align: center;
  padding: 7px 0;
  transition: all 0.3s ease-in-out;
}

.social-box a:hover {
  background-color: var(--primary-color);
  color: var(--accent-color);
}

.card-team-label {
  background-color: var(--accent-color);
  opacity: 85%;
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  width: 70%;
}

.card-service-label {
  background-color: rgba(17, 17, 17, 0.6);
  position: absolute;
  bottom: -24px;
  left: 50%;
  transform: translateX(-50%) translateY(0);
  width: 90%;
  max-height: 130px;
  overflow: hidden;
  transition: all 0.4s ease;
}

.card-service-label .card-text {
  color: var(--text-color-2);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.group-card:hover .card-service-label {
  transform: translateX(-50%) translateY(-25%);
  max-height: 400px;
}

.group-card:hover .card-service-label .card-text {
  opacity: 1;
}

.footer-logo-box {
  height: 60px;
}

/* ---------------------------- */
/* Accordion                    */
/* ---------------------------- */
.accordion .accordion-item {
  border: none;
  border-radius: 0;
  background-color: transparent;
  border-bottom: var(--accent-color-2) 2px solid;
}

.accordion .accordion-button {
  font-family: var(--font-2);
  padding: 15px 0px;
  font-size: 22px;
  font-weight: 600;
  background-color: transparent;
  color: var(--text-color);
  border: none;
  border-bottom: none !important;
  box-shadow: none !important;
}

.accordion .accordion-button::after {
  display: none;
}

.accordion .accordion-button.collapsed {
  color: var(--text-color-2);
  font-weight: 400;
  background-color: transparent;
}

.accordion .accordion-body {
  color: var(--text-color-2);
  padding: 10px 0px;
}

.accordion .accordion-body-2 {
  color: var(--text-color-2);
  padding: 10px 15px 10px 100px;
}

/* ---------------------------- */
/* Form                         */
/* ---------------------------- */
.form label {
  font-size: 18px;
  font-weight: 500;
}

.form input,
.form textarea {
  background-color: transparent;
  color: var(--text-color);
  border: solid 2px var(--accent-color-2);
  border-radius: 7px;
  outline: none;
  padding: 17px 30px;
}

.form input:focus,
.form textarea:focus {
    box-shadow: none;
    border: solid 2px var(--accent-color-2);
    background-color: transparent;
    color: var(--text-color);
}

.form input::placeholder,
.form textarea::placeholder {
    color: var(--text-color-2);
}

/* ---------------------------- */
/* Responsive Layouts           */
/* ---------------------------- */
@media only screen and (max-width: 1199.98px) {
  .section {
    padding: 5em 1.5em;
  }

  h1 {
    font-size: 64px;
  }

  h2 {
    font-size: 40px;
  }

  h3 {
    font-size: 32px;
  }

  h4 {
    font-size: 22px;
  }

  p,a {
    font-size: 18px;
  }

  .hero {
    height: 90vh;
  }

  .service-box.top-left {
    top: 0;
    left: 0;
  }

  .service-box.top-right {
    top: 0;
    right: 0;
  }

  .img-ratio-321 {
    position: relative;
    aspect-ratio: 21 / 9;
    overflow: hidden;
  }

  .img-ratio-121 {
    position: relative;
    aspect-ratio: 21 / 9;
    overflow: hidden;
  }

  .info-lb-overlay {
    width: 90%;
    left: 5%;
    bottom: 15%;
  }

  .footer-logo-box {
    height: 120px;
    width: 100%;
    display: flex;
    justify-content: center;
  }
}

@media (max-width: 991.98px) {
  .lang-switch-toggle {
    width: 60px;
    height: 32px;
    border-radius: 16px;
    padding: 0 3px;
    gap: 3px;
    align-items: center;
    justify-content: center;
  }
  .flag-th, .flag-en {
    width: 16px;
    height: 11px;
    opacity: 0.5;
    filter: grayscale(40%);
    border-width: 1px;
    display: inline-block;
  }
  .lang-switch-toggle[data-lang="th"] .flag-th {
    width: 26px;
    height: 18px;
    opacity: 1;
    filter: none;
    border: 1.5px solid #ed2024;
    z-index: 2;
  }
  .lang-switch-toggle[data-lang="th"] .flag-en {
    width: 14px;
    height: 10px;
    opacity: 0.3;
    filter: grayscale(80%);
    border: 1px solid transparent;
    z-index: 1;
  }
  .lang-switch-toggle[data-lang="en"] .flag-en {
    width: 26px;
    height: 18px;
    opacity: 1;
    filter: none;
    border: 1.5px solid #ed2024;
    z-index: 2;
  }
  .lang-switch-toggle[data-lang="en"] .flag-th {
    width: 14px;
    height: 10px;
    opacity: 0.3;
    filter: grayscale(80%);
    border: 1px solid transparent;
    z-index: 1;
  }
}

@media only screen and (max-width: 768.98px) {
  .section {
    padding: 3em 1em;
  }

  h1 {
    font-size: 48px;
  }

  h2 {
    font-size: 32px;
  }

  h3 {
    font-size: 24px;
  }

  h4 {
    font-size: 20px;
  }

  h5 {
    font-size: 18px;
  }

  h6 {
    font-size: 16px;
  }

  p,a {
    font-size: 14px;
  }

  .hero {
    height: 80vh;
  }

  .feature {
    margin-top: 0;
    z-index: 2;
  }

  .nav-pills .nav-link {
    text-align: center;
  }

  .footer-logo-box {
    height: 100px;
  }
}

@media only screen and (max-width: 576.98px) {
  .section {
    padding: 2em 1em;
  }

  h1 {
    font-size: 40px;
  }

  h2 {
    font-size: 28px;
  }

  h3 {
    font-size: 22px;
  }

  h4 {
    font-size: 18px;
  }

  h5 {
    font-size: 16px;
  }

  h6 {
    font-size: 14px;
  }

  p, a {
    font-size: 12px;
  }

  .hero {
    height: 85vh;
  }

  .service-icon {
    width: 55px;
    height: 55px;
  }

  .info-lb-overlay {
    bottom: 27.5%;
    bottom: 10%;
  }

  .img-ratio-321 {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
  }

  .img-ratio-113 {
    position: relative;
    aspect-ratio: 3 / 2;
    overflow: hidden;
  }

  .card-team-label {
    background-color: var(--accent-color);
    opacity: 85%;
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
  }

  .footer-logo-box {
    height: 80px;
  }

  .card.blogs .blogs-cover, .blogs .blogs-cover {
    height: 140px;
  }
}

/* กล่องขั้นตอนบริการ (Service Step Box) */
.service-step-box {
  background: rgba(34, 34, 34, 0.92);
  border: 2px solid #ed2024;
  border-radius: 22px;
  box-shadow: 0 4px 24px 0 rgba(0,0,0,0.12);
  padding: 2rem 1.2rem 1.5rem 1.2rem;
  margin-bottom: 1.5rem;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.service-step-box:hover {
  box-shadow: 0 8px 32px 0 rgba(0,0,0,0.18);
  border-color: #FFC107;
}
@media (max-width: 767px) {
  .service-step-box {
    padding: 1.2rem 0.7rem 1rem 0.7rem;
    border-radius: 16px;
  }
}

/* Step Badge for Service Steps */
.step-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #111;
  border-radius: 18px;
  min-width: 120px;
  min-height: 48px;
  padding: 0.2em 1.2em;
  box-shadow: 0 2px 12px 0 rgba(0,0,0,0.18);
  margin-bottom: 1.2rem;
  font-family: inherit;
}
.step-label {
  color: #fff;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 1px;
  margin-right: 0.5em;
}
.step-number {
  color: #ed2024;
  font-size: 2rem;
  font-weight: 900;
  line-height: 1;
  text-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
@media (max-width: 767px) {
  .step-badge {
    min-width: 90px;
    min-height: 38px;
    padding: 0.1em 0.7em;
  }
  .step-label {
    font-size: 1.05rem;
  }
  .step-number {
    font-size: 1.3rem;
  }
}

/* ===== Custom: Force 4 service cards in a row under the car image ===== */
.service-section-cards-row {
  display: flex !important;
  flex-wrap: nowrap !important;
  justify-content: center;
  align-items: flex-end;
  gap: 2rem;
  margin-top: -60px; /* overlap under car image */
  margin-bottom: 2rem;
}
.service-section-cards-row > [class*='col-'] {
  flex: 0 1 22%;
  max-width: 22%;
  min-width: 220px;
  padding-left: 0;
  padding-right: 0;
}
@media (max-width: 1199.98px) {
  .service-section-cards-row {
    gap: 1rem;
    margin-top: -30px;
  }
  .service-section-cards-row > [class*='col-'] {
    flex-basis: 24%;
    max-width: 24%;
    min-width: 180px;
  }
}
@media (max-width: 991.98px) {
  .service-section-cards-row {
    flex-wrap: wrap !important;
    gap: 1rem;
    margin-top: 1rem;
  }
  .service-section-cards-row > [class*='col-'] {
    flex-basis: 48%;
    max-width: 48%;
    min-width: 160px;
    margin-bottom: 1rem;
  }
}
@media (max-width: 576.98px) {
  .service-section-cards-row {
    flex-direction: column !important;
    align-items: center;
    margin-top: 1rem;
  }
  .service-section-cards-row > [class*='col-'] {
    flex-basis: 100%;
    max-width: 100%;
    min-width: 0;
  }
}

/* ===== Make blog cards equal height and beautiful ===== */
.row.row-cols-1.row-cols-md-2.row-cols-lg-3.g-4.mt-5.pt-2 {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
}
.card.blogs, .blogs {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}
.card.blogs .blogs-cover, .blogs .blogs-cover {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-top-left-radius: 1rem;
  border-top-right-radius: 1rem;
}
.card.blogs .card-body, .blogs .card-body {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
@media (max-width: 991.98px) {
  .card.blogs .blogs-cover, .blogs .blogs-cover {
    height: 180px;
  }
}
@media (max-width: 576.98px) {
  .card.blogs .blogs-cover, .blogs .blogs-cover {
    height: 140px;
  }
}

/* ===== Partner Logo Bar in Hero Section ===== */
.partner-logo-bar {
  background: rgba(30, 30, 30, 0.75);
  border-radius: 1.5rem;
  box-shadow: 0 8px 32px rgba(0,0,0,0.25);
  padding: 1.5rem 1rem;
  backdrop-filter: blur(4px);
  min-height: 120px;
  justify-content: center;
  align-items: center;
  gap: 2rem;
}

/* Two-row partner logos in hero (grid) */
.partner-logos-multirow {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  align-items: center;
  justify-items: center;
  gap: 16px 28px; /* row x column gap */
  position: relative;
  z-index: 5; /* stay above feature cards when stacked */
  margin-inline: auto;
  max-width: 900px;
}
.partner-logos-multirow img {
  height: auto !important;
  max-height: 100px !important;
  max-width: 220px !important;
  width: auto !important;
  object-fit: contain;
  position: relative;
  z-index: 1;
}
/* Subtle plate behind logos for readability */
.partner-logos-multirow::before {
  content: "";
  position: absolute;
  inset: -10px -14px;
  background: radial-gradient(100% 120% at 70% 50%, rgba(0,0,0,0.22) 0%, rgba(0,0,0,0.12) 40%, rgba(0,0,0,0) 100%);
  border-radius: 16px;
  z-index: 0;
}
/* Emphasize CarPro logo to be larger than others */
.partner-logos-multirow img[src$="carpro.png"] {
  max-height: 150px !important;
  max-width: 270px !important;
}
/* Nudge other brand logos slightly larger */
.partner-logos-multirow img[src$="adam's.png"],
.partner-logos-multirow img[src$="spieshecker.png"],
.partner-logos-multirow img[src$="spanesi.png"],
.partner-logos-multirow img[src$="llumar.png"],
.partner-logos-multirow img[src$="rupes.png"] {
  max-height: 110px !important;
  max-width: 235px !important;
}
/* Slightly larger Adam's logo */
.partner-logos-multirow img[src$="adam's.png"] {
  max-height: 120px !important;
  max-width: 245px !important;
}
@media (max-width: 991.98px) {
  .partner-logos-multirow {
    grid-template-columns: repeat(3, minmax(120px, 1fr));
    gap: 16px 20px;
    grid-auto-flow: dense;
    max-width: 680px;
  }
  /* Equalize logo sizes on tablets (~768–991px) */
  .partner-logos-multirow img {
    height: 90px !important;
    width: auto !important;
    max-height: none !important;
    max-width: 240px !important;
  }
  .partner-logos-multirow img[src$="carpro.png"],
  .partner-logos-multirow img[src$="adam's.png"],
  .partner-logos-multirow img[src$="spieshecker.png"],
  .partner-logos-multirow img[src$="spanesi.png"],
  .partner-logos-multirow img[src$="llumar.png"],
  .partner-logos-multirow img[src$="rupes.png"] {
    height: 90px !important;
    width: auto !important;
    max-height: none !important;
    max-width: 240px !important;
  }
}
@media (max-width: 600px) {
  .partner-logos-multirow {
    /* Switch to 2 columns to allow 50% larger logos */
    grid-template-columns: repeat(2, 1fr);
    gap: 14px 18px;
    grid-auto-flow: dense;
    max-width: min(95vw, 420px);
    margin-top: 6px;
  }
  /* Equalize logo size around 400px viewport: same height for all */
  .partner-logos-multirow img {
    height: 96px !important;
    width: auto !important;
    max-height: none !important;
    max-width: 220px !important;
    margin: 0.25rem !important;
  }
  /* Neutralize brand-specific overrides on mobile to keep size equal */
  .partner-logos-multirow img[src$="carpro.png"],
  .partner-logos-multirow img[src$="adam's.png"],
  .partner-logos-multirow img[src$="spieshecker.png"],
  .partner-logos-multirow img[src$="spanesi.png"],
  .partner-logos-multirow img[src$="llumar.png"],
  .partner-logos-multirow img[src$="rupes.png"] {
    height: 96px !important;
    width: auto !important;
    max-height: none !important;
    max-width: 220px !important;
  }
}
.partner-logo-img {
  height: 60px;
  width: 120px;
  object-fit: contain;
  background: #fff;
  border-radius: 0.75rem;
  box-shadow: 0 2px 12px rgba(0,0,0,0.10);
  padding: 0.5rem 1rem;
  margin: 0 0.25rem;
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.partner-logo-img:hover {
  transform: scale(1.08) translateY(-4px);
  box-shadow: 0 8px 24px rgba(237,32,36,0.18), 0 2px 12px rgba(0,0,0,0.18);
  z-index: 2;
}

/* Ensure desktop logos are uniform and not overlapping */
@media (min-width: 992px) {
  .partner-logos-multirow {
    grid-template-columns: repeat(3, minmax(180px, 1fr));
    gap: 22px 32px;
    max-width: 1100px;
    margin-inline: auto;
  }
  .partner-logos-multirow img,
  .partner-logos-multirow img[src$="carpro.png"],
  .partner-logos-multirow img[src$="adam's.png"],
  .partner-logos-multirow img[src$="spieshecker.png"],
  .partner-logos-multirow img[src$="spanesi.png"],
  .partner-logos-multirow img[src$="llumar.png"],
  .partner-logos-multirow img[src$="rupes.png"] {
    height: auto !important;
    max-height: 110px !important;
    width: auto !important;
    max-width: 100% !important;
    object-fit: contain;
  }
  /* Make CarPro a bit larger on desktop */
  .partner-logos-multirow img[src$="carpro.png"] {
    max-height: 165px !important; /* ~+50% from previous */
  }
  /* Nudge logos block slightly down-right for balance */
  .hero .col-xl-4 .partner-logos-multirow {
    transform: translate(16px, 22px);
  }
}
@media (max-width: 991.98px) {
  .partner-logo-bar {
    gap: 1rem;
    padding: 1rem 0.5rem;
  }
  .partner-logo-img {
    height: 44px;
    width: 80px;
    padding: 0.25rem 0.5rem;
  }
}
@media (max-width: 576.98px) {
  .partner-logo-bar {
    gap: 0.5rem;
    padding: 0.5rem 0.25rem;
    min-height: 80px;
  }
  .partner-logo-img {
    height: 32px;
    width: 60px;
    padding: 0.15rem 0.25rem;
  }
}

/* Responsive partner logo bar for mobile 320px */
@media (max-width: 400px) {
  .partner-logo-bar {
    flex-wrap: wrap;
    gap: 0.25rem;
    padding: 0.25rem 0.1rem;
    min-height: 90px;
    max-width: 98vw;
  }
  .partner-logo-img {
    height: 24px;
    width: 44px;
    padding: 0.05rem 0.1rem;
    margin: 0.1rem;
  }
}

/* Overrides to enlarge CarPro on tablet and mobile */
@media (max-width: 991.98px) {
  .partner-logos-multirow img[src$="carpro.png"] {
    height: 202px !important; /* +50% from 135px */
    max-width: 390px !important;
  }
}
@media (max-width: 600px) {
  .partner-logos-multirow img[src$="carpro.png"] {
    height: 216px !important; /* +50% from 144px */
    max-width: 450px !important;
    transform: translateX(10px);
    will-change: transform;
  }
}

/* Responsive How it works/Accordion section for mobile 320px */
@media (max-width: 400px) {
  .accordion, .accordion-item, .accordion-header, .accordion-body {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
  .accordion-button, .accordion-header, .accordion-body, .accordion-item h2, .accordion-item h3, .accordion-item h4, .accordion-item h5 {
    font-size: 1rem !important;
    line-height: 1.3;
  }
  .accordion-body p, .accordion-body span, .accordion-body {
    font-size: 0.95rem !important;
    line-height: 1.4;
    word-break: break-word;
  }
  .accordion .accordion-item {
    margin-bottom: 0.5rem;
    border-radius: 0.7rem;
  }
  .accordion-button {
    padding: 0.7rem 1rem;
    border-radius: 0.7rem;
  }
  .accordion-body {
    padding: 0.7rem 1rem 0.7rem 1rem !important;
  }
  .accordion-body img, .accordion-body .img-wrapper, .accordion-body .img-ratio-121 {
    display: block;
    margin: 0.7rem auto 0 auto;
    max-width: 100%;
    height: auto !important;
    border-radius: 0.7rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.10);
  }
  .btn, .btn-cta-primary, .btn-cta-secondary {
    font-size: 1rem !important;
    padding: 0.7rem 1.2rem !important;
    border-radius: 0.7rem !important;
  }
  .section {
    padding: 1.2em 0.2em !important;
  }
  .accordion-body blockquote, .accordion-body .quote, .accordion-body p.quote {
    display: block;
    margin-bottom: 0.5rem;
    position: static;
    background: none;
    z-index: auto;
  }
  .accordion-body img, .accordion-body .img-wrapper, .accordion-body .img-ratio-121 {
    margin-top: 0.5rem;
  }
}

/* Appointment section car image: zoom to taillight */
.appointment-section-car-img {
  object-fit: cover !important;
  object-position: 99% 70% !important;
  width: 100% !important;
  height: 320px !important;
  border-radius: 1.2rem !important;
  max-width: 100%;
  transform: scale(2.7);
}
@media (max-width: 600px) {
  .appointment-section-car-img {
    height: 180px !important;
    transform: scale(2.9);
    object-position: 100% 72% !important;
  }
}

@media (max-width: 600px) {
  .partner-logos-multirow img {
    height: 44px !important;
    max-width: 90px !important;
    margin: 0.25rem !important;
  }
}

#lineContactBtn {
  position: fixed;
  right: 18px;
  bottom: 90px;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: #00c300;
  border-radius: 50%;
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
  transition: box-shadow 0.2s;
  text-decoration: none !important;
}
#lineContactBtn:hover {
  box-shadow: 0 8px 32px rgba(0,195,0,0.25), 0 2px 12px rgba(0,0,0,0.18);
  filter: brightness(1.1);
}
/* Facebook floating button (stacked above LINE) */
#facebookContactBtn {
  position: fixed;
  right: 18px;
  bottom: 160px;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: #1877F2;
  border-radius: 50%;
  color: #fff;
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
  transition: box-shadow 0.2s, filter 0.2s;
  text-decoration: none !important;
}
#facebookContactBtn:hover {
  box-shadow: 0 8px 32px rgba(24,119,242,0.25), 0 2px 12px rgba(0,0,0,0.18);
  filter: brightness(1.08);
}
/* TikTok floating button (stacked above Facebook) */
#tiktokContactBtn {
  position: fixed;
  right: 18px;
  bottom: 230px;
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: #000;
  border-radius: 50%;
  color: #fff;
  box-shadow: 0 4px 16px rgba(0,0,0,0.18);
  transition: box-shadow 0.2s, filter 0.2s;
  text-decoration: none !important;
}
#tiktokContactBtn:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.25), 0 2px 12px rgba(0,0,0,0.18);
  filter: brightness(1.15);
}
@media (max-width: 600px) {
  #lineContactBtn {
    width: 44px;
    height: 44px;
    right: calc(10px + env(safe-area-inset-right)) !important;
    bottom: calc(18px + env(safe-area-inset-bottom)) !important;
  }
  #lineContactBtn i {
    font-size: 1.4rem;
  }
  #facebookContactBtn, #tiktokContactBtn {
    width: 44px;
    height: 44px;
    right: calc(10px + env(safe-area-inset-right)) !important;
  }
  #facebookContactBtn { bottom: calc(78px + env(safe-area-inset-bottom)) !important; }
  #tiktokContactBtn { bottom: calc(138px + env(safe-area-inset-bottom)) !important; }
  #facebookContactBtn i, #tiktokContactBtn i { font-size: 1.35rem; }
}

/* Make icons crisp and remove any underline artifacts */
#facebookContactBtn i, #tiktokContactBtn i, #lineContactBtn i {
  line-height: 1;
  text-decoration: none !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: inline-block;
}
