/* ── Base & Utilities ── */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
}

::selection {
  background: rgba(201, 168, 76, 0.3);
  color: #f1f5f9;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #0a1219;
}

::-webkit-scrollbar-thumb {
  background: #1e3a4a;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #2d5a6a;
}

/* ── Navbar ── */
#navbar {
  transition: background-color 0.4s ease, box-shadow 0.4s ease, backdrop-filter 0.4s ease;
}

#navbar.scrolled {
  background: rgba(10, 18, 25, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 rgba(201, 168, 76, 0.08), 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* ── Hero Stat Cards ── */
.stat-card {
  animation: floatCard 6s ease-in-out infinite;
}

.card-1 {
  animation-delay: 0s;
}

.card-2 {
  animation-delay: -1.5s;
}

.card-3 {
  animation-delay: -3s;
}

.card-4 {
  animation-delay: -4.5s;
}

@keyframes floatCard {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-12px);
  }
}

/* ── Service Cards ── */
.service-card {
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(201, 168, 76, 0.4), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

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

/* ── Reveal Animations (progressive enhancement) ── */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .reveal.revealed {
    opacity: 1;
    transform: translateY(0);
  }

  .reveal:nth-child(2) { transition-delay: 0.1s; }
  .reveal:nth-child(3) { transition-delay: 0.2s; }
  .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Always visible for reduced motion or no-JS */
@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ── Mobile Menu ── */
#mobileMenu {
  animation: slideDown 0.3s ease;
}

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

.mobile-link {
  position: relative;
}

.mobile-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: linear-gradient(90deg, #c9a84c, transparent);
  transition: width 0.3s ease;
}

.mobile-link:hover::after {
  width: 100%;
}

/* ── Gallery Hover ── */
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
}

.gallery-item img {
  transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.gallery-item:hover img {
  transform: scale(1.05);
}

/* ── Button Focus States ── */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid #c9a84c;
  outline-offset: 2px;
}

/* ── Select Arrow ── */
select.appearance-none {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

/* ── Responsive ── */
@media (max-width: 767px) {
  .stat-card {
    display: none;
  }

  #hero {
    min-height: 100vh;
    min-height: 100dvh;
  }
}

/* ── Print ── */
@media print {
  body {
    background: white;
    color: black;
  }

  #navbar, #mobileMenu {
    display: none;
  }
}
