/* ============================================
   Herboristería La Tila - Custom Styles
   ============================================ */

/* ============================================
   CSS Variables - Color Palette & Typography
   ============================================ */
:root {
  /* Primary Colors - Rosa vibrante */
  --color-pink: #D4698B;
  --color-dark-pink: #B85575;
  --color-light-pink: #E89BB5;
  
  /* Secondary Colors */
  --color-green: #8B9D83;
  --color-dark-green: #6B7D63;
  
  /* Neutral Colors */
  --color-cream: #F5F3EF;
  --color-white: #FFFFFF;
  --color-light-gray: #E8E6E1;
  --color-dark-gray: #4A4A4A;
  
  /* Accent Colors */
  --color-earth: #C9A87C;
  --color-mint: #A8C9A5;
  
  /* Typography */
  --font-heading: 'Playfair Display', serif;
  --font-body: 'Inter', sans-serif;
  
  /* Transitions */
  --transition-smooth: all 0.3s ease;
}

/* ============================================
   Base Styles
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--color-dark-gray);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
}

/* ============================================
   Utility Classes
   ============================================ */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* ============================================
   Custom Tailwind Configuration
   ============================================ */

/* ============================================
   Hero Section Styles
   ============================================ */
.hero {
  position: relative;
  overflow: hidden;
}

/* Background image with subtle blur effect - MOBILE */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url('../assets/images/mobilehero.jpg');
  background-size: cover;
  background-position: center;
  background-attachment: scroll; /* Scroll en móvil para mejor rendimiento */
  filter: blur(2px); /* Desenfoque suave */
  transform: scale(1.05); /* Prevent white edges from blur */
  z-index: 0;
}

/* Background image for DESKTOP (768px and up) */
@media (min-width: 768px) {
  .hero::before {
    background-image: url('../assets/images/hero.png');
    background-attachment: fixed; /* Parallax effect en desktop */
  }
}

/* Fallback background color if image fails to load */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-color: var(--color-pink);
  z-index: -1;
}

/* ============================================
   Header & Navigation Styles
   ============================================ */
#main-header {
  transition: var(--transition-smooth);
}

/* Scrolled state for header */
#main-header.scrolled {
  background-color: rgba(255, 255, 255, 0.98);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Mobile menu animation */
.mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease-out;
}

.mobile-menu.active {
  max-height: 500px;
  transition: max-height 0.4s ease-in;
}

/* Navigation link hover effect */
.nav-links a {
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-pink);
  transition: width 0.3s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

/* CTA Button styles */
.cta-button,
.cta-button-primary,
.cta-button-secondary {
  cursor: pointer;
  transition: var(--transition-smooth);
}

.cta-button:active,
.cta-button-primary:active,
.cta-button-secondary:active {
  transform: scale(0.98);
}

/* ============================================
   Focus States for Accessibility
   ============================================ */
/* Visible focus indicators for keyboard navigation */
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--color-pink);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Focus state for navigation links */
.nav-links a:focus-visible {
  outline-color: var(--color-pink);
  background-color: rgba(212, 105, 139, 0.1);
}

/* Focus state for buttons */
.cta-button:focus-visible,
.cta-button-primary:focus-visible,
.cta-button-secondary:focus-visible {
  outline: 3px solid var(--color-dark-pink);
  outline-offset: 3px;
}

/* Focus state for category cards */
.category-card:focus-visible {
  outline: 3px solid var(--color-pink);
  outline-offset: 4px;
}

/* Remove default focus outline but keep for keyboard users */
*:focus:not(:focus-visible) {
  outline: none;
}

/* ============================================
   Logo Styles
   ============================================ */
.logo img {
  max-height: 56px;
  height: auto;
  width: auto;
  object-fit: contain;
  transition: var(--transition-smooth);
}

/* Responsive logo sizing */
@media (max-width: 768px) {
  .logo img {
    max-height: 48px;
  }
  
  .logo span {
    font-size: 1.5rem; /* Texto más pequeño en móvil */
  }
}

/* Logo hover effect - subtle scale on image */
.logo a:hover img {
  transform: scale(1.05);
}

/* Logo text color transition on hover */
.logo a:hover span {
  color: #B85575;
  transition: color 0.3s ease;
}


/* ============================================
   Footer Styles
   ============================================ */
footer {
  background: linear-gradient(to bottom, #4A4A4A, #3A3A3A);
}

/* Footer links hover effect */
footer a {
  position: relative;
  display: inline-block;
}

footer a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--color-pink);
  transition: width 0.3s ease;
}

footer a:hover::after {
  width: 100%;
}

/* Social media icons hover effect */
footer .social-icon {
  transition: all 0.3s ease;
}

footer .social-icon:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(212, 105, 139, 0.3);
}

/* Footer responsive adjustments */
@media (max-width: 768px) {
  footer .grid {
    gap: 2rem;
  }
}
