:root {
    --primary: #24d8ff;
    --primary-dark: #083a56;
    --holo-violet: #7c5cff;
    --holo-mint: #30e6c7;
    --holo-ink: #172033;
    --bg: #eef4f8;
    --text: #172033;
    --muted: #6b7487;
    --line: rgba(126, 152, 176, .28);
    --soft: rgba(255,255,255,.66);
    --primary-soft: rgba(36, 216, 255, .13);
    --page-pad: 20px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    color: var(--text);
    font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    -webkit-text-size-adjust: 100%;
    background: #eef4f8;
}

img { max-width: 100%; }
button, input, textarea, select { font: inherit; }

.page-topbar,
.client-page-head {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    background: #fff;
    border-bottom: 1px solid rgba(36,216,255,.18);
}

.page-topbar h2,
.client-page-head h2 {
    margin: 10px 0;
    overflow-wrap: anywhere;
}

.page-topbar h2,
.client-page-head h2,
.panel h3,
.panel h4,
.customer-container h1 {
    color: var(--holo-ink);
    font-family: "Roboto Slab", Roboto, sans-serif;
    font-weight: 800;
    letter-spacing: 0;
}

.crm-search {
    flex: 1 1 420px;
    max-width: 760px;
    min-width: min(100%, 260px);
}

.crm-search input {
    width: 100%;
    min-height: 42px;
    margin: 0;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid rgba(126, 152, 176, .36);
    background: rgba(255,255,255,.88);
    font-weight: 700;
}

.crm-search input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(36, 216, 255, .18);
}

.column-empty {
    display: none;
    padding: 14px;
    color: #7b8797;
    font-size: 13px;
    text-align: center;
}

.kanban-board {
    display: grid;
    grid-template-columns: repeat(5, minmax(210px, 1fr));
    gap: 15px;
    padding: var(--page-pad);
    overflow-x: auto;
    background: transparent;
}

.column {
    min-width: 250px;
    min-height: 520px;
    padding: 10px;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #e8eef4;
    box-shadow: 0 8px 18px rgba(38, 67, 93, .06);
}

.col-header {
    font-weight: bold;
    margin-bottom: 10px;
    text-transform: uppercase;
    color: var(--primary-dark);
    border-bottom: 1px solid rgba(36,216,255,.22);
    padding-bottom: 5px;
    font-size: 13px;
    letter-spacing: .02em;
}

.client-card {
    background: #fff;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    cursor: pointer;
    border: 1px solid #eef2f6;
    border-left: 4px solid var(--primary);
    position: relative;
    content-visibility: auto;
    contain-intrinsic-size: 168px;
}

.client-card:hover {
    border-color: rgba(36,216,255,.44);
}

.client-card.status-sold { border-left-color: #2f9e6b; }
.client-card.status-refused { border-left-color: #c05656; }

.column-refused .col-header { color: #a33; }

.card-status {
    width: 100%;
    margin: 8px 0 0;
    padding: 6px 8px;
    min-height: 32px;
    border-radius: 6px;
    border: 1px solid rgba(126, 152, 176, .36);
    background: #fff;
    color: #172033;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}

.client-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    margin-top: 6px;
}

.seller-badge {
    font-size: 11px;
    background: rgba(36,216,255,.12);
    color: var(--primary-dark);
    border: 1px solid rgba(36,216,255,.34);
    padding: 2px 6px;
    border-radius: 4px;
    display: inline-block;
}

.client-date {
    font-size: 12px;
    color: #6b7487;
    font-weight: 700;
}

.client-comment {
    margin-top: 4px;
    color: #526079;
    font-size: 12px;
    font-weight: 700;
}

.client-card-facts {
    margin-top: 12px;
    color: #51607b;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.45;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.field-hint {
    color: #6b7487;
    font-weight: 500;
    font-size: 12px;
}

.consent-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 4px 0 14px;
}

.consent-check input[type="checkbox"] {
    width: 18px;
    height: 18px;
    min-width: 18px;
    margin: 2px 0 0;
    flex: none;
    accent-color: var(--primary-dark);
    cursor: pointer;
}

.consent-check-text {
    font-size: 12px;
    line-height: 1.4;
    color: #3d4758;
}

.consent-check-text label {
    display: inline;
    cursor: pointer;
}

.consent-check-text a {
    color: #0c056d;
    font-weight: 700;
    text-decoration: underline;
}

.done-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 16px;
    background: rgba(36,216,255,.12);
    padding: 2px 6px;
    border-radius: 10px;
    border: 1px solid rgba(36,216,255,.34);
    color: var(--primary-dark);
}

.editor-container {
    width: min(1360px, calc(100% - (var(--page-pad) * 2)));
    margin: 20px auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 0;
}

.panel {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e8eef4;
    box-shadow: 0 8px 18px rgba(38, 67, 93, .06);
    min-width: 0;
}

.product-builder {
    background: #f7fbff;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e8eef4;
    margin-bottom: 20px;
}

input, textarea, select {
    width: 100%;
    padding: 10px;
    border: 1px solid rgba(126, 152, 176, .36);
    border-radius: 8px;
    margin-bottom: 10px;
    box-sizing: border-box;
    background: rgba(255,255,255,.82);
    color: #000;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.65);
}

input:focus, textarea:focus, select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(36,216,255,.18);
    outline: none;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    min-height: 40px;
    color: #001c2b;
    font-weight: 800;
    box-shadow: 0 1px 0 rgba(0, 34, 52, .06);
}

.btn:hover {
    box-shadow: 0 4px 10px rgba(0, 34, 52, .08);
}

.btn-blue,
.btn-green {
    border: 0;
    background: linear-gradient(135deg, var(--primary), var(--holo-mint));
    color: #082338;
}

.btn-green {
    background: linear-gradient(135deg, var(--holo-violet), #24d8ff);
    color: #fff;
}

.btn-red {
    background: rgba(255,255,255,.70);
    border: 1px solid rgba(126, 152, 176, .32);
    color: #5b6678;
}

.copy-link-btn {
    display: block;
    width: min(260px, 100%);
    margin: 10px auto 0;
    box-shadow: 0 12px 26px rgba(36,216,255,.18);
}

.deliv-group { display: flex; gap: 5px; margin-bottom: 10px; }

.deliv-btn {
    flex: 1;
    padding: 8px;
    border: 1px solid rgba(126, 152, 176, .30);
    background: rgba(255,255,255,.70);
    cursor: pointer;
    border-radius: 8px;
    text-align: center;
    font-size: 13px;
    color: var(--primary-dark);
    font-weight: 600;
}

.deliv-btn.active,
.p-card.selected .select-btn,
.selection-tab-wrap.active,
.product-tab-wrap.active {
    background: linear-gradient(135deg, var(--primary), var(--holo-violet));
    color: #fff;
    border-color: transparent;
    box-shadow: 0 10px 22px rgba(36,216,255,.22);
}

.gallery-container {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 10px;
    background: linear-gradient(135deg, rgba(255,255,255,.94), rgba(239,250,255,.80));
    border: 1px solid rgba(126, 152, 176, .24);
}

.gallery-scroll {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    height: 100%;
    scrollbar-width: none;
    scroll-behavior: smooth;
}

.gallery-scroll::-webkit-scrollbar { display: none; }

.gallery-item {
    min-width: 100%;
    height: 100%;
    scroll-snap-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.gallery-item img { max-width: 100%; max-height: 100%; object-fit: contain; }

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(8, 58, 86, .62);
    color: white;
    border: none;
    padding: 10px;
    cursor: pointer;
    z-index: 10;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 18px rgba(36,216,255,.18);
}

.g-prev { left: 10px; }
.g-next { right: 10px; }

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.p-card {
    background: #fff;
    border: 1px solid #e8eef4;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    box-shadow: 0 8px 18px rgba(38, 67, 93, .06);
    content-visibility: auto;
    contain-intrinsic-size: 420px;
}

.p-card.selected {
    border-color: var(--primary);
    background: rgba(244,253,255,.86);
}

.p-body {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.p-body h3,
.total-price { color: #000; }

.select-btn-wrap { margin-top: auto; padding-top: 15px; }

.select-btn {
    padding: 12px;
    border: 2px solid rgba(126, 152, 176, .30);
    border-radius: 8px;
    background: rgba(255,255,255,.70);
    color: var(--primary-dark);
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: 0.2s;
}

.select-btn input { width: auto; margin: 0; cursor: pointer; transform: scale(1.3); }

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    align-items: center;
    justify-content: center;
    z-index: 100;
}

.modal.show { display: flex; }

.modal-content {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    width: 400px;
    max-width: calc(100vw - 24px);
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    border: 1px solid #e8eef4;
    box-shadow: 0 12px 28px rgba(38, 67, 93, .12);
}

.product-tabs-nav {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) 34px;
    gap: 6px;
    align-items: center;
    margin: 8px 0 10px;
}

.product-tabs-scroll {
    min-width: 0;
    max-width: 100%;
    display: flex;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
    scroll-behavior: smooth;
    border-bottom: 1px solid rgba(126, 152, 176, .28);
    padding-bottom: 6px;
}

.product-tabs-scroll::-webkit-scrollbar { display: none; }

.tabs-arrow {
    width: 34px;
    height: 34px;
    border: 1px solid rgba(126, 152, 176, .30);
    border-radius: 6px;
    background: rgba(255,255,255,.70);
    color: var(--primary-dark);
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tabs-arrow:hover,
.selection-add-tab:hover {
    background: rgba(36,216,255,.14);
}

.product-tab-wrap {
    flex: 0 0 auto;
    min-width: 190px;
    max-width: 290px;
    display: flex;
    align-items: stretch;
    background: rgba(255,255,255,.70);
    border: 1px solid rgba(126, 152, 176, .30);
    border-radius: 4px;
    overflow: hidden;
}

.tab-btn {
    min-width: 0;
    padding: 8px 8px 8px 12px;
    flex: 1;
    cursor: pointer;
    background: transparent;
    color: inherit;
    border: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: left;
}

.product-tab-close {
    border: 0;
    background: transparent;
    color: currentColor;
    cursor: pointer;
    width: 30px;
    padding: 0 8px 2px 2px;
    font-size: 18px;
    line-height: 1;
    opacity: 0.75;
}

.product-tab-close:hover { opacity: 1; background: rgba(229, 62, 62, 0.14); color: #e53e3e; }
.product-tab-wrap.active .product-tab-close:hover { background: rgba(255,255,255,0.18); color: white; }

.selection-tabs {
    min-width: 0;
    max-width: 100%;
    display: flex;
    gap: 6px;
    align-items: flex-end;
    overflow-x: auto;
    border-bottom: 1px solid rgba(126, 152, 176, .28);
    margin-bottom: 12px;
    padding-top: 2px;
}

.selection-tab-wrap {
    display: flex;
    align-items: stretch;
    min-width: 110px;
    border: 1px solid rgba(126, 152, 176, .30);
    border-bottom: none;
    background: rgba(255,255,255,.70);
    border-radius: 8px 8px 0 0;
    overflow: hidden;
}

.selection-tab {
    border: 1px solid #cbd5e0;
    border-bottom: none;
    background: #edf2f7;
    color: #4a5568;
    padding: 10px 14px;
    border-radius: 8px 8px 0 0;
    cursor: pointer;
    font-weight: bold;
    white-space: nowrap;
    min-width: 110px;
}

.selection-tab.active { background: white; color: var(--primary); padding-top: 13px; }

.selection-tab-wrap .selection-tab {
    border: 0;
    background: transparent;
    border-radius: 0;
    min-width: 0;
    padding: 10px 8px 10px 14px;
    flex: 1;
}

.selection-tab-wrap.active .selection-tab {
    color: #fff;
    font-weight: 900;
    padding-top: 13px;
}

.product-tab-wrap.active .tab-btn {
    color: #fff;
    font-weight: 900;
}

.selection-tab-close {
    border: 0;
    background: transparent;
    color: currentColor;
    cursor: pointer;
    width: 28px;
    padding: 0 8px 2px 2px;
    font-size: 18px;
    line-height: 1;
}

.selection-tab-close:hover { color: #e53e3e; background: #fff5f5; }

.selection-add-tab {
    border: 1px solid rgba(126, 152, 176, .30);
    border-bottom: none;
    background: rgba(255,255,255,.70);
    color: var(--primary-dark);
    width: 38px;
    height: 36px;
    border-radius: 8px 8px 0 0;
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
    font-weight: bold;
}

.customer-set { display: none; }
.customer-set.active { display: block; }

.customer-container {
    width: min(1120px, 100%);
    margin: 0 auto;
    padding: 20px;
    padding-bottom: 120px;
}

.url-row { display: flex; gap: 5px; margin-bottom: 10px; }
.url-row input { min-width: 0; margin-bottom: 0; }
.parse-status {
    display: none;
    margin: -2px 0 12px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
}
.parse-status.show { display: block; }
.parse-status.ok { color: #129867; }
.parse-status.err { color: #c53030; }
#parseBtn { white-space: nowrap; min-width: 118px; }
#parseBtn[disabled] { opacity: .72; cursor: wait; }

.form-actions {
    margin-top: 15px;
    display: flex;
    gap: 10px;
    border-top: 1px solid #eee;
    padding-top: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.form-actions .save-btn { margin-left: auto; }

.choice-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    width: auto;
    background: rgba(36,216,255,.12);
    padding: 10px 14px;
    border: 1px solid rgba(36,216,255,.34);
    border-radius: 6px;
    font-weight: bold;
    color: var(--primary-dark);
}

.buyer-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #fff;
    padding: 15px;
    box-shadow: 0 -6px 16px rgba(0, 34, 52, .08);
    border-top: 1px solid #e8eef4;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    z-index: 999;
}

.total-price { font-size: 18px; font-weight: bold; }

@media (min-width: 1440px) {
    :root { --page-pad: 28px; }
    .grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
    .gallery-container { height: 280px; }
}

@media (max-width: 1180px) {
    .kanban-board { grid-template-columns: repeat(2, minmax(260px, 1fr)); }
    .grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
    .gallery-container { height: 220px; }
}

@media (max-width: 760px) {
    :root { --page-pad: 12px; }
    body {
        background: #eef4f8;
    }
    .page-topbar, .client-page-head { padding: 14px 12px; }
    .page-topbar h2, .client-page-head h2 { font-size: 22px; }
    .page-topbar .btn { width: 100%; }
    .kanban-board { display: flex; overflow-x: auto; gap: 12px; padding: 12px; scroll-snap-type: x mandatory; }
    .column { min-width: min(86vw, 360px); min-height: 360px; scroll-snap-align: start; }
    .editor-container { width: calc(100% - 16px); margin: 12px 0; gap: 12px; }
    .panel { padding: 14px; border-radius: 8px; }
    .product-builder { padding: 12px; }
    .grid { grid-template-columns: 1fr; gap: 12px; }
    .deliv-group { flex-direction: column; }
    .deliv-btn { min-height: 42px; }
    .url-row { flex-direction: column; }
    .url-row .btn { width: 100%; }
    .form-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
    .form-actions .btn { width: 100%; padding-left: 10px; padding-right: 10px; }
    .form-actions .save-btn { grid-column: 1 / -1; margin-left: 0; }
    .selection-tabs { gap: 4px; }
    .selection-tab-wrap { min-width: 118px; }
    .selection-tab, .selection-tab-wrap .selection-tab { font-size: 13px; padding-left: 10px; padding-right: 6px; }
    .selection-add-tab { flex: 0 0 38px; }
    .product-tabs-nav { grid-template-columns: 36px minmax(0, 1fr) 36px; gap: 5px; }
    .tabs-arrow { width: 36px; height: 36px; }
    .product-tab-wrap { min-width: 165px; max-width: 230px; }
    .tab-btn { min-height: 36px; }
    .gallery-container { height: 210px; }
    .modal-content { padding: 18px; }
    .customer-container { padding: 14px 12px 128px; }
    .buyer-bar { padding: 12px; }
    .buyer-bar .btn { max-width: none !important; }
    .btn:hover, .client-card:hover { transform: none; box-shadow: none; }
    .page-topbar, .client-page-head, .panel, .column, .product-builder, .p-card {
        box-shadow: 0 6px 14px rgba(38, 67, 93, .06);
    }
}

@media (max-width: 420px) {
    .page-topbar h2, .client-page-head h2 { font-size: 20px; }
    .column { min-width: 88vw; }
    .form-row { grid-template-columns: 1fr; }
    .client-card { padding: 12px; }
    .gallery-container { height: 190px; }
    .select-btn { padding: 11px; }
    .form-actions { grid-template-columns: 1fr; }
    .form-actions .save-btn { grid-column: auto; }
}

/* Real SaaS cockpit layout for the client card */
body.client-card-view {
    min-height: 100vh;
    overflow-x: hidden;
    background: #eef5f8;
}

.holo-app-shell {
    width: min(1500px, calc(100% - 32px));
    min-height: calc(100vh - 48px);
    margin: 24px auto 32px;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid #e8eef4;
    background: #fff;
    box-shadow: 0 12px 28px rgba(31, 68, 102, .08);
}

.holo-main {
    min-width: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.holo-topbar {
    min-height: 72px;
    display: grid;
    grid-template-columns: minmax(90px, auto) 1fr minmax(180px, auto);
    align-items: center;
    gap: 16px;
    padding: 14px 20px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,.78);
    background: #fff;
    box-shadow: 0 8px 18px rgba(31, 68, 102, .06);
}

.holo-back {
    color: #51607b;
    text-decoration: none;
    font-weight: 700;
}

.holo-brand {
    justify-self: center;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #5568ff;
    font-weight: 900;
    letter-spacing: .32em;
    font-size: 13px;
}

.holo-user {
    justify-self: end;
    min-width: 0;
    max-width: 100%;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid rgba(117, 148, 178, .22);
    background: rgba(255,255,255,.64);
    color: #172033;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.holo-workspace {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(270px, 330px) minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.holo-side {
    min-width: 0;
    display: grid;
    gap: 18px;
}

.holo-topbar > *,
.holo-workspace > *,
.holo-card,
.holo-builder-card .product-builder {
    min-width: 0;
}

.holo-card {
    margin: 0;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,.78);
    background: #fff;
    box-shadow: 0 8px 18px rgba(31, 68, 102, .06);
}

.holo-card-kicker {
    margin-bottom: 12px;
    color: #6771d8;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.holo-link-card h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
}

.holo-link-card input#shareLink {
    background: rgba(255,255,255,.78);
    font-size: 12px;
    line-height: 1.35;
}

.holo-link-card .copy-link-btn {
    width: 100%;
    margin: 10px 0 0;
}

.copy-msg {
    display: none;
    margin-top: 8px;
    color: #129867;
    font-size: 12px;
    text-align: center;
    font-weight: 700;
}

.holo-link-card hr {
    margin: 16px 0 10px;
    border: 0;
    border-top: 1px solid rgba(117, 148, 178, .28);
}

.empty-choice {
    color: #8a93a5;
    font-size: 13px;
    line-height: 1.35;
}

.holo-link-card .choice-badge {
    width: fit-content;
    max-width: 100%;
    margin-top: 0;
}

.holo-section-title {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 16px;
    color: #172033;
    font-size: 20px;
    font-weight: 900;
}

.holo-builder-card .product-builder {
    margin: 0;
    padding: 14px;
    border-color: rgba(117, 148, 178, .22);
    background: #f7fbff;
}

.holo-builder-card label {
    margin-top: 12px;
    color: #273149;
    font-weight: 700;
}

.holo-builder-card input,
.holo-builder-card textarea {
    min-height: 40px;
}

.holo-builder-card textarea {
    min-height: 96px;
}

.holo-preview-card {
    position: sticky;
    top: 20px;
}

.holo-preview-card #grid.grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.holo-preview-card .p-card {
    min-width: 0;
    overflow: hidden;
    border-radius: 8px;
}

.holo-preview-card .gallery-container {
    height: 150px;
    border-radius: 8px 8px 0 0;
}

.holo-preview-card .gallery-nav {
    width: 30px;
    height: 30px;
}

.holo-preview-card .p-body {
    padding: 10px;
    font-size: 12px;
}

.holo-preview-card .p-body h3 {
    font-size: 12px;
    line-height: 1.25;
    margin-bottom: 8px;
}

.holo-preview-card .price,
.holo-preview-card .p-body [style*="font-size:18px"] {
    font-size: 14px !important;
}

.holo-preview-card .p-body [style*="white-space:pre-wrap"] {
    max-height: 92px;
    overflow: auto;
    font-size: 11px !important;
}

.holo-preview-card .select-btn {
    padding: 8px;
    font-size: 12px;
}

body.customer-view-page {
    background: #eef5f8;
}

body.customer-view-page .customer-container {
    width: min(980px, calc(100% - 24px));
    padding-bottom: 120px;
}

body.customer-view-page .customer-container h1 {
    margin: 24px 0;
    color: #172033;
    font-size: clamp(24px, 5vw, 34px);
}

body.customer-view-page .customer-container .grid {
    gap: 18px;
}

@media (max-width: 1180px) {
    .holo-app-shell {
        width: min(1120px, calc(100% - 20px));
    }

    .holo-workspace {
        grid-template-columns: minmax(240px, 290px) minmax(0, 1fr);
        gap: 14px;
    }

    .holo-card {
        padding: 16px;
    }
}

@media (max-width: 900px) {
    .holo-app-shell {
        grid-template-columns: 1fr;
        width: calc(100% - 14px);
        margin: 7px auto 18px;
        min-height: auto;
    }

    .holo-main {
        padding: 10px;
        gap: 10px;
    }

    .holo-topbar {
        grid-template-columns: auto minmax(0, 1fr);
        gap: 10px;
        min-height: 0;
        padding: 12px;
    }

    .holo-brand {
        justify-self: end;
        letter-spacing: .18em;
    }

    .holo-user {
        grid-column: 1 / -1;
        justify-self: stretch;
        text-align: center;
    }

    .holo-workspace {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .holo-builder-card {
        order: 1;
    }

    .holo-side {
        order: 2;
        gap: 10px;
    }

    .holo-preview-card {
        position: static;
    }
}

@media (max-width: 620px) {
    .holo-topbar {
        grid-template-columns: 1fr;
    }

    .holo-back,
    .holo-brand,
    .holo-user {
        justify-self: stretch;
    }

    .holo-brand {
        order: -1;
        text-align: center;
        letter-spacing: .14em;
        font-size: 11px;
    }

    .holo-back {
        text-align: left;
    }

    .holo-card {
        padding: 12px;
    }

    .holo-section-title {
        font-size: 18px;
    }

    .holo-builder-card .product-builder {
        padding: 10px;
        overflow: hidden;
    }

    .holo-builder-card input,
    .holo-builder-card textarea,
    .product-tabs-nav,
    .product-tabs-scroll,
    .selection-tabs {
        width: 100%;
        max-width: 100%;
    }

    .holo-preview-card #grid.grid,
    body.customer-view-page .customer-container .grid {
        grid-template-columns: 1fr;
    }

    .deliv-group {
        grid-template-columns: 1fr;
    }

    .form-actions {
        grid-template-columns: 1fr;
    }

    .save-btn {
        margin-left: 0;
    }
}

/* Compact buyer catalog and product detail page */
body.customer-view-page .customer-container {
    width: min(1380px, calc(100% - 28px));
}

.shop-header {
    display: grid;
    grid-template-columns: minmax(320px, 430px) minmax(0, 1fr);
    gap: 16px;
    align-items: stretch;
    margin: 18px 0 18px;
    padding: 16px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,.80);
    background: #fff;
    box-shadow: 0 8px 18px rgba(31, 68, 102, .06);
}

.shop-logo-box {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 146px;
    padding: 14px;
    border-radius: 8px;
    background: rgba(255,255,255,.78);
    border: 1px solid rgba(117, 148, 178, .22);
}

.shop-logo-box img {
    width: min(100%, 300px);
    max-height: 112px;
    object-fit: contain;
}

.shop-contacts {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.shop-footer-contacts {
    display: none;
}

.shop-contact-card {
    min-width: 0;
    padding: 14px;
    display: grid;
    grid-template-columns: minmax(220px, auto) 1fr auto;
    gap: 10px 16px;
    align-items: center;
    border-radius: 8px;
    border: 1px solid rgba(117, 148, 178, .22);
    background: linear-gradient(180deg, rgba(255,255,255,.82), rgba(246,251,255,.76));
}

.shop-contact-title {
    color: #172033;
    font-size: 18px;
    font-weight: 900;
    line-height: 1.15;
}

.shop-contact-phone {
    display: inline-flex;
    margin-top: 7px;
    color: #1d7ed8;
    font-size: 17px;
    font-weight: 900;
    text-decoration: none;
}

.shop-contact-note {
    margin-top: 0;
    color: #647084;
    font-size: 13px;
    line-height: 1.3;
}

.shop-socials {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
    margin-top: 0;
}

.shop-social-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 34px;
    padding: 7px 10px;
    border-radius: 8px;
    border: 1px solid rgba(117, 148, 178, .24);
    background: rgba(255,255,255,.80);
    color: #25314a;
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
}

.shop-social-link img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.customer-offer-title {
    max-width: 980px;
    margin: 26px auto 18px;
    text-align: center;
}

.customer-offer-title h1 {
    margin: 0 0 10px;
    color: #172033;
    font-size: clamp(25px, 4.2vw, 38px);
    line-height: 1.15;
}

.customer-offer-title p {
    margin: 0;
    color: #4f5b6f;
    font-size: clamp(15px, 2vw, 18px);
    font-weight: 700;
    line-height: 1.45;
}

body.customer-view-page .customer-container .customer-products-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 14px;
}

body.customer-view-page .customer-products-grid .p-card {
    min-width: 0;
    min-height: 410px;
    border-radius: 8px;
    background: rgba(255,255,255,.88);
}

body.customer-view-page .customer-products-grid .gallery-container {
    height: 170px;
    margin-bottom: 0;
    border-radius: 8px 8px 0 0;
}

body.customer-view-page .customer-products-grid .gallery-item img {
    object-fit: contain;
    padding: 8px;
}

body.customer-view-page .customer-products-grid .p-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 12px;
}

body.customer-view-page .customer-products-grid .p-body h3 {
    min-height: 54px;
    margin: 0 0 8px;
    font-size: 14px;
    line-height: 1.28;
    overflow-wrap: anywhere;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card-price {
    color: #1d7ed8;
    font-size: 16px;
    font-weight: 900;
}

.product-card-delivery {
    margin: 3px 0 6px;
    color: #28a467;
    font-size: 12px;
    line-height: 1.25;
}

.product-card-desc {
    color: #647084 !important;
    font-size: 12px !important;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    white-space: pre-wrap;
}

.product-card-actions {
    display: grid;
    gap: 8px;
    margin-top: auto;
    padding-top: 10px;
}

.details-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    border-radius: 8px;
    border: 1px solid rgba(49, 130, 206, .25);
    background: rgba(255,255,255,.82);
    color: #1d69b8;
    font-weight: 800;
    text-align: center;
    text-decoration: none;
}

.details-btn:hover {
    background: rgba(36,216,255,.12);
}

body.customer-view-page .customer-products-grid .select-btn-wrap {
    margin: 0;
    padding: 0;
}

body.customer-view-page .customer-products-grid .select-btn {
    min-height: 38px;
    padding: 9px 10px;
    font-size: 13px;
}

.product-detail-container {
    width: min(1180px, calc(100% - 28px));
    margin: 22px auto 130px;
}

.product-detail-back {
    display: inline-flex;
    margin-bottom: 14px;
    color: #526079;
    font-weight: 800;
    text-decoration: none;
}

.product-detail-shell {
    display: grid;
    grid-template-columns: minmax(320px, 46%) minmax(0, 1fr);
    gap: 22px;
    padding: 22px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,.78);
    background: #fff;
    box-shadow: 0 8px 18px rgba(31, 68, 102, .08);
}

.product-detail-gallery .gallery-container {
    height: 520px;
    margin: 0;
    border-radius: 8px;
}

.product-detail-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.product-detail-info h1 {
    margin: 0;
    color: #172033;
    font-size: clamp(24px, 3vw, 36px);
    line-height: 1.15;
}

.product-detail-price {
    color: #1d7ed8;
    font-size: 28px;
    font-weight: 900;
}

.product-detail-delivery {
    color: #28a467;
    font-weight: 800;
}

.product-detail-desc {
    padding-top: 14px;
    border-top: 1px solid rgba(117, 148, 178, .28);
    color: #4f5b6f;
    line-height: 1.48;
    white-space: pre-wrap;
}

.detail-select-btn {
    width: min(360px, 100%);
    min-height: 48px;
    font-size: 18px;
}

.detail-select-btn.selected {
    background: linear-gradient(135deg, #30e6c7, #24d8ff);
    color: #082338;
}

@media (max-width: 980px) {
    body.customer-view-page .customer-container .customer-products-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
        gap: 10px;
    }

    body.customer-view-page .customer-products-grid .gallery-container {
        height: 145px;
    }

    body.customer-view-page .customer-products-grid .p-body h3 {
        font-size: 13px;
    }
}

@media (max-width: 760px) {
    body.customer-view-page .customer-container {
        width: calc(100% - 12px);
        padding-left: 6px;
        padding-right: 6px;
    }

    .shop-header {
        grid-template-columns: 1fr;
        gap: 10px;
        margin-top: 8px;
        padding: 10px;
    }

    .shop-logo-box {
        min-height: 92px;
    }

    .shop-logo-box img {
        width: min(100%, 260px);
        max-height: 78px;
    }

    .shop-header .shop-contacts {
        display: none;
    }

    .shop-footer-contacts {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        margin: 18px 0 128px;
        padding: 10px;
        border-radius: 8px;
        border: 1px solid rgba(255,255,255,.80);
        background: #fff;
        box-shadow: 0 6px 14px rgba(31, 68, 102, .06);
    }

    .shop-contact-card {
        grid-template-columns: 1fr;
        gap: 7px;
    }

    .shop-socials {
        justify-content: flex-start;
    }

    body.customer-view-page .customer-container .customer-products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 10px;
    }

    body.customer-view-page .customer-products-grid .p-card {
        min-height: 365px;
    }

    body.customer-view-page .customer-products-grid .gallery-container {
        height: 132px;
    }

    body.customer-view-page .customer-products-grid .p-body {
        padding: 9px;
    }

    body.customer-view-page .customer-products-grid .p-body h3 {
        min-height: 48px;
        font-size: 12px;
        line-height: 1.25;
    }

    .product-card-price {
        font-size: 14px;
    }

    .product-card-desc {
        font-size: 11px !important;
        -webkit-line-clamp: 2;
    }

    .details-btn,
    body.customer-view-page .customer-products-grid .select-btn {
        min-height: 34px;
        font-size: 12px;
    }

    .product-detail-container {
        width: calc(100% - 12px);
        margin-top: 8px;
    }

    .product-detail-shell {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 12px;
    }

    .product-detail-gallery .gallery-container {
        height: 330px;
    }
}

.legal-note {
    margin: 16px 0 120px;
    text-align: center;
    font-size: 13px;
}

.legal-note a,
.legal-note-bar a {
    color: #526079;
    text-decoration: underline;
}

.legal-note-bar {
    margin: 4px 0 0;
    font-size: 12px;
}

.policy-container {
    padding-bottom: 40px !important;
}

.policy-card {
    margin: 18px 0 40px;
    padding: 28px;
    border-radius: 8px;
    border: 1px solid #e8eef4;
    background: #fff;
    box-shadow: 0 8px 18px rgba(31, 68, 102, .06);
}

.policy-card h1 {
    margin: 0 0 16px;
    font-size: clamp(24px, 4vw, 32px);
}

.policy-card h2 {
    margin: 28px 0 10px;
    font-size: 18px;
    color: #172033;
}

.policy-card p,
.policy-card li {
    color: #3d4758;
    font-size: 15px;
    line-height: 1.55;
}

.policy-card ul {
    margin: 0 0 12px;
    padding-left: 22px;
}

.policy-lead {
    font-weight: 700;
    color: #172033 !important;
}

@media (max-width: 760px) {
    .policy-card { padding: 16px; }
}
