:root {
  --midnight: #1A2340;
  --deep-navy: #243054;
  --slate: #2d3548;
  --gold: #D4A574;
  --gold-light: #E8C77A;
  --cream: #F4EAD5;
  --silver: #c0c5ce;
  --charcoal: #1e1e1e;
  --border: #4E4B46;
}

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

body {
  font-family: 'Vend Sans', sans-serif;
  background: var(--cream);
  color: var(--charcoal);
}

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--deep-navy); }
::-webkit-scrollbar-thumb { background: var(--gold); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--gold-light); }

h1, h2, h3, h4, h5, h6 {
  font-family: 'Vend Sans', sans-serif;
  font-weight: 700;
}

/* Nav */
/* Navigation */
.nav-link-custom {
  position: relative;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  font-weight: 600;
  padding: 10px 18px !important;
  transition: color 0.3s ease;
}

.nav-link-custom:hover {
  color: var(--gold-light) !important;
}

.nav-link-custom::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--gold);
  transition: width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateX(-50%);
  border-radius: 1px;
}

.nav-link-custom:hover::after {
  width: 50%;
}

.nav-link-custom.active::after {
  width: 60%;
}

.nav-link-custom.active {
  color: var(--gold-light) !important;
}

/* Mega Menu */
.mega-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(12px);
  width: 600px;
  background: #0d1233;
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-radius: 14px;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 100;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.group:hover .mega-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(6px);
}

.mega-menu a {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  border-radius: 10px;
  color: var(--cream);
  text-decoration: none;
  transition: all 0.25s ease;
  font-size: 0.9rem;
}

.mega-menu a:hover {
  background: rgba(212, 175, 55, 0.08);
  color: var(--gold-light);
  transform: translateX(4px);
}

.mega-menu a i {
  color: var(--gold);
  width: 24px;
  text-align: center;
  font-size: 1rem;
}

.mega-menu a:hover i {
  color: var(--gold-light);
}

#navbar {
  transition: box-shadow 0.3s ease;
}

#navbar.navbar-scrolled {
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}

#navbarInner {
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
  transition: padding 0.3s ease;
}

#navbar.navbar-scrolled #navbarInner {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
}

.navbar-brand {
  transition: font-size 0.3s ease;
}

#navbar.navbar-scrolled .navbar-brand {
  font-size: 1.3rem !important;
}

/* Buttons */
.btn-gold {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--midnight);
  padding: 14px 32px;
  border: none;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.85rem;
  transition: all 0.4s;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.btn-gold::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--midnight);
  transform: translateX(-100%);
  transition: transform 0.4s;
  z-index: 0;
}

.btn-gold:hover::before {
  transform: translateX(0);
}

.btn-gold span,
.btn-gold i,
.btn-gold svg {
  position: relative;
  z-index: 1;
  transition: color 0.4s;
}

.btn-gold:hover span,
.btn-gold:hover i,
.btn-gold:hover svg {
  color: var(--gold);
}

.btn-outline-gold {
  border: 2px solid var(--gold);
  color: var(--gold);
  padding: 12px 28px;
  background: transparent;
  transition: all 0.4s;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

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

/* Service Cards */
.service-card {
  background: white;
  padding: 36px 28px;
  border: 1px solid rgba(212, 175, 55, 0.2);
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--gold) 0%, var(--gold-light) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.service-card:hover::before {
  transform: scaleX(1);
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 50px rgba(10, 14, 39, 0.12);
}

.service-icon {
  transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.service-card:hover .service-icon {
  transform: scale(1.1) rotate(5deg);
}

/* Feature Cards */
.feature-card {
  background: white;
  padding: 36px 28px;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.1);
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 0;
  background: linear-gradient(to bottom, var(--gold) 0%, var(--gold-light) 100%);
  transition: height 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.feature-card:hover::before {
  height: 100%;
}

.feature-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(10, 14, 39, 0.1);
  border-color: var(--gold);
}

.feature-icon {
  transition: all 0.5s;
}

.feature-card:hover .feature-icon {
  transform: rotate(5deg) scale(1.1);
}

/* Trust Badges */
.trust-badge {
  text-align: center;
  padding: 28px 20px;
  background: var(--deep-navy);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 10px;
  transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  position: relative;
  overflow: hidden;
}

.trust-badge:hover {
  transform: translateY(-8px);
  background: rgb(39, 29, 0);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  border-color: rgba(212, 175, 55, 0.4);
}

.trust-badge i,
.trust-badge svg {
  transition: all 0.4s;
}

.trust-badge:hover i,
.trust-badge:hover svg {
  transform: scale(1.1);
}

/* Area Cards */
.area-card {
  text-align: center;
  padding: 36px 24px;
  background: white;
  border-radius: 12px;
  border: 1px solid rgba(212, 175, 55, 0.1);
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
  position: relative;
  overflow: hidden;
}

.area-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.1) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.5s;
}

.area-card:hover::before {
  opacity: 1;
}

.area-card:hover {
  transform: translateY(-8px);
  border-color: var(--gold);
  box-shadow: 0 20px 40px rgba(10, 14, 39, 0.08);
}

.area-icon {
  transition: all 0.5s;
}

.area-card:hover .area-icon {
  transform: scale(1.1);
}

/* Process Steps */
.process-step {
  text-align: center;
  padding: 32px 20px;
  position: relative;
  border: 1px solid #818181;
  border-radius: 40px;
  height: 100%;
}

.process-step::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 100%;
  width: calc(100% - 60px);
  height: 2px;
  background: linear-gradient(90deg, var(--gold) 0%, transparent 100%);
  transform: translateY(-50%);
  opacity: 0.3;
}

.process-step:last-child::before {
  display: none;
}

@media (max-width: 768px) {
  .process-step::before {
    display: none;
  }
}

.process-number {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--midnight);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 900;
  margin: 0 auto 20px;
  position: relative;
  z-index: 2;
  transition: all 0.4s;
  border: 3px solid rgba(212, 175, 55, 0.3);
}

.process-step:hover .process-number {
  transform: scale(1.1) rotate(15deg);
  box-shadow: 0 12px 24px rgba(212, 175, 55, 0.3);
}

/* Testimonials */
.testimonial-card {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  padding: 40px 32px;
  border: 1px solid rgba(212, 175, 55, 0.2);
  position: relative;
  height: 100%;
}

.testimonial-card::before {
  content: '"';
  position: absolute;
  top: 20px;
  left: 28px;
  font-size: 80px;
  color: var(--gold);
  opacity: 0.1;
  font-family: serif;
  line-height: 1;
}

/* Portfolio */
.portfolio-item {
  position: relative;
  height: 400px;
  overflow: hidden;
  cursor: pointer;
}

.portfolio-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s cubic-bezier(0.23, 1, 0.32, 1);
}

.portfolio-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 14, 39, 0.95) 0%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 32px;
  opacity: 0;
  transition: opacity 0.5s;
}

.portfolio-item:hover img {
  transform: scale(1.1);
}

.portfolio-item:hover .portfolio-overlay {
  opacity: 1;
}

/* Social */
.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 50%;
  transition: all 0.3s;
  color: var(--silver);
}

.social-links a:hover {
  background: var(--gold);
  color: var(--midnight) !important;
  border-color: var(--gold);
  transform: translateY(-3px);
}

/* FAQ */
.faq-toggle {
  cursor: pointer;
}

.faq-body {
  transition: all 0.3s ease;
}

/* Hero */
.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.hero-bg-home { background-image: url('../assets/images/hero-home.jpg'); }
.hero-bg-door { background-image: url('../assets/images/hero-door.jpg'); }
.hero-bg-ceiling { background-image: url('../assets/images/hero-ceiling.jpg'); }
.hero-bg-foam { background-image: url('../assets/images/hero-foam.jpg'); }
.hero-bg-window { background-image: url('../assets/images/hero-window.jpg'); }
.hero-bg-interior { background-image: url('../assets/images/hero-interior.jpg'); }
.hero-bg-contact { background-image: url('../assets/images/hero-contact.jpg'); }

.hero-pulse {
  animation: pulse 15s ease-in-out infinite;
  background: radial-gradient(circle at 20% 50%, rgba(212,165,116,0.1) 0%, transparent 50%), radial-gradient(circle at 80% 50%, rgba(212,165,116,0.05) 0%, transparent 50%);
}

@keyframes pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* Modal */
#quoteModal {
  display: none;
}

#quoteModal.show {
  display: flex !important;
}

/* Gallery filter */
.filter-btn.active {
  background: var(--gold);
  color: white;
  border-color: var(--gold);
}

/* Service Hero */
.service-hero-img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: 16px;
}

/* Model Card */
.model-card {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(212, 175, 55, 0.1);
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.model-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(10, 14, 39, 0.1);
  border-color: var(--gold);
}

/* Responsive */
@media (max-width: 1024px) {
  .mega-menu {
    width: 100%;
    left: 0;
    transform: translateY(12px);
  }
  .group:hover .mega-menu {
    transform: translateY(6px);
  }
}

@media (max-width: 768px) {
  .portfolio-item {
    height: 300px;
  }
  .service-card {
    padding: 28px 20px;
  }
  .testimonial-card {
    padding: 28px 20px;
  }
  .trust-badge {
    padding: 24px 16px;
  }
  .feature-card {
    padding: 28px 20px;
  }
  .service-hero-img {
    height: 250px;
  }
  .process-step::before {
    display: none;
  }
  .gallery-item {
    height: 250px;
  }
  .gallery-item img {
    height: 100% !important;
    object-fit: cover;
  }
  #quoteModal > div {
    margin: 0 8px;
  }
  .social-links a {
    width: 36px;
    height: 36px;
  }
}

@media (max-width: 480px) {
  .btn-gold {
    padding: 12px 20px;
    font-size: 0.8rem;
  }
  .btn-outline-gold {
    padding: 10px 18px;
    font-size: 0.8rem;
  }
  h1 {
    font-size: 1.75rem !important;
  }
  h2 {
    font-size: 1.5rem !important;
  }
  .service-card ul {
    font-size: 0.8rem;
  }
  .service-card .btn-outline-gold {
    font-size: 0.75rem;
    padding: 8px 14px;
  }
  #mobileMenu {
    padding: 0 12px;
  }
}
