.btn {
  border: none;
  border-radius: var(--radius-md);
  padding: 12px 18px;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition), border-color var(--transition), color var(--transition);
}

.btn.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  box-shadow: var(--glow);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.btn.secondary {
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(8px);
  color: var(--ink);
  border: 1px solid var(--border);
}

.btn.ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--ink);
}

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

.btn.icon-only {
  padding: 10px 12px;
  font-size: 16px;
  line-height: 1;
}

.btn:active {
  transform: translateY(0);
  box-shadow: none;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.card-soft {
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.card:hover,
.card-soft:hover {
  transform: translateY(-4px);
  border-color: rgba(139, 18, 36, 0.45);
  box-shadow: var(--shadow-strong);
}

.grid-2 {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid-3 {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.hero {
  display: grid;
  gap: 32px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: center;
}

.hero h1 {
  font-size: 42px;
  margin: 12px 0 16px;
}

.hero p {
  color: var(--muted);
  margin-bottom: 20px;
}

.hero-panel {
  background: rgba(18, 22, 32, 0.72);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  max-width: 420px;
  justify-self: end;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(176, 141, 87, 0.35);
  font-size: 12px;
  color: var(--gold);
  background: rgba(176, 141, 87, 0.08);
}

.input {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(14, 18, 26, 0.8);
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
}

.input:focus {
  outline: none;
  border-color: rgba(139, 18, 36, 0.6);
  box-shadow: 0 0 0 3px rgba(139, 18, 36, 0.2);
  background: rgba(17, 21, 30, 0.9);
}

.form-grid {
  display: grid;
  gap: 16px;
}

.product-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.product-card img {
  width: 100%;
  border-radius: var(--radius-md);
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #11151c;
  border: 1px solid var(--border-subtle);
}

.cart-pill {
  border-radius: 999px;
  border: 1px solid rgba(139, 18, 36, 0.4);
  background: rgba(20, 24, 33, 0.8);
  padding: 8px 14px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 0 0 1px rgba(139, 18, 36, 0.25), 0 8px 18px rgba(0, 0, 0, 0.35);
  transition: transform var(--transition), box-shadow var(--transition);
}

.cart-pill.icon-only {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  font-size: 16px;
  line-height: 1;
}

.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 0 5px;
  margin-left: 2px;
}

.cart-pill:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 0 1px rgba(139, 18, 36, 0.45), 0 12px 26px rgba(0, 0, 0, 0.45);
}

.cart-drawer {
  position: fixed;
  top: 86px;
  right: 24px;
  width: min(360px, 92vw);
  z-index: 1200;
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition);
}

.cart-drawer.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.cart-panel {
  background: rgba(18, 22, 32, 0.96);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-strong);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  border-radius: var(--radius-lg);
  max-height: min(72vh, 520px);
  overflow: hidden;
  position: relative;
}

.cart-panel::before {
  content: "";
  position: absolute;
  top: -8px;
  right: 28px;
  width: 16px;
  height: 16px;
  background: rgba(18, 22, 32, 0.96);
  border-left: 1px solid var(--border);
  border-top: 1px solid var(--border);
  transform: rotate(45deg);
}

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cart-items {
  flex: 1;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cart-item {
  display: flex;
  gap: 12px;
  align-items: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px;
  justify-content: space-between;
}

@media (max-width: 680px) {
  .cart-drawer {
    right: 12px;
    left: 12px;
    width: auto;
    top: 72px;
  }

  .cart-panel::before {
    right: 24px;
  }
}

.cart-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.cart-line {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.cart-item-title {
  font-weight: 600;
}

.cart-item-meta {
  font-size: 12px;
  color: var(--muted);
}

.cart-qty {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.cart-qty button {
  border: 1px solid var(--border);
  background: transparent;
  border-radius: 6px;
  padding: 4px 8px;
  cursor: pointer;
}

.cart-remove {
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  cursor: pointer;
}

.cart-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 16px;
}

.cart-actions {
  display: grid;
  gap: 10px;
}

.cart-close {
  line-height: 1;
  padding: 4px 10px;
}

.divider {
  height: 1px;
  background: var(--border);
}

@media (max-width: 900px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 32px;
  }
}
