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

:root {
  --primary: #1a3981;
  --secondary: #295acd;
  --success: #ddbd34;
  --warning: #f59e0b;
  --danger: #ef4444;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-600: #4b5563;
  --gray-800: #1f2937;
  --gray-900: #111827;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  padding: 20px;
  color: var(--gray-800);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  background: white;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  padding: 40px;
  animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

header {
  text-align: center;
  margin-bottom: 40px;
  padding-bottom: 30px;
  border-bottom: 3px solid var(--gray-200);
}

.logo {
  max-width: 100px;
  height: auto;
  margin: 0 auto 20px;
  display: block;
}

h1 {
  font-size: 2.5rem;
  color: var(--gray-900);
  margin-bottom: 10px;
  font-weight: 700;
}

.subtitle {
  color: var(--gray-600);
  font-size: 1.1rem;
  margin-top: 10px;
}

.view-badge {
  display: inline-block;
  padding: 8px 20px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  margin-top: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-links {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}

.nav-links a {
  padding: 12px 24px;
  background: white;
  color: var(--primary);
  text-decoration: none;
  border-radius: 10px;
  border: 2px solid var(--primary);
  font-weight: 600;
  transition: all 0.3s ease;
}

.nav-links a:hover {
  background: var(--primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(37, 99, 235, 0.3);
}

.timeline {
  position: relative;
  padding: 20px 0;
}

.day-section {
  margin-bottom: 60px;
  position: relative;
}

.day-header {
  display: flex;
  align-items: center;
  margin-bottom: 30px;
  position: sticky;
  top: 0;
  background: white;
  padding: 15px 0;
  z-index: 10;
}

.day-number {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.5rem;
  font-weight: 700;
  margin-right: 20px;
  box-shadow: 0 5px 15px rgba(37, 99, 235, 0.3);
}

.day-title {
  font-size: 2rem;
  font-weight: 700;
  color: var(--gray-900);
}

.events-list {
  position: relative;
  padding-left: 50px;
}

.events-list::before {
  content: '';
  position: absolute;
  left: 15px;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, var(--primary), var(--secondary));
  border-radius: 2px;
}

.event-card {
  position: relative;
  background: white;
  border: 2px solid var(--gray-200);
  border-radius: 15px;
  padding: 20px;
  margin-bottom: 20px;
  margin-left: 30px;
  transition: all 0.3s ease;
  animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.event-card:hover {
  transform: translateX(5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  border-color: var(--primary);
}

.event-card::before {
  content: '';
  position: absolute;
  left: -42px;
  top: 25px;
  width: 16px;
  height: 16px;
  background: white;
  border: 4px solid var(--primary);
  border-radius: 50%;
  box-shadow: 0 0 0 4px white;
}

.event-tipo-curso::before {
  border-color: var(--success);
}

.event-tipo-evento::before {
  border-color: var(--warning);
}

.event-tipo-comida::before {
  border-color: #ec4899;
}

.event-tipo-traslado::before {
  border-color: var(--gray-400);
}

.event-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  margin-bottom: 15px;
}

.event-time {
  font-weight: 700;
  color: var(--primary);
  font-size: 1rem;
  padding: 6px 12px;
  background: var(--gray-100);
  border-radius: 8px;
  white-space: nowrap;
}

.event-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--gray-900);
  margin-bottom: 8px;
}

.event-location {
  color: var(--gray-600);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 5px;
}

.event-location::before {
  content: '📍';
}

.event-details {
  display: grid;
  gap: 10px;
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid var(--gray-200);
}

.detail-item {
  display: flex;
  align-items: start;
  gap: 10px;
  font-size: 0.9rem;
}

.detail-label {
  font-weight: 600;
  color: var(--gray-700);
  min-width: 100px;
}

.detail-value {
  color: var(--gray-600);
  flex: 1;
}

.cost-badge {
  display: inline-block;
  background: var(--success);
  color: white;
  padding: 6px 16px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 1.1rem;
}

.tipo-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-left: 10px;
}

.tipo-curso {
  background: var(--success);
  color: white;
}

.tipo-evento {
  background: var(--warning);
  color: white;
}

.tipo-comida {
  background: #ec4899;
  color: white;
}

.tipo-traslado {
  background: var(--gray-300);
  color: var(--gray-700);
}

.tipo-logistica {
  background: var(--primary);
  color: white;
}

.tipo-actividad {
  background: var(--secondary);
  color: white;
}

.total-cost {
  position: sticky;
  bottom: 20px;
  background: linear-gradient(135deg, var(--success), #059669);
  color: white;
  padding: 20px 30px;
  border-radius: 15px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.3);
  margin-top: 40px;
}

.welcome-section {
  text-align: center;
  padding: 10px 20px;
}

.welcome-section h2 {
  font-size: 2rem;
  color: var(--gray-900);
  margin-bottom: 20px;
}

.welcome-section p {
  font-size: 1.1rem;
  color: var(--gray-600);
  margin-bottom: 40px;
  line-height: 1.6;
}

.view-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.view-card {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 15px;
  padding: 40px 30px;
  text-align: center;
  color: white;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.view-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.view-card h3 {
  font-size: 1.8rem;
  margin-bottom: 15px;
}

.view-card p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1rem;
  margin-bottom: 0;
}

.view-card.public {
  background: linear-gradient(135deg, var(--primary), #1d4ed8);
}

.view-card.doctor {
  background: linear-gradient(135deg, #ec4899, #db2777);
}

.view-card.staff {
  background: linear-gradient(135deg, var(--success), #059669);
}

@media (max-width: 768px) {
  .container {
    padding: 20px;
  }

  h1 {
    font-size: 2rem;
  }

  .day-title {
    font-size: 1.5rem;
  }

  .events-list {
    padding-left: 30px;
  }

  .event-card {
    margin-left: 20px;
    padding: 15px;
  }

  .event-header {
    flex-direction: column;
    gap: 10px;
  }

  .view-cards {
    grid-template-columns: 1fr;
  }
}
