.tbg-section {
  padding-block: clamp(2rem, 5vw, 4.5rem);
}

.tbg-section + .tbg-section {
  border-top: 1px solid var(--tbg-border);
}

.tbg-eyebrow {
  margin: 0 0 0.5rem;
  color: var(--tbg-olive);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.3;
  text-transform: uppercase;
}

.tbg-lead {
  max-width: 62ch;
  color: var(--tbg-muted);
  font-size: clamp(1.05rem, 2vw, 1.25rem);
}

.tbg-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr));
  gap: clamp(0.75rem, 2vw, 1.25rem);
}

.tbg-card {
  overflow: hidden;
  border: 1px solid var(--tbg-border);
  border-radius: var(--tbg-radius-lg);
  background: var(--tbg-surface);
  box-shadow: var(--tbg-shadow-sm);
}

.tbg-card__body {
  padding: clamp(1rem, 3vw, 1.5rem);
}

.tbg-card__body > :first-child {
  margin-top: 0;
}

.tbg-card__body > :last-child {
  margin-bottom: 0;
}

.tbg-button,
body.tbg-site .wp-element-button,
body.tbg-site button:not(.components-button):not(.wp-block-navigation__responsive-container-open):not(.wp-block-navigation__responsive-container-close) {
  min-height: var(--tbg-touch);
  border: 1px solid transparent;
  border-radius: 10px;
  font-weight: 650;
  line-height: 1.2;
  text-decoration: none;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.tbg-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.72rem 1.25rem;
  background: var(--tbg-forest);
  color: var(--tbg-surface);
}

.tbg-button:hover,
body.tbg-site .wp-element-button:hover {
  background: var(--tbg-dark);
  color: var(--tbg-surface);
}

.tbg-button:active,
body.tbg-site .wp-element-button:active {
  transform: translateY(1px);
}

.tbg-button--secondary {
  border-color: var(--tbg-forest);
  background: var(--tbg-surface);
  color: var(--tbg-forest);
}

.tbg-button--secondary:hover {
  border-color: var(--tbg-dark);
  background: var(--tbg-sage);
  color: var(--tbg-dark);
}

.tbg-button--quiet {
  border-color: var(--tbg-border);
  background: transparent;
  color: var(--tbg-dark);
}

.tbg-button--danger {
  background: var(--tbg-error);
  color: var(--tbg-surface);
}

.tbg-button[disabled],
.tbg-button[aria-disabled="true"],
body.tbg-site button[disabled] {
  cursor: not-allowed;
  opacity: 0.48;
}

.tbg-field {
  display: grid;
  gap: 0.4rem;
}

.tbg-field label,
.tbg-field__label {
  color: var(--tbg-dark);
  font-size: 0.875rem;
  font-weight: 650;
}

.tbg-field :where(input, select, textarea),
body.tbg-site :where(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  width: 100%;
  min-height: var(--tbg-touch);
  border: 1px solid var(--tbg-border);
  border-radius: 10px;
  padding: 0.68rem 0.8rem;
  background: var(--tbg-surface);
  color: var(--tbg-ink);
}

.tbg-field :where(input, select, textarea):hover,
body.tbg-site :where(input:not([type="checkbox"]):not([type="radio"]), select, textarea):hover {
  border-color: var(--tbg-leaf);
}

.tbg-field :where(input, select, textarea)[aria-invalid="true"] {
  border-color: var(--tbg-error);
  box-shadow: 0 0 0 1px var(--tbg-error);
}

.tbg-field__help {
  color: var(--tbg-muted);
  font-size: 0.75rem;
}

.tbg-field__error {
  color: var(--tbg-error);
  font-size: 0.75rem;
  font-weight: 600;
}

.tbg-notice {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  align-items: start;
  padding: 0.9rem 1rem;
  border: 1px solid var(--tbg-border);
  border-left: 4px solid var(--tbg-forest);
  border-radius: var(--tbg-radius-md);
  background: var(--tbg-sage);
  color: var(--tbg-dark);
}

.tbg-notice--success {
  border-left-color: var(--tbg-success);
}

.tbg-notice--warning {
  border-left-color: #a87800;
  background: #fff9df;
}

.tbg-notice--error {
  border-left-color: var(--tbg-error);
  background: #fff1f1;
}

.tbg-badge {
  display: inline-flex;
  align-items: center;
  min-height: 1.75rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--tbg-radius-pill);
  background: var(--tbg-sage);
  color: var(--tbg-forest);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
}

.tbg-badge--sale {
  background: var(--tbg-harvest);
  color: var(--tbg-dark);
}

.tbg-quantity {
  width: max-content;
  min-width: 8.5rem;
  display: grid;
  grid-template-columns: var(--tbg-touch) minmax(2.5rem, 1fr) var(--tbg-touch);
  align-items: center;
  overflow: hidden;
  border: 2px solid var(--tbg-forest);
  border-radius: 10px;
  background: var(--tbg-surface);
}

.tbg-quantity button {
  width: var(--tbg-touch);
  min-height: var(--tbg-touch);
  border: 0 !important;
  border-radius: 0 !important;
  padding: 0;
  background: var(--tbg-dark);
  color: var(--tbg-surface);
  font-size: 1.25rem;
}

.tbg-quantity output {
  padding-inline: 0.4rem;
  color: var(--tbg-dark);
  font-size: 0.8rem;
  font-weight: 650;
  text-align: center;
  white-space: nowrap;
}

.tbg-empty-state {
  padding: clamp(2rem, 6vw, 4rem) 1.25rem;
  border: 1px dashed var(--tbg-border);
  border-radius: var(--tbg-radius-lg);
  background: var(--tbg-cream);
  text-align: center;
}

.tbg-empty-state > * {
  max-width: 52ch;
  margin-inline: auto;
}

@media (max-width: 640px) {
  .tbg-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.6rem;
  }

  .tbg-card__body {
    padding: 0.8rem;
  }
}

@media (max-width: 380px) {
  .tbg-card-grid {
    grid-template-columns: 1fr;
  }
}
