/* ============================================
   HEADER COMPONENT
   Diseño profesional para navegación ONG
   ============================================ */

/* Variables si no están definidas en otro lugar */
:root {
  /* Colores principales */
  --background: #ffffff;
  --foreground: #1a202c;
  --text-secondary: #4a5568;
  --text-muted: #718096;

  /* Colores de marca - Inspirados en África */
  --primary: #d97706;
  --primary-dark: #b45309;
  --primary-light: #fbbf24;
  --primary-lighter: #fef3c7;

  --secondary: #059669;
  --secondary-dark: #047857;
  --secondary-light: #34d399;

  --accent: #0284c7;
  --accent-dark: #0369a1;
  --accent-light: #38bdf8;

  /* Colores humanitarios */
  --humanitarian-red: #dc2626;
  --humanitarian-orange: #ea580c;
  --humanitarian-blue: #0284c7;
  --humanitarian-green: #059669;

  /* Colores de estado */
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --info: #3b82f6;

  /* Fondos */
  --bg-primary: #ffffff;
  --bg-secondary: #f9fafb;
  --bg-tertiary: #f3f4f6;
  --bg-dark: #1f2937;
  --bg-overlay: rgba(0, 0, 0, 0.5);

  /* Bordes */
  --border-light: #e5e7eb;
  --border-medium: #d1d5db;
  --border-dark: #9ca3af;

  /* Sombras */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

  /* Espaciado */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --spacing-3xl: 4rem;

  /* Radios de borde */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;

  /* Transiciones */
  --transition-fast: 150ms ease;
  --transition-base: 200ms ease;
  --transition-slow: 300ms ease;

  /* Z-index */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal-backdrop: 1040;
  --z-modal: 1050;
  --z-popover: 1060;
  --z-tooltip: 1070;
}

/* ============================================
   TIPOGRAFÍA
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-top: 0;
  color: var(--foreground);
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: 1.5rem;
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1.25rem;
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 1rem;
}

h4 {
  font-size: clamp(1.25rem, 2vw, 1.5rem);
  margin-bottom: 0.875rem;
}

p {
  margin-top: 0;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition-base);
}

a:hover {
  color: var(--primary-dark);
}

.header {
  background: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: all 0.3s ease;
}

.nav {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
}

.navContent {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  transition: transform 0.3s ease;
}

.logo:hover {
  transform: scale(1.02);
}

.logoIcon {
  width: 70px;
  height: 70px;
  background: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
  border: 2px solid #f0f0f0;
}

.logoIcon::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent, rgba(255, 255, 255, 0.3));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.logo:hover .logoIcon::before {
  opacity: 1;
}

.logoIcon span {
  color: white;
  font-weight: 800;
  font-size: 1.5rem;
  position: relative;
  z-index: 2;
}

.logoImage {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: relative;
  z-index: 2;
}

.logoText {
  font-size: 1.5rem;
  font-weight: 800;
  color: #1a202c;
  letter-spacing: -0.02em;
}

/* Navigation Links */
.navLinks {
  display: none;
  align-items: center;
  gap: 2rem;
}

@media (min-width: 768px) {
  .navLinks {
    display: flex;
  }
}

.navLink {
  color: #4a5568;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  position: relative;
  padding: 0.5rem 0;
  transition: color 0.3s ease;
}

.navLink::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #d97706, #dc2626);
  transition: width 0.3s ease;
}

.navLink:hover {
  color: #d97706;
}

.navLink:hover::after {
  width: 100%;
}

.adminButton {
  background: linear-gradient(135deg, #d97706, #ea580c);
  color: white;
  padding: 0.625rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.3);
  border: none;
  cursor: pointer;
}

.adminButton:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(217, 119, 6, 0.4);
  background: linear-gradient(135deg, #ea580c, #dc2626);
}

/* Mobile Menu */
.mobileMenuButton {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: transform 0.3s ease;
}

@media (min-width: 768px) {
  .mobileMenuButton {
    display: none;
  }
}

.mobileMenuButton:hover {
  transform: scale(1.1);
}

.hamburger {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.hamburgerLine {
  width: 24px;
  height: 3px;
  background: #d97706;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.mobileMenuButton.open .hamburgerLine:nth-child(1) {
  transform: rotate(45deg) translateY(7px);
}

.mobileMenuButton.open .hamburgerLine:nth-child(2) {
  opacity: 0;
}

.mobileMenuButton.open .hamburgerLine:nth-child(3) {
  transform: rotate(-45deg) translateY(-7px);
}

/* Mobile Menu Dropdown */
.mobileMenu {
  display: none;
  background: white;
  border-top: 1px solid #e5e7eb;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.mobileMenu.open {
  display: block;
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobileMenuContent {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mobileNavLink {
  color: #4a5568;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  padding: 1rem;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
  text-align: center;
}

.mobileNavLink:hover {
  background: #fef3c7;
  color: #d97706;
}

.mobileAdminButton {
  background: linear-gradient(135deg, #d97706, #ea580c);
  color: white;
  padding: 1rem;
  border-radius: 0.5rem;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: all 0.3s ease;
  margin-top: 0.5rem;
}

.mobileAdminButton:hover {
  background: linear-gradient(135deg, #ea580c, #dc2626);
  transform: scale(1.02);
}

/* Scroll Effect */
.header.scrolled {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}
