/* ==========================================================================
   FOREVER LIVING  |  SHARED STYLESHEET  (v2.0)
   Used by:  index.html (shop)  ·  agent.html (agent portal)  ·  customer.html (customer portal)

   One design language: deep emerald + champagne gold on warm ivory,
   Playfair Display headings, Inter body text.

   Contents
     1  Design tokens
     2  Base & typography
     3  Components   (buttons, cards, forms, tables, badges, modal, toast, loader)
     4  Portals      (body.portal  -> agent.html and customer.html)
     5  Shop         (body.shop    -> index.html)
     6  Cart modal   (checkout dialog)
     7  Responsive & accessibility

   Fonts to load in every page <head>:
     https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&display=swap
   ========================================================================== */


/* ==========================================================================
   1  DESIGN TOKENS
   ========================================================================== */
:root {
    /* Brand */
    --brand-950: #03281e;
    --brand-900: #053f31;
    --brand-800: #064e3b;
    --brand-700: #0a6a50;
    --brand-500: #10b981;
    --brand-100: #d9f3e8;
    --gold-500: #d4af37;
    --gold-600: #b8932a;
    --gold-100: #f8efcf;

    /* Neutrals */
    --ivory: #fbfaf6;
    --surface: #ffffff;
    --ink-900: #14211c;
    --ink-700: #2f3d37;
    --ink-500: #5f6e67;
    --ink-300: #a7b2ac;
    --line: #e7e9e4;
    --line-soft: #f0f1ed;

    /* Status */
    --ok: #1f8a4c;
    --ok-bg: #e4f6ec;
    --warn: #b7791f;
    --warn-bg: #fdf3dc;
    --bad: #b42318;
    --bad-bg: #fde8e6;
    --info: #1d5fa8;
    --info-bg: #e5effa;

    /* Type */
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

    /* Shape & depth */
    --r-sm: 8px;
    --r-md: 12px;
    --r-lg: 18px;
    --r-pill: 999px;
    --shadow-xs: 0 1px 2px rgba(16, 33, 28, .06);
    --shadow-sm: 0 2px 8px rgba(16, 33, 28, .06);
    --shadow-md: 0 8px 24px rgba(16, 33, 28, .08);
    --shadow-lg: 0 24px 48px -12px rgba(16, 33, 28, .22);
    --ring: 0 0 0 3px rgba(212, 175, 55, .25);
    --ease: cubic-bezier(.2, .8, .2, 1);
    --t: .22s var(--ease);

    /* ---- legacy names (the three pages and script.js still use these) ---- */
    --primary-dark: var(--brand-800);
    --primary-main: var(--brand-700);
    --primary-light: var(--brand-500);
    --primary-color: var(--brand-800);
    --secondary-color: var(--gold-600);
    --accent-color: var(--gold-500);
    --accent-gold: var(--gold-500);
    --accent-gold-dim: var(--gold-600);
    --gold-accent: var(--gold-500);
    --gold-hover: var(--gold-600);
    --bg-cream: var(--ivory);
    --bg-white: var(--surface);
    --bg-body: var(--ivory);
    --bg-card: var(--surface);
    --light-gray: var(--ivory);
    --mid-gray: var(--line);
    --light-text: #ffffff;
    --dark-text: var(--ink-900);
    --text-main: var(--ink-900);
    --text-heading: var(--ink-900);
    --text-body: var(--ink-700);
    --text-muted: var(--ink-500);
    --success: var(--ok);
    --success-color: var(--ok);
    --danger: var(--bad);
    --danger-color: var(--bad);
    --radius-sm: var(--r-sm);
    --radius-md: var(--r-md);
    --radius-lg: var(--r-lg);
    --radius-pill: var(--r-pill);
    --border-radius-sm: var(--r-sm);
    --border-radius-lg: var(--r-lg);
    --shadow-subtle: var(--shadow-sm);
    --shadow-elevated: var(--shadow-md);
    --shadow-glow: 0 0 18px rgba(212, 175, 55, .3);
    --border-light: 1px solid var(--line);
    --transition: all var(--t);
    --font-family: var(--font-body);
    --glass-bg: rgba(255, 255, 255, .86);
    --glass-border: 1px solid rgba(255, 255, 255, .6);
    --nav-glass: rgba(255, 255, 255, .92);
}


/* ==========================================================================
   2  BASE & TYPOGRAPHY
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
    color: var(--ink-700);
    background-color: var(--ivory);
    background-image:
        radial-gradient(900px 420px at 8% -5%, rgba(212, 175, 55, .09), transparent 60%),
        radial-gradient(800px 400px at 100% 0%, rgba(16, 185, 129, .06), transparent 60%);
    background-attachment: fixed;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img { max-width: 100%; }
a { color: var(--brand-700); }
a:hover { color: var(--gold-600); }
.hidden { display: none !important; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--brand-900);
    font-weight: 600;
    letter-spacing: -.01em;
    line-height: 1.2;
}
h1 { font-size: clamp(2rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); margin-bottom: 1rem; }
h3 { font-size: 1.25rem; margin-bottom: .75rem; }
h4 {
    font-family: var(--font-body);
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: var(--gold-600);
    font-weight: 700;
}
p { margin-bottom: .6em; }
small { color: var(--ink-500); }


/* ==========================================================================
   3  COMPONENTS
   ========================================================================== */

/* ---- Buttons ---- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 24px;
    font-family: var(--font-body); font-size: .78rem; font-weight: 600;
    letter-spacing: .08em; text-transform: uppercase; text-decoration: none;
    border: 1px solid transparent; border-radius: var(--r-sm);
    cursor: pointer; transition: var(--t); user-select: none;
}
.btn:focus-visible { outline: none; box-shadow: var(--ring); }
.btn:disabled, .btn[disabled] { opacity: .55; cursor: not-allowed; transform: none !important; box-shadow: none !important; }

.btn-primary {
    background: linear-gradient(135deg, var(--brand-700), var(--brand-900));
    color: #fff;
    box-shadow: 0 6px 16px rgba(5, 63, 49, .28);
}
.btn-primary:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(5, 63, 49, .34); color: #fff; }

.btn-gold {
    background: linear-gradient(135deg, var(--gold-500), var(--gold-600));
    color: #fff;
    box-shadow: 0 6px 16px rgba(184, 147, 42, .3);
}
.btn-gold:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(184, 147, 42, .4); color: #fff; }

.btn-secondary {
    background: var(--surface); color: var(--brand-800);
    border-color: var(--line); box-shadow: var(--shadow-xs);
}
.btn-secondary:hover:not(:disabled) { border-color: var(--gold-500); color: var(--gold-600); transform: translateY(-1px); }

.btn-ghost { background: transparent; color: var(--ink-500); }
.btn-ghost:hover:not(:disabled) { background: var(--line-soft); color: var(--brand-800); }

.btn-danger { background: var(--bad-bg); color: var(--bad); border-color: #f5c6c1; }
.btn-danger:hover:not(:disabled) { background: var(--bad); color: #fff; }

.btn-sm { padding: 7px 14px; font-size: .7rem; border-radius: 7px; }
.btn-block { width: 100%; }

/* ---- Cards ---- */
.card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-sm);
    padding: 32px;
    margin-bottom: 24px;
}
.card::before {
    content: ''; position: absolute; left: 24px; right: 24px; top: -1px; height: 3px;
    border-radius: 0 0 6px 6px;
    background: linear-gradient(90deg, var(--brand-700), var(--gold-500), var(--brand-700));
    opacity: .85;
}
.card > h3:first-child, .card > h2:first-child { margin-bottom: 1rem; }

/* ---- Forms ---- */
label {
    display: block; margin-bottom: 6px;
    font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
    color: var(--ink-500);
}
input, select, textarea {
    width: 100%;
    padding: 12px 14px; margin-bottom: 14px;
    font-family: var(--font-body); font-size: .95rem; color: var(--ink-900);
    background: #fff;
    border: 1px solid var(--line); border-radius: var(--r-sm);
    transition: var(--t);
}
input::placeholder, textarea::placeholder { color: var(--ink-300); }
input:hover, select:hover, textarea:hover { border-color: #cfd4cc; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--gold-500); box-shadow: var(--ring); }
input:disabled, select:disabled, textarea:disabled { background: var(--line-soft); color: var(--ink-500); cursor: not-allowed; }
textarea { resize: vertical; min-height: 84px; }
select {
    appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 38px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%235f6e67' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 14px center;
}
input[type="checkbox"], input[type="radio"] { width: auto; margin: 0 8px 0 0; accent-color: var(--brand-700); }
input[type="file"] { padding: 9px; background: var(--ivory); font-size: .85rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.field-hint { font-size: .8rem; color: var(--ink-500); margin: -6px 0 12px; }

/* ---- Tables ---- */
table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .92rem; }
thead th {
    text-align: left; padding: 12px 16px;
    font-size: .68rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
    color: var(--ink-500); background: var(--ivory);
    border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
thead th:first-child { border-left: 1px solid var(--line); border-radius: var(--r-sm) 0 0 var(--r-sm); }
thead th:last-child { border-right: 1px solid var(--line); border-radius: 0 var(--r-sm) var(--r-sm) 0; }
tbody td { padding: 14px 16px; border-bottom: 1px solid var(--line-soft); color: var(--ink-700); vertical-align: middle; }
tbody tr { transition: background var(--t); }
tbody tr:hover td { background: #fcfbf7; }
tbody tr:last-child td { border-bottom: none; }
td .btn { white-space: nowrap; }
.num, td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* ---- Badges ---- */
.badge {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 4px 11px; border-radius: var(--r-pill);
    font-size: .7rem; font-weight: 700; letter-spacing: .04em; white-space: nowrap;
    background: var(--line-soft); color: var(--ink-500);
}
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-success { background: var(--ok-bg); color: var(--ok); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }
.badge-info { background: var(--info-bg); color: var(--info); }
.badge-danger { background: var(--bad-bg); color: var(--bad); }

/* ---- Alerts ---- */
.alert { padding: 12px 16px; border-radius: var(--r-sm); font-size: .9rem; border: 1px solid transparent; margin-bottom: 14px; }
.alert-ok { background: var(--ok-bg); color: var(--ok); border-color: #bfe6cd; }
.alert-warn { background: var(--warn-bg); color: var(--warn); border-color: #f1dca4; }
.alert-bad { background: var(--bad-bg); color: var(--bad); border-color: #f5c6c1; }

/* ---- Modal (shared by shop dialogs and the agent order editor) ---- */
.modal {
    display: none; position: fixed; inset: 0; z-index: 1001;
    justify-content: center; align-items: center; padding: 16px;
    background: rgba(3, 40, 30, .55);
    -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.modal-content {
    display: flex; flex-direction: column;
    width: 100%; max-width: 720px; max-height: 92vh; overflow: hidden;
    background: var(--surface); border-radius: var(--r-lg);
    box-shadow: var(--shadow-lg);
    animation: flRise .28s var(--ease);
}
@keyframes flRise { from { opacity: 0; transform: translateY(24px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-header {
    display: flex; justify-content: space-between; align-items: center; gap: 12px;
    padding: 20px 28px; background: var(--ivory); border-bottom: 1px solid var(--line);
}
.modal-header h2, .modal-header h3 { margin: 0; font-size: 1.4rem; }
.modal-body { padding: 24px 28px; overflow-y: auto; }
.modal-footer { padding: 18px 28px; background: var(--ivory); border-top: 1px solid var(--line); }
.close {
    width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center;
    font-size: 1.6rem; line-height: 1; color: var(--ink-500);
    background: transparent; border: none; border-radius: 50%; cursor: pointer; transition: var(--t);
}
.close:hover { background: var(--line-soft); color: var(--brand-800); }

/* ---- Toast ---- */
#fl-toast-root { position: fixed; right: 20px; bottom: 20px; z-index: 100000; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.fl-toast {
    min-width: 240px; max-width: 360px; padding: 13px 18px;
    background: var(--brand-900); color: #fff; font-size: .9rem;
    border-radius: var(--r-md); border-left: 4px solid var(--gold-500);
    box-shadow: var(--shadow-lg); animation: flRise .25s var(--ease);
}
.fl-toast.bad { border-left-color: #f0605a; }
.fl-toast.ok { border-left-color: var(--brand-500); }

/* ---- Loader ---- */
.loader { text-align: center; padding: 3rem; color: var(--gold-600); font-family: var(--font-heading); font-size: 1.3rem; }
.spinner {
    width: 22px; height: 22px; border-radius: 50%;
    border: 3px solid var(--line); border-top-color: var(--gold-500);
    animation: flSpin .8s linear infinite; display: inline-block; vertical-align: middle;
}
@keyframes flSpin { to { transform: rotate(360deg); } }

/* ---- Stat tiles ---- */
.stat-box {
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
    padding: 22px; text-align: center; transition: var(--t);
}
.stat-box:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.stat-label { display: block; margin-bottom: 8px; font-size: .68rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-500); }
.stat-value { font-family: var(--font-heading); font-size: 2rem; font-weight: 700; color: var(--brand-800); }

/* ---- Summary lines (cart & order totals) ---- */
.summary-line { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 6px; font-size: .92rem; color: var(--ink-700); }
.summary-line.total {
    margin-top: 10px; padding-top: 12px; border-top: 1px dashed #cfd4cc;
    font-family: var(--font-heading); font-size: 1.45rem; font-weight: 700; color: var(--brand-800);
}


/* ==========================================================================
   4  PORTALS   (body.portal)  ·  agent.html and customer.html
   ========================================================================== */

/* ---- Login ---- */
body.portal #login-view {
    display: flex; justify-content: center; align-items: center; min-height: 100vh; padding: 24px;
    background:
        radial-gradient(700px 420px at 15% 10%, rgba(212, 175, 55, .22), transparent 60%),
        radial-gradient(700px 480px at 90% 95%, rgba(16, 185, 129, .25), transparent 60%),
        linear-gradient(135deg, var(--brand-950), var(--brand-800));
}
body.portal #login-box {
    width: 100%; max-width: 430px; padding: 44px 40px; text-align: center;
    border: none; box-shadow: var(--shadow-lg); margin: 0;
}
body.portal #login-box::before { left: 40px; right: 40px; }
body.portal #login-box img {
    width: 84px; height: 84px; object-fit: cover; border-radius: 50%;
    border: 3px solid var(--gold-500); padding: 3px; margin-bottom: 18px;
    box-shadow: 0 0 0 6px rgba(212, 175, 55, .14);
}
body.portal #login-box h1 { font-size: 1.9rem; margin-bottom: 6px; }
body.portal #login-box p { color: var(--ink-500); }
body.portal #login-box form { text-align: left; margin-top: 22px; }
body.portal #login-box input { margin-bottom: 14px; }
body.portal #login-box .btn { width: 100%; padding: 14px; }
body.portal #login-status, body.portal #register-status, body.portal #password-change-status { text-align: center; min-height: 1.4em; margin-top: 12px; font-size: .88rem; color: var(--bad); font-weight: 500; }
body.portal #login-box a { font-weight: 600; font-size: .88rem; text-decoration: none; border-bottom: 1px solid rgba(184, 147, 42, .4); }

/* ---- Shell ---- */
body.portal #portal-view { max-width: 1240px; margin: 0 auto; padding: 28px 24px 60px; }
body.portal header {
    display: flex; justify-content: space-between; align-items: flex-start; gap: 20px;
    padding: 0 0 22px; margin-bottom: 22px; background: transparent;
    border-bottom: 1px solid var(--line); text-align: left;
}
body.portal header h2 { margin: 0; font-size: clamp(1.6rem, 3vw, 2.3rem); color: var(--brand-900); }
body.portal #agent-details-display, body.portal #customer-details-display {
    margin: 6px 0 0 !important; font-size: .72rem !important; font-weight: 700 !important;
    letter-spacing: .16em; text-transform: uppercase; color: var(--gold-600) !important;
}
body.portal header > div:last-child { display: flex; flex-direction: column; gap: 8px; align-items: stretch; min-width: 150px; }

/* Target progress */
.target-bar-container { width: 100%; height: 6px; background: var(--line); border-radius: var(--r-pill); margin-top: 12px; overflow: hidden; }
.target-progress { height: 100%; border-radius: var(--r-pill); background: linear-gradient(90deg, var(--brand-700), var(--gold-500)); transition: width 1s var(--ease); }

/* ---- Tab navigation ---- */
body.portal nav {
    display: flex; flex-wrap: wrap; gap: 6px; padding: 6px; margin-bottom: 26px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow-xs);
    position: static; backdrop-filter: none;
}
body.portal nav .btn {
    flex: 1 1 130px; flex-direction: row; gap: 9px; padding: 12px 14px;
    background: transparent; color: var(--ink-500); border: none; box-shadow: none;
    font-size: .72rem; border-radius: 9px;
}
body.portal nav .btn i { font-size: 1rem; color: var(--ink-300); transition: var(--t); }
body.portal nav .btn:hover:not(.active):not(:disabled) { background: var(--ivory); color: var(--brand-800); transform: none; }
body.portal nav .btn.active { background: linear-gradient(135deg, var(--brand-700), var(--brand-900)); color: #fff; box-shadow: 0 6px 14px rgba(5, 63, 49, .28); }
body.portal nav .btn.active i { color: var(--gold-500); }

body.portal .view { animation: flRise .3s var(--ease); }
body.portal .view > h2, body.portal .view > h3:first-child { margin-bottom: 1.1rem; }

/* ---- Open orders (agent) ---- */
.open-order-card {
    display: flex; justify-content: space-between; align-items: center; gap: 20px;
    padding: 20px 22px; margin-bottom: 14px;
    background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--line);
    border-radius: var(--r-md); transition: var(--t);
}
.open-order-card:hover { border-left-color: var(--gold-500); box-shadow: var(--shadow-md); transform: translateX(3px); }
.open-order-info { line-height: 1.55; }
.open-order-info strong { display: block; margin-bottom: 4px; font-family: var(--font-heading); font-size: 1.2rem; color: var(--brand-800); }
.admin-assign-box { display: flex; align-items: center; gap: 8px; margin-top: 12px; padding: 10px 12px; background: var(--gold-100); border-radius: var(--r-sm); }
.admin-assign-box select { margin: 0; padding: 8px 34px 8px 10px; font-size: .85rem; }

/* ---- Create order (agent) ---- */
#order-creation-workflow { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; align-items: start; }
#order-creation-workflow > div > .card, #order-creation-workflow .card { margin-bottom: 20px; }
.product-item-selectable {
    display: flex; align-items: center; gap: 16px; padding: 12px 14px;
    border-bottom: 1px solid var(--line-soft); cursor: pointer; transition: var(--t); border-radius: var(--r-sm);
}
.product-item-selectable:hover { background: var(--ivory); }
.product-item-selectable img { width: 56px; height: 56px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: var(--r-sm); padding: 3px; }
#product-selection-list { max-height: 520px; overflow-y: auto; }
#summary-items-list { background: var(--ivory); border: 1px solid var(--line); border-radius: var(--r-md); padding: 8px 16px; margin-bottom: 16px; }
#summary-items-list input[type="number"] { margin: 0; padding: 8px; font-size: .9rem; border-radius: 7px; }
#summary-total { font-family: var(--font-heading); color: var(--brand-800); }

/* ---- Customer shop ---- */
#shop-workflow { display: grid; grid-template-columns: 1fr 400px; gap: 24px; align-items: start; }
#product-list { max-height: 780px; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--r-md); background: #fff; }
.product-item { display: grid; grid-template-columns: 76px 1fr auto; align-items: center; gap: 16px; padding: 12px 16px; border-bottom: 1px solid var(--line-soft); transition: background var(--t); }
.product-item:hover { background: var(--ivory); }
.product-item img { width: 68px; height: 68px; object-fit: contain; background: #fff; border: 1px solid var(--line); border-radius: var(--r-sm); padding: 3px; }
.summary-item { display: grid; grid-template-columns: 1fr 64px 30px; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.summary-item input { margin: 0; padding: 8px; }
.summary-item p { margin: 0; color: var(--ink-500); font-size: .85rem; }

/* ---- Profile ---- */
.profile-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px 36px; }
.profile-item label { color: var(--gold-600); }
.profile-item input:disabled { background: var(--line-soft); }

/* ---- Order editor modal (agent) ---- */
#order-modal .modal-content { max-width: 880px; }
.order-meta { display: flex; flex-wrap: wrap; gap: 10px 22px; align-items: center; margin-bottom: 18px; color: var(--ink-500); font-size: .88rem; }
.order-meta strong { color: var(--brand-800); font-family: var(--font-heading); font-size: 1.15rem; }
.order-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.order-grid .full { grid-column: 1 / -1; }
.order-items { width: 100%; margin: 6px 0 14px; }
.order-items input { margin: 0; padding: 8px 10px; font-size: .9rem; border-radius: 7px; }
.order-items td { padding: 8px 10px; }
.order-items .qty { width: 74px; }
.order-items .price { width: 100px; }
.order-totals { margin-left: auto; max-width: 320px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.low-price { color: var(--bad); font-size: .78rem; font-weight: 600; }


/* ==========================================================================
   5  SHOP   (body.shop)  ·  index.html
   ========================================================================== */

/* ---- Header ---- */
body.shop header { background: #fff; padding: 24px 0; text-align: center; border-bottom: 1px solid var(--line); }
.header-content { display: flex; align-items: center; justify-content: center; gap: 20px; }
.header-logo { width: 70px; height: 70px; border-radius: 50%; border: 2px solid var(--gold-500); padding: 2px; object-fit: cover; }
#company-name-header { margin: 0; font-size: 2.2rem; line-height: 1.1; color: var(--brand-800); }
#company-name-header .by-line { display: block; margin-top: 6px; font-family: var(--font-body); font-size: .9rem; color: var(--gold-600); letter-spacing: .22em; text-transform: uppercase; font-weight: 600; }
#company-name-header .slogan { display: block; margin-top: 6px; font-family: var(--font-body); font-size: .8rem; color: var(--ink-500); font-weight: 300; font-style: italic; letter-spacing: 0; text-transform: none; }

/* Promo banner */
#promo-running-banner {
    display: none; overflow: hidden; white-space: nowrap; padding: 9px 0;
    color: #fff; font-weight: 600; font-size: .88rem;
    background: linear-gradient(90deg, var(--brand-900), #0f3d3e);
}
#promo-running-banner .marquee-content { display: inline-block; padding-left: 100%; animation: marquee 20s linear infinite; }
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-100%); } }

/* Sticky glass navigation */
body.shop nav {
    position: sticky; top: 0; z-index: 1000;
    background: var(--nav-glass); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow-xs);
}
body.shop nav ul { display: flex; flex-wrap: wrap; justify-content: center; list-style: none; }
body.shop nav a {
    position: relative; padding: 18px 24px; cursor: pointer; text-decoration: none;
    font-size: .8rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
    color: var(--brand-800); transition: color var(--t);
}
body.shop nav a::after {
    content: ''; position: absolute; left: 50%; bottom: 10px; width: 0; height: 2px;
    background: var(--gold-500); transition: all var(--t);
}
body.shop nav a:hover { color: var(--gold-600); }
body.shop nav a:hover::after { width: 60%; left: 20%; }
.nav-login-btn {
    display: inline-flex; align-items: center; margin: 10px 14px; padding: 8px 24px !important;
    background: var(--brand-800); color: var(--gold-500) !important; border-radius: var(--r-pill);
    box-shadow: 0 4px 12px rgba(6, 78, 59, .25);
}
.nav-login-btn:hover { background: var(--ink-900); color: #fff !important; transform: translateY(-1px); }
.nav-login-btn::after { display: none !important; }

body.shop main { padding: 3rem 0; min-height: 60vh; }
.tab-content { display: none; animation: fadeIn .6s var(--ease); }
.tab-content.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

body.shop footer {
    padding: 56px 20px; text-align: center;
    background: var(--brand-900); color: rgba(255, 255, 255, .72);
    border-top: 4px solid var(--gold-500);
}
.timestamp { margin-top: 14px; font-size: .8rem; opacity: .5; }

/* ---- Homepage & content ---- */
.hero-section {
    padding: 96px 24px; margin-bottom: 40px; text-align: center; color: #fff;
    border-radius: var(--r-lg); box-shadow: var(--shadow-md);
    background: linear-gradient(rgba(5, 63, 49, .9), rgba(5, 63, 49, .78)), url('https://images.unsplash.com/photo-1544367563-12123d8965cd?q=80&w=2070&auto=format&fit=crop') center / cover;
}
.hero-section h2 { color: var(--gold-500); font-size: clamp(1.8rem, 4vw, 2.6rem); margin-bottom: 14px; }
.hero-section p { max-width: 620px; margin: 0 auto; font-size: 1.15rem; opacity: .92; }

.dynamic-content-wrapper {
    margin-bottom: 2rem; padding: 3rem;
    background: #fff; border: 1px solid var(--line-soft); border-radius: var(--r-lg); box-shadow: var(--shadow-sm);
}
.why-choose-us-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2rem; margin-top: 2rem; text-align: center; }
.why-choose-us-grid div { padding: 20px; transition: transform var(--t); }
.why-choose-us-grid div:hover { transform: translateY(-5px); }
.why-choose-us-grid i { margin-bottom: 1rem; padding: 20px; font-size: 2.2rem; color: var(--gold-500); background: rgba(212, 175, 55, .12); border-radius: 50%; }

#youtube-videos-container { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 2rem; }
.video-wrapper { position: relative; height: 0; padding-bottom: 56.25%; overflow: hidden; border: 4px solid #fff; border-radius: var(--r-lg); box-shadow: var(--shadow-md); }
.video-wrapper iframe { position: absolute; inset: 0; width: 100%; height: 100%; }

#testimonies-container { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.testimony-card { padding: 2rem; text-align: center; background: #fff; border-top: 3px solid var(--gold-500); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); }
.testimony-rating { margin-top: 10px; color: var(--gold-500); }

.owner-profile { display: flex; flex-wrap: wrap; align-items: center; gap: 3rem; margin-bottom: 3rem; }
.owner-image { flex-shrink: 0; width: 220px; height: 220px; object-fit: cover; border: 6px solid #fff; border-radius: 50%; box-shadow: var(--shadow-md); }
.about-section { margin-top: 24px; padding: 28px; background: #fff; border-left: 5px solid var(--gold-500); border-radius: 0 var(--r-lg) var(--r-lg) 0; box-shadow: var(--shadow-sm); }

/* Careers */
.job-card { margin-bottom: 2rem; overflow: hidden; background: #fff; border: 1px solid var(--line-soft); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); transition: var(--t); }
.job-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.job-header { display: flex; justify-content: space-between; align-items: center; padding: 24px 30px; background: var(--brand-900); color: #fff; }
.job-header h3 { margin: 0; font-size: 1.4rem; color: var(--gold-500); }
.job-body { padding: 30px; }
.job-details { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px; margin-bottom: 24px; padding: 16px; background: var(--ivory); border-radius: 10px; }
.job-detail-item { display: flex; align-items: center; gap: 10px; font-size: .9rem; font-weight: 600; color: var(--ink-500); }
.job-detail-item i { color: var(--brand-500); }
.job-description { margin-top: 1.5rem; padding-top: 1.5rem; white-space: pre-wrap; border-top: 1px dashed var(--line); color: var(--ink-900); }

/* ---- Product grid ---- */
.product-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 28px; }
.product {
    position: relative; display: flex; flex-direction: column; overflow: hidden;
    background: #fff; border: 1px solid var(--line-soft); border-radius: var(--r-lg); box-shadow: var(--shadow-sm);
    transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.product:hover { transform: translateY(-8px); box-shadow: var(--shadow-md); }
.product-tag {
    position: absolute; top: 18px; left: 18px; z-index: 2;
    padding: 5px 12px; border-radius: 6px;
    background: var(--gold-500); color: var(--brand-950);
    font-size: .7rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
}
.product-image-container { display: flex; align-items: center; justify-content: center; height: 280px; padding: 28px; background: radial-gradient(circle, #fff 0%, #f3f3ee 100%); }
.product img { max-width: 100%; max-height: 100%; object-fit: contain; filter: drop-shadow(0 10px 14px rgba(0, 0, 0, .1)); transition: transform var(--t); }
.product:hover img { transform: scale(1.05); }
.product-info { display: flex; flex: 1; flex-direction: column; padding: 22px; text-align: center; }
.product h3 { margin: 0 0 10px; font-size: 1.2rem; color: var(--ink-900); }
.price-section { margin-bottom: 14px; }
.new-price { font-family: var(--font-heading); font-size: 1.45rem; font-weight: 700; color: var(--brand-800); }
.product .benefits, .product .consumption { margin: 8px 0; font-size: .88rem; font-style: italic; color: var(--ink-500); }
.product-actions { margin-top: auto; padding-top: 14px; }
.product-actions .btn { width: 100%; }

/* ---- Floating buttons ---- */
.fab-container { position: fixed; right: 28px; bottom: 28px; z-index: 990; display: flex; gap: 14px; }
.fab {
    position: relative; display: flex; align-items: center; justify-content: center;
    width: 62px; height: 62px; font-size: 1.4rem; cursor: pointer;
    background: var(--brand-800); color: var(--gold-500); border: 2px solid var(--gold-500); border-radius: 50%;
    box-shadow: 0 10px 24px rgba(6, 78, 59, .4); transition: var(--t);
}
.fab:hover { transform: scale(1.08) rotate(4deg); }
#cart-count {
    position: absolute; top: -6px; right: -6px; padding: 3px 8px;
    background: #e11d48; color: #fff; border: 2px solid #fff; border-radius: 999px;
    font-size: .72rem; font-weight: 700;
}

/* ---- Shop modals ---- */
body.shop .modal { background: rgba(5, 63, 49, .6); }
.cart-item { display: flex; align-items: center; gap: 18px; padding: 16px; margin-bottom: 10px; background: #fff; border: 1px solid var(--line-soft); border-radius: var(--r-md); transition: background var(--t); }
.cart-item:hover { background: var(--ivory); }
.cart-item-image { width: 84px; height: 84px; object-fit: contain; padding: 5px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-sm); }
.cart-item-details h4 { margin-bottom: 4px; font-family: var(--font-heading); font-size: 1rem; letter-spacing: 0; text-transform: none; color: var(--brand-800); }
.quantity-controls { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.quantity-btn {
    display: flex; align-items: center; justify-content: center; width: 32px; height: 32px;
    background: #fff; color: var(--brand-800); border: 1px solid var(--line); border-radius: 50%; cursor: pointer; transition: var(--t);
}
.quantity-btn:hover { background: var(--brand-800); color: #fff; border-color: var(--brand-800); }
.remove-item-btn { margin-left: auto; background: none; border: none; color: #ef4444; font-size: 1.05rem; cursor: pointer; }
.customer-info-form h3, .enquiry-form h3 { margin-bottom: 18px; font-family: var(--font-heading); color: var(--brand-800); }

/* Login chooser */
#login-modal-content { max-width: 500px; text-align: center; }
.login-option { position: relative; overflow: hidden; margin-bottom: 18px; padding: 28px; border: 1px solid var(--line); border-radius: var(--r-lg); transition: var(--t); }
.login-option::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--gold-500); transform: scaleY(0); transition: transform var(--t); }
.login-option:hover { border-color: transparent; box-shadow: var(--shadow-md); transform: translateX(4px); }
.login-option:hover::before { transform: scaleY(1); }
.login-option h3 { margin-top: 0; }

/* Shop assistant — scoped so the shared portal styles are unaffected. */
#eshop-chat-widget {
    position: fixed; right: 28px; bottom: 104px; z-index: 1000; width: 420px;
    height: min(690px, calc(100vh - 132px)); height: min(690px, calc(100dvh - 132px));
    display: flex; flex-direction: column; overflow: hidden; text-align: left;
    background: #f6f8f6; color: #20392e; font: 14px/1.5 var(--font-body);
    border: 1px solid #dce6df; border-radius: 24px;
    box-shadow: 0 24px 80px -12px rgba(3, 40, 30, .28), 0 4px 16px rgba(3, 40, 30, .08);
    visibility: hidden; opacity: 0; transform: translateY(16px) scale(.98); transform-origin: bottom right;
    transition: opacity .22s ease, transform .22s ease, visibility .22s;
}
#eshop-chat-widget.active { visibility: visible; opacity: 1; transform: none; }
#eshop-chat-widget svg { width: 20px; height: 20px; flex-shrink: 0; }
#eshop-chat-widget button, #eshop-chat-widget input, #eshop-chat-widget textarea { font-family: inherit; }
#eshop-chat-widget button:focus-visible, #eshop-chat-widget a:focus-visible { outline: 3px solid #b8932a; outline-offset: 3px; }
#eshop-chat-widget button:disabled { cursor: wait; opacity: .55; }
#chat-header { display: flex; flex-shrink: 0; justify-content: space-between; align-items: center; gap: 8px; padding: 22px 20px; background: linear-gradient(125deg, #064e3b, #123e30); color: #fff; }
#chat-header .chat-brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
#chat-header .chat-brandmark { display: grid; place-items: center; width: 44px; height: 48px; flex-shrink: 0; border: 1px solid #ffffff29; border-radius: 15px; background: #ffffff0d; color: #e8d89f; }
#chat-header .chat-brandmark svg { width: 27px; height: 27px; }
#chat-header .chat-brand-label { display: block; font-size: 9px; font-weight: 600; letter-spacing: .2em; color: #d5e7db; }
#chat-title { margin: 3px 0; color: #fff; font: 600 19px/1.2 var(--font-body); letter-spacing: -.4px; }
#chat-account-state { display: block; font-size: 10px; color: #d1e1d6; }
#chat-header .chat-header-actions { display: flex; gap: 2px; align-self: flex-start; }
#chat-header button { display: grid; place-items: center; width: 36px; height: 38px; padding: 0; border: 0; border-radius: 10px; background: transparent; color: #e1ede5; cursor: pointer; }
#chat-header button:hover { background: #ffffff18; }
#chat-header button svg { width: 18px; height: 18px; }
#chat-body { display: flex; flex: 1; min-height: 0; flex-direction: column; gap: 14px; padding: 20px 18px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #b9ccc0 transparent; }
#chat-body .chat-message { flex-shrink: 0; max-width: 90%; margin: 0; padding: 12px 15px; border-radius: 16px; overflow-wrap: anywhere; font-size: 13px; line-height: 1.65; box-shadow: 0 2px 4px #173e2504; }
#chat-body .bot-message { align-self: flex-start; background: #fff; color: #30493c; border: 1px solid #e3eae4; border-top-left-radius: 4px; }
#chat-body .user-message { align-self: flex-end; background: #12523f; color: #fff; border: 0; border-bottom-right-radius: 4px; white-space: pre-wrap; }
#chat-body .chat-menu-card, #chat-body .chat-results { width: 100%; max-width: 100%; padding: 0; border: 0; background: transparent; box-shadow: none; }
#chat-body h3 { margin: 0; color: #173e2d; font: 600 18px/1.3 var(--font-body); letter-spacing: -.4px; }
#chat-body .chat-menu-intro { padding: 0 2px 14px; }
#chat-body .chat-eyebrow { display: block; margin-bottom: 8px; font-size: 9px; font-weight: 600; letter-spacing: .14em; color: #718477; }
#chat-body .chat-menu-intro h3 { font-size: 24px; letter-spacing: -.9px; }
#chat-body .chat-menu-intro p { margin: 6px 0 0; font-size: 12px; color: #65786b; }
#chat-body .chat-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
#chat-body .chat-option { position: relative; display: flex; align-items: center; gap: 10px; min-height: 78px; padding: 12px 10px; text-align: left; color: #244231; border: 1px solid #e0e8e1; border-radius: 13px; background: #fff; cursor: pointer; transition: border-color .18s, box-shadow .18s, transform .18s; }
#chat-body .chat-option:hover { border-color: #91b5a1; box-shadow: 0 3px 12px #064e3b0a; transform: translateY(-1px); }
#chat-body .chat-option-icon { display: grid; place-items: center; width: 30px; height: 34px; flex-shrink: 0; border-radius: 9px; background: #f0f6f1; color: #357353; }
#chat-body .chat-option-copy { min-width: 0; }
#chat-body .chat-option strong { display: block; font-size: 11.5px; font-weight: 600; line-height: 1.4; }
#chat-body .chat-option small { display: block; margin-top: 3px; font-size: 10px; line-height: 1.4; color: #6d7d70; }
#chat-body .chat-option-lock { position: absolute; top: 6px; right: 6px; display: flex; color: #809588; }
#chat-body .chat-option-lock svg { width: 10px; height: 10px; }
#chat-body .chat-human-link { display: flex; grid-column: 1 / -1; align-items: center; gap: 12px; margin-top: 4px; padding: 13px 14px; color: #234e36; background: #edf5ee; border: 1px solid #d8e8db; border-radius: 13px; text-decoration: none; transition: background .18s; }
#chat-body .chat-human-link:hover { background: #e2efe5; }
#chat-body .chat-human-icon { display: grid; place-items: center; width: 31px; height: 31px; flex-shrink: 0; }
#chat-body .chat-human-icon svg { width: 25px; height: 25px; }
#chat-body .chat-human-link strong { display: block; font-size: 12px; font-weight: 600; }
#chat-body .chat-human-link small { display: block; margin-top: 1px; font-size: 10px; color: #667c6c; }
#chat-body .chat-human-link > svg { margin-left: auto; width: 15px; height: 15px; }
#chat-body .chat-menu-note { display: flex; align-items: center; justify-content: center; gap: 5px; margin: 13px 0 0; font-size: 10px; color: #748275; }
#chat-body .chat-menu-note svg { width: 12px; height: 12px; }
#chat-body .chat-signout { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 10px auto 0; padding: 8px; background: transparent; border: 0; color: #5c7364; font-size: 10px; cursor: pointer; }
#chat-body .chat-signout svg { width: 13px; height: 13px; }
#chat-input-container { display: flex; flex-shrink: 0; align-items: center; gap: 8px; margin: 0; padding: 13px 16px 5px; border-top: 1px solid #e0e8e1; background: #fff; }
#chat-input { flex: 1; min-width: 0; width: auto; margin: 0; padding: 12px 14px; background: #f5f7f4; color: #244231; border: 1px solid #e1e8e1; border-radius: 12px; font-size: 12px; box-shadow: none; }
#chat-input::placeholder { color: #768579; }
#chat-input:focus { outline: 2px solid #94bba5; outline-offset: 1px; }
#chat-send-btn { display: grid; place-items: center; flex-shrink: 0; width: 42px; height: 42px; padding: 0; border: 0; border-radius: 12px; background: #14573f; color: #fff; cursor: pointer; transition: background .18s; }
#chat-send-btn:hover { background: #0b3e2c; }
#chat-send-btn svg { width: 19px; height: 19px; }
#eshop-chat-widget .chat-footer { flex-shrink: 0; padding: 5px 16px 12px; background: #fff; color: #7b887e; text-align: center; font-size: 9px; }
#chat-body .chat-form-card { width: 100%; max-width: 100%; padding: 20px; border-radius: 16px; }
#chat-body .chat-form-icon { display: grid; place-items: center; width: 36px; height: 36px; margin-bottom: 12px; border-radius: 11px; background: #edf5ef; color: #276643; }
#chat-body .chat-form-card > p { margin: 8px 0 16px; color: #6a7b6e; font-size: 12px; }
#chat-body .chat-form label { display: block; margin-bottom: 12px; color: #395142; font-size: 11px; font-weight: 600; }
#chat-body .chat-form input, #chat-body .chat-form textarea { display: block; width: 100%; min-height: 42px; margin: 5px 0 0; padding: 10px 12px; border: 1px solid #dce5dc; border-radius: 9px; background: #fafcf9; color: #243f30; font-size: 13px; box-shadow: none; }
#chat-body .chat-form textarea { min-height: 72px; resize: vertical; }
#chat-body .chat-form input:focus, #chat-body .chat-form textarea:focus { outline: 2px solid #94bba5; outline-offset: 1px; }
#chat-body .chat-form-actions { display: flex; gap: 8px; }
#chat-body .chat-primary-btn, #chat-body .chat-secondary-btn { min-height: 42px; padding: 9px 17px; border: 1px solid #14573f; border-radius: 9px; background: #14573f; color: #fff; font-size: 12px; font-weight: 600; cursor: pointer; }
#chat-body .chat-secondary-btn { border-color: #dce5dc; background: #fff; color: #5c6f60; }
#chat-body .chat-form-status { margin: 8px 0 0; color: #9a402e; font-size: 11px; }
#chat-body .chat-form-help { display: inline-block; margin-top: 10px; color: #527e60; font-size: 11px; }
#chat-body .chat-result-heading { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; color: #316e4c; }
#chat-body .chat-result-heading h3 { font-size: 16px; }
#chat-body .chat-order-card { padding: 16px; margin-top: 10px; border: 1px solid #e0e8e1; border-radius: 14px; background: #fff; }
#chat-body .chat-order-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 6px; font-size: 12px; }
#chat-body .chat-status-badge { display: inline-block; padding: 4px 8px; border-radius: 6px; background: #f8f0dc; color: #7b6226; font-size: 10px; font-weight: 500; }
#chat-body .chat-status-badge.is-delivered { background: #e6f3e8; color: #2f7248; }
#chat-body .chat-order-date { display: block; margin-top: 5px; color: #728174; font-size: 10px; }
#chat-body .chat-order-items, #chat-body .chat-order-remarks { margin: 10px 0 0; font-size: 12px; color: #64766a; }
#chat-body .chat-order-total { display: flex; justify-content: space-between; margin-top: 12px; padding-top: 10px; border-top: 1px solid #eef1ec; font-size: 11px; }
#chat-body .chat-order-total strong { color: #214d34; font-size: 13px; }
#chat-body .chat-order-timeline { padding: 0; margin: 16px 0 0; list-style: none; }
#chat-body .chat-order-timeline li { position: relative; display: flex; align-items: center; gap: 10px; min-height: 29px; color: #7f8b81; font-size: 11px; }
#chat-body .chat-order-timeline li:not(:last-child)::after { content: ''; position: absolute; left: 7px; top: 22px; height: 14px; width: 1px; background: #dfe7df; }
#chat-body .chat-step-dot { display: grid; place-items: center; z-index: 1; width: 15px; height: 15px; border: 1px solid #d1ddd2; border-radius: 50%; background: #fff; }
#chat-body .chat-step-dot svg { width: 11px; height: 11px; }
#chat-body .chat-order-timeline .is-done { color: #50775c; }
#chat-body .chat-order-timeline .is-done .chat-step-dot { border-color: #79aa8a; background: #eaf4ec; }
#chat-body .chat-order-timeline .is-current { color: #205e38; font-weight: 600; }
#chat-body .chat-order-timeline .is-current .chat-step-dot { background: #397b50; border: 4px solid #deece1; }
#chat-body .chat-rewards-card { padding: 24px; border: 1px solid #d9e7d9; border-radius: 16px; background: linear-gradient(135deg, #eef6ef, #fafbf6); text-align: center; }
#chat-body .chat-rewards-card > span { color: #64826b; font-size: 10px; letter-spacing: .12em; }
#chat-body .chat-rewards-card > strong { display: block; margin: 8px 0; color: #1e5737; font-size: 42px; line-height: 1.1; letter-spacing: -2px; }
#chat-body .chat-rewards-card p { margin: 8px 0 0; font-size: 11px; color: #6a7d6e; }
#chat-body .chat-thinking { padding: 13px 17px; }
#chat-body .chat-typing { display: flex; align-items: center; gap: 4px; height: 12px; }
#chat-body .chat-typing > span { width: 5px; height: 5px; border-radius: 50%; background: #89a794; animation: chat-dot-pulse 1.2s infinite; }
#chat-body .chat-typing > span:nth-child(2) { animation-delay: .15s; }
#chat-body .chat-typing > span:nth-child(3) { animation-delay: .3s; }
#eshop-chat-widget .chat-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.fab svg { width: 27px; height: 27px; }
@keyframes chat-dot-pulse { 0%, 60%, 100% { opacity: .45; } 30% { opacity: 1; } }

/* Maintenance */
#maintenance-overlay {
    display: none; position: fixed; inset: 0; z-index: 99999; padding: 20px;
    flex-direction: column; justify-content: center; align-items: center; text-align: center;
    background: var(--brand-900); color: #fff;
}
#maintenance-overlay h1 { margin-bottom: 1rem; font-size: 3rem; color: var(--gold-500); }


/* ==========================================================================
   6  CART MODAL   (checkout dialog on the shop)
   ========================================================================== */
#cart-modal {
    display: none; position: fixed; z-index: 99999; left: 0; top: 0; width: 100%; height: 100%;
    justify-content: center; align-items: center; padding: 15px; box-sizing: border-box;
    background-color: rgba(3, 40, 30, .55);
    -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px);
}
#cart-modal .modal-content {
    background: #ffffff !important;
    width: 100% !important; max-width: 480px !important; max-height: 88vh !important;
    overflow-y: auto !important;
    display: flex !important; flex-direction: column !important;
    padding: 18px 22px !important; margin: auto;
    border-radius: 16px !important; box-shadow: var(--shadow-lg) !important; box-sizing: border-box !important;
}
#cart-modal .modal-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 0 0 12px; margin-bottom: 12px; background: transparent;
    border-bottom: 1px solid #eef2f5;
}
#cart-modal .modal-header h2 { margin: 0 !important; font-size: 1.25rem !important; font-weight: 700 !important; color: var(--brand-900) !important; }
#cart-modal .close { background: transparent; border: none; font-size: 1.6rem; line-height: 1; color: #64748b; cursor: pointer; }

#cart-modal .cart-scroll-area { flex: 1; overflow-y: auto; padding: 16px 22px; }
#cart-modal #cart-items { display: flex; flex-direction: column; gap: 12px; margin-bottom: 15px; }

#cart-modal .cart-item { display: flex; align-items: center; gap: 12px; padding: 10px; margin: 0; background: #f8faf9; border: 1px solid #e5ece8; border-radius: 10px; }
#cart-modal .cart-item-image { width: 52px; height: 52px; object-fit: cover; background: #fff; border-radius: 6px; padding: 0; border: none; }
#cart-modal .cart-item-details { display: flex; flex: 1; flex-direction: column; gap: 4px; }
#cart-modal .cart-item-details strong { font-size: .88rem; line-height: 1.2; color: #1e293b; }
#cart-modal .quantity-controls { display: inline-flex; align-items: center; gap: 8px; margin: 0; padding: 2px 6px; width: fit-content; background: #fff; border: 1px solid #d1d5db; border-radius: 6px; }
#cart-modal .quantity-btn { width: auto; height: auto; padding: 0 4px; background: none; border: none; border-radius: 0; font-weight: bold; font-size: 1rem; color: var(--brand-900); }
#cart-modal .quantity-btn:hover { background: none; color: var(--gold-600); }
#cart-modal .remove-item-btn { padding: 4px; background: none; border: none; font-size: .95rem; color: #dc2626; cursor: pointer; }

#cart-modal .modal-footer { margin-top: 10px; padding: 10px 0 6px; background: transparent; border-top: 1px dashed #cbd5e1; }
#cart-modal .summary-line { margin-bottom: 3px; font-size: .88rem; color: #475569; }
#cart-modal .summary-line.total { margin-top: 4px; padding-top: 6px; border-top: none; font-family: var(--font-body); font-size: 1.1rem; font-weight: bold; color: var(--brand-900); }

.customer-info-form { margin-top: 10px; padding: 12px; background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 10px; }
.customer-info-form h3 { margin: 0 0 8px !important; font-family: var(--font-body); font-size: .8rem !important; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--brand-900) !important; }
.cart-input-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.customer-info-form input, .customer-info-form textarea {
    width: 100% !important; padding: 7px 10px !important; margin-bottom: 8px !important;
    font-size: .82rem !important; color: #1e293b !important;
    background: #ffffff !important; border: 1px solid #cbd5e1 !important; border-radius: 6px !important; box-sizing: border-box !important;
}
.customer-info-form textarea { height: 48px !important; min-height: 0; margin-top: 6px !important; resize: none !important; }
.customer-info-form input:focus, .customer-info-form textarea:focus { border-color: var(--brand-900) !important; box-shadow: none; }

.cart-submit-wrap { padding: 12px 22px 18px; background: #fafbfc; border-top: 1px solid #eef0f2; }
.cart-submit-wrap .btn-primary { padding: 12px !important; font-size: .95rem !important; font-weight: 600; border-radius: 8px; cursor: pointer; }
.cart-submit-btn-area { margin-top: 12px; padding-bottom: 4px; }
.cart-submit-btn-area button {
    width: 100% !important; padding: 11px !important;
    font-size: .95rem !important; font-weight: 600 !important; letter-spacing: 0; text-transform: none;
    background: var(--brand-900) !important; color: #ffffff !important;
    border: none !important; border-radius: 8px !important; cursor: pointer !important; transition: background .2s;
}
.cart-submit-btn-area button:hover { background: var(--brand-950) !important; }


/* ==========================================================================
   7  RESPONSIVE & ACCESSIBILITY
   ========================================================================== */
@media (max-width: 1000px) {
    #order-creation-workflow, #shop-workflow { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
    body { font-size: 14.5px; }
    .card { padding: 22px 18px; }
    .modal-header, .modal-body, .modal-footer { padding-left: 18px; padding-right: 18px; }
    .dynamic-content-wrapper { padding: 1.6rem 1.2rem; }
    body.portal #portal-view { padding: 18px 14px 48px; }
    body.portal header { flex-direction: column; align-items: stretch; text-align: center; }
    body.portal header > div:last-child { flex-direction: row; justify-content: center; }
    body.portal nav .btn { flex: 1 1 46%; }
    .open-order-card { flex-direction: column; align-items: stretch; }
    .form-row, .order-grid { grid-template-columns: 1fr; }
    .header-content { flex-direction: column; gap: 10px; }
    body.shop nav a { padding: 14px 14px; font-size: .74rem; }
    .fab-container { right: 16px; bottom: 16px; }
    #eshop-chat-widget { right: 12px; left: auto; width: min(420px, calc(100vw - 24px)); bottom: max(88px, env(safe-area-inset-bottom)); height: min(690px, calc(100dvh - 112px)); border-radius: 20px; }
    #chat-body .chat-form input, #chat-body .chat-form textarea, #chat-input { font-size: 16px; }
    table { display: block; overflow-x: auto; white-space: nowrap; }
    .product-image-container { height: 220px; }
}
@media (max-width: 480px) {
    .cart-input-grid { grid-template-columns: 1fr; }
    body.portal #login-box { padding: 34px 22px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
@media print {
    body { background: #fff; }
    nav, .fab-container, #eshop-chat-widget, .btn { display: none !important; }
    .card { box-shadow: none; border: 1px solid #ddd; }
}


/* ===== Customer account: tracker, orders, rewards (v2.1) ===== */
body.portal .login-links { text-align:center; font-size:.85rem; margin-top:14px; color:var(--ink-500); }
body.portal .login-links a { color:var(--emerald-700,#064e3b); font-weight:600; }
body.portal .login-links span { margin:0 8px; }
body.portal .form-status { min-height:1.3em; margin-top:10px; font-size:.88rem; font-weight:500; }
body.portal #reset-status { text-align:center; min-height:1.4em; margin-top:12px; font-size:.88rem; font-weight:500; }
.order-card { margin-bottom:16px; }
.order-top { display:flex; justify-content:space-between; align-items:center; gap:10px; flex-wrap:wrap; }
.order-no { font-family:'Playfair Display',serif; font-size:1.1rem; }
.order-date { margin-left:10px; color:var(--ink-500); font-size:.85rem; }
.order-items-line { margin:8px 0; font-size:.9rem; color:var(--ink-700,#333); }
.order-items-line i { color:var(--gold-500,#d4af37); margin-right:8px; width:16px; }
.order-bottom { display:flex; justify-content:space-between; align-items:flex-end; gap:12px; flex-wrap:wrap; margin-top:12px; padding-top:12px; border-top:1px solid var(--line,#e5e7eb); }
.order-total span { display:block; font-size:.75rem; text-transform:uppercase; letter-spacing:.08em; color:var(--ink-500); }
.order-total strong { font-size:1.25rem; }
.order-total small { display:block; color:var(--ink-500); font-size:.78rem; }
.order-total small.pts { color:var(--ok); font-weight:600; }
.order-actions { display:flex; gap:8px; flex-wrap:wrap; }
.tracker { list-style:none; display:flex; margin:18px 0 8px; padding:0; }
.tracker li { flex:1; text-align:center; position:relative; font-size:.74rem; color:var(--ink-500); }
.tracker li::before { content:''; position:absolute; top:13px; left:-50%; width:100%; height:3px; background:#e5e7eb; z-index:0; }
.tracker li:first-child::before { display:none; }
.tracker li.done::before, .tracker li.now::before { background:var(--ok); }
.tracker .dot { position:relative; z-index:1; display:inline-flex; width:28px; height:28px; border-radius:50%; background:#e5e7eb; color:#6b7280; align-items:center; justify-content:center; font-weight:700; font-size:.75rem; }
.tracker li.done .dot { background:var(--ok); color:#fff; }
.tracker li.now .dot { background:var(--gold-500,#d4af37); color:#053f31; box-shadow:0 0 0 4px rgba(212,175,55,.25); }
.tracker li.now .lbl { color:#053f31; font-weight:700; }
.tracker .lbl { display:block; margin-top:6px; }
.rewards-hero { display:flex; justify-content:space-between; align-items:center; gap:20px; flex-wrap:wrap; background:linear-gradient(135deg,#064e3b,#053f31); color:#fff; }
.rewards-hero .stat-label { color:#d4af37; text-transform:uppercase; letter-spacing:.1em; font-size:.75rem; }
.rewards-hero .field-hint { color:#cfe8dd; margin:6px 0 0; }
.points-big { font-family:'Playfair Display',serif; font-size:3.2rem; color:#fff; line-height:1.1; }
.redeem-soon { background:rgba(255,255,255,.1); border:1px dashed #d4af37; padding:14px 18px; border-radius:12px; max-width:280px; display:flex; flex-direction:column; gap:4px; font-size:.85rem; }
.redeem-soon i { color:#d4af37; font-size:1.3rem; }
@media (max-width:600px){ .tracker li .lbl{font-size:.62rem} .tracker li::before{top:13px} }


/* ==========================================================================
   LUXURY LAYER  (v3.0)  — onyx emerald, champagne gold, ivory marble
   Sits on top of everything above and wins by coming last.
   ========================================================================== */
:root {
    --onyx: #07120f;
    --onyx-2: #0c1e18;
    --gold-300: #f1dc94;
    --gold-400: #e4c566;
    --gold-grad: linear-gradient(135deg, #f6e7a8 0%, #dcb94f 38%, #b8932a 70%, #e8cf7a 100%);
    --gold-line: linear-gradient(90deg, transparent, #d4af37 20%, #f1dc94 50%, #d4af37 80%, transparent);
    --emerald-grad: linear-gradient(160deg, #0b5a44 0%, #064e3b 45%, #03281e 100%);
    --ivory: #faf7ee;
    --line: #ece6d4;
    --line-soft: #f3eedf;
    --hairline-gold: 1px solid rgba(212, 175, 55, .35);
    --shadow-md: 0 14px 34px rgba(7, 18, 15, .10);
    --shadow-lg: 0 30px 70px -18px rgba(7, 18, 15, .45);
    --glow-gold: 0 0 0 1px rgba(212, 175, 55, .5), 0 14px 34px rgba(184, 147, 42, .22);
    --ring: 0 0 0 3px rgba(212, 175, 55, .3);
}

html { scroll-behavior: smooth; }
body { background: var(--ivory); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
h1, h2, h3, h4 { letter-spacing: .01em; }
::selection { background: var(--gold-300); color: var(--onyx); }
::-webkit-scrollbar { width: 11px; }
::-webkit-scrollbar-track { background: var(--ivory); }
::-webkit-scrollbar-thumb { background: linear-gradient(var(--gold-400), var(--gold-600)); border-radius: 8px; border: 2px solid var(--ivory); }

/* ---- Buttons ---- */
.btn { border-radius: 4px; letter-spacing: .14em; font-weight: 600; position: relative; overflow: hidden; }
.btn-primary { background: var(--emerald-grad); color: var(--gold-300); border: 1px solid rgba(212, 175, 55, .55); box-shadow: 0 8px 20px rgba(3, 40, 30, .32), inset 0 1px 0 rgba(255, 255, 255, .12); }
.btn-primary:hover:not(:disabled) { color: #fff; border-color: var(--gold-400); box-shadow: 0 12px 28px rgba(3, 40, 30, .4), 0 0 0 3px rgba(212, 175, 55, .18); }
.btn-gold { background: var(--gold-grad); color: var(--onyx); border: 1px solid #b8932a; box-shadow: 0 8px 20px rgba(184, 147, 42, .35), inset 0 1px 0 rgba(255, 255, 255, .5); text-shadow: 0 1px 0 rgba(255, 255, 255, .35); }
.btn-gold:hover:not(:disabled) { color: var(--onyx); box-shadow: 0 12px 28px rgba(184, 147, 42, .45); }
.btn-secondary { background: #fff; color: var(--brand-900); border: 1px solid rgba(212, 175, 55, .45); }
.btn-secondary:hover:not(:disabled) { background: var(--onyx); color: var(--gold-300); border-color: var(--onyx); }
.btn::after { content: ''; position: absolute; top: 0; left: -120%; width: 60%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .28), transparent); transform: skewX(-20deg); transition: left .7s var(--ease); pointer-events: none; }
.btn:hover:not(:disabled)::after { left: 130%; }

/* ---- Cards, forms, tables ---- */
.card { border: 1px solid rgba(212, 175, 55, .22); border-radius: 14px; box-shadow: 0 10px 30px rgba(7, 18, 15, .06); }
.card::before { height: 2px; left: 0; right: 0; border-radius: 14px 14px 0 0; background: var(--gold-line); opacity: 1; }
input, select, textarea { background: #fffefa; border: 1px solid #e3dcc6; border-radius: 6px; }
input:focus, select:focus, textarea:focus { border-color: var(--gold-500) !important; box-shadow: var(--ring) !important; background: #fff; }
table thead th, table th { background: var(--onyx-2); color: var(--gold-300); letter-spacing: .12em; font-size: .7rem; border-bottom: 2px solid var(--gold-500); }
table tbody tr:hover { background: #fcf9ee; }
.badge { letter-spacing: .08em; border: 1px solid rgba(0, 0, 0, .05); }
.modal-content { border: 1px solid rgba(212, 175, 55, .45); border-radius: 14px; box-shadow: var(--shadow-lg); }
.modal-header { background: var(--emerald-grad); color: var(--gold-300); border-bottom: 2px solid var(--gold-500); }
.modal-header h2, .modal-header h3 { color: var(--gold-300); }
.modal-header .close, .modal-header .close:hover { color: var(--gold-300); }

/* ==========================================================================
   SHOP
   ========================================================================== */
body.shop { background: radial-gradient(900px 500px at 50% -10%, #fffdf5 0%, var(--ivory) 60%); }

body.shop header {
    position: relative; padding: 34px 0 30px; color: #fff;
    background:
        radial-gradient(520px 220px at 50% 0%, rgba(212, 175, 55, .20), transparent 70%),
        linear-gradient(180deg, #0a3d30 0%, #062b21 60%, #04201a 100%);
    border-bottom: none;
}
body.shop header::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--gold-line); }
body.shop header::before { content: ''; position: absolute; inset: 10px; border: 1px solid rgba(212, 175, 55, .22); border-radius: 6px; pointer-events: none; }
.header-content { gap: 26px; }
.header-logo { width: 88px; height: 88px; border: 2px solid var(--gold-500); padding: 3px; background: #fff; box-shadow: 0 0 0 6px rgba(212, 175, 55, .14), 0 10px 30px rgba(0, 0, 0, .45); }
#company-name-header { font-size: clamp(1.7rem, 4vw, 2.9rem); font-weight: 600; letter-spacing: .04em; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent; text-shadow: none; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .35)); }
#company-name-header .by-line { color: var(--gold-300); -webkit-text-fill-color: var(--gold-300); letter-spacing: .38em; font-size: .72rem; font-weight: 500; }
#company-name-header .slogan { color: rgba(255, 255, 255, .72); -webkit-text-fill-color: rgba(255, 255, 255, .72); letter-spacing: .06em; font-size: .85rem; }

#promo-running-banner { background: linear-gradient(90deg, #07120f, #0c2a22 50%, #07120f); color: var(--gold-300); border-bottom: 1px solid rgba(212, 175, 55, .35); letter-spacing: .12em; text-transform: uppercase; font-size: .74rem; }

body.shop nav { background: rgba(7, 18, 15, .94); border-bottom: 1px solid rgba(212, 175, 55, .35); box-shadow: 0 12px 30px rgba(0, 0, 0, .25); }
body.shop nav a { color: rgba(255, 255, 255, .82); font-size: .74rem; letter-spacing: .22em; }
body.shop nav a::after { background: var(--gold-grad); height: 2px; }
body.shop nav a:hover { color: var(--gold-300); }
.nav-login-btn { background: var(--gold-grad) !important; color: var(--onyx) !important; font-weight: 700 !important; border-radius: 3px !important; box-shadow: 0 6px 18px rgba(212, 175, 55, .3) !important; }
.nav-login-btn:hover { background: #fff !important; color: var(--onyx) !important; }

body.shop main { padding: 3.2rem 0 4rem; }

.hero-section {
    position: relative; padding: 120px 28px; border-radius: 6px; overflow: hidden; border: 1px solid rgba(212, 175, 55, .45);
    background:
        radial-gradient(700px 320px at 50% 0%, rgba(212, 175, 55, .24), transparent 70%),
        linear-gradient(rgba(4, 32, 26, .88), rgba(4, 32, 26, .8)),
        url('https://images.unsplash.com/photo-1544367563-12123d8965cd?q=80&w=2070&auto=format&fit=crop') center / cover;
    box-shadow: 0 30px 70px -20px rgba(3, 40, 30, .6);
}
.hero-section::before { content: ''; position: absolute; inset: 14px; border: 1px solid rgba(212, 175, 55, .4); pointer-events: none; }
.hero-section::after { content: '\2726'; position: absolute; top: 22px; left: 50%; transform: translateX(-50%); color: var(--gold-400); font-size: 1rem; background: transparent; letter-spacing: 0; }
.hero-section h2 { font-size: clamp(2.2rem, 5.5vw, 3.8rem); font-weight: 600; letter-spacing: .06em; background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.hero-section p { letter-spacing: .08em; font-weight: 300; font-size: 1.1rem; }

/* gold-rule section headings */
.tab-content > h2, .dynamic-content-wrapper > h2, #about-us-content > h2, .view > h2 { text-align: center; position: relative; padding-bottom: 20px; margin-bottom: 2rem; color: var(--brand-900); font-weight: 600; }
.tab-content > h2::after, .dynamic-content-wrapper > h2::after, #about-us-content > h2::after, .view > h2::after { content: ''; position: absolute; left: 50%; bottom: 0; width: 120px; height: 2px; transform: translateX(-50%); background: var(--gold-line); }
.tab-content > h2::before, .dynamic-content-wrapper > h2::before { content: '\25C6'; position: absolute; left: 50%; bottom: -7px; transform: translateX(-50%); font-size: .55rem; color: var(--gold-500); background: var(--ivory); padding: 0 8px; z-index: 1; }
.view > h2 { text-align: left; } .view > h2::after { left: 0; transform: none; width: 90px; } .view > h2::before { display: none; }

.dynamic-content-wrapper { border: 1px solid rgba(212, 175, 55, .22); border-radius: 8px; box-shadow: 0 14px 40px rgba(7, 18, 15, .06); background: linear-gradient(180deg, #fff, #fffdf7); }
.why-choose-us-grid i { background: var(--onyx-2); color: var(--gold-400); box-shadow: 0 0 0 4px rgba(212, 175, 55, .22), 0 10px 22px rgba(0, 0, 0, .2); }
.testimony-card { border-top: none; border: 1px solid rgba(212, 175, 55, .3); position: relative; border-radius: 8px; }
.testimony-card::before { content: '\201C'; position: absolute; top: -6px; left: 18px; font-family: var(--font-heading); font-size: 4.5rem; color: rgba(212, 175, 55, .35); line-height: 1; }
.about-section { border-left: 3px solid var(--gold-500); border-radius: 0 8px 8px 0; background: linear-gradient(90deg, #fffdf5, #fff); }
.owner-image { border: 4px solid #fff; box-shadow: 0 0 0 2px var(--gold-500), 0 20px 40px rgba(0, 0, 0, .18); }
.job-header { background: var(--emerald-grad); border-bottom: 2px solid var(--gold-500); }
.job-card { border: 1px solid rgba(212, 175, 55, .25); border-radius: 8px; }

/* ---- Products ---- */
.product { border: 1px solid rgba(212, 175, 55, .28); border-radius: 8px; background: #fff; box-shadow: 0 8px 24px rgba(7, 18, 15, .06); }
.product::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--gold-line); transform: scaleX(0); transition: transform .5s var(--ease); }
.product:hover { transform: translateY(-10px); border-color: var(--gold-500); box-shadow: 0 26px 50px -12px rgba(7, 18, 15, .25), 0 0 0 1px rgba(212, 175, 55, .55); }
.product:hover::after { transform: scaleX(1); }
.product-image-container { background: radial-gradient(circle at 50% 38%, #ffffff 0%, #f7f2e2 100%); border-bottom: 1px solid var(--line-soft); }
.product-tag { border-radius: 2px; background: var(--onyx); color: var(--gold-300); letter-spacing: .16em; border: 1px solid var(--gold-500); font-size: .62rem; }
.product h3 { font-size: 1.12rem; letter-spacing: .03em; }
.new-price { color: var(--brand-900); font-size: 1.55rem; }
.new-price::before { content: ''; display: block; width: 36px; height: 1px; margin: 0 auto 8px; background: var(--gold-500); }

body.shop footer { background: linear-gradient(180deg, #062b21, #03170f); color: rgba(255, 255, 255, .7); border-top: none; position: relative; letter-spacing: .06em; font-size: .86rem; }
body.shop footer::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--gold-line); }
body.shop footer a { color: var(--gold-300); text-decoration: none; border-bottom: 1px solid rgba(212, 175, 55, .4); }

.fab { background: var(--onyx); border: 2px solid var(--gold-500); color: var(--gold-300); box-shadow: 0 12px 28px rgba(0, 0, 0, .4), 0 0 0 5px rgba(212, 175, 55, .14); }
.fab:hover { background: var(--gold-grad); color: var(--onyx); }
#cart-count { background: var(--gold-grad); color: var(--onyx); border-color: var(--onyx); }
body.shop .modal { background: rgba(4, 22, 17, .72); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }

/* ==========================================================================
   PORTALS  (agent + customer)
   ========================================================================== */
body.portal { background: radial-gradient(900px 480px at 50% -10%, #fffdf5, var(--ivory) 60%); }
body.portal #login-view {
    background:
        radial-gradient(640px 380px at 12% 8%, rgba(212, 175, 55, .28), transparent 62%),
        radial-gradient(700px 480px at 92% 98%, rgba(16, 185, 129, .22), transparent 62%),
        linear-gradient(150deg, #04201a 0%, #07120f 100%);
}
body.portal #login-box { border: 1px solid rgba(212, 175, 55, .5); border-radius: 10px; background: linear-gradient(180deg, #fffefa, #faf6ea); box-shadow: 0 40px 90px -20px rgba(0, 0, 0, .65), 0 0 0 8px rgba(212, 175, 55, .08); }
body.portal #login-box::before { left: 0; right: 0; height: 3px; border-radius: 10px 10px 0 0; background: var(--gold-line); }
body.portal #login-box img { box-shadow: 0 0 0 7px rgba(212, 175, 55, .16), 0 10px 26px rgba(0, 0, 0, .25); }
body.portal #login-box h1 { letter-spacing: .04em; color: var(--brand-900); }
body.portal #login-box a { color: var(--brand-800); }

body.portal header { border-bottom: 1px solid rgba(212, 175, 55, .35); position: relative; }
body.portal header::after { content: ''; position: absolute; left: 0; bottom: -1px; width: 120px; height: 2px; background: var(--gold-grad); }
body.portal header h2 { color: var(--brand-900); font-weight: 600; }

body.portal nav { background: var(--onyx); border: 1px solid rgba(212, 175, 55, .4); border-radius: 8px; box-shadow: 0 14px 34px rgba(7, 18, 15, .25); }
body.portal nav .btn { color: rgba(255, 255, 255, .72); letter-spacing: .16em; border-radius: 5px; }
body.portal nav .btn i { color: rgba(212, 175, 55, .6); }
body.portal nav .btn:hover:not(.active):not(:disabled) { background: rgba(212, 175, 55, .12); color: var(--gold-300); }
body.portal nav .btn.active { background: var(--gold-grad); color: var(--onyx); box-shadow: 0 6px 18px rgba(212, 175, 55, .35); }
body.portal nav .btn.active i { color: var(--onyx); }

.stat-box { border: 1px solid rgba(212, 175, 55, .3); border-radius: 10px; background: linear-gradient(180deg, #fff, #fffaf0); }
.open-order-card { border-left: 4px solid var(--gold-500); border-radius: 8px; }

/* order tracker & rewards */
.tracker .dot { background: #eee8d6; }
.tracker li.done .dot { background: var(--emerald-grad); color: var(--gold-300); box-shadow: 0 0 0 1px var(--gold-500); }
.tracker li.now .dot { background: var(--gold-grad); color: var(--onyx); box-shadow: 0 0 0 5px rgba(212, 175, 55, .28); }
.tracker li.done::before, .tracker li.now::before { background: linear-gradient(90deg, var(--brand-700), var(--gold-500)); }
.order-card { border-left: 4px solid var(--gold-500); }
.rewards-hero { background: radial-gradient(500px 220px at 85% 0%, rgba(212, 175, 55, .3), transparent 70%), linear-gradient(150deg, #0a3d30, #04201a); border: 1px solid var(--gold-500); border-radius: 12px; box-shadow: 0 24px 50px -16px rgba(3, 40, 30, .6); }
.points-big { background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; font-size: 3.8rem; }
.redeem-soon { border: 1px dashed var(--gold-400); background: rgba(212, 175, 55, .08); }

@media (max-width: 720px) {
    body.shop header::before { inset: 6px; }
    .hero-section { padding: 80px 18px; }
    .hero-section::before { inset: 8px; }
    .header-logo { width: 64px; height: 64px; }
}
@media print { .btn::after { display: none; } }

/* Catalog discovery and confirmed checkout */
.section-eyebrow { display: block; margin-bottom: 10px; color: var(--gold-600); font-size: .68rem; font-weight: 700; letter-spacing: .16em; }
.catalog-heading { padding: 28px 0 18px; }
.catalog-heading h2 { margin: 0 0 8px; font-size: clamp(1.6rem, 4vw, 2.4rem); }
.catalog-heading p { margin: 0; color: var(--ink-500); }
.catalog-toolbar { display: grid; grid-template-columns: minmax(180px, 2fr) minmax(140px, 1fr) minmax(150px, 1fr) auto; align-items: end; gap: 14px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.catalog-toolbar label { margin: 0; font-size: .76rem; font-weight: 600; color: var(--ink-500); }
.catalog-toolbar input, .catalog-toolbar select { width: 100%; margin: 7px 0 0; font-size: 16px; }
.catalog-toolbar .btn { margin: 0; min-height: 46px; }
#catalog-count { padding: 14px 2px; margin: 0; font-size: .8rem; color: var(--ink-500); }
.catalog-empty { padding: 48px 24px; text-align: center; background: #fff; border: 1px dashed var(--line); border-radius: 14px; }
.retry-catalog { margin: 14px auto; }
#rewards-content { margin-top: 28px; }
.rewards-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 28px 0; }
.rewards-steps article { padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--ivory); }
.rewards-steps article > span { color: var(--gold-600); font-size: .8rem; font-weight: 700; }
.rewards-steps h3 { margin: 12px 0 8px; font-size: 1.1rem; }
.rewards-steps p { margin: 0; color: var(--ink-500); font-size: .88rem; }
.rewards-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.checkout-status { margin: 0 0 10px; color: var(--bad); font-size: .82rem; }
.checkout-status:empty { display: none; }
.checkout-status a { text-decoration: underline; }
.order-confirmation { max-width: 800px; margin: 38px auto; padding: clamp(24px, 5vw, 48px); background: #fff; border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow-sm); }
.confirmation-mark { display: grid; place-items: center; width: 58px; height: 58px; margin-bottom: 24px; background: var(--ok-bg); color: var(--ok); border-radius: 50%; font-size: 26px; }
.order-confirmation h2 { margin: 0 0 12px; font-size: clamp(1.8rem, 4vw, 2.5rem); }
.confirmation-total { padding: 22px; margin: 24px 0; border-radius: 12px; background: var(--ivory); }
.confirmation-total > span, .confirmation-total small { display: block; color: var(--ink-500); font-size: .82rem; }
.confirmation-total > strong { display: block; font-size: 1.8rem; color: var(--brand-800); }
.confirmation-next h3 { font-size: 1.2rem; }
.confirmation-next ol { padding-left: 22px; color: var(--ink-500); }
.confirmation-next li { padding: 6px 0; }
.order-status-note { padding: 12px; background: var(--ivory); border-radius: 8px; }
.static-product { max-width: 1100px; margin: 0 auto; padding: 32px 20px; }
.static-product nav { position: static; margin: 20px 0; padding: 12px; }
.static-product-list { list-style: none; padding: 0; }
.static-product-list li { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; padding: 16px; border-bottom: 1px solid var(--line); }
.static-product-list span { color: var(--ink-500); font-size: .85rem; }
@media (max-width: 760px) { .catalog-toolbar { grid-template-columns: 1fr 1fr; } .catalog-toolbar label:first-child { grid-column: 1 / -1; } .rewards-steps { grid-template-columns: 1fr; } .rewards-actions .btn { width: 100%; } }
@media (max-width: 390px) { .catalog-toolbar { grid-template-columns: 1fr; } }

/* Product layout previously injected by script.js; shared with static product pages. */

/* product grid: 5 per row on desktop, stepping down on smaller screens */
.product-list { display: grid !important; grid-template-columns: repeat(5, minmax(0, 1fr)) !important; gap: 16px !important; align-items: stretch; }
@media (max-width: 1280px) { .product-list { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; } }
@media (max-width: 1024px) { .product-list { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; } }
@media (max-width: 720px)  { .product-list { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 10px !important; } }
@media (max-width: 330px)  { .product-list { grid-template-columns: 1fr !important; } }
.product-list .product { display: flex !important; flex-direction: column; width: auto !important; max-width: none !important; margin: 0 !important;
    position: relative; cursor: pointer; background: #fff; border-radius: 14px; overflow: hidden;
    box-shadow: 0 4px 14px rgba(0,0,0,.08); transition: transform .25s ease, box-shadow .25s ease; }
.product-list .product:hover, .product-list .product:focus-visible { transform: translateY(-5px); box-shadow: 0 14px 28px rgba(0,0,0,.16); outline: none; }
.product-list .product-image-container { position: relative; width: 100%; aspect-ratio: 1 / 1; overflow: hidden; background: #f4f7f5;
    display: flex; align-items: center; justify-content: center; }
.product-list .product-image-container img { width: 100%; height: 100%; object-fit: contain; transition: transform .4s ease; }
.product-list .product:hover .product-image-container img { transform: scale(1.06); }
.product-list .product-info { display: flex; flex-direction: column; flex: 1; padding: 10px 12px 12px; gap: 6px; }
.product-list .product-info h3 { margin: 0; font-size: .92rem; line-height: 1.3; min-height: 2.6em; display: -webkit-box;
    -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-list .price-section { font-size: 1rem; font-weight: 800; }
.product-list .product-benefits { font-size: .78rem; line-height: 1.4; color: #475569; display: -webkit-box;
    -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.product-list .product-consumption { display: none !important; }
.product-list .product-more { font-size: .76rem; font-weight: 700; color: var(--primary-color, #113626); }
.product-list .product-actions { margin-top: auto; }
.product-list .product-actions .btn { width: 100%; padding: 8px 10px; font-size: .82rem; }

/* YouTube cards */
#youtube-videos-container { display: grid !important; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 22px; }
.yt-item { max-width: 680px; width: 100%; margin: 0 auto; }
.yt-frame { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #0f1a15; box-shadow: 0 8px 24px rgba(0,0,0,.18); }
.yt-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.yt-play { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: pointer; }
.yt-play img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s; }
.yt-play:hover img { transform: scale(1.04); }
.yt-btn { position: absolute; left: 50%; top: 50%; width: 68px; height: 48px; margin: -24px 0 0 -34px; border-radius: 14px; background: rgba(210,20,20,.92); }
.yt-btn::after { content: ''; position: absolute; left: 27px; top: 14px; border-left: 18px solid #fff; border-top: 10px solid transparent; border-bottom: 10px solid transparent; }
.yt-fallback { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 10px;
    padding: 18px; text-align: center; color: #fff; text-decoration: none; font-size: .9rem; line-height: 1.4; }
.yt-fallback .yt-btn { top: 38%; }
.yt-link { display: inline-block; margin-top: 8px; font-size: .85rem; font-weight: 600; color: var(--primary-color, #113626); text-decoration: none; }
.yt-link:hover { text-decoration: underline; }

/* cart: let the whole list show (the modal itself scrolls) */
#cart-items { max-height: none !important; overflow: visible !important; }
#cart-items .cart-item { flex-shrink: 0; }

/* dedicated product page */
.pd-wrap { max-width: 1100px; margin: 0 auto; padding: 18px 14px 30px; }
.pd-crumbs { font-size: .85rem; color: #64748b; margin-bottom: 14px; }
.pd-crumbs a { color: var(--primary-color, #113626); font-weight: 700; text-decoration: none; cursor: pointer; }
.pd-card { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 28px; background: #fff; border-radius: 18px;
    padding: 24px; box-shadow: 0 10px 34px rgba(0,0,0,.1); position: relative; }
.pd-media { position: relative; border-radius: 14px; background: #f4f7f5; aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.pd-media img { width: 100%; height: 100%; object-fit: contain; }
.pd-info h1 { margin: 6px 0 8px; font-size: 1.7rem; line-height: 1.25; color: #10231b; }
.pd-price { font-size: 1.7rem; font-weight: 800; color: var(--primary-color, #113626); margin-bottom: 14px; }
.pd-block { margin: 0 0 14px; padding: 12px 14px; background: #f8fafc; border-left: 4px solid var(--secondary-color, #ffd700); border-radius: 8px; }
.pd-block h3 { margin: 0 0 4px; font-size: .8rem; text-transform: uppercase; letter-spacing: .6px; color: #475569; }
.pd-block p { margin: 0; line-height: 1.65; white-space: pre-line; color: #1f2937; }
.pd-buy { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: 18px 0 12px; }
.pd-qty { display: flex; align-items: center; border: 1px solid #cbd5e1; border-radius: 10px; overflow: hidden; }
.pd-qty button { width: 40px; height: 44px; border: 0; background: #f1f5f9; font-size: 1.2rem; cursor: pointer; }
.pd-qty span { min-width: 44px; text-align: center; font-weight: 700; }
.pd-buy .btn { flex: 1; min-width: 160px; padding: 12px 18px; font-size: 1rem; }
.pd-links { display: flex; gap: 10px; flex-wrap: wrap; }
.pd-links a, .pd-links button { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; border: 1px solid #cbd5e1;
    background: #fff; color: #1f2937; font-size: .85rem; font-weight: 600; text-decoration: none; cursor: pointer; }
.pd-links a:hover, .pd-links button:hover { border-color: var(--primary-color, #113626); color: var(--primary-color, #113626); }
.pd-related h2 { margin: 30px 0 12px; }
.pd-related-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.pd-mini { background: #fff; border-radius: 12px; overflow: hidden; cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.08); transition: transform .2s; }
.pd-mini:hover { transform: translateY(-4px); }
.pd-mini img { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #f4f7f5; display: block; }
.pd-mini div { padding: 8px 10px 10px; font-size: .85rem; font-weight: 600; line-height: 1.3; }
.pd-mini small { display: block; margin-top: 3px; color: var(--primary-color, #113626); font-weight: 800; }
@media (max-width: 820px) {
    .pd-card { grid-template-columns: 1fr; padding: 16px; gap: 16px; }
    .pd-info h1 { font-size: 1.35rem; }
    .pd-related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Guided assistant follow-ups and unobscured conversation. */
#chat-body .chat-help-actions { display: flex; flex-wrap: wrap; gap: 7px; border: 0; background: transparent; padding: 0; max-width: 100%; box-shadow: none; }
#chat-body .chat-help-button { display: inline-block; margin: 9px 5px 0 0; padding: 9px 12px; min-height: 38px; border: 1px solid #cadfd0; border-radius: 9px; background: #f0f7f1; color: #205b38; font-size: 11px; line-height: 1.4; text-align: left; cursor: pointer; }
#chat-body .chat-help-button:hover { background: #dfefe3; border-color: #83af91; }
#chat-body .chat-request-note { display: block; margin-top: 8px; color: #6a7d6e; font-size: 10px; }
body:has(#eshop-chat-widget.active) #fl-fx-canvas { z-index: 999 !important; }
#chat-body .chat-text { white-space: pre-line; }

/* Readable factual order breakdowns inside the assistant. */
#chat-body .chat-order-line-list { list-style: none; margin: 14px 0 0; padding: 0; }
#chat-body .chat-order-line-list li { display: flex; flex-direction: column; gap: 4px; padding: 10px 0; border-bottom: 1px solid #edf1eb; }
#chat-body .chat-order-line-list strong { font-size: 12px; color: #294b36; }
#chat-body .chat-order-line-list span { font-size: 11px; color: #62786a; }
#chat-body .chat-order-facts { margin: 14px 0 0; }
#chat-body .chat-order-facts > div { display: flex; justify-content: space-between; gap: 14px; padding: 8px 0; border-bottom: 1px solid #edf1eb; font-size: 11px; }
#chat-body .chat-order-facts dt { color: #6a7d6e; }
#chat-body .chat-order-facts dd { max-width: 60%; margin: 0; text-align: right; color: #294b36; font-weight: 600; }
#chat-body .chat-order-note { margin: 12px 0 0; color: #62786a; font-size: 11px; }

/* Shared customer account navigation. */
#main-nav li[hidden] { display: none !important; }
body.shop nav .nav-account-action { display: inline-flex; align-items: center; padding: 14px; background: transparent; color: var(--gold-100); border: 1px solid #ffffff35; border-radius: 8px; font: 600 .75rem var(--font-body); letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
body.shop nav .nav-account-action:hover { background: #ffffff12; }
#shop-account-notice { margin-top: 10px; margin-bottom: 0; color: var(--ink-500); font-size: .82rem; }
#shop-account-notice:empty { display: none; }
.cart-account-note { padding: 10px; margin: 0 0 12px; border-radius: 8px; background: #edf5ef; color: #315d3d; font-size: .8rem; }
.cart-account-note a { text-decoration: underline; }
