/*
 * ComSMP — Night Stone + Emerald
 * SellAuth theme overrides (safe across theme updates)
 */

:root {
  --comsmp-emerald: #3ddc84;
  --comsmp-gold: #e4b84a;
  --comsmp-moss: rgba(61, 220, 132, 0.08);
  --comsmp-veil: rgba(11, 15, 12, 0.55);
}

/* Soft emerald atmosphere (not neon glow) */
[data-scheme="dark"] body.sa-tpl-shop::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 45% at 50% -10%, rgba(61, 220, 132, 0.14), transparent 55%),
    radial-gradient(ellipse 45% 35% at 100% 20%, rgba(42, 53, 48, 0.55), transparent 50%),
    radial-gradient(ellipse 40% 30% at 0% 60%, rgba(26, 34, 30, 0.7), transparent 55%);
}

[data-scheme="dark"] #app {
  position: relative;
  z-index: 1;
}

/* Hero — brand-first ComSMP */
.sa-tpl-shop .sa-hero {
  min-height: min(78vh, 820px);
  display: flex;
  align-items: center;
}

.sa-tpl-shop .sa-hero-title {
  font-size: clamp(3.25rem, 9vw, 5.75rem);
  letter-spacing: -0.04em;
  line-height: 0.95;
}

.sa-tpl-shop .sa-hero-eyebrow {
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 600;
}

.sa-tpl-shop .sa-hero-subtitle {
  max-width: 34rem;
  font-size: 1.125rem;
  line-height: 1.55;
}

/* Tame default hero grid so it feels like stone, not tech UI */
.sa-hero .hero-bg-grid {
  opacity: 0.35;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 20%, transparent 75%);
}

.sa-hero .hero-bg-glow {
  opacity: 0.45;
  filter: saturate(0.85);
}

/* Navbar brand weight */
.sa-navbar-logo,
.sa-header .font-heading {
  letter-spacing: -0.02em;
}

/* Product cards — stone surface, emerald hover edge */
.sa-product-card {
  border-color: rgba(42, 53, 48, 0.95);
  transition:
    border-color var(--dur, 250ms) ease,
    transform var(--dur, 250ms) ease,
    background-color var(--dur, 250ms) ease;
}

[data-scheme="dark"] .sa-product-card:hover {
  border-color: rgba(61, 220, 132, 0.45);
  background-color: rgba(26, 34, 30, 0.65);
}

/* Primary buttons — denser emerald */
.sa-btn--primary,
.sa-btn.sa-btn--primary,
a.sa-btn[class*="primary"] {
  font-weight: 600;
  letter-spacing: 0.01em;
}

/* Gold only for sale / VIP-style badges when present */
.sa-product-card-badges .sa-badge,
.sa-product-card .sa-badge {
  border-radius: var(--radius-badge, 6px);
}

/* Section rhythm */
.sa-tpl-shop .sa-features,
.sa-tpl-shop .sa-steps,
.sa-tpl-shop .sa-faq {
  position: relative;
}

/* Footer quiet moss wash */
[data-scheme="dark"] .sa-footer {
  background: linear-gradient(180deg, transparent 0%, rgba(18, 24, 22, 0.85) 40%, #121816 100%);
  border-top: 1px solid rgba(42, 53, 48, 0.9);
}

/* Motion: soft attention on primary CTA (respects reduced motion) */
@keyframes comsmp-ip-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(61, 220, 132, 0);
  }
  50% {
    box-shadow: 0 0 0 4px rgba(61, 220, 132, 0.12);
  }
}

.sa-tpl-shop .sa-hero-actions .sa-btn--primary {
  animation: comsmp-ip-pulse 3.2s ease-in-out 1.2s infinite;
}

@media (prefers-reduced-motion: reduce) {
  .sa-tpl-shop .sa-hero-actions .sa-btn--primary {
    animation: none;
  }
}

/* Light scheme stays coherent if toggled */
[data-scheme="light"] .sa-product-card:hover {
  border-color: rgba(61, 220, 132, 0.55);
}

/* ── Products page ─────────────────────────────────────────── */
[data-scheme="dark"] body.sa-tpl-products::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 60% 40% at 15% 0%, rgba(61, 220, 132, 0.1), transparent 55%),
    radial-gradient(ellipse 50% 35% at 90% 30%, rgba(42, 53, 48, 0.45), transparent 50%);
}

.sa-tpl-products .sa-page-products .sa-section-header {
  margin-bottom: 2rem;
}

.sa-tpl-products .sa-page-products .sa-section-title {
  letter-spacing: -0.03em;
}

.sa-tpl-products .sa-page-products-sidebar {
  border-color: rgba(42, 53, 48, 0.95);
}

.sa-tpl-products .sa-page-products-sidebar .input {
  background: rgba(26, 34, 30, 0.55);
  border-color: rgba(42, 53, 48, 0.95);
}

.sa-tpl-products .sa-page-products-sidebar .input:focus {
  border-color: rgba(61, 220, 132, 0.55);
  outline: none;
  box-shadow: 0 0 0 3px rgba(61, 220, 132, 0.12);
}

.sa-page-products-empty {
  min-height: 22rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(18, 24, 22, 0.55);
  border-color: rgba(42, 53, 48, 0.95);
}

.sa-page-products-empty-fx {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 55% 50% at 50% 20%, rgba(61, 220, 132, 0.1), transparent 65%),
    linear-gradient(180deg, transparent 40%, rgba(11, 15, 12, 0.35) 100%);
}

.sa-page-products-empty-icon {
  box-shadow: inset 0 0 0 1px rgba(61, 220, 132, 0.12);
}

.sa-tpl-products .sa-page-products-items {
  align-items: stretch;
}

.sa-tpl-products .sa-product-card {
  height: 100%;
  background: rgba(18, 24, 22, 0.72);
}