:root {
  --bg-main: #130f1c;
  --card-bg: #1c1729;
  --card-border: rgba(186, 140, 245, 0.25);
  
  --violet-primary: #8a63d2;
  --violet-light: #c084fc;
  --violet-heart: #a855f7;
  --violet-glow: rgba(168, 85, 247, 0.45);
  
  --gold: #d4af37;
  --gold-light: #f3e5ab;
  --gold-glow: rgba(212, 175, 55, 0.4);
  
  --text-main: #f9fafb;
  --text-muted: #b0a8c4;
  --stamp-empty: #231c34;
  --stamp-filled: #311c4d;
  --success-green: #25d366;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-main);
  background-image: radial-gradient(circle at 50% 10%, rgba(138, 99, 210, 0.18), transparent 60%);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 12px 32px 12px;
}

.card-wrapper {
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Encabezado con Logo y Tipografía Oficial */
.header {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 4px 0 10px 0;
}

.logo-container {
  width: 80px;
  height: 80px;
  margin-bottom: 6px;
  border-radius: 50%;
  padding: 3px;
  background: linear-gradient(135deg, var(--gold), var(--violet-light));
  box-shadow: 0 4px 16px rgba(138, 99, 210, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
}

.header-logo {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #ffffff;
}

.brand-font {
  font-family: 'Pacifico', cursive;
  font-size: 2.2rem;
  font-weight: 400;
  letter-spacing: 0.5px;
  color: #ffffff;
  text-shadow: 0 2px 10px rgba(168, 85, 247, 0.5);
  line-height: 1.1;
  margin-bottom: 2px;
}

.brand-subtitle {
  font-size: 0.75rem;
  letter-spacing: 4px;
  color: var(--gold-light);
  font-weight: 600;
  text-transform: uppercase;
}

.program-title {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Tarjeta Principal */
.loyalty-card {
  background: linear-gradient(150deg, #221b33 0%, #171322 100%);
  border: 1px solid var(--card-border);
  border-radius: 22px;
  padding: 22px 16px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), 0 0 25px rgba(138, 99, 210, 0.2);
  position: relative;
  overflow: hidden;
}

.loyalty-card::after {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 130px;
  height: 130px;
  background: radial-gradient(circle, rgba(168, 85, 247, 0.25) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 12px;
}

.client-info span {
  font-size: 0.7rem;
  color: var(--gold);
  letter-spacing: 1.5px;
  font-weight: 700;
}

.client-info h2 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #ffffff;
  margin-top: 2px;
}

.stamp-count-badge {
  background: rgba(168, 85, 247, 0.2);
  border: 1px solid var(--violet-light);
  color: #ffffff;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.3);
}

/* Grilla de Sellos (2 filas de 5) */
.stamps-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  margin-bottom: 18px;
}

.stamp-slot {
  aspect-ratio: 1;
  background-color: var(--stamp-empty);
  border: 2px dashed rgba(168, 85, 247, 0.25);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: all 0.25s ease;
}

.stamp-slot .num {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
}

/* Sello Marcado */
.stamp-slot.filled {
  background: radial-gradient(circle, #382059 0%, #201338 100%);
  border: 2px solid var(--violet-light);
  box-shadow: 0 0 12px var(--violet-glow);
  transform: scale(1.03);
}

/* Corazón Violeta (1 a 4 y 6 a 9) */
.heart-svg {
  width: 26px;
  height: 26px;
  color: var(--violet-heart);
  filter: drop-shadow(0 0 6px var(--violet-glow));
  animation: pulseHeart 0.3s ease-out;
}

@keyframes pulseHeart {
  0% { transform: scale(0.6); opacity: 0; }
  70% { transform: scale(1.2); }
  100% { transform: scale(1); opacity: 1; }
}

/* Sello 5 y 10 con Logo de la Peluquería */
.stamp-slot.is-logo-slot {
  border-color: var(--gold);
}

.stamp-slot.is-logo-slot.filled {
  border: 2px solid var(--gold);
  box-shadow: 0 0 14px var(--gold-glow);
}

.stamp-logo-img {
  width: 82%;
  height: 82%;
  border-radius: 50%;
  object-fit: cover;
}

.stamp-logo-img.pending-logo {
  opacity: 0.25;
  filter: grayscale(80%);
}

/* Etiquetas de Hito 10% y 15% */
.stamp-slot .goal-tag {
  position: absolute;
  bottom: -6px;
  font-size: 0.55rem;
  font-weight: 800;
  padding: 1px 4px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--gold), #b8860b);
  color: #120f1c;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}

/* Banner de Estado del Premio */
.reward-status {
  background: rgba(255, 255, 255, 0.04);
  border-left: 3px solid var(--violet-primary);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 0.88rem;
  line-height: 1.4;
  color: var(--text-main);
}

.reward-status.available {
  background: rgba(168, 85, 247, 0.15);
  border-left-color: var(--gold);
  color: #f3e5ab;
  font-weight: 600;
}

/* Sección QR para presentar en caja */
.qr-section {
  background: #ffffff;
  border-radius: 18px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.qr-section img {
  width: 175px;
  height: 175px;
  display: block;
}

.qr-section p {
  color: #4b5563;
  font-size: 0.8rem;
  margin-top: 8px;
  font-weight: 600;
}

/* Botones de Acción */
.actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-whatsapp {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background-color: var(--success-green);
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 14px;
  border-radius: 14px;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35);
  transition: transform 0.15s ease;
}

.btn-whatsapp:active {
  transform: scale(0.98);
}

.btn-google-wallet {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background-color: #111111;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 13px;
  border-radius: 14px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  transition: transform 0.15s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.btn-google-wallet:hover {
  background-color: #1a1a1a;
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-google-wallet:active {
  transform: scale(0.98);
}

/* Tarjeta Destacada de Reseñas Google */
.google-reviews-banner {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(212, 175, 55, 0.14) 100%);
  border: 1.5px solid rgba(212, 175, 55, 0.45);
  border-radius: 18px;
  padding: 16px 18px;
  margin: 16px 0;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  position: relative;
  overflow: hidden;
}

.review-stars-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 6px;
}

.review-score-pill {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 12px;
  padding: 2px 8px;
  font-weight: 800;
  font-size: 0.95rem;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.review-stars {
  color: #fbbf24;
  font-size: 1.15rem;
  letter-spacing: 2px;
  filter: drop-shadow(0 0 4px rgba(251, 191, 36, 0.5));
}

.review-prompt-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #fef08a;
  margin-bottom: 4px;
}

.review-prompt-subtitle {
  font-size: 0.84rem;
  color: #e9d5ff;
  line-height: 1.35;
  margin-bottom: 12px;
}

.btn-review-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, #fbbf24 0%, #d97706 100%);
  color: #1a1026;
  text-decoration: none;
  font-weight: 800;
  font-size: 0.95rem;
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-review-google:active {
  transform: scale(0.98);
}

.wallet-badge-img {
  height: 24px;
  width: auto;
}

.social-links-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 4px;
}

.btn-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 8px;
  border-radius: 12px;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  transition: transform 0.15s ease, opacity 0.2s;
}

.btn-social:active {
  transform: scale(0.97);
}

.btn-social-ig {
  background: linear-gradient(135deg, #833ab4, #fd1d1d, #fcb045);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(225, 48, 108, 0.3);
}

.btn-social-maps {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fef08a;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-install {
  display: none;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text-muted);
  font-size: 0.85rem;
  padding: 11px;
  border-radius: 12px;
  cursor: pointer;
  text-align: center;
}

.footer {
  text-align: center;
  font-size: 0.75rem;
  color: #7c7490;
  margin-top: 6px;
  line-height: 1.4;
}
