/* Main CSS - Creative Consistency Webinar */

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

/* Body scroll lock for mobile menu */
body.menu-open {
  overflow: hidden;
}

/* Focus styles for accessibility */
*:focus-visible {
  outline: 2px solid #7C8B6F;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Minimum font size enforcement */
body {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Image defaults */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Selection color */
::selection {
  background-color: #7C8B6F;
  color: #ffffff;
}

/* Form input placeholder */
input::placeholder,
textarea::placeholder {
  color: #9CA3AF;
}

/* Form validation states */
input:invalid:not(:placeholder-shown):not(:focus) {
  border-color: #EF4444;
}

input:valid:not(:placeholder-shown) {
  border-color: #7C8B6F;
}

textarea:invalid:not(:placeholder-shown):not(:focus) {
  border-color: #EF4444;
}

textarea:valid:not(:placeholder-shown) {
  border-color: #7C8B6F;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
  background: #7C8B6F;
}

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

#mobile-menu.menu-visible {
  display: block;
  animation: fadeIn 0.3s ease;
}

#mobile-menu .absolute.inset-y-0 {
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

#mobile-menu.menu-visible .absolute.inset-y-0 {
  transform: translateX(0);
}

/* Cookie consent animation */
#cookie-consent {
  animation: slideUpCookie 0.4s ease-out;
}

@keyframes slideUpCookie {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Fade in animation */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Slide up animation */
@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

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

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

/* Link underline animation */
.link-underline {
  position: relative;
  text-decoration: none;
}

.link-underline::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #7C8B6F;
  transition: width 0.3s ease;
}

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

/* FAQ accordion styles */
.faq-item .faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

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

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

.faq-item.open .faq-icon {
  transform: rotate(180deg);
}

/* Success message animation */
.success-animate {
  animation: successPulse 0.6s ease;
}

@keyframes successPulse {
  0% { transform: scale(0.9); opacity: 0; }
  50% { transform: scale(1.02); }
  100% { transform: scale(1); opacity: 1; }
}

/* Print styles */
@media print {
  header, footer, #cookie-consent, #mobile-menu {
    display: none !important;
  }
  body {
    background: white;
    color: black;
  }
}

/* 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;
  }
}