/* GEAR RENTAL PRO — Premium Monochrome */

:root {
    --grp-bg: #f5f5f5;
    --grp-surface: #fff;
    --grp-surface-2: #fafafa;
    --grp-surface-3: #f0f0f0;
    --grp-border: #e5e5e5;
    --grp-text: #111;
    --grp-text-2: #555;
    --grp-text-muted: #999;
    --grp-black: #111;
    --grp-white: #fff;
    --grp-accent: #111;
    --grp-accent-hover: #333;
    --grp-accent-text: #fff;
    --grp-green: #34a853;
    --grp-red: #d93025;
    --grp-overlay: rgba(0,0,0,0.5);
    --grp-shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --grp-shadow-md: 0 4px 20px rgba(0,0,0,0.08);
    --grp-shadow-lg: 0 12px 40px rgba(0,0,0,0.12);
    --grp-r: 16px;
    --grp-r-sm: 12px;
    --grp-r-xs: 8px;
    --grp-font: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --grp-font-display: 'Instrument Serif', Georgia, serif;
    --grp-t: 0.2s ease;
}
@media (prefers-color-scheme: dark) {
    :root {
        --grp-bg: #000;
        --grp-surface: #1c1c1e;
        --grp-surface-2: #2c2c2e;
        --grp-surface-3: #3a3a3c;
        --grp-border: #48484a;
        --grp-text: #f5f5f7;
        --grp-text-2: #d1d1d6;
        --grp-text-muted: #a1a1a6;
        --grp-black: #f5f5f7;
        --grp-white: #1c1c1e;
        --grp-accent: #f5f5f7;
        --grp-accent-hover: #e5e5ea;
        --grp-accent-text: #000;
        --grp-green: #30d158;
        --grp-red: #ff453a;
        --grp-overlay: rgba(0,0,0,0.7);
        --grp-shadow-sm: none;
        --grp-shadow-md: 0 4px 20px rgba(0,0,0,0.3);
        --grp-shadow-lg: 0 12px 40px rgba(0,0,0,0.4);
    }
}

.grp-app { font-family: var(--grp-font); background: var(--grp-bg); color: var(--grp-text); min-height: 100vh; line-height: 1.5; -webkit-font-smoothing: antialiased; width: 100vw; position: relative; left: 50%; right: 50%; margin-left: -50vw; margin-right: -50vw; overflow-x: hidden; padding-top: 24px; }
.grp-app *, .grp-app *::before, .grp-app *::after { box-sizing: border-box; margin: 0; }
.grp-app img:not(.grp-cart-item-img) { max-width: 100%; height: auto; }
.grp-app input, .grp-app textarea, .grp-app select, .grp-app button { font-family: inherit; }

/* ═══ HEADER ═══ */
.grp-header { position: sticky; top: 0; z-index: 100; background: var(--grp-surface); border-bottom: 1px solid var(--grp-border); backdrop-filter: blur(20px); background: rgba(255,255,255,0.85); }
@media (prefers-color-scheme: dark) { .grp-header { background: rgba(28,28,30,0.92); } }
.grp-header-inner { max-width: 1280px; margin: 0 auto; padding: 10px 24px; min-height: 52px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; }
.grp-header-left { display: flex; align-items: center; flex-shrink: 0; justify-self: start; min-width: 0; }
.grp-logo { font-family: var(--grp-font-display); font-size: 20px; color: var(--grp-text); white-space: nowrap; font-weight: 400; }
.grp-header-center { justify-self: center; display: flex; align-items: center; justify-content: center; gap: 8px; }
.grp-dates { display: flex; align-items: center; gap: 10px; background: var(--grp-surface-2); border: 1px solid var(--grp-border); border-radius: 100px; padding: 6px 20px; }
.grp-date-arrow { color: var(--grp-text-muted); font-size: 16px; }
.grp-date-badge { font-size: 12px; font-weight: 600; white-space: nowrap; background: var(--grp-accent); color: var(--grp-accent-text); padding: 3px 12px; border-radius: 100px; }
.grp-header-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; justify-self: end; min-width: 0; }

/* Search */
.grp-search-wrap { display: flex; align-items: center; gap: 6px; background: var(--grp-surface-2); border: 1px solid var(--grp-border); border-radius: 100px; padding: 8px 16px; width: 220px; max-width: 100%; transition: border-color var(--grp-t), width var(--grp-t); }
.grp-search-wrap:focus-within { border-color: var(--grp-text-muted); width: 280px; }
.grp-search-wrap .material-icons { font-size: 16px; color: var(--grp-text-muted); flex-shrink: 0; }
.grp-search-wrap input { background: transparent !important; border: none !important; box-shadow: none !important; outline: none !important; color: var(--grp-text); font-size: 14px; width: 100%; min-width: 0; padding: 0 !important; margin: 0 !important; height: auto !important; line-height: normal !important; -webkit-appearance: none; appearance: none; }
.grp-search-wrap input::placeholder { color: var(--grp-text-muted); }
.grp-cart-btn { position: relative; background: var(--grp-accent); border: none; border-radius: 100px; width: 36px; height: 36px; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all var(--grp-t); flex-shrink: 0; }
.grp-cart-btn .material-icons { color: var(--grp-accent-text); font-size: 17px; }
.grp-cart-btn:hover { opacity: 0.8; }
.grp-cart-count { position: absolute; top: -4px; right: -4px; background: var(--grp-green); color: #fff; font-size: 10px; font-weight: 700; width: 18px; height: 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }

/* ═══ CUSTOM DATE PICKER ═══ */
.grp-date-field { display: flex; flex-direction: column; align-items: center; gap: 2px; cursor: pointer; }
.grp-date-field label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.8px; color: var(--grp-text-muted); font-weight: 600; pointer-events: none; }
.grp-date-trigger { background: none; border: none; color: var(--grp-text); font-size: 15px; font-weight: 600; cursor: pointer; padding: 2px 4px; font-family: var(--grp-font); letter-spacing: -0.01em; border-bottom: 2px solid transparent; transition: border-color var(--grp-t); }
.grp-date-trigger:hover { border-bottom-color: var(--grp-text); }
.grp-date-trigger.active { border-bottom-color: var(--grp-accent); }

.grp-cal { position: fixed; top: 0; left: 0; background: var(--grp-surface); border: 1px solid var(--grp-border); border-radius: 16px; box-shadow: var(--grp-shadow-lg); padding: 20px; width: 340px; z-index: 2147483647; }
.grp-cal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.grp-cal-title { font-size: 17px; font-weight: 600; }
.grp-cal-nav { background: none; border: 1px solid var(--grp-border); border-radius: 50%; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--grp-text); transition: all var(--grp-t); }
.grp-cal-nav:hover { background: var(--grp-surface-2); }
.grp-cal-nav .material-icons { font-size: 20px; }
.grp-cal-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 0; margin-bottom: 4px; }
.grp-cal-days span { text-align: center; font-size: 12px; font-weight: 600; color: var(--grp-text-muted); padding: 8px 0; }
.grp-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.grp-cal-grid button { background: none; border: none; width: 100%; aspect-ratio: 1; border-radius: 50%; font-size: 15px; font-weight: 500; cursor: pointer; color: var(--grp-text); transition: all var(--grp-t); font-family: var(--grp-font); }
.grp-cal-grid button:hover:not(:disabled):not(.sel) { background: var(--grp-surface-2); }
.grp-cal-grid button.today { font-weight: 700; }
.grp-cal-grid button.sel { background: var(--grp-accent); color: var(--grp-accent-text); font-weight: 700; }
.grp-cal-grid button.in-range { background: var(--grp-surface-3); }
.grp-cal-grid button:disabled { color: var(--grp-text-muted); opacity: 0.35; cursor: not-allowed; }
.grp-cal-grid button.other-month { color: var(--grp-text-muted); opacity: 0.4; }

/* ═══ CATEGORIES ═══ */
.grp-categories { max-width: 1280px; margin: 0 auto; padding: 20px 24px 8px; display: flex; gap: 8px; flex-wrap: wrap; }
.grp-cat-btn { background: var(--grp-surface); border: 1px solid var(--grp-border); color: var(--grp-text-2); padding: 7px 16px; border-radius: 100px; font-size: 13px; font-weight: 500; cursor: pointer; transition: all var(--grp-t); display: flex; align-items: center; gap: 5px; }
.grp-cat-btn:hover { border-color: var(--grp-text); color: var(--grp-text); }
.grp-cat-btn.active { background: var(--grp-accent); color: var(--grp-accent-text); border-color: var(--grp-accent); }
.grp-cat-btn .material-icons { font-size: 16px; }

/* ═══ GRID ═══ */
.grp-grid-wrap { max-width: 1280px; margin: 0 auto; padding: 20px 24px 64px; }
.grp-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }

/* View mode toolbar */
.grp-view-toolbar { max-width: 1280px; margin: 0 auto; padding: 14px 24px 0; display: flex; justify-content: flex-end; }
.grp-view-toggle { display: inline-flex; background: var(--grp-surface-2); border: 1px solid var(--grp-border); border-radius: var(--grp-r-sm); padding: 3px; gap: 2px; }
.grp-view-btn { background: transparent; border: 0; padding: 6px 10px; border-radius: calc(var(--grp-r-sm) - 3px); cursor: pointer; color: var(--grp-text-muted); display: inline-flex; align-items: center; transition: background 0.15s, color 0.15s; }
.grp-view-btn:hover { color: var(--grp-text); }
.grp-view-btn.active { background: var(--grp-surface); color: var(--grp-text); box-shadow: 0 1px 2px rgba(0,0,0,0.08); }
.grp-view-btn .material-icons { font-size: 18px; }

/* List view container: single column on mobile, 2 columns on tablet+ */
.grp-grid.grp-view-list-mode { display: grid; grid-template-columns: 1fr; gap: 8px; }
@media (min-width: 768px) {
    .grp-grid.grp-view-list-mode { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* List row */
.grp-row { display: flex; align-items: center; gap: 14px; background: var(--grp-surface); border: 1px solid var(--grp-border); border-radius: var(--grp-r-sm); padding: 10px 14px; cursor: pointer; transition: border-color 0.15s, transform 0.1s; animation: grpFadeIn 0.3s both; }
.grp-row:hover { border-color: var(--grp-text-muted); }
.grp-row:active { transform: scale(0.998); }
.grp-row-img-wrap { flex-shrink: 0; width: 56px; height: 56px; border-radius: var(--grp-r-sm); overflow: hidden; background: var(--grp-surface-2); }
.grp-row-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.grp-row-img-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; color: var(--grp-text-muted); }
.grp-row-img-ph .material-icons { font-size: 24px; }
.grp-row-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.grp-row-cat { font-size: 10px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--grp-text-muted); font-weight: 600; }
.grp-row-name { font-size: 15px; font-weight: 600; color: var(--grp-text); line-height: 1.25; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.grp-row-avail { font-size: 11px; font-weight: 500; }
.grp-row-avail.ok { color: var(--grp-text-2); }
.grp-row-avail.none { color: var(--grp-text-muted); }
.grp-row-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex-shrink: 0; }
.grp-row-price { font-size: 16px; font-weight: 700; color: var(--grp-text); letter-spacing: -0.01em; line-height: 1; white-space: nowrap; }
.grp-row-price-prefix { font-size: 11px; color: var(--grp-text-muted); font-weight: 500; }
.grp-row-price-period { font-size: 11px; color: var(--grp-text-muted); font-weight: 500; margin-left: 2px; }
.grp-row-add-btn { background: var(--grp-text); color: var(--grp-bg); border: 0; padding: 6px 14px; border-radius: 999px; font-size: 12px; font-weight: 600; cursor: pointer; min-width: 60px; transition: opacity 0.15s; }
.grp-row-add-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.grp-row-add-btn.added { background: var(--grp-accent, #4a6230); }

/* Mobile: tighten the list row */
@media (max-width: 640px) {
    .grp-row { padding: 8px 10px; gap: 10px; }
    .grp-row-img-wrap { width: 48px; height: 48px; }
    .grp-row-name { font-size: 14px; }
    .grp-row-price { font-size: 15px; }
    .grp-row-add-btn { padding: 5px 12px; font-size: 11px; min-width: 52px; }
}
.grp-card { background: var(--grp-surface); border: 1px solid var(--grp-border); border-radius: var(--grp-r); overflow: hidden; cursor: pointer; transition: all 0.3s ease; box-shadow: var(--grp-shadow-sm); display: flex; flex-direction: column; animation: grpFade 0.4s ease both; }
.grp-card:hover { transform: translateY(-4px); box-shadow: var(--grp-shadow-md); }
.grp-card-img-wrap { width: 100%; aspect-ratio: 1/1; background: var(--grp-surface-2); overflow: hidden; }
.grp-card-img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s ease; }
.grp-card:hover .grp-card-img { transform: scale(1.05); }
.grp-card-img-ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.grp-card-img-ph .material-icons { font-size: 40px; color: var(--grp-border); }
.grp-card-body { padding: 14px 16px 16px; flex: 1; display: flex; flex-direction: column; min-width: 0; }
.grp-card-cat { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: var(--grp-text-muted); font-weight: 600; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grp-card-name { font-size: 15px; font-weight: 600; line-height: 1.3; margin-bottom: 8px; word-wrap: break-word !important; overflow-wrap: break-word !important; white-space: normal !important; text-overflow: clip !important; overflow: visible !important; }
.grp-app .grp-card .grp-card-body .grp-card-name,
.grp-app .grp-card-name { white-space: normal !important; text-overflow: unset !important; overflow: visible !important; display: block !important; -webkit-line-clamp: unset !important; -webkit-box-orient: unset !important; }
.grp-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 10px; border-top: 1px solid var(--grp-border); }
.grp-card-meta { display: flex; flex-direction: column; gap: 3px; min-width: 0; align-items: flex-start; }
.grp-card-price { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; display: flex; align-items: baseline; gap: 3px; flex-wrap: wrap; }
.grp-card-price small { font-size: 12px; color: var(--grp-text-muted); font-weight: 400; }
.grp-card-price-prefix { font-size: 12px; color: var(--grp-text-muted); font-weight: 500; }
.grp-card-price-period { font-size: 11px; color: var(--grp-text-muted); font-weight: 500; letter-spacing: 0.02em; }
.grp-card-avail { font-size: 11px; font-weight: 500; white-space: nowrap; color: var(--grp-text-2); }
.grp-card-avail.none { color: var(--grp-red); }
/* Action area: fixed footprint so Add ↔ stepper swap causes zero layout shift */
.grp-item-action { flex-shrink: 0; display: flex; justify-content: flex-end; }
.grp-card-qty { display: flex; align-items: center; border: 1px solid var(--grp-border); border-radius: var(--grp-r-xs); overflow: hidden; flex-shrink: 0; }
.grp-card-qty button { background: var(--grp-surface-2); border: none; color: var(--grp-text); width: 28px; height: 28px; cursor: pointer; font-size: 14px; }
.grp-card-qty button:hover { background: var(--grp-surface-3); }
.grp-card-qty span { width: 26px; text-align: center; font-size: 13px; font-weight: 600; }
.grp-card-add-btn { background: var(--grp-accent); color: var(--grp-accent-text); border: none; width: 104px; height: 38px; padding: 0; border-radius: 100px; font-size: 13px; font-weight: 600; cursor: pointer; transition: opacity var(--grp-t); white-space: nowrap; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; }
.grp-card-add-btn:hover { opacity: 0.8; }
.grp-card-add-btn.added { background: var(--grp-green); color: #fff; }
.grp-card-add-btn:disabled { opacity: 0.3; cursor: not-allowed; }

/* ═══ DETAIL MODAL ═══ */
.grp-detail-overlay { position: fixed; inset: 0; z-index: 2147483645 !important; background: var(--grp-overlay); display: flex; align-items: center; justify-content: center; padding: 20px; opacity: 0; visibility: hidden; transition: all var(--grp-t); }
.grp-detail-overlay.open { opacity: 1; visibility: visible; }
.grp-detail-panel { position: relative; background: var(--grp-surface); border-radius: 20px; max-width: 780px; width: 100%; max-height: calc(100vh - 40px); display: flex; flex-direction: row; overflow: hidden; box-shadow: var(--grp-shadow-lg); transform: scale(0.96) translateY(8px); opacity: 0; transition: transform 0.28s cubic-bezier(0.16,1,0.3,1), opacity 0.22s ease; }
.admin-bar .grp-detail-overlay { padding-top: 52px; }
.admin-bar .grp-cart-overlay { padding-top: 0; }
.grp-detail-overlay.open .grp-detail-panel { transform: scale(1) translateY(0); opacity: 1; }
.grp-detail-left { width: 300px; flex-shrink: 0; background: var(--grp-surface-2); position: relative; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.grp-detail-left img { width: 100%; height: 100%; object-fit: contain; padding: 12px; }
.grp-detail-left .grp-ph { font-size: 48px; color: var(--grp-border); }
.grp-detail-right { flex: 1; padding: 24px; display: flex; flex-direction: column; overflow-y: auto; min-width: 0; width: 0; }
.grp-detail-close { position: absolute; top: 14px; right: 14px; background: var(--grp-surface); border: none; border-radius: 50%; width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: var(--grp-shadow-sm); z-index: 5; transition: background var(--grp-t); }
/* Loading state sized so the panel opens near full size (no resize jump), spinner centered */
.grp-detail-loading { width: 100%; min-height: 560px; max-height: calc(100vh - 40px); display: flex; align-items: center; justify-content: center; }
/* Content fades/rises in once it replaces the loader */
.grp-detail-left, .grp-detail-right { animation: grpDetailIn 0.3s ease both; }
@keyframes grpDetailIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
.grp-detail-close .material-icons { font-size: 16px; color: var(--grp-text); }
.grp-detail-close:hover { background: var(--grp-accent); }
.grp-detail-close:hover .material-icons { color: var(--grp-accent-text); }
.grp-detail-cat { font-size: 11px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--grp-text-muted); font-weight: 600; margin-bottom: 4px; white-space: normal; }
.grp-detail-name { font-size: 22px; font-weight: 600; margin-bottom: 6px; line-height: 1.2; letter-spacing: -0.02em; white-space: normal; word-wrap: break-word; overflow-wrap: anywhere; }
.grp-detail-desc { font-size: 14px; color: var(--grp-text-2); line-height: 1.6; margin-bottom: 10px; white-space: normal; word-wrap: break-word; overflow-wrap: anywhere; }
.grp-detail-rental-summary { background: var(--grp-surface-2); border: 1px solid var(--grp-border); border-radius: var(--grp-r-sm); padding: 14px 18px; margin-bottom: 12px; }
.grp-rental-headline { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; color: var(--grp-text); display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; }
.grp-rental-period { font-size: 14px; font-weight: 500; color: var(--grp-text-muted); letter-spacing: 0; text-transform: none; }
.grp-rental-explainer { font-size: 12px; color: var(--grp-text-muted); margin-top: 4px; }

/* VARIANTS */
.grp-variants { margin-bottom: 12px; }
.grp-variants-title { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 1px; color: var(--grp-text-muted); margin-bottom: 8px; }
.grp-variant-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; background: var(--grp-surface-2); border: 1px solid var(--grp-border); border-radius: var(--grp-r-xs); margin-bottom: 4px; cursor: pointer; transition: all var(--grp-t); }
.grp-variant-item:hover { border-color: var(--grp-text); }
.grp-variant-item input { display: none; }
.grp-variant-check { width: 20px; height: 20px; border: 2px solid var(--grp-border); border-radius: 6px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; transition: all var(--grp-t); }
.grp-variant-item input:checked ~ .grp-variant-check { background: var(--grp-accent); border-color: var(--grp-accent); }
.grp-variant-item input:checked ~ .grp-variant-check::after { content: '✓'; color: var(--grp-accent-text); font-size: 12px; font-weight: 700; }
.grp-variant-name { flex: 1; font-size: 14px; font-weight: 500; color: var(--grp-text); }
.grp-variant-price { font-size: 14px; font-weight: 600; color: var(--grp-text-2); }
.grp-variant-avail { font-size: 11px; font-weight: 600; color: var(--grp-green); white-space: nowrap; }
.grp-variant-avail.out { color: var(--grp-red, #e74c3c); }
.grp-variant-item.unavailable { opacity: 0.5; cursor: not-allowed; }
.grp-variant-item.unavailable:hover { border-color: var(--grp-border); }
.grp-variant-next { font-size: 10px; color: var(--grp-text-muted); font-style: italic; white-space: nowrap; width: 100%; padding-left: 30px; margin-top: -4px; }
.grp-variant-item { flex-wrap: wrap; }

/* ADDONS */
.grp-addons { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--grp-border); }
.grp-addons-highlight { animation: grpPulse 0.5s ease; }
@keyframes grpPulse { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }
.grp-addons-title { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 1px; color: var(--grp-text-muted); margin-bottom: 8px; }
.grp-addons-grid { display: flex; flex-direction: column; gap: 4px; max-height: 180px; overflow-y: auto; padding-right: 4px; }
.grp-addons-grid::-webkit-scrollbar { width: 4px; }
.grp-addons-grid::-webkit-scrollbar-thumb { background: var(--grp-border); border-radius: 4px; }
.grp-addon-card { display: flex; align-items: center; gap: 10px; padding: 8px 10px; background: var(--grp-surface-2); border: 1px solid var(--grp-border); border-radius: var(--grp-r-xs); transition: border-color var(--grp-t); cursor: pointer; }
.grp-addon-card:hover { border-color: var(--grp-text-muted); }
.grp-addon-img { width: 40px; height: 40px; border-radius: 8px; background: var(--grp-surface-3); overflow: hidden; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.grp-addon-img img { width: 100%; height: 100%; object-fit: cover; }
.grp-addon-img .material-icons { font-size: 18px; color: var(--grp-text-muted); }
.grp-addon-info { flex: 1; min-width: 0; }
.grp-addon-name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grp-addon-meta { display: flex; align-items: center; gap: 8px; margin-top: 2px; }
.grp-addon-price { font-size: 12px; font-weight: 600; color: var(--grp-text); }
.grp-addon-avail { font-size: 11px; font-weight: 500; color: var(--grp-text-muted); }
.grp-addon-avail.out { color: var(--grp-red, #e74c3c); }
.grp-addon-action { flex-shrink: 0; display: flex; justify-content: flex-end; min-width: 30px; }
.grp-addon-add { background: var(--grp-accent); color: var(--grp-accent-text); border: none; width: 30px; height: 30px; border-radius: 50%; font-size: 18px; cursor: pointer; flex-shrink: 0; display: flex; align-items: center; justify-content: center; transition: opacity var(--grp-t); }
.grp-addon-add:disabled { opacity: 0.3; cursor: not-allowed; }
.grp-addon-stepper { display: inline-flex; align-items: center; border: 1px solid var(--grp-accent); border-radius: 999px; overflow: hidden; background: var(--grp-accent); height: 30px; }
.grp-addon-stepper button { background: var(--grp-accent); border: none; color: var(--grp-accent-text); width: 28px; height: 100%; cursor: pointer; font-size: 16px; font-weight: 600; display: flex; align-items: center; justify-content: center; line-height: 1; }
.grp-addon-stepper button:disabled { opacity: 0.35; cursor: not-allowed; }
.grp-addon-stepper button .material-icons { font-size: 15px; }
.grp-addon-stepper span { min-width: 22px; text-align: center; font-size: 12px; font-weight: 700; color: var(--grp-accent-text); }

.grp-detail-actions { display: flex; align-items: center; gap: 10px; margin-top: auto; padding-top: 12px; }
.grp-qty-ctrl { display: flex; align-items: center; border: 1px solid var(--grp-border); border-radius: var(--grp-r-sm); overflow: hidden; }
.grp-qty-ctrl button { background: var(--grp-surface-2); border: none; color: var(--grp-text); width: 40px; height: 40px; cursor: pointer; font-size: 18px; }
.grp-qty-ctrl button:hover { background: var(--grp-surface-3); }
.grp-qty-ctrl span { width: 40px; text-align: center; font-size: 15px; font-weight: 600; }
.grp-detail-add-btn { flex: 1; background: var(--grp-accent); color: var(--grp-accent-text); border: none; height: 48px; padding: 0 20px; border-radius: 100px; font-weight: 600; font-size: 14px; cursor: pointer; transition: all var(--grp-t); letter-spacing: 0.02em; display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; }
.grp-detail-add-btn:hover { opacity: 0.85; }
.grp-detail-add-btn.added { background: var(--grp-green); color: #fff; }
.grp-detail-add-btn:disabled { opacity: 0.3; cursor: not-allowed; }
/* In-cart full-width stepper — same footprint as the Add button (seamless swap), green = added */
.grp-detail-incart { flex: 1; display: flex; align-items: center; justify-content: space-between; height: 48px; background: var(--grp-green); border-radius: 100px; box-sizing: border-box; overflow: hidden; }
.grp-detail-incart.grp-just-added { animation: grp-added-pop 0.4s cubic-bezier(0.34,1.56,0.64,1); }
@keyframes grp-added-pop { 0% { transform: scale(0.94); } 55% { transform: scale(1.035); } 100% { transform: scale(1); } }
.grp-detail-step { background: transparent; border: none; color: #fff; width: 56px; height: 100%; cursor: pointer; font-size: 22px; font-weight: 600; display: flex; align-items: center; justify-content: center; line-height: 1; transition: opacity 0.15s; flex-shrink: 0; }
.grp-detail-step:disabled { opacity: 0.3; cursor: not-allowed; }
.grp-detail-step .material-icons { font-size: 20px; }
.grp-detail-incart-label { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 5px; text-align: center; color: #fff; font-size: 14px; font-weight: 500; letter-spacing: 0.02em; white-space: nowrap; }
.grp-detail-incart-label strong { font-weight: 700; }
.grp-incart-check { font-size: 16px !important; }
.grp-detail-avail { font-size: 12px; font-weight: 600; color: var(--grp-green); letter-spacing: 0.04em; margin-top: 4px; display: inline-block; }
.grp-detail-avail.out { color: var(--grp-red, #e74c3c); }
.grp-detail-next-avail, .grp-card-next-avail { font-size: 11px; color: var(--grp-text-muted); font-style: italic; display: block; margin-top: 2px; }
.grp-card-next-avail { font-size: 10px; width: 100%; }

/* ═══ CART ═══ */
.grp-cart-overlay { position: fixed; inset: 0; z-index: 2147483646 !important; background: var(--grp-overlay); opacity: 0; visibility: hidden; transition: all var(--grp-t); }
.grp-cart-overlay.open { opacity: 1; visibility: visible; }
.grp-cart-panel { position: fixed; right: 0; top: 0; bottom: 0; z-index: 2147483647 !important; width: 420px; max-width: 100vw; background: var(--grp-surface); border-left: 1px solid var(--grp-border); transform: translateX(100%); transition: transform 0.3s ease; display: flex; flex-direction: column; }
.admin-bar .grp-cart-panel { top: 32px; }
@media screen and (max-width: 782px) { .admin-bar .grp-cart-panel { top: 46px; } }
.grp-cart-overlay.open .grp-cart-panel { transform: translateX(0); }
.grp-cart-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--grp-border); flex-shrink: 0; }
.grp-cart-header h2 { font-size: 18px; font-weight: 600; }
.grp-cart-close { background: none; border: none; color: var(--grp-text-muted); cursor: pointer; padding: 4px; }
.grp-cart-scroll { flex: 1; overflow-y: auto; }
.grp-cart-items { padding: 12px 20px; }
.grp-cart-empty { color: var(--grp-text-muted); text-align: center; padding: 32px 0; font-size: 14px; }
.grp-cart-item { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--grp-border); align-items: center; }
.grp-cart-item-img { width: 48px !important; height: 48px !important; min-width: 48px; max-width: 48px; border-radius: 10px; object-fit: cover; background: var(--grp-surface-2); flex-shrink: 0; }
.grp-cart-qty { display: inline-flex; align-items: center; gap: 4px; }
.grp-cart-qty button { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--grp-border); background: transparent; color: var(--grp-text); cursor: pointer; font-size: 14px; display: flex; align-items: center; justify-content: center; padding: 0; }
.grp-cart-qty button:disabled { opacity: 0.3; cursor: not-allowed; }
.grp-cart-qty span { font-weight: 600; min-width: 18px; text-align: center; font-size: 13px; }
.grp-cart-item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 9px; }
.grp-cart-item-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.grp-cart-item-name { font-weight: 600; font-size: 14px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.grp-cart-item-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.grp-cart-item-pricewrap { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; white-space: nowrap; }
.grp-cart-item-unit { font-size: 11px; color: var(--grp-text-muted); }
.grp-cart-item-dur { font-size: 11px; color: var(--grp-text-muted); }
.grp-cart-item-price { font-weight: 700; font-size: 15px; }
.grp-cart-item-remove { background: none; border: none; cursor: pointer; color: var(--grp-text-muted); padding: 2px; flex-shrink: 0; margin-top: -2px; }
.grp-cart-item-remove:hover { color: var(--grp-red); }
.grp-cart-item-remove .material-icons { font-size: 18px; }

.grp-cart-discount { padding: 12px 20px; display: flex; gap: 8px; }
.grp-cart-discount input { flex: 1; min-width: 0; background: var(--grp-surface-2); border: 1px solid var(--grp-border); color: var(--grp-text); padding: 8px 14px; border-radius: 100px; font-size: 13px; text-transform: uppercase; }
.grp-cart-discount input::placeholder { text-transform: none; color: var(--grp-text-muted); }
.grp-cart-discount button { background: var(--grp-surface-3); border: 1px solid var(--grp-border); color: var(--grp-text); padding: 8px 16px; border-radius: 100px; font-size: 13px; font-weight: 600; cursor: pointer; flex-shrink: 0; }
.grp-cart-discount button:hover { border-color: var(--grp-text); }
.grp-discount-result { padding: 0 20px 6px; font-size: 12px; }
.grp-discount-result.success { color: var(--grp-green); }
.grp-discount-result.error { color: var(--grp-red); }

.grp-cart-totals { padding: 12px 20px; border-top: 1px solid var(--grp-border); font-size: 14px; }
.grp-total-row { display: flex; justify-content: space-between; padding: 3px 0; }
.grp-total-row.discount { color: var(--grp-green); }
.grp-total-row.grand { font-size: 20px; font-weight: 600; padding-top: 10px; border-top: 1px solid var(--grp-border); margin-top: 6px; letter-spacing: -0.02em; }

.grp-cart-actions { padding: 12px 20px 20px; flex-shrink: 0; }
.grp-btn { width: 100%; padding: 14px 20px; border: none; border-radius: 100px; font-weight: 600; font-size: 15px; cursor: pointer; text-align: center; transition: all var(--grp-t); display: block; letter-spacing: 0.01em; }
.grp-btn-quote { background: var(--grp-accent); color: var(--grp-accent-text); }
.grp-btn-quote:hover { opacity: 0.85; }
.grp-btn-back { background: none; border: 1px solid var(--grp-border); color: var(--grp-text-muted); width: auto; display: inline-block; padding: 10px 20px; font-size: 13px; }
.grp-btn-confirm { background: var(--grp-accent); color: var(--grp-accent-text); width: auto; display: inline-block; flex: 1; font-size: 13px; }
.grp-btn-confirm:hover { opacity: 0.85; }
.grp-btn:disabled { opacity: 0.3; cursor: not-allowed; }

.grp-checkout { padding: 16px 20px 24px; border-top: 1px solid var(--grp-border); }
.grp-checkout h3 { font-size: 18px; font-weight: 600; margin-bottom: 12px; }
.grp-form-row { display: flex; gap: 10px; }
.grp-form-row .grp-form-group { flex: 1; min-width: 0; }
.grp-form-group { margin-bottom: 10px; }
.grp-form-group label { display: block; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.8px; color: var(--grp-text-muted); margin-bottom: 4px; }
.grp-form-group input, .grp-form-group textarea { width: 100%; background: var(--grp-surface-2); border: 1px solid var(--grp-border); color: var(--grp-text); padding: 10px 14px; border-radius: var(--grp-r-xs); font-size: 14px; }
.grp-form-group input:focus, .grp-form-group textarea:focus { outline: none; border-color: var(--grp-text); }
.grp-checkout-actions { display: flex; gap: 10px; margin-top: 12px; }

/* MODAL */
.grp-modal { position: fixed; inset: 0; z-index: 2147483647 !important; background: var(--grp-overlay); display: flex; align-items: center; justify-content: center; padding: 20px; }
.grp-modal-content { background: var(--grp-surface); border-radius: 24px; padding: 40px; text-align: center; max-width: 400px; width: 100%; box-shadow: var(--grp-shadow-lg); }
.grp-modal-icon { font-size: 48px; color: var(--grp-green); }
.grp-modal-content h2 { font-size: 24px; font-weight: 600; margin: 12px 0 8px; letter-spacing: -0.02em; }
.grp-modal-content p { color: var(--grp-text-2); margin-bottom: 20px; font-size: 14px; white-space: pre-line; line-height: 1.6; }
.grp-modal-content .grp-btn { width: auto; min-width: 140px; display: inline-block; }

/* MISC */
.grp-cart-dates { padding: 12px 20px; background: var(--grp-surface-2); border-bottom: 1px solid var(--grp-border); }
.grp-cart-date-fields { display: flex; align-items: flex-end; gap: 10px; }
.grp-cart-date-field { display: flex; flex-direction: column; gap: 4px; flex: 1; min-width: 0; }
.grp-cart-date-label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--grp-text-muted); font-weight: 600; }
.grp-cart-date-trigger { background: var(--grp-surface); color: var(--grp-text); border: 1px solid var(--grp-border); border-radius: var(--grp-r-sm); padding: 10px 12px; font-size: 14px; font-weight: 600; font-family: inherit; width: 100%; text-align: left; cursor: pointer; transition: border-color var(--grp-t); box-sizing: border-box; }
.grp-cart-date-trigger:hover, .grp-cart-date-trigger.active { border-color: var(--grp-text); }
.grp-cart-date-arrow { color: var(--grp-text-muted); font-size: 18px; padding-bottom: 11px; flex-shrink: 0; }
.grp-cal-note { margin-top: 10px; padding-top: 8px; border-top: 1px solid var(--grp-border); font-size: 11px; color: var(--grp-text-muted); display: flex; gap: 12px; flex-wrap: wrap; }
.grp-pagination { max-width: 1280px; margin: 0 auto; padding: 16px 0; display: flex; align-items: center; justify-content: center; gap: 8px; }
.grp-pagination button { background: var(--grp-surface); border: 1px solid var(--grp-border); color: var(--grp-text); width: 36px; height: 36px; border-radius: 50%; cursor: pointer; font-size: 14px; font-weight: 600; display: flex; align-items: center; justify-content: center; transition: all var(--grp-t); }
.grp-pagination button:hover { border-color: var(--grp-text); }
.grp-pagination button.active { background: var(--grp-accent); color: var(--grp-accent-text); border-color: var(--grp-accent); }
.grp-pagination button:disabled { opacity: 0.3; cursor: not-allowed; }
.grp-pagination .grp-page-info { font-size: 13px; color: var(--grp-text-muted); margin: 0 8px; }
body.grp-no-scroll { position: fixed !important; width: 100% !important; overflow-y: scroll !important; }
body.grp-no-scroll header:not(.grp-header),
body.grp-no-scroll nav:not(.grp-categories),
body.grp-no-scroll .header-space,
body.grp-no-scroll #header-outer,
body.grp-no-scroll #header-space,
body.grp-no-scroll [class*="nav-wrap"],
body.grp-no-scroll [class*="site-header"],
body.grp-no-scroll [class*="main-nav"],
body.grp-no-scroll [class*="sticky-header"],
body.grp-no-scroll #top-bar,
body.grp-no-scroll #wpadminbar { z-index: 0 !important; }
.grp-loading { grid-column: 1/-1; text-align: center; padding: 48px; }
.grp-spinner { width: 24px; height: 24px; border: 2px solid var(--grp-border); border-top-color: var(--grp-text); border-radius: 50%; animation: grpSpin 0.8s linear infinite; margin: 0 auto; }
@keyframes grpSpin { to { transform: rotate(360deg); } }
.grp-no-results { grid-column: 1/-1; text-align: center; padding: 48px; color: var(--grp-text-muted); font-size: 14px; }
.grp-no-results .material-icons { font-size: 36px; display: block; margin-bottom: 8px; }
@keyframes grpFade { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* RESPONSIVE */
@media (max-width: 960px) { .grp-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px) {
    .grp-header-inner { display: flex; height: auto; flex-wrap: wrap; padding: 10px 16px; gap: 6px; }
    .grp-header-left { width: auto; justify-self: auto; }
    .grp-header-center { justify-self: auto; order: 3; flex-basis: 100%; justify-content: center; }
    .grp-header-right { justify-self: auto; margin-left: auto; gap: 6px; }
    .grp-dates { padding: 4px 10px; gap: 6px; overflow: hidden; max-width: 100%; }
    .grp-date-field label { font-size: 9px; }
    .grp-date-trigger { font-size: 13px; }
    .grp-date-badge { font-size: 10px; padding: 2px 8px; }
    .grp-cal { width: 300px; padding: 16px; }
    .grp-grid-wrap { padding: 16px 16px 40px; }
    .grp-cart-panel { width: 100%; }
    .grp-categories { padding: 16px 16px 8px; }

    /* Detail modal: bottom sheet on mobile */
    .grp-detail-overlay { display: flex !important; align-items: flex-end !important; justify-content: center !important; padding: 0 !important; }
    .grp-detail-panel { flex-direction: column !important; width: 100% !important; max-width: 100% !important; max-height: 85vh !important; border-radius: 20px 20px 0 0 !important; overflow: hidden !important; transform: none !important; }
    .grp-detail-overlay.open .grp-detail-panel { transform: none !important; }
    .grp-detail-loading { min-height: 55vh !important; }
    .grp-detail-left { width: 100% !important; height: 220px !important; flex-shrink: 0 !important; }
    .grp-detail-left img { width: 100% !important; height: 100% !important; object-fit: contain !important; padding: 16px !important; }
    .grp-detail-right { width: 100% !important; min-width: 100% !important; flex: 1 !important; padding: 14px !important; overflow-y: scroll !important; -webkit-overflow-scrolling: touch; overflow-x: hidden !important; }
    .grp-detail-name { font-size: 18px !important; white-space: normal !important; word-wrap: break-word !important; overflow-wrap: break-word !important; margin-bottom: 4px !important; }
    .grp-detail-desc { font-size: 12px !important; white-space: normal !important; margin-bottom: 6px !important; line-height: 1.4 !important; }
    .grp-detail-actions { flex-shrink: 0 !important; padding-top: 8px !important; }
    .grp-detail-add-btn { font-size: 13px; }
    .grp-addons { margin-top: 10px !important; padding-top: 8px !important; }
    .grp-addons-grid { max-height: 120px; }
}
@media (max-width: 480px) {
    .grp-grid { grid-template-columns: 1fr; }
    .grp-date-arrow { display: none; }
    .grp-dates { gap: 4px; }
    .grp-date-trigger { font-size: 12px; }
    .grp-detail-left { height: 160px !important; }
    .grp-detail-right { padding: 14px !important; }
    .grp-detail-name { font-size: 18px !important; }
}

/* Promo banner — fixed colors so it pops in both light/dark mode */
.grp-banner { background: #111; color: #fff; padding: 0; margin: 0 0 12px; border-radius: 0; box-sizing: border-box; }
.grp-banner-inner { padding: 10px 44px 10px 20px; display: flex; align-items: center; justify-content: center; gap: 12px; position: relative; min-height: 0; box-sizing: border-box; }
.grp-banner-text { font-size: 13px; font-weight: 500; text-align: center; line-height: 1.4; margin: 0; word-wrap: break-word; overflow-wrap: break-word; white-space: normal; min-width: 0; }
.grp-banner-close { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); background: transparent; color: #fff; border: none; font-size: 18px; line-height: 1; cursor: pointer; padding: 4px 8px; opacity: 0.7; transition: opacity 0.2s; }
.grp-banner-close:hover { opacity: 1; }
@media (max-width: 600px) { .grp-banner-inner { padding: 10px 36px 10px 14px; } .grp-banner-text { font-size: 12px; text-align: left; } }

/* Floating cart button (FAB) */
.grp-cart-fab {
    position: fixed;
    bottom: 24px;
    left: 24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--grp-accent, #111);
    color: var(--grp-accent-text, #fff);
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.25s ease, transform 0.25s ease;
    pointer-events: none;
}
.grp-cart-fab.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}
.grp-cart-fab .material-icons { font-size: 26px; }
.grp-cart-fab-count {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 11px;
    background: var(--grp-green, #16a34a);
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    transform: scale(0);
    transition: transform 0.2s ease;
}
.grp-cart-fab.has-items .grp-cart-fab-count { transform: scale(1); }
.grp-cart-fab:hover { transform: translateY(0) scale(1.05); }


@media (max-width: 600px) {
    .grp-cart-fab { bottom: 16px; left: 16px; width: 52px; height: 52px; }
}

/* ============ Rate ladder cart diagram (ported from current build) ============ */
.grp-rate-explainer { max-height: 0; overflow: hidden; background: var(--grp-surface-2); border-bottom: 1px solid var(--grp-border); transition: max-height 0.28s ease; }
.grp-rate-explainer.open { max-height: 600px; }
.grp-rate-explainer-inner { padding: 14px 16px 16px; }
.grp-rate-ladder { display: flex; align-items: stretch; gap: 4px; margin-bottom: 10px; }
.grp-rate-step { flex: 1; padding: 10px 6px; border-radius: 10px; background: var(--grp-surface-3); position: relative; transition: all 0.2s; min-width: 0; text-align: center; }
.grp-rate-step.active { background: var(--grp-text); color: var(--grp-surface); transform: scale(1.06); box-shadow: 0 4px 16px rgba(0,0,0,0.18); z-index: 2; }
.grp-rate-step.locked { opacity: 0.55; }
.grp-rate-step .grp-rate-ribbon { position: absolute; top: -7px; left: 50%; transform: translateX(-50%); background: var(--grp-green); color: #fff; font-size: 9px; font-weight: 700; letter-spacing: 0.5px; padding: 2px 7px; border-radius: 4px; white-space: nowrap; }
.grp-rate-step .grp-rate-name { font-size: 10px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--grp-text-muted); margin-bottom: 3px; font-weight: 600; }
.grp-rate-step.active .grp-rate-name { color: var(--grp-green); }
.grp-rate-step .grp-rate-range { font-size: 10px; color: var(--grp-text-muted); margin-bottom: 6px; }
.grp-rate-step.active .grp-rate-range { color: var(--grp-text-muted); opacity: 0.7; }
.grp-rate-step .grp-rate-price { font-size: 13px; font-weight: 700; color: var(--grp-text); white-space: nowrap; }
.grp-rate-step.active .grp-rate-price { color: var(--grp-surface); font-size: 14px; }
.grp-rate-step .grp-rate-savings { font-size: 9px; color: var(--grp-green); margin-top: 4px; font-weight: 600; white-space: nowrap; }
.grp-rate-arrow { display: flex; align-items: center; color: var(--grp-border); font-size: 13px; flex-shrink: 0; padding: 0 1px; }
.grp-rate-tip { padding: 9px 12px; background: var(--grp-surface-3); border-radius: 8px; font-size: 11px; color: var(--grp-text-2); display: flex; align-items: center; gap: 8px; line-height: 1.4; }
.grp-rate-tip strong { color: var(--grp-text); font-weight: 600; }
@media (max-width: 480px) {
    .grp-rate-step { padding: 8px 4px; }
    .grp-rate-step .grp-rate-price { font-size: 12px; }
    .grp-rate-step.active { transform: scale(1.04); }
}

/* ============ Mobile UI fixes (v1.8.0) ============ */

/* Unified qty stepper — used in grid + list when item is in cart */
.grp-qty-stepper { display: inline-flex; align-items: center; border: 1px solid var(--grp-green); border-radius: 999px; overflow: hidden; flex-shrink: 0; background: var(--grp-green); min-width: 104px; height: 38px; box-sizing: border-box; }
.grp-qty-stepper button { background: transparent; border: none; color: #fff; width: 46px; flex-shrink: 0; height: 100%; cursor: pointer; font-size: 18px; font-weight: 600; display: flex; align-items: center; justify-content: center; line-height: 1; transition: color 0.15s, opacity 0.15s; }
.grp-qty-stepper button:hover { opacity: 0.85; }
.grp-qty-stepper button:disabled { opacity: 0.35; cursor: not-allowed; }
.grp-qty-stepper button.grp-step-trash .material-icons { font-size: 17px; }
.grp-qty-stepper button.grp-step-trash:hover { color: #ff5b5b; opacity: 1; }
.grp-qty-stepper .grp-stepper-mid { flex: 1; text-align: center; font-size: 13px; font-weight: 600; color: #fff; white-space: nowrap; padding: 0 8px; }
.grp-qty-stepper.no-plus .grp-stepper-mid { padding-right: 18px; }
/* List row: action keeps the same fixed footprint */
.grp-row-actions .grp-item-action { align-self: flex-end; }
.grp-row-add-btn { width: 104px; height: 38px; box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; }

/* Next-available hint in list rows */
.grp-row-next-avail { font-size: 10px; color: var(--grp-text-muted); }

/* Windowed pagination polish */
.grp-pagination .grp-page-arrow .material-icons { font-size: 18px; }

/* Mobile search: icon toggle + full-width drop bar */
.grp-search-toggle { display: none; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--grp-surface-2); border: 1px solid var(--grp-border); color: var(--grp-text); cursor: pointer; flex-shrink: 0; transition: background var(--grp-t); }
.grp-search-toggle:hover { background: var(--grp-surface-3); }
.grp-search-toggle .material-icons { font-size: 20px; color: var(--grp-text); }
.grp-search-close { display: none; background: none; border: none; color: var(--grp-text-muted); cursor: pointer; padding: 0; align-items: center; justify-content: center; flex-shrink: 0; }
.grp-search-close .material-icons { font-size: 18px; }

@media (max-width: 768px) {
    /* Hide inline search; show the icon toggle instead */
    .grp-search-toggle { display: flex; }
    .grp-search-wrap { display: none; }

    /* Search open → expand inline within the header's top row (part of the UI, not a floating overlay) */
    .grp-header.search-open .grp-header-left { display: none; }
    .grp-header.search-open .grp-search-toggle { display: none; }
    .grp-header.search-open .grp-header-right { flex: 1 1 100%; gap: 8px; margin-left: 0; }
    .grp-header.search-open .grp-search-wrap {
        display: flex; flex: 1; width: auto; min-width: 0;
        background: var(--grp-surface-2); border: 1px solid var(--grp-border);
        border-radius: 100px; padding: 0 16px; height: 42px; box-sizing: border-box;
    }
    .grp-header.search-open .grp-search-wrap .material-icons { color: var(--grp-text-muted); }
    .grp-header.search-open .grp-search-wrap input { color: var(--grp-text); font-size: 15px; }
    .grp-search-close { display: flex; }
}

/* ============ Touch-device hover fix (v1.9.3) ============ */
/* iOS keeps :hover active after a tap, so a freshly re-rendered button kept its
   dimmed hover opacity (looked greyed-out until you tapped elsewhere). Disable
   opacity-dim hovers on devices without a true hover pointer. */
@media (hover: none) {
    .grp-detail-add-btn:hover:not(:disabled), .grp-card-add-btn:hover:not(:disabled), .grp-row-add-btn:hover:not(:disabled),
    .grp-qty-stepper button:hover:not(:disabled), .grp-detail-step:hover:not(:disabled), .grp-addon-add:hover:not(:disabled),
    .grp-addon-stepper button:hover:not(:disabled), .grp-cart-btn:hover:not(:disabled), .grp-cart-fab:hover:not(:disabled),
    .grp-search-toggle:hover:not(:disabled), .grp-view-btn:hover:not(:disabled) { opacity: 1; }
}

/* ============ Rate clarity v1.9.5 ============ */
/* Multiplier label on non-active ladder tiers */
.grp-rate-step .grp-rate-mult { font-size: 14px; font-weight: 700; color: var(--grp-text-muted); margin-top: 2px; }
.grp-rate-step.active .grp-rate-mult { color: var(--grp-surface); }

/* Plain-language rate strip in the header (visible outside the cart) */
.grp-rate-strip { display: flex; align-items: center; justify-content: center; gap: 7px; padding: 7px 16px; background: var(--grp-green); color: #fff; font-size: 12.5px; font-weight: 500; line-height: 1.3; text-align: center; }
.grp-rate-strip strong { font-weight: 700; }
.grp-rate-strip .grp-strip-icon { font-size: 13px; }

/* Tier tag near catalog card price + on the subline next to availability */
.grp-card-subline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.grp-tier-tag { font-size: 10px; font-weight: 600; color: var(--grp-green); text-transform: uppercase; letter-spacing: 0.4px; background: color-mix(in srgb, var(--grp-green) 12%, transparent); padding: 2px 7px; border-radius: 100px; white-space: nowrap; }
@supports not (background: color-mix(in srgb, red, blue)) { .grp-tier-tag { background: rgba(52,168,83,0.12); } }

/* Combined qty+remove: the trash icon when at qty 1 */
.grp-cart-qty button .material-icons { font-size: 14px; }
.grp-cart-qty.at-min button[data-action="dec"]:hover { color: var(--grp-red); border-color: var(--grp-red); }

/* ============ Cart rate banner v1.9.6 (replaces the tier ladder) ============ */
.grp-rate-banner { display: flex; align-items: center; gap: 12px; padding: 12px 14px; background: color-mix(in srgb, var(--grp-green) 10%, var(--grp-surface)); border: 1px solid color-mix(in srgb, var(--grp-green) 30%, transparent); border-radius: var(--grp-r-sm); }
@supports not (background: color-mix(in srgb, red, blue)) { .grp-rate-banner { background: rgba(52,168,83,0.08); border-color: rgba(52,168,83,0.3); } }
.grp-rate-banner-icon { width: 36px; height: 36px; border-radius: 50%; background: var(--grp-green); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.grp-rate-banner-icon .material-icons { font-size: 20px; }
.grp-rate-banner-body { flex: 1; min-width: 0; }
.grp-rate-banner-title { font-size: 13.5px; font-weight: 700; color: var(--grp-text); }
.grp-rate-banner-sub { font-size: 12px; color: var(--grp-text-2); margin-top: 1px; line-height: 1.35; }
.grp-rate-banner-save { display: flex; flex-direction: column; align-items: flex-end; flex-shrink: 0; text-align: right; }
.grp-rate-save-amt { font-size: 14px; font-weight: 700; color: var(--grp-green); white-space: nowrap; }
.grp-rate-save-pct { font-size: 10px; color: var(--grp-text-muted); white-space: nowrap; }
.grp-rate-upsell { display: flex; align-items: center; gap: 8px; margin-top: 8px; padding: 9px 12px; background: var(--grp-surface-2); border: 1px dashed var(--grp-border); border-radius: var(--grp-r-sm); font-size: 12px; color: var(--grp-text-2); }
.grp-rate-upsell .material-icons { font-size: 16px; color: var(--grp-text-muted); flex-shrink: 0; }

/* "for N days" price caption */
.grp-card-price-period, .grp-row-price-period { text-transform: uppercase; letter-spacing: 0.04em; }

/* List row subline: availability + tier tag together */
.grp-row-subline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ============ Live grid refresh + per-each clarity v1.9.7 ============ */
/* Cart-driven re-renders skip the entry fade so cards update without blinking */
.grp-grid--noanim .grp-card, .grp-grid--noanim .grp-row { animation: none !important; }
/* Per-each total shown on a card/row when its cart qty > 1 */
.grp-each-total { font-size: 11px; font-weight: 700; color: var(--grp-green); white-space: nowrap; }

/* Per-unit "for N days" context line under each cart item name */
.grp-cart-item-unitline { font-size: 12px; color: var(--grp-text-muted); margin-top: -7px; }

/* ============ Price-in-button (Add · $X) v1.9.12 ============ */
/* Price segment inside the Add button, lightly separated */
.grp-add-price { font-weight: 700; margin-left: 2px; }
.grp-add-price::before { content: "·"; margin: 0 5px 0 4px; opacity: 0.55; font-weight: 400; }

/* Add buttons grow to fit the price; stepper keeps the same min footprint */
.grp-card-add-btn { width: auto; min-width: 104px; padding: 0 16px; }
.grp-row-add-btn { min-width: 88px; }

/* Desktop grid card: meta on the left, action on the right — same row/level.
   (On mobile the footer stacks to a full-width button — see the max-width:768px block.) */
.grp-card-footer { flex-direction: row; align-items: center; justify-content: space-between; gap: 10px; }
.grp-card-meta { align-items: flex-start; }
@media (max-width: 768px) {
    .grp-card-footer { flex-direction: column; align-items: stretch; gap: 9px; }
    .grp-card-footer .grp-item-action { justify-content: stretch; }
    .grp-card-footer .grp-item-action > button,
    .grp-card-footer .grp-item-action > .grp-qty-stepper { width: 100%; }
}

/* Duration caption (replaces the standalone price now that price lives in the button) */
.grp-card-dur, .grp-row-dur { font-size: 11px; color: var(--grp-text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; }

/* ============ Stepper price text + trash hover + cart avail v1.9.13 ============ */
/* Cart combined stepper: trash (at qty 1) turns red on hover */
.grp-cart-qty.at-min button[data-action="dec"]:hover .material-icons { color: #ff5b5b; }
/* Detail modal step trash: red on hover */
.grp-detail-step.grp-step-trash:hover { color: #ff5b5b; opacity: 1; }
.grp-detail-step.grp-step-trash:hover .material-icons { color: #ff5b5b; }
/* Availability line under each cart item title */
.grp-cart-item-avail { font-size: 11px; color: var(--grp-text-muted); margin-top: 1px; }

/* ============ Seamless theme integration (Salient + generic) v1.9.15 ============ */
/* Applied only on pages containing the [gear_rental] shortcode (body.grp-seamless),
   so the rest of the site is untouched. Strips the theme's white content frame,
   page-title strip, and width gutters so the storefront sits flush in the page.
   Backgrounds use the storefront's own --grp-bg, which is defined on :root and so
   cascades to the theme wrappers too — meaning these match light AND dark mode. */
body.grp-seamless #ajax-content-wrap,
body.grp-seamless .container-wrap { background: var(--grp-bg) !important; }
body.grp-seamless .container-wrap { padding: 0 !important; margin: 0 !important; box-shadow: none !important; min-width: 0 !important; }
body.grp-seamless .container-wrap .container,
body.grp-seamless .container-wrap .main-content { width: 100% !important; max-width: 100% !important; min-width: 0 !important; padding: 0 !important; margin: 0 !important; }
body.grp-seamless .main-content > .row { width: 100% !important; max-width: 100% !important; margin: 0 !important; }
/* WPBakery / Salient row + column wrappers that wrap the shortcode */
body.grp-seamless .main-content .wpb_row,
body.grp-seamless .main-content .vc_row,
body.grp-seamless .main-content .wpb_column,
body.grp-seamless .main-content .vc_column_container,
body.grp-seamless .main-content .vc_column-inner,
body.grp-seamless .main-content .wpb_wrapper,
body.grp-seamless .main-content .wpb_text_column { margin: 0 !important; padding: 0 !important; }
/* Hide the Salient page-title header strip on this page (the white band up top) */
body.grp-seamless #page-header-bg,
body.grp-seamless .page-header-no-bg,
body.grp-seamless .title-container { display: none !important; }
/* The storefront now fills a full-width container, so retire the 100vw breakout —
   it relies on the container being centered and includes the scrollbar width, which
   can leave a sliver of horizontal scroll. Letting it be 100% is cleaner here. */
body.grp-seamless #grp-app.grp-app { width: 100% !important; left: auto !important; right: auto !important; margin-left: 0 !important; margin-right: 0 !important; }

/* ============ Kits (v1.10.0) ============ */
.grp-card-img-wrap { position: relative; }
/* Auto-mosaic from component photos */
.grp-kit-mosaic { width: 100%; height: 100%; display: grid; gap: 2px; background: var(--grp-border); }
.grp-kit-mosaic.m1 { grid-template-columns: 1fr; }
.grp-kit-mosaic.m2 { grid-template-columns: 1fr 1fr; }
.grp-kit-mosaic.m3 { grid-template-columns: 1.4fr 1fr; grid-template-rows: 1fr 1fr; }
.grp-kit-mosaic.m3 .grp-kmt-big { grid-row: 1 / 3; }
.grp-kit-mosaic.m4 { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; }
.grp-kmt { background-size: cover; background-position: center; background-color: var(--grp-surface-2); }
.grp-kmt-big { background-size: cover; background-position: center; display: flex; align-items: center; justify-content: center; }
.grp-kmt-empty { display: flex; align-items: center; justify-content: center; color: var(--grp-text-muted); }
.grp-kmt-empty .material-icons, .grp-kmt-big .material-icons { font-size: 22px; }
.grp-kmt-more { position: relative; background-size: cover; background-position: center; background-color: var(--grp-surface-2); display: flex; align-items: center; justify-content: center; }
.grp-kmt-more::before { content: ""; position: absolute; inset: 0; background: rgba(0,0,0,0.55); }
.grp-kmt-more-n { position: relative; z-index: 1; color: #fff; font-weight: 700; font-size: 18px; text-shadow: 0 1px 3px rgba(0,0,0,0.5); }
.grp-kmt-more-solid { background-color: var(--grp-accent); }
.grp-kmt-more-solid::before { background: transparent; }
/* "Kit" corner badge on the image */
.grp-kit-badge { position: absolute; top: 8px; left: 8px; background: var(--grp-accent); color: var(--grp-accent-text); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; padding: 3px 8px; border-radius: var(--grp-r-xs); z-index: 2; }
.grp-kit-badge-inline { position: static; display: inline-block; margin-right: 6px; }
/* "save X%" pill next to availability */
.grp-kit-save { display: inline-block; margin-left: 8px; background: var(--grp-green); color: #fff; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: var(--grp-r-xs); }
.grp-row-kit .grp-row-img-wrap, .grp-card-kit .grp-card-img-wrap { position: relative; }

/* Savings banner in the kit modal */
.grp-kit-banner { display: flex; align-items: center; gap: 11px; background: rgba(52,168,83,0.12); border: 1px solid rgba(52,168,83,0.34); border-radius: var(--grp-r); padding: 12px 14px; margin: 14px 0; }
.grp-kit-banner .material-icons { color: var(--grp-green); font-size: 26px; }
.grp-kit-banner strong { display: block; color: var(--grp-green); font-size: 14px; }
.grp-kit-banner span { display: block; color: var(--grp-text-2); font-size: 12px; margin-top: 1px; }

/* "What's included" list */
.grp-kit-includes { margin: 16px 0; }
.grp-kit-includes-title { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--grp-text-muted); font-weight: 700; margin-bottom: 8px; }
.grp-kit-inc-row { display: flex; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--grp-border); font-size: 14px; }
.grp-kit-inc-row:last-child { border-bottom: none; }
.grp-kit-inc-q { color: var(--grp-text-muted); font-weight: 600; min-width: 26px; }
.grp-kit-inc-n { color: var(--grp-text); }

/* Modal gallery */
.grp-kit-gallery { position: absolute; inset: 0; }
.grp-kit-gallery-stage { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.grp-kit-gallery-stage img { width: 100%; height: 100%; object-fit: contain; padding: 12px; }
.grp-kit-gallery-stage .grp-kit-mosaic { width: 100%; height: 100%; gap: 3px; }
.grp-kg-arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border-radius: 50%; background: var(--grp-surface); border: 1px solid var(--grp-border); color: var(--grp-text); display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 1px 4px rgba(0,0,0,.15); }
.grp-kg-arrow:hover { background: var(--grp-surface-2); }
.grp-kg-prev { left: 8px; } .grp-kg-next { right: 8px; }
.grp-kg-cap { position: absolute; bottom: 30px; left: 0; right: 0; text-align: center; font-size: 12px; color: var(--grp-text-2); background: linear-gradient(transparent, var(--grp-surface-2)); padding: 6px; }
.grp-kg-dots { position: absolute; bottom: 12px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; }
.grp-kg-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--grp-border); cursor: pointer; }
.grp-kg-dot.on { background: var(--grp-text); }
@media (max-width: 768px) {
    .grp-kg-cap { bottom: 28px; }
}

/* ============ Compact pagination (current of total) v1.10.1 ============ */
.grp-page-count { display: inline-flex; align-items: baseline; gap: 6px; padding: 0 14px; font-size: 14px; color: var(--grp-text-2); user-select: none; }
.grp-page-cur { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 30px; padding: 0 9px; border-radius: 999px; background: var(--grp-accent); color: var(--grp-accent-text); font-weight: 700; }
.grp-page-of { color: var(--grp-text-muted); font-weight: 500; }

/* What's included (accessory manifest) in item detail */
.grp-detail-includes{margin:12px 0 16px}
.grp-includes-title{font-size:11px;font-weight:700;letter-spacing:.6px;text-transform:uppercase;color:#5c6b45;margin-bottom:7px}
.grp-includes-list{margin:0;padding-left:18px;font-size:13px;line-height:1.5;color:var(--grp-text-2);column-count:2;column-gap:28px}
.grp-includes-list li{margin:3px 0;break-inside:avoid}
.grp-includes-list li::marker{color:var(--grp-text-muted)}
@media (prefers-color-scheme: dark){.grp-includes-title{color:#a3b183}}
@media (max-width:600px){.grp-includes-list{column-count:1}}

/* ============================================================================
   Tier 1 storefront enhancements (v1.24.0)
   ========================================================================== */

/* 1. Card hover: lift + shadow + image zoom */
.grp-card{transition:transform .2s ease,box-shadow .2s ease}
.grp-card:hover{transform:translateY(-4px);box-shadow:0 12px 28px rgba(20,26,10,.14)}
.grp-card-img-wrap{overflow:hidden}
.grp-card-img-wrap img,.grp-card-img-wrap .grp-card-img-ph{transition:transform .35s ease}
.grp-card:hover .grp-card-img-wrap img,.grp-card:hover .grp-card-img-wrap .grp-card-img-ph{transform:scale(1.08)}

/* 2. Add feedback: stepper pop + toast (bounce removed in 1.24.1 — felt cheap) */
.grp-qty-stepper,.grp-addon-stepper{animation:grp-pop .25s cubic-bezier(.34,1.56,.64,1)}
@keyframes grp-pop{from{transform:scale(.82)}to{transform:scale(1)}}
#grp-toast{position:fixed;left:50%;bottom:96px;transform:translate(-50%,16px);background:#191c14;color:#fff;padding:11px 20px;border-radius:999px;font-size:13.5px;font-weight:600;opacity:0;pointer-events:none;transition:opacity .25s ease,transform .25s ease;box-shadow:0 12px 28px rgba(20,26,10,.25);z-index:2147483647}
#grp-toast.show{opacity:1;transform:translate(-50%,0)}

/* 3. Cart drawer polish: scrim blur + smoother slide */
.grp-cart-overlay{backdrop-filter:blur(2px);-webkit-backdrop-filter:blur(2px)}
.grp-cart-panel{transition:transform .3s cubic-bezier(.32,.72,.35,1)!important}

/* 4. Skeleton loading */
.grp-skel{pointer-events:none}
.grp-skel .grp-card-img-wrap{height:150px;background:var(--grp-surface-3);position:relative;overflow:hidden}
.grp-skel-line{height:13px;border-radius:6px;background:var(--grp-surface-3);margin:9px 14px;position:relative;overflow:hidden}
.grp-skel-line.w40{width:40%}.grp-skel-line.w80{width:80%}.grp-skel-line.w60{width:60%;margin-bottom:16px}
.grp-skel .grp-card-img-wrap::after,.grp-skel-line::after{content:"";position:absolute;inset:0;background:linear-gradient(90deg,transparent,var(--grp-skel-shine,rgba(255,255,255,.55)),transparent);animation:grp-shimmer 1.3s infinite}
@media (prefers-color-scheme: dark){:root{--grp-skel-shine:rgba(255,255,255,.09)}}
/* Date-change refresh: dim in place instead of wiping to skeletons */
#grp-grid.grp-grid-loading{opacity:.55;pointer-events:none;transition:opacity .2s ease}
#grp-grid{transition:opacity .2s ease}
@keyframes grp-shimmer{from{transform:translateX(-100%)}to{transform:translateX(100%)}}

/* 5. Sticky mobile cart bar (reshapes the FAB below 768px) */
#grp-fab-items,#grp-fab-total{display:none}
@media(max-width:767px){
  .grp-cart-fab{left:12px;right:12px;bottom:12px;width:auto;height:auto;border-radius:16px;padding:13px 18px;justify-content:space-between;align-items:center;background:#242b17;border:1px solid rgba(255,255,255,.09);box-shadow:0 14px 32px rgba(20,26,10,.35);transform:translateY(calc(100% + 16px))}
  .grp-cart-fab.visible{display:flex;transform:translateY(0);box-shadow:0 14px 32px rgba(20,26,10,.35)}
  .grp-cart-fab:hover{transform:translateY(0)}
  .grp-cart-fab .material-icons,.grp-cart-fab .grp-cart-fab-count{display:none}
  #grp-fab-items{display:block;font-size:11px;font-weight:500;color:#c9d3b4;text-align:left}
  #grp-fab-total{display:block;font-size:15px;font-weight:700;color:#fff}
  /* Keep the last cards' Add buttons scrollable above the fixed bar */
  body.grp-bar-on .grp-app{padding-bottom:92px}
}
/* Subtle total refresh cue (replaces the scale bounce) */
.grp-total-tick{animation:grp-total-tick .45s ease}
@keyframes grp-total-tick{0%{opacity:.35}100%{opacity:1}}

/* 6. Price recalc flash */
.grp-price-flash{animation:grp-pflash .7s ease}
@keyframes grp-pflash{0%{background:#eef1e7;border-radius:6px;box-shadow:0 0 0 4px #eef1e7}100%{background:transparent;box-shadow:none}}

/* 7. Tier hint */
.grp-tier-hint{font-size:11px;color:#5a7f3b;font-weight:600;margin:1px 0 2px}

/* 8. Unavailable treatment */
.grp-card-out .grp-card-img-wrap{filter:grayscale(.45) opacity(.8)}
.grp-card-out:hover{transform:none;box-shadow:none}
.grp-card-next-avail,.grp-row-next-avail{display:inline-block;background:#fdf0dd;color:#a35b00;font-size:11px;font-weight:700;padding:3px 9px;border-radius:999px}
