/* Cambridge Daycare Center - Custom Styles */

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

/* Base typography */
body {
  font-family: 'Quicksand', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Custom heading styles */
h1, h2, h3, h4 {
  font-family: 'Nunito', sans-serif;
}

/* Gradient hero background */
.hero-gradient {
  background: linear-gradient(135deg, #9a1e41 0%, #d43968 30%, #ff6b88 60%, #ff99aa 80%, #ffdee6 100%);
}

/* Decorative blob shapes */
.blob {
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
}

.blob-2 {
  border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
}

.blob-3 {
  border-radius: 40% 60% 60% 40% / 70% 30% 70% 30%;
}

/* Service card hover effects */
.service-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(154, 30, 65, 0.15);
}

/* CTA button pulse animation */
.cta-pulse {
  animation: pulse-soft 2s ease-in-out infinite;
}

@keyframes pulse-soft {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.03);
  }
}

/* Focus visible outlines */
:focus-visible {
  outline: 3px solid #d43968;
  outline-offset: 2px;
  border-radius: 4px;
}

/* Mobile menu */
.mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.mobile-menu.open {
  max-height: 400px;
}

/* Testimonial carousel */
.testimonial-track {
  display: flex;
  transition: transform 0.5s ease;
}

/* Floating shapes animation */
.float-1 {
  animation: float 6s ease-in-out infinite;
}

.float-2 {
  animation: float 8s ease-in-out infinite reverse;
}

.float-3 {
  animation: float 7s ease-in-out infinite 1s;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-20px) rotate(5deg);
  }
}

/* Scroll reveal animations - progressive enhancement */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
  }
  
  .reveal.visible {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Ensure content is visible without JS */
@media not all and (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* Print styles */
@media print {
  nav, .mobile-menu, .cta-pulse {
    display: none;
  }
  
  body {
    color: #000;
    background: #fff;
  }
}

/* High contrast mode support */
@media (forced-colors: active) {
  .service-card {
    border: 1px solid ButtonText;
  }
}

/* Reduced motion support */
@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;
  }
  
  .reveal {
    opacity: 1;
    transform: none;
  }
}

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

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

::-webkit-scrollbar-thumb {
  background: #d43968;
  border-radius: 5px;
}

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

/* Selection color */
::selection {
  background: #d43968;
  color: #fff;
}

/* Form input focus states */
input:focus,
textarea:focus,
select:focus {
  border-color: #d43968 !important;
  box-shadow: 0 0 0 3px rgba(212, 57, 104, 0.1) !important;
}

/* Smooth image loading */
img {
  transition: opacity 0.3s ease;
}

img[loading="lazy"] {
  opacity: 0;
}

img[loading="lazy"].loaded {
  opacity: 1;
}

/* Card shadow variants */
.shadow-soft {
  box-shadow: 0 4px 20px rgba(154, 30, 65, 0.08);
}

.shadow-medium {
  box-shadow: 0 8px 30px rgba(154, 30, 65, 0.12);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .hero-gradient {
    background: linear-gradient(180deg, #9a1e41 0%, #d43968 50%, #ff6b88 100%);
  }
}

/* Accessibility: skip to content */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: #9a1e41;
  color: #fff;
  padding: 8px;
  text-decoration: none;
  z-index: 100;
}

.skip-link:focus {
  top: 0;
}

/* Loading states */
.loading {
  opacity: 0.6;
  pointer-events: none;
}

/* Error states */
.error-state {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.error-message {
  color: #ef4444;
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

/* Success states */
.success-state {
  border-color: #22c55e !important;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1) !important;
}

/* Badge styles */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-burgundy {
  background-color: #fce7eb;
  color: #9a1e41;
}

.badge-cream {
  background-color: #fff0d6;
  color: #8a5418;
}

/* Divider styles */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, #fce7eb, transparent);
}
