/* Custom styles extending Tailwind */

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

body.menu-open {
  overflow: hidden;
}

main {
  flex: 1;
}

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

/* Smooth transitions for interactive elements */
a,
button {
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

/* Form input transitions */
input,
textarea,
select {
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* Error state for form fields */
input.error,
textarea.error {
  border-color: #e03131;
  box-shadow: 0 0 0 3px rgba(224, 49, 49, 0.1);
}

input.success,
textarea.success {
  border-color: #2f9e44;
  box-shadow: 0 0 0 3px rgba(47, 158, 68, 0.1);
}

/* Mobile menu animation */
#mobile-menu {
  transition: opacity 0.3s ease;
  opacity: 0;
  pointer-events: none;
}

#mobile-menu.active {
  opacity: 1;
  pointer-events: auto;
}

#mobile-menu > div:last-child {
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobile-menu.active > div:last-child {
  transform: translateX(0);
}

/* Cookie banner animation */
#cookie-banner {
  animation: slideInUp 0.4s ease-out;
}

@keyframes slideInUp {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hero section decorative pattern */
.hero-pattern {
  background-image: radial-gradient(circle at 25% 50%, rgba(255,255,255,0.05) 0%, transparent 50%),
                    radial-gradient(circle at 75% 30%, rgba(255,255,255,0.04) 0%, transparent 40%);
}

/* Card hover lift effect */
.card-hover {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

/* FAQ accordion styles */
.faq-item {
  border-bottom: 1px solid #e9ecef;
}

.faq-item:last-child {
  border-bottom: none;
}

.faq-toggle {
  cursor: pointer;
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
}

.faq-answer.open {
  max-height: 500px;
}

.faq-icon {
  transition: transform 0.3s ease;
}

.faq-toggle[aria-expanded="true"] .faq-icon {
  transform: rotate(180deg);
}

/* Responsive typography adjustments */
@media (max-width: 640px) {
  h1 {
    font-size: 1.75rem;
    line-height: 1.3;
  }
  h2 {
    font-size: 1.5rem;
  }
}

/* Print styles */
@media print {
  header,
  footer,
  #cookie-banner,
  #mobile-menu {
    display: none !important;
  }
  body {
    font-size: 12pt;
    color: #000;
    background: #fff;
  }
  a {
    text-decoration: underline;
    color: #000;
  }
}

/* Selection color */
::selection {
  background-color: #bac8ff;
  color: #212529;
}

/* Scrollbar subtle styling */
::-webkit-scrollbar {
  width: 8px;
}

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

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

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