/* 
   Franklin Engineering Ltd. Landing Page
   Created: 2025-05-26
   Custom CSS with Tailwind-inspired utility classes for Elementor
*/

/* Variables & Base Styles */
:root {
    --navy: #0d1a41;
    --navy-light: #1e2b52;
    --navy-dark: #06102a;
    --gold: #d1962a;
    --gold-light: #e5b04c;
    --gold-dark: #b37d1b;
    --gradient-grey: #b1b3b6;
    --lightest-grey: #cdcfd0;
    --darkest-grey: #97999c;
    --grey-medium: #a5a7aa;
    --white: #ffffff;
    --off-white: #f8f9fa;
    --black: #000000;
    --text-primary: #2c2c2c;
    --text-secondary: #5c5c5c;
    --text-light: #ffffff;
    
    --transition-fast: 0.2s ease;
    --transition-medium: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    --border-radius-sm: 4px;
    --border-radius-md: 6px;
    --border-radius-lg: 8px;
    
    --box-shadow-sm: 0 2px 5px rgba(0, 0, 0, 0.08);
    --box-shadow-md: 0 4px 10px rgba(0, 0, 0, 0.1);
    --box-shadow-lg: 0 6px 20px rgba(0, 0, 0, 0.15);
    
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--text-primary);
    line-height: 1.6;
    background-color: var(--white);
    overflow-x: hidden; /* Combined height of top contact bar (~48px) + header (~90px) */
    transition: padding-top var(--transition-medium);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: var(--navy);
    transition: color var(--transition-medium);
}

a:hover {
    color: var(--gold);
}

ul, ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* Blueprint Grid Background */
.blueprint-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--navy);
    background-image: url('https://placehold.co/200x200?text=Blueprint+Grid');
    background-size: 40px 40px;
    opacity: 0.15;
    z-index: -1;
}

/* Hero section background overlay */
.hero-section .blueprint-overlay {
    background-image: url('/assets/img/hero-bg.webp');
    background-size: cover;
    background-position: center;
    opacity: 0.8;
}

/* Dark overlay for readability */
.dark-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(rgba(13, 26, 65, 0.3), rgba(13, 26, 65, 0.7));
    z-index: -1;
}

.blueprint-overlay.light {
    background-color: var(--lightest-grey);
    opacity: 0.25;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.3;
    color: var(--navy);
    margin-bottom: 0.75rem;
}

h1 {
    font-size: 3.5rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.75rem;
}

h4 {
    font-size: 1.25rem;
}

p {
    margin-bottom: 1.25rem;
}

.text-center {
    text-align: center;
}


/* Update existing font declarations to use custom fonts as primary */
h1, h2, h3 {
    font-family: 'Montserrat', sans-serif;
}

h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

/* Specific overrides for brand consistency */
.hero-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: normal;
}

.hero-subtitle {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

.section-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: normal;
}

.tab-btn, .filter-btn {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

.stat-number {
    font-family: 'Montserrat', sans-serif;
    font-weight: normal;
}

.stat-label {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

.philosophy-quote p {
    font-family: 'Montserrat', sans-serif;
    font-weight: normal;
}

.quote-author {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

/* Button font consistency */
.btn {
    font-family: 'Open Sans', sans-serif;
    letter-spacing: 0.02em;
}

/* Navigation and footer headings */
.footer-heading {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

/* Form headers */
.form-header h3 {
    font-family: 'Montserrat', sans-serif;
    font-weight: normal;
}

/* Contact info headings */
.info-content h4 {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

/* Feature content headings */
.feature-content h4 {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

/* Project and testimonial titles */
.project-title {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

.testimonial-author h4 {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
}

/* Tab titles */
.tab-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: normal;
}

/* CTA section */
.cta-content h2 {
    font-family: 'Montserrat', sans-serif;
    font-weight: normal;
}

/* Container */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
    position: relative;
}

/* Section Styles */
section {
    padding: 5rem 0;
    position: relative;
}

.section-heading {
    margin-bottom: 3rem;
    position: relative;
}

.section-heading.center {
    text-align: center;
}

.section-tag {
    display: inline-block;
    color: var(--gold);
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1rem;
}

.section-title {
    margin-bottom: 1.25rem;
    position: relative;
}

.section-line {
    display: block;
    width: 80px;
    height: 3px;
    background: var(--gold);
    margin-bottom: 2rem;
}

.section-heading.center .section-line {
    margin: 0 auto 2rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 600;
    padding: 0.9rem 2rem;
    border-radius: var(--border-radius-md);
    transition: all var(--transition-medium);
    cursor: pointer;
    border: none;
    text-align: center;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-size: 0.9rem;
}

.btn-primary {
    background-color: var(--gold);
    color: var(--text-primary);
    box-shadow: var(--box-shadow-sm);
}

.btn-primary:hover {
    background-color: var(--gold-light);
    color: var(--text-primary);
    transform: translateY(-2px);
    box-shadow: var(--box-shadow-md);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-light);
    border: 2px solid var(--gold);
}

.btn-outline:hover {
    background-color: var(--gold);
    color: var(--text-primary);
    transform: translateY(-2px);
    box-shadow: var(--box-shadow-sm);
}

.btn-text {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--gold);
    display: inline-flex;
    align-items: center;
    padding: 0;
    background: transparent;
    border: none;
}

.btn-arrow {
    display: inline-block;
    margin-left: 0.35rem;
    transition: transform var(--transition-fast);
}

.btn-text:hover .btn-arrow {
    transform: translateX(4px);
}

.btn-sm {
    padding: 0.5rem 1.25rem;
    font-size: 0.8rem;
}

/* Header Wrapper - Contains both top contact bar and main header */
.header-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: all var(--transition-medium);
}

/* Header */
.header {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    transition: all var(--transition-medium);
    box-shadow: 0 1px 5px rgba(0,0,0,0.05);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 90px;
    transition: height var(--transition-medium);
}

.logo-wrapper {
    flex-shrink: 0;
}

.logo {
    height: 62px;
    transition: height var(--transition-medium);
}

/* Larger, more evident logo on desktop headers; sized to stay inside the
   90px header bar (no overlap into the content below). Mobile keeps the
   smaller base size to fit its shorter header. */
@media (min-width: 769px) {
    .logo {
        height: 68px;
    }
}

.main-nav {
    margin-left: auto;
    margin-right: 2rem;
}

.nav-list {
    display: flex;
    gap: 1.25rem;
}

.nav-item {
    position: relative;
}

.nav-link {
    font-family: var(--font-heading);
    font-weight: 500;
    padding: 0.5rem 0.25rem;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    color: var(--navy);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--gold);
    transform: scaleX(0);
    transition: transform var(--transition-medium);
    transform-origin: bottom right;
}

.nav-link:hover::after,
.nav-link.active::after {
    transform: scaleX(1);
    transform-origin: bottom left;
}

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-content {
    position: absolute;
    top: 100%;
    left: -1rem;
    width: 250px;
    background-color: var(--white);
    box-shadow: var(--box-shadow-md);
    border-radius: var(--border-radius-md);
    padding: 0.75rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all var(--transition-medium);
    z-index: 100;
    margin-top: 5px;
}

.dropdown:hover .dropdown-content {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-content a {
    display: block;
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    color: var(--text-primary);
    transition: all var(--transition-fast);
}

.dropdown-content a:hover {
    background-color: var(--lightest-grey);
    color: var(--gold);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    cursor: pointer;
}

.mobile-menu-toggle span {
    display: block;
    height: 2px;
    background-color: var(--navy);
    transition: all var(--transition-medium);
}

/* Mobile Navigation */
.mobile-nav {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    height: calc(100vh - 80px);
    background-color: white;
    padding: 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateX(-100%);
    transition: transform var(--transition-medium);
    z-index: 1000;
    overflow-y: auto;
}

.mobile-nav.active {
    transform: translateX(0);
}

.mobile-nav .nav-list {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.mobile-nav .nav-item {
    margin: 0;
    width: 100%;
    border-bottom: 1px solid var(--light-grey);
}

.mobile-nav .nav-link {
    padding: 1rem 0;
    font-size: 1.2rem;
    display: block;
}

.mobile-nav .dropdown-content {
    position: relative;
    box-shadow: none;
    margin-left: 1rem;
    display: none;
    opacity: 1;
    transform: none;
    padding: 0.5rem 0;
}

.mobile-nav .nav-item.dropdown:hover .dropdown-content {
    display: block;
}

.mobile-nav .dropdown-content a {
    padding: 0.5rem 1rem;
}

/* Mobile Nav Button Styling */
.mobile-nav .btn-primary {
    margin-top: 1.5rem;
    width: 100%;
    text-align: center;
    display: none; /* Hide by default */
}

@media (max-width: 768px) {
    /* Adjust button visibility for mobile */
    .header-cta .btn-primary {
        display: none; /* Hide the Request Quote button on mobile */
    }
    
    .mobile-menu-toggle {
        margin-left: 0; /* Remove left margin from hamburger menu */
    }

    .header-cta {
        display: flex;
        align-items: center;
    }

    /* Display the Request Quote button inside the mobile nav */
    .mobile-nav .nav-list {
        margin-bottom: 2rem;
    }

    .mobile-nav .btn-primary {
        display: block; /* Show the Request Quote button */
    }
}

body.menu-open {
    overflow: hidden; /* Prevent scrolling when menu is open */
}

/* Mobile Menu Icon Animation (Hamburger to X) */
.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile Menu Display Fix */
.mobile-nav {
    display: block; /* Ensure it's displayed */
    z-index: 999; /* Ensure it's above other elements */
}
/* Mobile Menu Nav ends */

/* Top Contact Bar */
.top-contact-bar {
  background-color: var(--gold);
  color: var(--navy);
  padding: 0.75rem 0;
  font-size: 0.9rem;
  position: relative;
  z-index: 1002;
  transition: all 0.3s ease;
}

.top-contact-info {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--navy);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.contact-item:hover {
  color: var(--navy-dark);
}

.contact-item i {
  font-size: 1.1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
  .top-contact-info {
    gap: 1rem;
    justify-content: space-around;
  }
  
  .contact-item {
    font-size: 0.85rem;
  }
  
  body {
    padding-top: 125px; /* Smaller combined height for tablets */
  }
}

@media (max-width: 576px) {
  .top-contact-bar {
    padding: 0.5rem 0;
    display: none;
  }
  
  .top-contact-info {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .contact-item {
    font-size: 0.8rem;
  }
  
  body {
    padding-top: 90px; /* Reduced since top-contact-bar is hidden */
  }
}

/* Top Contact Bar ends */

/* Hero Section */
.hero-section {
  height: 100vh;
  min-height: 700px;
  display: flex;
  align-items: center;
  position: relative;
  overflow: visible; /* Ensure scroll indicator is not hidden */
  padding: 0;
  background-color: var(--navy);
  color: var(--text-light);
}

/* Dedicated, clipped layer for the slow background zoom (kept separate from
   .hero-section so overflow:visible above is untouched — that's needed for
   the scroll indicator). */
.hero-bg-zoom {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}

.hero-bg-zoom::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('/assets/img/hero-bg.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  animation: heroBgZoom 24s ease-in-out infinite alternate;
  will-change: transform;
}

@keyframes heroBgZoom {
  from { transform: scale(1); }
  to { transform: scale(1.12); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-bg-zoom::before {
    animation: none;
  }
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to right, rgba(13, 26, 65, 0.85) 0%, rgba(13, 26, 65, 0.6) 50%, rgba(13, 26, 65, 0.2) 100%);
  z-index: 1;
}

.hero-container {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  max-width: 1400px;
  height: 100%;
  position: relative;
  z-index: 2;
  padding-bottom: 1rem; /* Ensure space for scroll indicator */
  padding-left: 5%; /* Add left padding for breathing room */
}

/* Desktop: the header is fixed and overlays the hero, so reserve its height
   (top bar ~48px + header 90px) plus breathing room, keeping the card clear
   of the navbar and above the scroll indicator. Mobile/tablet already offset
   the page via body padding-top. */
@media (min-width: 769px) {
  .hero-section {
    padding: calc(138px + 1.5rem) 0 5rem;
  }
}


.hero-content {
  max-width: 1000px;
  position: relative;
  text-align: left;
  padding: 2.5rem 3rem;
  margin-top: 0;
  z-index: 2;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 12px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.hero-title {
  /* FLUID RESPONSIVE FONT: Scales gently between ~3.25rem and 4.5rem above the
     1200px breakpoint (smaller/fixed sizes below that are set separately). */
  font-size: clamp(3.25rem, 1.5vw + 2.25rem, 4.5rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  color: rgba(255, 255, 255, 0.98);
  text-transform: uppercase;
  letter-spacing: 2px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.hero-highlight {
  display: block;
  color: var(--gold);
  font-weight: 700;
}

.hero-divider {
  width: 120px;
  height: 4px;
  background: var(--gold);
  margin: 2rem 0;
}

.hero-subtitle {
  /* FLUID RESPONSIVE FONT: Scales between 1.1rem and 1.5rem */
  font-size: clamp(1.1rem, 1.5vw + 0.5rem, 1.5rem);
  margin-bottom: 3rem;
  max-width: 700px;
  margin-left: 0;
  margin-right: 0;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.95);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}
.hero-btns {
  display: flex;
  gap: 1.5rem;
  justify-content: flex-start;
}

/* Button Fix for Outline Style */
.hero-btns .btn-outline {
  border-color: var(--gold);
  background-color: rgba(0, 0, 0, 0.2);
}

.hero-btns .btn-outline:hover {
  background-color: var(--gold);
}

/* Scroll Indicator Styling */
.scroll-indicator {
  position: absolute;
  bottom: 3rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.3s ease;
  cursor: pointer;
}

.scroll-indicator:hover {
  transform: translateX(-50%) translateY(5px);
}

.scroll-indicator:hover .wheel {
  animation-play-state: running;
}

.mouse {
  width: 30px;
  height: 50px;
  border: 2px solid var(--white);
  border-radius: 25px;
  margin-bottom: 0.5rem;
  display: flex;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.wheel {
  width: 4px;
  height: 8px;
  background: var(--white);
  border-radius: 2px;
  margin-top: 8px;
  animation: scroll 1.5s ease infinite;
}

@keyframes scroll {
  0% {
    transform: translateY(0);
    opacity: 1;
  }
  50% {
    transform: translateY(10px);
    opacity: 0.8;
  }
  100% {
    transform: translateY(20px);
    opacity: 0;
  }
}

.arrows span {
  display: block;
  width: 10px;
  height: 10px;
  border-bottom: 2px solid var(--white);
  border-right: 2px solid var(--white);
  transform: rotate(45deg);
  margin: 0 0 5px 0;
  animation: arrow 1.5s infinite;
}

.arrows span:nth-child(2) {
  animation-delay: 0.2s;
}

.arrows span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes arrow {
  0% {
    opacity: 0.4;
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0.4;
  }
}

/* Responsive Styles */
@media (max-width: 1199px) {
  .scroll-indicator {
    bottom: 2.5rem;
  }
}

@media (max-width: 991px) {
  .scroll-indicator {
    bottom: 2rem;
  }

  .mouse {
    width: 25px;
    height: 40px;
  }

  .hero-content {
    padding: 2rem 2rem;
  }

  .hero-section {
    padding-bottom: 4rem;
  }
  
  .hero-title {
      font-size: 3.5rem;
  }
}

@media (max-width: 767px) {
  .scroll-indicator {
    bottom: 1.5rem;
  }

  .mouse {
    width: 20px;
    height: 35px;
  }

  .hero-content {
    padding: 1.75rem 1.5rem;
    background: rgba(13, 26, 65, 0.35);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .hero-section {
    padding-bottom: 3rem;
  }
  
  .hero-title {
      font-size: 2.5rem;
  }
  
  .hero-container {
      padding-left: 1.5rem;
      padding-right: 1.5rem;
  }
}

@media (max-width: 576px) {
  .hero-content {
    padding: 1.5rem 1.25rem;
    margin-top: 20px;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }
}
/* Short desktop screens (e.g. 1280x720 laptops): tighten the card's internal
   spacing so it never crowds the navbar. */
@media (min-width: 769px) and (max-height: 820px) {
  .hero-content {
    padding: 2rem 3rem;
  }

  .hero-title {
    margin-bottom: 1rem;
  }

  .hero-divider {
    margin: 1.25rem 0;
  }

  .hero-subtitle {
    margin-bottom: 2rem;
  }
}
/* Hero Section */

/* Expertise Banner */
.expertise-banner {
    background-color: var(--white);
    padding: 2.5rem 0;
    box-shadow: var(--box-shadow-sm);
    position: relative;
    z-index: 10;
}

.expertise-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
}

.expertise-item {
    text-align: center;
}

.expertise-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1rem;
    background-color: var(--navy);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 0 5px rgba(13, 26, 65, 0.1);
}

.expertise-icon i {
    font-size: 32px;
    color: var(--gold);
    font-weight: bold;
}

.expertise-item h3 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

.expertise-item p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* About Section */
.about-section {
    background-color: var(--white);
    position: relative;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text {
    font-size: 1.05rem;
    color: var(--text-secondary);
    margin-bottom: 1.75rem;
    line-height: 1.7;
}

.about-features {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 2.5rem;
}

.feature {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    justify-content: flex-start;
}

.feature-icon {
    width: 50px;
    height: 50px;
    background-color: var(--gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.feature-icon i {
    font-size: 24px;
    color: var(--white);
    font-weight: bold;
}

.feature-content {
    flex: 1;
    text-align: left;
}

.feature-content h4 {
    font-size: 1.125rem;
    margin-bottom: 0.35rem;
    font-weight: 700;
    color: var(--navy);
}

.feature-content p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 0;
}

.about-image {
    position: relative;
}

.image-frame {
    position: relative;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--box-shadow-lg);
}

.image-frame::before {
    content: '';
    position: absolute;
    top: -20px;
    right: -20px;
    width: 100px;
    height: 100px;
    border: 5px solid var(--gold);
    z-index: -1;
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(13, 26, 65, 0.2), rgba(13, 26, 65, 0.4));
    z-index: 1;
}

/* Service Section Starts */

/* Services Section */
.services-section {
    background-color: var(--off-white);
    position: relative;
}

.service-tabs {
    margin-top: 3rem;
}

.tab-controls {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 3rem;
}

.tab-btn {
    background-color: transparent;
    border: none;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 1rem;
    padding: 0.75rem 1.5rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-medium);
    border-radius: var(--border-radius-md);
    position: relative;
}

.tab-btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 60%;
    height: 2px;
    background-color: var(--gold);
    transition: transform var(--transition-medium);
}

.tab-btn:hover {
    color: var(--navy);
}

.tab-btn.active {
    color: var(--navy);
    font-weight: 700;
}

.tab-btn.active::after {
    transform: translateX(-50%) scaleX(1);
}

.tab-content {
    position: relative;
}

.tab-pane {
    display: none;
    animation: fadeIn 0.5s ease;
}

.tab-pane.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}


.tab-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    align-items: stretch;
}

.tab-image {
    position: relative;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--box-shadow-md);
    width: 100%;
    min-height: 300px;
    max-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tab-image img {
    width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: contain;
    object-position: center;
}

.tab-details {
    padding: 2rem;
    background-color: var(--off-white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow-md);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.tab-title {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 1rem;
}

.tab-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 2px;
    background-color: var(--gold);
}

.tab-summary {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

.tab-cta {
    margin-top: 0.5rem;
}

.tab-cta .btn {
    margin-top: 0;
    padding: 0.85rem 1.75rem;
}

.service-features li {
    position: relative;
    padding-left: 1.75rem;
    margin-bottom: 0.75rem;
    font-size: 1rem;
    color: var(--text-primary);
}

.service-features li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.5rem;
    width: 6px;
    height: 6px;
    background-color: var(--gold);
    border-radius: 50%;
}

/* More services grid layout */
.more-services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  padding: 2rem 0;
}

/* Individual service item styling */
.service-item {
  background-color: var(--white);
  padding: 2rem;
  border-radius: var(--border-radius-lg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  border: 1px solid rgba(13, 26, 65, 0.1);
}

.service-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-color: var(--gold);
}

/* Service title styling */
.service-item .service-title {
  color: var(--navy);
  font-size: 1.375rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.3;
}

/* Service description styling */
.service-description {
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

/* Learn more button styling */
.service-item .btn.btn-text {
  color: var(--gold);
  font-weight: 600;
  padding: 0;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: all 0.2s ease;
}

.service-item .btn.btn-text:hover {
  color: var(--navy);
}

.service-item .btn-arrow {
  margin-left: 0.5rem;
  transition: transform 0.2s ease;
}

.service-item .btn.btn-text:hover .btn-arrow {
  transform: translateX(4px);
}

/* Responsive design for different screen sizes for the more-services-grid */
@media (min-width: 992px) {
  .more-services-grid {
    grid-template-columns: repeat(2, 1fr); /* 2 columns on desktop */
    gap: 2.5rem;
  }

  .service-item {
    padding: 2.5rem;
  }
}

@media (min-width: 768px) and (max-width: 991px) {
  .more-services-grid {
    grid-template-columns: repeat(2, 1fr); /* 2 columns on tablet */
    gap: 2rem;
  }
}

@media (max-width: 767px) {
  .more-services-grid {
    grid-template-columns: 1fr; /* 1 column on mobile */
    gap: 1.5rem;
  }

  .service-item {
    padding: 1.5rem;
  }

  .service-item .service-title {
    font-size: 1.25rem;
  }
}

/* Animation for when the specific 'More' tab becomes active */
.tab-pane#tab-5 .service-item {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease forwards;
}

.tab-pane#tab-5 .service-item:nth-child(1) {
  animation-delay: 0.1s;
}

.tab-pane#tab-5 .service-item:nth-child(2) {
  animation-delay: 0.2s;
}

.tab-pane#tab-5 .service-item:nth-child(3) {
  animation-delay: 0.3s;
}

.tab-pane#tab-5 .service-item:nth-child(4) {
  animation-delay: 0.4s;
}

.tab-pane#tab-5 .service-item:nth-child(5) {
  animation-delay: 0.5s;
}

.tab-pane#tab-5 .service-item:nth-child(6) {
  animation-delay: 0.6s;
}

.tab-pane#tab-5 .service-item:nth-child(7) {
  animation-delay: 0.7s;
}

.tab-pane#tab-5 .service-item:nth-child(8) {
  animation-delay: 0.8s;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Service Section Ends */

/* Philosophy Section */
.philosophy-section {
    background-color: var(--navy);
    padding: 6rem 0;
    position: relative;
}

.philosophy-content {
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.philosophy-quote {
    position: relative;
    padding: 2rem;
}

.philosophy-quote p {
    font-family: 'Montserrat', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--white);
    margin-bottom: 1.5rem;
}

.philosophy-quote::before,
.philosophy-quote::after {
    content: '"';
    font-family: Georgia, serif;
    font-size: 7rem;
    line-height: 0;
    color: var(--gold);
    opacity: 0.3;
    position: absolute;
}

.philosophy-quote::before {
    top: 2rem;
    left: 0;
}

.philosophy-quote::after {
    bottom: -1rem;
    right: 0;
    transform: rotate(180deg);
}

.quote-author {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 700;
    font-size: 1.1rem;
    margin-top: 0.5rem;
}

/* Projects Section */
.projects-section {
    background-color: var(--white);
    position: relative;
}

.project-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 3rem;
}

.filter-btn {
    background-color: transparent;
    border: none;
    font-family: var(--font-heading);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.5rem 1rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-medium);
    border-radius: var(--border-radius-md);
}

.filter-btn:hover {
    color: var(--navy);
}

.filter-btn.active {
    background-color: var(--navy);
    color: var(--white);
}

/* Projects Grid - Equal Size Cards with improved responsiveness */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.project-card {
    background-color: var(--white);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--box-shadow-sm);
    display: flex; /* Added for equal height cards */
    flex-direction: column; /* Added for equal height cards */
    height: 100%; /* Added for equal height cards */
    transition: transform var(--transition-medium), box-shadow var(--transition-medium);
    position: relative;
}

.project-card:hover {
    transform: translateY(-10px); /* Kept original hover subtle lift */
    box-shadow: var(--box-shadow-lg); /* Kept original box shadow on hover */
}

/* Removed .project-card.featured to ensure equal sizing as per "fix" goal */

.project-image {
    position: relative;
    height: 240px; /* Consistent image height */
    overflow: hidden;
}

/* Removed .project-card.featured .project-image to ensure equal sizing as per "fix" goal */

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.project-card:hover .project-image img {
    transform: scale(1.05);
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(13, 26, 65, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-medium);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-link {
    color: var(--white); /* Kept original white text for link */
    background-color: var(--gold);
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius-md); /* Kept original border-radius-md */
    font-weight: 600;
    transform: translateY(20px); /* Kept original animation */
    transition: all var(--transition-medium);
}

.project-card:hover .project-link {
    transform: translateY(0); /* Kept original animation */
}

.project-link:hover {
    background-color: var(--gold-light); /* Kept original lighter gold on hover */
    color: var(--text-primary); /* Kept original text-primary on hover */
}

.project-details {
    padding: 1.5rem;
    flex-grow: 1; /* Ensures content pushes to the bottom for equal height */
    display: flex; /* Added for flex content in details */
    flex-direction: column; /* Added for flex content in details */
}

.project-title {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.project-category {
    color: var(--gold);
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px; /* Kept original letter spacing */
}

.project-description {
    color: var(--text-secondary); /* Kept original text-secondary for description */
    font-size: 0.95rem; /* Kept original font size */
    margin-bottom: 1rem;
    flex-grow: 1; /* Ensures description takes available space for equal height */
}

.project-more {
    font-weight: 600;
    color: var(--navy); /* Kept original navy color */
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    align-self: flex-start; /* Ensures button aligns to start when flex-direction is column */
}

.project-more:hover {
    color: var(--gold);
}

.project-more::after {
    content: '→';
    margin-left: 0.35rem; /* Kept original margin */
    transition: transform var(--transition-fast); /* Kept original transition */
}

.project-more:hover::after {
    transform: translateX(4px);
}

.projects-btn {
    text-align: center;
    margin-top: 3rem;
}

/* Media queries to adjust layout at different screen sizes, from the "fix" code */
@media (min-width: 992px) {
    .projects-grid {
        grid-template-columns: repeat(3, 1fr); /* 3 columns on desktop */
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columns on tablet */
    }
}

@media (max-width: 767px) {
    .projects-grid {
        grid-template-columns: 1fr; /* 1 column on mobile */
    }

    .project-image {
        height: 220px; /* Slightly smaller on mobile */
    }
}
/* Client project cards (homepage + Our Projects page).
   Content is taken verbatim from Franklin Engineering's project write-ups.
   Cards without a supplied photo show a themed icon panel; when a photo is
   added, place an <img> inside .fe-project-media and it will cover the panel. */
.project-card.fe-project {
    border: 1px solid rgba(13, 26, 65, 0.08);
    border-radius: 10px;
    box-shadow: 0 4px 18px rgba(13, 26, 65, 0.08);
    background: var(--white);
}

.project-card.fe-project:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(13, 26, 65, 0.16);
}

.fe-project-media {
    position: relative;
    height: 200px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background-color: var(--navy);
    /* Subtle blueprint grid over a navy gradient */
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 55%, var(--navy-light) 100%);
    background-size: 22px 22px, 22px 22px, 100% 100%;
    border-bottom: 3px solid var(--gold);
}

.fe-project-media--photo {
    cursor: pointer;
    background-color: var(--navy);
}

.fe-project-media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform var(--transition-slow);
}

.fe-project-photo-count {
    position: absolute;
    right: 0.75rem;
    bottom: 0.75rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 0.65rem;
    border-radius: 999px;
    background: rgba(6, 16, 42, 0.78);
    color: var(--white);
    font-family: var(--font-heading);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.project-card.fe-project:hover .fe-project-media img {
    transform: scale(1.05);
}

.fe-project-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.25rem;
    color: var(--gold);
    background: rgba(209, 150, 42, 0.12);
    border: 1px solid rgba(209, 150, 42, 0.45);
    transition: transform var(--transition-medium), background-color var(--transition-medium);
}

.project-card.fe-project:hover .fe-project-icon {
    transform: scale(1.08);
    background: rgba(209, 150, 42, 0.2);
}

.fe-project-body {
    padding: 1.5rem 1.5rem 1.35rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.fe-project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.85rem;
}

.fe-project-category,
.fe-project-subcategory {
    font-family: var(--font-heading);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 0.3rem 0.65rem;
    border-radius: 999px;
    line-height: 1.2;
}

.fe-project-category {
    color: var(--gold-dark);
    background: rgba(209, 150, 42, 0.12);
}

.fe-project-subcategory {
    color: var(--navy);
    background: rgba(13, 26, 65, 0.07);
}

.fe-project-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.35;
    color: var(--navy);
    margin-bottom: 0.75rem;
}

.fe-project-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: 1.25rem;
    /* Card shows a 3-line excerpt; the full text opens in the project dialog */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.fe-project-more {
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    width: 100%;
    padding: 1rem 0 0;
    background: none;
    border: none;
    border-top: 1px solid rgba(13, 26, 65, 0.08);
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--navy);
    text-align: left;
    cursor: pointer;
    transition: color var(--transition-fast);
}

.fe-project-more i {
    transition: transform var(--transition-fast);
}

.fe-project-more:hover,
.fe-project-more:focus-visible {
    color: var(--gold-dark);
}

.fe-project-more:hover i,
.fe-project-more:focus-visible i {
    transform: translateX(4px);
}

/* Same 3/2/1 column grid on the homepage and the Our Projects page */
.projects-grid.fe-projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.project-card.fe-project:hover {
    border-color: rgba(209, 150, 42, 0.45);
}

@media (max-width: 991px) {
    .projects-grid.fe-projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 767px) {
    .projects-grid.fe-projects-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .fe-project-media {
        height: 190px;
    }

    .fe-project-body {
        padding: 1.25rem 1.25rem 1.15rem;
    }
}
/* Project "Read more" dialog (project-modal.js) */
html.fe-dialog-open {
    overflow: hidden;
}

.fe-project-dialog {
    /* The global reset zeroes margins; restore auto margins to centre the dialog */
    margin: auto;
    width: min(960px, calc(100vw - 2rem));
    max-width: none;
    max-height: calc(100vh - 2rem);
    padding: 0;
    border: none;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(6, 16, 42, 0.45);
    background: var(--white);
}

.fe-project-dialog::backdrop {
    background: rgba(6, 16, 42, 0.78);
    backdrop-filter: blur(3px);
}

.fe-project-dialog [hidden] {
    display: none !important;
}

.fe-dialog-inner {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    max-height: calc(100vh - 2rem);
}

.fe-dialog-media {
    position: relative;
    min-height: 420px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--navy-dark);
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 55%, var(--navy-light) 100%);
    background-size: 22px 22px, 22px 22px, 100% 100%;
}

.fe-dialog-img {
    display: block;
    width: 100%;
    height: 100%;
    max-height: calc(100vh - 2rem);
    object-fit: contain;
}

.fe-dialog-icon {
    width: 110px;
    height: 110px;
    font-size: 3.25rem;
}

.fe-dialog-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--navy);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--box-shadow-md);
    cursor: pointer;
    transition: background-color var(--transition-fast), color var(--transition-fast);
}

.fe-dialog-nav:hover,
.fe-dialog-nav:focus-visible {
    background: var(--gold);
    color: var(--white);
}

.fe-dialog-prev {
    left: 0.85rem;
}

.fe-dialog-next {
    right: 0.85rem;
}

.fe-dialog-counter {
    position: absolute;
    bottom: 0.85rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    background: rgba(6, 16, 42, 0.78);
    color: var(--white);
    font-family: var(--font-heading);
    font-size: 0.75rem;
    font-weight: 600;
}

.fe-dialog-body {
    padding: 2.5rem 2.25rem 2.25rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    border-top: 4px solid var(--gold);
}

.fe-dialog-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--navy);
    margin-bottom: 1rem;
}

.fe-dialog-description {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.75;
    margin-bottom: 2rem;
}

.fe-dialog-cta {
    align-self: flex-start;
}

.fe-dialog-close {
    position: absolute;
    top: 0.85rem;
    right: 0.85rem;
    z-index: 2;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(13, 26, 65, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--navy);
    background: var(--white);
    box-shadow: var(--box-shadow-md);
    cursor: pointer;
    transition: background-color var(--transition-fast), color var(--transition-fast);
}

.fe-dialog-close:hover,
.fe-dialog-close:focus-visible {
    background: var(--navy);
    color: var(--white);
}

@media (max-width: 767px) {
    .fe-project-dialog {
        width: calc(100vw - 1.5rem);
        max-height: calc(100vh - 1.5rem);
    }

    .fe-dialog-inner {
        grid-template-columns: 1fr;
        max-height: calc(100vh - 1.5rem);
        overflow-y: auto;
    }

    .fe-dialog-media {
        min-height: 0;
        height: 260px;
    }

    .fe-dialog-img {
        max-height: 260px;
    }

    .fe-dialog-icon {
        width: 84px;
        height: 84px;
        font-size: 2.5rem;
    }

    .fe-dialog-body {
        padding: 1.5rem 1.25rem 1.5rem;
        overflow-y: visible;
    }

    .fe-dialog-title {
        font-size: 1.25rem;
    }

    .fe-dialog-cta {
        align-self: stretch;
        text-align: center;
    }
}
/* Projects Section Ends */

/* Testimonials Section */
.testimonials-section {
    background-color: var(--off-white);
    position: relative;
    padding: 5rem 0 6rem;
}

/* Testimonial Slider */
.testimonials-slider {
    position: relative;
    overflow: hidden;
    min-height: 450px; /* Adjusted for consistency */
    margin-bottom: 2rem;
    padding: 1rem 0;
}

/* Testimonial Track for Carousel */
.testimonial-track {
    display: flex;
    position: absolute;
    width: 100%;
    height: 100%;
    transition: transform 0.6s ease-in-out;
    padding-bottom: 20px; /* Space at the bottom */
}

/* Testimonial Card */
.testimonial-card {
    background-color: var(--white);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--box-shadow-md);
    transition: transform 0.4s ease, opacity 0.4s ease;
    position: relative;
    flex-shrink: 0;
    margin-right: 2rem;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
    height: auto;
    min-height: 400px;
    display: flex;
    flex-direction: column;
}

/* Hover Effect for Testimonial Card */
.testimonial-card:hover {
    transform: translateY(-5px);
}

/* Active Testimonial Card */
.testimonial-card.active {
    z-index: 2;
}

/* Testimonial Content */
.testimonial-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    flex: 1;
    padding: 2rem;
}

/* Quote Icon */
.quote-icon {
    width: 40px;
    height: 40px;
    background-color: rgba(13, 26, 65, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.quote-icon svg {
    width: 20px;
    height: 20px;
    fill: var(--gold);
}

/* Testimonial Text */
.testimonial-content p {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

/* Testimonial Rating */
.testimonial-rating {
    color: var(--gold);
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
}

/* Testimonial Author Info */
.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-info h4 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.author-info p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* Testimonial Navigation (Prev & Next) */
.testimonial-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

/* Navigation Button Styles */
.testimonial-prev,
.testimonial-next {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--white);
    border: 1px solid var(--lightest-grey);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-medium);
}

/* Navigation Button SVGs */
.testimonial-prev svg,
.testimonial-next svg {
    width: 24px;
    height: 24px;
    fill: var(--navy);
    transition: fill var(--transition-medium);
}

/* Hover State for Prev/Next */
.testimonial-prev:hover,
.testimonial-next:hover {
    background-color: var(--navy);
    border-color: var(--navy);
}

.testimonial-prev:hover svg,
.testimonial-next:hover svg {
    fill: var(--white);
}

/* Testimonial Dot Navigation */
.testimonial-dots {
    display: flex;
    gap: 0.5rem;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: var(--lightest-grey);
    cursor: pointer;
    transition: background-color var(--transition-medium);
}

.dot.active,
.dot:hover {
    background-color: var(--gold);
}

/* Testimonial Carousel Responsive Styles */
@media (min-width: 1200px) {
    /* Desktop - Show 3 cards */
    .testimonial-card {
        width: calc((100% - 4rem) / 3);
    }
}

@media (min-width: 768px) and (max-width: 1199px) {
    /* Tablet - Show 2 cards */
    .testimonial-card {
        width: calc((100% - 2rem) / 2);
    }
}

@media (max-width: 767px) {
    /* Mobile - Show 1 card */
    .testimonial-card {
        width: 100%;
        margin-right: 0;
    }

    .testimonials-slider {
        min-height: 420px;
    }
}
/* Testimonials Section Ends */

/* Stats Section */
.stats-section {
    background-color: var(--navy);
    padding: 4rem 0;
    position: relative;
    color: var(--white);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.stat-card {
    padding: 1.5rem;
}

.stat-number {
    font-family: 'Montserrat', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: var(--gold);
    margin-bottom: 0.5rem;
    line-height: 1;
}

.stat-label {
    font-size: 1rem;
    color: var(--white);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Team Section */
.team-section {
    background-color: var(--white);
    position: relative;
}

.team-intro {
    max-width: 800px;
    margin: 0 auto 3rem;
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.team-cta {
    text-align: center;
}

.team-cta .btn-outline {
    color: var(--navy);
    border-color: var(--navy);
}

.team-cta .btn-outline:hover {
    background-color: var(--navy);
    color: var(--white);
}

/* Contact Section */
.contact-section {
    background-color: var(--off-white);
    position: relative;
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-intro {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    line-height: 1.7;
}

.info-group {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.info-icon {
    width: 40px;
    height: 40px;
    background-color: rgba(13, 26, 65, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.info-icon svg {
    width: 22px;
    height: 22px;
    fill: var(--navy);
}

.info-content h4 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
    color: var(--navy);
}

.info-content p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.info-content a {
    color: var(--navy);
    font-weight: 500;
}

.info-content a:hover {
    color: var(--gold);
}

.map-container {
    margin-top: 3rem;
    border-radius: var(--border-radius-md);
    overflow: hidden;
    height: 250px;
    box-shadow: var(--box-shadow-md);
}

.map-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.contact-form-container {
    background-color: var(--white);
    padding: 2.5rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow-md);
}

.form-header {
    margin-bottom: 2rem;
    text-align: center;
}

.form-header h3 {
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
    color: var(--navy);
}

.form-header p {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 0;
}

.contact-form {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.form-group {
    position: relative;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.contact-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-primary);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--lightest-grey);
    border-radius: var(--border-radius-md);
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--text-primary);
    background-color: var(--white);
    transition: border-color var(--transition-medium);
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    border-color: var(--gold);
    outline: none;
    box-shadow: 0 0 0 2px rgba(209, 150, 42, 0.2);
}

.contact-form textarea {
    resize: vertical;
    min-height: 120px;
}

.form-submit {
    margin-top: 1rem;
}

.form-submit .btn {
    width: 100%;
}

/* CTA Section */
.cta-section {
    background-color: var(--navy);
    color: var(--white);
    padding: 5rem 0;
    position: relative;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 2;
}

.cta-content h2 {
    font-size: 2.5rem;
    color: var(--white);
    margin-bottom: 1rem;
}

.cta-content p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

/* Footer */
.footer {
    background-color: var(--navy-dark);
    color: var(--white);
    padding: 5rem 0 2rem;
    position: relative;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 3fr 2fr;
    gap: 4rem;
    margin-bottom: 3rem;
}

.footer-brand {
    display: flex;
    flex-direction: column;
}

.footer-logo {
    height: 40px;
    width: auto;
    margin-bottom: 1.5rem;
}

.footer-tagline {
    font-size: 1rem;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.footer-address {
    font-size: 0.9rem;
    opacity: 0.7;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.footer-certifications {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.cert-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.1);
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
}

.footer-nav-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.footer-heading {
    font-size: 1.125rem;
    color: var(--white);
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    transition: all var(--transition-medium);
    display: inline-block;
}

.footer-links a:hover {
    color: var(--gold);
    transform: translateX(5px);
}

.footer-contact-info {
    margin-bottom: 2rem;
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.footer-icon {
    width: 18px;
    height: 18px;
    fill: var(--gold);
}

.footer-contact-item a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
}

.footer-contact-item a:hover {
    color: var(--gold);
}

.footer-newsletter h4 {
    margin-bottom: 1rem;
}

/* Social Link Styling */
.social-link {
  margin-top: 1rem;
}

.instagram-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--gold);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.instagram-link:hover {
  color: var(--gold-light);
}

.instagram-link i {
  font-size: 1.2rem;
}


.newsletter-form {
    display: flex;
    gap: 0.5rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius-md);
    background-color: rgba(255, 255, 255, 0.05);
    color: var(--white);
    font-family: var(--font-body);
}

.newsletter-form input:focus {
    outline: none;
    border-color: var(--gold);
}

.newsletter-form input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-form .btn {
    padding: 0.75rem 1rem;
    background-color: var(--gold);
    color: var(--text-primary);
}

.newsletter-form .btn:hover {
    background-color: var(--gold-light);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.copyright {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
    margin-bottom: 0;
}

.footer-legal {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.footer-legal a {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
}

.footer-legal a:hover {
    color: var(--gold);
}

.separator {
    color: rgba(255, 255, 255, 0.3);
}

/* Animation Classes */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.slide-in-right.visible {
    opacity: 1;
    transform: translateX(0);
}

.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.slide-in-left.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Responsive Design */
@media (max-width: 1200px) {
    html {
        font-size: 15px;
    }
    
    .hero-title {
        font-size: 3.5rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
}

@media (max-width: 992px) {
    html {
        font-size: 14px;
    }
    
    .main-nav {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: flex;
        margin-left: auto;
    }
    
    .header-cta {
        margin-left: 1.5rem;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .expertise-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
    
    .about-grid,
    .tab-grid,
    .contact-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .about-image,
    .tab-image {
        order: -1;
    }
    
    .project-card.featured {
        grid-column: span 1;
    }
    
    .project-card.featured .project-image {
        height: 240px;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

@media (max-width: 768px) {
    section {
        padding: 4rem 0;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-btns {
        flex-direction: column;
        gap: 1rem;
    }
    
    .hero-btns .btn {
        width: 100%;
    }
    
    .expertise-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .testimonials-slider {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .footer-nav-container {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .philosophy-quote p {
        font-size: 2rem;
    }
    
    .tab-image {
        min-height: 250px;
        max-height: 400px;
        margin: 0 auto;
    }
    
    .cta-buttons {
        flex-direction: column;
        gap: 1rem;
    }
}

@media (max-width: 576px) {
    .section-title {
        font-size: 2rem;
    }
    
    .tab-controls {
        flex-direction: column;
    }
    
    .tab-btn {
        width: 100%;
        text-align: center;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-form .btn {
        width: 100%;
    }
}

/* Utility Classes */
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 2rem; }
.mt-5 { margin-top: 3rem; }

.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 2rem; }
.mb-5 { margin-bottom: 3rem; }

.ml-1 { margin-left: 0.25rem; }
.ml-2 { margin-left: 0.5rem; }
.ml-3 { margin-left: 1rem; }

.mr-1 { margin-right: 0.25rem; }
.mr-2 { margin-right: 0.5rem; }
.mr-3 { margin-right: 1rem; }

.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 1rem; padding-bottom: 1rem; }
.py-4 { padding-top: 2rem; padding-bottom: 2rem; }
.py-5 { padding-top: 3rem; padding-bottom: 3rem; }

.px-1 { padding-left: 0.25rem; padding-right: 0.25rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-3 { padding-left: 1rem; padding-right: 1rem; }
.px-4 { padding-left: 2rem; padding-right: 2rem; }
.px-5 { padding-left: 3rem; padding-right: 3rem; }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-white { color: var(--white); }
.text-navy { color: var(--navy); }
.text-gold { color: var(--gold); }
.text-grey { color: var(--text-secondary); }

.bg-white { background-color: var(--white); }
.bg-navy { background-color: var(--navy); }
.bg-gold { background-color: var(--gold); }
.bg-off-white { background-color: var(--off-white); }

.fw-light { font-weight: 300; }
.fw-regular { font-weight: 400; }
.fw-medium { font-weight: 500; }
.fw-semi-bold { font-weight: 600; }
.fw-bold { font-weight: 700; }

.fs-sm { font-size: 0.875rem; }
.fs-base { font-size: 1rem; }
.fs-lg { font-size: 1.125rem; }
.fs-xl { font-size: 1.25rem; }
.fs-2xl { font-size: 1.5rem; }

/* FAQ Section */
.faq-section {
  background-color: var(--white);
  position: relative;
}

.faq-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  margin-top: 3rem;
  position: relative;
  min-height: 400px;
}

/* Sidebar */
.faq-sidebar {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* Category Buttons */
.faq-category-btn {
  background-color: transparent;
  border: none;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1rem;
  padding: 1rem 1.5rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-medium);
  border-radius: var(--border-radius-md);
  text-align: left;
  border-left: 3px solid transparent;
}

.faq-category-btn:hover {
  color: var(--navy);
  background-color: rgba(13, 26, 65, 0.07);
}

.faq-category-btn:focus {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.faq-category-btn.active {
  color: var(--navy);
  background-color: rgba(13, 26, 65, 0.05);
  border-left-color: var(--gold);
}

/* FAQ Content Wrapper */
.faq-content {
  position: relative;
  min-height: 400px;
}

/* Tab Content */
.faq-category {
  display: none;
  animation: fadeIn 0.3s ease;
  transition: opacity 0.3s ease;
  opacity: 0;
}

.faq-category.active {
  display: block;
  opacity: 1;
}

/* Accordion Item */
.faq-item {
  margin-bottom: 1.5rem;
  border-radius: var(--border-radius-md);
  background-color: var(--off-white);
  overflow: hidden;
  box-shadow: var(--box-shadow-sm);
  transition: box-shadow var(--transition-medium);
}

.faq-item:hover {
  box-shadow: var(--box-shadow-md);
}

/* Accordion Header */
.faq-question {
  padding: 1.5rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.faq-question h3 {
  font-family: 'Montserrat', sans-serif;
  letter-spacing: 0.02em;
  font-size: 1.125rem;
  margin-bottom: 0;
  padding-right: 2rem;
  color: var(--navy);
}

/* Accordion Icon */
.faq-icon {
  position: relative;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.faq-icon .plus,
.faq-icon .minus {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--navy);
  transition: transform var(--transition-medium);
}

.faq-icon .plus {
  transform: translateY(-50%);
}

.faq-icon .minus {
  transform: translateY(-50%) rotate(90deg);
}

.faq-item.active .faq-icon .minus {
  transform: translateY(-50%) rotate(0);
}

/* Accordion Body */
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
  padding: 0 1.5rem;
}

.faq-item.active .faq-answer {
  max-height: 500px;
  padding-bottom: 1.5rem;
}

.faq-answer p {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1rem;
}

.faq-answer p:last-child {
  margin-bottom: 0;
}

/* Responsive Design */
@media (max-width: 992px) {
  .faq-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .faq-sidebar {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
  }

  .faq-category-btn {
    border-left: none;
    border-bottom: 3px solid transparent;
    padding: 0.75rem 1.25rem;
  }

  .faq-category-btn.active {
    border-bottom-color: var(--gold);
  }
}

@media (max-width: 768px) {
  .faq-category-btn {
    width: calc(50% - 0.5rem);
    font-size: 0.9rem;
    padding: 0.75rem 1rem;
    text-align: center;
  }
}

@media (max-width: 576px) {
  .faq-category-btn {
    width: 100%;
  }

  .faq-question h3 {
    font-size: 1rem;
  }
}

/* Specific Tab Styling (if needed) */
#services {
  position: relative;
}

.fs-md { font-size: 1rem; }
.fs-lg { font-size: 1.25rem; }
.fs-xl { font-size: 1.5rem; }
.fs-xxl { font-size: 2rem; }

/* Legal pages (Privacy Policy, Terms of Use) and 404 page */
.legal-section {
    padding: 4rem 0 5rem;
}

.legal-content {
    max-width: 820px;
    margin: 0 auto;
    color: var(--text-secondary);
    line-height: 1.75;
}

.legal-content .legal-updated {
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

.legal-content h2 {
    font-size: 1.4rem;
    color: var(--navy);
    margin: 2.5rem 0 0.75rem;
}

.legal-content p,
.legal-content ul {
    margin-bottom: 1rem;
}

.legal-content ul {
    padding-left: 1.5rem;
}

.legal-content li {
    margin-bottom: 0.4rem;
}

.legal-content a {
    color: var(--gold);
    text-decoration: underline;
}

.not-found-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 2rem;
}

/* Contact form spam trap (hidden from people) and send-error message */
.form-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.form-error-message {
    margin-top: 1rem;
    color: #b42318;
    font-size: 0.95rem;
}
