:root {
  --brand-badge: url("/assets/img/svg/TPM_Badge.svg");
  --brand-logo: url("/assets/img/svg/headerlogo-new-dark.svg");
}

@media (max-width: 450px) {
  .float-image, .float-image.right {
    float: none;
    width: 100%;
    max-width: 500px;
    margin: 0 auto 1.5rem auto;
    display: block;
    shape-outside: none;
  }
}

@media (min-width: 576px) {
  .card-body p {
    display: block;
  }
}

.container {
  --bs-gutter-x: 1rem;
}

@media (min-width: 768px) {
  .container {
    --bs-gutter-x: 2rem;
  }
}

@media (min-width: 1200px) {
  .container {
    --bs-gutter-x: 3rem;
  }
}

@media (max-width: 575.98px) {
  .float-image.right {
    margin: 0 0 .8rem 1rem;
  }
}

@media (max-width: 575.98px) {
  .float-image, .float-image.right {
    width: 62%;
    min-width: 200px;
    margin: 0 1rem .8rem 0;
  }
}

@media (max-width: 649.98px) {
  #navButt {
    min-width: 120px;
  }
}

@media (max-width: 649.98px) {
  #searchBar {
    width: 72px;
    max-width: 420px;
    transition: width 0.3s ease;
    transform-origin: left center;
    padding-right: 0;
  }
}

@media (max-width: 649.98px) {
  #searchBar:focus-within {
    width: 180px;
    max-width: 180px;
  }
}

@media (min-width: 650px) {
  #navButt {
    min-width: 206px;
  }
}

@media (min-width: 650px) {
  #searchBar {
    padding-right: 30%;
  }
}

@media (max-width: 767.98px) {
  .float-image {
    width: 55%;
    min-width: 240px;
    margin: 0 1rem .8rem 0;
  }
}

@media (max-width: 767.98px) {
  #navButt ul {
    flex-direction: column;
  }
}

@media (max-width: 767.98px) {
  .float-image.right {
    margin: 0 0 .8rem 1rem;
  }
}

@media (max-width: 767.98px) {
  .map-container iframe {
    height: 250px;
  }
}

@media (max-width: 767.98px) {
  .thumbnail {
    height: 60px;
  }
}

@media (max-width: 767.98px) {
  #searchInput {
    font-size: 14px;
  }
}

@media (max-width: 767.98px) {
  #swiper-1 {
    height: 12rem;
  }
}

@media (min-width: 768px) {
  #swiper-1 {
    height: 16rem;
  }
}

@media (max-width: 985.98px) {
  #brandBadge {
    display: block;
  }
}

@media (max-width: 985.98px) {
  #brandLogo {
    display: none;
  }
}

@media (min-width: 986px) {
  #brandBadge {
    display: none;
  }
}

@media (min-width: 986px) {
  #brandLogo {
    display: block;
  }
}

@media (min-width: 1200px) {
  .image-container .bg {
    max-width: 85%;
  }
}

@media (min-width: 1200px) {
  #snowCarousel .carousel-item {
    height: 34rem;
  }
}

@media (min-width: 1600px) {
  .image-container .bg {
    max-width: 75%;
  }
}

@media (min-width: 1600px) {
  #snowCarousel .carousel-item {
    height: 36rem;
  }
}

#searchBar {
  justify-self: start;
}

#brand {
  justify-self: center;
  flex: 1;
}

#navButt {
  justify-self: end;
}

#brandBadge {
  background: var(--brand-badge) no-repeat center;
  background-size: contain;
  width: 70px;
  height: 60px;
}

#brandLogo {
  background: var(--brand-logo) no-repeat center;
  background-size: contain;
  min-width: 200px;
  min-height: 60px;
}

.custom-navbar {
  background-image: var(--bs-gradient)!important;
  --bs-bg-opacity: .90;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  background-color: rgba(var(--bs-dark-rgb),var(--bs-bg-opacity))!important;
}

.custom-navbar .container {
  max-width: 100% !important;
  padding-left: 3% !important;
  padding-right: 3% !important;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

.custom-navbar-ext {
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  background-color: rgba(33, 37, 41, 0.9);
  background-image: var(--bs-gradient-inv);
}

.custom-navbar .navbar-brand, .custom-navbar .nav-link, .custom-navbar .btn {
  opacity: 1;
  background-color: transparent !important;
}

/* Navigation icon states */

.nav-link.active img.active-icon.d-md-inline-block {
  display: inline-block !important;
}

.nav-link img.default-icon.d-md-inline-block {
  display: inline-block !important;
}

.nav-link.active img.default-icon {
  display: none !important;
}

.nav-link img.active-icon {
  display: none !important;
}

.nav-link img.d-none {
  display: none !important;
}

.nav-link:not(.active):hover img.default-icon {
  display: none !important;
}

.nav-link:not(.active):hover img.active-icon {
  display: inline-block !important;
}

.portfolio-item {
  padding: 1.25rem;
}

.navbar-nav {
  flex-direction: row;
}

.nav-item span {
  display: flex;
  border: 1px outset var(--bs-body-bg);
  text-align: center;
  font-family: 'ADLaM Display', serif;
  font-size: 14px;
  color: var(--bs-body-bg);
  background-color: #091512;
}

.nav-item {
  text-align: center;
  margin-left: 0.25rem !important;
  margin-right: 0.25rem !important;
}

.help-icon {
  display: inline-block;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background-color: #6c757d;
  color: white;
  text-align: center;
  font-size: 12px;
  line-height: 18px;
  cursor: help;
  margin-left: 8px;
}

.help-icon:hover {
  background-color: #495057;
}

.image-container {
  position: relative;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.image-container .bg {
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

.image-container .g40overlay {
  position: absolute;
  top: 28%;
  left: 23%;
  width: 28%;
  height: auto;
  max-width: 240px;
  min-width: 90px;
  pointer-events: none;
  transform: translate(-50%, -50%);
}

.image-container .e85overlay {
  position: absolute;
  top: 68%;
  left: 74%;
  width: 35%;
  height: auto;
  max-width: 240px;
  min-width: 90px;
  pointer-events: none;
  transform: translate(-50%, -50%);
}

.main-product-image {
  border: 2px solid #dee2e6;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.main-product-image:hover {
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

/* FIXED: New class for product layer images to prevent border inheritance */

.product-layer-image {
  border: none !important;
  border-radius: 8px;
}

.map-container {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
}

.map-container iframe {
  width: 100%;
  height: 350px;
  border: 0;
  border-radius: 10px;
}

.thumbnail {
  height: 80px;
  object-fit: scale-down;
  cursor: pointer;
  transition: all 0.3s ease;
  opacity: 0.8;
}

.thumbnail:hover {
  opacity: 1;
  border-color: #007bff;
  transform: scale(1.05);
}

.thumbnail.active {
  opacity: 1;
  border-color: #007bff;
  box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

.gallery-nav {
  cursor: pointer;
  user-select: none;
  display: inline-block;
  transition: opacity 0.2s;
}

.gallery-nav:hover {
  opacity: 0.7;
}

.social {
  text-align: center;
}

/* Newsarticle Formatting */

.float-image {
  width: 34%;
  max-width: 100%;
  height: auto;
  float: left;
  margin: 0 1rem .8rem 0;
  shape-outside: inset(0 round 8px);
  clip-path: inset(0 round 8px);
  border-radius: 8px;
}

.float-image.right {
  float: right;
  margin: 0 0 .8rem 1rem;
  shape-outside: inset(0 round 8px);
  clip-path: inset(0 round 8px);
  border-radius: 8px;
}

.about-section::after {
  content: "";
  display: block;
  clear: both;
}

.cutout {
  shape-outside: polygon();
  clip-path: polygon();
}

/* end of Newsarticle Formatting */

.team-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
  padding: 2rem 1rem;
  justify-items: center;
}

.teamcard {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  padding: 1.5rem;
  text-align: center;
  max-width: 320px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.teamcard:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.teamcard img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 1rem;
}

.teamcard h3 {
  margin: 0.5rem 0 0.25rem;
  font-size: 1.2rem;
}

.teamcard p {
  color: #666;
  font-size: 0.95rem;
}

.card-body p {
  display: none;
}

.bio card {
  width: min-content;
}

/* Apply to all card rows */

.row:has(.card) > .col {
  display: flex;
}

.row:has(.card) .col > a, .row .col > .card {
  display: flex;
  flex: 1;
  width: 100%;
}

.row .card {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.row .card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

/* If you have lists in cards, push them to bottom */

.row .card-body ul {
  margin-top: auto;
}

.hover-lift {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

/* Breadcrumb styling */

.breadcrumb-item + .breadcrumb-item::before {
  color: #b1f5af;
}

.breadcrumb-item.active {
  color: #f0fff0;
}

.breadcrumb-item a {
  color: #b1f5af;
  text-decoration: none;
}

.breadcrumb-item a:hover {
  color: #a59a94;
  text-decoration: underline;
}

.bs-icon {
  --bs-icon-size: .75rem;
  display: flex;
  flex-shrink: 0;
  justify-content: center;
  align-items: center;
  font-size: var(--bs-icon-size);
  width: calc(var(--bs-icon-size) * 2);
  height: calc(var(--bs-icon-size) * 2);
  color: var(--bs-primary);
}

.bs-icon-xs {
  --bs-icon-size: 1rem;
  width: calc(var(--bs-icon-size) * 1.5);
  height: calc(var(--bs-icon-size) * 1.5);
}

.bs-icon-sm {
  --bs-icon-size: 1rem;
}

.bs-icon-md {
  --bs-icon-size: 1.5rem;
}

.bs-icon-lg {
  --bs-icon-size: 2rem;
}

.bs-icon-xl {
  --bs-icon-size: 2.5rem;
}

.bs-icon.bs-icon-primary {
  color: var(--bs-white);
  background: var(--bs-primary);
}

.bs-icon.bs-icon-primary-light {
  color: var(--bs-primary);
  background: rgba(var(--bs-primary-rgb), .2);
}

.bs-icon.bs-icon-semi-white {
  color: var(--bs-primary);
  background: rgba(255, 255, 255, .5);
}

.bs-icon.bs-icon-rounded {
  border-radius: .5rem;
}

.bs-icon.bs-icon-circle {
  border-radius: 50%;
}

.col > a {
  text-decoration: none;
}

/* Product Page styling */

.main-product-image-container {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.main-product-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.svg-arrow {
  position: absolute;
  top: 85%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  cursor: pointer;
  z-index: 5;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
  filter: drop-shadow(1px 1px 2px rgba(42, 49, 16, 0.5));
}

.svg-arrow.visible {
  opacity: 0.5;
  visibility: visible;
}

.svg-arrow.visible:hover {
  opacity: .8;
}

.svg-arrow:hover {
  opacity: .8;
}

.svg-arrow-prev {
  left: 4%;
}

.svg-arrow-next {
  right: 4%;
}

.svg-arrow path {
  fill: white;
}

.description-excerpt p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 7;
  overflow: hidden;
  position: relative;
  margin-bottom: 0.5rem;
  z-index: 1;
}

.description-excerpt {
  position: relative;
}

.fade-overlay {
  position: absolute;
  top: 8em;
  height: 2em;
  background: linear-gradient( rgba(255,255,255,0), rgba(255,255,255,1) );
  pointer-events: none;
  z-index: 2;
}

.description-full {
  display: none;
}

.toggle-text {
  position: relative;
  font-size: 0.9rem;
  color: var(--bs-link-color);
  cursor: pointer;
  z-index: 3;
}

.options-group {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 100%;
  margin-bottom: 1rem;
}

.options-label {
  flex-shrink: 0;
  white-space: nowrap;
}

.options-options {
  display: flex;
  gap: 1rem;
  flex: 1 1 auto;
  min-width: 0;
  flex-wrap: wrap;
}

.options-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
  line-height: 1;
}

.options-item input[type="radio"] {
  margin: 0;
}

.options-item {
  position: relative;
}

.options-item:hover .options-name {
  opacity: 1;
  transform: translateX(-50%) translateY(-4px);
}

/* FIXED: Added styling for hose length radio buttons to show active state */

#hoseSelect input[type="radio"] {
  position: static;
  opacity: 1;
  pointer-events: auto;
  accent-color: #0d6efd;
  cursor: pointer;
}

#hoseSelect .options-item {
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  transition: background-color 0.15s ease;
}

#hoseSelect .options-item.active {
  background-color: rgba(13, 110, 253, 0.1);
}

#hoseSelect .options-item:hover {
  background-color: rgba(13, 110, 253, 0.05);
}

#colorSelect input[type="radio"], #wheelSelect input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.options-item:hover .swatches {
  transform: scale(1.1);
}

.options-item input[type="radio"]:checked + .swatches {
  border-color: #0d6efd;
  box-shadow: 0 0 0 2px rgba(13, 110, 253, 0.35);
}

.options-name {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  opacity: 0;
  pointer-events: none;
  background: #000;
  color: #fff;
  font-size: 0.7rem;
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.options-item.swatches.wheel img {
  width: 48px;
  height: auto;
  border-radius: 4px;
  border: 2px solid transparent;
}

.options-item.active img, .options-item:hover img {
  border-color: #0d6efd;
}

.options-item.swatches.wheel.active img, .options-item.swatches.wheel:has(input[type="radio"]:checked) img {
  transform: scale(1.1);
  filter: drop-shadow(0 0 4px rgba(13, 110, 253, 0.95));
}

.swatches {
  width: 26px;
  height: 26px;
  border-radius: 4px;
  border: 2px solid transparent;
  cursor: pointer;
  box-sizing: border-box;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.swatches.blue {
  background: #2b6b7f;
}

.swatches.black {
  background: #111;
}

.swatches.red {
  background: #8c1d18;
}

.swatches.white {
  background: #f5f5f5;
  border-color: #ccc;
}

.swatches.green {
  background: #2f6f3e;
}

.swatches.yellow {
  background: #e2b400;
}

.swatches.custom {
  background: repeating-linear-gradient( 45deg, #ca0a0a, #afc207 5px, #087924 5px, #130b86 10px );
  color: #333;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
}

.color-disclaimer {
  display: none;
  opacity: 0.7;
  font-size: 10px;
}

body.custom-color-active .color-disclaimer {
  display: inline-block;
}

.image-disclaimer {
  position: absolute;
  bottom: 8px;
  right: 10px;
  color: #000;
  padding: 4px 6px;
  pointer-events: none;
}

/* end of Product Page styling */

#brandSrch {
  flex: 1 1 auto;
  max-width: 100%;
  padding-right: 0.5rem;
  overflow: hidden;
}

#navButt {
  flex: 0 0 auto;
  /*padding-left: 0.5rem;*/
  display: flex;
  /*align-items: center;*/
  justify-content: flex-start;
}

#defaultView .col {
  display: flex;
}

#defaultView .col > a {
  display: flex;
  flex: 1;
  width: 100%;
  text-decoration: none;
}

#defaultView .card {
  display: flex;
  flex-direction: column;
  flex: 1;
  height: 100%;
}

#defaultView .card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

#defaultView .card img {
  width: 100%;
  height: 120px;
  object-fit: contain;
  object-position: center;
}

#searchInput {
  min-width: 40px;
  transition: min-width 0.3s ease;
  transform-origin: right;
}

#searchInput:focus {
  min-width: 120px;
}

/* --- SNOW CAROUSEL FIX --- */

#snowCarousel {
  position: relative;
  overflow: hidden;
}

/* Set a consistent slide height */

#snowCarousel .carousel-item {
  height: 32vh;
  position: relative;
}

#snowCarousel .carousel-item > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;
}

#snowCarousel .container {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

#swiper-1 .swiper-slide {
  height: 100% !important;
}

/* Make sure images fill the slide */

#swiper-1 .swiper-slide img {
  height: 100% !important;
  object-fit: cover;
}

