/* Global smooth scrolling. The JavaScript also handles anchors for consistent behavior. */
html {
  scroll-behavior: smooth;
}

/* Offset anchored sections below the sticky navigation. */
section {
  scroll-margin-top: 88px;
}

/* Improve type rendering on supported systems. */
body {
  text-rendering: optimizeLegibility;
}

/* Featured hero logo treatment. */
.hero-logo-card {
  align-items: center;
  background: rgba(248, 246, 242, 0.94);
  border: 1px solid rgba(216, 203, 183, 0.72);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.24);
  display: flex;
  justify-content: center;
  justify-self: center;
  max-width: 25rem;
  padding: clamp(1rem, 3vw, 1.75rem);
  width: min(100%, 25rem);
}

.hero-logo {
  display: block;
  height: auto;
  object-fit: cover;
  width: 100%;
}

@media (max-width: 1023px) {
  .hero-logo-card {
    max-width: 16rem;
    order: -1;
  }
}

/* Reusable desktop navigation link styling. */
.nav-link {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  transition: color 180ms ease;
}

.nav-link:hover {
  color: #ffffff;
}

/* Reusable mobile navigation link styling. */
.mobile-link {
  color: rgba(255, 255, 255, 0.84);
  padding: 0.75rem 0;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* Section eyebrow labels. */
.section-kicker {
  color: #b87444;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

/* Section headings. */
.section-title {
  color: #234034;
  font-family: "Playfair Display", serif;
  font-size: clamp(2.25rem, 5vw, 4.5rem);
  font-weight: 600;
  line-height: 1.05;
}

/* Service card interaction. */
.service-card {
  background: #ffffff;
  border: 1px solid rgba(35, 64, 52, 0.1);
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 60px rgba(35, 64, 52, 0.12);
}

/* Contact form layout and focus states. */
.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.form-field span {
  color: #234034;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  border: 1px solid rgba(35, 64, 52, 0.18);
  background: #ffffff;
  color: #2b2b2b;
  padding: 0.95rem 1rem;
  font: inherit;
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.form-field textarea {
  resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: #b87444;
  box-shadow: 0 0 0 3px rgba(184, 116, 68, 0.16);
}

/* Mobile hamburger icon. */
.menu-icon,
.menu-icon::before,
.menu-icon::after {
  display: block;
  width: 18px;
  height: 2px;
  background: #ffffff;
  transition: transform 180ms ease, opacity 180ms ease;
}

.menu-icon {
  position: relative;
}

.menu-icon::before,
.menu-icon::after {
  content: "";
  left: 0;
  position: absolute;
}

.menu-icon::before {
  top: -6px;
}

.menu-icon::after {
  top: 6px;
}

/* Hamburger active state. */
.menu-open .menu-icon {
  background: transparent;
}

.menu-open .menu-icon::before {
  transform: translateY(6px) rotate(45deg);
}

.menu-open .menu-icon::after {
  transform: translateY(-6px) rotate(-45deg);
}

/* Subtle hero entrance animation. */
.animate-fade-up {
  animation: fadeUp 900ms ease both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Respect users who prefer reduced motion. */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
