/*
Theme Name: Sindyanna of Galilee
Theme URI: https://he.sindyanna.com
Author: Forcemedia
Author URI: https://forcemedia.co.il
Description: Custom WooCommerce theme for Sindyanna of Galilee — fair trade olive oil cooperative. Features dual pricing for club members, ACF Pro content management, popup system, and full RTL Hebrew support.
Version: 1.7.8
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: sindyanna
Tags: rtl, woocommerce, custom-menu, featured-images, theme-options, translation-ready
*/

@import url('css/style.css?v=1.8.4');

/* Screen-reader-only utility.
   .screen-reader-text is the WordPress/WooCommerce core class (used by
   searchform.php and WC templates); aliased here because the default
   WooCommerce stylesheet — which normally defines it — is dequeued. */
.sr-only,
.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Reveal screen-reader text when it receives keyboard focus (WP core pattern). */
.screen-reader-text:focus {
    clip: auto;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0.75rem 1.5rem;
    z-index: 100000;
    background: var(--color-cream-light, #F7F6EE);
    color: var(--color-black, #1D1D1B);
    font-weight: 700;
    text-decoration: none;
}

/* Skip-to-content link */
.skip-link {
    position: absolute;
    top: -100%;
    left: 0;
    z-index: 10000;
    padding: 0.75rem 1.5rem;
    background: var(--color-gold, #C9A84C);
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    transition: top 0.2s;
}
.skip-link:focus {
    top: 0;
}

/* Remove gap between header and hero */
.home .hero {
    margin-block-start: 0;
    padding-block-start: var(--header-total-height);
}

/* CTA Banner — video variant */
.cta-banner--video {
    background-image: none;
}
.cta-banner__video-wrap {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
}
.cta-banner__video-wrap iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 177.78vh; /* 16:9 */
    height: 100vh;
    min-width: 100%;
    min-height: 100%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    border: 0;
}
.cta-banner--video .cta-banner__inner {
    position: relative;
    z-index: 2;
}
.cta-banner--video::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 1;
}

/* ------------------------------------------------------------------
   Mega menu — allow the category tab row to wrap.
   The live catalog has many top-level categories with long names; the
   prototype's single non-wrapping row overflowed and looked broken. Let
   the tabs flow onto a second row and tighten the spacing a touch so the
   panel of thumbnails below still reads as the focus.
   ------------------------------------------------------------------ */
.mega-menu__tabs {
    flex-wrap: wrap;
    row-gap: 0.25rem;
    column-gap: 0.25rem;
}
.mega-menu__tab {
    padding-inline: 12px;
}
/* Give the panel's product row breathing room on both sides and let it wrap
   instead of clipping the last tile when a category has many sub-categories. */
.mega-menu__products {
    flex-wrap: wrap;
    padding-inline: var(--space-lg);
}

/* ------------------------------------------------------------------
   Default page template wrapper — keep cart / checkout / account and
   other plain pages clear of the fixed header and give them breathing
   room at the bottom. (page.php renders the_content() here.)
   ------------------------------------------------------------------ */
.site-main--page {
    padding-block-start: calc(var(--header-total-height, 120px) + var(--space-xl, 2rem));
    padding-block-end: var(--space-3xl, 4rem);
}

/* ------------------------------------------------------------------
   Shop / category grid — WooCommerce wraps every product in
   <li class="product">, but the prototype's grid/list rules expect
   .cat-card to BE the grid item. Make the <li> a transparent flex cell
   so .cat-card fills it identically in every view mode (5/4/3 columns,
   2-up and list). Without this the <li> wrapper broke the list layout
   (misaligned images, wrapped text) and the column switcher.
   ------------------------------------------------------------------ */
.cat-grid__items {
    list-style: none;
    margin: 0;
    padding: 0;
}
.cat-grid__items > li.product {
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
}
.cat-grid__items > li.product::before,
.cat-grid__items > li.product::marker {
    content: none;
}
.cat-grid__items > li.product > .cat-card {
    flex: 1 1 auto;
    width: 100%;
}

/* ── View-switcher: grid column variations + list view ──
   The base modifier rules also live in css/style.css; these !important
   copies guarantee the dropdown's chosen layout wins over the 4-column
   default and the <li> wrapper in every view mode. */
.cat-grid__items--cols-5 { grid-template-columns: repeat(5, 1fr) !important; gap: var(--space-md); }
.cat-grid__items--cols-3 { grid-template-columns: repeat(3, 1fr) !important; gap: var(--space-xl); }
.cat-grid__items--cols-2 { grid-template-columns: repeat(2, 1fr) !important; gap: var(--space-lg); }

.cat-grid__items--list { grid-template-columns: 1fr !important; gap: var(--space-sm); }
.cat-grid__items--list > li.product { display: block; }
.cat-grid__items--list .cat-card { flex-direction: row; align-items: center; border-radius: 8px; }
.cat-grid__items--list .cat-card__img { flex: 0 0 180px; aspect-ratio: 4 / 3; border-radius: 8px 0 0 8px; }
.cat-grid__items--list .cat-card__body { flex-direction: row; align-items: center; gap: var(--space-lg); padding: var(--space-md) var(--space-lg); }
.cat-grid__items--list .cat-card__name { flex: 1; margin-bottom: 0; font-size: 1.15rem; }
.cat-grid__items--list .cat-card__volume { margin-bottom: 0; }
.cat-grid__items--list .cat-card__price-row { margin-bottom: 0; min-width: 80px; }
.cat-grid__items--list .cat-card__actions { margin-top: 0; flex-shrink: 0; gap: var(--space-md); }
.cat-grid__items--list .cat-card__add-btn { min-width: 140px; height: 42px; font-size: 0.95rem; padding-inline: var(--space-lg); }
.cat-grid__items--list .cat-card__badge { inset-block-start: var(--space-xs); inset-inline-start: var(--space-xs); font-size: 0.7rem; }

@media (max-width: 1024px) {
    .cat-grid__items--cols-5 { grid-template-columns: repeat(3, 1fr) !important; }
}

@media (max-width: 768px) {
    .cat-grid__items--cols-5,
    .cat-grid__items--cols-4,
    .cat-grid__items--cols-3,
    .cat-grid__items--cols-2 { grid-template-columns: repeat(2, 1fr) !important; gap: var(--space-md); }

    .cat-grid__items--list { grid-template-columns: 1fr !important; gap: var(--space-md); }
    .cat-grid__items--list .cat-card { flex-direction: column; align-items: stretch; }
    .cat-grid__items--list .cat-card__img { flex: none; width: 100%; aspect-ratio: 16 / 9; border-radius: 8px 8px 0 0; }
    .cat-grid__items--list .cat-card__body { flex-direction: column; align-items: stretch; gap: var(--space-sm); padding: var(--space-lg); }
    .cat-grid__items--list .cat-card__name { font-size: 1.15rem; margin-bottom: 0; }
    .cat-grid__items--list .cat-card__price-row { margin-bottom: var(--space-sm); }
    .cat-grid__items--list .cat-card__actions { flex-direction: row; gap: var(--space-md); }
    .cat-grid__items--list .cat-card__qty { align-self: auto; }
    .cat-grid__items--list .cat-card__add-btn { width: auto; flex: 1; height: 42px; font-size: 0.95rem; }
}

/* ------------------------------------------------------------------
   Filter toolbar — WooCommerce renders the sort control and result
   count with its own markup (form.woocommerce-ordering > select.orderby
   and p.woocommerce-result-count). Give them the prototype's
   .cat-filters__select / .cat-filters__count appearance so the toolbar
   matches category.html.
   ------------------------------------------------------------------ */
.cat-filters .woocommerce-ordering {
    margin: 0;
}
.cat-filters .orderby {
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--color-black);
    padding: var(--space-xs) var(--space-md);
    padding-inline-start: 2rem;
    border: 1.5px solid var(--color-cream);
    border-radius: 6px;
    background-color: var(--color-white);
    cursor: pointer;
    transition: border-color var(--transition-fast);
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23888' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 0.75rem center;
}
.cat-filters .orderby:hover,
.cat-filters .orderby:focus {
    border-color: var(--color-gold);
    outline: none;
}
.cat-filters .woocommerce-result-count {
    margin: 0;
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--color-olive-400);
}

/* ------------------------------------------------------------------
   Order notes on the CHECKOUT page — WooCommerce renders the notes
   textarea (#order_comments) inside the additional-fields section. The
   notes field was removed from the cart, so it lives only here; style it
   to match the Sindyanna form fields.
   ------------------------------------------------------------------ */
.woocommerce-checkout .woocommerce-additional-fields h3,
.woocommerce-checkout .order-notes-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-black);
    margin-bottom: var(--space-sm);
}
.woocommerce-checkout #order_comments_field label {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--color-black);
    margin-bottom: var(--space-xs);
    display: block;
}
.woocommerce-checkout #order_comments {
    width: 100%;
    min-height: 100px;
    border: 1px solid var(--color-cream);
    border-radius: 8px;
    padding: var(--space-sm) var(--space-md);
    font-family: var(--font-body);
    font-size: 0.95rem;
    color: var(--color-black);
    background: var(--color-white);
    resize: vertical;
    transition: border-color var(--transition-fast);
}
.woocommerce-checkout #order_comments:focus {
    border-color: var(--color-gold);
    outline: none;
    box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.15);
}
.woocommerce-checkout #order_comments::placeholder {
    color: var(--color-olive-300);
    font-family: var(--font-body);
}

/* ------------------------------------------------------------------
   Product-card action button — normalize across product types. Simple
   products render a <button class="cat-card__add-btn">, while variable /
   grouped / external (and out-of-stock) products render an <a> ("בחר
   אפשרויות" / "קרא עוד"). The base rule didn't reset <a> defaults, so
   those looked underlined and top-aligned. Make both render identically.
   ------------------------------------------------------------------ */
.cat-card__add-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    text-decoration: none;
    line-height: 1;
    padding-inline: var(--space-md);
}
.cat-card__add-btn:hover,
.cat-card__add-btn:focus {
    color: var(--color-white);
    text-decoration: none;
}

/* Sale price markup inside the card price (variable ranges / on-sale). */
.cat-card__price del {
    color: var(--color-olive-400);
    font-weight: 400;
    font-size: 0.9em;
    margin-inline-end: 0.25rem;
}
.cat-card__price ins {
    text-decoration: none;
    color: var(--color-gold-dark);
}

/* ------------------------------------------------------------------
   Member ("חברי מועדון") price row on product cards — was unstyled.
   ------------------------------------------------------------------ */
.cat-card__member-price {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: var(--color-olive-500);
    margin-bottom: var(--space-sm);
}
.cat-card__member-label {
    font-family: var(--font-body);
}
.cat-card__member-value {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--color-gold);
}

/* ------------------------------------------------------------------
   Single product — keep the variable-product variations UI inside the
   info column. The variations form/table has no theme styling of its own,
   so cap its width and let long option lists wrap rather than push the
   layout edge-to-edge.
   ------------------------------------------------------------------ */
.product__purchase .variations_form,
.product__purchase .variations,
.product__purchase .single_variation_wrap,
.product__purchase .woocommerce-variation-add-to-cart {
    max-width: 100%;
}
.product__purchase .variations {
    width: 100%;
    border-collapse: collapse;
}
.product__purchase .variations th,
.product__purchase .variations td {
    padding-block: var(--space-xs);
    text-align: start;
    vertical-align: middle;
}
.product__purchase .variations .label {
    font-family: var(--font-body);
    font-weight: 600;
    color: var(--color-black);
    padding-inline-end: var(--space-md);
    white-space: nowrap;
}
.product__purchase .variations select {
    max-width: 100%;
    width: 100%;
    height: 40px;
    border: 1px solid var(--color-cream);
    border-radius: 8px;
    padding-inline: var(--space-md);
    font-family: var(--font-body);
    background: var(--color-white);
}
.product__purchase .reset_variations {
    font-size: 0.85rem;
    color: var(--color-olive-500);
}

/* ------------------------------------------------------------------
   Out-of-stock product cards — badge + dimmed image + restyled button so
   it's clear WHY the button says "מידע נוסף" instead of "הוספה לסל".
   ------------------------------------------------------------------ */
/* OOS badge styling + positioning lives in the badge block further down
   (it sits on the opposite corner from new/sale, so no stacking needed). */
.cat-card--oos .cat-card__img {
    position: relative;
}
.cat-card--oos .cat-card__img img {
    opacity: 0.55;
    filter: grayscale(30%);
}
.cat-card--oos .cat-card__img::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.25);
    pointer-events: none;
}
.cat-card--oos .cat-card__add-btn {
    background: var(--color-olive-300);
    color: var(--color-white);
}
.cat-card--oos .cat-card__add-btn:hover,
.cat-card--oos .cat-card__add-btn:focus {
    background: var(--color-olive-500);
    color: var(--color-white);
}

/* ------------------------------------------------------------------
   Single product stock status (WooCommerce renders <p class="stock
   out-of-stock"> / "in-stock"). The OOS line shows for our backorder-
   purchasable products that are currently out of stock.
   ------------------------------------------------------------------ */
.product .stock.out-of-stock,
.product__stock--oos {
    display: inline-block;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--color-olive-700);
    background: var(--color-cream-light);
    padding: var(--space-xs) var(--space-md);
    border-radius: 6px;
    margin-bottom: var(--space-md);
}
.product .stock.in-stock,
.product__stock--in {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--color-olive-500);
    margin-bottom: var(--space-sm);
}

/* ------------------------------------------------------------------
   Variable product add-to-cart (WooCommerce variable.php renders the
   .single_variation_wrap button with default classes, not our
   .product__add-to-cart). Style it + the "select an option" disabled
   state. The variations <select> styling lives in the .product__purchase
   block above.
   ------------------------------------------------------------------ */
.single-product .single_variation_wrap .single_add_to_cart_button {
    width: 100%;
    height: 48px;
    margin-top: var(--space-sm);
    background: var(--color-gold);
    color: var(--color-white);
    border: none;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background var(--transition-fast);
}
.single-product .single_variation_wrap .single_add_to_cart_button:hover {
    background: var(--color-gold-dark);
}
.single-product .single_variation_wrap .single_add_to_cart_button.disabled,
.single-product .single_variation_wrap .single_add_to_cart_button.wc-variation-selection-needed,
.single-product .single_variation_wrap .single_add_to_cart_button:disabled {
    background: var(--color-olive-300);
    cursor: not-allowed;
}
/* Variations table layout: label + select on one row, reset link, and the
   add-to-cart row (qty + button) laid out like the rest of the product UI. */
.single-product .variations tr {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-sm);
}
.single-product .variations th { flex: 0 0 auto; }
.single-product .variations td { flex: 1; }
.single-product .variations .reset_variations {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--color-olive-400);
    text-decoration: underline;
    margin-top: var(--space-xs);
    display: inline-block;
}
.single-product .single_variation .woocommerce-variation-price {
    margin-bottom: var(--space-md);
}
.single-product .woocommerce-variation-add-to-cart {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}
.single-product .woocommerce-variation-add-to-cart .quantity {
    display: flex;
    align-items: center;
    border: 1.5px solid var(--color-cream);
    border-radius: 8px;
    overflow: hidden;
}
.single-product .woocommerce-variation-add-to-cart .quantity .qty {
    width: 50px;
    height: 44px;
    border: none;
    text-align: center;
    font-family: var(--font-body);
    font-size: 1rem;
}

/* ------------------------------------------------------------------
   Product card badges — larger, higher-contrast. "מסיק חדש" goes dark
   olive green (was gold), "מבצע" black, "אזל מהמלאי" olive.
   ------------------------------------------------------------------ */
.cat-card__badge {
    padding: 0.3em 0.85em;
    font-size: 0.82rem;
    letter-spacing: 0.03em;
}
.cat-card__badge--new {
    background: #2c3723;
    color: var(--color-white);
}
.cat-card__badge--sale {
    background: var(--color-black);
    color: var(--color-white);
}
/* OOS badge on the OPPOSITE corner from new/sale: top-left in RTL
   (inset-inline-end), so the two never overlap or stack. */
.cat-card__badge--oos {
    inset-block-start: var(--space-sm);
    inset-inline-end: var(--space-sm);
    inset-inline-start: auto;
    background: var(--color-olive-500);
    color: var(--color-white);
}
/* WooCommerce's own sale flash, if it ever renders, matches the card badges. */
.woocommerce span.onsale,
ul.products li.product .onsale,
.single-product .product .onsale {
    position: absolute;
    inset-block-start: var(--space-sm);
    inset-inline-start: var(--space-sm);
    margin: 0;
    padding: 0.3em 0.85em;
    border-radius: 4px;
    font-family: var(--font-heading);
    font-size: 0.82rem;
    font-weight: 700;
    line-height: normal;
    min-width: auto;
    min-height: auto;
    background: var(--color-black);
    color: var(--color-white);
    z-index: 1;
}

/* ------------------------------------------------------------------
   WooCommerce notices — constrain to container width + brand styling.
   On the cart these render via woocommerce_before_cart, which fires
   BEFORE our .container, so they were edge-to-edge. Constraining the
   wrapper (and the messages, for cases with no wrapper) fixes it.
   ------------------------------------------------------------------ */
.woocommerce-notices-wrapper,
.woocommerce-message,
.woocommerce-error,
.woocommerce-info {
    max-width: var(--container-max);
    margin-inline: auto;
    padding-inline: var(--container-padding);
}
/* Info & message notices: flex row so the button sits beside the text
   instead of floating over it (WC puts the button first + floats it). */
.woocommerce-info,
.woocommerce-message {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    background: var(--color-cream-light);
    border: none;
    border-right: 4px solid var(--color-gold);
    border-radius: 8px;
    padding: var(--space-md) var(--space-lg);
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: #555;
    line-height: 1.6;
    margin-bottom: var(--space-lg);
}

/* Drop the default WooCommerce icon — clashes with the flex layout. */
.woocommerce-info::before,
.woocommerce-message::before {
    display: none;
}

.woocommerce-message a { color: var(--color-gold-dark); font-weight: 600; }

/* Button inside notice — no float; order:1 pushes it to the LEFT (end) in RTL. */
.woocommerce-info .woocommerce-Button,
.woocommerce-info .button,
.woocommerce-message .woocommerce-Button,
.woocommerce-message .button {
    float: none !important;
    flex-shrink: 0;
    order: 1;
    display: inline-block;
    padding: 8px 20px;
    background: var(--color-gold);
    color: var(--color-white);
    border: none;
    border-radius: 6px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: background var(--transition-fast);
}
.woocommerce-info .woocommerce-Button:hover,
.woocommerce-info .button:hover,
.woocommerce-message .woocommerce-Button:hover,
.woocommerce-message .button:hover {
    background: var(--color-gold-dark);
    color: var(--color-white);
}

/* Error notices */
.woocommerce-error {
    border-radius: 8px;
    padding: var(--space-md) var(--space-lg);
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: #991b1b;
    margin-bottom: var(--space-lg);
    background: #fef2f2;
    border: none;
    border-right: 4px solid #dc2626;
    list-style: none;
}
.woocommerce-error::before { display: none; }

/* Mobile: stack the info/message notice so the button drops below the text
   instead of competing for width in the flex row (cart/checkout on phones). */
@media (max-width: 768px) {
    .woocommerce-info,
    .woocommerce-message {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        gap: var(--space-sm);
    }
    .woocommerce-info .woocommerce-Button,
    .woocommerce-info .button,
    .woocommerce-message .woocommerce-Button,
    .woocommerce-message .button {
        order: 0;
        align-self: center;
    }
}

/* ------------------------------------------------------------------
   RTL prices — force left-to-right so the ₪ stays on the LEFT of the
   number and variable price ranges read low–high. The currency/format
   settings are already correct (₪, left_space); this only stops the RTL
   BiDi algorithm from visually flipping the symbol to the right.
   ------------------------------------------------------------------ */
.woocommerce-Price-amount,
.woocommerce-Price-amount bdi {
    direction: ltr;
    unicode-bidi: isolate;
}
.woocommerce-Price-amount {
    display: inline-block;
}
.price,
.cat-card__price,
.cat-card__member-value,
.product__price,
.product__member-value,
.cart__price,
.cart__subtotal,
.cart__summary-value,
.cart__summary-total,
.checkout__order-td--end {
    direction: ltr;
}

/* ------------------------------------------------------------------
   Accessibility: AA-contrast gold for small informational text on light
   backgrounds. Brand gold (#C9A84C) on white is ~2.5:1 — fails WCAG AA for
   small text. #8B7332 reaches ~4.6:1. Applied to small body text (member
   price); large headings/buttons keep the brand gold (AA-large only needs 3:1).
   ------------------------------------------------------------------ */
:root {
    --color-gold-accessible: #8B7332;
}
.cat-card__member-value,
.product__member-value,
.cart-card__member-value {
    color: var(--color-gold-accessible);
}

/* ------------------------------------------------------------------
   My Account dashboard — nav sidebar + content; orders table, addresses
   grid, edit-account form, club badge, responsive stacking.
   Wrapper is .account-page (added in woocommerce/myaccount/my-account.php,
   inside the .container).
   ------------------------------------------------------------------ */
.account-page {
    display: flex;
    gap: var(--space-2xl);
    align-items: flex-start;
    padding-block: var(--space-xl);
}

/* ── Navigation sidebar ── */
.account-page .woocommerce-MyAccount-navigation {
    flex: 0 0 220px;
    position: sticky;
    top: 120px;
}
.account-page .woocommerce-MyAccount-content {
    flex: 1 1 auto;
    min-width: 0;
}
.woocommerce-MyAccount-navigation ul {
    list-style: none;
    margin: 0;
    padding: var(--space-sm);
    background: var(--color-cream-light);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}
.woocommerce-MyAccount-navigation ul li a {
    display: block;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--color-olive-700);
    text-decoration: none;
    padding: 10px 16px;
    border-radius: 8px;
    transition: all var(--transition-fast);
}
.woocommerce-MyAccount-navigation ul li a:hover {
    background: rgba(201, 168, 76, 0.12);
    color: var(--color-gold-dark);
}
.woocommerce-MyAccount-navigation ul li.is-active a {
    background: var(--color-gold);
    color: var(--color-white);
    font-weight: 600;
}
/* Logout link: muted, separated, red on hover */
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--customer-logout {
    margin-top: var(--space-xs);
    padding-top: var(--space-xs);
    border-top: 1px solid var(--color-cream);
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--customer-logout a {
    font-size: 0.82rem;
    color: #888;
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--customer-logout a:hover {
    background: transparent;
    color: #c0392b;
}

/* ── Content area ── */
.woocommerce-MyAccount-content {
    font-family: var(--font-body);
}
.woocommerce-MyAccount-content > p:first-of-type {
    line-height: 1.8;
    padding-bottom: var(--space-md);
    margin-bottom: var(--space-md);
    border-bottom: 1px solid var(--color-cream);
}
.woocommerce-MyAccount-content > p a {
    color: var(--color-gold-dark);
    font-weight: 600;
}

/* Club member badge on dashboard */
.club-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    background: linear-gradient(135deg, rgba(201, 168, 76, 0.1), rgba(201, 168, 76, 0.05));
    border: 1px solid rgba(201, 168, 76, 0.3);
    border-radius: 10px;
    padding: 10px 20px;
    margin-bottom: var(--space-lg);
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-gold-dark);
}

/* ── Orders table ── */
.woocommerce-MyAccount-content .woocommerce-orders-table,
.woocommerce-MyAccount-content table.shop_table {
    width: 100%;
    border-collapse: collapse;
}
.woocommerce-MyAccount-content thead {
    background: var(--color-cream-light);
}
.woocommerce-MyAccount-content th {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    border-bottom: 2px solid var(--color-cream);
}
.woocommerce-MyAccount-content .woocommerce-orders-table th,
.woocommerce-MyAccount-content .woocommerce-orders-table td,
.woocommerce-MyAccount-content table.shop_table th,
.woocommerce-MyAccount-content table.shop_table td {
    padding: 14px var(--space-md);
    border-bottom: 1px solid var(--color-cream);
    text-align: start;
    font-size: 0.9rem;
}
.woocommerce-MyAccount-content tbody tr:hover {
    background: rgba(201, 168, 76, 0.05);
}

/* ── Addresses ── */
.woocommerce-Addresses {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
}
.woocommerce-Addresses .woocommerce-Address {
    background: var(--color-cream-light);
    border-radius: 12px;
    padding: var(--space-lg);
}
.woocommerce-Address .woocommerce-Address-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: var(--space-sm);
    margin-bottom: var(--space-sm);
    border-bottom: 1px solid var(--color-cream);
}
.woocommerce-Address-title h3 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: 1.1rem;
}
.woocommerce-Address-title .edit {
    color: var(--color-gold-dark);
    font-size: 0.8rem;
    text-decoration: none;
}
.woocommerce-Address address {
    font-family: var(--font-body);
    font-size: 0.9rem;
    line-height: 1.8;
    font-style: normal;
}

/* ── Edit Account & address forms ── */
.woocommerce-MyAccount-content form label {
    display: block;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: var(--space-xs);
}
.woocommerce-MyAccount-content .woocommerce-form-row,
.woocommerce-MyAccount-content p.form-row {
    margin-bottom: var(--space-md);
}
.woocommerce-MyAccount-content input.input-text,
.woocommerce-MyAccount-content input[type="text"],
.woocommerce-MyAccount-content input[type="email"],
.woocommerce-MyAccount-content input[type="tel"],
.woocommerce-MyAccount-content input[type="password"],
.woocommerce-MyAccount-content select {
    width: 100%;
    height: 46px;
    padding: 0 14px;
    border: 1.5px solid var(--color-cream);
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 0.9rem;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.woocommerce-MyAccount-content input.input-text:focus,
.woocommerce-MyAccount-content input[type="text"]:focus,
.woocommerce-MyAccount-content input[type="email"]:focus,
.woocommerce-MyAccount-content input[type="tel"]:focus,
.woocommerce-MyAccount-content input[type="password"]:focus,
.woocommerce-MyAccount-content select:focus {
    border-color: var(--color-gold);
    outline: none;
    box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.12);
}
.woocommerce-MyAccount-content fieldset {
    border: 1px solid var(--color-cream);
    border-radius: 12px;
    padding: var(--space-lg);
    margin-top: var(--space-lg);
}
.woocommerce-MyAccount-content fieldset legend {
    padding-inline: var(--space-sm);
    font-family: var(--font-heading);
    font-size: 1.1rem;
}
.woocommerce-EditAccountForm span em {
    font-size: 0.8rem;
    color: #888;
    font-style: normal;
}

/* ── Buttons in account content ── */
.woocommerce-MyAccount-content a.button,
.woocommerce-MyAccount-content button.button,
.woocommerce-MyAccount-content input.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 46px;
    padding-inline: 28px;
    background: var(--color-gold);
    color: var(--color-white);
    border: none;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: background var(--transition-fast);
}
.woocommerce-MyAccount-content a.button:hover,
.woocommerce-MyAccount-content button.button:hover,
.woocommerce-MyAccount-content input.button:hover {
    background: var(--color-gold-dark);
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .account-page {
        flex-direction: column;
        gap: 0;
    }
    .account-page .woocommerce-MyAccount-navigation {
        flex: none;
        width: 100%;
        position: static;
        margin-bottom: var(--space-lg);
    }
    /* Nav becomes a horizontal scroll strip */
    .woocommerce-MyAccount-navigation ul {
        flex-direction: row;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: var(--space-xs);
    }
    .woocommerce-MyAccount-navigation ul::-webkit-scrollbar {
        display: none;
    }
    .woocommerce-MyAccount-navigation ul li {
        flex-shrink: 0;
    }
    .woocommerce-MyAccount-navigation ul li a {
        white-space: nowrap;
        padding: 8px 14px;
        font-size: 0.85rem;
    }
    .woocommerce-MyAccount-content {
        width: 100%;
    }
    .woocommerce-MyAccount-content .woocommerce-orders-table {
        font-size: 0.85rem;
    }
    .woocommerce-Addresses {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }
}

@media (max-width: 480px) {
    .woocommerce-MyAccount-navigation ul li a {
        padding: var(--space-xs) var(--space-sm);
        font-size: 0.8rem;
    }
    /* Drop the order Total column on the narrowest screens */
    .woocommerce-orders-table .woocommerce-orders-table__header-order-total,
    .woocommerce-orders-table .woocommerce-orders-table__cell-order-total {
        display: none;
    }
}

/* ── Club Registration Form ── */
.club-register { max-width: 780px; margin: 0 auto; }
.club-register__row { display: flex; gap: var(--space-md); }
.club-register__row .club-register__field { flex: 1; }
.club-register__field { margin-bottom: var(--space-md); }
.club-register__field label { display: block; font-family: var(--font-body); font-size: 0.9rem; font-weight: 600; margin-bottom: var(--space-xs); }
.club-register__field input,
.club-register__field select { width: 100%; padding: 10px 14px; border: 1px solid var(--color-cream); border-radius: 8px; font-family: var(--font-body); font-size: 0.95rem; transition: border-color var(--transition-fast); }
.club-register__field input:focus,
.club-register__field select:focus { border-color: var(--color-gold); outline: none; }
.club-register__dob-row { display: flex; gap: var(--space-sm); }
.club-register__dob-row select { flex: 1; }
.club-register__terms { margin-bottom: var(--space-lg); font-size: 0.85rem; }
.club-register__terms a { color: var(--color-gold); }
.club-register__btn { width: 100%; padding: 14px; background: var(--color-gold); color: white; border: none; border-radius: 8px; font-family: var(--font-heading); font-size: 1.05rem; font-weight: 700; cursor: pointer; transition: background var(--transition-fast); }
.club-register__btn:hover { background: var(--color-gold-dark); }
.club-register__status { text-align: center; padding: var(--space-xl); background: var(--color-cream-light); border-radius: 12px; }

/* Password toggle */
.club-register__password-wrap { position: relative; }
.club-register__password-wrap input { padding-left: 60px; }
.club-register__toggle-pw {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #999;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
}
.club-register__toggle-pw:hover { color: var(--color-gold); }

@media (max-width: 480px) {
  .club-register__row { flex-direction: column; gap: 0; }
}

/* ── Club Landing Page Hero ── */
.club-hero {
  text-align: center;
  padding: var(--space-xl) var(--container-padding);
  max-width: 780px;
  margin: 0 auto var(--space-lg);
}
.club-hero__title {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  color: var(--color-black);
  margin-bottom: var(--space-sm);
}
.club-hero__subtitle {
  font-family: var(--font-body);
  font-size: 1.05rem;
  color: #666;
  margin-bottom: var(--space-lg);
}
.club-hero__benefits {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  text-align: right;
  max-width: 400px;
  margin: 0 auto;
}
.club-hero__benefit {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  direction: rtl;
}
.club-hero__benefit-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}
.club-hero__benefit-text {
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.5;
}
.club-hero__benefit-text strong {
  color: var(--color-gold);
}

.club-hero__perks { font-family: var(--font-body); font-size: 0.95rem; color: #555; line-height: 1.8; }
.club-hero__perks strong { color: var(--color-gold); }

/* ── Club Tabs ── */
.club-tabs { max-width: 780px; margin: 0 auto; }
.club-tabs__nav { display: flex; justify-content: center; gap: var(--space-sm); margin-bottom: var(--space-lg); border-bottom: 2px solid var(--color-cream); padding-bottom: var(--space-sm); }
.club-tabs__tab { background: none; border: none; font-family: var(--font-body); font-size: 1rem; font-weight: 600; color: #999; cursor: pointer; padding: 8px 20px; border-bottom: 3px solid transparent; margin-bottom: -2px; transition: all var(--transition-fast); }
.club-tabs__tab:hover { color: var(--color-black); }
.club-tabs__tab--active { color: var(--color-gold); border-bottom-color: var(--color-gold); }
.club-tabs__panel { display: none; }
.club-tabs__panel--active { display: block; }
.club-login__forgot { text-align: center; margin-top: var(--space-md); font-size: 0.85rem; }
.club-login__forgot a { color: var(--color-gold); }
.club-register__join-existing { max-width: 780px; margin: 0 auto; text-align: center; }
.club-register__join-existing p { margin-bottom: var(--space-lg); font-family: var(--font-body); font-size: 1.05rem; }
.club-register__join-existing .club-register__row { justify-content: center; max-width: 400px; margin: 0 auto var(--space-md); }
.club-register__join-existing .club-register__btn { max-width: 400px; margin: 0 auto; display: block; }
.club-register__join-existing .club-register__terms { max-width: 400px; margin: 0 auto var(--space-lg); }

/* ==================================================================
   SITEMAP PAGE (page-sitemap.php)
   ================================================================== */
.sitemap__title {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: var(--color-black);
    margin-block-end: var(--space-xl);
}
.sitemap__section {
    margin-block-end: var(--space-2xl);
}
.sitemap__section-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--color-black);
    margin-block-end: var(--space-md);
    padding-block-end: var(--space-sm);
    border-block-end: 2px solid var(--color-gold);
}
.sitemap__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: var(--space-sm);
}
.sitemap__item a {
    font-family: var(--font-body);
    color: var(--color-black);
    text-decoration: none;
    padding: var(--space-xs) 0;
    display: block;
    transition: color 0.2s;
}
.sitemap__item a:hover {
    color: var(--color-gold);
}
@media (max-width: 480px) {
    .sitemap__list {
        grid-template-columns: 1fr;
    }
    .sitemap__title { font-size: 1.6rem; }
    .sitemap__section-title { font-size: 1.3rem; }
}

/* ==================================================================
   THANK YOU / ORDER RECEIVED — order details printed by the
   woocommerce_thankyou hook (woocommerce_order_details_table). page.php
   omits the container on checkout pages, so thankyou.php wraps this block
   in .container.thankyou__order; these rules give it the brand card look.
   ================================================================== */
.thankyou__order {
    margin-block: var(--space-2xl);
}
.woocommerce-order-details,
.woocommerce-customer-details {
    max-width: 800px;
    margin-inline: auto;
    margin-block-end: var(--space-xl);
}
.woocommerce-order-details__title,
.woocommerce-customer-details h2 {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: var(--color-black);
    margin-block-end: var(--space-md);
    padding-block-end: var(--space-sm);
    border-block-end: 2px solid var(--color-gold);
}
.woocommerce-table--order-details {
    width: 100%;
    border-collapse: collapse;
    background: var(--color-white);
    border: 1px solid var(--color-cream);
    border-radius: 8px;
    overflow: hidden;
    font-family: var(--font-body);
    font-size: 0.95rem;
}
.woocommerce-table--order-details th,
.woocommerce-table--order-details td {
    padding: 12px 16px;
    text-align: start;
    border-block-end: 1px solid var(--color-cream);
}
.woocommerce-table--order-details thead th {
    background: var(--color-cream-light);
    font-family: var(--font-heading);
    color: var(--color-black);
}
.woocommerce-table--order-details tfoot th {
    background: var(--color-cream-light);
    text-align: start;
}
.woocommerce-table--order-details tfoot tr:last-child th,
.woocommerce-table--order-details tfoot tr:last-child td {
    font-size: 1.1rem;
    color: var(--color-gold-dark);
    border-block-end: none;
}
.woocommerce-customer-details address {
    font-style: normal;
    line-height: 1.8;
    padding: var(--space-md) var(--space-lg);
    background: var(--color-cream-light);
    border: 1px solid var(--color-cream);
    border-radius: 8px;
}
@media (max-width: 480px) {
    .woocommerce-table--order-details th,
    .woocommerce-table--order-details td { padding: 8px 10px; font-size: 0.88rem; }
}

/* ==================================================================
   ORDER-RECEIVED / ORDER-PAY — center the content column.
   page.php omits the .container on checkout pages, and the theme has
   no form-pay.php, so WooCommerce core renders full-width and RTL
   pushes everything to the right edge. Scoped to these two body classes
   only — does NOT affect cart / main checkout / account. Centering only;
   the brand table styling above is untouched.
   ================================================================== */
body.woocommerce-order-received .site-main--page,
body.woocommerce-order-pay .site-main--page {
    max-width: 840px;
    margin-inline: auto;
    padding-inline: var(--container-padding);
    box-sizing: border-box;
}
body.woocommerce-order-pay .site-main--page {
    max-width: 620px;
}
/* Center the thank-you greeting (RTL defaults to right-aligned). */
body.woocommerce-order-received .thankyou,
body.woocommerce-order-received .thankyou__title,
body.woocommerce-order-received .thankyou__text {
    text-align: center;
}

/* SMS delivery notice on the thank-you page. */
.thankyou__sms-notice {
    text-align: center;
    color: var(--color-text-secondary, #666);
    font-size: 15px;
    margin-top: 8px;
    margin-bottom: 20px;
}
