/* cart.css — styles for Add to Cart widget, cart page, order success, and admin orders */

/* ─── Cart badge in navbar ─── */
.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #6B7D33;
  color: #fff;
  font-size: 10px;
  font-family: 'DM Mono', monospace;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  margin-left: 4px;
  vertical-align: middle;
}

/* ─── Add to Cart widget on product page ─── */
.cart-cta-card {
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: 4px;
  padding: 28px 24px;
  margin-top: 24px;
}

.cart-cta-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.cart-price-display {
  text-align: right;
}

.cart-price-amount {
  font-family: 'Oswald', sans-serif;
  font-size: 28px;
  font-weight: 600;
  color: #F0EDE6;
  letter-spacing: 0.02em;
}

.cart-option-group {
  margin-bottom: 18px;
}

.cart-option-label {
  display: block;
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #666;
  margin-bottom: 8px;
}

.cart-option-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cart-pill {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  color: #A89E83;
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  padding: 6px 14px;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.15s ease;
  letter-spacing: 0.04em;
}

.cart-pill:hover {
  border-color: #444;
  color: #F0EDE6;
}

.cart-pill--active {
  background: #6B7D33;
  border-color: #6B7D33;
  color: #fff;
}

.cart-add-row {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 20px;
  margin-bottom: 12px;
}

.cart-qty-wrap {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid #2a2a2a;
  border-radius: 3px;
  overflow: hidden;
}

.cart-qty-btn {
  background: #1a1a1a;
  border: none;
  color: #A89E83;
  font-size: 18px;
  width: 36px;
  height: 40px;
  cursor: pointer;
  transition: background 0.15s;
  font-family: 'DM Mono', monospace;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-qty-btn:hover {
  background: #252525;
  color: #F0EDE6;
}

.cart-qty-val {
  font-family: 'DM Mono', monospace;
  font-size: 14px;
  color: #F0EDE6;
  width: 36px;
  text-align: center;
  background: #111;
}

.cart-add-btn {
  flex: 1;
  background: #6B7D33;
  border: none;
  color: #fff;
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 12px 20px;
  border-radius: 3px;
  cursor: pointer;
  transition: background 0.15s;
}

.cart-add-btn:hover {
  background: #7a8f3a;
}

.cart-shipping-note {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: #555;
  margin: 8px 0 0;
  letter-spacing: 0.04em;
}

.cart-added-msg {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: #6B7D33;
  margin-top: 10px;
  letter-spacing: 0.04em;
}

.cart-added-link {
  color: #6B7D33;
  text-decoration: underline;
}

/* ─── Cart page ─── */
.cart-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 24px 80px;
}

.cart-page-header {
  margin-bottom: 40px;
}

.cart-page-title {
  font-family: 'Oswald', sans-serif;
  font-size: 40px;
  font-weight: 700;
  text-transform: uppercase;
  color: #F0EDE6;
  letter-spacing: 0.04em;
  margin: 8px 0 0;
}

.cart-empty {
  text-align: center;
  padding: 80px 0;
}

.cart-empty-text {
  font-family: 'DM Mono', monospace;
  color: #666;
  margin-bottom: 24px;
}

.cart-empty-cta {
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #6B7D33;
  text-decoration: none;
  text-transform: uppercase;
}

.cart-content {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

.cart-items {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.cart-item {
  display: flex;
  gap: 20px;
  background: #111;
  border: 1px solid #1e1e1e;
  border-radius: 4px;
  padding: 20px;
  align-items: center;
}

.cart-item-img-wrap {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
  border-radius: 3px;
  overflow: hidden;
}

.cart-item-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cart-item-info {
  flex: 1;
  min-width: 0;
}

.cart-item-name {
  font-family: 'Oswald', sans-serif;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #F0EDE6;
  margin-bottom: 4px;
}

.cart-item-meta {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: #666;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}

.cart-item-price {
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  color: #A89E83;
}

.cart-item-controls {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  flex-shrink: 0;
}

.cart-item-line-total {
  font-family: 'Oswald', sans-serif;
  font-size: 20px;
  font-weight: 600;
  color: #F0EDE6;
}

.cart-item-remove {
  background: none;
  border: none;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: #555;
  cursor: pointer;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0;
}

.cart-item-remove:hover { color: #c44; }

/* ─── Order summary sidebar ─── */
.cart-summary {
  width: 320px;
  flex-shrink: 0;
}

.cart-summary-inner {
  background: #111;
  border: 1px solid #1e1e1e;
  border-radius: 4px;
  padding: 24px;
  position: sticky;
  top: 24px;
}

.cart-summary-rows {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 16px 0;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 14px;
  color: #A89E83;
}

.cart-summary-row--total {
  font-family: 'Oswald', sans-serif;
  font-size: 22px;
  font-weight: 600;
  color: #F0EDE6;
  letter-spacing: 0.02em;
}

.cart-summary-free-shipping {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: #6B7D33;
  letter-spacing: 0.04em;
}

.cart-summary-divider {
  height: 1px;
  background: #1e1e1e;
  margin: 16px 0;
}

.cart-summary-note {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: #555;
  letter-spacing: 0.04em;
  margin: 12px 0 20px;
}

.cart-checkout-btn {
  width: 100%;
  background: #6B7D33;
  border: none;
  color: #fff;
  font-family: 'Oswald', sans-serif;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 14px;
  border-radius: 3px;
  cursor: pointer;
  transition: background 0.15s;
}

.cart-checkout-btn:hover:not(:disabled) { background: #7a8f3a; }
.cart-checkout-btn:disabled { opacity: 0.6; cursor: not-allowed; }

.cart-error-msg {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: #c44;
  margin-top: 10px;
  letter-spacing: 0.04em;
}

.cart-summary-security {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: #444;
  text-align: center;
  margin-top: 14px;
  letter-spacing: 0.04em;
}

/* ─── Order success page ─── */
.success-page {
  max-width: 600px;
  margin: 0 auto;
  padding: 60px 24px 80px;
  text-align: center;
}

.success-icon {
  font-size: 48px;
  color: #6B7D33;
  margin-bottom: 16px;
  line-height: 1;
}

.success-title {
  font-family: 'Oswald', sans-serif;
  font-size: 42px;
  font-weight: 700;
  text-transform: uppercase;
  color: #F0EDE6;
  letter-spacing: 0.04em;
  margin: 8px 0 12px;
}

.success-subtitle {
  font-family: 'Source Sans 3', sans-serif;
  font-size: 16px;
  color: #A89E83;
  line-height: 1.7;
  margin-bottom: 32px;
}

.success-order-card {
  background: #111;
  border: 1px solid #1e1e1e;
  border-radius: 4px;
  padding: 24px;
  text-align: left;
  margin-bottom: 28px;
}

.success-order-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.success-order-id {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: #666;
  letter-spacing: 0.08em;
}

.success-line-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #1a1a1a;
}

.success-item-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.success-item-name {
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #F0EDE6;
  letter-spacing: 0.04em;
}

.success-item-meta {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: #666;
  letter-spacing: 0.06em;
}

.success-item-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.success-item-qty {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: #666;
}

.success-item-price {
  font-family: 'Oswald', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #F0EDE6;
}

.success-totals {
  margin-top: 16px;
}

.success-total-row {
  display: flex;
  justify-content: space-between;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 14px;
  color: #A89E83;
  padding: 4px 0;
}

.success-total-row--bold {
  font-family: 'Oswald', sans-serif;
  font-size: 20px;
  font-weight: 600;
  color: #F0EDE6;
  padding-top: 10px;
  margin-top: 8px;
  border-top: 1px solid #1e1e1e;
}

.success-promise {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: #555;
  letter-spacing: 0.06em;
  margin-bottom: 36px;
}

.success-actions {
  display: flex;
  justify-content: center;
  gap: 16px;
}

.success-btn-secondary {
  font-family: 'Oswald', sans-serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #A89E83;
  text-decoration: none;
  border: 1px solid #2a2a2a;
  padding: 10px 24px;
  border-radius: 3px;
  transition: all 0.15s;
}

.success-btn-secondary:hover {
  border-color: #444;
  color: #F0EDE6;
}

/* ─── Admin orders page ─── */
.admin-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 48px 24px 80px;
}

.admin-header {
  margin-bottom: 32px;
}

.admin-title {
  font-family: 'Oswald', sans-serif;
  font-size: 36px;
  font-weight: 700;
  text-transform: uppercase;
  color: #F0EDE6;
  letter-spacing: 0.04em;
  margin: 8px 0 4px;
}

.admin-subtitle {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: #666;
  letter-spacing: 0.06em;
}

.admin-empty {
  text-align: center;
  padding: 60px 0;
}

.admin-empty p { color: #666; font-family: 'DM Mono', monospace; }

.admin-empty-link {
  color: #6B7D33;
  font-family: 'Oswald', sans-serif;
  font-size: 15px;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.admin-stats {
  display: flex;
  gap: 32px;
  margin-bottom: 32px;
}

.admin-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.admin-stat-val {
  font-family: 'Oswald', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: #F0EDE6;
}

.admin-stat-label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.admin-table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 14px;
}

.admin-table th {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #666;
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid #1e1e1e;
  white-space: nowrap;
}

.admin-row td {
  padding: 12px;
  border-bottom: 1px solid #111;
  vertical-align: top;
}

.admin-cell { color: #A89E83; }
.admin-cell--id { font-family: 'DM Mono', monospace; font-size: 12px; color: #666; }
.admin-cell--date { font-family: 'DM Mono', monospace; font-size: 12px; white-space: nowrap; }
.admin-cell--total { font-family: 'Oswald', sans-serif; font-size: 16px; font-weight: 600; color: #F0EDE6; }

.admin-line-item {
  font-size: 13px;
  color: #A89E83;
  margin-bottom: 3px;
}

.admin-status {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 3px;
}

.admin-status--paid { background: rgba(107,125,51,0.2); color: #6B7D33; }
.admin-status--pending { background: rgba(168,158,131,0.1); color: #666; }

/* ─── Responsive ─── */
@media (max-width: 768px) {
  .cart-content { flex-direction: column; }
  .cart-summary { width: 100%; }
  .cart-item { flex-wrap: wrap; }
  .cart-item-controls { flex-direction: row; align-items: center; width: 100%; justify-content: space-between; }
  .admin-stats { flex-wrap: wrap; gap: 20px; }
  .cart-add-row { flex-direction: column; }
  .cart-add-btn { width: 100%; }
}
