/* ====================================================================
   Organic Global Trade — app.css
   Design tokens: deep field green + grain gold on warm paper.
   Display: Bricolage Grotesque · Body: Inter
   ==================================================================== */

:root {
    --field:      #14532d;   /* deep agricultural green (primary)   */
    --field-700:  #0f3d22;   /* darker green                        */
    --leaf:       #1f9d55;   /* fresh leaf (CTA / accent)           */
    --leaf-600:   #198347;
    --grain:      #d8a531;   /* grain / wheat gold (secondary)      */
    --grain-soft: #f3e3b8;
    --ink:        #1d2419;   /* near-black soil text                */
    --ink-soft:   #51604a;   /* muted body                          */
    --paper:      #faf8f2;   /* warm paper background               */
    --paper-2:    #f1efe6;   /* soft section bg                     */
    --line:       #e2e6da;   /* hairline borders                    */
    --white:      #ffffff;

    --r-sm: 10px;
    --r-md: 16px;
    --r-lg: 24px;
    --shadow: 0 18px 50px -28px rgba(20, 83, 45, .45);
    --shadow-sm: 0 8px 24px -16px rgba(20, 83, 45, .4);

    --font-display: "Bricolage Grotesque", system-ui, sans-serif;
    --font-body: "Inter", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

body {
    font-family: var(--font-body);
    color: var(--ink);
    background: var(--paper);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Stop any element from pushing the page wider than the screen (the "sideways
   slide"). overflow-x: clip is used instead of hidden so the sticky header and
   dropdown menus keep working. */
html, body { max-width: 100%; overflow-x: clip; }
img { max-width: 100%; height: auto; }

h1, h2, h3, h4, .navbar-brand { font-family: var(--font-display); letter-spacing: -.02em; }
h1, h2 { font-weight: 800; line-height: 1.08; }
h3 { font-weight: 700; }

a { color: var(--field); text-decoration: none; }
a:hover { color: var(--leaf-600); }

.eyebrow {
    display: inline-block;
    font-family: var(--font-body);
    font-weight: 700;
    font-size: .78rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--leaf-600);
    margin-bottom: .9rem;
}

/* ---- Brand mark ---------------------------------------------------- */
.brand-mark {
    width: 26px; height: 26px;
    border-radius: 8px;
    background:
        radial-gradient(circle at 30% 30%, var(--grain), transparent 60%),
        linear-gradient(135deg, var(--leaf), var(--field));
    display: inline-block;
    flex: none;
    box-shadow: inset 0 0 0 2px rgba(255,255,255,.25);
}
.brand-mark--light { box-shadow: inset 0 0 0 2px rgba(255,255,255,.4); }

/* ---- Buttons ------------------------------------------------------- */
.btn { border-radius: 999px; font-weight: 600; padding: .6rem 1.4rem; }
.btn-lg { padding: .8rem 1.8rem; }
.btn-leaf { background: var(--leaf); border-color: var(--leaf); color: #fff; }
.btn-leaf:hover { background: var(--leaf-600); border-color: var(--leaf-600); color: #fff; }
.btn-ghost { background: transparent; border: 1.5px solid var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--field); color: var(--field); }
.btn-outline-dark { border: 1.5px solid var(--ink); color: var(--ink); }
.btn-outline-dark:hover { background: var(--ink); color: #fff; }

.link-arrow { font-weight: 700; color: var(--field); }
.link-arrow:hover { color: var(--leaf-600); }
.small-link { font-size: .9rem; color: var(--ink-soft); }

/* ====================================================================
   HEADER / NAV
   ==================================================================== */
.site-header__bar {
    background: var(--field-700);
    color: #e8f1e6;
    font-size: .82rem;
}
.site-header__bar .container {
    display: flex; justify-content: space-between; align-items: center;
    padding: .45rem 12px;
    gap: 1rem;
}
.site-header__bar a { color: var(--grain-soft); font-weight: 600; }
.site-header__bar span { opacity: .92; }

.site-nav {
    background: rgba(250, 248, 242, .9);
    backdrop-filter: saturate(140%) blur(8px);
    border-bottom: 1px solid var(--line);
    position: sticky; top: 0; z-index: 1020;
    padding-top: .6rem; padding-bottom: .6rem;
}
.navbar-brand { display: flex; align-items: center; gap: .55rem; font-size: 1.25rem; font-weight: 800; color: var(--ink); }
.brand-text strong { color: var(--leaf-600); }
.site-nav .nav-link { font-weight: 600; color: var(--ink-soft); padding: .4rem .6rem; }
.site-nav .nav-link:hover { color: var(--field); }
/* When the top bar is expanded, let the action buttons wrap to a second row
   rather than spilling past the right edge (happens most when signed in). */
.site-nav .navbar-collapse { flex-wrap: wrap; row-gap: .4rem; column-gap: .3rem; }
.site-nav__actions { flex-wrap: wrap; }

@media (max-width: 1199.98px) {
    .site-nav__actions { padding-top: .6rem; }
}

/* ====================================================================
   FLASH
   ==================================================================== */
.flash-wrap { margin-top: 1rem; }

/* ====================================================================
   HERO
   ==================================================================== */
.hero {
    background:
        radial-gradient(1100px 480px at 88% -10%, rgba(216,165,49,.16), transparent 60%),
        radial-gradient(900px 420px at -5% 110%, rgba(31,157,85,.14), transparent 55%),
        var(--paper);
    padding: clamp(3rem, 6vw, 5.5rem) 0;
    overflow: hidden;
}
.hero__title { font-size: clamp(2.1rem, 4.6vw, 3.5rem); margin-bottom: 1.1rem; }
.hero__lede { font-size: 1.18rem; color: var(--ink-soft); max-width: 34rem; margin-bottom: 1.8rem; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-bottom: 2.4rem; }

.hero__stats { display: flex; gap: 2.2rem; flex-wrap: wrap; margin: 0; }
.hero__stats dt { font-family: var(--font-display); font-size: 2rem; font-weight: 800; color: var(--field); line-height: 1; }
.hero__stats dd { margin: .3rem 0 0; font-size: .9rem; color: var(--ink-soft); max-width: 9rem; }

/* Signature: the trade corridor */
.corridor {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow);
    padding: 2rem 1.6rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: .4rem;
    position: relative;
}
.corridor__node {
    display: flex; flex-direction: column; align-items: center; text-align: center;
    padding: 1.3rem;
    border-radius: var(--r-md);
}
.corridor__node--farm { background: linear-gradient(160deg, #eaf6ec, #f4fbf3); }
.corridor__node--world { background: linear-gradient(160deg, #fdf6e3, #fffaf0); }
.corridor__icon { font-size: 2.2rem; line-height: 1; margin-bottom: .4rem; }
.corridor__node strong { font-family: var(--font-display); font-size: 1.15rem; }
.corridor__node small { color: var(--ink-soft); }

.corridor__track {
    position: relative;
    height: 64px;
    display: flex; align-items: center; justify-content: center;
}
.corridor__track::before {
    content: ""; position: absolute; left: 8%; right: 8%; top: 50%;
    height: 3px; border-radius: 3px;
    background: repeating-linear-gradient(90deg, var(--leaf) 0 10px, transparent 10px 18px);
    opacity: .55;
}
.corridor__dot {
    position: absolute; left: 8%; top: 50%; width: 14px; height: 14px;
    margin-top: -7px; border-radius: 50%;
    background: var(--grain); box-shadow: 0 0 0 4px rgba(216,165,49,.25);
    animation: corridor-move 4.5s ease-in-out infinite;
}
.corridor__label {
    position: relative; z-index: 1;
    background: var(--white); padding: .2rem .7rem;
    font-size: .76rem; font-weight: 700; letter-spacing: .04em;
    color: var(--field); text-transform: uppercase;
    border: 1px solid var(--line); border-radius: 999px;
}
@keyframes corridor-move {
    0%, 100% { left: 8%; }
    50% { left: calc(92% - 14px); }
}
@media (prefers-reduced-motion: reduce) {
    .corridor__dot { animation: none; }
}

/* ====================================================================
   SECTIONS
   ==================================================================== */
.section { padding: clamp(3rem, 6vw, 5rem) 0; }
.section--soft { background: var(--paper-2); }
.section--dark { background: var(--field-700); color: #eaf2e8; }

.section-head { max-width: 46rem; margin: 0 auto 2.6rem; text-align: center; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
.section-head p { color: var(--ink-soft); font-size: 1.06rem; margin-top: .6rem; }
.section-head--left { margin-left: 0; text-align: left; }
.section-head--invert h2 { color: #fff; }
.section-head--invert .eyebrow { color: var(--grain); }

/* ---- Two business models ------------------------------------------ */
.model-card {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    padding: 2.2rem;
    height: 100%;
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}
.model-card::after {
    content: ""; position: absolute; inset: 0 0 auto 0; height: 5px;
}
.model-card--b2b::after { background: linear-gradient(90deg, var(--field), var(--leaf)); }
.model-card--b2c::after { background: linear-gradient(90deg, var(--grain), #e9c45f); }
.model-card__tag {
    font-size: .76rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
    color: var(--leaf-600);
}
.model-card h2 { font-size: 1.55rem; margin: .5rem 0 .7rem; }
.model-card p { color: var(--ink-soft); }
.model-card__list { list-style: none; padding: 0; margin: 1rem 0 1.3rem; }
.model-card__list li { padding: .35rem 0 .35rem 1.6rem; position: relative; }
.model-card__list li::before {
    content: "✓"; position: absolute; left: 0; color: var(--leaf-600); font-weight: 800;
}

/* ---- Category cards ----------------------------------------------- */
.category-card {
    display: block; height: 100%;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    padding: 1.6rem;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
    color: inherit;
}
.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
    border-color: var(--leaf);
    color: inherit;
}
.category-card__icon {
    font-size: 1.9rem; display: inline-grid; place-items: center;
    width: 54px; height: 54px; border-radius: 14px;
    background: var(--paper-2); margin-bottom: 1rem;
}
.category-card h3 { font-size: 1.18rem; margin-bottom: .4rem; }
.category-card p { color: var(--ink-soft); font-size: .94rem; margin: 0; }

/* ---- Local store strip -------------------------------------------- */
.store-strip { display: flex; flex-wrap: wrap; gap: 1rem; }
.store-pill {
    flex: 1 1 220px;
    background: var(--white);
    border: 1px solid var(--line);
    border-left: 4px solid var(--grain);
    border-radius: var(--r-sm);
    padding: 1.1rem 1.3rem;
}
.store-pill strong { display: block; font-family: var(--font-display); font-size: 1.05rem; }
.store-pill span { color: var(--ink-soft); font-size: .9rem; }

/* ---- Steps -------------------------------------------------------- */
.steps {
    list-style: none; padding: 0; margin: 0;
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem;
    counter-reset: step;
}
.step {
    border-top: 2px solid rgba(216,165,49,.5);
    padding-top: 1.2rem;
}
.step__num {
    font-family: var(--font-display); font-weight: 800; font-size: 1.1rem;
    color: var(--grain);
}
.step h3 { color: #fff; font-size: 1.15rem; margin: .6rem 0 .4rem; }
.step p { color: #cdddc9; font-size: .94rem; margin: 0; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

/* ---- Certifications ----------------------------------------------- */
.cert-grid { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: center; }
.cert-chip {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: .55rem 1.2rem;
    font-weight: 600; font-size: .92rem;
    color: var(--field);
}
.cert-detail {
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: 1.5rem; height: 100%;
}
.cert-detail h3 { font-size: 1.15rem; color: var(--field); }
.cert-detail p { color: var(--ink-soft); margin: .4rem 0 0; font-size: .94rem; }

/* ---- CTA ----------------------------------------------------------- */
.cta { background: var(--paper); padding: 0 0 clamp(3rem,6vw,5rem); }
.cta__inner {
    background: linear-gradient(130deg, var(--field), var(--field-700));
    color: #fff; border-radius: var(--r-lg);
    padding: clamp(2rem, 4vw, 3.2rem);
    display: flex; align-items: center; justify-content: space-between;
    gap: 2rem; flex-wrap: wrap;
    box-shadow: var(--shadow);
}
.cta__inner h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.2rem); }
.cta__inner p { color: #d6e7d4; margin: .5rem 0 0; }
.cta__actions { display: flex; gap: .8rem; flex-wrap: wrap; }
.btn-outline-light { border: 1.5px solid rgba(255,255,255,.6); color: #fff; }
.btn-outline-light:hover { background: #fff; color: var(--field); }

/* ====================================================================
   GENERIC PAGE HERO + PROSE
   ==================================================================== */
.page-hero {
    background: var(--paper-2);
    border-bottom: 1px solid var(--line);
    padding: clamp(2.4rem, 5vw, 4rem) 0;
}
.page-hero h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
.page-hero__lede { color: var(--ink-soft); font-size: 1.1rem; max-width: 42rem; margin-top: .8rem; }
.prose-h2 { font-size: 1.4rem; margin: 1.6rem 0 .6rem; }
.fact-panel, .form-panel, .contact-info {
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: 1.8rem;
}
.fact-list { list-style: none; padding: 0; margin: .6rem 0 1.2rem; }
.fact-list li { padding: .55rem 0; border-bottom: 1px solid var(--line); }
.fact-list li:last-child { border-bottom: 0; }
.contact-info__label {
    display: block; font-size: .76rem; text-transform: uppercase;
    letter-spacing: .08em; color: var(--ink-soft); font-weight: 700;
}
.contact-info p { margin-bottom: 1rem; }

/* ====================================================================
   FORMS
   ==================================================================== */
.form-label { font-weight: 600; font-size: .92rem; }
.form-control, .form-select {
    border-radius: var(--r-sm); border-color: var(--line); padding: .65rem .85rem;
}
.form-control:focus, .form-select:focus {
    border-color: var(--leaf); box-shadow: 0 0 0 .2rem rgba(31,157,85,.15);
}

/* ====================================================================
   AUTH LAYOUT
   ==================================================================== */
.auth-body { background: var(--paper-2); }
.auth-shell {
    display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh;
}
.auth-aside {
    background: linear-gradient(150deg, var(--field), var(--field-700));
    color: #fff; padding: clamp(2rem, 5vw, 4rem);
    display: flex; flex-direction: column; justify-content: center;
}
.auth-brand { display: flex; align-items: center; gap: .55rem; color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; margin-bottom: 2.5rem; }
.auth-brand:hover { color: #fff; }
.auth-aside__title { color: #fff; font-size: clamp(1.6rem, 3vw, 2.3rem); }
.auth-aside__text { color: #d6e7d4; margin: 1rem 0 1.6rem; max-width: 26rem; }
.auth-aside__list { list-style: none; padding: 0; }
.auth-aside__list li { padding: .45rem 0 .45rem 1.7rem; position: relative; color: #eaf2e8; }
.auth-aside__list li::before { content: "🌿"; position: absolute; left: 0; }

.auth-main {
    display: flex; flex-direction: column; justify-content: center;
    padding: clamp(1.5rem, 4vw, 3rem);
}
.auth-card {
    width: 100%; max-width: 30rem; margin: 0 auto;
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-lg); padding: 2.2rem;
    box-shadow: var(--shadow-sm);
}
.auth-card__title { font-size: 1.7rem; }
.auth-card__sub { color: var(--ink-soft); margin-bottom: 1.5rem; }
.auth-card__alt { text-align: center; margin: 1.3rem 0 0; color: var(--ink-soft); }
.auth-card__badge {
    display: inline-block; background: var(--grain-soft); color: #7a5a09;
    font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
    padding: .25rem .7rem; border-radius: 999px; margin-bottom: .8rem;
}
@media (max-width: 860px) {
    .auth-shell { grid-template-columns: 1fr; }
    .auth-aside { display: none; }
}

/* ====================================================================
   DASHBOARD (member)
   ==================================================================== */
.dash-welcome {
    display: flex; align-items: flex-start; justify-content: space-between;
    gap: 1rem; flex-wrap: wrap;
    padding-bottom: 1.2rem; border-bottom: 1px solid var(--line);
}
.dash-card {
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: 1.5rem; height: 100%;
}
.dash-card h3 { font-size: 1.15rem; }
.dash-card--soon { background: var(--paper-2); }
.dash-card--soon p { color: var(--ink-soft); }
.dash-list { list-style: none; padding: 0; margin: 0; }
.dash-list li { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem 0; border-bottom: 1px solid var(--line); }
.dash-list li:last-child { border-bottom: 0; }
.dash-list span { color: var(--ink-soft); }
.badge-soon {
    display: inline-block; margin-top: .6rem;
    background: var(--grain-soft); color: #7a5a09;
    font-size: .74rem; font-weight: 700; padding: .25rem .7rem; border-radius: 999px;
}

/* ====================================================================
   ADMIN LAYOUT
   ==================================================================== */
.admin-body { background: var(--paper-2); }
.admin-shell { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }
.admin-sidebar {
    background: var(--field-700); color: #dceadb;
    display: flex; flex-direction: column; padding: 1.4rem 1rem;
}
.admin-brand { display: flex; align-items: center; gap: .5rem; color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; padding: .3rem .5rem 1.4rem; }
.admin-brand:hover { color: #fff; }
.admin-nav { display: flex; flex-direction: column; gap: .15rem; flex: 1; }
.admin-nav a, .admin-nav__soon {
    display: flex; justify-content: space-between; align-items: center;
    padding: .6rem .75rem; border-radius: var(--r-sm);
    color: #cfe0ce; font-weight: 600; font-size: .94rem;
}
.admin-nav a:hover, .admin-nav a.active { background: rgba(255,255,255,.12); color: #fff; }
.admin-nav__soon { color: #88a386; cursor: default; }
.admin-nav__soon em { font-style: normal; font-size: .68rem; background: rgba(255,255,255,.08); padding: .1rem .45rem; border-radius: 999px; }
.admin-logout { margin-top: 1rem; }

.admin-content { display: flex; flex-direction: column; }
.admin-topbar {
    background: var(--white); border-bottom: 1px solid var(--line);
    padding: .9rem 1.5rem; display: flex; justify-content: space-between; align-items: center;
    font-weight: 600; color: var(--ink-soft);
}
.admin-inner { padding: 1.8rem 1.5rem; }
.page-head { margin-bottom: 1.6rem; }
.page-head h1 { font-size: 1.7rem; }
.stat-card {
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: 1.3rem; height: 100%;
    display: flex; flex-direction: column; gap: .3rem;
}
.stat-card__label { font-size: .82rem; color: var(--ink-soft); font-weight: 600; }
.stat-card__value { font-family: var(--font-display); font-size: 2rem; font-weight: 800; color: var(--field); line-height: 1; }
.stat-card__hint { font-size: .74rem; color: var(--grain); font-weight: 700; }
.stat-card--muted .stat-card__value { color: var(--line); }
.panel {
    background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: 1.5rem;
}
.panel__title { font-size: 1.2rem; margin-bottom: 1rem; }

@media (max-width: 768px) {
    .admin-shell { grid-template-columns: 1fr; }
    .admin-sidebar { flex-direction: row; flex-wrap: wrap; align-items: center; }
    .admin-nav { flex-direction: row; flex-wrap: wrap; }
    .admin-nav__soon { display: none; }
}

/* ====================================================================
   FOOTER
   ==================================================================== */
.site-footer { background: var(--ink); color: #c7d2c2; padding: 3.2rem 0 1.6rem; }
.footer-brand { display: flex; align-items: center; gap: .5rem; color: #fff; font-family: var(--font-display); font-weight: 800; font-size: 1.25rem; }
.footer-brand:hover { color: #fff; }
.footer-tagline { color: #9fb09b; margin-top: .8rem; font-size: .94rem; max-width: 22rem; }
.site-footer h4 { color: #fff; font-size: .82rem; letter-spacing: .08em; text-transform: uppercase; margin-bottom: .9rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer ul li { padding: .25rem 0; }
.site-footer ul a { color: #b9c7b4; font-size: .94rem; }
.site-footer ul a:hover { color: var(--grain); }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,.1);
    margin-top: 2.4rem; padding-top: 1.2rem;
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem;
    font-size: .85rem; color: #8a9886;
}

/* ====================================================================
   ERROR PAGE
   ==================================================================== */
.error-page__code {
    font-family: var(--font-display); font-weight: 800;
    font-size: clamp(4rem, 12vw, 7rem); color: var(--leaf); line-height: 1;
    display: block; margin-bottom: .5rem;
}

/* Accessibility: visible focus */
a:focus-visible, .btn:focus-visible, .form-control:focus-visible,
.form-select:focus-visible, button:focus-visible {
    outline: 3px solid var(--grain); outline-offset: 2px;
}

/* ====================================================================
   BRAND LOGO IMAGES + HERO ILLUSTRATION
   ==================================================================== */
.navbar-brand { gap: .6rem; }
.brand-logo  { height: 42px; width: auto; display: block; }
.footer-logo { width: 230px; max-width: 80%; height: auto; display: block; }
.auth-brand, .admin-brand { gap: .6rem; }
.auth-logo   { height: 40px; width: auto; display: block; }
.admin-logo  { height: 34px; width: auto; display: block; }

.hero__art { position: relative; }
.hero__img {
    width: 100%; height: auto; display: block;
    border-radius: var(--r-lg);
    filter: drop-shadow(0 26px 50px rgba(20, 83, 45, .22));
}

/* =====================================================================
   PHASE 2 — Catalogue, product cards, detail, filters, admin tables
   ===================================================================== */

/* Breadcrumbs */
.crumbs { font-size: .85rem; color: var(--ink-soft); margin-bottom: .75rem; }
.crumbs a { color: var(--ink-soft); }
.crumbs a:hover { color: var(--leaf-600); }
.crumbs span { opacity: .5; margin: 0 .35rem; }

/* Catalogue header band */
.catalog-hero { background: var(--paper-2); border-bottom: 1px solid var(--line); padding: 2.2rem 0 1.8rem; }
.catalog-hero h1 { margin: .2rem 0 .4rem; }

/* Empty state */
.empty-state {
    text-align: center; padding: 3rem 1.5rem; background: var(--white);
    border: 1px dashed var(--line); border-radius: var(--r-md);
}
.empty-state h3 { margin-bottom: .5rem; }

/* Product grid + cards */
.product-grid {
    display: grid; gap: 1.25rem;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.product-card {
    display: flex; flex-direction: column; background: var(--white);
    border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden;
    color: inherit; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-sm); border-color: #cfd8c5; color: inherit; }
.product-card__media { position: relative; aspect-ratio: 4 / 3; background: var(--paper-2); }
.product-card__media img { width: 100%; height: 100%; object-fit: cover; }
.product-card__feat {
    position: absolute; top: .6rem; left: .6rem; background: var(--grain);
    color: #5b430a; font-size: .68rem; font-weight: 700; padding: .2rem .5rem; border-radius: 999px;
    text-transform: uppercase; letter-spacing: .04em;
}
.product-card__body { padding: .85rem .95rem 1rem; display: flex; flex-direction: column; flex: 1; }
.product-card__cat { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--leaf-600); font-weight: 600; }
.product-card__name { font-size: 1.02rem; margin: .25rem 0 .35rem; line-height: 1.25; }
.product-card__desc { font-size: .85rem; color: var(--ink-soft); margin: 0 0 .75rem; flex: 1;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-card__foot { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-top: auto; }
.product-card__price { font-weight: 700; color: var(--field); }
.product-card__price small { color: var(--ink-soft); font-weight: 500; }
.product-card__tag { font-size: .7rem; color: var(--ink-soft); background: var(--paper-2); padding: .2rem .5rem; border-radius: 999px; white-space: nowrap; }

/* Filters */
.filter-panel { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1.1rem; }
.filter-block { margin-bottom: 1.1rem; }
.filter-label { display: block; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-soft); margin-bottom: .4rem; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.seg__btn { padding: .35rem .85rem; font-size: .85rem; color: var(--ink-soft); }
.seg__btn:hover { background: var(--paper-2); color: var(--field); }
.seg__btn.is-active { background: var(--field); color: #fff; }
.cat-tree { list-style: none; margin: 0; padding: 0; font-size: .9rem; }
.cat-tree a { display: block; padding: .3rem .2rem; color: var(--ink); border-radius: 6px; }
.cat-tree a:hover { color: var(--leaf-600); }
.cat-tree a.is-active { color: var(--leaf-600); font-weight: 700; }
.cat-tree ul { list-style: none; margin: 0 0 .4rem .8rem; padding: 0; border-left: 1px solid var(--line); }
.cat-tree ul a { font-size: .85rem; color: var(--ink-soft); padding: .22rem .6rem; }

/* Pagination */
.pagination-wrap { margin-top: 2rem; display: flex; justify-content: center; }
.pagination-wrap .page-link { color: var(--field); border-color: var(--line); }
.pagination-wrap .active .page-link { background: var(--field); border-color: var(--field); }

/* Product detail */
.product-detail { padding-top: 1.8rem; }
.gallery__main { background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; aspect-ratio: 1 / 1; }
.gallery__main img { width: 100%; height: 100%; object-fit: cover; }
.gallery__thumbs { display: flex; gap: .5rem; margin-top: .6rem; flex-wrap: wrap; }
.gallery__thumb { width: 64px; height: 64px; border-radius: 8px; overflow: hidden; border: 2px solid transparent; padding: 0; background: var(--paper-2); cursor: pointer; }
.gallery__thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery__thumb.is-active { border-color: var(--leaf); }
.detail-cat { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--leaf-600); font-weight: 700; }
.detail-title { margin: .3rem 0 .6rem; }
.detail-price { font-size: 1.8rem; font-weight: 800; color: var(--field); font-family: var(--font-display); }
.detail-price small { font-size: .95rem; font-weight: 500; color: var(--ink-soft); }
.detail-lede { color: var(--ink-soft); margin: .6rem 0 1rem; }
.detail-meta { list-style: none; padding: 0; margin: 1rem 0; border-top: 1px solid var(--line); }
.detail-meta li { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--line); }
.detail-meta span { color: var(--ink-soft); }
.detail-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1.2rem; }
.detail-note { font-size: .85rem; color: var(--ink-soft); margin-top: .7rem; }
.detail-desc { margin-top: 2.5rem; max-width: 820px; }
.detail-desc h2 { font-size: 1.3rem; margin-bottom: .6rem; }

/* Enquiry card */
.enquiry-card { margin-top: 2.5rem; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.6rem; max-width: 820px; }
.enquiry-card h2 { font-size: 1.3rem; margin-bottom: 1rem; }
.related { margin-top: 3rem; }
.related h2 { font-size: 1.4rem; margin-bottom: 1.1rem; }

/* Tables (supplier + admin) */
.table-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.table-card .table { margin: 0; }
.table-card thead th { background: var(--paper-2); font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-soft); border-bottom: 1px solid var(--line); }
.cell-product { display: flex; align-items: center; gap: .7rem; }
.cell-product img { width: 46px; height: 46px; border-radius: 8px; object-fit: cover; background: var(--paper-2); }
.small-link { font-size: .78rem; color: var(--leaf-600); display: inline-block; }
.status-chip { font-size: .72rem; font-weight: 700; padding: .2rem .55rem; border-radius: 999px; text-transform: uppercase; letter-spacing: .03em; }
.status-active { background: #e3f5ea; color: #176b3a; }
.status-inactive { background: #f1f0ec; color: #6b6b63; }
.status-pending { background: #fcf2dc; color: #8a6314; }
.btn-danger-soft { background: #fbeaea; color: #b3261e; border: 1px solid #f3d2d0; }
.btn-danger-soft:hover { background: #f6d8d6; color: #8f1d17; }

/* Forms */
.form-panel { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.6rem; }
.form-thumb { width: 90px; height: 90px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
.gallery-manage { display: flex; gap: .7rem; flex-wrap: wrap; }
.gallery-manage__item { position: relative; }
.gallery-manage__item img { width: 84px; height: 84px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
.gallery-manage__del { position: absolute; top: -8px; right: -8px; width: 24px; height: 24px; border-radius: 50%; border: none; background: #b3261e; color: #fff; line-height: 1; font-size: 1rem; cursor: pointer; }

/* Dashboard live cards + stat */
.dash-card--live { border-color: #cfe6d7; }
.dash-stat { font-family: var(--font-display); font-size: 2rem; font-weight: 800; color: var(--field); margin: .2rem 0 .4rem; }
.dash-stat span { font-size: .9rem; font-weight: 500; color: var(--ink-soft); }

/* Supplier enquiries */
.enquiry-list { display: grid; gap: 1rem; }
.enquiry-item { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1.1rem 1.25rem; }
.enquiry-item__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; }
.enquiry-item__product { font-weight: 700; color: var(--field); }
.enquiry-item__date { display: block; font-size: .78rem; color: var(--ink-soft); }
.enquiry-item__msg { margin: .7rem 0; color: var(--ink); }
.enquiry-item__meta { display: flex; flex-wrap: wrap; gap: 1rem; font-size: .85rem; color: var(--ink-soft); border-top: 1px solid var(--line); padding-top: .7rem; }

/* Admin category rows */
.cat-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .6rem .2rem; border-bottom: 1px solid var(--line); }
.cat-row--parent { font-size: 1rem; }
.cat-row--child { padding-left: 1.2rem; color: var(--ink-soft); }
.panel__title { font-size: 1.1rem; margin-bottom: 1rem; }

@media (max-width: 575px) {
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .8rem; }
    .detail-price { font-size: 1.5rem; }
}

/* =====================================================================
   PHASE 3 — Supplier directory & public profiles
   ===================================================================== */

/* Verified badge */
.vbadge { display: inline-flex; align-items: center; justify-content: center; background: var(--leaf); color: #fff;
    font-size: .7rem; font-weight: 700; border-radius: 999px; padding: .05rem .35rem; vertical-align: middle; }
.vbadge--lg { font-size: .8rem; padding: .15rem .55rem; margin-left: .4rem; }

/* Supplier grid + cards */
.supplier-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.supplier-card { display: flex; gap: 1rem; padding: 1.1rem; background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); color: inherit; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.supplier-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-sm); border-color: #cfd8c5; color: inherit; }
.supplier-card__logo { flex: 0 0 60px; width: 60px; height: 60px; border-radius: 12px; overflow: hidden; background: var(--paper-2);
    display: flex; align-items: center; justify-content: center; border: 1px solid var(--line); }
.supplier-card__logo img { width: 100%; height: 100%; object-fit: cover; }
.supplier-card__initial { font-family: var(--font-display); font-size: 1.5rem; font-weight: 700; color: var(--field); }
.supplier-card__body { flex: 1; min-width: 0; }
.supplier-card__name { font-size: 1.05rem; margin: 0 0 .15rem; line-height: 1.25; }
.supplier-card__role { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--leaf-600); font-weight: 600; }
.supplier-card__tag { font-size: .85rem; color: var(--ink-soft); margin: .35rem 0 .5rem;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.supplier-card__foot { display: flex; flex-wrap: wrap; gap: .8rem; font-size: .78rem; color: var(--ink-soft); }

/* Profile header */
.profile-head { position: relative; background: var(--white); border-bottom: 1px solid var(--line); }
.profile-banner { height: 200px; background: linear-gradient(120deg, var(--field), var(--leaf)); background-size: cover; background-position: center; }
.profile-head__inner { display: flex; gap: 1.5rem; align-items: flex-end; margin-top: -55px; padding-bottom: 1.5rem; position: relative; }
.profile-logo { flex: 0 0 110px; width: 110px; height: 110px; border-radius: 20px; background: var(--white); border: 1px solid var(--line);
    box-shadow: var(--shadow-sm); overflow: hidden; display: flex; align-items: center; justify-content: center; }
.profile-logo img { width: 100%; height: 100%; object-fit: cover; }
.profile-logo__initial { font-family: var(--font-display); font-size: 3rem; font-weight: 700; color: var(--field); }
.profile-headline { padding-bottom: .35rem; }
.profile-headline h1 { margin: 0 0 .3rem; font-size: 1.9rem; }
.profile-meta-line { display: flex; flex-wrap: wrap; gap: 1rem; color: var(--ink-soft); font-size: .9rem; }
.profile-meta-line span:first-child { color: var(--leaf-600); font-weight: 600; }
.profile-tagline { margin: .6rem 0 0; color: var(--ink); font-size: 1.05rem; }

.profile-h2 { font-size: 1.35rem; margin-bottom: .8rem; }
.profile-about { color: var(--ink-soft); line-height: 1.7; max-width: 70ch; }
.profile-side { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1.4rem; position: sticky; top: 1.5rem; }
.profile-side h3 { font-size: 1rem; margin-bottom: .8rem; }
.profile-facts { list-style: none; padding: 0; margin: 0; }
.profile-facts li { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem 0; border-bottom: 1px solid var(--line); font-size: .9rem; }
.profile-facts li:last-child { border-bottom: 0; }
.profile-facts span { color: var(--ink-soft); }
.profile-facts strong { text-align: right; }
.cert-tags { display: flex; flex-wrap: wrap; gap: .4rem; }
.cert-tag { background: var(--grain-soft); color: #6b520f; font-size: .78rem; font-weight: 600; padding: .25rem .6rem; border-radius: 999px; }
.profile-contact { list-style: none; padding: 0; margin: 0; font-size: .92rem; }
.profile-contact li { padding: .3rem 0; }
.verify-banner { background: #e3f5ea; color: #176b3a; border: 1px solid #b9e3c8; border-radius: var(--r-sm); padding: .7rem 1rem; font-size: .9rem; }

@media (max-width: 575px) {
    .profile-head__inner { flex-direction: column; align-items: flex-start; gap: .8rem; margin-top: -45px; }
    .profile-headline h1 { font-size: 1.5rem; }
    .supplier-grid { grid-template-columns: 1fr; }
}

/* =====================================================================
   PHASE 4 — Buy leads (RFQs) & messaging
   ===================================================================== */

/* Nav badge + messages button */
.nav-badge { display: inline-flex; min-width: 18px; height: 18px; padding: 0 5px; align-items: center; justify-content: center;
    background: var(--grain); color: #5b430a; font-size: .7rem; font-weight: 700; border-radius: 999px; }
.btn-msg { position: relative; }

/* RFQ board */
.rfq-filter { display: flex; gap: .6rem; flex-wrap: wrap; }
.rfq-filter .form-control, .rfq-filter .form-select { max-width: 280px; }
.rfq-list { display: grid; gap: 1rem; }
.rfq-card { display: flex; gap: 1.5rem; justify-content: space-between; background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: 1.2rem 1.4rem; flex-wrap: wrap; }
.rfq-card__main { flex: 1; min-width: 240px; }
.rfq-card__title { font-family: var(--font-display); font-size: 1.15rem; font-weight: 700; color: var(--field); display: inline-block; margin-bottom: .3rem; }
.rfq-card__title:hover { color: var(--leaf-600); }
.rfq-card__desc { color: var(--ink-soft); font-size: .92rem; margin: 0 0 .6rem; }
.rfq-card__meta { display: flex; flex-wrap: wrap; gap: .9rem; font-size: .82rem; color: var(--ink-soft); }
.rfq-card__side { display: flex; flex-direction: column; align-items: flex-end; gap: .5rem; justify-content: center; }
.rfq-card__deadline { font-size: .8rem; color: var(--ink-soft); }
.rfq-card__quotes { font-size: .8rem; font-weight: 600; color: var(--field); }
.rfq-detail { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1.6rem; }
.rfq-quote-price { color: var(--field); font-family: var(--font-display); font-size: 1.2rem; }

/* Messages inbox */
.msg-inbox { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; background: var(--white); }
.msg-row { display: flex; align-items: center; gap: .9rem; padding: .9rem 1.1rem; border-bottom: 1px solid var(--line); color: inherit; }
.msg-row:last-child { border-bottom: 0; }
.msg-row:hover { background: var(--paper-2); color: inherit; }
.msg-row.is-unread { background: #f1f8f3; }
.msg-row__avatar { flex: 0 0 42px; width: 42px; height: 42px; border-radius: 50%; background: var(--field); color: #fff;
    display: flex; align-items: center; justify-content: center; font-weight: 700; font-family: var(--font-display); }
.msg-row__body { flex: 1; min-width: 0; }
.msg-row__top { display: flex; justify-content: space-between; gap: .5rem; }
.msg-row__time { font-size: .78rem; color: var(--ink-soft); }
.msg-row__ctx { font-size: .76rem; color: var(--leaf-600); font-weight: 600; }
.msg-row__snippet { margin: .15rem 0 0; font-size: .88rem; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.msg-row.is-unread .msg-row__snippet { color: var(--ink); font-weight: 500; }
.msg-row__badge { flex: 0 0 auto; background: var(--leaf); color: #fff; font-size: .72rem; font-weight: 700; border-radius: 999px; min-width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; padding: 0 6px; }

/* Thread */
.thread-head { display: flex; align-items: center; gap: .9rem; padding-bottom: 1rem; border-bottom: 1px solid var(--line); margin-bottom: 1.2rem; }
.thread-head__name { font-size: 1.3rem; margin: 0; }
.thread { display: flex; flex-direction: column; gap: .6rem; padding: .5rem 0 1.2rem; }
.bubble-row { display: flex; }
.bubble-row--me { justify-content: flex-end; }
.bubble { max-width: 75%; background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: .65rem .9rem; }
.bubble p { margin: 0; }
.bubble__time { display: block; font-size: .7rem; color: var(--ink-soft); margin-top: .25rem; }
.bubble-row--me .bubble { background: var(--field); border-color: var(--field); color: #fff; }
.bubble-row--me .bubble__time { color: rgba(255,255,255,.7); }
.thread-reply { position: sticky; bottom: 0; background: var(--paper); padding-top: .5rem; }
.msg-supplier summary { list-style: none; cursor: pointer; }
.msg-supplier summary::-webkit-details-marker { display: none; }

@media (max-width: 575px) {
    .rfq-card__side { align-items: flex-start; }
    .bubble { max-width: 88%; }
}

/* =====================================================================
   PHASE 5 — Store: cart, checkout, orders, payment
   ===================================================================== */

/* Add-to-cart on product page */
.add-cart { display: flex; gap: .6rem; align-items: center; }
.add-cart__qty { width: 90px; }

/* Cart table */
.cart-table td, .cart-table th { vertical-align: middle; }
.cart-qty { margin: 0; }
.cart-qty input { width: 78px; }

/* Order summary card */
.summary-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1.4rem; }
.summary-card h3 { font-size: 1.1rem; margin-bottom: 1rem; }
.summary-items { list-style: none; padding: 0; margin: 0 0 1rem; border-bottom: 1px solid var(--line); }
.summary-items li { display: flex; justify-content: space-between; gap: 1rem; padding: .35rem 0; font-size: .9rem; }
.summary-items__name { color: var(--ink); }
.summary-items__name em { color: var(--ink-soft); font-style: normal; }
.summary-list { list-style: none; padding: 0; margin: 0 0 1.1rem; }
.summary-list li { display: flex; justify-content: space-between; padding: .4rem 0; color: var(--ink-soft); }
.summary-list .summary-total { border-top: 1px solid var(--line); margin-top: .3rem; padding-top: .7rem; color: var(--ink); font-size: 1.15rem; }
.summary-list .summary-total strong { color: var(--field); font-family: var(--font-display); }

/* Payment options */
.pay-options { display: grid; gap: .7rem; }
.pay-option { display: flex; align-items: center; gap: .8rem; border: 1px solid var(--line); border-radius: var(--r-sm); padding: .9rem 1.1rem; cursor: pointer; margin: 0; }
.pay-option:hover { border-color: #cfd8c5; }
.pay-option input { width: 18px; height: 18px; }
.pay-option span { display: flex; flex-direction: column; }
.pay-option small { color: var(--ink-soft); }

/* Order detail */
.order-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }

/* Razorpay pay page */
.pay-box { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 2.4rem; }
.pay-amount { font-family: var(--font-display); font-size: 2.2rem; font-weight: 800; color: var(--field); margin: .5rem 0 1rem; }

/* =====================================================================
   PHASE 6 — Fulfilment: tracker, timeline, tracking, notifications
   ===================================================================== */

/* Progress tracker */
.track-steps { display: flex; gap: .4rem; margin: 1.2rem 0; }
.track-step { flex: 1; text-align: center; position: relative; }
.track-step__dot { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%;
    background: var(--paper-2); border: 2px solid var(--line); color: var(--ink-soft); font-weight: 700; font-size: .85rem; }
.track-step__label { display: block; font-size: .72rem; color: var(--ink-soft); margin-top: .35rem; }
.track-step::after { content: ''; position: absolute; top: 16px; left: 50%; width: 100%; height: 2px; background: var(--line); z-index: -1; }
.track-step:last-child::after { display: none; }
.track-step.is-done .track-step__dot { background: var(--leaf); border-color: var(--leaf); color: #fff; }
.track-step.is-done .track-step__label { color: var(--field); }
.track-step.is-current .track-step__dot { box-shadow: 0 0 0 4px rgba(31,157,85,.18); }

/* Tracking card */
.track-card { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; background: var(--white); border: 1px solid var(--line);
    border-radius: var(--r-md); padding: .9rem 1.2rem; margin-bottom: .5rem; }
.track-card span { font-size: .9rem; color: var(--ink-soft); }

/* Timeline */
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { position: relative; padding: 0 0 .9rem 1.1rem; border-left: 2px solid var(--line); }
.timeline li:last-child { border-left-color: transparent; padding-bottom: 0; }
.timeline li::before { content: ''; position: absolute; left: -6px; top: 3px; width: 10px; height: 10px; border-radius: 50%; background: var(--leaf); }
.timeline__status { font-weight: 700; color: var(--field); }
.timeline__note { display: block; font-size: .88rem; color: var(--ink); }
.timeline__time { display: block; font-size: .76rem; color: var(--ink-soft); }

/* Supplier order group head */
.supplier-order__head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .8rem 1rem; border-bottom: 1px solid var(--line); flex-wrap: wrap; }

/* Notifications */
.notif-list { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; background: var(--white); }
.notif-link { color: inherit; }
.notif-item { padding: .9rem 1.1rem; border-bottom: 1px solid var(--line); }
.notif-link:last-child .notif-item, .notif-list > .notif-item:last-child { border-bottom: 0; }
.notif-item.is-unread { background: #f1f8f3; }
.notif-item__body p { margin: .2rem 0; font-size: .9rem; color: var(--ink-soft); }
.notif-item__time { font-size: .76rem; color: var(--ink-soft); }

/* =====================================================================
   PHASE 7 — Membership plans & badges
   ===================================================================== */

/* Plan badges (also used on profiles & cards) */
.plan-badge { display: inline-block; font-size: .68rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase;
    padding: .12rem .45rem; border-radius: 999px; vertical-align: middle; margin-left: .35rem; color: #fff; background: var(--ink-soft); }
.plan-badge--silver { background: linear-gradient(135deg, #b8bcc4, #8b9099); color: #fff; }
.plan-badge--gold { background: linear-gradient(135deg, #e7c14d, #c79a1e); color: #4a3a05; }

/* Plan grid */
.plan-grid { display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); align-items: stretch; }
.plan-card { position: relative; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.8rem 1.5rem; display: flex; flex-direction: column; }
.plan-card--silver { border-color: #c9ccd2; }
.plan-card--gold { border-color: #e7c14d; box-shadow: 0 8px 30px rgba(199,154,30,.12); }
.plan-card.is-current { outline: 2px solid var(--leaf); }
.plan-card__badge { position: absolute; top: 1.2rem; right: 1.2rem; margin: 0; }
.plan-card__name { font-size: 1.3rem; margin: 0 0 .4rem; }
.plan-card__price { font-family: var(--font-display); font-size: 2rem; font-weight: 800; color: var(--field); margin-bottom: .6rem; }
.plan-card__price small { font-size: .9rem; font-weight: 500; color: var(--ink-soft); }
.plan-card__desc { color: var(--ink-soft); font-size: .9rem; }
.plan-card__perks { list-style: none; padding: 0; margin: 1rem 0 1.4rem; flex: 1; }
.plan-card__perks li { padding: .35rem 0 .35rem 1.5rem; position: relative; font-size: .92rem; border-bottom: 1px solid var(--line); }
.plan-card__perks li:last-child { border-bottom: 0; }
.plan-card__perks li::before { content: '✓'; position: absolute; left: 0; color: var(--leaf); font-weight: 700; }
.btn.disabled { opacity: .6; pointer-events: none; }

/* =====================================================================
   PHASE 8 — Blog & content
   ===================================================================== */
.blog-grid { display: grid; gap: 1.6rem; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
.blog-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .15s, transform .15s; }
.blog-card:hover { box-shadow: var(--shadow-sm); transform: translateY(-2px); }
.blog-card__cover { display: block; aspect-ratio: 16/9; background: var(--paper-2); overflow: hidden; }
.blog-card__cover img { width: 100%; height: 100%; object-fit: cover; }
.blog-card__placeholder { display: flex; align-items: center; justify-content: center; height: 100%; font-size: 2.4rem; }
.blog-card__body { padding: 1.2rem 1.3rem 1.4rem; display: flex; flex-direction: column; flex: 1; }
.blog-card__cat { align-self: flex-start; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--leaf-600); background: #eaf5ee; padding: .15rem .55rem; border-radius: 999px; margin-bottom: .6rem; }
.blog-card__title { font-size: 1.15rem; line-height: 1.3; margin: 0 0 .5rem; }
.blog-card__title a { color: var(--ink); }
.blog-card__title a:hover { color: var(--field); }
.blog-card__excerpt { color: var(--ink-soft); font-size: .92rem; flex: 1; }
.blog-card__meta { font-size: .78rem; color: var(--ink-soft); margin-top: .8rem; }

/* Post detail */
.post-head { margin-bottom: 1.4rem; }
.post-head h1 { font-size: 2.1rem; line-height: 1.15; margin: .5rem 0; }
.post-meta { color: var(--ink-soft); font-size: .9rem; }
.post-cover { width: 100%; border-radius: var(--r-lg); margin-bottom: 1.8rem; }
.post-body { font-size: 1.06rem; line-height: 1.75; color: #28301f; }
.post-body h2 { font-family: var(--font-display); font-size: 1.5rem; margin: 1.8rem 0 .7rem; }
.post-body h3 { font-size: 1.2rem; margin: 1.4rem 0 .6rem; }
.post-body p { margin: 0 0 1.1rem; }
.post-body ul, .post-body ol { margin: 0 0 1.1rem 1.3rem; }
.post-body li { margin-bottom: .4rem; }
.post-body a { color: var(--leaf-600); text-decoration: underline; }
.post-body img { max-width: 100%; border-radius: var(--r-md); }
.post-body blockquote { border-left: 3px solid var(--leaf); padding-left: 1rem; color: var(--ink-soft); font-style: italic; margin: 0 0 1.1rem; }
.post-tags { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .5rem; }
.tag-chip { background: var(--paper-2); border: 1px solid var(--line); border-radius: 999px; padding: .2rem .7rem; font-size: .8rem; color: var(--ink-soft); }

/* =====================================================================
   PHASE 9 — AI assistant & developer API
   ===================================================================== */
.btn-ai { background: linear-gradient(135deg, #1f9d55, #14532d); color: #fff; border: 0; font-weight: 600; }
.btn-ai:hover { filter: brightness(1.08); color: #fff; }
.btn-ai:disabled { opacity: .65; }

.api-key-reveal { display: inline-block; background: #14532d; color: #fff; padding: .25rem .6rem; border-radius: 6px; margin-left: .4rem; font-size: .85rem; word-break: break-all; }

.code-block { background: #14210f; color: #e8f0e2; padding: 1.1rem 1.3rem; border-radius: var(--r-md); overflow-x: auto; font-size: .86rem; line-height: 1.55; }
.api-endpoint { border: 1px solid var(--line); border-radius: var(--r-md); padding: 1rem 1.2rem; margin-bottom: 1rem; background: var(--white); }
.api-endpoint code { color: var(--field); }
.api-method { display: inline-block; background: var(--leaf); color: #fff; font-size: .72rem; font-weight: 700; padding: .1rem .5rem; border-radius: 5px; margin-right: .4rem; }

/* =====================================================================
   PHASE 10 — Footer socials & misc hardening UI
   ===================================================================== */
.footer-social { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 1rem; }
.footer-social a { color: #cfe3d5; font-size: .85rem; text-decoration: none; border: 1px solid rgba(255,255,255,.18); padding: .25rem .7rem; border-radius: 999px; }
.footer-social a:hover { background: rgba(255,255,255,.1); color: #fff; }

/* =====================================================================
   POST-LAUNCH FIXES — brand, footer, mobile menu, enquiries
   ===================================================================== */

/* Header brand: logo never crops, optional tagline under the wordmark */
.brand-logo { height: 40px; width: auto; max-width: 54px; object-fit: contain; display: block; flex: none; }
.brand-wordmark { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text { font-size: 1.2rem; }
.brand-tagline { font-size: .62rem; font-weight: 600; letter-spacing: .02em; color: var(--ink-soft); text-transform: uppercase; }
@media (max-width: 575.98px) {
    .brand-tagline { display: none; }
    .brand-text { font-size: 1.05rem; }
}

/* Footer brand: clean colourful mark + crisp white wordmark on dark bg */
.footer-logo-mark { height: 46px; width: auto; display: block; flex: none; }
.footer-brand span strong { color: var(--grain); }

/* Mobile menu: make the Categories dropdown expand inline instead of as a
   floating popover (which could render off-screen and look like it closed) */
@media (max-width: 1199.98px) {
    .site-nav .navbar-nav .dropdown-menu {
        position: static;
        float: none;
        width: 100%;
        border: 0;
        box-shadow: none;
        padding-left: 1rem;
        margin-top: .25rem;
        background: transparent;
    }
    .site-nav .navbar-collapse { padding-bottom: .5rem; }
}

/* Admin enquiry cards */
.enquiry-card { border: 1px solid var(--line); border-radius: var(--r-md); padding: 1rem 1.2rem; background: var(--white); }
.enquiry-card.is-unread { border-left: 3px solid var(--leaf); background: #f6fbf7; }
.enquiry-card__head { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; align-items: flex-start; }
.enquiry-card__body { margin: .8rem 0 0; color: var(--ink); white-space: pre-line; }

/* =====================================================================
   Legal / policy pages + footer legal links
   ===================================================================== */
.legal-doc { line-height: 1.7; }
.legal-doc p { margin-bottom: 1rem; color: var(--ink); }
.prose-h3 { font-family: var(--font-display); font-size: 1.1rem; margin: 1.4rem 0 .5rem; color: var(--field); }
.legal-contact { background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r-md); padding: 1rem 1.2rem; }
.footer-legal { display: flex; gap: 1.1rem; flex-wrap: wrap; }
.footer-legal a { opacity: .85; }
.footer-legal a:hover { opacity: 1; text-decoration: underline; }
@media (max-width: 575.98px) { .footer-legal { gap: .8rem; } }

/* Certification tag in admin members list */
.cert-tag { display: inline-block; background: var(--field); color: #fff; font-size: .62rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; padding: .05rem .4rem; border-radius: 999px; }

/* =====================================================================
   Language switcher (Google Translate element) in the top bar
   ===================================================================== */
.site-header__bar-right { display: inline-flex; align-items: center; gap: 1rem; }
.lang-switch { line-height: 1; }
.lang-switch .goog-te-gadget { font-size: 0 !important; color: transparent; }
.lang-switch .goog-te-gadget > span { display: none; }
.lang-switch .goog-logo-link,
.lang-switch img.goog-te-gadget-icon { display: none !important; }
.lang-switch .goog-te-combo {
    font-size: .76rem; margin: 0; padding: .12rem .55rem; cursor: pointer; max-width: 150px;
    color: #fff; background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.35); border-radius: 999px; outline: none;
}
.lang-switch .goog-te-combo option { color: #14210f; background: #fff; }
/* Hide Google's injected top banner and stop it pushing the sticky nav down */
.goog-te-banner-frame, .skiptranslate > iframe { display: none !important; }
body { top: 0 !important; }
#goog-gt-tt, .goog-tooltip, .goog-text-highlight { display: none !important; background: none !important; box-shadow: none !important; }
@media (max-width: 575.98px) {
    .site-header__bar .container { flex-wrap: wrap; gap: .3rem; }
    .site-header__bar > .container > span.notranslate { font-size: .72rem; }
}
