/*
 * S. B. Collins — theme stylesheet.
 *
 * Only rules for markup that has no counterpart in the source design
 * (WooCommerce output, form state, reveal engine scaffolding) plus the
 * functional hooks the theme's JavaScript drives. All designed elements are
 * styled by assets/css/app.css through their source class lists.
 */

/* Match Lovable root: min-h-screen + overflow-x-clip (not hidden — keeps sticky). */
html {
  overflow-x: clip;
}

html:has(body.is-customizer) {
  scroll-behavior: auto !important;
}

body {
  overflow-x: clip;
  min-height: 100svh;
}

main {
  min-width: 0;
}

img,
video,
svg {
  max-width: 100%;
}

/* ---------------------------------------------------------------
   Reveal engine
   Initial-hidden states mirror the source motion variants per element;
   inline custom properties are written by main.js.
   --------------------------------------------------------------- */
.theme-reveal {
  opacity: 0;
  transform: translate3d(var(--reveal-x, 0px), var(--reveal-y, 20px), 0)
    scale(var(--reveal-scale, 1));
  transform-origin: center center;
}

.theme-reveal.is-visible {
  opacity: 1;
  transform: none;
  transition:
    opacity var(--reveal-duration, 0.75s) cubic-bezier(0.22, 1, 0.36, 1) var(--reveal-delay, 0s),
    transform var(--reveal-duration, 0.75s) cubic-bezier(0.22, 1, 0.36, 1) var(--reveal-delay, 0s);
}

/* Fallbacks: never hide content in the Customizer preview, without JS, or
   when the observer cannot fire. */
body.is-customizer .theme-reveal,
.no-js .theme-reveal,
body.theme-reveal-fallback .theme-reveal {
  opacity: 1 !important;
  transform: none !important;
}

@media (prefers-reduced-motion: reduce) {
  .theme-reveal,
  .theme-reveal.is-visible {
    opacity: 1 !important;
    transform: none !important;
    transition: opacity 0.3s ease !important;
  }
}

/* Footer fade (source: FooterFade — opacity only, 1s ease-out) */
.theme-footer-fade {
  opacity: 0;
}

.theme-footer-fade.is-visible {
  opacity: 1;
  transition: opacity 1s ease-out;
}

body.is-customizer .theme-footer-fade,
.no-js .theme-footer-fade {
  opacity: 1 !important;
}

@media (prefers-reduced-motion: reduce) {
  .theme-footer-fade,
  .theme-footer-fade.is-visible {
    opacity: 1 !important;
    transition: opacity 0.2s ease !important;
  }
}

/* Hero cover pointer tilt + scroll parallax (source: HeroCover) */
.theme-hero-cover {
  transform: perspective(1200px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg))
    translate3d(var(--shift-x, 0px), var(--parallax-y, 0px), 0);
  transition: transform 320ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
  .theme-hero-cover {
    transform: none !important;
    transition: none !important;
  }
}

/* Article dialog (Crow's Nest). Position comes from the source classes;
   the enter/exit motion animates opacity and `top`, which no utility sets,
   so it cannot fight Tailwind's `translate` property. */
.theme-article-overlay {
  opacity: 0;
  transition: opacity 200ms ease;
}

.theme-article-overlay.is-visible {
  opacity: 1;
}

.theme-article-modal {
  opacity: 0;
  transition:
    opacity 240ms cubic-bezier(0.22, 1, 0.36, 1),
    top 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.theme-article-modal.is-visible {
  opacity: 1;
  top: 50%;
}

body.article-open {
  overflow: hidden;
}

@media (prefers-reduced-motion: reduce) {
  .theme-article-overlay,
  .theme-article-modal {
    transition-duration: 0.01ms;
  }
}

/* ---------------------------------------------------------------
   Header states — the source swaps class strings on scroll; the theme
   toggles the same strings from main.js. These rules only cover the
   sticky positioning the source applies via the utility layer.
   --------------------------------------------------------------- */
.site-header {
  position: fixed;
}

/* Logged-in admin bar (Customizer preview included) must not cover the header. */
body.admin-bar .site-header {
  top: 32px;
}

body.admin-bar #theme-cart-drawer {
  top: 32px;
}

@media screen and (max-width: 782px) {
  body.admin-bar .site-header,
  body.admin-bar #theme-cart-drawer {
    top: 46px;
  }
}

.site-logo-img {
  height: var(--logo-height, 3.5rem);
  width: auto;
}

/* Height offset for the fixed header on inner pages only; the home hero
   starts at top: 0 and sits beneath the transparent header. */
.theme-no-hero .site-main {
  padding-top: 64px;
}

@media (min-width: 640px) {
  .theme-no-hero .site-main {
    padding-top: 80px;
  }
}

body.admin-bar.theme-no-hero .site-main {
  padding-top: calc(64px + 32px);
}

@media (min-width: 640px) {
  body.admin-bar.theme-no-hero .site-main {
    padding-top: calc(80px + 32px);
  }
}

@media screen and (max-width: 782px) {
  body.admin-bar.theme-no-hero .site-main {
    padding-top: calc(64px + 46px);
  }

  @media (min-width: 640px) {
    body.admin-bar.theme-no-hero .site-main {
      padding-top: calc(80px + 46px);
    }
  }
}

/* Pointer cursor on interactive elements (buttons ship with utilities; links
   and disclosure controls rely on this baseline). */
a[href]:not([aria-disabled='true']),
area[href],
button:not(:disabled),
summary,
label[for],
[role='button']:not([aria-disabled='true']),
.nav-link,
.link-underline,
[data-cart-open],
[data-cart-close],
[data-mobile-toggle],
[data-mobile-link],
[data-article-open],
[data-bio-toggle],
.theme-product-thumbnails button,
.theme-qty-minus,
.theme-qty-plus {
  cursor: pointer;
}

/* ---------------------------------------------------------------
   Mobile navigation panel (separate from desktop nav — Lovable source)
   --------------------------------------------------------------- */
#mobile-navigation[hidden] {
  display: none !important;
}

#mobile-navigation:not([hidden]) {
  display: block;
}

.theme-mobile-nav {
  max-height: calc(100svh - 4rem);
}

@media (min-width: 640px) {
  .theme-mobile-nav {
    max-height: calc(100svh - 5rem);
  }
}

/* Desktop primary menu: WP outputs <ul class="menu">; mirror Lovable flex row. */
#site-header ul.menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

#site-header ul.menu .menu-item {
  margin: 0;
  padding: 0;
}

@media (min-width: 1280px) {
  #site-header ul.menu.hidden {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.75rem;
  }
}

/* ---------------------------------------------------------------
   Cart drawer / overlay
   Visibility driven by body.cart-open. The drawer node is replaced by
   WooCommerce fragments, so open/close is a transition, never a keyframe.
   --------------------------------------------------------------- */
#theme-cart-overlay {
  position: fixed;
  inset: 0;
  z-index: 59;
  display: block;
  background-color: color-mix(in oklab, var(--charcoal) 70%, transparent);
  backdrop-filter: blur(2px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

body.cart-open #theme-cart-overlay {
  opacity: 1;
  pointer-events: auto;
}

#theme-cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 28rem;
  border-left: 1px solid color-mix(in oklab, var(--ivory) 10%, transparent);
  background-color: var(--navy-deep);
  color: var(--ivory);
  transform: translateX(100%);
  visibility: hidden;
  transition:
    transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 0.5s;
}

body.cart-open #theme-cart-drawer {
  transform: translateX(0);
  visibility: visible;
  transition:
    transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 0s;
}

@media (prefers-reduced-motion: reduce) {
  #theme-cart-drawer {
    transition: opacity 0.2s linear, visibility 0s linear 0.2s;
    opacity: 0;
  }

  body.cart-open #theme-cart-drawer {
    transition: opacity 0.2s linear, visibility 0s linear 0s;
    opacity: 1;
    transform: none;
  }
}

body.cart-open {
  overflow: hidden;
}

#theme-cart-drawer.is-updating > * {
  opacity: 0.6;
  pointer-events: none;
}

/* Cart badge: hidden when empty (source renders it only when count > 0). */
.theme-cart-count:empty {
  display: none;
}

/* ---------------------------------------------------------------
   Hide "View cart" injected by WooCommerce after AJAX add-to-cart.
   --------------------------------------------------------------- */
.woocommerce-page a.added_to_cart.wc-forward,
.single-product a.added_to_cart.wc-forward,
body a.added_to_cart.wc-forward {
  display: none !important;
}

/* Suppress WooCommerce's own spinner; the theme shows its own lock state. */
.single-product .single_add_to_cart_button.loading::after,
.ajax_add_to_cart.loading::after {
  display: none !important;
}

.ajax_add_to_cart.theme-btn-loading {
  opacity: 0.6 !important;
  pointer-events: none !important;
  cursor: wait !important;
}

/* Disabled add-to-cart states (variable products before a choice is made,
   and simple products that are out of stock). */
.single_add_to_cart_button.button:disabled,
.single_add_to_cart_button.button.disabled,
.add_to_cart_button.button:disabled,
.add_to_cart_button.button.disabled {
  cursor: not-allowed !important;
  opacity: 0.4 !important;
  pointer-events: none !important;
}

.single_add_to_cart_button.button:disabled:hover,
.single_add_to_cart_button.button.disabled:hover,
.add_to_cart_button.button:disabled:hover,
.add_to_cart_button.button.disabled:hover {
  opacity: 0.4 !important;
}

/* Hidden native variation selects (pills drive them). */
.theme-attr-select-hidden {
  display: none !important;
}

/* ---------------------------------------------------------------
   Quantity control — the visible numeric input is the source of truth.
   --------------------------------------------------------------- */
.theme-quantity-input {
  width: 2.5rem;
  min-width: 2.5rem;
  border: 0;
  background: transparent;
  text-align: center;
  font-size: 0.875rem;
  line-height: 1rem;
  color: var(--ivory);
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
  appearance: textfield;
}

.theme-quantity-input::-webkit-outer-spin-button,
.theme-quantity-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.theme-quantity-input:focus {
  outline: none;
}

/* ---------------------------------------------------------------
   Contact form states (source has no equivalent markup; values copied
   from the source field styles).
   --------------------------------------------------------------- */
.contact-form-status {
  margin-top: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--ivory);
}

.contact-form-status[data-state="error"] {
  color: #e9b9a8;
}

.contact-form-status[data-state="success"] {
  color: var(--gold-light);
}

.contact-form-status:empty {
  display: none;
}

/* Contact “reason” select — native menus overflow on narrow viewports; JS
   builds a contained list (see initContactReasonSelect in main.js). */
.theme-contact-reason {
  position: relative;
}

.theme-contact-reason__native--sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.theme-contact-reason.is-open {
  z-index: 40;
}

.theme-contact-reason__trigger {
  display: flex;
  min-height: 3rem;
  width: 100%;
  max-width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  border: 0;
  border-bottom: 1px solid color-mix(in oklab, var(--ivory) 25%, transparent);
  background: transparent;
  padding: 0 0 0 0;
  text-align: left;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--ivory);
  cursor: pointer;
  transition:
    border-color 300ms ease,
    color 300ms ease;
}

.theme-contact-reason__trigger:hover {
  border-bottom-color: color-mix(in oklab, var(--ivory) 40%, transparent);
}

.theme-contact-reason__trigger:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.theme-contact-reason__value {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.theme-contact-reason__chevron {
  flex-shrink: 0;
  width: 0.5rem;
  height: 0.5rem;
  border-right: 1.5px solid color-mix(in oklab, var(--ivory) 55%, transparent);
  border-bottom: 1.5px solid color-mix(in oklab, var(--ivory) 55%, transparent);
  transform: rotate(45deg) translateY(-2px);
  transition: transform 200ms ease;
}

.theme-contact-reason.is-open .theme-contact-reason__chevron {
  transform: rotate(-135deg) translateY(2px);
}

.theme-contact-reason__list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 50;
  margin: 0.25rem 0 0;
  max-height: min(16rem, 55vh);
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  list-style: none;
  padding: 0.25rem 0;
  border: 1px solid color-mix(in oklab, var(--ivory) 18%, transparent);
  background: var(--navy-deep);
  box-shadow: 0 12px 40px color-mix(in oklab, var(--ink) 45%, transparent);
}

.theme-contact-reason__list[hidden] {
  display: none;
}

.theme-contact-reason__option {
  display: block;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  border: 0;
  background: transparent;
  padding: 0.75rem 1rem;
  text-align: left;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.35;
  color: color-mix(in oklab, var(--ivory) 88%, transparent);
  cursor: pointer;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
  transition: background-color 200ms ease, color 200ms ease;
}

.theme-contact-reason__option:hover,
.theme-contact-reason__option:focus-visible {
  outline: none;
  background: color-mix(in oklab, var(--gold) 14%, transparent);
  color: var(--gold-light);
}

.theme-contact-reason__option[aria-selected='true'] {
  color: var(--gold-light);
}

#contact select.theme-contact-reason__native:not(.theme-contact-reason__native--sr) {
  max-width: 100%;
  min-width: 0;
}

/* ---------------------------------------------------------------
   Product cards inside the WordPress loop
   Card markup reuses the source class list; these rules only supply the
   wrapper behaviours the source gets from a React wrapper element.
   --------------------------------------------------------------- */
.theme-product-card-wrap {
  height: 100%;
}

.theme-product-card__media-link {
  display: block;
}

.theme-product-card__media-link img {
  display: block;
  width: 100%;
}

/* Quick-add overlay button sits above the card's media link. */
.theme-card-add {
  position: relative;
  z-index: 2;
}

/* ---------------------------------------------------------------
   WooCommerce notices — styled to match the design system. Errors stay
   visible on every page.
   --------------------------------------------------------------- */
.woocommerce-notices-wrapper {
  max-width: 80rem;
  margin: 0 auto;
  padding: 1rem 1.25rem 0;
}

@media (min-width: 640px) {
  .woocommerce-notices-wrapper {
    padding-inline: 2rem;
  }
}

.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  position: relative;
  list-style: none;
  margin: 0 0 1rem;
  padding: 1rem 1.25rem;
  border: 1px solid color-mix(in oklab, var(--ivory) 15%, transparent);
  border-left: 2px solid var(--gold);
  background-color: var(--navy);
  color: var(--ivory);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  line-height: 1.6;
}

.woocommerce-message a,
.woocommerce-info a,
.woocommerce-error a {
  color: var(--gold-light);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.woocommerce-error {
  border-left-color: #d9775b;
}

.woocommerce-message::before,
.woocommerce-info::before,
.woocommerce-error::before {
  content: none;
}

/* In the drawer and on the single product page the drawer itself provides
   the feedback, so the inline notices are redundant there. */
.single-product .woocommerce-message,
.single-product .woocommerce-info {
  display: none;
}

#theme-cart-drawer .woocommerce-message,
#theme-cart-drawer .woocommerce-info {
  display: none;
}

/* ---------------------------------------------------------------
   Star rating inside WooCommerce output
   --------------------------------------------------------------- */
.theme-cart-line-attrs {
  margin-top: 0.25rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: color-mix(in oklab, var(--ivory) 50%, transparent);
}

/* ---------------------------------------------------------------
   Shop / archive grid wrapper — the source grid markup is reused, this
   only ensures the loop's generated wrapper participates in it.
   --------------------------------------------------------------- */
.theme-shop-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: minmax(0, 1fr);
}

@media (min-width: 640px) {
  .theme-shop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .theme-shop-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.5rem;
  }
}

/* Fixed-count product rows (related products, "you may also like"). */
.theme-product-row {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
}

@media (min-width: 640px) {
  .theme-product-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .theme-product-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Equal heights inside both grids. */
.theme-shop-grid > *,
.theme-product-row > * {
  min-width: 0;
  height: 100%;
}

/* ---------------------------------------------------------------
   Single product layout guards
   --------------------------------------------------------------- */
body.single-product,
body.post-type-archive-product,
body.tax-product_cat,
body.tax-product_tag,
body.woocommerce-shop {
  background-color: var(--navy-deep);
  color: var(--ivory);
}

body.single-product .theme-product-layout,
.single-product .theme-product-gallery,
.single-product .theme-product-info {
  min-width: 0;
  max-width: 100%;
}

/* Header offset on the single product page (its own padded container). */
.single-product .theme-product-layout {
  scroll-margin-top: 6rem;
}

.single-product .theme-product-gallery {
  position: relative;
}

.single-product .theme-product-gallery img {
  display: block;
}

.single-product .theme-add-to-cart-area {
  display: flex;
  align-items: stretch;
  flex-wrap: wrap;
  gap: 0.75rem;
  width: 100%;
}

.single-product .theme-add-to-cart-area .single_add_to_cart_button {
  flex: 1 1 auto;
  min-width: 160px;
}

.single-product .woocommerce-product-details__short-description,
.single-product .woocommerce-variation-description,
.single-product .posted_in,
.single-product .theme-product-description {
  overflow-wrap: break-word;
  word-break: break-word;
}

/* Variations table reflowed to stacked label/control rows. */
.single-product .variations tbody,
.single-product .variations tbody tr,
.single-product .variations tbody td {
  display: block;
  width: 100%;
}

.single-product .variations tbody td.label {
  padding-bottom: 0.25rem;
}

.single-product .variations tbody td.value {
  padding-top: 0;
}

.single-product .variations td.label label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: color-mix(in oklab, var(--ivory) 55%, transparent);
}

.single-product .variations select {
  display: none;
}

.single-product form.variations_form .single_variation_wrap {
  width: 100%;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid color-mix(in oklab, var(--ivory) 10%, transparent);
}

.woocommerce-variation-price {
  margin-bottom: 1rem;
}

.woocommerce-variation-availability p,
.woocommerce-variation-price .price {
  font-family: var(--font-sans);
  color: var(--ivory);
}

/* Attribute pills. */
.theme-attr-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.theme-attr-pill {
  display: inline-flex;
  min-height: 2.5rem;
  align-items: center;
  gap: 0.5rem;
  padding: 0 0.9rem;
  border: 1px solid color-mix(in oklab, var(--ivory) 20%, transparent);
  border-radius: 2px;
  background: transparent;
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: color-mix(in oklab, var(--ivory) 70%, transparent);
  cursor: pointer;
  transition: border-color 220ms ease, background-color 220ms ease, color 220ms ease;
}

.theme-attr-pill:hover {
  border-color: color-mix(in oklab, var(--ivory) 40%, transparent);
  color: var(--ivory);
}

.theme-attr-pill.is-active {
  border-color: var(--gold-light);
  background-color: color-mix(in oklab, var(--ivory) 6%, transparent);
  color: var(--ivory);
}

.theme-attr-pill__dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 9999px;
  border: 1px solid color-mix(in oklab, var(--ivory) 25%, transparent);
}

/* ---------------------------------------------------------------
   WooCommerce-generated product detail table on the single page.
   --------------------------------------------------------------- */
.single-product dl.theme-product-details {
  display: block;
}

/* Gallery thumbnails. */
.theme-product-thumbnails {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  max-width: 100%;
  margin-top: 0.75rem;
}

.theme-product-thumbnails button {
  position: relative;
  width: 4.5rem;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 1px solid color-mix(in oklab, var(--ivory) 12%, transparent);
  background-color: var(--navy-deep);
  cursor: pointer;
  transition: border-color 220ms ease;
}

.theme-product-thumbnails button.is-active {
  border-color: var(--gold-light);
}

.theme-product-thumbnails img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* ---------------------------------------------------------------
   Archive / shop page chrome (no source equivalent).
   --------------------------------------------------------------- */
.theme-shop-hero {
  position: relative;
  background-color: var(--navy);
  color: var(--ivory);
}

.theme-breadcrumb,
.woocommerce-breadcrumb {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: color-mix(in oklab, var(--ivory) 55%, transparent);
}

.woocommerce-breadcrumb a {
  color: var(--gold-light);
}

.woocommerce-result-count,
.woocommerce-ordering select {
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  color: color-mix(in oklab, var(--ivory) 60%, transparent);
}

.woocommerce-ordering select {
  min-height: 2.75rem;
  padding: 0 0.75rem;
  border: 1px solid color-mix(in oklab, var(--ivory) 20%, transparent);
  background-color: var(--navy-deep);
  color: var(--ivory);
}

/* Out-of-stock badge on cards (source badge styling). */
.theme-stock-badge {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  z-index: 3;
  background-color: color-mix(in oklab, var(--navy-deep) 80%, transparent);
  padding: 0.25rem 0.625rem;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  line-height: 1.3333;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--gold-light);
  backdrop-filter: blur(4px);
  pointer-events: none;
}

/* ---------------------------------------------------------------
   Checkout (native WooCommerce Checkout Block)
   Scoped to body.woocommerce-checkout so nothing else is affected.
   --------------------------------------------------------------- */
body.woocommerce-checkout .site-main {
  padding-top: 64px;
  padding-bottom: 4rem;
  background-color: var(--navy-deep);
  color: var(--ivory);
}

@media (min-width: 640px) {
  body.woocommerce-checkout .site-main {
    padding-top: 80px;
  }
}

body.woocommerce-checkout .theme-page-container {
  max-width: 80rem;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

@media (min-width: 640px) {
  body.woocommerce-checkout .theme-page-container {
    padding-inline: 2rem;
  }
}

body.woocommerce-checkout .page-title {
  margin: 0 0 2rem;
  font-family: var(--font-display);
  font-size: clamp(3rem, 6vw, 5rem);
  font-weight: 400;
  line-height: 0.9;
  letter-spacing: -0.01em;
  color: var(--ivory);
}

body.woocommerce-checkout .entry-content,
body.woocommerce-cart .entry-content,
body.woocommerce-account .entry-content {
  max-width: 100%;
}

body.woocommerce-checkout .wc-block-checkout {
  display: block;
  color: var(--ivory);
  font-family: var(--font-sans);
}

@media (min-width: 768px) {
  body.woocommerce-checkout .wc-block-checkout.is-large,
  body.woocommerce-checkout .wc-block-components-sidebar-layout.is-large {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
  }
}

body.woocommerce-checkout .wc-block-checkout__main,
body.woocommerce-checkout .wc-block-checkout__sidebar {
  min-width: 0;
  width: 100%;
  max-width: none;
}

body.woocommerce-checkout .wc-block-checkout__sidebar {
  background-color: var(--navy);
  border: 1px solid color-mix(in oklab, var(--ivory) 10%, transparent);
  border-radius: 2px;
  padding: 1.5rem;
  color: var(--ivory);
}

body.woocommerce-checkout .wc-block-components-notice-banner {
  grid-column: 1 / -1;
}

body.woocommerce-checkout .wc-block-checkout__sidebar *,
body.woocommerce-checkout .wc-block-checkout__main * {
  color: inherit;
}

body.woocommerce-checkout .wc-block-components-title,
body.woocommerce-checkout h2,
body.woocommerce-checkout h3 {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ivory);
}

body.woocommerce-checkout .wc-block-components-text-input input,
body.woocommerce-checkout .wc-block-components-select select,
body.woocommerce-checkout .wc-blocks-components-select__select,
body.woocommerce-checkout .wc-block-components-textarea textarea,
body.woocommerce-checkout .wc-block-components-combobox .wc-block-components-combobox-control input.components-combobox-control__input {
  width: 100% !important;
  max-width: none !important;
  border: 1px solid color-mix(in oklab, var(--ivory) 20%, transparent) !important;
  border-radius: 3px !important;
  background-color: color-mix(in oklab, var(--navy-deep) 60%, transparent) !important;
  font-family: var(--font-sans) !important;
  font-size: 1rem !important;
  color: var(--ivory) !important;
  box-shadow: none !important;
}

body.woocommerce-checkout .wc-block-components-text-input input:focus,
body.woocommerce-checkout .wc-block-components-select select:focus,
body.woocommerce-checkout .wc-blocks-components-select__select:focus,
body.woocommerce-checkout .wc-block-components-textarea textarea:focus {
  border-color: var(--gold-light) !important;
  outline: none !important;
  box-shadow: 0 0 0 2px color-mix(in oklab, var(--gold-light) 35%, transparent) !important;
}

body.woocommerce-checkout .wc-block-components-text-input label,
body.woocommerce-checkout .wc-block-components-select label,
body.woocommerce-checkout .wc-block-components-checkbox label {
  font-family: var(--font-sans) !important;
  color: color-mix(in oklab, var(--ivory) 70%, transparent) !important;
}

body.woocommerce-checkout .wc-block-components-checkout-place-order-button,
body.woocommerce-checkout .wc-block-components-button:not(.is-link) {
  border-radius: 3px !important;
  background-color: var(--gold) !important;
  color: var(--navy-deep) !important;
  font-family: var(--font-sans) !important;
  font-size: 0.875rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.03em !important;
  min-height: 3rem !important;
  transition: background-color 300ms ease !important;
}

body.woocommerce-checkout .wc-block-components-checkout-place-order-button:hover,
body.woocommerce-checkout .wc-block-components-button:not(.is-link):hover {
  background-color: var(--gold-light) !important;
  color: var(--navy-deep) !important;
}

body.woocommerce-checkout .wc-block-cart-items,
body.woocommerce-checkout .wc-block-components-order-summary {
  color: var(--ivory);
}

body.woocommerce-checkout .wc-block-components-totals-item__label,
body.woocommerce-checkout .wc-block-components-totals-item__value {
  font-family: var(--font-sans);
  color: color-mix(in oklab, var(--ivory) 75%, transparent);
}

body.woocommerce-checkout .wc-block-components-totals-footer-item .wc-block-components-totals-item__value,
body.woocommerce-checkout .wc-block-components-totals-footer-item .wc-block-components-totals-item__label {
  color: var(--ivory);
  font-weight: 600;
}

/* Cart + My Account pages: same container and heading inset as checkout. */
body.woocommerce-cart .site-main,
body.woocommerce-account .site-main,
body.theme-thankyou-page .site-main {
  padding-top: 64px;
  padding-bottom: 4rem;
  background-color: var(--navy-deep);
  color: var(--ivory);
}

@media (min-width: 640px) {
  body.woocommerce-cart .site-main,
  body.woocommerce-account .site-main,
  body.theme-thankyou-page .site-main {
    padding-top: 80px;
  }
}

body.woocommerce-cart,
body.woocommerce-account,
body.theme-thankyou-page {
  background-color: var(--navy-deep);
  color: var(--ivory);
}

body.woocommerce-cart .page-title,
body.woocommerce-account .page-title,
body.theme-thankyou-page .page-title {
  margin: 0 0 2rem;
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400;
  line-height: 0.92;
  letter-spacing: -0.01em;
  color: var(--ivory);
}

/* ---------------------------------------------------------------
   WooCommerce Blocks on the cart and account pages: match the theme's
   own components (same treatment as the checkout block).
   --------------------------------------------------------------- */
body.woocommerce-cart .wp-block-woocommerce-cart,
body.woocommerce-cart .wc-block-cart,
body.woocommerce-account .woocommerce {
  font-family: var(--font-sans);
  color: var(--ivory);
}

body.woocommerce-cart .wc-block-cart,
body.woocommerce-account .woocommerce {
  max-width: none;
}

body.woocommerce-cart .wc-block-cart *,
body.woocommerce-account .woocommerce * {
  color: inherit;
}

body.woocommerce-cart .wc-block-components-title,
body.woocommerce-cart .wc-block-cart__main h2,
body.woocommerce-account h2,
body.woocommerce-account h3 {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.01em;
}

body.woocommerce-cart .wc-block-cart-items__row,
body.woocommerce-cart .wc-block-components-totals-item {
  border-color: color-mix(in oklab, var(--ivory) 12%, transparent);
}

body.woocommerce-cart .wc-block-cart__submit-button,
body.woocommerce-cart .wc-block-components-button:not(.is-link),
body.woocommerce-account .woocommerce-Button,
body.woocommerce-account .button {
  border-radius: 3px !important;
  background-color: var(--gold) !important;
  color: var(--navy-deep) !important;
  font-family: var(--font-sans) !important;
  font-size: 0.875rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.03em !important;
  min-height: 3rem !important;
  transition: background-color 300ms ease !important;
}

body.woocommerce-cart .wc-block-cart__submit-button:hover,
body.woocommerce-cart .wc-block-components-button:not(.is-link):hover,
body.woocommerce-account .woocommerce-Button:hover,
body.woocommerce-account .button:hover {
  background-color: var(--gold-light) !important;
  color: var(--navy-deep) !important;
}

body.woocommerce-cart .wc-block-cart-item__image img,
body.woocommerce-cart .wc-block-components-product-image img {
  border-radius: 2px;
}

body.woocommerce-account .woocommerce-form-login,
body.woocommerce-account .woocommerce-form-register,
body.woocommerce-account .woocommerce-MyAccount-navigation,
body.woocommerce-account .woocommerce-MyAccount-content {
  border: 1px solid color-mix(in oklab, var(--ivory) 10%, transparent);
  background-color: var(--navy);
  border-radius: 2px;
  padding: 1.5rem;
}

body.woocommerce-account .woocommerce-MyAccount-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

body.woocommerce-account .woocommerce-MyAccount-navigation li a {
  display: block;
  padding: 0.5rem 0;
  color: color-mix(in oklab, var(--ivory) 70%, transparent);
  font-size: 0.875rem;
  border-bottom: 1px solid color-mix(in oklab, var(--ivory) 8%, transparent);
}

body.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a,
body.woocommerce-account .woocommerce-MyAccount-navigation li a:hover {
  color: var(--gold-light);
}

body.woocommerce-account .woocommerce-MyAccount-content {
  min-width: 0;
}

/* ---------------------------------------------------------------
   Thank you page
   --------------------------------------------------------------- */
body.theme-thankyou-page {
  overflow-x: hidden;
  background-color: var(--navy-deep);
  color: var(--ivory);
}

body.theme-thankyou-page .woocommerce-order,
body.theme-thankyou-page .woocommerce-order-overview,
body.theme-thankyou-page .woocommerce-customer-details,
body.theme-thankyou-page .woocommerce-order-details {
  font-family: var(--font-sans);
  color: color-mix(in oklab, var(--ivory) 80%, transparent);
}

body.theme-thankyou-page .woocommerce-order > p,
body.theme-thankyou-page .woocommerce-notice {
  font-size: 1.125rem;
  line-height: 1.625;
  color: color-mix(in oklab, var(--ivory) 70%, transparent);
}

body.theme-thankyou-page h2,
body.theme-thankyou-page .woocommerce-order-details__title,
body.theme-thankyou-page .woocommerce-column__title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--ivory);
  padding: 0 0 1rem 0;
}

body.theme-thankyou-page .woocommerce-order-overview {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin: 0 0 2rem;
  padding: 0;
  list-style: none;
  border-top: 1px solid color-mix(in oklab, var(--ivory) 12%, transparent);
  border-bottom: 1px solid color-mix(in oklab, var(--ivory) 12%, transparent);
  padding-block: 1.25rem;
}

body.theme-thankyou-page .woocommerce-order-overview li {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: color-mix(in oklab, var(--ivory) 50%, transparent);
}

body.theme-thankyou-page .woocommerce-order-overview li strong {
  display: block;
  margin-top: 0.35rem;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ivory);
}

body.theme-thankyou-page .woocommerce-order-details table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  font-size: 0.875rem;
}

body.theme-thankyou-page .woocommerce-order-details table th,
body.theme-thankyou-page .woocommerce-order-details table td {
  padding: 0.75rem 0.5rem;
  border-bottom: 1px solid color-mix(in oklab, var(--ivory) 10%, transparent);
  vertical-align: top;
}

body.theme-thankyou-page .woocommerce-order-details tfoot th {
  text-align: left;
}

body.theme-thankyou-page .woocommerce-order-details tfoot td {
  text-align: right;
}

body.theme-thankyou-page .woocommerce-customer-details {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-top: 2rem;
}

body.theme-thankyou-page .woocommerce-customer-details address {
  max-width: 480px;
  overflow-wrap: break-word;
  font-style: normal;
  line-height: 1.75;
  color: color-mix(in oklab, var(--ivory) 75%, transparent);
}

/* ---------------------------------------------------------------
   WordPress core helpers rendered by WooCommerce/WordPress markup.
   --------------------------------------------------------------- */
.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Ensure the drawer stays hidden until opened, whatever a plugin adds. */
body:not(.cart-open) #theme-cart-drawer {
  pointer-events: none;
}

/* Keep the page from scrolling behind the open drawer. */
html:has(body.cart-open) {
  overflow: hidden;
}
