/* =============================================================================
   AMB Walk'n Talk — WordPress and WooCommerce additions
   Everything the static site never had a screen for: the cart page, checkout,
   account, notices, blog and page templates, plus the small pieces the product
   template gained (variant selects, gallery thumbs, quantity stepper).

   assets/css/style.css is an unmodified copy of the original stylesheet, so
   every rule below is an addition — nothing here overrides the design, and a
   visual difference from the static site is a template bug, not a style clash.
   ========================================================================== */

/* ------------------------------------------------------------------ PAGES */

.amb-page {
  padding-top: clamp(40px, 7vw, 88px);
}

.amb-page__inner {
  max-width: 860px;
  margin: 0 auto;
}

.amb-page__head {
  margin-bottom: clamp(24px, 4vw, 44px);
}

.amb-page__media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 32px;
}

.amb-page__media img {
  display: block;
  width: 100%;
  height: auto;
}

.amb-page__body {
  color: var(--text-2);
  font-size: 1.02rem;
  line-height: 1.75;
}

.amb-page__body > * + * {
  margin-top: 1.1em;
}

.amb-page__body h2,
.amb-page__body h3,
.amb-page__body h4 {
  color: var(--text);
  line-height: 1.25;
  margin-top: 1.8em;
}

.amb-page__body h2 { font-size: clamp(1.35rem, 2.6vw, 1.75rem); }
.amb-page__body h3 { font-size: 1.1rem; }

.amb-page__body a {
  color: var(--green-light);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.amb-page__body ul,
.amb-page__body ol {
  padding-left: 1.3em;
}

.amb-page__body li + li {
  margin-top: .5em;
}

.amb-page__body img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
}

.amb-page__body table {
  width: 100%;
  border-collapse: collapse;
}

.amb-page__body th,
.amb-page__body td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

/* ------------------------------------------------------------ BLOG INDEX */

.amb-posts {
  display: grid;
  gap: 28px;
}

.amb-post {
  display: grid;
  grid-template-columns: minmax(0, 220px) 1fr;
  gap: 24px;
  align-items: start;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.amb-post__media img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
}

.amb-post__body h2 {
  font-size: 1.3rem;
  line-height: 1.3;
}

.amb-post__body h2 a {
  color: var(--text);
  text-decoration: none;
}

.amb-post__body h2 a:hover {
  color: var(--green-light);
}

.amb-post__meta {
  color: var(--text-3);
  font-size: .82rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  margin: 6px 0 10px;
}

.amb-post__body p {
  color: var(--text-2);
  line-height: 1.7;
}

@media (max-width: 720px) {
  .amb-post { grid-template-columns: 1fr; }
}

.amb-pagination {
  margin-top: 40px;
}

.amb-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  margin-right: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--text-2);
  text-decoration: none;
  font-weight: 600;
  font-size: .9rem;
}

.amb-pagination .page-numbers.current,
.amb-pagination .page-numbers:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

/* ----------------------------------------------------------- SEARCH FORM */

.amb-searchform {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  max-width: 460px;
}

.amb-searchform input[type="search"] {
  flex: 1;
  min-width: 0;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-2);
  font: inherit;
  color: var(--text);
}

.amb-searchform input[type="search"]:focus {
  outline: none;
  border-color: var(--green-light);
}

/* --------------------------------------------------------------- NOTICES */

.amb-notices:empty {
  display: none;
}

.amb-notices {
  max-width: var(--container);
  margin: 0 auto clamp(16px, 3vw, 28px);
  padding: 0 var(--gutter);
}

.woocommerce-message,
.woocommerce-error,
.woocommerce-info,
.woocommerce-notice {
  list-style: none;
  margin: 0 0 12px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--bg-2);
  color: var(--text);
  font-size: .95rem;
  box-shadow: var(--shadow-sm);
}

.woocommerce-message {
  border-left: 3px solid var(--green-light);
}

.woocommerce-error {
  border-left: 3px solid #b3261e;
}

.woocommerce-error li + li {
  margin-top: 6px;
}

.woocommerce-message .button,
.woocommerce-error .button,
.woocommerce-info .button {
  float: right;
  margin-left: 16px;
  color: var(--green-light);
  text-decoration: underline;
  background: none;
  border: 0;
  font: inherit;
  cursor: pointer;
}

/* ------------------------------------------------------ PRODUCT: VARIANTS */

/* WooCommerce's own selects drive the variation script and stay reachable by
   keyboard and screen readers; the pills above them are the visual control. */
.amb-variation-select {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.amb-variation-select select:focus-visible {
  position: static;
  width: auto;
  height: auto;
  clip: auto;
}

.amb-reset-variations {
  margin: -6px 0 14px;
  font-size: .85rem;
}

.amb-reset-variations a {
  color: var(--text-3);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.amb-reset-variations a:hover {
  color: var(--text);
}

.amb-variant-current {
  font-weight: 600;
  color: var(--text);
}

/* The variation script prints the chosen variant's price into this block. */
.woocommerce-variation-price {
  display: block;
  margin: 4px 0 18px;
}

.woocommerce-variation-price .price,
.woocommerce-variation-price .amount {
  font-size: clamp(1.6rem, 3.4vw, 2.1rem);
  font-weight: 700;
  color: var(--text);
  letter-spacing: -.02em;
}

.woocommerce-variation-price del {
  color: var(--text-3);
  font-size: 1rem;
  font-weight: 500;
  margin-right: 10px;
}

.woocommerce-variation-price del .amount {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-3);
}

.woocommerce-variation-price ins {
  text-decoration: none;
}

.product-detail__stock {
  margin: 0 0 14px;
  font-size: .9rem;
  color: var(--text-2);
}

.product-detail__stock.out-of-stock,
.stock.out-of-stock {
  color: #b3261e;
  font-weight: 600;
}

.product-detail__long {
  margin: 24px 0 0;
  color: var(--text-2);
  line-height: 1.75;
}

.product-detail__long > * + * {
  margin-top: 1em;
}

/* -------------------------------------------------- PRODUCT: GALLERY THUMBS */

.product-detail__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.product-detail__thumb {
  width: 66px;
  height: 66px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-2);
  cursor: pointer;
  transition: border-color .2s var(--ease);
}

.product-detail__thumb.is-active,
.product-detail__thumb:hover {
  border-color: var(--green-light);
}

.product-detail__thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* --------------------------------------------------- QUANTITY + BUTTONS */

.quantity {
  display: inline-flex;
  align-items: center;
  margin: 0 0 14px;
}

.quantity label {
  margin-right: 10px;
  font-size: .9rem;
  color: var(--text-2);
}

.quantity input.qty {
  width: 74px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-2);
  font: inherit;
  font-weight: 600;
  color: var(--text);
  text-align: center;
}

.quantity input.qty:focus {
  outline: none;
  border-color: var(--green-light);
}

.product-detail__actions .btn[disabled] {
  opacity: .6;
  cursor: progress;
}

.product-detail__actions .btn.is-added {
  opacity: .8;
}

.qv__foot {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* -------------------------------------------------------- CART + CHECKOUT */

.woocommerce table.shop_table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 28px;
}

.woocommerce table.shop_table th,
.woocommerce table.shop_table td {
  padding: 14px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

.woocommerce table.shop_table th {
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-3);
  font-weight: 700;
}

.woocommerce table.shop_table img {
  width: 64px;
  height: auto;
  border-radius: var(--radius-sm);
}

.woocommerce table.shop_table .product-remove a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--text-2);
  text-decoration: none;
  font-weight: 700;
}

.woocommerce table.shop_table .product-remove a:hover {
  background: var(--green);
  color: #fff;
}

.woocommerce .cart-collaterals,
.woocommerce .cross-sells {
  margin-top: 32px;
}

.woocommerce .cart_totals h2,
.woocommerce-checkout h3,
.woocommerce-billing-fields h3,
.woocommerce-shipping-fields h3,
.woocommerce-additional-fields h3 {
  font-size: 1.15rem;
  margin-bottom: 14px;
  color: var(--text);
}

.woocommerce .coupon {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

/* WooCommerce prints its own <button class="button">; give it the theme's
   primary pill rather than leaving it unstyled. */
.woocommerce .button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce a.button,
.woocommerce #respond input#submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border: 0;
  border-radius: 999px;
  background: var(--green);
  color: #fff;
  font: inherit;
  font-weight: 600;
  font-size: .95rem;
  line-height: 1;
  cursor: pointer;
  text-decoration: none;
  transition: background .2s var(--ease), transform .2s var(--ease);
}

.woocommerce .button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button:hover {
  background: var(--green-dark);
  transform: translateY(-1px);
}

.woocommerce .button:disabled,
.woocommerce .button.disabled {
  opacity: .5;
  cursor: not-allowed;
  transform: none;
}

.woocommerce #place_order,
.woocommerce .checkout-button {
  width: 100%;
  padding: 16px 26px;
  font-size: 1rem;
}

.woocommerce form .form-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.woocommerce form .form-row label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-2);
}

.woocommerce form .form-row .required {
  color: #b3261e;
  text-decoration: none;
}

.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce .select2-container .select2-selection--single {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-2);
  font: inherit;
  color: var(--text);
  height: auto;
}

.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus {
  outline: none;
  border-color: var(--green-light);
}

.woocommerce form .form-row textarea {
  min-height: 110px;
  resize: vertical;
}

@media (min-width: 720px) {
  .woocommerce form .form-row-first,
  .woocommerce form .form-row-last {
    display: inline-flex;
    width: calc(50% - 8px);
  }
  .woocommerce form .form-row-first { margin-right: 16px; }
}

.woocommerce-checkout #payment {
  margin-top: 20px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-3);
}

.woocommerce-checkout #payment ul.payment_methods {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
}

.woocommerce-checkout #payment ul.payment_methods li + li {
  margin-top: 12px;
}

.woocommerce-checkout #payment .payment_box {
  margin-top: 8px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: .9rem;
  color: var(--text-2);
}

.woocommerce-checkout-review-order-table tfoot th,
.woocommerce-checkout-review-order-table tfoot td {
  font-weight: 700;
  color: var(--text);
}

.woocommerce .woocommerce-order,
.woocommerce .woocommerce-MyAccount-content {
  color: var(--text-2);
  line-height: 1.7;
}

.woocommerce-MyAccount-navigation ul {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.woocommerce-MyAccount-navigation a {
  display: inline-block;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text-2);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 600;
}

.woocommerce-MyAccount-navigation .is-active a,
.woocommerce-MyAccount-navigation a:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

/* ----------------------------------------------------------- PAGINATION */

.woocommerce-pagination ul.page-numbers {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0;
  margin: 40px 0 0;
  justify-content: center;
}

.woocommerce-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--text-2);
  text-decoration: none;
  font-weight: 600;
  font-size: .9rem;
}

.woocommerce-pagination .page-numbers.current,
.woocommerce-pagination .page-numbers:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}

/* --------------------------------------------------------- FOOTER WIDGET */

.footer__note {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter) 24px;
}

.footer__widget + .footer__widget {
  margin-top: 16px;
}
