/* ==================== XTRAVEL PERÚ - DATOS ESENCIALES (CSS MODERNO) ==================== */

/* Variables CSS */
#xtravel-datos-esenciales {
  --primary-blue: #009bff;
  --text-primary: #1a202c;
  --text-secondary: #718096;
  --text-muted: #a0aec0;
  --bg-light: #f7fafc;
  --bg-card: #ffffff;
  --border-light: #e2e8f0;
  --shadow-soft: 0 4px 20px rgba(139, 92, 246, 0.08);
  --shadow-medium: 0 8px 32px rgba(139, 92, 246, 0.15);
  --radius: 20px;
  --gradient-purple: linear-gradient(135deg, #f59e0b, #f5a00b);
  font-size: 14px;
  line-height: 1.5;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Layout principal */
.main-layout {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  max-width: 980px;
  margin: 0 auto;
}

.main-content {
  flex: 1 1 0%;
  min-width: 0;
  font-size: 14px;
}

.xtravel-widget-section {
  width: 320px;
  flex-shrink: 0;
  padding: 20px 8px;
}

.widget-container {
  max-width: 100%;
  margin: 0;
  padding: 0;
}

/* Panel principal */
.xtravel-panel {
  padding: 0;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  margin: 0;
}

/* Header con gradiente mejorado */
.panel-header {
  background: var(--gradient-purple);
  color: white; 
  padding: 28px 24px 70px;
  text-align: center;
  position: relative;
  border-radius: var(--radius) var(--radius) 0 0;
}

.panel-title {
  display: inline-flex; 
  align-items: center; 
  justify-content: center;
  gap: 8px; 
  font-size: 0.85rem; 
  font-weight: 600; 
  margin: 0;
  background: rgba(255,255,255,0.2);
  padding: 10px 24px;
  border-radius: 30px;
  backdrop-filter: blur(15px);
  border: 1px solid rgba(255,255,255,0.15);
  letter-spacing: 0.3px;
}

/* Grid de información mejorado - Zona roja más compacta */
.info-grid {
  display: grid; 
  grid-template-columns: 1fr 1fr;
  gap: 10px; 
  padding: 16px; 
  background: var(--bg-card);
  margin: -40px 18px 16px;
  border-radius: 16px;
  position: relative;
  z-index: 2;
  box-shadow: 0 6px 24px rgba(0,0,0,0.05);
  border: 1px solid rgba(255,255,255,0.8);
}

.info-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  padding: 14px;
  background: #fafbfc;
  border-radius: 12px;
  border: 1px solid #f1f5f9;
  transition: all 0.3s ease;
  box-shadow: 0 2px 6px rgba(0,0,0,0.02);
  min-height: 80px;
}

.info-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(139, 92, 246, 0.06);
  border-color: #e2e8f0;
}

.item-icon {
  width: 30px; 
  height: 30px; 
  border-radius: 50%;
  display: flex; 
  align-items: center; 
  justify-content: center;
  font-size: 0.9rem; 
  color: white; 
  margin-bottom: 8px;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.item-icon.duration { background: #3b82f6; }
.item-icon.pickup { background: #10b981; }
.item-icon.altitude { background: #f59e0b; }
.item-icon.difficulty { background: #8b5cf6; }

.item-content { 
  display: flex; 
  flex-direction: column; 
  gap: 2px; 
  width: 100%;
}

.item-value { 
  font-size: 0.80rem; /* Más pequeño */
  font-weight: 700; 
  color: var(--text-primary); 
  line-height: 1.1; 
  margin-bottom: 1px;
}

.item-label { 
  font-size: 0.55rem; /* Más pequeño */
  color: var(--text-secondary); 
  font-weight: 600; 
  text-transform: uppercase; 
  letter-spacing: 0.8px; 
}

/* Cards media - Zona verde ultra mejorada */
.media-cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0 18px 20px;
}

.media-card {
  display: flex;
  align-items: center;
  height: 58px;
  border-radius: 18px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 3px 20px rgba(0, 0, 0, 0.08);
  border: none;
  padding: 0 18px;
  position: relative;
  backdrop-filter: blur(25px);
}

.media-card:hover { 
  transform: translateY(-4px) scale(1.02); 
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
}

.media-card.video-card {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  box-shadow: 0 3px 20px rgba(239, 68, 68, 0.3);
}

.media-card.video-card:hover {
  box-shadow: 0 12px 40px rgba(239, 68, 68, 0.4);
}

.media-card.map-card {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  box-shadow: 0 3px 20px rgba(16, 185, 129, 0.3);
}

.media-card.map-card:hover {
  box-shadow: 0 12px 40px rgba(16, 185, 129, 0.4);
}

.media-card.faq-card {
  background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
  box-shadow: 0 3px 20px rgba(249, 115, 22, 0.3);
}

.media-card.faq-card:hover {
  box-shadow: 0 12px 40px rgba(249, 115, 22, 0.4);
}

.play-button, .map-pin, .faq-icon {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2em;
  margin-right: 14px;
  flex-shrink: 0;
  color: white;
  background: rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.15);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.media-card:hover .play-button,
.media-card:hover .map-pin,
.media-card:hover .faq-icon {
  transform: scale(1.1) rotate(5deg);
  background: rgba(255, 255, 255, 0.35);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.media-info {
  flex: 1;
  color: white;
}

.media-info h5 {
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 3px 0;
  letter-spacing: 0.4px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
}

.media-card:hover .media-info h5 {
  transform: translateX(2px);
}

.media-info p {
  font-size: 0.72rem;
  opacity: 0.9;
  margin: 0;
  font-weight: 500;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
  letter-spacing: 0.2px;
}

.media-action {
  flex-shrink: 0;
  margin-left: 14px;
}

.media-btn {
  background: rgba(255, 255, 255, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: white;
  padding: 7px 14px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  backdrop-filter: blur(20px);
  white-space: nowrap;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  letter-spacing: 0.3px;
  position: relative;
  overflow: hidden;
}

/* Botones específicos por color con efectos únicos */
.video-card .media-btn {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), rgba(255, 182, 193, 0.2));
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.2);
}

.video-card .media-btn:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.4), rgba(255, 182, 193, 0.3));
  box-shadow: 0 6px 20px rgba(239, 68, 68, 0.3);
  transform: translateY(-2px) scale(1.05);
}

.map-card .media-btn {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), rgba(187, 247, 208, 0.2));
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.2);
}

.map-card .media-btn:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.4), rgba(187, 247, 208, 0.3));
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.3);
  transform: translateY(-2px) scale(1.05);
}

.faq-card .media-btn {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), rgba(255, 237, 213, 0.2));
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.2);
}

.faq-card .media-btn:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.4), rgba(255, 237, 213, 0.3));
  box-shadow: 0 6px 20px rgba(249, 115, 22, 0.3);
  transform: translateY(-2px) scale(1.05);
}

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

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

/* Estilos para el switcher de video en el modal */
.video-switcher {
  display: flex;
  background: rgba(0,0,0,.2);
  border-radius: 8px;
  padding: 4px;
  gap: 2px;
}

.video-switcher button {
  background: transparent;
  border: none;
  color: #fff;
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all .2s ease;
  flex: 1;
  justify-content: center;
  white-space: nowrap;
}

.video-switcher button:hover {
  background: rgba(255,255,255,.15);
}

.video-switcher button.active {
  background: #fff !important;
  color: #6366f1 !important;
  box-shadow: 0 2px 8px rgba(0,0,0,.2);
}

.video-switcher button i {
  font-size: 1.1em;
}

/* Modal styles */
.xtravel-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 20px;
}

.xtravel-modal > div {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  max-width: 900px;
  width: 100%;
  max-height: 80vh;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

/* Responsive Design mejorado */
@media (max-width: 768px) {
  .main-layout { 
    flex-direction: column; 
    gap: 0; 
    max-width: 100vw; 
  }
  
  .main-content { 
    width: 100%; 
  }
  
  .xtravel-widget-section { 
    width: 100%; 
    padding: 16px; 
  }
  
  .widget-container { 
    max-width: 100%; 
  }
  
  .xtravel-panel { 
    margin: 16px; 
    border-radius: 16px;
  }
  
  .panel-header {
    padding: 20px 20px 50px;
  }
  
  .panel-title {
    font-size: 0.8rem;
    padding: 8px 20px;
  }
  
  .info-grid { 
    margin: -35px 14px 14px; 
    grid-template-columns: 1fr 1fr; 
    gap: 6px; 
    padding: 12px;
  }
  
  .info-item { 
    padding: 10px;
    min-height: 65px;
  }
  
  .item-icon {
    width: 24px;
    height: 24px;
    font-size: 0.75rem;
    margin-bottom: 4px;
  }
  
  .item-value { 
    font-size: 0.95rem; 
  }
  
  .item-label { 
    font-size: 0.55rem; 
  }
  
  .media-cards { 
    gap: 8px; 
    padding: 0 14px 16px;
  }
  
  .media-card { 
    height: 52px;
    padding: 0 14px;
    border-radius: 16px;
  }
  
  .play-button, .map-pin, .faq-icon {
    width: 30px;
    height: 30px;
    font-size: 1em;
    margin-right: 10px;
    border-radius: 10px;
  }
  
  .media-info h5 {
    font-size: 0.82rem;
  }
  
  .media-info p {
    font-size: 0.66rem;
  }
  
  .media-btn {
    padding: 6px 10px;
    font-size: 0.66rem;
    border-radius: 16px;
  }
  
  /* Modal mobile */
  .xtravel-modal {
    padding: 12px;
    align-items: flex-start;
    padding-top: 8vh;
  }
  
  .xtravel-modal > div {
    max-width: 100%;
    width: 100%;
    max-height: 85vh;
    border-radius: 14px;
  }
  
  /* Video switcher mobile */
  .video-switcher {
    width: 100%;
    margin: 6px 0 0 0;
    justify-content: center;
    background: rgba(0,0,0,.25);
  }
  
  .video-switcher button {
    flex: 1;
    padding: 10px 6px;
    font-size: 0.75rem;
    min-height: 40px;
    text-align: center;
  }
}

/* Responsive text hiding for very small screens */
@media (max-width: 480px) {
  .video-switcher button .btn-text {
    display: none;
  }
  
  .video-switcher button {
    padding: 8px;
    justify-content: center;
  }
  
  .video-switcher button i {
    font-size: 1.1em;
    margin: 0;
  }
  
  .media-card {
    height: 48px;
    border-radius: 14px;
  }
  
  .media-info h5 {
    font-size: 0.78rem;
  }
  
  .media-info p {
    font-size: 0.62rem;
  }
  
  .media-btn {
    padding: 5px 8px;
    font-size: 0.62rem;
    border-radius: 14px;
  }
  
  .play-button, .map-pin, .faq-icon {
    width: 26px;
    height: 26px;
    font-size: 0.9em;
    border-radius: 8px;
  }
  
  .info-item {
    min-height: 60px;
    padding: 8px;
  }
  
  .item-icon {
    width: 22px;
    height: 22px;
    font-size: 0.7rem;
    margin-bottom: 3px;
  }
  
  .item-value {
    font-size: 0.85rem;
  }
  
  .item-label {
    font-size: 0.5rem;
  }
  
  .info-grid {
    margin: -30px 12px 12px;
    padding: 10px;
    gap: 5px;
  }
  
  .media-cards {
    padding: 0 12px 12px;
    gap: 6px;
  }
}

/* Responsive extra para pantallas muy pequeñas */
@media (max-width: 360px) {
  .xtravel-panel { 
    margin: 12px; 
  }
  
  .info-grid {
    margin: -28px 10px 10px;
    padding: 8px;
    gap: 4px;
    grid-template-columns: 1fr 1fr;
  }
  
  .info-item {
    min-height: 55px;
    padding: 6px;
  }
  
  .item-icon {
    width: 20px;
    height: 20px;
    font-size: 0.65rem;
    margin-bottom: 2px;
  }
  
  .item-value {
    font-size: 0.8rem;
    line-height: 1;
  }
  
  .item-label {
    font-size: 0.45rem;
    letter-spacing: 0.5px;
  }
  
  .media-cards {
    padding: 0 10px 10px;
    gap: 4px;
  }
  
  .media-card {
    height: 44px;
    padding: 0 10px;
  }
  
  .panel-title {
    font-size: 0.75rem;
    padding: 6px 16px;
  }
}
