/* Primary Button (gold) */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  background: var(--gradient-gold);
  background-size: 200% auto;
  color: var(--bg-primary);
  font: 600 clamp(11px, 1.2vw, 14px)/1 var(--font-body);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  padding: clamp(14px, 1.5vw, 18px) clamp(24px, 3vw, 36px);
  border-radius: var(--border-radius-full);
  border: none;
  cursor: pointer;
  /* ИСПРАВЛЕНО: убран white-space:nowrap — текст переносится на маленьких экранах
     если нужен nowrap, используйте только в конкретных местах */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%; /* ← не вылезает из контейнера */
  min-height: 48px; /* ← минимальный tappable размер */
  position: relative;
  transition: background-position 0.5s ease,
              box-shadow var(--duration-normal) ease,
              transform var(--duration-fast) ease;
  will-change: transform; /* ← compositing layer для анимации */
}

.btn-primary:hover {
  background-position: right center;
  box-shadow: var(--shadow-cta);
  transform: translateY(-1px);
}

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

/* Shimmer effect */
.btn-primary::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -60%;
  width: 40%;
  height: 200%;
  background: linear-gradient(
    105deg,
    transparent 40%,
    rgba(255, 255, 255, 0.25) 45%,
    rgba(255, 255, 255, 0.35) 50%,
    rgba(255, 255, 255, 0.25) 55%,
    transparent 60%
  );
  transform: skewX(-20deg);
  animation: btnShimmer 4s infinite 2s;
  pointer-events: none;
}

@keyframes btnShimmer {
  0% { left: -60%; }
  20% { left: 120%; }
  100% { left: 120%; }
}

.btn-primary:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.btn-large {
  padding: 20px 48px;
  font-size: 14px;
}

/* Secondary Button (outline) */
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  background: transparent;
  color: var(--gold);
  font: 500 clamp(11px, 1.2vw, 14px)/1 var(--font-body);
  letter-spacing: 0.06em;
  text-decoration: none;
  padding: clamp(13px, 1.4vw, 16px) clamp(22px, 2.8vw, 32px);
  border-radius: var(--border-radius-full);
  border: 1px solid var(--border-default);
  cursor: pointer;
  white-space: nowrap;
  max-width: 100%;
  min-height: 48px;
  transition: all var(--duration-normal) var(--ease-default);
  will-change: transform;
}

.btn-secondary:hover {
  background: rgba(201, 169, 110, 0.06);
  border-color: var(--border-hover);
}

.btn-secondary:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

/* ── Telegram secondary ── */
.btn-secondary--tg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: transparent;
  color: rgba(255, 255, 255, 0.8);
  font: 500 clamp(11px, 1.2vw, 14px)/1 var(--font-body);
  letter-spacing: 0.06em;
  text-decoration: none;
  padding: clamp(13px, 1.4vw, 16px) clamp(22px, 2.8vw, 32px);
  border-radius: var(--border-radius-full);
  border: 1px solid rgba(42, 171, 238, 0.35);
  cursor: pointer;
  white-space: nowrap;
  max-width: 100%;
  min-height: 48px;
  transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
  will-change: transform;
}

.btn-secondary--tg:hover,
.btn-secondary--tg:focus-visible {
  background: rgba(42, 171, 238, 0.12);
  border-color: rgba(42, 171, 238, 0.6);
  color: #fff;
  transform: translateY(-1px);
  outline: none;
}

.btn-secondary--tg svg {
  flex-shrink: 0;
  opacity: 0.85;
}

/* ── Ghost button ("Узнать подробнее") ── */
.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.45);
  font: 400 clamp(12px, 1.1vw, 14px)/1 var(--font-body);
  padding: 0.5rem 0;
  cursor: pointer;
  text-decoration: none;
  min-height: 44px;
  transition: color 0.2s;
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  color: rgba(255, 255, 255, 0.8);
  outline: none;
}

/* ── Instagram button ── */
.btn-instagram {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: transparent;
  border: 1px solid rgba(250, 113, 255, 0.5);
  color: rgba(255, 255, 255, 0.8);
  font: 500 clamp(11px, 1.2vw, 14px)/1 var(--font-body);
  letter-spacing: 0.06em;
  text-decoration: none;
  padding: clamp(13px, 1.4vw, 16px) clamp(22px, 2.8vw, 32px);
  border-radius: var(--border-radius-full);
  cursor: pointer;
  white-space: nowrap;
  max-width: 100%;
  min-height: 48px;
  transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
  will-change: transform;
}

.btn-instagram:hover,
.btn-instagram:focus-visible {
  background: rgba(255, 51, 218, 0.12);
  border-color: rgba(234, 112, 238, 0.5);
  color: #fff;
  transform: translateY(-1px);
  outline: none;
}

.btn-instagram svg {
  fill: currentColor;
  flex-shrink: 0;
}

/* Card */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--border-radius-md);
  padding: var(--space-6);
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  transition: all var(--duration-normal) var(--ease-default);
  will-change: transform;
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-glow);
  transform: translateY(-4px);
}

/* Section Label */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--gold);
  font: 500 11px/1 var(--font-body);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}

.section-label::before {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--gold);
  opacity: 0.6;
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .btn-primary {
    font-size: 9px;
  }

  .btn-secondary {
    font-size: 9px;
  }

  .section-label {
    font-size: 12px;
  }
}
