/* Base & Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  overflow-x: hidden;
}

/* Clip paths */
.clip-diagonal {
  clip-path: polygon(30% 0%, 100% 0%, 100% 100%, 0% 100%);
}

/* Hero image */
#hero img {
  transition: transform 0.6s ease;
}

#hero:hover img {
  transform: scale(1.02);
}

/* Service cards */
.service-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
  transform: translateY(-4px);
}

/* Navbar */
#navbar {
  background: transparent;
  transition: background 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
}

#navbar.scrolled {
  background: rgba(139, 63, 37, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.15);
  padding: 0;
}

#navbar.scrolled .bg-nav {
  background: transparent;
}

/* Mobile menu */
#mobile-menu.active {
  opacity: 1;
  pointer-events: all;
}

#mobile-menu .mobile-link {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

#mobile-menu.active .mobile-link {
  opacity: 1;
  transform: translateY(0);
}

#mobile-menu.active .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.active .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.active .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.active .mobile-link:nth-child(4) { transition-delay: 0.25s; }

/* Menu button animation */
.menu-line.active:nth-child(1) {
  transform: rotate(45deg) translate(4px, 4px);
}

.menu-line.active:nth-child(2) {
  opacity: 0;
}

.menu-line.active:nth-child(3) {
  width: 5;
  transform: rotate(-45deg) translate(4px, -4px);
}

/* Scroll animations */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* Form inputs */
input:focus, select:focus, textarea:focus {
  outline: none;
}

/* Floating card animation */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.floating-card {
  animation: float 4s ease-in-out infinite;
}

/* Pulse dot */
@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.3); }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .clip-diagonal {
    clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
  }

  #hero {
    min-height: auto;
    padding-top: 100px;
    padding-bottom: 60px;
  }
}

/* Selection color */
::selection {
  background: #C4653A;
  color: #FDF8F0;
}
