/* Estilos para la isla dinámica con efecto liquid glass */
.dynamic-island-container {
  display: none; /* Por defecto oculto, se muestra solo en móvil */
  position: fixed;
  top: 15px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2100;
  width: 120px;
  height: 40px;
  border-radius: 20px;
  background: #ffffff;
  /* Efecto neumorfismo (soft UI) */
  box-shadow: 8px 8px 16px rgba(200, 200, 200, 0.5),
             -8px -8px 16px rgba(255, 255, 255, 0.8);
  border: none;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.dynamic-island-container.expanded {
  width: 90%;
  max-width: 350px;
  height: auto;
  max-height: 80vh;
  border-radius: 24px;
  background: #ffffff;
  /* Efecto neumorfismo más pronunciado cuando está expandido */
  box-shadow: 12px 12px 24px rgba(200, 200, 200, 0.6),
             -12px -12px 24px rgba(255, 255, 255, 0.8),
             inset 1px 1px 2px rgba(255, 255, 255, 0.3);
  border: none;
}

.dynamic-island-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.island-logo {
  width: 40px;
  height: auto;
  object-fit: contain;
  transition: all 0.3s ease;
  margin: 0 auto;
  border-radius: 8px;
}

.dynamic-island-container.expanded .island-logo {
  position: absolute;
  top: 15px;
  left: 15px;
  width: 60px;
  height: auto;
  margin: 0;
  border-radius: 8px;
  object-fit: contain;
}

.island-menu-container {
  display: none;
  flex-direction: column;
  width: 100%;
  padding: 60px 15px 15px;
}

.dynamic-island-container.expanded .island-menu-container {
  display: flex;
}

.island-menu-item {
  padding: 12px 15px;
  margin-bottom: 12px;
  border-radius: 12px;
  background: #ffffff;
  color: #e67e22;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  /* Efecto neumorfismo (soft UI) */
  box-shadow: 6px 6px 12px rgba(200, 200, 200, 0.5),
             -6px -6px 12px rgba(255, 255, 255, 0.8);
  border: none;
  position: relative;
  overflow: hidden;
}

.island-menu-item:hover, .island-menu-item:active {
  background: #fff9f4;
  color: #e67e22;
  /* Efecto neumorfismo invertido al hacer hover */
  box-shadow: inset 4px 4px 8px rgba(200, 200, 200, 0.5),
              inset -4px -4px 8px rgba(255, 255, 255, 0.8);
  transform: translateY(0);
}

.island-menu-item:before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 100%;
  background: rgba(230, 126, 34, 0.1);
  transition: width 0.3s ease;
  z-index: -1;
}

.island-menu-item:hover:before {
  width: 100%;
}

.island-menu-item i {
  margin-right: 12px;
  font-size: 16px;
  color: #e67e22;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 2px 2px 5px rgba(200, 200, 200, 0.3),
             -2px -2px 5px rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
}

.island-menu-item:hover i {
  box-shadow: inset 2px 2px 3px rgba(200, 200, 200, 0.3),
              inset -2px -2px 3px rgba(255, 255, 255, 0.5);
  transform: scale(0.95);
}

.island-close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #ffffff;
  display: none;
  align-items: center;
  justify-content: center;
  color: #e67e22;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  border: none;
  /* Efecto neumorfismo (soft UI) */
  box-shadow: 4px 4px 8px rgba(200, 200, 200, 0.5),
             -4px -4px 8px rgba(255, 255, 255, 0.8);
  transition: all 0.3s ease;
}

.dynamic-island-container.expanded .island-close {
  display: flex;
}

.island-close:hover {
  box-shadow: inset 3px 3px 5px rgba(200, 200, 200, 0.5),
              inset -3px -3px 5px rgba(255, 255, 255, 0.8);
  color: #e67e22;
  transform: scale(0.95);
}

.island-pulse {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e67e22;
  box-shadow: 0 0 0 rgba(230, 126, 34, 0.4);
  animation: pulse 2s infinite;
}

.dynamic-island-container.expanded .island-pulse {
  display: none;
}

@keyframes pulse {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(230, 126, 34, 0.7);
  }
  
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 10px rgba(230, 126, 34, 0);
  }
  
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(230, 126, 34, 0);
  }
}

/* Media queries para mostrar/ocultar la isla dinámica */
@media only screen and (max-width: 767px) {
  .dynamic-island-container {
    display: flex;
  }
  
  .cd-header {
    background: transparent !important;
    box-shadow: none !important;
  }
  
  .cd-primary-nav-trigger {
    display: none !important;
  }
  
  .logo-wrap {
    opacity: 0;
  }
}
