/* =========================================================
   Gulmarg Snowline — components.css
   Buttons and floating action buttons.
   ========================================================= */

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2xs);
  padding: var(--space-sm) var(--space-xl);
  min-height: 52px;
  border-radius: var(--radius-md);
  font-weight: 650;
  font-size: var(--text-base);
  letter-spacing: -0.01em;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  transition: background var(--transition-fast), color var(--transition-fast),
    border-color var(--transition-fast), transform var(--transition-fast),
    box-shadow var(--transition-fast);
}

/* On narrow phones a long nowrap label plus wide padding is wider than the
   viewport and pushes the whole page sideways, so let labels wrap there. */
@media (max-width: 480px) {
  .btn {
    white-space: normal;
    padding-inline: var(--space-md);
    max-width: 100%;
  }
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--white);
  box-shadow: 0 6px 18px rgba(25, 155, 232, 0.35);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background: var(--color-primary-hover);
  box-shadow: 0 10px 26px rgba(20, 123, 184, 0.45);
}

/* Translucent companion button for use over hero photography. */
.btn-glass {
  background: rgba(255, 255, 255, 0.14);
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.btn-glass:hover,
.btn-glass:focus-visible {
  background: rgba(255, 255, 255, 0.95);
  border-color: transparent;
  color: var(--navy);
}

.btn-secondary {
  background: transparent;
  color: var(--navy);
  border: 2px solid var(--color-border);
}

.btn-secondary:hover,
.btn-secondary:focus-visible {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.btn-inverse {
  background: var(--white);
  color: var(--navy);
}

.btn-inverse:hover,
.btn-inverse:focus-visible {
  background: var(--color-surface);
}

/* ---------- Floating buttons ---------- */
/* Both buttons share size/shape; left = back-to-top, right = WhatsApp.
   Fixed 16px edge margin keeps a wide gap between them even at a 320px
   viewport (48px button + 16px margin per side leaves ~192px of clear
   space between them at 320px width). */
.float-btn {
  position: fixed;
  bottom: var(--space-md);
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  z-index: 800;
  transition: transform var(--transition-fast), opacity var(--transition-fast),
    background var(--transition-fast);
}

.float-btn:hover {
  transform: translateY(-2px);
}

.float-btn svg {
  width: 24px;
  height: 24px;
}

.float-whatsapp {
  left: var(--space-md);
  background: #25d366;
}

.float-whatsapp svg {
  fill: var(--white);
}

.float-whatsapp:hover,
.float-whatsapp:focus-visible {
  background: #1ebc59;
}

.float-top {
  right: var(--space-md);
  background: var(--navy);
}

.float-top svg {
  fill: var(--white);
}

.float-top:hover,
.float-top:focus-visible {
  background: var(--blue-dark);
}

.float-top[hidden] {
  display: none;
}

@media (min-width: 640px) {
  .float-btn {
    bottom: var(--space-lg);
    width: 56px;
    height: 56px;
  }

  .float-whatsapp {
    left: var(--space-lg);
  }

  .float-top {
    right: var(--space-lg);
  }
}
