/* Custom styles and overrides */
body {
  font-family: 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

/* Smooth scrolling for anchor links */
html {
  scroll-behavior: smooth;
}

/* Custom selection color */
::selection {
  background-color: #059669;
  color: #faf9f6;
}

/* Focus styles for accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid #059669;
  outline-offset: 2px;
}

/* Reduced motion preference */
@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;
  }
}

/* Print styles */
@media print {
  nav,
  #contact,
  footer {
    display: none;
  }
  
  body {
    color: #000;
    background: #fff;
  }
  
  .hero-gradient {
    background: #064e3b !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .btn-primary {
    border: 2px solid currentColor;
  }
}

/* Dark mode support (if system preference is set) */
@media (prefers-color-scheme: dark) {
  /* Additional dark mode styles can be added here */
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
  .card-hover:hover {
    transform: none;
    box-shadow: none;
  }
  
  .btn-primary:hover {
    transform: none;
    box-shadow: none;
  }
}

/* Ensure all interactive elements are large enough for touch */
button,
a,
input,
select,
textarea {
  min-height: 44px;
  min-width: 44px;
}

/* Improve readability on small screens */
@media (max-width: 640px) {
  h1 {
    font-size: 2.5rem;
    line-height: 1.1;
  }
  
  h2 {
    font-size: 2rem;
    line-height: 1.2;
  }
  
  .serif {
    font-size: 1.875rem;
  }
}

/* Better image rendering */
img {
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

/* Prevent text selection on non-selectable elements */
nav,
.hero-gradient {
  -webkit-user-select: none;
  user-select: none;
}

nav a,
nav button,
.hero-gradient a,
.hero-gradient button {
  -webkit-user-select: text;
  user-select: text;
}
