body {
  margin: 0;
  font-family: "abc-repro", sans-serif;
  overflow-x: hidden; /* CRITICAL: Prevent horizontal scroll */
  max-width: 100%;
}

/* Ensure all sections stay within viewport */
* {
  box-sizing: border-box;
}

/* Header */
header {
  background: transparent;
  z-index: 1000;
  width: 100%;
}

/* Logo behavior */
#logo {
  transition: all 0.4s ease;
}
#logo.hidden {
  opacity: 0;
  transform: translateY(-10px);
}
#logo.small {
  transform: scale(0.95);
  opacity: 1;
}

/* Right menu background */
.menu-container {
  background-color: #F4E4C5;
}

/* Bounce animation */
@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(-5px); }
  60% { transform: translateY(-3px); }
}

/* Menu links */
.nav-link {
  color: #4b000b !important;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 6px;
  transition: 0.3s;
}
.nav-link:hover {
  color: #800020 !important;
  animation: bounce 0.6s;
}

/* Contact button */
.contact-btn {
  background-color: #800020;
  color: #f8eddc !important;
  padding: 6px 18px;
  border-radius: 6px;
  transition: 0.3s;
}
.contact-btn:hover {
  background-color: #a83246;
  animation: bounce 0.6s;
}

/* --- MOBILE MENU --- */
.navbar-toggler {
  border: none;
  background: transparent !important;
  filter: invert(25%);
}

.navbar-toggler-icon {
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath stroke='rgba(0,0,0,0.8)' stroke-width='2' stroke-linecap='round' stroke-miterlimit='10' d='M4 7h22M4 15h22M4 23h22'/%3E%3C/svg%3E");
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 75%;
  height: 100vh;
  background-color: #F4E4C5;
  transition: right 0.4s ease;
  z-index: 2000;
  padding: 2rem;
}
.mobile-menu.active {
  right: 0;
}
.mobile-menu .close-btn {
  font-size: 2rem;
  cursor: pointer;
  text-align: right;
  margin-bottom: 1.5rem;
  color: #800020;
}
.mobile-menu ul {
  list-style: none;
  padding: 0;
}
.mobile-menu ul li {
  margin-bottom: 1rem;
}
.mobile-menu ul li a {
  color: #4b000b;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
}
.mobile-menu ul li a:hover {
  color: #800020;
  animation: bounce 0.6s;
}

/*About US*/

/* SECTION TITLE */
.section-title {
  font-size: 4rem;
  font-weight: 700;
  color: #800020;
  position: relative;
  display: inline-block;
  font-family: "Awesome Serif", serif;
  transition: transform 0.3s ease-in-out;
  margin-bottom: 16px;
}

.section-title::after {
  content: "";
  width: 15px;
  height: 15px;
  background-color: #800020;
  display: inline-block;
  margin-left: 8px;
  vertical-align: middle;
}

@keyframes bounceHover {
  0% { transform: translateY(0); }
  30% { transform: translateY(-20px); }
  50% { transform: translateY(0); }
  70% { transform: translateY(-10px); }
  100% { transform: translateY(0); }
}

.section-title:hover {
  animation: bounceHover 0.8s ease-in-out;
  transform: scale(1.05);
}

/* ABOUT TEXT */
.about-text {
  max-width: 860px;
  margin: 20px auto 40px auto;
  text-align: center;
  font-family: "ABC Repro";
  font-size: 20px;
  font-weight: 400;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.3s, transform 0.3s;
  padding: 0 20px;
}

/* ABOUT IMAGE */
.about-image {
  overflow: hidden;
  border-radius: 12px;
  transform-origin: center center;
  transform: scale(1);
  transition: transform 0.3s, opacity 0.3s;
  margin-top: 60px;
}

.about-image img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
}

/* SECTION BASE */
section#about-section {
  position: relative;
  overflow: hidden;
  /*min-height: 100vh;*/
  padding-bottom: 40px;
}

/* RESPONSIVE FIXES */
@media (max-width: 768px) {
  .section-title {
    font-size: 2.2rem;
    margin-bottom: 10px;
  }

  .about-text {
    font-size: 16px;
    padding: 0 18px;
  }

  .about-image {
    margin-top: 40px;
    padding: 0 18px;
  }
}

/*What We do*/

.whatwedo-section {
  padding: 60px 0;
  overflow: hidden; /* CRITICAL FIX */
}

.section2-title {
  font-size: 3.8rem;
  font-weight: 700;
  color: #800020;
  display: inline-block;
  position: relative;
  margin-bottom: 2rem;
  font-family: "Awesome Serif", serif;
  transition: transform 0.3s ease-in-out;
}

.section2-title::after {
  content: "";
  width: 15px;
  height: 15px;
  background-color: #800020;
  display: inline-block;
  margin-left: 8px;
  vertical-align: middle;
  font-family: "Awesome Serif", serif;
}

.section2-title:hover {
  animation: bounceHover 0.8s ease-in-out;
  transform: scale(1.05);
}

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.9s ease, transform 0.9s ease;
  will-change: transform, opacity;
}

.reveal.slide-left {
  transform: translateX(-100px);
}
.reveal.slide-right {
  transform: translateX(100px);
}

.reveal.active {
  opacity: 1 !important;
  transform: translate(0, 0) !important;
}

.reveal.slide-right.active {
  opacity: 1 !important;
  transform: none !important;
}

.reveal.permanent {
  opacity: 1 !important;
  transform: none !important;
}

.reveal.slide-left.active,
.reveal.slide-right.active {
  transform: translate(0, 0);
}

.whatwedo-section img {
  border-radius: 10px;
  width: 100%;
  height: 450px;
  object-fit: cover;
}

.whatwedo-section p {
  font-family: "ABC Repro";
  max-width: 860px;
  font-size: 18px;
  font-weight: 400;
}

@media (max-width: 767.98px) {

  .whatwedo-section .container {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }

   .section2-title {
    font-size: 2.2rem !important;
  }

  .whatwedo-text {
    font-size: 16px !important;
    line-height: 1.5;
  }
  
  .whatwedo-section .row {
    flex-direction: column;
  }

  .whatwedo-section .row > .col-md-6 {
    display: flex;
    flex-direction: column;
  }

  .whatwedo-section .row > .col-md-6:first-child img {
    order: 1;
  }
  .whatwedo-section .row > .col-md-6:first-child .whatwedo-text {
    order: 2;
  }

  .whatwedo-section .row > .col-md-6:last-child img {
    order: 1;
  }
  .whatwedo-section .row > .col-md-6:last-child .whatwedo-text {
    order: 2;
  }

  .whatwedo-section img {
    height: auto;
    margin-bottom: 12px;
    border-radius: 10px;
  }

  .whatwedo-text {
    font-size: 16px;
    text-align: justify;
    margin-bottom: 20px;
  }
}

/*Our Values*/

.values-section {
  overflow: hidden; /* CRITICAL FIX */
  width: 100%;
  padding-top: 5px !important;
    padding-bottom: 40px !important;
  
}

.section3-title {
  font-size: 3.8rem;
  font-weight: 700;
  padding-right: 120px;
  color: #800020;
  display: inline-block;
  position: relative;
  margin-bottom: 40px;
  width: 100%;
  font-family: "Awesome Serif", serif;
  text-align: right;
}

.section3-title::after {
  content: "";
  width: 15px;
  height: 15px;
  background-color: #800020;
  display: inline-block;
  margin-left: 8px;
  vertical-align: middle;
  font-family: "Awesome Serif", serif;
}

.section3-title:hover {
  animation: bounceHover 0.8s ease-in-out;
  transform: scale(1.05);
}

.card-wrapper {
  width: 100%;
  max-width: 100%;
  padding: 0;
  overflow: hidden;
}

.card-container {
  width: 100%; /* CRITICAL FIX: Changed from 100vw */
  max-width: 100%; /* CRITICAL FIX */
  height: 282px;
  border-top: 1px solid rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  background-color: #f8eddc;
  box-sizing: border-box;
  padding: 0 120px;
  transition: all 0.5s ease;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  margin: 0; /* CRITICAL FIX */
}

.card-container:last-child {
  border-bottom: 1px solid rgba(0, 0, 0, 0.2);
}

.card-left {
  display: flex;
  align-items: flex-start;
  gap: 60px;
  transition: all 0.5s ease;
}

.card-number {
  font-family: "Awesome Serif", serif;
  font-size: 24px;
  color: #800020;
  font-weight: 600;
}

.card-image {
  width: 182px;
  height: 161px;
  object-fit: cover;
  transition: all 0.5s ease;
}

.card-content {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 133px;
  margin-left: 209px;
  flex: 1;
  transition: all 0.5s ease;
}

.card-text {
  display: flex;
  flex-direction: column;
  transition: all 0.5s ease;
}

.card-title {
  font-family: "Awesome Serif", serif;
  font-size: 32px;
  font-weight: 700;
  color: #800020;
  margin-bottom: 8px;
}

.card-subtitle {
  font-family: "ABC Repro";
  font-size: 16px;
  color: #333;
  max-width: 480px;
}

.card-description {
  display: none;
  font-family: "ABC Repro";
  font-size: 18px;
  color: #333;
  margin-top: 35px;
  max-width: 700px;
  line-height: 1.4;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.card-icon {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #800020;
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.card-container.expanded {
  height: 507px;
  padding-top: 25px;
  padding-bottom: 25px;
}

.card-container.expanded .card-image {
  width: 340px;
  height: 315px;
}

.card-container.expanded .card-description {
  display: block;
  opacity: 1;
}

.card-container.expanded .card-content {
  align-items: flex-start;
}

@media (max-width: 991px) {
  .section3-title {
    font-size: 2.5rem;
    padding-right: 20px;
    text-align: center;
  }

  .card-wrapper {
    padding: 0;
    width: 100%;
  }

  .card-container {
    width: 100%;
    height: auto;
    flex-direction: column;
    align-items: flex-start;
    padding: 25px 20px;
    margin: 0;
  }

  .card-left {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }

  .card-number {
    font-size: 22px;
  }

  .card-image {
    width: 100%;
    max-width: 320px;
    height: auto;
  }

  .card-content {
    margin-left: 0;
    margin-top: 25px;
    flex-direction: column;
    gap: 25px;
    width: 100%;
  }

  .card-text {
    width: 100%;
  }

  .card-title {
    font-size: 26px;
  }

  .card-subtitle {
    font-size: 17px;
    max-width: 100%;
  }

  .card-description {
    font-size: 18px;
    margin-top: 20px;
    max-width: 100%;
  }

  .card-icon {
    align-self: flex-end;
    margin-top: 10px;
  }

  .card-container.expanded .card-image {
    width: 100%;
    max-width: 100%;
    height: auto;
  }

  .card-container.expanded {
    height: auto;
  }
}

/*Footer*/
body {
  background-color: #f8eddc;
  font-family: 'ABC Repro', sans-serif !important;
  color: #3a2a2a;
}

.footer-section {
  background-color: #f8eddc;
  width: 100%;
  overflow: hidden;
}

.footer-line {
  width: 60%;
  border-top: 1px solid #3a2a2a;
  opacity: 0.6;
  margin-top: 15px;
}

.footer-quote {
  font-family: 'Awesome Serif', serif;
  font-size: 1.6rem;
  color: #8b0000;
  line-height: 1.6;
  opacity: 0;
  max-width: 750px;
  margin: 0 auto;
  text-align: center;
  transition: opacity 0.5s ease-in-out;
  white-space: normal;
}

.footer-link {
  color: #3a2a2a;
  text-decoration: none;
  display: inline-block;
  transition: all 0.3s ease;
  font-family: 'ABC Repro', sans-serif;
}

.footer-link:hover {
  color: #a10000;
  transform: translateY(-2px);
}

.btn-danger {
  background-color: #a10000;
  border: none;
  transition: 0.3s ease;
}

.btn-danger:hover {
  background-color: #7a0000;
}

.footer-section .row {
  text-align: center;
}

.footer-section .row > .col-lg-4 {
  text-align: left;
}

.footer-section h5 {
  font-family: 'Awesome Serif', serif;
  font-weight: 600;
  color: #8b0000;
  letter-spacing: 0.5px;
}

@media (min-width: 768px) {
  .footer-section .row .col-lg-3,
  .footer-section .row .col-lg-4 {
    text-align: left !important; /* desktop */
  }
}

@media (max-width: 768px) {
  .footer-section {
    text-align: center;
    padding: 50px 25px;
  }

  .footer-quote {
    font-size: 1.25rem;
    margin: 30px 10px;
    max-width: 90%;
  }

  .footer-section .row > .col-lg-4 {
    text-align: center;
  }

  .footer-line {
    width: 85%;
  }
}