/* ==========================================================================
   Ofaar web — design system
   ========================================================================== */

:root {
    --brand: #ee2f36;
    --brand-600: #d61f27;
    --brand-700: #b3161d;
    --brand-50: #fff0f0;
    --brand-100: #ffdcdd;

    --ink-950: #0e111a;
    --ink-900: #161a26;
    --ink-800: #1f2433;
    --ink-700: #2b3141;
    --ink-600: #454c5e;
    --ink-500: #626a7e;
    --ink-400: #8b92a5;
    --ink-300: #b7bccb;
    --ink-200: #dcdfe8;
    --ink-100: #eceef4;
    --ink-50: #f5f6fa;

    --surface: #ffffff;
    --bg: #f6f7fb;
    --line: #e7e9f0;

    --green: #12a150;
    --green-50: #e8f7ee;
    --amber: #d98a04;
    --amber-50: #fff5e0;
    --violet: #7447e6;
    --violet-50: #f1ecff;
    --blue: #2563eb;
    --blue-50: #eaf1ff;

    --radius-sm: 10px;
    --radius: 16px;
    --radius-lg: 24px;
    --shadow-xs: 0 1px 2px rgba(16, 20, 34, .06);
    --shadow-sm: 0 2px 8px rgba(16, 20, 34, .06), 0 1px 2px rgba(16, 20, 34, .04);
    --shadow-md: 0 12px 32px -12px rgba(16, 20, 34, .18), 0 2px 6px rgba(16, 20, 34, .05);
    --shadow-lg: 0 30px 60px -20px rgba(16, 20, 34, .30);

    --font: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --container: 1240px;
    --nav-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.55;
    color: var(--ink-800);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, h5 { margin: 0; color: var(--ink-900); line-height: 1.2; letter-spacing: -.02em; }
p { margin: 0; }
hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--brand) 40%, transparent); outline-offset: 2px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding-inline: 24px; }
.muted { color: var(--ink-500); }
.small { font-size: 13px; }
.xs { font-size: 12px; }
.strong { font-weight: 700; }
.nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pre-line { white-space: pre-line; }
.text-brand { color: var(--brand); }
.text-green { color: var(--green); }
.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; align-items: center; gap: 12px; }
.row-wrap { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1 1 auto; min-width: 0; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; } .mt-48 { margin-top: 48px; }
.mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; }
.w-full { width: 100%; }

/* ---------- Buttons ---------- */
.btn {
    --btn-bg: var(--surface);
    --btn-fg: var(--ink-800);
    --btn-bd: var(--line);
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    height: 44px; padding: 0 18px;
    border-radius: 12px; border: 1px solid var(--btn-bd);
    background: var(--btn-bg); color: var(--btn-fg);
    font-weight: 600; font-size: 14px; white-space: nowrap;
    cursor: pointer; transition: background .15s, border-color .15s, color .15s, box-shadow .15s, transform .05s;
}
.btn:hover { background: var(--ink-50); }
.btn:active { transform: translateY(1px); }
.btn .bi { font-size: 1.05em; }
.btn-primary { --btn-bg: var(--brand); --btn-fg: #fff; --btn-bd: var(--brand); box-shadow: 0 8px 20px -8px rgba(238, 47, 54, .6); }
.btn-primary:hover { background: var(--brand-600); border-color: var(--brand-600); }
.btn-dark { --btn-bg: var(--ink-900); --btn-fg: #fff; --btn-bd: var(--ink-900); }
.btn-dark:hover { background: var(--ink-700); }
.btn-ghost { --btn-bg: transparent; --btn-bd: transparent; }
.btn-ghost:hover { background: var(--ink-100); }
.btn-soft { --btn-bg: var(--brand-50); --btn-fg: var(--brand-700); --btn-bd: transparent; }
.btn-soft:hover { background: var(--brand-100); }
.btn-success { --btn-bg: var(--green); --btn-fg: #fff; --btn-bd: var(--green); }
.btn-success:hover { background: #0e8a44; }
.btn-danger-outline { --btn-fg: var(--brand-700); --btn-bd: var(--brand-100); }
.btn-danger-outline:hover { background: var(--brand-50); }
.btn-white { --btn-bg: #fff; --btn-fg: var(--ink-900); --btn-bd: #fff; }
.btn-sm { height: 36px; padding: 0 12px; border-radius: 10px; font-size: 13px; }
.btn-lg { height: 52px; padding: 0 24px; border-radius: 14px; font-size: 15px; }
.btn-icon { width: 44px; padding: 0; }
.btn-icon.btn-sm { width: 36px; }
.btn[disabled], .btn.is-loading { opacity: .6; pointer-events: none; }
.link { color: var(--brand-600); font-weight: 600; }
.link:hover { text-decoration: underline; }

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.label { font-size: 13px; font-weight: 600; color: var(--ink-700); }
.hint { font-size: 12px; color: var(--ink-400); }
.input, .select, .textarea {
    width: 100%; height: 46px; padding: 0 14px;
    border: 1px solid var(--ink-200); border-radius: 12px;
    background: var(--surface); color: var(--ink-900);
    transition: border-color .15s, box-shadow .15s;
}
.textarea { height: auto; min-height: 120px; padding: 12px 14px; resize: vertical; line-height: 1.5; }
.select { appearance: none; padding-right: 38px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23626a7e' viewBox='0 0 16 16'%3E%3Cpath d='M1.6 5.1a.6.6 0 0 1 .85 0L8 10.66l5.55-5.56a.6.6 0 1 1 .85.85l-5.97 5.97a.6.6 0 0 1-.85 0L1.6 5.95a.6.6 0 0 1 0-.85z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.input::placeholder, .textarea::placeholder { color: var(--ink-300); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px rgba(238, 47, 54, .12); }
.input-icon { position: relative; }
.input-icon > .bi { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-400); pointer-events: none; }
.input-icon > .input { padding-left: 42px; }
.input-icon > .toggle-password { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--ink-400); cursor: pointer; padding: 8px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .span-2 { grid-column: span 2; }
.check { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; font-size: 14px; }
.check input { width: 18px; height: 18px; accent-color: var(--brand); }

.alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 12px; font-size: 14px; border: 1px solid; }
.alert .bi { font-size: 18px; line-height: 1.2; }
.alert-error { background: var(--brand-50); border-color: var(--brand-100); color: var(--brand-700); }
.alert-info { background: var(--blue-50); border-color: #d3e1ff; color: #1d4ed8; }
.alert-warn { background: var(--amber-50); border-color: #fde5b3; color: #92600a; }
.alert-success { background: var(--green-50); border-color: #c5ecd5; color: #0b7a3b; }
.alert ul { margin: 4px 0 0; padding-left: 18px; }

/* Segmented control */
.segmented { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; background: var(--ink-100); border-radius: 14px; }
.segmented input { position: absolute; opacity: 0; pointer-events: none; }
.segmented label { display: flex; align-items: center; justify-content: center; gap: 8px; height: 44px; border-radius: 10px; font-weight: 600; font-size: 14px; color: var(--ink-500); cursor: pointer; transition: all .15s; }
.segmented input:checked + label { background: var(--surface); color: var(--ink-900); box-shadow: var(--shadow-sm); }

/* Dropzone */
.dropzone { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 160px; padding: 20px; border: 2px dashed var(--ink-200); border-radius: var(--radius); background: var(--ink-50); text-align: center; color: var(--ink-500); cursor: pointer; transition: border-color .15s, background .15s; overflow: hidden; }
.dropzone:hover, .dropzone.is-dragging { border-color: var(--brand); background: var(--brand-50); }
.dropzone input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.dropzone .bi { font-size: 28px; color: var(--brand); }
.dropzone .dz-preview { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.preview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.preview-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); }

/* ---------- Cards & surfaces ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-xs); }
.card-pad { padding: 24px; }
.card-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 24px; border-bottom: 1px solid var(--line); }
.card-header h3 { font-size: 16px; }
.card-body { padding: 24px; }
.section { padding-block: 56px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.section-head h2 { font-size: 28px; }
.eyebrow { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); }

/* ---------- Badges, chips ---------- */
.badge { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; background: var(--ink-100); color: var(--ink-600); }
.badge .bi { font-size: 12px; }
.type-bogo { background: var(--violet-50); color: var(--violet); }
.type-discount { background: var(--brand-50); color: var(--brand-600); }
.type-cashback { background: var(--green-50); color: var(--green); }
.type-coupon { background: var(--amber-50); color: var(--amber); }
.status-live { background: var(--green-50); color: var(--green); }
.status-pending { background: var(--amber-50); color: var(--amber); }
.status-rejected { background: var(--brand-50); color: var(--brand-600); }
.status-muted { background: var(--ink-100); color: var(--ink-500); }
.status-urgent { background: var(--brand); color: #fff; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }

.chip { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: 14px; color: var(--ink-700); white-space: nowrap; transition: all .15s; cursor: pointer; }
.chip:hover { border-color: var(--ink-300); }
.chip.is-active, .chip:has(input:checked) { background: var(--ink-900); border-color: var(--ink-900); color: #fff; }
.chip input { display: none; }

.avatar { position: relative; flex: none; width: 40px; height: 40px; border-radius: 50%; display: inline-grid; place-items: center; background: linear-gradient(135deg, var(--brand), #ff7a45); color: #fff; font-weight: 700; font-size: 14px; overflow: hidden; }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #fff; }
.avatar-sm { width: 32px; height: 32px; font-size: 12px; }
.avatar-lg { width: 64px; height: 64px; font-size: 22px; }
.avatar-xl { width: 96px; height: 96px; font-size: 32px; border-radius: 24px; }
.avatar-square { border-radius: 14px; }
.avatar-ink { background: linear-gradient(135deg, var(--ink-700), var(--ink-900)); }

/* ---------- Top navigation ---------- */
.nav { position: sticky; top: 0; z-index: 50; height: var(--nav-h); background: rgba(255, 255, 255, .85); backdrop-filter: saturate(180%) blur(14px); -webkit-backdrop-filter: saturate(180%) blur(14px); border-bottom: 1px solid var(--line); }
.nav .container { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 22px; letter-spacing: -.04em; color: var(--ink-900); }
.brand img { width: 34px; height: 34px; }
.brand small { display: block; font-size: 10px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-400); margin-top: -4px; }
.brand-light { color: #fff; }
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a { height: 40px; display: inline-flex; align-items: center; gap: 8px; padding: 0 14px; border-radius: 10px; font-weight: 600; font-size: 14px; color: var(--ink-600); }
.nav-links a:hover { background: var(--ink-100); color: var(--ink-900); }
.nav-links a.is-active { color: var(--ink-900); background: var(--ink-100); }
.nav-search { flex: 1 1 auto; max-width: 420px; margin-left: auto; }
.nav-search .input { height: 42px; background: var(--ink-50); border-color: transparent; border-radius: 999px; }
.nav-search .input:focus { background: #fff; }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.nav-toggle { display: none; }

/* Dropdown (details/summary) */
.dropdown { position: relative; }
.dropdown > summary { list-style: none; cursor: pointer; }
.dropdown > summary::-webkit-details-marker { display: none; }
.dropdown-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 240px; padding: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); z-index: 60; animation: pop .14s ease-out; }
.dropdown-menu a, .dropdown-menu button { display: flex; width: 100%; align-items: center; gap: 10px; padding: 10px 12px; border: 0; background: none; border-radius: 10px; font-size: 14px; font-weight: 500; color: var(--ink-700); cursor: pointer; text-align: left; }
.dropdown-menu a:hover, .dropdown-menu button:hover { background: var(--ink-50); color: var(--ink-900); }
.dropdown-menu .bi { color: var(--ink-400); font-size: 16px; }
.dropdown-head { padding: 10px 12px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.user-trigger { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px 4px 4px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); }
.user-trigger:hover { border-color: var(--ink-300); }
@keyframes pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; background: var(--ink-950); color: #fff; }
.hero::before { content: ""; position: absolute; width: 720px; height: 720px; right: -180px; top: -320px; background: radial-gradient(circle, rgba(238, 47, 54, .55), transparent 62%); filter: blur(10px); }
.hero::after { content: ""; position: absolute; width: 560px; height: 560px; left: -220px; bottom: -340px; background: radial-gradient(circle, rgba(116, 71, 230, .35), transparent 65%); }
.hero-grid-bg { position: absolute; inset: 0; background-image: linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px); background-size: 56px 56px; mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%); }
.hero .container { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; padding-block: 72px 88px; }
.hero h1 { color: #fff; font-size: clamp(36px, 5vw, 60px); font-weight: 800; letter-spacing: -.035em; line-height: 1.04; }
.hero h1 em { font-style: normal; background: linear-gradient(90deg, #ff5a5f, #ff9a3d); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-lead { margin-top: 18px; font-size: 18px; color: rgba(255, 255, 255, .72); max-width: 540px; }
.hero-pill { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 14px 0 6px; border-radius: 999px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .12); font-size: 13px; font-weight: 600; margin-bottom: 22px; }
.hero-pill b { background: var(--brand); color: #fff; height: 22px; display: inline-grid; place-items: center; padding: 0 8px; border-radius: 999px; font-size: 11px; }
.hero-search { margin-top: 32px; display: flex; gap: 8px; padding: 8px; background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); max-width: 620px; }
.hero-search .input-icon { flex: 1 1 auto; }
.hero-search .input, .hero-search .select { border: 0; height: 52px; box-shadow: none !important; }
.hero-search .select { width: 190px; border-left: 1px solid var(--line); border-radius: 0; }
.hero-stats { display: flex; gap: 36px; margin-top: 36px; }
.hero-stats strong { display: block; font-size: 30px; font-weight: 800; letter-spacing: -.03em; }
.hero-stats span { font-size: 13px; color: rgba(255, 255, 255, .6); }
.hero-visual { position: relative; height: 440px; }
.hero-card { position: absolute; width: 270px; background: #fff; color: var(--ink-800); border-radius: 20px; padding: 10px; box-shadow: var(--shadow-lg); transition: transform .3s; }
.hero-card:hover { transform: translateY(-6px) rotate(0deg) !important; }
.hero-card .hc-img { aspect-ratio: 4/3; border-radius: 14px; overflow: hidden; background: var(--ink-100); }
.hero-card .hc-img img { width: 100%; height: 100%; object-fit: cover; }
.hero-card .hc-body { padding: 12px 6px 6px; }
.hero-card:nth-child(1) { left: 0; top: 40px; transform: rotate(-6deg); z-index: 1; }
.hero-card:nth-child(2) { right: 0; top: 0; transform: rotate(5deg); z-index: 2; }
.hero-card:nth-child(3) { left: 70px; bottom: -10px; transform: rotate(2deg); z-index: 3; }
.hero-placeholder { display: grid; place-items: center; height: 100%; border: 1px dashed rgba(255, 255, 255, .15); border-radius: 28px; color: rgba(255, 255, 255, .4); text-align: center; }
.hero-placeholder .bi { font-size: 64px; color: var(--brand); }

/* Category rail */
.rail { display: flex; gap: 10px; overflow-x: auto; scrollbar-width: none; padding: 2px 2px 8px; scroll-snap-type: x proximity; }
.rail::-webkit-scrollbar { display: none; }
.rail > * { scroll-snap-align: start; }
.category-tile { flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; width: 132px; height: 116px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); font-weight: 600; font-size: 13px; color: var(--ink-700); text-align: center; padding: 10px; transition: all .18s; }
.category-tile .bi { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 14px; font-size: 22px; background: var(--brand-50); color: var(--brand); transition: all .18s; }
.category-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: transparent; }
.category-tile:hover .bi { background: var(--brand); color: #fff; }

/* Banner carousel */
.carousel { position: relative; }
.carousel-track { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; border-radius: var(--radius-lg); }
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-slide { flex: 0 0 100%; scroll-snap-align: start; position: relative; aspect-ratio: 16/5; border-radius: var(--radius-lg); overflow: hidden; background: var(--ink-100); }
.carousel-slide img { width: 100%; height: 100%; object-fit: cover; }
.carousel-slide figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 28px 22px; background: linear-gradient(transparent, rgba(14, 17, 26, .75)); color: #fff; font-weight: 700; font-size: 20px; }
.carousel-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); box-shadow: var(--shadow-md); cursor: pointer; display: grid; place-items: center; font-size: 18px; z-index: 2; }
.carousel-btn.prev { left: 14px; } .carousel-btn.next { right: 14px; }
.carousel-dots { display: flex; justify-content: center; gap: 6px; margin-top: 14px; }
.carousel-dots button { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 999px; background: var(--ink-200); cursor: pointer; transition: all .2s; }
.carousel-dots button.is-active { width: 24px; background: var(--brand); }

/* ---------- Offer card ---------- */
.offer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px; }
.offer-grid.cols-3 { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.offer-card { position: relative; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; transition: transform .2s ease, box-shadow .2s ease, border-color .2s; }
.offer-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: transparent; }
.offer-card .oc-media { position: relative; aspect-ratio: 4/3; background: linear-gradient(135deg, var(--ink-100), var(--ink-50)); overflow: hidden; }
.offer-card .oc-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.offer-card:hover .oc-media img { transform: scale(1.05); }
.offer-card .oc-media .oc-fallback { position: absolute; inset: 0; display: grid; place-items: center; color: var(--ink-300); font-size: 40px; }
.offer-card .oc-top { position: absolute; top: 12px; left: 12px; right: 12px; display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.offer-card .oc-top .badge { box-shadow: var(--shadow-sm); }
.offer-card .oc-top .badge:not([class*="type-"]):not([class*="status-"]) { background: rgba(255, 255, 255, .95); }
.offer-card .oc-body { display: flex; flex-direction: column; gap: 6px; padding: 16px 18px 18px; flex: 1; }
.offer-card .oc-company { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--ink-500); }
.offer-card .oc-title { font-size: 16px; font-weight: 700; color: var(--ink-900); letter-spacing: -.01em; line-height: 1.35; }
.offer-card .oc-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 10px; font-size: 12px; color: var(--ink-500); }
.offer-card .oc-foot .ends { display: inline-flex; align-items: center; gap: 5px; font-weight: 600; }
.offer-card .oc-foot .ends.soon { color: var(--brand-600); }
.offer-card .stretched::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.wish-btn { position: relative; z-index: 2; width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .95); color: var(--ink-600); display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow-sm); transition: transform .15s, color .15s; font-size: 16px; }
.wish-btn:hover { transform: scale(1.08); color: var(--brand); }
.wish-btn.is-active { color: var(--brand); }
.wish-btn.is-active .bi-heart::before { content: "\f415"; }
.wish-btn.bump, .wish-toggle.bump { animation: bump .35s ease; }
.wish-toggle.is-active { color: var(--brand-600); background: var(--brand-50); border-color: var(--brand-100); }
.wish-toggle.is-active .bi-heart::before { content: "\f415"; }
@keyframes bump { 40% { transform: scale(1.25); } }

/* ---------- Browse layout ---------- */
.page-head { padding-block: 36px 24px; }
.page-head h1 { font-size: 32px; font-weight: 800; }
.browse { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 28px; align-items: start; padding-bottom: 64px; }
.filters { position: sticky; top: calc(var(--nav-h) + 20px); display: flex; flex-direction: column; gap: 22px; padding: 22px; }
.filters h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-500); margin-bottom: 10px; }
.filter-list { display: flex; flex-direction: column; gap: 4px; max-height: 280px; overflow-y: auto; }
.filter-list label { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; cursor: pointer; font-size: 14px; }
.filter-list label:hover { background: var(--ink-50); }
.filter-list input { accent-color: var(--brand); width: 16px; height: 16px; }
.filter-list .child { padding-left: 32px; font-size: 13px; color: var(--ink-600); }
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.active-filters { display: flex; gap: 8px; flex-wrap: wrap; }
.active-filters a { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 999px; background: var(--ink-900); color: #fff; font-size: 13px; font-weight: 600; }
.pagination { display: flex; justify-content: center; align-items: center; gap: 6px; margin-top: 36px; }
.pagination a, .pagination span { min-width: 40px; height: 40px; display: grid; place-items: center; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; font-size: 14px; }
.pagination a:hover { border-color: var(--ink-300); }
.pagination .is-active { background: var(--ink-900); border-color: var(--ink-900); color: #fff; }
.pagination .is-disabled { opacity: .4; pointer-events: none; }
.filter-toggle { display: none; }

/* ---------- Empty state ---------- */
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 56px 24px; }
.empty .empty-icon { width: 72px; height: 72px; border-radius: 22px; display: grid; place-items: center; font-size: 30px; background: var(--brand-50); color: var(--brand); margin-bottom: 6px; }
.empty h3 { font-size: 18px; }
.empty p { color: var(--ink-500); max-width: 380px; }

/* ---------- Offer details ---------- */
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-500); padding-block: 22px; flex-wrap: wrap; }
.breadcrumb a:hover { color: var(--ink-900); }
.details { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.gallery-main { position: relative; aspect-ratio: 4/3; border-radius: var(--radius-lg); overflow: hidden; background: var(--ink-100); }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 10px; margin-top: 12px; }
.gallery-thumbs button { padding: 0; border: 2px solid transparent; border-radius: 12px; overflow: hidden; aspect-ratio: 1; cursor: pointer; background: var(--ink-100); opacity: .7; transition: all .15s; }
.gallery-thumbs button img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumbs button.is-active, .gallery-thumbs button:hover { border-color: var(--brand); opacity: 1; }
.details-side { position: sticky; top: calc(var(--nav-h) + 20px); display: flex; flex-direction: column; gap: 18px; }
.details-title { font-size: clamp(26px, 3vw, 36px); font-weight: 800; }
.countdown { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.countdown div { background: var(--ink-900); color: #fff; border-radius: 12px; padding: 10px 6px; text-align: center; }
.countdown strong { display: block; font-size: 22px; font-weight: 800; font-variant-numeric: tabular-nums; }
.countdown span { font-size: 11px; color: rgba(255, 255, 255, .6); text-transform: uppercase; letter-spacing: .06em; }
.meta-list { display: flex; flex-direction: column; }
.meta-list > div { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.meta-list > div:last-child { border-bottom: 0; }
.meta-list .bi { width: 38px; height: 38px; flex: none; display: grid; place-items: center; border-radius: 12px; background: var(--ink-50); color: var(--ink-600); font-size: 17px; }
.meta-list dt { font-size: 12px; color: var(--ink-400); font-weight: 600; }
.meta-list dd { margin: 0; font-weight: 600; color: var(--ink-800); }
.company-mini { display: flex; align-items: center; gap: 14px; }
.review-banner { display: flex; gap: 12px; align-items: center; padding: 14px 18px; border-radius: 14px; font-weight: 600; font-size: 14px; }

/* Comments */
.comment { display: flex; gap: 14px; }
.comment + .comment { margin-top: 22px; }
.comment-bubble { background: var(--ink-50); border-radius: 4px 16px 16px 16px; padding: 12px 16px; }
.comment-bubble strong { font-size: 14px; }
.comment-replies { margin-top: 14px; padding-left: 18px; border-left: 2px solid var(--line); }
.comment-actions { display: flex; gap: 14px; margin-top: 6px; font-size: 12px; font-weight: 600; color: var(--ink-500); }
.comment-actions button { border: 0; background: none; padding: 0; color: inherit; font-weight: 600; cursor: pointer; }
.comment-actions button:hover { color: var(--brand); }
.comment-form { display: flex; gap: 12px; align-items: flex-start; }
.comment-form .textarea { min-height: 52px; height: 52px; border-radius: 14px; }
.comment-form .textarea:focus { height: 96px; }

/* ---------- Company profile ---------- */
.company-cover { position: relative; height: 220px; background: var(--ink-950); overflow: hidden; }
.company-cover::before { content: ""; position: absolute; width: 520px; height: 520px; right: -120px; top: -260px; background: radial-gradient(circle, rgba(238, 47, 54, .55), transparent 62%); }
.company-cover .hero-grid-bg { opacity: .8; }
.company-head { position: relative; display: flex; align-items: flex-end; gap: 22px; margin-top: -64px; padding-bottom: 28px; flex-wrap: wrap; }
.company-head .avatar-xl { width: 128px; height: 128px; border-radius: 30px; border: 5px solid var(--bg); box-shadow: var(--shadow-md); font-size: 42px; background: #fff; color: var(--brand); }
.company-head h1 { font-size: 32px; font-weight: 800; }
.branch-card { padding: 18px; display: flex; flex-direction: column; gap: 6px; }

/* ---------- Auth ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; background: var(--surface); }
.auth-art { position: relative; overflow: hidden; background: var(--ink-950); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-art::before { content: ""; position: absolute; width: 700px; height: 700px; right: -260px; top: -200px; background: radial-gradient(circle, rgba(238, 47, 54, .6), transparent 62%); }
.auth-art::after { content: ""; position: absolute; width: 500px; height: 500px; left: -200px; bottom: -260px; background: radial-gradient(circle, rgba(116, 71, 230, .4), transparent 65%); }
.auth-art > * { position: relative; z-index: 1; }
.auth-art h2 { color: #fff; font-size: 44px; font-weight: 800; letter-spacing: -.035em; line-height: 1.08; max-width: 480px; }
.auth-art p { color: rgba(255, 255, 255, .7); font-size: 17px; max-width: 440px; margin-top: 16px; }
.auth-floats { display: flex; flex-direction: column; gap: 12px; max-width: 360px; }
.auth-float { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1); border-radius: 16px; backdrop-filter: blur(8px); }
.auth-float .bi { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; background: var(--brand); font-size: 18px; flex: none; }
.auth-float:nth-child(2) { margin-left: 40px; } .auth-float:nth-child(2) .bi { background: var(--violet); }
.auth-float:nth-child(3) .bi { background: var(--green); }
.auth-float strong { display: block; font-size: 14px; }
.auth-float span { font-size: 13px; color: rgba(255, 255, 255, .6); }
.auth-panel { display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.auth-box { width: 100%; max-width: 420px; }
.auth-box h1 { font-size: 30px; font-weight: 800; }
.auth-box .lead { color: var(--ink-500); margin-top: 8px; margin-bottom: 28px; }
.otp-input { letter-spacing: .6em; text-align: center; font-size: 22px; font-weight: 700; height: 60px; }

/* ---------- Portal (merchant / admin) ---------- */
.portal { display: grid; grid-template-columns: 264px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; background: var(--ink-950); color: rgba(255, 255, 255, .7); padding: 22px 16px; overflow-y: auto; }
.sidebar .brand { color: #fff; padding: 4px 10px 22px; }
.sidebar .brand small { color: rgba(255, 255, 255, .45); }
.side-label { padding: 18px 12px 8px; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: rgba(255, 255, 255, .35); }
.side-link { display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 12px; border-radius: 12px; font-weight: 600; font-size: 14px; color: rgba(255, 255, 255, .7); transition: all .15s; }
.side-link .bi { font-size: 18px; }
.side-link:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.side-link.is-active { background: rgba(238, 47, 54, .16); color: #fff; box-shadow: inset 3px 0 0 var(--brand); }
.side-link .count { margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px; background: var(--brand); color: #fff; font-size: 11px; display: grid; place-items: center; }
.side-cta { margin-top: 18px; }
.side-foot { margin-top: auto; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, .08); }
.side-user { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; }
.side-user strong { color: #fff; font-size: 14px; display: block; }
.side-user span { font-size: 12px; color: rgba(255, 255, 255, .45); }
.portal-main { min-width: 0; }
.portal-top { position: sticky; top: 0; z-index: 40; height: 68px; display: flex; align-items: center; gap: 14px; padding: 0 32px; background: rgba(246, 247, 251, .85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.portal-top h1 { font-size: 20px; font-weight: 800; }
.portal-content { padding: 28px 32px 56px; max-width: 1320px; }
.portal-toggle { display: none; }
.portal-backdrop { display: none; }

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.stat { position: relative; padding: 20px 22px; display: flex; flex-direction: column; gap: 6px; overflow: hidden; }
.stat-icon { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; font-size: 20px; margin-bottom: 8px; }
.stat strong { font-size: 32px; font-weight: 800; letter-spacing: -.03em; color: var(--ink-900); line-height: 1; }
.stat span { font-size: 13px; color: var(--ink-500); font-weight: 600; }
.stat a.stat-link { position: absolute; inset: 0; }
.stat:has(a.stat-link):hover { box-shadow: var(--shadow-md); }
.ic-green { background: var(--green-50); color: var(--green); }
.ic-amber { background: var(--amber-50); color: var(--amber); }
.ic-red { background: var(--brand-50); color: var(--brand); }
.ic-violet { background: var(--violet-50); color: var(--violet); }
.ic-blue { background: var(--blue-50); color: var(--blue); }
.ic-ink { background: var(--ink-100); color: var(--ink-600); }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.grid-main-side { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 22px; align-items: start; }

.tabs { display: flex; gap: 4px; padding: 4px; background: var(--ink-100); border-radius: 14px; overflow-x: auto; scrollbar-width: none; }
.tabs a { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 10px; font-weight: 600; font-size: 14px; color: var(--ink-500); white-space: nowrap; }
.tabs a:hover { color: var(--ink-900); }
.tabs a.is-active { background: var(--surface); color: var(--ink-900); box-shadow: var(--shadow-sm); }
.tabs a .count { min-width: 22px; height: 20px; padding: 0 7px; border-radius: 999px; background: var(--ink-200); color: var(--ink-700); font-size: 11px; display: grid; place-items: center; }
.tabs a.is-active .count { background: var(--brand); color: #fff; }

.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-400); padding: 12px 20px; border-bottom: 1px solid var(--line); background: var(--ink-50); white-space: nowrap; }
.table td { padding: 14px 20px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr { transition: background .12s; }
.table tbody tr:hover { background: #fafbfd; }
.table .thumb { width: 64px; height: 48px; border-radius: 10px; object-fit: cover; background: var(--ink-100); flex: none; }
.thumb-fallback { width: 64px; height: 48px; border-radius: 10px; background: var(--ink-100); display: grid; place-items: center; color: var(--ink-300); flex: none; }

.list-item { display: flex; align-items: center; gap: 14px; padding: 14px 24px; border-bottom: 1px solid var(--line); }
.list-item:last-child { border-bottom: 0; }
a.list-item:hover { background: #fafbfd; }

.company-card { padding: 22px; display: flex; flex-direction: column; gap: 14px; transition: box-shadow .2s, transform .2s; }
.company-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.welcome { position: relative; overflow: hidden; background: var(--ink-950); color: #fff; border-radius: var(--radius-lg); padding: 30px 32px; display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.welcome::before { content: ""; position: absolute; width: 460px; height: 460px; right: -120px; top: -240px; background: radial-gradient(circle, rgba(238, 47, 54, .55), transparent 62%); }
.welcome > * { position: relative; }
.welcome h2 { color: #fff; font-size: 26px; font-weight: 800; }
.welcome p { color: rgba(255, 255, 255, .65); margin-top: 6px; }

.review-hero { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 22px; align-items: start; }
.decision { position: sticky; top: 88px; }

.banner-card { overflow: hidden; }
.banner-card img { width: 100%; aspect-ratio: 16/6; object-fit: cover; background: var(--ink-100); }

/* ---------- Chat ---------- */
.chat { display: grid; grid-template-columns: 340px minmax(0, 1fr); height: calc(100vh - var(--nav-h) - 48px); min-height: 520px; overflow: hidden; }
.chat-list { border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; }
.chat-list-head { padding: 20px; border-bottom: 1px solid var(--line); }
.chat-items { overflow-y: auto; flex: 1; }
.chat-item { display: flex; gap: 12px; align-items: center; padding: 14px 20px; border-bottom: 1px solid var(--ink-100); }
.chat-item:hover { background: var(--ink-50); }
.chat-item.is-active { background: var(--brand-50); box-shadow: inset 3px 0 0 var(--brand); }
.chat-thread { display: flex; flex-direction: column; min-height: 0; }
.chat-thread-head { display: flex; align-items: center; gap: 12px; padding: 14px 22px; border-bottom: 1px solid var(--line); }
.chat-messages { flex: 1; overflow-y: auto; padding: 24px; display: flex; flex-direction: column; gap: 6px; background: linear-gradient(var(--ink-50), #fff); }
.msg { max-width: min(70%, 520px); padding: 10px 14px; border-radius: 18px; font-size: 14px; line-height: 1.45; word-wrap: break-word; white-space: pre-wrap; box-shadow: var(--shadow-xs); }
.msg time { display: block; font-size: 10px; margin-top: 4px; opacity: .6; }
.msg-them { align-self: flex-start; background: #fff; border: 1px solid var(--line); border-bottom-left-radius: 6px; }
.msg-mine { align-self: flex-end; background: var(--ink-900); color: #fff; border-bottom-right-radius: 6px; }
.msg-date { align-self: center; font-size: 11px; font-weight: 600; color: var(--ink-400); background: var(--ink-100); border-radius: 999px; padding: 3px 10px; margin: 10px 0; }
.chat-compose { display: flex; gap: 10px; padding: 14px 18px; border-top: 1px solid var(--line); background: #fff; }
.chat-compose .textarea { min-height: 46px; height: 46px; border-radius: 14px; padding-top: 11px; resize: none; }

/* ---------- Toasts ---------- */
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 200; display: flex; flex-direction: column; gap: 10px; max-width: calc(100vw - 40px); }
.toast { display: flex; align-items: center; gap: 12px; min-width: 280px; max-width: 420px; padding: 14px 16px; border-radius: 14px; background: var(--ink-900); color: #fff; box-shadow: var(--shadow-lg); font-size: 14px; font-weight: 500; animation: toast-in .3s cubic-bezier(.2, .9, .3, 1.2); }
.toast .bi { font-size: 18px; }
.toast.success .bi { color: #4ade80; }
.toast.error .bi { color: #ff7b7f; }
.toast.is-leaving { animation: toast-out .25s ease forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateY(12px) scale(.96); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(8px); } }

/* ---------- Dialog ---------- */
dialog.modal { width: min(520px, calc(100vw - 32px)); border: 0; padding: 0; border-radius: 22px; box-shadow: var(--shadow-lg); color: var(--ink-800); }
dialog.modal::backdrop { background: rgba(14, 17, 26, .55); backdrop-filter: blur(3px); }
dialog.modal[open] { animation: pop .18s ease-out; }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.modal-head h3 { font-size: 18px; }
.modal-body { padding: 24px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--line); background: var(--ink-50); }

.search-results { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; max-height: 300px; overflow-y: auto; }
.search-result { display: flex; align-items: center; gap: 12px; padding: 10px; border: 1px solid var(--line); border-radius: 12px; }

/* ---------- Footer ---------- */
.footer { background: var(--ink-950); color: rgba(255, 255, 255, .6); margin-top: 40px; }
.footer .container { padding-block: 56px 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 40px; }
.footer h5 { color: #fff; font-size: 14px; margin-bottom: 14px; }
.footer a { display: block; padding: 5px 0; font-size: 14px; }
.footer a:hover { color: #fff; }
.footer-bottom { margin-top: 44px; padding-top: 22px; border-top: 1px solid rgba(255, 255, 255, .08); display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 13px; }
.cta-band { position: relative; overflow: hidden; border-radius: var(--radius-lg); background: linear-gradient(120deg, var(--brand), #ff7a45); color: #fff; padding: 44px; display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.cta-band h2 { color: #fff; font-size: 30px; font-weight: 800; }
.cta-band p { color: rgba(255, 255, 255, .85); margin-top: 8px; max-width: 520px; }
.cta-band::after { content: "%"; position: absolute; right: 26%; top: -60px; font-size: 260px; font-weight: 800; color: rgba(255, 255, 255, .08); line-height: 1; }

.skeleton { background: linear-gradient(90deg, var(--ink-100), var(--ink-50), var(--ink-100)); background-size: 200% 100%; animation: shimmer 1.2s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
    .hero .container { grid-template-columns: 1fr; }
    .hero-visual { display: none; }
    .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .grid-main-side, .review-hero { grid-template-columns: 1fr; }
    .decision { position: static; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 960px) {
    .nav-links, .nav-search { display: none; }
    .nav-toggle { display: inline-flex; margin-left: auto; }
    .nav.is-open .nav-links { display: flex; position: absolute; top: var(--nav-h); left: 0; right: 0; flex-direction: column; align-items: stretch; padding: 12px 16px 18px; background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md); }
    .browse { grid-template-columns: 1fr; }
    .filters { position: fixed; inset: 0 auto 0 0; width: min(340px, 88vw); z-index: 90; border-radius: 0 20px 20px 0; overflow-y: auto; transform: translateX(-105%); transition: transform .25s ease; }
    .filters.is-open { transform: none; box-shadow: var(--shadow-lg); }
    .filter-toggle { display: inline-flex; }
    .details { grid-template-columns: 1fr; }
    .details-side { position: static; }
    .auth { grid-template-columns: 1fr; }
    .auth-art { display: none; }
    .portal { grid-template-columns: 1fr; }
    .sidebar { position: fixed; left: 0; top: 0; z-index: 100; width: 272px; transform: translateX(-105%); transition: transform .25s ease; }
    .portal.is-open .sidebar { transform: none; }
    .portal.is-open .portal-backdrop { display: block; position: fixed; inset: 0; z-index: 99; background: rgba(14, 17, 26, .5); }
    .portal-toggle { display: inline-flex; }
    .portal-top { padding: 0 16px; }
    .portal-content { padding: 20px 16px 48px; }
    .chat { grid-template-columns: 1fr; height: auto; min-height: 0; }
    .chat.has-thread .chat-list { display: none; }
    .chat:not(.has-thread) .chat-thread { display: none; }
    .chat-thread { height: calc(100vh - var(--nav-h) - 32px); }
    .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

.mobile-only { display: none !important; }
@media (max-width: 960px) {
    .nav.is-open .nav-links .mobile-only { display: flex !important; }
}

@media (max-width: 640px) {
    body { font-size: 14px; }
    .brand small { display: none; }
    .nav .container { gap: 12px; }
    .nav-actions { gap: 4px; }
    .nav-actions .desktop-only { display: none; }
    .container { padding-inline: 16px; }
    .hero .container { padding-block: 48px 56px; }
    .hero-search { flex-direction: column; }
    .hero-search .select { width: 100%; border-left: 0; border-top: 1px solid var(--line); }
    .hero-stats { gap: 22px; }
    .hero-stats strong { font-size: 24px; }
    .section { padding-block: 40px; }
    .section-head h2 { font-size: 22px; }
    .offer-grid, .offer-grid.cols-3 { grid-template-columns: repeat(auto-fill, minmax(100%, 1fr)); gap: 16px; }
    .form-grid { grid-template-columns: 1fr; }
    .form-grid .span-2 { grid-column: auto; }
    .stats { grid-template-columns: 1fr 1fr; gap: 12px; }
    .stat { padding: 16px; }
    .stat strong { font-size: 26px; }
    .carousel-slide { aspect-ratio: 16/8; }
    .cta-band { padding: 28px; }
    .footer-grid { grid-template-columns: 1fr; }
    .card-body, .card-pad { padding: 18px; }
    .card-header { padding: 16px 18px; }
    .list-item { padding: 12px 18px; }
    .table th, .table td { padding: 12px 14px; }
    .company-head .avatar-xl { width: 104px; height: 104px; }
    .msg { max-width: 85%; }
    .countdown strong { font-size: 18px; }
}
