/* ─── Base & Utilities ─── */
html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
}

/* ─── Nav Links ─── */
.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: #d15226;
  border-radius: 1px;
  transition: width 0.25s ease;
}

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

/* ─── Mobile Menu Link ─── */
.mobile-link {
  border-radius: 0.75rem;
}

/* ─── Card Hover ─── */
.card-hover {
  transform: translateY(0);
}

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

/* ─── Scroll Reveal ─── */
.reveal {
  opacity: 1;
  transform: translateY(0);
  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);
}

/* Default visible state for reduced-motion / no-JS */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
  }

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

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

/* ─── Form Focus Ring Custom ─── */
input:focus,
select:focus,
textarea:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(209, 82, 38, 0.15);
}

/* ─── Custom Scrollbar ─── */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #fdf6eb;
}

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

::-webkit-scrollbar-thumb:hover {
  background: #b5401d;
}

/* ─── Selection ─── */
::selection {
  background: #f5c4b0;
  color: #77291b;
}

/* ─── Active Nav Highlight ─── */
.nav-link.active {
  color: #d15226;
}

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

/* ─── Select Arrow ─── */
select {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.75rem center;
  background-repeat: no-repeat;
  background-size: 1.25rem;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

/* ─── Smooth Anchor Offset ─── */
section[id] {
  scroll-margin-top: 5rem;
}
