/* ============================================================
   ROYAL HERITAGE RESORT — Components
   ============================================================
   Buttons, cards, forms, badges, modals, loaders.
   ============================================================ */

/* ════════════════════════════════════════════════════════════
   BUTTONS
   ════════════════════════════════════════════════════════════ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-8);
  font-family: var(--font-body);
  font-size: var(--fs-small);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wider);
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition-base);
  white-space: nowrap;
  text-decoration: none;
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.1);
  opacity: 0;
  transition: var(--transition-fast);
}

.btn:hover::after {
  opacity: 1;
}

/* Primary: Gold */
.btn-primary {
  background: var(--color-gold);
  color: var(--color-black);
  border-color: var(--color-gold);
}

.btn-primary:hover {
  background: var(--color-gold-bright);
  border-color: var(--color-gold-bright);
  color: var(--color-black);
  box-shadow: var(--shadow-gold);
  transform: translateY(-2px);
}

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

/* Secondary: Maroon */
.btn-secondary {
  background: var(--color-maroon);
  color: var(--color-white);
  border-color: var(--color-maroon);
}

.btn-secondary:hover {
  background: var(--color-maroon-light);
  border-color: var(--color-maroon-light);
  color: var(--color-white);
  transform: translateY(-2px);
}

/* Outline: Gold border */
.btn-outline {
  background: transparent;
  color: var(--color-gold);
  border-color: var(--color-gold);
}

.btn-outline:hover {
  background: var(--color-gold);
  color: var(--color-black);
  transform: translateY(-2px);
}

/* Outline on dark */
.btn-outline-light {
  background: transparent;
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-outline-light:hover {
  background: var(--color-white);
  color: var(--color-black);
  border-color: var(--color-white);
  transform: translateY(-2px);
}

/* Ghost (text only) */
.btn-ghost {
  background: transparent;
  color: var(--color-gold);
  border-color: transparent;
  padding-left: var(--space-2);
  padding-right: var(--space-2);
}

.btn-ghost:hover {
  color: var(--color-gold-bright);
}

.btn-ghost::after { display: none; }

/* Sizes */
.btn-sm {
  padding: var(--space-2) var(--space-5);
  font-size: var(--fs-xs);
}

.btn-lg {
  padding: var(--space-4) var(--space-10);
  font-size: var(--fs-body);
}

/* Icon inside button */
.btn .btn-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.btn-icon-only {
  padding: var(--space-3);
  border-radius: var(--radius-full);
}


/* ════════════════════════════════════════════════════════════
   CARDS
   ════════════════════════════════════════════════════════════ */

.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  position: relative;
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-6px);
}

.card-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
}

.card-body {
  padding: var(--space-6);
}

.card-label {
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wider);
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: var(--space-2);
}

.card-title {
  font-family: var(--font-display);
  font-size: var(--fs-h4);
  font-weight: var(--fw-bold);
  margin-bottom: var(--space-3);
  line-height: var(--lh-snug);
}

.card-text {
  font-size: var(--fs-small);
  color: var(--text-secondary);
  line-height: var(--lh-normal);
  margin-bottom: var(--space-4);
}

.card-footer {
  padding: var(--space-4) var(--space-6);
  border-top: var(--border-thin);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Accommodation Card (tent/cottage) */
.accommodation-card {
  display: flex;
  flex-direction: column;
}

.accommodation-card .card-price {
  font-family: var(--font-display);
  font-size: var(--fs-h4);
  color: var(--color-maroon);
  font-weight: var(--fw-bold);
}

.accommodation-card .card-price span {
  font-family: var(--font-body);
  font-size: var(--fs-small);
  font-weight: var(--fw-regular);
  color: var(--text-muted);
}

.accommodation-card .card-amenities {
  display: flex;
  gap: var(--space-3);
  flex-wrap: wrap;
  margin-bottom: var(--space-4);
}

.accommodation-card .amenity-tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--fs-xs);
  color: var(--text-muted);
  background: var(--color-cream);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
}

/* Feature Card (highlights section) */
.feature-card {
  text-align: center;
  padding: var(--space-10) var(--space-6);
  border: var(--border-thin);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  transition: var(--transition-base);
}

.feature-card:hover {
  border-color: var(--color-gold);
  box-shadow: var(--shadow-gold);
  transform: translateY(-4px);
}

.feature-card .feature-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto var(--space-6);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-cream);
  border-radius: var(--radius-full);
  color: var(--color-gold);
  font-size: 1.5rem;
}

.feature-card .feature-title {
  font-family: var(--font-display);
  font-size: var(--fs-h5);
  margin-bottom: var(--space-3);
}

.feature-card .feature-text {
  font-size: var(--fs-small);
  color: var(--text-secondary);
  line-height: var(--lh-relaxed);
}


/* ════════════════════════════════════════════════════════════
   FORMS
   ════════════════════════════════════════════════════════════ */

.form-group {
  position: relative;
  margin-bottom: var(--space-6);
}

.form-label {
  display: block;
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: var(--space-2);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  color: var(--text-primary);
  background: var(--color-white);
  border: 1px solid var(--color-sand);
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--color-gold);
  box-shadow: 0 0 0 3px rgba(200, 169, 110, 0.15);
}

.form-input::placeholder {
  color: var(--color-silver);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236B6B6B' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: var(--space-10);
}

.form-error {
  font-size: var(--fs-xs);
  color: var(--color-maroon);
  margin-top: var(--space-1);
}

/* Inline form row */
.form-row {
  display: flex;
  gap: var(--space-4);
}

.form-row .form-group {
  flex: 1;
}


/* ════════════════════════════════════════════════════════════
   BADGES & TAGS
   ════════════════════════════════════════════════════════════ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-1) var(--space-3);
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  border-radius: var(--radius-full);
}

.badge-gold {
  background: rgba(200, 169, 110, 0.15);
  color: var(--color-gold-dark);
}

.badge-maroon {
  background: rgba(107, 15, 26, 0.1);
  color: var(--color-maroon);
}

.badge-emerald {
  background: rgba(13, 92, 78, 0.1);
  color: var(--color-emerald);
}


/* ════════════════════════════════════════════════════════════
   MODAL
   ════════════════════════════════════════════════════════════ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-overlay-heavy);
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-6);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-base);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  max-width: 560px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-xl);
  transform: translateY(20px) scale(0.95);
  transition: var(--transition-base);
}

.modal-overlay.active .modal {
  transform: translateY(0) scale(1);
}

.modal-header {
  padding: var(--space-6);
  border-bottom: var(--border-thin);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title {
  font-family: var(--font-display);
  font-size: var(--fs-h4);
}

.modal-close {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  color: var(--text-muted);
  transition: var(--transition-fast);
}

.modal-close:hover {
  background: var(--color-cream);
  color: var(--text-primary);
}

.modal-body {
  padding: var(--space-6);
}

.modal-footer {
  padding: var(--space-4) var(--space-6);
  border-top: var(--border-thin);
  display: flex;
  justify-content: flex-end;
  gap: var(--space-3);
}


/* ════════════════════════════════════════════════════════════
   LOADING SPINNER
   ════════════════════════════════════════════════════════════ */

.loader {
  width: 36px;
  height: 36px;
  border: 3px solid var(--color-sand);
  border-top-color: var(--color-gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loader-overlay {
  position: fixed;
  inset: 0;
  background: rgba(253, 248, 240, 0.9);
  z-index: var(--z-overlay);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: var(--space-4);
}

.loader-text {
  font-family: var(--font-display);
  font-size: var(--fs-body);
  color: var(--text-secondary);
}


/* ════════════════════════════════════════════════════════════
   TOAST NOTIFICATION
   ════════════════════════════════════════════════════════════ */

.toast-container {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.toast {
  padding: var(--space-4) var(--space-6);
  border-radius: var(--radius-md);
  background: var(--bg-dark);
  color: var(--text-on-dark);
  font-size: var(--fs-small);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 280px;
  transform: translateX(120%);
  transition: var(--transition-base);
}

.toast.visible {
  transform: translateX(0);
}

.toast-success { border-left: 3px solid var(--color-emerald); }
.toast-error { border-left: 3px solid var(--color-maroon); }
.toast-info { border-left: 3px solid var(--color-gold); }

/* ════════════════════════════════════════════════════════
   WHATSAPP & DESERT BOOKING STYLES
   ════════════════════════════════════════════════════════ */

/* WhatsApp Action Button */
.btn-whatsapp {
  background: var(--color-whatsapp);
  color: #FFFFFF;
  border-color: var(--color-whatsapp);
  box-shadow: 0 4px 14px var(--color-whatsapp-glow);
}

.btn-whatsapp:hover {
  background: var(--color-whatsapp-hover);
  border-color: var(--color-whatsapp-hover);
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.45);
}

.btn-whatsapp svg, .btn-whatsapp img {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.btn-whatsapp-outline {
  background: transparent;
  color: var(--color-whatsapp-dark);
  border-color: var(--color-whatsapp);
}

.btn-whatsapp-outline:hover {
  background: var(--color-whatsapp);
  color: #FFFFFF;
}

/* Floating WhatsApp Concierge Widget */
.floating-whatsapp {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 999;
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.floating-whatsapp-badge {
  background: var(--bg-dark);
  color: var(--text-on-dark);
  padding: 8px 14px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: var(--fw-medium);
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(212, 154, 61, 0.4);
  white-space: nowrap;
  pointer-events: none;
  animation: floatPulse 3s infinite ease-in-out;
}

.floating-whatsapp-btn {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--color-whatsapp);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.5);
  transition: all var(--duration-normal) var(--ease-spring);
  position: relative;
}

.floating-whatsapp-btn::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid var(--color-whatsapp);
  opacity: 0.6;
  animation: pulseWave 2s infinite;
}

.floating-whatsapp:hover .floating-whatsapp-btn {
  transform: scale(1.1) rotate(6deg);
  background: var(--color-whatsapp-hover);
}

.floating-whatsapp-btn svg {
  width: 32px;
  height: 32px;
  fill: #FFFFFF;
}

@keyframes pulseWave {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(1.4); opacity: 0; }
}

@keyframes floatPulse {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

/* Desert Live Quote Card */
.desert-quote-card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-sand);
  padding: var(--space-8);
  box-shadow: var(--shadow-xl);
  position: sticky;
  top: 100px;
}

.quote-header {
  border-bottom: 1px dashed var(--color-sand);
  padding-bottom: var(--space-4);
  margin-bottom: var(--space-6);
}

.quote-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-3);
  font-size: var(--fs-small);
  color: var(--text-secondary);
}

.quote-row.total {
  border-top: 2px solid var(--color-sand);
  padding-top: var(--space-4);
  margin-top: var(--space-4);
  font-size: var(--fs-h4);
  font-weight: var(--fw-bold);
  color: var(--text-primary);
}

.quote-row.total .price {
  color: var(--color-terracotta);
  font-family: var(--font-display);
  font-size: 1.8rem;
}

.inclusion-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #FDF4E7;
  color: #934C11;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 500;
  margin: 3px;
  border: 1px solid rgba(212, 154, 61, 0.3);
}

