/* Custom CSS for Clínica Geriátrica Sol */

/* Import Google Fonts - Playfair Display for elegant titles */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700;800&family=Crimson+Text:ital,wght@0,400;0,600;1,400&display=swap');

/* Color Variables */
:root {
  --primary-color: #2585c7;
  --secondary-color: #f7c348;
  --primary-dark: #1e6ca0;
  --secondary-dark: #d4a63a;
  --text-dark: #333;
  --text-muted: #666;
  --light-bg: #f8f9fa;
  --white: #ffffff;
  --shadow: rgba(0, 0, 0, 0.1);
  --gradient-primary: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
  --gradient-secondary: linear-gradient(135deg, var(--secondary-color), var(--secondary-dark));
}

/* Global Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Crimson Text', Georgia, serif;
  line-height: 1.6;
  color: var(--text-dark);
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 1rem;
  letter-spacing: -0.5px;
}

h1 {
  font-size: 2.5rem;
  line-height: 1.1;
  font-weight: 700;
}

h2 {
  font-size: 2.2rem;
  color: var(--primary-color);
  font-weight: 600;
}

h3 {
  font-size: 1.8rem;
  color: var(--text-dark);
  font-weight: 500;
}

p {
  line-height: 1.7;
  margin-bottom: 1rem;
  font-size: 1.05rem;
}

/* Navigation */
.navbar {
  transition: all 0.3s ease;
  padding: 0.2rem 0;
}

.navbar-scrolled {
  background-color: var(--white) !important;
  box-shadow: 0 2px 10px var(--shadow);
}

.navbar-brand img {
  transition: all 0.3s ease;
}

.navbar-nav .nav-link {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 400;
  color: var(--text-dark) !important;
  margin: 0 0.5rem;
  padding: 0.5rem 1rem !important;
  border-radius: 25px;
  transition: all 0.3s ease;
  position: relative;
}

.navbar-nav .nav-link:hover {
  background-color: var(--primary-color);
  color: var(--white) !important;
  transform: translateY(-2px);
}

.navbar-nav .nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--secondary-color);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.navbar-nav .nav-link:hover::after {
  width: 80%;
}

/* Hero Section */
.hero-section {
  min-height: 100vh;
  background: linear-gradient(rgba(37, 133, 199, 0.8), rgba(30, 108, 160, 0.9)), 
              url('../img/bg-hero.jpeg') center/cover no-repeat;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(37, 133, 199, 0) 0%, rgba(247, 195, 72, 0.5) 100%)
  z-index: 1;
}

.hero-section .container {
  position: relative;
  z-index: 2;
}

.hero-title {
  font-size: 3rem;
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  margin-bottom: 1.5rem;
  animation: fadeInUp 1s ease-out;
  letter-spacing: -1px;
}

.hero-subtitle {
  font-size: 1.25rem;
  font-weight: 400;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
  margin-bottom: 2rem;
  animation: fadeInUp 1s ease-out 0.3s both;
  font-family: 'Crimson Text', Georgia, serif;
}

.hero-buttons {
  animation: fadeInUp 1s ease-out 0.6s both;
}

/* Buttons */
.btn {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 500;
  padding: 12px 30px;
  border-radius: 8px;
  border: none;
  transition: all 0.3s ease;
  letter-spacing: 0.3px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: all 0.5s;
}

.btn:hover::before {
  left: 100%;
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--white);
  box-shadow: 0 4px 15px rgba(37, 133, 199, 0.3);
}

.btn-primary:hover {
  background: var(--gradient-primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 133, 199, 0.4);
}

.btn-secondary {
  background: var(--gradient-secondary);
  color: var(--text-dark);
  box-shadow: 0 4px 15px rgba(247, 195, 72, 0.3);
}

.btn-secondary:hover {
  background: var(--gradient-secondary);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(247, 195, 72, 0.4);
  color: var(--text-dark);
}

/* Section Styles */
section {
  padding: 80px 0;
}

.section-title {
  font-size: 2.5rem;
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 1rem;
  position: relative;
  letter-spacing: -0.5px;
}

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  margin-bottom: 3rem;
  font-style: italic;
}

.section-divider {
  width: 80px;
  height: 4px;
  background: var(--primary-color);
  margin: 0 auto 3rem;
  border-radius: 0;
}

/* Institucional Section */
.institucional-content h3 {
  color: var(--primary-color);
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  font-family: 'Playfair Display', Georgia, serif;
}

.institucional-content p {
  font-size: 1.05rem;
  line-height: 1.8;
  text-align: justify;
  font-family: 'Crimson Text', Georgia, serif;
}

/* Recursos Cards */
.recurso-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.08);
  border: 1px solid #e8e8e8;
  transition: all 0.3s ease;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.recurso-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 4px;
  background: var(--gradient-primary);
  transition: all 0.3s ease;
}

.recurso-card:hover::before {
  left: 0;
}

.recurso-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 8px 25px rgba(37, 133, 199, 0.15);
}

.recurso-icon {
  width: 80px;
  height: 80px;
  background: var(--primary-color);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  transition: all 0.3s ease;
}

.recurso-card:hover .recurso-icon {
  background: var(--secondary-color);
  transform: scale(1.1);
}

.recurso-icon i {
  font-size: 2rem;
  color: var(--white);
}

.recurso-card h4 {
  font-size: 1.3rem;
  font-family: 'Playfair Display', Georgia, serif;
  color: var(--primary-color);
  margin-bottom: 1rem;
  font-weight: 500;
}

.recurso-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0;
  font-family: 'Crimson Text', Georgia, serif;
}

/* Gallery */
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  cursor: pointer;
  border: 2px solid #f0f0f0;
}

.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border-color: var(--primary-color);
}

.gallery-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  transition: all 0.3s ease;
}

.gallery-item:hover .gallery-img {
  transform: scale(1.1);
}

/* Footer */
.footer {
  background: var(--text-dark);
  padding: 4rem 0 2rem;
}

.footer-logo {
  filter: brightness(0) invert(1);
}

.footer h5 {
  color: var(--secondary-color);
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.3rem;
  margin-bottom: 1.5rem;
  font-weight: 500;
}

.footer p {
  color: #ccc;
  line-height: 1.7;
  font-family: 'Crimson Text', Georgia, serif;
}

.contact-info p {
  margin-bottom: 0.8rem;
  display: flex;
  align-items: flex-start;
}

.contact-info i {
  color: var(--secondary-color);
  margin-right: 0.5rem;
  margin-top: 0.2rem;
  min-width: 20px;
}

.footer ul li {
  margin-bottom: 0.5rem;
  transition: all 0.3s ease;
}

.footer ul li:hover {
  transform: translateX(5px);
}

.footer ul li a:hover {
  color: var(--secondary-color) !important;
}

/* WhatsApp Float Button */
.whatsapp-float {
  position: fixed;
  width: auto;
  height: auto;
  padding: 15px 20px;
  bottom: 30px;
  right: 30px;
  background: #25d366;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.3);
  z-index: 1000;
  animation: pulse 2s infinite;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--white);
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 500;
  font-size: 0.9rem;
  white-space: nowrap;
}

.whatsapp-float:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 25px rgba(37, 211, 102, 0.5);
  color: var(--white);
  text-decoration: none;
}

.whatsapp-float i {
  font-size: 1.5rem;
  margin-right: 8px;
}

/* WhatsApp Menu Pill */
.whatsapp-pill {
  background: #25d366;
  color: var(--white) !important;
  padding: 8px 15px;
  border-radius: 25px;
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  margin-left: 1rem;
}

.whatsapp-pill:hover {
  background: #1fb854;
  color: var(--white) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.whatsapp-pill i {
  margin-right: 5px;
  font-size: 1rem;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero-title {
    font-size: 2rem;
  }
  
  .hero-subtitle {
    font-size: 1.1rem;
  }
  
  .section-title {
    font-size: 2rem;
  }
  
  .hero-buttons .btn {
    display: block;
    margin: 0.5rem 0;
    width: 100%;
  }
  
  .recurso-card {
    padding: 2rem;
    margin-bottom: 1.5rem;
  }
  
  .whatsapp-float {
    padding: 12px 15px;
    bottom: 20px;
    right: 20px;
    font-size: 0.8rem;
  }
  
  .whatsapp-float i {
    font-size: 1.3rem;
    margin-right: 6px;
  }
  
  .whatsapp-pill {
    margin-left: 0.5rem;
    padding: 6px 12px;
    font-size: 0.8rem;
  }

  section {
    padding: 60px 0;
  }
}

@media (max-width: 576px) {
  .hero-title {
    font-size: 1.6rem;
  }
  
  .hero-subtitle {
    font-size: 1rem;
  }
  
  .section-title {
    font-size: 1.6rem;
  }
  
  .btn {
    padding: 10px 20px;
    font-size: 0.9rem;
  }
  
  .recurso-card {
    padding: 1.5rem;
  }
  
  .gallery-img {
    height: 250px;
  }

  .whatsapp-float {
    padding: 10px 12px;
    font-size: 0.75rem;
  }

  .whatsapp-float i {
    font-size: 1.2rem;
    margin-right: 5px;
  }

  .whatsapp-pill {
    display: none;
  }
}

/* Logo size adjustments */
.navbar-brand img {
  height: 90px !important;
  transition: all 0.3s ease;
}

.footer-logo {
  height: 90px !important;
  filter: brightness(0) invert(1);
}

@media (max-width: 768px) {
  .navbar-brand img {
    height: 70px !important;
  }
  
  .footer-logo {
    height: 70px !important;
  }
}

/* Loading Animation */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  html {
    scroll-behavior: auto;
  }
}

/* Print Styles */
@media print {
  .navbar,
  .whatsapp-float,
  .hero-buttons {
    display: none !important;
  }
  
  .hero-section {
    background: var(--white) !important;
    color: var(--text-dark) !important;
    min-height: auto;
  }
  
  * {
    box-shadow: none !important;
  }
}