/*
Theme Name: AgriMart
Theme URI: https://example.com/agrimart
Author: Built with Claude
Author URI: https://example.com
Description: A clean, high-trust WooCommerce theme for agriculture marketplaces. Deep-green agri look with a harvest-gold accent, built for machinery, tools, fertilizers, pesticides, irrigation and gardening supplies. Fully responsive, WooCommerce-ready.
Version: 1.3.1
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: agrimart
Tags: e-commerce, two-columns, right-sidebar, custom-menu, custom-logo, featured-images, threaded-comments, translation-ready
WC requires at least: 6.0
WC tested up to: 8.6
*/

/* ==========================================================================
   1. Design tokens
   ========================================================================== */
:root {
    --am-green:        #1e7a4d; /* primary - fresher, brighter */
    --am-green-dark:   #14563a; /* header / footer bands */
    --am-green-deep:   #0e3325; /* footer base */
    --am-green-fresh:  #2f9e63; /* links / hover */
    --am-green-soft:   #d3e7d9; /* card tints, borders */
    --am-green-mist:   #eef4ec; /* section wash */
    --am-gold:         #ef7d21; /* harvest-orange accent / sale */
    --am-gold-dark:    #cc6413;
    --am-ink:          #16261d; /* body text */
    --am-muted:        #5c6b60; /* secondary text */
    --am-line:         #e7e3d6; /* warm hairlines */
    --am-page:         #f8f6ef; /* warm wheat canvas */
    --am-white:        #ffffff;
    --am-danger:       #c0392b;

    --am-font-head: "Bricolage Grotesque", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --am-font-body: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    --am-radius:    14px;
    --am-radius-sm: 9px;
    --am-shadow:    0 1px 2px rgba(16, 41, 29, .04), 0 8px 24px rgba(16, 41, 29, .06);
    --am-shadow-lg: 0 12px 40px rgba(16, 41, 29, .12);
    --am-wrap:      1200px;
    --am-gap:       clamp(1rem, 2.5vw, 1.75rem);
    --am-transition: .18s ease;
}

/* ==========================================================================
   2. Base / reset
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--am-font-body);
    font-size: 16px;
    line-height: 1.65;
    color: var(--am-ink);
    background: var(--am-page);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--am-font-head);
    font-weight: 700;
    line-height: 1.15;
    color: var(--am-ink);
    margin: 0 0 .6em;
    letter-spacing: -0.01em;
}
h1 { font-size: clamp(2rem, 4.5vw, 3rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.25rem); }
h3 { font-size: 1.35rem; }
h4 { font-size: 1.1rem; }

p { margin: 0 0 1.2em; }

a {
    color: var(--am-green-fresh);
    text-decoration: none;
    transition: color var(--am-transition);
}
a:hover, a:focus { color: var(--am-green-dark); }

img { max-width: 100%; height: auto; display: block; }

/* Inline icon default size (prevents unconstrained SVGs from ballooning) */
.am-icon { width: 20px; height: 20px; flex: 0 0 auto; }
.am-topbar__msg .am-icon { width: 16px; height: 16px; }
.am-hero__eyebrow .am-icon { width: 16px; height: 16px; }

ul, ol { padding-left: 1.25rem; }

blockquote {
    margin: 1.5rem 0;
    padding: .5rem 0 .5rem 1.25rem;
    border-left: 4px solid var(--am-gold);
    color: var(--am-muted);
    font-style: italic;
}

code, pre {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    background: var(--am-green-mist);
    border-radius: 6px;
}
code { padding: .12em .4em; font-size: .9em; }
pre { padding: 1rem; overflow: auto; }

hr { border: 0; border-top: 1px solid var(--am-line); margin: 2rem 0; }

:focus-visible {
    outline: 3px solid var(--am-gold);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Accessibility helpers */
.screen-reader-text {
    border: 0; clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px; width: 1px;
    margin: -1px; overflow: hidden; padding: 0;
    position: absolute !important; word-wrap: normal !important;
}
.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 999;
    background: var(--am-gold); color: var(--am-green-deep);
    padding: .6rem 1rem; font-weight: 600; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; color: var(--am-green-deep); }

/* ==========================================================================
   3. Layout helpers
   ========================================================================== */
.am-wrap {
    width: min(100% - 2.5rem, var(--am-wrap));
    margin-inline: auto;
}
.am-section { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.am-section--mist { background: var(--am-green-mist); }

.am-section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}
.am-section-title {
    position: relative;
    margin: 0;
    padding-bottom: .5rem;
}
/* signature: a short green rule tipped with a harvest-orange seed */
.am-section-title::after {
    content: "";
    position: absolute;
    left: 0; bottom: 0;
    width: 44px; height: 4px;
    border-radius: 4px;
    background: var(--am-green);
}
.am-section-title::before {
    content: "";
    position: absolute;
    left: 48px; bottom: -1px;
    width: 8px; height: 8px;
    border-radius: 50% 50% 50% 0;
    transform: rotate(45deg);
    background: var(--am-gold);
}
.am-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    font-family: var(--am-font-head);
    font-size: .76rem;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--am-green);
    margin-bottom: .55rem;
}
.am-eyebrow::before {
    content: "";
    width: 18px; height: 2px; border-radius: 2px;
    background: var(--am-gold);
}

/* Buttons */
.am-btn, .button, button, input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    font-family: var(--am-font-head);
    font-weight: 600;
    font-size: .95rem;
    line-height: 1;
    padding: .85rem 1.5rem;
    border: 2px solid var(--am-green);
    border-radius: 999px;
    background: var(--am-green);
    color: #fff;
    cursor: pointer;
    transition: background var(--am-transition), border-color var(--am-transition), transform var(--am-transition), color var(--am-transition);
}
.am-btn:hover, .button:hover, button:hover, input[type="submit"]:hover {
    background: var(--am-green-dark);
    border-color: var(--am-green-dark);
    color: #fff;
    transform: translateY(-1px);
}
.am-btn--gold { background: var(--am-gold); border-color: var(--am-gold); color: #fff; }
.am-btn--gold:hover { background: var(--am-gold-dark); border-color: var(--am-gold-dark); color: #fff; }
.am-btn--ghost { background: transparent; color: var(--am-green-dark); }
.am-btn--ghost:hover { background: var(--am-green); border-color: var(--am-green); color: #fff; }
.am-btn--light { background: #fff; border-color: #fff; color: var(--am-green-dark); }
.am-btn--light:hover { background: var(--am-gold); border-color: var(--am-gold); color: var(--am-green-deep); }

/* Forms */
input[type="text"], input[type="email"], input[type="url"], input[type="password"],
input[type="search"], input[type="number"], input[type="tel"], input[type="date"],
textarea, select {
    width: 100%;
    padding: .7rem .9rem;
    font-family: var(--am-font-body);
    font-size: 1rem;
    color: var(--am-ink);
    background: #fff;
    border: 1px solid var(--am-line);
    border-radius: var(--am-radius-sm);
    transition: border-color var(--am-transition), box-shadow var(--am-transition);
}
input:focus, textarea:focus, select:focus {
    border-color: var(--am-green-fresh);
    box-shadow: 0 0 0 3px rgba(64, 145, 108, .18);
    outline: none;
}
label { font-weight: 600; font-size: .92rem; }

/* ==========================================================================
   4. Header
   ========================================================================== */
.am-topbar {
    background: var(--am-green-deep);
    color: #cfe3d6;
    font-size: .82rem;
}
.am-topbar .am-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 38px;
    flex-wrap: wrap;
}
.am-topbar a { color: #eaf3ed; }
.am-topbar a:hover { color: var(--am-gold); }
.am-topbar__msg { display: inline-flex; align-items: center; gap: .5rem; }

.site-header {
    background: var(--am-green-dark);
    color: #fff;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 12px rgba(16, 41, 29, .18);
}
.am-header__inner {
    display: flex;
    align-items: center;
    gap: clamp(1rem, 3vw, 2.5rem);
    min-height: 76px;
}
.am-branding { display: flex; align-items: center; gap: .7rem; flex-shrink: 0; }
.am-branding a { display: flex; align-items: center; gap: .7rem; color: #fff; }
.am-branding__mark {
    width: 40px; height: 40px;
    display: grid; place-items: center;
    background: var(--am-gold);
    color: var(--am-green-deep);
    border-radius: 12px;
    flex-shrink: 0;
}
.am-branding__mark svg { width: 24px; height: 24px; }
.site-title {
    font-family: var(--am-font-head);
    font-size: 1.4rem;
    font-weight: 800;
    line-height: 1;
    margin: 0;
    letter-spacing: -0.02em;
    color: #fff;
}
.site-title a { color: #fff; }
.site-description { margin: 2px 0 0; font-size: .72rem; color: #9dc3ac; letter-spacing: .04em; }
.custom-logo { max-height: 52px; width: auto; }

/* Header search */
.am-header__search { flex: 1 1 auto; max-width: 560px; }
/* the_widget() wraps the search in a .widget box — reset it inside the header */
.am-header__search .widget,
.am-header__search .widget.woocommerce {
    background: transparent; border: 0; border-radius: 0; padding: 0; margin: 0; box-shadow: none;
}
.am-header__search .widget-title { display: none; }
.am-header__search form { position: relative; display: block; margin: 0; }
.am-header__search label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.am-header__search input[type="search"] {
    width: 100%;
    height: 50px;
    line-height: 1.2;
    border-radius: 999px;
    padding: 0 7rem 0 1.3rem;
    border-color: transparent;
    background: #fff;
    font-size: 1rem;
}
.am-header__search button {
    position: absolute; right: 5px; top: 50%; transform: translateY(-50%);
    width: auto; height: 40px; min-height: 40px; padding: 0 1.3rem;
    border-radius: 999px;
    font-size: .92rem;
    background: var(--am-gold); border-color: var(--am-gold); color: #fff;
}
.am-header__search button:hover { background: var(--am-gold-dark); border-color: var(--am-gold-dark); color: #fff; transform: translateY(-50%); }

/* Header actions */
.am-header__actions { display: flex; align-items: center; gap: 1.25rem; margin-left: auto; }
.am-header__icon {
    display: inline-flex; align-items: center; gap: .5rem;
    color: #fff; font-weight: 500; font-size: .9rem;
    position: relative;
}
.am-header__icon:hover { color: var(--am-gold); }
.am-header__icon svg { width: 24px; height: 24px; }
.am-cart-count {
    position: absolute; top: -8px; left: 14px;
    min-width: 18px; height: 18px; padding: 0 5px;
    display: grid; place-items: center;
    background: var(--am-gold); color: var(--am-green-deep);
    font-size: .68rem; font-weight: 700; line-height: 1;
    border-radius: 999px;
}

/* ==========================================================================
   5. Primary navigation
   ========================================================================== */
.am-nav-bar { background: var(--am-green); }
.main-navigation { display: flex; align-items: center; }
.main-navigation ul {
    list-style: none; margin: 0; padding: 0;
    display: flex; flex-wrap: wrap;
}
.main-navigation li { position: relative; }
.main-navigation a {
    display: block;
    padding: .95rem 1.15rem;
    color: #eaf3ed;
    font-family: var(--am-font-head);
    font-weight: 500;
    font-size: .95rem;
    transition: background var(--am-transition), color var(--am-transition);
}
.main-navigation a:hover,
.main-navigation .current-menu-item > a,
.main-navigation .current_page_item > a {
    background: var(--am-green-dark);
    color: #fff;
}
/* Sub-menus */
.main-navigation ul ul {
    position: absolute;
    top: 100%; left: 0;
    display: block;
    min-width: 220px;
    background: #fff;
    border-radius: 0 0 var(--am-radius-sm) var(--am-radius-sm);
    box-shadow: var(--am-shadow-lg);
    opacity: 0; visibility: hidden; transform: translateY(6px);
    transition: opacity var(--am-transition), transform var(--am-transition), visibility var(--am-transition);
    z-index: 40;
    padding: .35rem 0;
}
.main-navigation li:hover > ul,
.main-navigation li:focus-within > ul { opacity: 1; visibility: visible; transform: translateY(0); }
.main-navigation ul ul a { color: var(--am-ink); padding: .6rem 1.1rem; }
.main-navigation ul ul a:hover { background: var(--am-green-mist); color: var(--am-green-dark); }

/* Mobile toggle */
.am-menu-toggle {
    display: none;
    background: transparent; border: 0; color: #fff;
    padding: .5rem; cursor: pointer;
}
.am-menu-toggle svg { width: 26px; height: 26px; }

/* ==========================================================================
   6. Hero
   ========================================================================== */
.am-hero {
    position: relative;
    background:
        radial-gradient(900px 420px at 88% 0%, rgba(30,122,77,.10), transparent 62%),
        linear-gradient(180deg, #fcfbf5 0%, var(--am-page) 100%);
    color: var(--am-ink);
    overflow: hidden;
    border-bottom: 1px solid var(--am-line);
}
/* subtle furrow rows as a signature backdrop */
.am-hero::after {
    content: "";
    position: absolute; inset: 0;
    background-image: repeating-linear-gradient(115deg, rgba(30,122,77,.05) 0 2px, transparent 2px 26px);
    pointer-events: none;
}
.am-hero__inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    gap: clamp(1.5rem, 4vw, 3.5rem);
    align-items: center;
    padding: clamp(2.5rem, 6vw, 4.5rem) 0;
}
.am-hero__eyebrow {
    display: inline-flex; align-items: center; gap: .5rem;
    background: var(--am-green-mist);
    color: var(--am-green);
    font-family: var(--am-font-head);
    font-weight: 600; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase;
    padding: .45rem 1rem; border-radius: 999px;
    border: 1px solid var(--am-green-soft);
    margin-bottom: 1.4rem;
}
.am-hero__eyebrow .am-icon { color: var(--am-gold); }
.am-hero h1 { color: var(--am-ink); font-size: clamp(2.2rem, 5vw, 3.7rem); font-weight: 700; letter-spacing: -0.02em; }
.am-hero h1 .am-hl { color: var(--am-green); position: relative; white-space: nowrap; }
/* hand-drawn underline under the highlighted word */
.am-hero h1 .am-hl::after {
    content: "";
    position: absolute; left: 0; right: 0; bottom: -.08em; height: .28em;
    background: var(--am-gold);
    border-radius: 999px;
    opacity: .35;
    z-index: -1;
}
.am-hero__lead { font-size: 1.14rem; color: var(--am-muted); max-width: 46ch; margin-bottom: 1.8rem; }
.am-hero__cta { display: flex; flex-wrap: wrap; gap: .8rem; }
.am-hero__cta .am-btn--light { background: #fff; border-color: var(--am-green-soft); color: var(--am-green-dark); }
.am-hero__cta .am-btn--light:hover { background: var(--am-green); border-color: var(--am-green); color: #fff; }
.am-hero__stats {
    display: flex; gap: 2.25rem; margin-top: 2.4rem; flex-wrap: wrap;
}
.am-hero__stat { position: relative; padding-left: 1rem; }
.am-hero__stat::before { content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 3px; border-radius: 3px; background: var(--am-gold); }
.am-hero__stat strong { display: block; font-family: var(--am-font-head); font-size: 1.65rem; color: var(--am-green-dark); line-height: 1; }
.am-hero__stat span { font-size: .82rem; color: var(--am-muted); }
.am-hero__media {
    position: relative;
    border-radius: var(--am-radius);
    overflow: hidden;
    box-shadow: var(--am-shadow-lg);
    aspect-ratio: 4 / 3;
    background: var(--am-green-mist);
    border: 6px solid #fff;
    outline: 1px solid var(--am-line);
}
.am-hero__media img { width: 100%; height: 100%; object-fit: cover; }

/* Trust bar */
.am-trust {
    background: var(--am-white);
    border-bottom: 1px solid var(--am-line);
}
.am-trust__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    padding: 1.5rem 0;
}
.am-trust__item { display: flex; align-items: center; gap: .8rem; }
.am-trust__item svg { width: 30px; height: 30px; color: var(--am-green); flex-shrink: 0; }
.am-trust__item strong { display: block; font-family: var(--am-font-head); font-size: .98rem; }
.am-trust__item span { font-size: .82rem; color: var(--am-muted); }

/* ==========================================================================
   7. Category grid
   ========================================================================== */
.am-cat-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: var(--am-gap);
}
@media (max-width: 1024px) { .am-cat-grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 820px)  { .am-cat-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px)  { .am-cat-grid { grid-template-columns: repeat(2, 1fr); } }
.am-cat-card {
    display: flex; flex-direction: column;
    background: #fff;
    border: 1px solid var(--am-line);
    border-radius: var(--am-radius);
    overflow: hidden;
    text-align: center;
    transition: transform var(--am-transition), box-shadow var(--am-transition), border-color var(--am-transition);
}
.am-cat-card:hover { transform: translateY(-4px); box-shadow: var(--am-shadow); border-color: var(--am-green-soft); }
.am-cat-card__thumb {
    aspect-ratio: 4 / 3;
    background: linear-gradient(160deg, var(--am-green-mist), var(--am-green-soft));
    display: grid; place-items: center;
    overflow: hidden;
}
.am-cat-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.am-cat-card__thumb svg { width: 46px; height: 46px; color: var(--am-green); }
.am-cat-card__body { padding: 1rem .75rem 1.2rem; }
.am-cat-card__body h3 { font-size: 1.02rem; margin: 0 0 .15rem; color: var(--am-green-dark); }
.am-cat-card__count { font-size: .8rem; color: var(--am-muted); }

/* ==========================================================================
   8. Product cards (WooCommerce)
   ========================================================================== */
.woocommerce ul.products:not(.am-carousel__track),
ul.products:not(.am-carousel__track) {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    justify-content: stretch !important;
    justify-items: stretch !important;
    gap: var(--am-gap) !important;
    list-style: none;
    margin: 0; padding: 0;
}
/* WooCommerce adds ::before/::after clearfix elements that become phantom grid
   cells (pushing products right by one slot). Remove them in the grid. */
.woocommerce ul.products::before,
.woocommerce ul.products::after,
.woocommerce-page ul.products::before,
.woocommerce-page ul.products::after,
ul.products::before,
ul.products::after {
    content: none !important;
    display: none !important;
}
/* 3 across when the shop has a sidebar */
.am-layout.has-sidebar .woocommerce ul.products:not(.am-carousel__track),
.am-layout.has-sidebar ul.products:not(.am-carousel__track) {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}
@media (max-width: 900px) {
    .woocommerce ul.products:not(.am-carousel__track),
    ul.products:not(.am-carousel__track),
    .am-layout.has-sidebar .woocommerce ul.products:not(.am-carousel__track),
    .am-layout.has-sidebar ul.products:not(.am-carousel__track) {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}
.woocommerce ul.products li.product,
ul.products li.product {
    width: auto !important;
    margin: 0 !important;
    float: none !important;
    background: #fff;
    border: 1px solid var(--am-line);
    border-radius: var(--am-radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform var(--am-transition), box-shadow var(--am-transition), border-color var(--am-transition);
}
.woocommerce ul.products li.product:hover {
    transform: translateY(-4px);
    box-shadow: var(--am-shadow);
    border-color: var(--am-green-soft);
}
.woocommerce ul.products li.product a.woocommerce-LoopProduct-link { display: block; }
.woocommerce ul.products li.product img {
    aspect-ratio: 1 / 1;
    object-fit: cover;
    width: 100%;
    margin: 0 !important;
    background: var(--am-green-mist);
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
    font-family: var(--am-font-head);
    font-size: 1rem !important;
    font-weight: 600;
    color: var(--am-ink);
    padding: .9rem 1rem .2rem !important;
    line-height: 1.3;
}
.woocommerce ul.products li.product .price {
    display: block;
    padding: 0 1rem;
    color: var(--am-green-dark) !important;
    font-family: var(--am-font-head);
    font-weight: 700;
    font-size: 1.1rem;
}
.woocommerce ul.products li.product .price del { color: var(--am-muted); font-weight: 400; font-size: .9rem; margin-right: .35rem; }
.woocommerce ul.products li.product .price ins { text-decoration: none; }
.woocommerce ul.products li.product .star-rating { margin: .5rem 1rem 0; font-size: .8rem; }
.woocommerce ul.products li.product .button,
.woocommerce ul.products li.product .added_to_cart {
    margin: .9rem 1rem 1.1rem !important;
    width: calc(100% - 2rem);
    box-sizing: border-box;
}
.woocommerce ul.products li.product .onsale,
.woocommerce span.onsale {
    position: absolute; top: 12px; left: 12px;
    background: var(--am-gold); color: var(--am-green-deep);
    font-family: var(--am-font-head); font-weight: 700; font-size: .72rem;
    padding: .3rem .6rem; border-radius: 999px;
    min-height: auto; min-width: auto; line-height: 1; margin: 0;
    z-index: 3;
}
.woocommerce ul.products li.product .woocommerce-loop-product__link { flex: 1; }

/* ==========================================================================
   9. Single product
   ========================================================================== */
.woocommerce div.product { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: start; }
/* Every direct child spans full width by default; only gallery + summary share the top row.
   This prevents any unexpected element from displacing/hiding the product info. */
.woocommerce div.product > * { grid-column: 1 / -1; min-width: 0; }
.woocommerce div.product > .woocommerce-product-gallery { grid-column: 1 / 2; grid-row: 1; }
.woocommerce div.product > .summary,
.woocommerce div.product > .entry-summary { grid-column: 2 / 3; grid-row: 1; }
/* Override WooCommerce's default 48% gallery/summary widths so they fill their grid cells */
.woocommerce div.product .woocommerce-product-gallery,
.woocommerce div.product .woocommerce-product-gallery.images { width: 100% !important; float: none !important; margin: 0 !important; }
.woocommerce div.product .entry-summary { width: 100% !important; float: none !important; margin: 0 !important; }
.woocommerce div.product .woocommerce-product-gallery { margin: 0; }
.woocommerce div.product .woocommerce-product-gallery img { border-radius: var(--am-radius); }
.woocommerce div.product .product_title { font-size: clamp(1.6rem, 3vw, 2.2rem); margin-bottom: .5rem; }
.woocommerce div.product p.price,
.woocommerce div.product span.price {
    color: var(--am-green-dark);
    font-family: var(--am-font-head);
    font-size: 1.7rem; font-weight: 800;
}
.woocommerce div.product .woocommerce-product-rating { margin-bottom: 1rem; }
.woocommerce div.product form.cart { margin: 1.5rem 0; display: flex; gap: .75rem; flex-wrap: wrap; align-items: center; }
.woocommerce div.product form.cart .quantity input {
    width: 84px; text-align: center;
}
.woocommerce .quantity .qty { padding: .8rem .5rem; }
.woocommerce div.product .product_meta { font-size: .88rem; color: var(--am-muted); margin-top: 1.5rem; padding-top: 1rem; border-top: 1px solid var(--am-line); }
.woocommerce div.product .product_meta a { color: var(--am-green-fresh); }

/* Tabs */
.woocommerce div.product .woocommerce-tabs { grid-column: 1 / -1; margin-top: 1rem; }
.woocommerce div.product .woocommerce-tabs ul.tabs {
    border: 0; padding: 0; margin: 0 0 1.5rem;
    display: flex; gap: .5rem; flex-wrap: wrap;
}
.woocommerce div.product .woocommerce-tabs ul.tabs::before { display: none; }
.woocommerce div.product .woocommerce-tabs ul.tabs li {
    background: var(--am-green-mist); border: 0; border-radius: 999px; margin: 0; padding: 0;
}
.woocommerce div.product .woocommerce-tabs ul.tabs li::before,
.woocommerce div.product .woocommerce-tabs ul.tabs li::after { display: none; }
.woocommerce div.product .woocommerce-tabs ul.tabs li a { padding: .6rem 1.25rem; color: var(--am-green-dark); font-family: var(--am-font-head); font-weight: 600; }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active { background: var(--am-green); }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: #fff; }

/* Related products full width */
.woocommerce .related.products,
.woocommerce .upsells.products { grid-column: 1 / -1; margin-top: 3rem; }
.woocommerce .related.products > h2,
.woocommerce .upsells.products > h2 { font-size: 1.5rem; margin-bottom: 1.5rem; }

/* ==========================================================================
   10. WooCommerce misc (notices, cart, checkout, pagination)
   ========================================================================== */
.woocommerce-message, .woocommerce-info, .woocommerce-error, .woocommerce-noreviews {
    border-top: none;
    border-radius: var(--am-radius-sm);
    padding: 1rem 1.25rem 1rem 3rem;
    position: relative;
    font-size: .95rem;
    list-style: none;
}
.woocommerce-message { background: var(--am-green-mist); color: var(--am-green-dark); }
.woocommerce-message::before { color: var(--am-green); }
.woocommerce-info { background: #eef3fb; color: #2c4a7c; }
.woocommerce-info::before { color: #3a6bc4; }
.woocommerce-error { background: #fdecea; color: var(--am-danger); }

.woocommerce-message .button,
.woocommerce-info .button { padding: .45rem 1rem; font-size: .82rem; }

.woocommerce table.shop_table {
    border-radius: var(--am-radius); border-collapse: separate; border-spacing: 0;
    overflow: hidden; border: 1px solid var(--am-line);
}
.woocommerce table.shop_table th { background: var(--am-green-mist); font-family: var(--am-font-head); }
.woocommerce-cart table.cart img { width: 64px; border-radius: 8px; }

.woocommerce #respond input#submit.alt,
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt {
    background: var(--am-gold); border-color: var(--am-gold); color: var(--am-green-deep);
}
.woocommerce #respond input#submit.alt:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover {
    background: var(--am-gold-dark); border-color: var(--am-gold-dark); color: var(--am-green-deep);
}

.woocommerce nav.woocommerce-pagination ul { border: 0; display: flex; gap: .4rem; justify-content: center; }
.woocommerce nav.woocommerce-pagination ul li { border: 0; }
.woocommerce nav.woocommerce-pagination ul li a,
.woocommerce nav.woocommerce-pagination ul li span {
    border-radius: 8px; border: 1px solid var(--am-line);
    min-width: 42px; padding: .5rem; font-family: var(--am-font-head); font-weight: 600;
}
.woocommerce nav.woocommerce-pagination ul li span.current {
    background: var(--am-green); color: #fff; border-color: var(--am-green);
}

/* Shop toolbar */
.woocommerce .woocommerce-result-count { color: var(--am-muted); margin: 0; }
.woocommerce .woocommerce-ordering { margin: 0; }
.am-shop-toolbar {
    display: flex; align-items: center; justify-content: space-between;
    gap: 1rem; flex-wrap: wrap; margin-bottom: 1.75rem;
}

/* ==========================================================================
   11. Content / posts / pages
   ========================================================================== */
.site-content { padding: clamp(2rem, 5vw, 3.5rem) 0; }
.am-layout { display: grid; grid-template-columns: 1fr; gap: clamp(1.5rem, 4vw, 3rem); }
.am-layout.has-sidebar { grid-template-columns: minmax(0, 1fr) 300px; }

.am-page-header { margin-bottom: 2rem; }
.am-page-header .page-title, .am-page-header .entry-title { margin-bottom: .3rem; }

.am-post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: var(--am-gap); }
.am-card {
    background: #fff; border: 1px solid var(--am-line); border-radius: var(--am-radius);
    overflow: hidden; display: flex; flex-direction: column;
    transition: transform var(--am-transition), box-shadow var(--am-transition);
}
.am-card:hover { transform: translateY(-3px); box-shadow: var(--am-shadow); }
.am-card__thumb { aspect-ratio: 16 / 9; overflow: hidden; background: var(--am-green-mist); }
.am-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.am-card__body { padding: 1.25rem; }
.am-card__body h2, .am-card__body h3 { font-size: 1.2rem; margin-bottom: .4rem; }
.am-card__meta { font-size: .8rem; color: var(--am-muted); margin-bottom: .6rem; }
.am-readmore { font-family: var(--am-font-head); font-weight: 600; }

.entry-content { max-width: 72ch; }
.entry-content > * { margin-bottom: 1.2rem; }
.entry-content h2 { margin-top: 2rem; }
.wp-block-image img, .entry-content img { border-radius: var(--am-radius-sm); }
.wp-caption-text, .wp-element-caption { font-size: .82rem; color: var(--am-muted); text-align: center; }
.sticky .am-card, .sticky.am-card { border-color: var(--am-gold); }

.post-navigation, .posts-navigation { margin: 2.5rem 0 0; padding-top: 1.5rem; border-top: 1px solid var(--am-line); }
.post-navigation .nav-links { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }

/* Comments */
.comments-area { margin-top: 3rem; }
.comment-list { list-style: none; padding: 0; }
.comment-body { padding: 1.25rem; border: 1px solid var(--am-line); border-radius: var(--am-radius); margin-bottom: 1rem; background: #fff; }
.comment-author { font-family: var(--am-font-head); font-weight: 600; }
.comment-metadata { font-size: .8rem; color: var(--am-muted); }
.comment-list .children { list-style: none; padding-left: clamp(1rem, 4vw, 2.5rem); }

/* ==========================================================================
   12. Sidebar / widgets
   ========================================================================== */
.widget { background: #fff; border: 1px solid var(--am-line); border-radius: var(--am-radius); padding: 1.4rem; margin-bottom: 1.5rem; }
.widget-title { font-size: 1.05rem; margin-bottom: 1rem; padding-bottom: .6rem; border-bottom: 2px solid var(--am-green-mist); position: relative; }
.widget-title::after { content: ""; position: absolute; left: 0; bottom: -2px; width: 40px; height: 2px; background: var(--am-gold); }
.widget ul { list-style: none; padding: 0; margin: 0; }
.widget ul li { padding: .45rem 0; border-bottom: 1px dashed var(--am-line); }
.widget ul li:last-child { border-bottom: 0; }
.widget ul li a { color: var(--am-ink); }
.widget ul li a:hover { color: var(--am-green-fresh); }
.widget_product_search .woocommerce-product-search { display: flex; gap: .5rem; flex-direction: column; }

/* ==========================================================================
   13. Footer
   ========================================================================== */
.site-footer { background: var(--am-green-deep); color: #b7cfc0; margin-top: auto; }
.am-footer__cta {
    background: var(--am-green);
    padding: clamp(2rem, 5vw, 3rem) 0;
}
.am-footer__cta .am-wrap { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.am-footer__cta h2 { color: #fff; margin: 0; }
.am-footer__cta p { color: #d7ecdf; margin: .3rem 0 0; }

.am-footer__main {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: 2.5rem;
    padding: clamp(2.5rem, 6vw, 4rem) 0 2.5rem;
}
.am-footer__main h4 { color: #fff; font-size: 1rem; margin-bottom: 1rem; }
.am-footer__main a { color: #b7cfc0; }
.am-footer__main a:hover { color: var(--am-gold); }
.am-footer__main ul { list-style: none; padding: 0; margin: 0; }
.am-footer__main li { padding: .3rem 0; }
.am-footer__brand p { font-size: .92rem; margin-top: .8rem; max-width: 34ch; }
.am-footer__contact li { display: flex; gap: .6rem; align-items: flex-start; }
.am-footer__contact svg { width: 18px; height: 18px; color: var(--am-gold); flex-shrink: 0; margin-top: 3px; }
.am-social { display: flex; gap: .6rem; margin-top: 1rem; }
.am-social a {
    width: 38px; height: 38px; border-radius: 10px;
    display: grid; place-items: center;
    background: rgba(255,255,255,.08); color: #fff;
}
.am-social a:hover { background: var(--am-gold); color: var(--am-green-deep); }
.am-social svg { width: 18px; height: 18px; }

.am-footer__bottom {
    border-top: 1px solid rgba(255,255,255,.1);
    padding: 1.4rem 0;
    font-size: .85rem;
}
.am-footer__bottom .am-wrap { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.am-footer__pay { display: flex; gap: .5rem; align-items: center; }
.am-footer__pay span { background: rgba(255,255,255,.1); padding: .25rem .55rem; border-radius: 6px; font-size: .72rem; font-weight: 600; letter-spacing: .03em; }

/* ==========================================================================
   14. Responsive
   ========================================================================== */
@media (max-width: 980px) {
    .am-hero__inner { grid-template-columns: 1fr; }
    .am-hero__media { order: -1; aspect-ratio: 16 / 9; }
    .woocommerce div.product { grid-template-columns: 1fr; }
    .woocommerce div.product > .woocommerce-product-gallery,
    .woocommerce div.product > .summary,
    .woocommerce div.product > .entry-summary { grid-column: 1 / -1; grid-row: auto; }
    .am-footer__main { grid-template-columns: 1fr 1fr; gap: 2rem; }
    .am-trust__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
    .am-layout.has-sidebar { grid-template-columns: 1fr; }
    .am-header__search { order: 3; flex-basis: 100%; max-width: none; }
    .am-header__inner { flex-wrap: wrap; min-height: auto; padding: .9rem 0; gap: 1rem; }
    .am-menu-toggle { display: inline-flex; margin-left: auto; }
    .am-nav-bar .am-wrap { padding: 0; width: 100%; }
    .main-navigation ul { flex-direction: column; display: none; }
    .main-navigation.am-nav--open ul { display: flex; }
    .main-navigation ul ul {
        position: static; opacity: 1; visibility: visible; transform: none;
        box-shadow: none; border-radius: 0; background: var(--am-green-dark);
        padding: 0;
    }
    .main-navigation ul ul a { color: #eaf3ed; padding-left: 2rem; }
    .main-navigation ul ul a:hover { background: var(--am-green-deep); color: #fff; }
}

@media (max-width: 560px) {
    .am-topbar__links { display: none; }
    .am-footer__main { grid-template-columns: 1fr; }
    .am-trust__grid { grid-template-columns: 1fr; }
    .am-header__actions { gap: .9rem; }
    .am-header__icon span { display: none; }
    .am-hero__stats { gap: 1.25rem; }
}

@media (prefers-reduced-motion: reduce) {
    * { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}

/* ==========================================================================
   15. Premium upgrades: carousels, richer cards, single product, benefits
   ========================================================================== */

/* ---- Horizontal product carousel ---- */
.am-carousel { position: relative; }
.woocommerce ul.products.am-carousel__track,
ul.products.am-carousel__track,
.am-carousel__track {
    display: flex !important;
    grid-template-columns: none !important;
    gap: var(--am-gap);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 6px 4px 1.4rem;
    margin: 0 !important;
    list-style: none;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--am-green-soft) transparent;
}
.woocommerce ul.products.am-carousel__track > li.product,
ul.products.am-carousel__track > li.product,
.am-carousel__track > li.product {
    flex: 0 0 clamp(215px, 23%, 275px) !important;
    width: auto !important;
    max-width: 275px;
    scroll-snap-align: start;
}
.am-carousel__track::-webkit-scrollbar { height: 8px; }
.am-carousel__track::-webkit-scrollbar-track { background: transparent; }
.am-carousel__track::-webkit-scrollbar-thumb { background: var(--am-green-soft); border-radius: 8px; }
.am-carousel__nav {
    position: absolute; top: 34%;
    z-index: 5;
    width: 46px; height: 46px; padding: 0;
    border-radius: 50%;
    background: #fff; color: var(--am-green-dark);
    border: 1px solid var(--am-line);
    box-shadow: var(--am-shadow);
    display: grid; place-items: center;
    cursor: pointer;
    transition: background var(--am-transition), color var(--am-transition), border-color var(--am-transition), transform var(--am-transition);
}
.am-carousel__nav:hover { background: var(--am-green); color: #fff; border-color: var(--am-green); transform: scale(1.06); }
.am-carousel__nav .am-icon { width: 22px; height: 22px; }
.am-carousel__nav--prev { left: -16px; }
.am-carousel__nav--next { right: -16px; }
.am-carousel__nav[disabled] { opacity: .35; pointer-events: none; }
@media (max-width: 860px) { .am-carousel__nav { display: none; } }

/* ---- Richer product cards ---- */
.am-loop-cat {
    display: block;
    padding: .9rem 1rem 0;
    font-family: var(--am-font-head);
    font-size: .68rem; font-weight: 600;
    letter-spacing: .09em; text-transform: uppercase;
    color: var(--am-green-fresh);
    position: relative; z-index: 1; background: #fff;
}
.woocommerce ul.products li.product .am-loop-cat + .woocommerce-loop-product__title {
    padding-top: .15rem !important;
}
/* keep text panel opaque so the zooming image never bleeds over it */
.woocommerce ul.products li.product .woocommerce-loop-product__title,
.woocommerce ul.products li.product .price,
.woocommerce ul.products li.product .star-rating {
    position: relative; z-index: 1; background: #fff;
}
/* image zoom on hover */
.woocommerce ul.products li.product a img { transition: transform .45s cubic-bezier(.2,.7,.2,1); }
.woocommerce ul.products li.product:hover a img { transform: scale(1.06); }
.woocommerce ul.products li.product { box-shadow: var(--am-shadow); }
.woocommerce ul.products li.product:hover { box-shadow: var(--am-shadow-lg); }
/* premium add-to-cart in loop */
.woocommerce ul.products li.product .button {
    background: var(--am-green); color: #fff;
    border: 1.5px solid var(--am-green);
}
.woocommerce ul.products li.product .button:hover {
    background: var(--am-green-dark); color: #fff; border-color: var(--am-green-dark);
}
.woocommerce ul.products li.product .added_to_cart {
    background: var(--am-green-dark); color: #fff; border-color: var(--am-green-dark);
}
.woocommerce ul.products li.product .star-rating { color: var(--am-gold); }

/* Uniform cards: grow the image/title/price link so add-to-cart aligns at the bottom */
.woocommerce ul.products li.product > a.woocommerce-LoopProduct-link {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}
.woocommerce ul.products li.product .price { margin-top: auto; padding-top: .35rem; }
/* clamp titles to 2 lines so every card lines up */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.6em;
}

/* ---- Category quick-nav grid: a touch more premium ---- */
.am-cat-card { box-shadow: var(--am-shadow); }
.am-cat-card:hover { box-shadow: var(--am-shadow-lg); }
.am-cat-card__thumb { position: relative; }
.am-cat-card__thumb::after {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(180deg, transparent 55%, rgba(20,86,58,.12));
    opacity: 0; transition: opacity var(--am-transition);
}
.am-cat-card:hover .am-cat-card__thumb::after { opacity: 1; }

/* section head "view all" chevron */
.am-section-head .am-btn .am-icon { width: 16px; height: 16px; margin-left: -.15rem; }

/* ---- Single product: premium presentation ---- */
.woocommerce div.product .woocommerce-product-gallery__wrapper { border-radius: var(--am-radius); overflow: hidden; }
.woocommerce div.product .woocommerce-product-gallery img { border-radius: var(--am-radius); }
.woocommerce div.product .flex-control-thumbs { margin-top: .8rem; display: flex; gap: .6rem; padding: 0; }
.woocommerce div.product .flex-control-thumbs li { width: 74px !important; }
.woocommerce div.product .flex-control-thumbs img { border-radius: 10px; border: 2px solid transparent; opacity: .7; transition: opacity var(--am-transition), border-color var(--am-transition); }
.woocommerce div.product .flex-control-thumbs img:hover,
.woocommerce div.product .flex-control-thumbs img.flex-active { opacity: 1; border-color: var(--am-green); }

.woocommerce div.product .entry-summary {
    background: #fff;
    border: 1px solid var(--am-line);
    border-radius: var(--am-radius);
    padding: clamp(1.4rem, 3vw, 2rem);
    box-shadow: var(--am-shadow);
}
.woocommerce div.product .product_title { letter-spacing: -0.02em; }
.woocommerce div.product .woocommerce-product-rating { display: flex; align-items: center; gap: .5rem; }
.woocommerce div.product .woocommerce-product-rating .star-rating { color: var(--am-gold); }
.woocommerce div.product p.price,
.woocommerce div.product span.price { display: block; margin: .25rem 0 1rem; }
.woocommerce div.product p.price del { color: var(--am-muted); font-size: 1.1rem; font-weight: 400; margin-right: .5rem; }
.woocommerce div.product p.price ins { text-decoration: none; }
.woocommerce div.product .woocommerce-product-details__short-description { color: var(--am-muted); padding-top: 1rem; border-top: 1px solid var(--am-line); }
.woocommerce div.product form.cart { margin: 1.5rem 0 0; align-items: stretch; }
.woocommerce div.product form.cart .quantity { display: flex; }
.woocommerce div.product form.cart .quantity input.qty {
    height: 100%; min-height: 52px; width: 88px; font-family: var(--am-font-head); font-weight: 600;
    border-radius: 999px;
}
.woocommerce div.product form.cart .single_add_to_cart_button {
    flex: 1; min-height: 52px; font-size: 1rem;
    background: var(--am-gold); border-color: var(--am-gold); color: #fff;
}
.woocommerce div.product form.cart .single_add_to_cart_button:hover {
    background: var(--am-gold-dark); border-color: var(--am-gold-dark);
}
/* reassurance badges under add-to-cart */
.am-single-trust {
    list-style: none; margin: 1.5rem 0 0; padding: 1.25rem 0 0;
    border-top: 1px solid var(--am-line);
    display: grid; gap: .75rem;
}
.am-single-trust li { display: flex; align-items: center; gap: .65rem; font-size: .92rem; color: var(--am-ink); }
.am-single-trust .am-icon { width: 22px; height: 22px; color: var(--am-green); }
.woocommerce div.product .product_meta { font-size: .88rem; }
.woocommerce div.product .product_meta > span { display: block; padding: .2rem 0; }

/* ---- Benefits band ---- */
.am-benefits { background: var(--am-green-dark); color: #fff; padding: clamp(2.25rem, 5vw, 3.25rem) 0; }
.am-benefits__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.am-benefit { display: flex; gap: .95rem; align-items: center; }
.am-benefit__ic { width: 54px; height: 54px; border-radius: 15px; background: rgba(255,255,255,.09); display: grid; place-items: center; flex-shrink: 0; }
.am-benefit__ic .am-icon { width: 26px; height: 26px; color: var(--am-gold); }
.am-benefit strong { display: block; font-family: var(--am-font-head); font-size: 1.02rem; }
.am-benefit span { font-size: .82rem; color: #b7cfc0; }

@media (max-width: 980px) { .am-benefits__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .am-benefits__grid { grid-template-columns: 1fr; } }

/* ==========================================================================
   16. Cart & Checkout (block) readability tidy-ups
   ========================================================================== */
/* keep product names breaking only at spaces, never mid-word */
.wc-block-components-order-summary-item__description,
.wc-block-components-order-summary-item__description .wc-block-components-product-name {
    word-break: normal;
    overflow-wrap: break-word;
    hyphens: none;
}
/* keep money amounts on a single line */
.wc-block-components-formatted-money-amount,
.wc-block-formatted-money-amount,
.woocommerce-Price-amount.amount { white-space: nowrap; }
/* neaten the little order-summary product thumbnail */
.wc-block-components-order-summary-item__image img { border-radius: 8px; }
/* give the order-summary panel a bit more breathing room */
.wc-block-components-sidebar .wc-block-components-order-summary-item { gap: .75rem; }

/* Cart / Checkout / Account pages: use the full content width, not the 72ch reading width */
.woocommerce-cart .entry-content,
.woocommerce-checkout .entry-content,
.woocommerce-account .entry-content { max-width: none; }
.woocommerce-cart .am-layout,
.woocommerce-checkout .am-layout,
.woocommerce-account .am-layout { max-width: none; }
