/* ==========================================
   BENTO GRID / WHY US SECTION STYLESHEET
   ========================================== */

.why-us-section {
  display: block;
  padding: 3rem 3.5rem 1.5rem;
  margin: 0 auto;
  width: 100%;
  max-width: 1500px;
  box-sizing: border-box;
}

.section-header-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 2.5rem;
}

.tag-pill {
  background-color: #f2ead8;
  color: #986a3e;
  padding: 0.35rem 0.85rem;
  border-radius: 2rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  word-wrap: break-word;
}

.serif-title.large {
  font-size: 2.6rem;
  line-height: 1.15;
  color: #633b2c;
  font-weight: 500;
  margin-bottom: 0;
}

/* Main Grid Container */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
  height: 560px;
  max-height: 600px;
  min-height: 480px;
}

/* Grid Columns */
.bento-col {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  height: 100%;
  min-height: 0;
  min-width: 0;
}

/* General Bento Card */
.bento-card {
  border-radius: 1.5rem;
  overflow: hidden;
  position: relative;
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  background-color: #f2ead8;
  box-sizing: border-box;
  min-height: 0;
}

.bento-card.bg-light {
  background-color: #f2ead8;
}

.bento-card.has-bg-img {
  background-size: cover;
  background-position: center;
  color: #fff;
  padding: 0;
}

/* ==========================================
   COLUMN 1 FLEX SIZES & CARDS
   ========================================== */
.bento-col:nth-child(1) .bento-card:nth-child(1) {
  flex: 5.8;
  min-height: 280px;
}

.bento-col:nth-child(1) .bento-card:nth-child(2) {
  flex: 4.2;
  min-height: 180px;
}

/* Before / After Slider Card */
.ba-slider {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.ba-slider img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ba-img-after {
  z-index: 1;
}

.ba-img-before {
  z-index: 2;
  clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%);
}

.ba-slider input[type="range"] {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 3;
  opacity: 0;
  cursor: ew-resize;
}

.slider-handle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 36px;
  height: 36px;
  background: #fff;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 4;
  pointer-events: none;
  color: #633b2c;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.card-badges-top {
  position: absolute;
  top: 1rem;
  left: 1rem;
  right: 1rem;
  display: flex;
  justify-content: space-between;
  z-index: 5;
  pointer-events: none;
}

.card-badges-top .badge {
  background: rgba(255, 255, 255, 0.88);
  color: #1a1a1a;
  padding: 0.35rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.card-content-bottom.dark-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(to top, rgba(99, 59, 44, 0.92), transparent 85%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 50%;
  z-index: 5;
  pointer-events: none;
  box-sizing: border-box;
}

.dark-overlay h3 {
  font-size: 1.3rem;
  font-weight: 500;
  margin: 0 0 0.35rem 0;
  color: #fff;
}

.card-meta {
  display: flex;
  gap: 1.25rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.95);
}

.card-meta span {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* Bespoke CTA Card */
.icon-circle-badge {
  width: 44px;
  height: 44px;
  background: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  color: #1a1a1a;
  margin-bottom: 0.5rem;
  border: 1.5px dashed #ca8f3e;
}

.flex-col-center {
  align-items: center;
  text-align: center;
  justify-content: center;
}

/* ==========================================
   COLUMN 2 FLEX SIZES & CARDS
   ========================================== */
.bento-col:nth-child(2) .bento-card {
  flex: 1;
  min-height: 140px;
}

/* Location Card (Side-by-side flex, ZERO overlap possible) */
.location-card {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 1.25rem !important;
  gap: 1rem !important;
  overflow: hidden;
  position: relative;
}

.location-text {
  flex: 1;
  min-width: 0;
  z-index: 2;
}

.location-text .sub-title {
  font-size: 0.75rem;
  color: #986a3e;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}

.location-text h3 {
  font-size: 1.25rem;
  color: #633b2c;
  line-height: 1.25;
  margin: 0;
}

.location-img-wrap {
  width: 44%;
  height: 100%;
  min-height: 90px;
  border-radius: 1.25rem;
  overflow: hidden;
  flex-shrink: 0;
}

.location-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Technology Marquee Card */
.tech-card {
  padding: 1.25rem !important;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.tech-card h3 {
  font-size: 1.25rem;
  color: #633b2c;
  margin: 0 0 0.15rem 0;
  line-height: 1.2;
}

.tech-card p {
  color: #6b5d53;
  font-size: 0.75rem;
  margin: 0;
}

.tech-card .marquee-container {
  height: 55px;
  margin-top: 0.35rem;
  overflow: hidden;
}

.tech-card .marquee-track img {
  width: 55px;
  height: 55px;
  object-fit: cover;
  border-radius: 0.65rem;
}

/* Marquee Track */
.marquee-container {
  overflow: hidden;
  position: relative;
  width: 100%;
  flex: 1;
  display: flex;
  align-items: center;
  margin-top: 0.5rem;
}

.marquee-track {
  display: flex;
  gap: 0.75rem;
  width: fit-content;
  animation: scroll-left 15s linear infinite;
}

.marquee-track img {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: 0.85rem;
}

@keyframes scroll-left {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-50% - 0.375rem));
  }
}

/* Video Box */
.video-box {
  padding: 0;
  position: relative;
}

.video-box video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
}

/* ==========================================
   COLUMN 3 FLEX SIZES & CARDS
   ========================================== */
.bento-col:nth-child(3) .bento-card:nth-child(1) {
  flex: 4;
  min-height: 140px;
}

.bento-col:nth-child(3) .bento-card:nth-child(2) {
  flex: 6;
  min-height: 280px;
}

.serif-title.huge {
  font-size: 1.5rem;
  line-height: 1;
  margin-bottom: 0.2rem;
  color: #633b2c;
}

.stats-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.stats-pills .pill {
  background: #fff;
  padding: 0.35rem 0.85rem;
  border-radius: 2rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #633b2c;
  width: fit-content;
}

.rating-stars-center {
  display: flex;
  justify-content: center;
  gap: 0.2rem;
  color: #ca8f3e;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

/* Vertical Testimonials Marquee */
.vertical-marquee-container {
  overflow: hidden;
  position: relative;
  width: 100%;
  height: 100%;
  margin-top: 0.75rem;
  mask-image: linear-gradient(
    to bottom,
    transparent,
    black 10%,
    black 90%,
    transparent
  );
  -webkit-mask-image: linear-gradient(
    to bottom,
    transparent,
    black 10%,
    black 90%,
    transparent
  );
}

.vertical-marquee-track {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  animation: scroll-up 20s linear infinite;
}

@keyframes scroll-up {
  0% {
    transform: translateY(0);
  }
  100% {
    transform: translateX(0) translateY(calc(-50% - 0.5rem));
  }
}

.mini-testi {
  background: #fff;
  padding: 1rem 1.25rem;
  border-radius: 1rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
}

.mini-testi p {
  font-size: 0.825rem;
  color: #4a4a4a;
  margin: 0 0 0.75rem 0;
  line-height: 1.5;
}

.mini-reviewer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mini-reviewer .info {
  display: flex;
  flex-direction: column;
}

.mini-reviewer .info strong {
  font-size: 0.85rem;
  color: #1a1a1a;
}

.mini-reviewer .info span {
  font-size: 0.75rem;
  color: #7a7a7a;
}

.mini-reviewer img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid rgba(152, 106, 62, 0.35);
  box-shadow: 0 2px 8px rgba(99, 59, 44, 0.1);
  flex-shrink: 0;
}

.mini-reviewer .avatar-wrapper {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid rgba(152, 106, 62, 0.35);
  box-shadow: 0 2px 8px rgba(99, 59, 44, 0.1);
  flex-shrink: 0;
  background-color: #f5ebe1;
}

.mini-reviewer .avatar-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
  border: none;
  box-shadow: none;
}

.mini-reviewer .avatar-wrapper img.avatar-zoom {
  transform: scale(1.55);
  transform-origin: center 25%;
}

/* ==========================================
   RESPONSIVE BREAKPOINTS
   ========================================== */

/* Laptop / Short Viewport Adjustment (e.g. 1280x585 or screens < 720px height) */
@media (max-height: 720px) {
  .why-us-section {
    padding: 1.25rem 1.5rem 1rem;
  }
  .section-header-center {
    margin-bottom: 1rem;
  }
  .serif-title.large {
    font-size: 2.6rem;
    margin-top:0rem ;
  }
  .bento-grid {
    height: 480px;
    max-height: 520px;
    gap: 1rem;
  }
}

/* Tablet & Mobile Breakpoints */
@media (max-width: 1024px) {
  .bento-grid {
    grid-template-columns: 1fr;
    height: auto;
    max-height: none;
    min-height: auto;
    gap: 1.25rem;
  }
  .bento-col {
    height: auto;
    gap: 1.25rem;
  }
  .bento-col:nth-child(1) .bento-card:nth-child(1) {
    height: 380px;
    min-height: 380px;
  }
  .bento-col:nth-child(1) .bento-card:nth-child(2) {
    height: auto;
    min-height: 200px;
  }
  .bento-col:nth-child(2) .bento-card {
    height: auto;
    min-height: 180px;
  }
  .bento-col:nth-child(3) .bento-card:nth-child(1) {
    height: auto;
    min-height: 180px;
  }
  .bento-col:nth-child(3) .bento-card:nth-child(2) {
    height: 380px;
    min-height: 380px;
  }
}
