/* ==========================================================================
   Header y Navegación
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}

.top-bar {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: var(--white);
  padding: 0.75rem 0;
  font-size: 0.875rem;
}

.top-bar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.top-bar-left,
.top-bar-right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.top-bar-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--white);
  transition: opacity var(--transition-fast);
}

.top-bar-item:hover {
  opacity: 0.8;
  color: var(--white);
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-link {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  color: var(--white);
  transition: all var(--transition-normal);
}

.social-link:hover {
  background: var(--white);
  color: var(--primary-color);
  transform: translateY(-2px);
}

.main-navigation {
  padding: 1rem 0;
}

.nav-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
}

.site-branding {
  flex-shrink: 0;
}

.site-title {
  margin: 0;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-color);
}

.site-title a {
  color: inherit;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.custom-logo-link {
  display: block;
  max-width: 200px;
}

.custom-logo {
  height: auto;
  max-height: 60px;
}

.nav-menu-wrapper {
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-grow: 1;
  justify-content: flex-end;
}

.nav-menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 2rem;
}

.nav-menu li {
  position: relative;
}

.nav-menu a {
  display: block;
  padding: 0.5rem 0;
  color: var(--dark-color);
  font-weight: 500;
  position: relative;
  transition: color var(--transition-fast);
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  transition: width var(--transition-normal);
}

.nav-menu a:hover {
  color: var(--primary-color);
}

.nav-menu a:hover::after,
.nav-menu .current-menu-item a::after {
  width: 100%;
}

.nav-cta {
  white-space: nowrap;
  font-size: 0.9rem;
  padding: 0.75rem 1.5rem;
}

.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
}

.mobile-menu-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background: var(--primary-color);
  border-radius: 3px;
  transition: all var(--transition-normal);
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--dark-color);
  color: var(--light-color);
}

.footer-main {
  padding: var(--spacing-xl) 0 var(--spacing-lg);
}

.footer-widgets {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: var(--spacing-lg);
}

.footer-about {
  max-width: 400px;
}

.footer-doctor-name {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.footer-widget-column .widget {
  margin-bottom: var(--spacing-md);
}

.footer-widget-column h4 {
  color: var(--white);
  margin-bottom: var(--spacing-sm);
  font-size: 1.25rem;
  position: relative;
  padding-bottom: 0.75rem;
}

.footer-widget-column h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 50px;
  height: 3px;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.footer-widget-column p {
  line-height: 1.8;
  color: var(--light-color);
  opacity: 0.9;
}

.footer-widget-column ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-widget-column ul li {
  margin-bottom: 0.75rem;
}

.footer-widget-column ul li a {
  color: var(--light-color);
  transition: all var(--transition-fast);
  display: inline-block;
  position: relative;
}

.footer-widget-column ul li a::before {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--secondary-color);
  transition: width var(--transition-fast);
}

.footer-widget-column ul li a:hover {
  color: var(--secondary-color);
  padding-left: 8px;
}

.footer-widget-column ul li a:hover::before {
  width: 100%;
}

.contact-info li {
  margin-bottom: 1rem;
  line-height: 1.6;
}

.contact-info strong {
  color: var(--white);
  display: block;
  margin-bottom: 0.25rem;
}

.footer-bottom {
  background: rgba(0, 0, 0, 0.3);
  padding: 1.5rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.copyright {
  margin: 0;
  font-size: 0.9rem;
  opacity: 0.8;
}

.footer-nav {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 1.5rem;
}

.footer-nav a {
  color: var(--light-color);
  font-size: 0.9rem;
}

.footer-nav a:hover {
  color: var(--secondary-color);
}

/* ==========================================================================
   Cards y Componentes
   ========================================================================== */
.card {
  background: var(--white);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-xl);
}

.card-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.card:hover .card-image {
  transform: scale(1.1);
}

.card-content {
  padding: var(--spacing-md);
}

.card-title {
  font-size: 1.5rem;
  margin-bottom: var(--spacing-sm);
  color: var(--dark-color);
}

.card-text {
  color: #666;
  line-height: 1.6;
  margin-bottom: var(--spacing-sm);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  overflow: hidden;
}

/* Video de fondo */
.hero-video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translateX(-50%) translateY(-50%);
  z-index: 0;
  object-fit: cover;
}

/* Overlay semi-transparente azul */
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(0, 102, 204, 0.85), rgba(0, 184, 212, 0.85));
  z-index: 1;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="rgba(255,255,255,0.1)" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,138.7C960,139,1056,117,1152,101.3C1248,85,1344,75,1392,69.3L1440,64L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>');
  background-size: cover;
  background-position: bottom;
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  color: var(--white);
  max-width: 800px;
}

.hero-title {
  font-size: 3.5rem;
  margin-bottom: var(--spacing-md);
  animation: fadeInUp 0.8s ease;
}

.hero-subtitle {
  font-size: 1.5rem;
  margin-bottom: var(--spacing-lg);
  opacity: 0.95;
  animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease 0.4s both;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .nav-menu {
    gap: 1.5rem;
  }

  .nav-menu a {
    font-size: 0.95rem;
  }
}

@media (max-width: 768px) {
  .top-bar-content {
    font-size: 0.8rem;
  }

  .top-bar-left,
  .top-bar-right {
    gap: 1rem;
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .nav-menu-wrapper {
    position: fixed;
    top: 0;
    left: -100%;
    width: 80%;
    max-width: 300px;
    height: 100vh;
    background: var(--white);
    box-shadow: var(--shadow-xl);
    flex-direction: column;
    justify-content: flex-start;
    padding: var(--spacing-lg);
    transition: left var(--transition-normal);
    overflow-y: auto;
  }

  .nav-menu-wrapper.active {
    left: 0;
  }

  .nav-menu {
    flex-direction: column;
    gap: 0;
    width: 100%;
  }

  .nav-menu li {
    width: 100%;
    border-bottom: 1px solid #eee;
  }

  .nav-menu a {
    padding: 1rem 0;
  }

  .nav-cta {
    width: 100%;
    text-align: center;
    margin-top: var(--spacing-sm);
  }

  .hero-title {
    font-size: 2.5rem;
  }

  .hero-subtitle {
    font-size: 1.2rem;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .footer-widgets {
    grid-template-columns: 1fr;
  }

  .footer-about {
    max-width: 100%;
  }

  .footer-doctor-name {
    font-size: 2rem;
  }

  .footer-bottom-content {
    flex-direction: column;
    text-align: center;
  }

  .footer-nav {
    flex-direction: column;
    gap: 0.5rem;
  }
}

@media (max-width: 480px) {
  .top-bar-left,
  .top-bar-right {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .social-links {
    margin-top: 0.5rem;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1rem;
  }
}

/* ==========================================================================
   Loading y Efectos
   ========================================================================== */
.loading {
  position: relative;
  pointer-events: none;
  opacity: 0.6;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 40px;
  height: 40px;
  margin: -20px 0 0 -20px;
  border: 4px solid var(--light-color);
  border-top-color: var(--primary-color);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Parallax effect */
.parallax {
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

/* Gradient text */
.gradient-text {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Pulse animation */
@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.pulse {
  animation: pulse 2s ease-in-out infinite;
}

/* ========================================
   Sección de Valores y Compromiso
   ======================================== */

.values-section {
  background: var(--light-color);
}

.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
  margin-top: var(--spacing-xl);
}

.value-card {
  background: var(--white);
  padding: 2.5rem 2rem;
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  transition: all var(--transition-base);
  text-align: center;
  border: 2px solid transparent;
}

.value-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 102, 204, 0.15);
  border-color: var(--primary-color);
}

.value-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: 50%;
  color: var(--white);
  transition: all var(--transition-base);
}

.value-card:hover .value-icon {
  transform: rotateY(360deg);
  background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
}

.value-card h3 {
  color: var(--dark-color);
  margin-bottom: 1rem;
  font-size: 1.35rem;
  font-weight: 700;
}

.value-card p {
  color: #666;
  line-height: 1.8;
  font-size: 0.95rem;
}

/* Responsive ajustes */
@media (max-width: 768px) {
  .values-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .value-card {
    padding: 2rem 1.5rem;
  }

  .value-icon {
    width: 70px;
    height: 70px;
  }
}
