/* ==========================================================================
   Product page styles — depends on nocturne-home.css
   Ported from mockups/product/mockup-product-v1.html, plus styling for
   WooCommerce's native add-to-cart / variation form.
   ========================================================================== */

/* ---- Breadcrumb ---- */
.ne-breadcrumb {
  padding: 22px 0 0;
  font-size: 12.5px;
  color: var(--muted);
}
.ne-breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
}
.ne-breadcrumb li { display: flex; align-items: center; gap: 8px; }
.ne-breadcrumb li + li::before {
  content: "/";
  color: var(--line);
}
.ne-breadcrumb a:hover { color: var(--accent); text-decoration: underline; }
.ne-breadcrumb [aria-current="page"] { color: var(--ink); font-weight: 500; }

/* ---- Two-column product layout ---- */
.ne-product {
  display: grid;
  grid-template-columns: minmax(0, 460px) 1fr;
  gap: 64px;
  align-items: start;
  padding: 40px 0 88px;
}

/* ---- Gallery slot (fallback when [nocturne_gallery] is not available) ---- */
.ne-gallery-slot {
  position: relative;
  aspect-ratio: 3 / 4;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 22px 45px -26px rgba(22, 19, 15, 0.4);
  overflow: hidden;
}
.ne-gallery-slot img { width: 100%; height: 100%; object-fit: cover; }
.ne-gallery-caption {
  margin-top: 14px;
  text-align: center;
  font-size: 12.5px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

/* ---- Product summary (right column) ---- */
.ne-summary .ne-composer-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.ne-summary h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(38px, 4.5vw, 52px);
  line-height: 1.05;
  margin-top: 6px;
}
.ne-summary .ne-product-meta {
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
}
.ne-summary .ne-product-meta a { color: var(--accent); }
.ne-summary .ne-product-meta a:hover { text-decoration: underline; }
.ne-price {
  margin-top: 18px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 34px;
  line-height: 1;
}

/* ---- Wishlist ghost link ---- */
.ne-wishlist {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding: 12px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  transition: color 0.2s ease, border-color 0.2s ease;
}
.ne-wishlist svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 1.5; }
.ne-wishlist:hover { color: var(--accent); border-color: var(--line); }

/* ---- Reassurance line ---- */
.ne-reassure {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.ne-reassure svg {
  width: 17px;
  height: 17px;
  stroke: var(--accent);
  fill: none;
  stroke-width: 1.5;
  flex: none;
  margin-top: 2px;
}

/* ---- Accordion ---- */
.ne-accordion { margin-top: 34px; border-top: 1px solid var(--line); }
.ne-accordion details { border-bottom: 1px solid var(--line); }
.ne-accordion summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 2px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 21px;
}
.ne-accordion summary::-webkit-details-marker { display: none; }
.ne-accordion summary::after {
  content: "+";
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 400;
  color: var(--muted);
  transition: transform 0.2s ease;
}
.ne-accordion details[open] summary::after { transform: rotate(45deg); }
.ne-accordion summary:hover { color: var(--accent); }
.ne-accordion .ne-acc-body {
  padding: 0 2px 22px;
  font-size: 14.5px;
  color: var(--ink-soft);
}
.ne-accordion .ne-acc-body p + p { margin-top: 12px; }

/* ---- Details table inside the accordion ---- */
.ne-spec { width: 100%; border-collapse: collapse; font-size: 14px; }
.ne-spec th, .ne-spec td { padding: 10px 0; border: 0; border-bottom: 1px solid var(--line); text-align: left; background: transparent; }
.ne-spec tr:last-child th, .ne-spec tr:last-child td { border-bottom: 0; }
.ne-spec th {
  font-weight: 600;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  width: 45%;
}
.ne-spec td { color: var(--ink); }

/* ---- About this edition ---- */
.ne-edition-note { max-width: 720px; }
.ne-edition-note p { margin-top: 18px; color: var(--ink-soft); }

/* ==========================================================================
   WooCommerce native add-to-cart / variation form
   The template renders WooCommerce's own form (one <select> per product
   attribute, live variation price, stock messages, quantity, add-to-cart).
   The rules below restyle that markup to match the design system, replacing
   the mockup's pill toggles with elegantly styled selects.
   ========================================================================== */

.ne-summary form.cart { margin-top: 28px; }

/* Variation attribute rows: stacked label + full-width select */
.ne-summary table.variations {
  width: 100%;
  border-collapse: collapse;
  border: 0;
  margin: 0;
}
.ne-summary table.variations tr { display: block; }
.ne-summary table.variations tr + tr { margin-top: 22px; }
.ne-summary table.variations th,
.ne-summary table.variations td {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
}

/* Attribute labels: small caps, letterspaced */
.ne-summary table.variations th.label,
.ne-summary table.variations th.label label {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.ne-summary table.variations th.label { margin-bottom: 10px; }

/* Attribute selects */
.ne-summary form.cart select {
  display: block;
  width: 100%;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ink);
  padding: 12px 14px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  cursor: pointer;
}
.ne-summary form.cart select:hover { border-color: var(--ink); }
.ne-summary form.cart select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* "Clear" (reset variations) link */
.ne-summary .reset_variations {
  display: inline-block;
  margin-top: 8px;
  font-size: 12px;
  color: var(--muted);
}
.ne-summary .reset_variations:hover { color: var(--accent); text-decoration: underline; }

/* Live variation price + availability */
.ne-summary .woocommerce-variation-price .price {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 26px;
  line-height: 1;
  color: var(--ink);
}
.ne-summary .single_variation_wrap { margin-top: 24px; }
.ne-summary .woocommerce-variation-availability {
  margin-top: 8px;
  font-size: 13px;
  color: var(--muted);
}
.ne-summary .woocommerce-variation-availability .out-of-stock { color: var(--accent); }

/* Quantity + add to cart row */
.ne-summary form.cart .woocommerce-variation-add-to-cart,
.ne-summary form.cart:not(.variations_form) {
  display: flex;
  gap: 12px;
  align-items: stretch;
  margin-top: 18px;
}
.ne-summary form.cart .quantity { flex: none; display: flex; }
.ne-summary form.cart input.qty {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  width: 70px;
  height: 100%;
  min-height: 47px;
  color: var(--ink);
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
}
.ne-summary form.cart input.qty:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
/* Digital products hide the quantity field; keep the button full width */
.ne-summary form.cart .quantity.hidden { display: none; }

/* Add-to-cart button: same treatment as .ne-btn, full width */
.ne-summary form.cart button.single_add_to_cart_button {
  flex: 1;
  display: inline-block;
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-align: center;
  padding: 14px 28px;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  transition: background 0.2s ease, color 0.2s ease;
  cursor: pointer;
  border-radius: var(--radius);
}
.ne-summary form.cart button.single_add_to_cart_button:hover {
  background: transparent;
  color: var(--ink);
}
.ne-summary form.cart button.single_add_to_cart_button.disabled,
.ne-summary form.cart button.single_add_to_cart_button:disabled {
  background: var(--line);
  border-color: var(--line);
  color: var(--muted);
  cursor: not-allowed;
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
  .ne-product { grid-template-columns: 1fr; gap: 44px; padding: 32px 0 64px; }
}


/* ==========================================================================
   PURCHASE UI POLISH (v1.2.3) — styles the woo-variation-swatches buttons,
   quantity, add-to-cart, express pay and wishlist to match the mockup pills
   ========================================================================== */

/* Attribute swatch pills (woo-variation-swatches plugin output) */
div.ne-page .ne-summary .variable-items-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
}
div.ne-page .ne-summary .variable-item:not(.radio-variable-item) {
  box-shadow: none;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  padding: 0;
  margin: 0;
  min-width: 0;
  height: auto;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}
div.ne-page .ne-summary .variable-item .variable-item-contents,
div.ne-page .ne-summary .variable-item .variable-item-span {
  padding: 10px 18px;
  font-family: var(--sans);
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.2;
}
div.ne-page .ne-summary .variable-item:hover { border-color: var(--ink); box-shadow: none; }
div.ne-page .ne-summary .variable-item.selected,
div.ne-page .ne-summary .variable-item.selected:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
  box-shadow: none;
}

/* Attribute group labels */
div.ne-page .ne-summary table.variations th.label label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Quantity stepper */
div.ne-page .ne-summary .quantity .qty {
  width: 74px;
  padding: 12px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  font-family: var(--sans);
  font-size: 15px;
  text-align: center;
}

/* Add to cart — same language as .ne-btn, full width */
div.ne-page .ne-summary .single_add_to_cart_button {
  display: block;
  width: 100%;
  margin-top: 16px;
  padding: 16px 28px;
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
div.ne-page .ne-summary .single_add_to_cart_button:hover {
  background: transparent;
  color: var(--ink);
}
div.ne-page .ne-summary .single_add_to_cart_button.disabled,
div.ne-page .ne-summary .single_add_to_cart_button:disabled {
  background: var(--paper-deep);
  border-color: var(--line);
  color: var(--muted);
  cursor: not-allowed;
}

/* Live variation price (after picking options) */
div.ne-page .ne-summary .woocommerce-variation-price .price {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 24px;
  color: var(--ink);
}

/* Express pay (Google Pay / Apple Pay) and wishlist spacing */
div.ne-page .ne-summary .wcpay-payment-request-wrapper,
div.ne-page .ne-summary #wcpay-payment-request-wrapper { margin-top: 12px; }
div.ne-page .ne-summary .yith-wcwl-add-to-wishlist { margin-top: 18px; }
div.ne-page .ne-summary .yith-wcwl-add-to-wishlist a {
  color: var(--ink-soft);
  font-size: 14px;
}
div.ne-page .ne-summary .yith-wcwl-add-to-wishlist a:hover { color: var(--accent); }

/* Reset-variations link */
div.ne-page .ne-summary .reset_variations {
  font-size: 12.5px;
  color: var(--muted);
  text-decoration: underline;
}


/* ==========================================================================
   DETAILS TABLE + QUANTITY STEPPER POLISH (v1.4.1)
   ========================================================================== */
/* Kill theme striping/boxes; clean hairline rows like the mockup */
div.ne-page .ne-spec,
div.ne-page .ne-spec tr,
div.ne-page .ne-spec th,
div.ne-page .ne-spec td {
  background: transparent;
  border: 0;
}
div.ne-page .ne-spec { width: 100%; border-collapse: collapse; }
div.ne-page .ne-spec th,
div.ne-page .ne-spec td {
  border-bottom: 1px solid var(--line);
  padding: 11px 0;
  text-align: left;
  vertical-align: top;
}
div.ne-page .ne-spec tr:last-child th,
div.ne-page .ne-spec tr:last-child td { border-bottom: 0; }
div.ne-page .ne-spec th {
  width: 38%;
  padding-right: 18px;
  font-family: var(--sans);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
div.ne-page .ne-spec td { font-size: 14.5px; color: var(--ink); }
div.ne-page .ne-spec td a {
  color: var(--accent);
  border-bottom: 1px solid rgba(142, 47, 42, 0.35);
}
div.ne-page .ne-spec td a:hover { border-bottom-color: var(--accent); }

/* Quantity stepper: minus / value / plus in one bordered group (buttons
   are injected by minicart.js) */
div.ne-page .ne-summary form.cart .quantity {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #fff;
  overflow: hidden;
  vertical-align: middle;
}
div.ne-page .ne-summary form.cart .quantity .qty {
  width: 48px;
  border: 0;
  border-radius: 0;
  padding: 12px 4px;
  text-align: center;
  font-family: var(--sans);
  font-size: 15px;
  background: transparent;
  -moz-appearance: textfield;
  appearance: textfield;
}
div.ne-page .ne-summary form.cart .quantity .qty::-webkit-inner-spin-button,
div.ne-page .ne-summary form.cart .quantity .qty::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
div.ne-page .ne-summary .ne-qty-btn {
  width: 38px;
  border: 0;
  background: transparent;
  font-size: 17px;
  line-height: 1;
  color: var(--ink-soft);
  cursor: pointer;
}
div.ne-page .ne-summary .ne-qty-btn:hover { background: var(--paper-deep); color: var(--ink); }


/* Visible keyboard focus on variation swatches (plugin removes outlines) */
div.ne-page .ne-summary .variable-item:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  box-shadow: none;
}


/* ==========================================================================
   OPTIONS POLISH (v1.6.1) — closer to the mockup
   ========================================================================== */
/* Hide the ": SELECTED VALUE" echo after the attribute label */
div.ne-page .ne-summary .woo-selected-variation-item-name { display: none; }

/* Price digits: lining numerals (Cormorant's oldstyle digits look uneven) */
div.ne-page .ne-price,
div.ne-page .ne-summary .woocommerce-variation-price .price {
  font-variant-numeric: lining-nums;
}

/* Quantity + Add to cart on one row, like the mockup */
div.ne-page .ne-summary .woocommerce-variation-add-to-cart,
div.ne-page .ne-summary form.cart:not(.variations_form) {
  display: flex;
  align-items: stretch;
  gap: 10px;
}
div.ne-page .ne-summary .woocommerce-variation-add-to-cart .quantity,
div.ne-page .ne-summary form.cart:not(.variations_form) .quantity { flex: 0 0 auto; }
div.ne-page .ne-summary .woocommerce-variation-add-to-cart .single_add_to_cart_button,
div.ne-page .ne-summary form.cart:not(.variations_form) .single_add_to_cart_button {
  flex: 1;
  width: auto;
  margin-top: 0;
}

/* Reset/Clear link: quiet, out of the flow of the pills */
div.ne-page .ne-summary .reset_variations { display: inline-block; margin-top: 6px; }


/* ==========================================================================
   SWATCHES PLUGIN VARIABLES (v1.6.5) — the woo-variation-swatches plugin
   styles its pills with these custom properties at very high specificity;
   feeding it our tokens beats it cleanly instead of fighting selectors.
   ========================================================================== */
div.ne-page .ne-summary .woo-variation-swatches,
div.ne-page .ne-summary .variable-items-wrapper {
  --wvs-item-background-color: #ffffff;
  --wvs-item-text-color: var(--ink);
  --wvs-item-box-shadow: none;
  --wvs-hover-item-background-color: var(--paper-deep);
  --wvs-hover-item-text-color: var(--ink);
  --wvs-hover-item-box-shadow: none;
  --wvs-selected-item-background-color: var(--ink);
  --wvs-selected-item-text-color: var(--paper);
  --wvs-selected-item-box-shadow: none;
}
