/* ═══════════════════════════════════════════════════════════════
   THE COUNTY — WooCommerce Checkout Customization
   Dark brutalist / luxury aesthetic for checkout pages
═══════════════════════════════════════════════════════════════ */

:root {
  --cream:        #fefcef;
  --sand:         #dedcd0;
  --sand-75:      rgba(222,220,208,0.75);
  --sand-55:      rgba(222,220,208,0.55);
  --sand-40:      rgba(222,220,208,0.4);
  --sand-25:      rgba(222,220,208,0.25);
  --sand-12:      rgba(222,220,208,0.12);
  --sand-06:      rgba(222,220,208,0.06);
  --bg:           #080808;
  --danger:       #c94040;
  --easing:       cubic-bezier(.22,.61,.36,1);
}

/* ─── GLOBAL STYLES ─── */
body.woocommerce,
body.woocommerce-page {
  background: var(--bg);
  color: var(--cream);
  font-family: Montserrat, Arial, sans-serif;
}

.woocommerce,
.woocommerce-page {
  background: var(--bg);
}

/* ─── CHECKOUT PAGE ─── */
.woocommerce-checkout {
  background: var(--bg);
}

.woocommerce form .form-row {
  margin-bottom: 1.5rem;
}

.woocommerce form .form-row input,
.woocommerce form .form-row select,
.woocommerce form .form-row textarea {
  border: 1px solid var(--sand-12);
  background: var(--sand-06);
  color: var(--cream);
  padding: 12px 16px;
  font-size: 14px;
  font-family: Montserrat, Arial, sans-serif;
  transition: border-color 0.2s, background 0.2s;
}

.woocommerce form .form-row input:focus,
.woocommerce form .form-row select:focus,
.woocommerce form .form-row textarea:focus {
  border-color: var(--sand-40);
  background: rgba(222,220,208,0.09);
  outline: none;
  box-shadow: none;
}

.woocommerce form .form-row label {
  color: var(--sand-40);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  display: block;
  margin-bottom: 0.6rem;
}

.woocommerce form .form-row.form-row-wide {
  width: 100%;
}

/* ─── CHECKOUT FORM ─── */
.woocommerce-checkout .woocommerce-billing-fields h3,
.woocommerce-checkout .woocommerce-shipping-fields h3,
.woocommerce-checkout .woocommerce-additional-fields h3 {
  font-size: clamp(1.1rem, 1.6vw, 1.4rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--cream);
  text-transform: uppercase;
  padding-bottom: 1.4rem;
  margin-bottom: 1.4rem;
  border-bottom: 1px solid var(--sand-12);
}

/* ─── ORDER REVIEW ─── */
.woocommerce table.shop_table {
  background: transparent;
  border: 1px solid var(--sand-12);
  width: 100%;
}

.woocommerce table.shop_table thead th {
  background: var(--sand-06);
  border: none;
  color: var(--cream);
  padding: 1.2rem;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--sand-12);
}

.woocommerce table.shop_table tbody tr {
  border-bottom: 1px solid var(--sand-12);
}

.woocommerce table.shop_table tbody tr td {
  background: transparent;
  color: var(--cream);
  padding: 1.2rem;
  vertical-align: middle;
}

.woocommerce table.shop_table tbody tr:last-child {
  border-bottom: none;
}

.woocommerce table.shop_table tbody tr:hover {
  background: rgba(222,220,208,0.03);
}

/* ─── TOTALS TABLE ─── */
.woocommerce table.shop_table tfoot th,
.woocommerce table.shop_table tfoot td {
  background: rgba(222,220,208,0.06);
  border: 1px solid var(--sand-12);
  color: var(--cream);
  padding: 1rem 1.2rem;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.woocommerce table.shop_table tfoot .order-total th,
.woocommerce table.shop_table tfoot .order-total td {
  background: rgba(222,220,208,0.09);
  border-color: var(--sand-25);
  font-weight: 700;
  font-size: 12px;
}

/* ─── PAYMENT METHODS ─── */
.woocommerce #payment ul {
  border: none;
  background: transparent;
}

.woocommerce #payment ul li {
  border: 1px solid var(--sand-12);
  background: var(--sand-06);
  padding: 1rem;
  margin-bottom: 1px;
  list-style: none;
}

.woocommerce #payment ul li:hover {
  border-color: var(--sand-25);
  background: rgba(222,220,208,0.08);
}

.woocommerce #payment ul li.woocommerce-notice {
  border: none;
  background: transparent;
  padding: 0;
}

.woocommerce #payment ul li label {
  display: block;
  color: var(--cream);
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.woocommerce #payment ul li input[type="radio"] {
  margin-right: 0.5rem;
}

/* ─── BUTTONS ─── */
.woocommerce button.button,
.woocommerce input[type="button"],
.woocommerce input[type="submit"],
button.button.alt {
  background: var(--sand);
  color: #080808;
  border: 1px solid var(--sand);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  padding: 1rem 1.5rem;
  cursor: pointer;
  transition: all 0.3s var(--easing);
  border-radius: 0;
}

.woocommerce button.button:hover,
.woocommerce input[type="button"]:hover,
.woocommerce input[type="submit"]:hover,
button.button.alt:hover {
  background: var(--cream);
  border-color: var(--cream);
}

.woocommerce button.button:disabled,
.woocommerce input[type="submit"]:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ─── CHECKBOXES ─── */
.woocommerce form .form-row input[type="checkbox"],
.woocommerce form .form-row input[type="radio"] {
  width: 16px;
  height: 16px;
  margin-right: 0.5rem;
  cursor: pointer;
  accent-color: var(--sand);
}

.woocommerce form .form-row input[type="checkbox"] + label,
.woocommerce form .form-row input[type="radio"] + label {
  display: inline;
  margin: 0;
  font-size: 12px;
  color: var(--sand-75);
  cursor: pointer;
  user-select: none;
}

/* ─── NOTICES ─── */
.woocommerce .woocommerce-notice,
.woocommerce .woocommerce-info,
.woocommerce .woocommerce-error,
.woocommerce .woocommerce-message {
  background: rgba(222,220,208,0.08);
  border: 1px solid var(--sand-25);
  color: var(--cream);
  padding: 1.2rem;
  margin-bottom: 1.5rem;
  border-radius: 0;
  list-style: none;
}

.woocommerce .woocommerce-error {
  border-color: var(--danger);
  background: rgba(201,64,64,0.08);
}

.woocommerce .woocommerce-error li::before {
  content: none;
}

/* ─── ORDER DETAILS ─── */
.woocommerce-order {
  background: var(--bg);
}

.woocommerce-order-details {
  border: 1px solid var(--sand-12);
  background: var(--sand-06);
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.woocommerce-order-details h2 {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cream);
  margin-bottom: 1.2rem;
  border-bottom: 1px solid var(--sand-12);
  padding-bottom: 1rem;
}

.woocommerce-order-details .order-items {
  margin: 1.5rem 0;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 600px) {
  .woocommerce-checkout-review-order {
    margin-top: 2rem;
  }

  .woocommerce table.shop_table thead {
    display: none;
  }

  .woocommerce table.shop_table tbody tr {
    display: block;
    border: 1px solid var(--sand-12);
    background: var(--sand-06);
    margin-bottom: 1px;
    padding: 1rem;
  }

  .woocommerce table.shop_table tbody tr td {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border: none;
  }

  .woocommerce table.shop_table tbody tr td::before {
    content: attr(data-title);
    font-weight: 700;
    color: var(--sand-40);
    text-transform: uppercase;
    font-size: 10px;
    letter-spacing: 0.08em;
  }
}

/* ─── SHIPPING/PAYMENT FIELDS ─── */
.woocommerce-shipping-fields,
.woocommerce-additional-fields {
  margin-top: 2rem;
}

.woocommerce-shipping-fields h3,
.woocommerce-additional-fields h3 {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cream);
  padding-bottom: 0.8rem;
  margin-bottom: 1.2rem;
  border-bottom: 1px solid var(--sand-12);
}

/* ─── ACCOUNT LOGIN ─── */
.woocommerce-form {
  background: transparent;
  border: none;
  padding: 0;
}

.woocommerce-form-login {
  background: var(--sand-06);
  border: 1px solid var(--sand-12);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

/* ─── PROCEED TO CHECKOUT ─── */
.woocommerce a.checkout-button {
  display: inline-block;
  background: var(--sand);
  color: #080808;
  border: 1px solid var(--sand);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  padding: 1rem 1.5rem;
  transition: all 0.3s var(--easing);
  text-decoration: none;
}

.woocommerce a.checkout-button:hover {
  background: var(--cream);
  border-color: var(--cream);
}

/* ─── COUPON FORM ─── */
.woocommerce .coupon {
  display: flex;
  gap: 1px;
  margin-bottom: 1.5rem;
}

.woocommerce .coupon input {
  flex: 1;
  padding: 0.9rem 1rem;
  background: var(--sand-06);
  border: 1px solid var(--sand-12);
  color: var(--cream);
  font-size: 12px;
}

.woocommerce .coupon button {
  padding: 0.9rem 1.5rem;
  background: rgba(222,220,208,0.1);
  border: 1px solid var(--sand-25);
  color: var(--cream);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
}

.woocommerce .coupon button:hover {
  background: rgba(222,220,208,0.15);
  border-color: var(--cream);
}
