:root {
  --primary-color: #2563eb;
  --secondary-color: #10b981;
  --accent-color: #f59e0b;
  --text-color: #1e293b;
  --light-text: #64748b;
  --background-color: #f8fafc;
  --card-background: #ffffff;
  --border-color: #e2e8f0;
  --footer-background: #0f172a;
  --footer-text: #e2e8f0;
  --success-color: #10b981;
  --error-color: #ef4444;
  --transition: all 0.3s ease;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
  --radius: 8px;
  --radius-lg: 12px;
}

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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text-color);
  background-color: var(--background-color);
}

/* Barra de progreso */
.progress-container {
  position: fixed;
  top: 0;
  z-index: 1000;
  width: 100%;
  height: 4px;
  background: transparent;
}

.progress-bar {
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  width: 0%;
  transition: width 0.2s ease;
}

/* Navegación */
.navbar {
  background-color: var(--card-background);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}

.logo img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

.logo span {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary-color);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 1.5rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 500;
  transition: var(--transition);
}

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

.nav-links a.active {
  color: var(--primary-color);
}

.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
}

.bar {
  width: 25px;
  height: 3px;
  background-color: var(--text-color);
  transition: var(--transition);
}

/* Hero Section */
.hero {
  background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('images/1.jpg');
  background-size: cover;
  background-position: center;
  color: white;
  text-align: center;
  padding: 6rem 0;
  position: relative;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1rem;
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.hero p {
  font-size: 1.2rem;
  margin-bottom: 2rem;
}

.btn {
  display: inline-block;
  background-color: var(--primary-color);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 600;
  transition: var(--transition);
  border: none;
  cursor: pointer;
}

.btn:hover {
  background-color: #1d4ed8;
  transform: translateY(-2px);
}

.btn-secondary {
  background-color: var(--secondary-color);
}

.btn-secondary:hover {
  background-color: #059669;
}

.btn-outline {
  background-color: transparent;
  border: 2px solid white;
}

.btn-outline:hover {
  background-color: white;
  color: var(--primary-color);
}

/* Secciones */
.section {
  padding: 5rem 0;
}

.section-title {
  font-size: 2.2rem;
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 80px;
  height: 4px;
  background: var(--primary-color);
  margin: 0.5rem auto 0;
}

/* Tarjetas de blog */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}

.card {
  background: var(--card-background);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

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

.card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.card-content {
  padding: 1.5rem;
}

.card-tag {
  display: inline-block;
  background-color: var(--secondary-color);
  color: white;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
  margin-bottom: 1rem;
}

.card h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.card p {
  margin-bottom: 1.5rem;
  color: var(--light-text);
}

.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

.card-date {
  display: flex;
  align-items: center;
  font-size: 0.9rem;
  color: var(--light-text);
}

.card-date svg {
  margin-right: 5px;
}

.read-more {
  color: var(--primary-color);
  font-weight: 600;
  text-decoration: none;
  display: flex;
  align-items: center;
}

.read-more:hover {
  text-decoration: underline;
}

/* Timeline */
.timeline-container {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
}

.timeline-container::after {
  content: '';
  position: absolute;
  width: 4px;
  background-color: var(--border-color);
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -2px;
}

.timeline-item {
  padding: 10px 40px;
  position: relative;
  width: 50%;
  box-sizing: border-box;
}

.timeline-item::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  right: -12px;
  background-color: var(--card-background);
  border: 4px solid var(--primary-color);
  top: 15px;
  border-radius: 50%;
  z-index: 1;
}

.timeline-item:nth-child(odd) {
  left: 0;
}

.timeline-item:nth-child(even) {
  left: 50%;
}

.timeline-item:nth-child(even)::after {
  left: -12px;
}

.timeline-content {
  padding: 20px;
  background-color: var(--card-background);
  position: relative;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.timeline-date {
  color: var(--accent-color);
  font-weight: bold;
}

/* Formulario de contacto */
.contact-form {
  max-width: 600px;
  margin: 0 auto;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.form-control {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  font-size: 1rem;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}

textarea.form-control {
  min-height: 150px;
}

/* Información de contacto */
.contact-info {
  background-color: var(--card-background);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.contact-info h3 {
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

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

.contact-info-item svg {
  margin-right: 1rem;
  color: var(--primary-color);
  flex-shrink: 0;
}

/* Equipo */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 2rem;
}

.team-card {
  background: var(--card-background);
  border-radius: var(--radius);
  overflow: hidden;
  text-align: center;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.team-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.team-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.team-info {
  padding: 1.5rem;
}

.team-info h3 {
  margin-bottom: 0.5rem;
}

.team-info p {
  color: var(--light-text);
  margin-bottom: 1rem;
}

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

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: #f1f5f9;
  transition: var(--transition);
}

.social-links a:hover {
  background-color: var(--primary-color);
  color: white;
}

/* Artículo de blog */
.post-header {
  text-align: center;
  margin-bottom: 3rem;
}

.post-meta {
  color: var(--light-text);
  margin-bottom: 1rem;
}

.post-featured-img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 2rem;
}

.post-content {
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.8;
}

.post-content h2 {
  margin: 2rem 0 1rem;
}

.post-content p {
  margin-bottom: 1.5rem;
}

.post-content ul, .post-content ol {
  margin-bottom: 1.5rem;
  margin-left: 2rem;
}

.post-content img {
  max-width: 100%;
  border-radius: var(--radius);
  margin: 1.5rem 0;
}

.post-footer {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.post-tag {
  background-color: #f1f5f9;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  font-size: 0.9rem;
  color: var(--light-text);
}

.share-buttons {
  display: flex;
  gap: 1rem;
}

.share-button {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: #f1f5f9;
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  color: var(--text-color);
  text-decoration: none;
  transition: var(--transition);
}

.share-button:hover {
  background-color: var(--primary-color);
  color: white;
}

/* Related posts */
.related-posts {
  margin-top: 3rem;
}

.related-posts h3 {
  margin-bottom: 1.5rem;
}

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

.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.footer-widget h4 {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.footer-widget h4::after {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background: var(--accent-color);
  margin-top: 0.8rem;
}

.footer-widget ul {
  list-style: none;
}

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

.footer-widget ul li a {
  color: var(--footer-text);
  text-decoration: none;
  transition: var(--transition);
}

.footer-widget ul li a:hover {
  color: var(--accent-color);
  padding-left: 5px;
}

.footer-widget p {
  margin-bottom: 1rem;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
  color: #94a3b8;
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: var(--card-background);
  padding: 1.5rem;
  z-index: 1000;
  box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  transform: translateY(100%);
  transition: transform 0.5s ease-in-out;
}

.cookie-banner.show {
  transform: translateY(0);
}

.cookie-text {
  flex: 1;
  min-width: 300px;
}

.cookie-text h3 {
  margin-bottom: 0.5rem;
}

.cookie-buttons {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
}

/* Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease-in-out;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background-color: var(--card-background);
  width: 90%;
  max-width: 500px;
  border-radius: var(--radius);
  padding: 2rem;
  position: relative;
  transform: translateY(20px);
  transition: all 0.3s ease-in-out;
}

.modal-overlay.active .modal {
  transform: translateY(0);
}

.close-modal {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 1.5rem;
  cursor: pointer;
  background: none;
  border: none;
  color: var(--light-text);
}

.modal-icon {
  display: flex;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.modal-icon svg {
  font-size: 4rem;
  color: var(--success-color);
}

.modal h3 {
  text-align: center;
  margin-bottom: 1rem;
}

.modal p {
  text-align: center;
  margin-bottom: 1.5rem;
}

/* Responsive */
@media (max-width: 768px) {
  .navbar .container {
    flex-wrap: wrap;
  }
  
  .menu-toggle {
    display: flex;
  }
  
  .nav-links {
    flex-basis: 100%;
    flex-direction: column;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }
  
  .nav-links.active {
    max-height: 300px;
  }
  
  .hero h1 {
    font-size: 2.5rem;
  }
  
  .timeline-container::after {
    left: 31px;
  }
  
  .timeline-item {
    width: 100%;
    padding-left: 70px;
    padding-right: 25px;
  }
  
  .timeline-item::after {
    left: 20px;
  }
  
  .timeline-item:nth-child(even) {
    left: 0;
  }
  
  .timeline-item:nth-child(even)::after {
    left: 20px;
  }
  
  .contact-info {
    margin-top: 2rem;
  }
}
