/* Estilos para la tarjeta de bienvenida personalizada */
.client-welcome-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(90deg, #e0ffe7 0%, #f7fafd 100%);
  border-radius: 16px;
  box-shadow: 0 2px 12px 0 rgba(44, 187, 99, 0.10);
  padding: 18px 24px;
  margin-bottom: 18px;
  font-size: 1.15em;
  color: #217a4b;
  opacity: 0;
  transform: translateY(-20px);
  transition: opacity 0.5s, transform 0.5s;
}
.client-welcome-card.show {
  opacity: 1;
  transform: translateY(0);
}
.client-welcome-icon {
  font-size: 2em;
  margin-right: 8px;
}
.client-welcome-text {
  flex: 1;
  font-weight: 500;
}
.client-welcome-btn {
  background: #2d8f6f;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 18px;
  margin-left: 16px;
  font-size: 1em;
  cursor: pointer;
  transition: background 0.2s;
}
.client-welcome-btn:hover {
  background: #217a4b;
}
/* Import de fuentes */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;900&family=Great+Vibes&display=swap');

* {
  box-sizing: border-box;
}

/* BODY GENERAL */
body {
  font-family: var(--font-primary);
  background: linear-gradient(
    180deg,
    var(--bg-gradient-start) 0%,
    var(--bg-gradient-mid) 50%,
    var(--bg-gradient-end) 100%
  );
  color: var(--color-text-primary);
  margin: 0;
  padding: 0;
  overflow-y: auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  min-width: 320px;
}

/* Wrapper de página (para CTA sticky en móvil) */
.home-page {
  width: 100%;
}

/* WRAPPER PRINCIPAL DEL PERFIL */
.profile_wrapper {
  padding: clamp(12px, 2vw, 22px) clamp(16px, 4vw, 32px) var(--spacing-lg);
  text-align: center;
  width: min(960px, 100%);
  margin: 0 auto;
  margin-top: 32px !important;
  margin-bottom: 48px !important;
  position: relative;
}

@media (max-width: 640px) {
  .profile_wrapper {
    margin-top: 20px;
    padding-left: var(--spacing-md);
    padding-right: var(--spacing-md);
  }
}

.profile_wrapper::before {
  content: "";
  position: absolute;
  inset: -24px -16px auto -16px;
  height: 240px;
  background: radial-gradient(closest-side, rgba(46, 125, 219, 0.18), rgba(46, 125, 219, 0));
  filter: blur(2px);
  z-index: -1;
  pointer-events: none;
}

.profile_head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-sm);
}

/* === AVATAR / LOGO REDONDO === */
.thumb {
  margin-top: 0 !important;
  width: 180px;
  height: 180px;               /* cuadrado */
  border-radius: 50%;          /* redonda */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 3px solid var(--color-primary);
  box-shadow: var(--shadow-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.thumb:hover {
  transform: scale(1.04);
  box-shadow: var(--shadow-hover);
}

@media (max-width: 768px) {
  .thumb {
    width: 160px;
    height: 160px;
  }
}

@media (max-width: 480px) {
  .thumb {
    width: 130px;
    height: 130px;
  }
}

/* NOMBRE DE LA MARCA */
.brand-calligraphy {
  font-family: var(--font-primary);
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-text-primary);
  letter-spacing: 1px;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  margin: var(--spacing-md) 0 8px;
  animation: fadeInUp 0.8s ease forwards;
  opacity: 0;
}

/* BIO / DESCRIPCIÓN */
.profile_head_bio {
  margin-top: var(--spacing-xs);
}

.profile_head_bio p {
  font-size: var(--font-size-sm);
  line-height: 1.45;
  max-width: 700px;
  margin: 32px auto 40px auto;
  padding: 0 var(--spacing-md);
  margin: 0 auto;
  animation: fadeInUp 0.8s ease 0.3s forwards;
  opacity: 0;
}

/* Chips / beneficios */
.home-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 10px;
}

.home-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(6px);
  font-size: 13px;
  color: var(--color-text-secondary);
  box-shadow: var(--shadow-sm);
}

/* Secciones */
.home-section {
  width: 100%;
  max-width: 760px;
  margin: 18px auto 0;
  text-align: left;
}

.home-section-title {
  font-size: 16px;
  margin: 18px 0 10px;
  text-align: center;
  font-weight: var(--font-weight-bold);
  letter-spacing: 0.02em;
}

.home-features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.home-feature {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 14px 14px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}

.home-feature:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  border-color: var(--border-color-hover);
}

.home-feature-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-weight: var(--font-weight-black);
  color: #fff;
  background: linear-gradient(135deg, var(--color-secondary), var(--color-accent));
  box-shadow: var(--shadow-md);
  margin: 0 auto 10px;
}

.home-feature h3 {
  font-size: 14px;
  text-align: center;
  margin: 0 0 6px;
  font-weight: var(--font-weight-bold);
}

.home-feature p {
  margin: 0;
  font-size: 13px;
  color: var(--color-text-light);
  line-height: 1.35;
  text-align: center;
}

.ios-install-message {
  background: #f3f4f6;
  padding: 10px;
  border-radius: 10px;
  margin-bottom: 10px;
  max-width: 520px;
  width: min(520px, 100%);
}

/* LISTA DE LINKS (WHATSAPP, INSTAGRAM, ETC.) */
.profile_links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-sm);
  margin-top: 12px;
  margin-bottom: var(--spacing-lg);
  width: 100%;
  max-width: 640px;
  padding: 0 var(--spacing-sm);
  margin-left: auto;
  margin-right: auto;
}

/* CARD DE LINK SOCIAL */
.SocialLink {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--color-text-primary);
  background-color: var(--bg-card);
  padding: 11px 18px;
  border-radius: var(--radius-md);
  width: 100%;
  justify-content: center;
  max-width: 520px;
  font-size: var(--font-size-base);
  letter-spacing: 0.02em;
  border: 1px solid var(--border-color);
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
  gap: var(--spacing-xs);
  flex-wrap: wrap;
}

.SocialLink:hover {
  background-color: var(--bg-card-hover);
  color: var(--color-text-primary);
  border-color: var(--border-color-hover);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

/* ICONO DE CADA LINK */
.asset-logo {
  width: 26px;
  height: 26px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  margin-right: var(--spacing-sm);
  border-radius: var(--radius-full);
  transition: transform var(--transition-normal);
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.12);
}

.SocialLink:hover .asset-logo {
  transform: scale(1.08);
}

.SocialLink_body h3 {
  margin: 0;
  font-size: 15px;
}

.SocialLink_body {
  flex: 1;
  text-align: center;
}

.SocialLink:focus-visible,
.install-btn:focus-visible {
  outline: 2px solid var(--color-secondary);
  outline-offset: 3px;
}

/* === CTA “REALIZA TU RESERVA” (VARIANTE DESTACADA) === */
.SocialLink.vibrar {
  background-color: var(--color-secondary); /* BOTÓN PRINCIPAL: AZUL */
  color: #FFFFFF;
  font-weight: var(--font-weight-bold);
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  border-color: var(--color-secondary);
  margin-bottom: 8px;
}

.SocialLink.vibrar:hover {
  background-color: var(--color-secondary-light);
  transform: scale(1.02);
}

.reserva-link .SocialLink_body h3 {
  font-size: 18px;
}

/* TOAST DE BIENVENIDA */
.toast-welcome {
  position: fixed;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  background-color: var(--bg-card);
  color: var(--color-text-primary);
  padding: 14px 20px;
  border-radius: var(--radius-md);
  font-size: 14px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: all 0.5s ease;
  pointer-events: none;
  z-index: 2147483647;
  border: 2px solid var(--color-secondary);
  max-width: 90%;
  width: min(540px, calc(100% - 32px));
  line-height: 1.4;
}

.toast-welcome.show {
  top: 80px;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* ANIMACIONES GENERALES */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes vibrar {
  0% { transform: translateX(0); }
  25% { transform: translateX(-2px); }
  50% { transform: translateX(2px); }
  75% { transform: translateX(-2px); }
  100% { transform: translateX(0); }
}

.vibrar {
  animation: vibrar var(--transition-fast) linear infinite;
}

/* CTA sticky (móvil) */
.home-sticky-cta {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  display: none;
  gap: 10px;
  padding: 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(10px);
  z-index: 2147483000;
}

.home-sticky-btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: var(--font-weight-bold);
  font-size: 14px;
  border: 1px solid var(--border-color);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
}

.home-sticky-btn:active {
  transform: translateY(1px);
}

.home-sticky-primary {
  background: var(--color-secondary);
  color: #fff;
  border-color: var(--color-secondary);
}

.home-sticky-primary:hover {
  background: var(--color-secondary-light);
  color: var(--color-text-primary);
  box-shadow: var(--shadow-hover);
}

.home-sticky-ghost {
  background: var(--bg-card);
  color: var(--color-text-primary);
}

.home-sticky-ghost:hover {
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-hover);
}

/* AJUSTES RESPONSIVE EN ALTURA */
@media (max-height: 700px) {
  .thumb {
    width: 150px;
    height: 150px;
  }

  .brand-calligraphy {
    font-size: var(--font-size-xl);
    margin: 8px 0 var(--spacing-xs);
  }

  .profile_head_bio p {
    font-size: var(--font-size-xs);
  }

  .SocialLink {
    padding: 9px 16px;
  }

  .toast-welcome.show {
    top: 20px;
  }
}

@media (max-width: 480px) {
  .profile_head_bio p {
    font-size: var(--font-size-xs);
  }

  .home-features {
    grid-template-columns: 1fr;
  }

  .SocialLink,
  .install-btn {
    padding: 10px 14px;
    font-size: var(--font-size-sm);
  }

  .brand-calligraphy {
    font-size: 1.25rem;
  }

  .client-welcome-card {
    font-size: 0.98rem;
    padding: 12px 10px;
  }
  .client-welcome-icon {
    font-size: 1.3em;
  }
  .client-welcome-btn {
    font-size: 0.98em;
    padding: 7px 12px;
  }
  .toast-welcome {
    font-size: 12px;
    padding: 10px 8px;
  }
  .SocialLink_body h3 {
    font-size: 13px;
  }

  .profile_wrapper {
    margin-top: 10px !important;
    padding-top: 8px !important;
  }
  .thumb {
    width: 100px;
    height: 100px;
  }
}

@media (max-width: 375px) {
  .brand-calligraphy {
    font-size: 1.05rem;
  }
  .client-welcome-card {
    font-size: 0.89rem;
    padding: 8px 4px;
  }
  .client-welcome-btn {
    font-size: 0.89em;
    padding: 6px 8px;
  }
  .toast-welcome {
    font-size: 11px;
    padding: 7px 4px;
  }
  .SocialLink_body h3 {
    font-size: 12px;
  }
}

@media (min-height: 900px) {
  .profile_wrapper {
    margin-top: 50px;
  }

  .thumb {
    width: 200px;
    height: 200px;
  }
}

/* BOTÓN DE INSTALACIÓN PWA - USANDO VARIABLES GLOBALES */
.install-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  background-color: var(--color-primary-light); /* antes #5eead4 */
  color: var(--color-text-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-weight: var(--font-weight-bold);
  font-family: var(--font-primary);
  cursor: pointer;
  margin: 0 auto var(--spacing-sm);
  box-shadow: var(--shadow-sm);
  max-width: 520px;
  width: 100%;
  font-size: var(--font-size-base);
  letter-spacing: 0.02em;
  transition: all var(--transition-normal);
  user-select: none;
  text-align: center;
}

.install-btn,
#iosInstallMessage {
  margin-left: auto;
  margin-right: auto;
  width: min(520px, 100%);
}

.install-btn:hover {
  background-color: var(--bg-card-hover); /* antes #d1f7f3 */
  transform: scale(1.02);
  box-shadow: var(--shadow-hover);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .vibrar {
    animation: none !important;
  }
}

@media (max-width: 640px) {
  .home-sticky-cta {
    display: flex;
  }

  .home-page {
    padding-bottom: 88px;
  }
}
