@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&family=Open+Sans:wght@400;600&display=swap');

/* Fallback font-face to ensure compliance with font-display rules if external fails */
@font-face {
  font-family: 'Montserrat';
  src: local('Montserrat');
  font-display: swap;
}
@font-face {
  font-family: 'Open Sans';
  src: local('Open Sans');
  font-display: swap;
}

:root {
  --primary-dark: #2C3E50;
  --accent: #F39C12;
  --accent-hover: #E67E22;
  --bg-secondary: #ECF0F1;
  --white: #FFFFFF;
  --text-gray: #7F8C8D;
  --font-primary: 'Montserrat', sans-serif;
  --font-fallback: 'Open Sans', sans-serif;
}

body {
  font-family: var(--font-primary);
  color: var(--text-gray);
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--primary-dark);
  font-family: var(--font-primary);
}

p {
  font-family: var(--font-fallback);
  line-height: 1.6;
}

/* Typography Hierarchy */
h1 { font-size: 2.5rem; font-weight: 700; line-height: 1.2; margin-bottom: 1rem; }
h2 { font-size: 2rem; font-weight: 600; line-height: 1.3; margin-bottom: 1rem; }
h3 { font-size: 1.5rem; font-weight: 600; line-height: 1.4; margin-bottom: 0.75rem; }
.caption { font-size: 0.875rem; color: var(--text-gray); }

@media (min-width: 768px) {
  h1 { font-size: 3.5rem; }
  h2 { font-size: 2.5rem; }
  h3 { font-size: 1.75rem; }
}

/* CTAs */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
  cursor: pointer;
}

.btn-primary {
  background-color: var(--accent);
  color: var(--white);
  font-weight: 700;
  border-radius: 4px;
  padding: 12px 24px;
  text-transform: uppercase;
  border: none;
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  color: var(--white);
  box-shadow: 0 4px 12px rgba(243, 156, 18, 0.4); /* Glow effect */
  transform: scale(1.05);
}

.btn-secondary {
  background-color: transparent;
  color: var(--primary-dark);
  border: 2px solid var(--primary-dark);
  font-weight: 600;
  border-radius: 4px;
  padding: 10px 22px;
}

.btn-secondary:hover {
  background-color: var(--primary-dark);
  color: var(--white);
}

.btn-tertiary {
  color: var(--primary-dark);
  text-decoration: underline;
  font-weight: 500;
  background: transparent;
  border: none;
  padding: 0;
}

.btn-tertiary:hover {
  color: var(--accent);
  text-decoration: none;
}

/* Header & Nav */
.desktop-nav a {
  color: var(--primary-dark);
  font-weight: 500;
  position: relative;
  text-decoration: none;
  transition: color 0.2s ease-in-out;
}

.desktop-nav a:hover {
  color: var(--accent);
}

.desktop-nav a::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--accent);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.3s ease-in-out;
}

.desktop-nav a:hover::after {
  transform: scaleX(1);
}

.header-sticky {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 50;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  background: var(--white);
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from { transform: translateY(-100%); }
  to { transform: translateY(0); }
}

/* Animations & Interactions */
.fade-in-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

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

.icon-interactive {
  transition: transform 0.2s ease-in-out;
}
.icon-interactive:hover {
  transform: scale(1.05) translateY(-2px);
}

.testimonial-card {
  transition: box-shadow 0.3s ease;
  border: 2px solid transparent;
}
.testimonial-card:hover {
  border-color: var(--accent);
}

.service-card {
  transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}
.service-card:hover {
  transform: scale(1.02);
  box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

/* Form inputs */
.form-input {
  border: 1px solid #ccc;
  border-bottom: 2px solid #ccc;
  transition: border-bottom-color 0.3s ease;
}
.form-input:focus {
  outline: none;
  border-bottom-color: var(--primary-dark);
}

/* Lightbox */
#lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.9);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
#lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

/* Mobile Nav Overlay */
#mobile-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: var(--primary-dark);
  z-index: 40;
  transform: translateY(-100%);
  transition: transform 0.3s ease-in-out;
}
#mobile-nav.open {
  transform: translateY(0);
}

/* Hero Animations */
.hero-text {
  animation: slideInLeft 0.8s ease-out;
}
.hero-img {
  animation: slideInRight 0.8s ease-out;
}

@keyframes slideInLeft {
  from { opacity: 0; transform: translateX(-50px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(50px); }
  to { opacity: 1; transform: translateX(0); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
