/* ============================================
   TROY'S TILE INC. — Custom Styles
   ============================================ */

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

body {
  font-family: 'DM Sans', system-ui, sans-serif;
}

.font-serif {
  font-family: 'Playfair Display', Georgia, serif;
}

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

#navbar.scrolled {
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 20px rgba(139, 26, 74, 0.08);
}

.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: #8B1A4A;
  transition: width 0.3s ease;
}

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

/* Hero Blobs */
.hero-blob {
  animation: blobFloat 8s ease-in-out infinite;
}

.hero-blob-1 {
  animation-delay: 0s;
}

.hero-blob-2 {
  animation-delay: -3s;
}

.hero-blob-3 {
  animation-delay: -5s;
}

@keyframes blobFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(20px, -20px) scale(1.05); }
  66% { transform: translate(-15px, 15px) scale(0.95); }
}

/* Service Cards */
.service-card {
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

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

/* Gallery Items */
.gallery-item {
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

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

.gallery-item img {
  transition: transform 0.7s ease;
}

/* Testimonial Cards */
.testimonial-card {
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}

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

/* Scroll Reveal Animations */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

/* Mobile Menu */
#mobile-menu {
  animation: slideDown 0.3s ease;
}

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

.mobile-link {
  display: block;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(139, 26, 74, 0.06);
}

.mobile-link:last-child {
  border-bottom: none;
}

/* Accent underline on serif em */
.font-serif em {
  font-style: italic;
}

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

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

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

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

/* Focus styles */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid #8B1A4A;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  html {
    scroll-behavior: auto;
  }
  
  .hero-blob {
    animation: none;
  }
}

/* Mobile responsive */
@media (max-width: 767px) {
  #navbar {
    padding-top: 0;
  }

  #navbar.scrolled {
    padding-top: 0;
  }
}
