/* ═══════════════════════════════════════════════════════════
   Jam Studio — B2B Supply Platform
   Design System v1.0
   ═══════════════════════════════════════════════════════════ */

:root {
    /* Premium light palette */
    --bg:            #fafaf7;
    --surface:       #ffffff;
    --surface-hover: #f5f3ed;
    --border:        #e7e3da;
    --border-light:  #f0ede6;
    --text:          #1c1915;
    --text-muted:    #8a857a;
    --text-dim:      #a39c8e;
    --accent:        #b8943e;
    --accent-dim:    #8c6e2a;
    --danger:        #c53030;
    --success:       #2d8a56;

    /* Typography */
    --font:          -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    --font-mono:     'SF Mono', 'Fira Code', monospace;

    /* Spacing */
    --max-width:     1280px;
    --header-h:      64px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

a {
    color: var(--text);
    text-decoration: none;
    transition: color .15s;
}
a:hover { color: var(--accent); }

img { max-width: 100%; display: block; }

/* ═══════════════════════════════════════════════════════════
   HEADER
   ═══════════════════════════════════════════════════════════ */

header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(250,250,247,0.94);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    height: var(--header-h);
    display: flex;
    align-items: center;
    padding: 0 clamp(1rem, 4vw, 2rem);
}

.header-inner {
    max-width: var(--max-width);
    width: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: .06em;
    color: var(--text);
    text-decoration: none;
    white-space: nowrap;
}
.logo span { color: var(--accent); }

nav { display: flex; gap: 2rem; align-items: center; }

nav a {
    font-size: .92rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: color .15s;
    white-space: nowrap;
}
nav a:hover, nav a.active { color: var(--text); }

/* ═══════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════ */

footer {
    border-top: 1px solid var(--border);
    padding: 3rem clamp(1rem, 4vw, 2rem);
    margin-top: auto;
    color: var(--text-dim);
    font-size: .85rem;
}
.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 2rem;
}
.footer-col { min-width: 160px; }
.footer-col h4 {
    color: var(--text);
    font-size: .9rem;
    margin-bottom: .75rem;
    font-weight: 600;
}
.footer-col a {
    display: block;
    color: var(--text-dim);
    margin-bottom: .35rem;
    font-size: .85rem;
}
.footer-col a:hover { color: var(--accent); }

/* ═══════════════════════════════════════════════════════════
   PAGE LAYOUT
   ═══════════════════════════════════════════════════════════ */

main {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: clamp(2rem, 5vw, 4rem) clamp(1rem, 4vw, 2rem);
    min-height: calc(100vh - var(--header-h) - 200px);
}

.page-header {
    margin-bottom: 3rem;
}
.page-header h1 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -.02em;
    line-height: 1.15;
    margin-bottom: .5rem;
}
.page-header h1 span { color: var(--accent); }
.page-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 560px;
}

/* ═══════════════════════════════════════════════════════════
   HERO (Homepage)
   ═══════════════════════════════════════════════════════════ */

.hero {
    text-align: center;
    padding: clamp(3rem, 8vw, 6rem) 0;
    border-bottom: 1px solid var(--border);
    margin-bottom: 3rem;
}
.hero h1 {
    font-size: clamp(2.2rem, 6vw, 4rem);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}
.hero h1 span { color: var(--accent); }
.hero p {
    color: var(--text-muted);
    font-size: 1.15rem;
    max-width: 540px;
    margin: 0 auto 2rem;
}

/* ═══════════════════════════════════════════════════════════
   GRID CARDS (Directions, Brands, Categories)
   ═══════════════════════════════════════════════════════════ */

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.75rem;
    transition: border-color .2s, background .2s;
    text-decoration: none;
    display: block;
}
.card:hover {
    border-color: var(--border-light);
    background: var(--surface-hover);
}
.card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: .5rem;
    color: var(--text);
}
.card p {
    color: var(--text-muted);
    font-size: .9rem;
    line-height: 1.5;
}

/* ═══════════════════════════════════════════════════════════
   CATALOG / PRODUCT LIST
   ═══════════════════════════════════════════════════════════ */

.catalog-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 2rem;
    align-items: start;
}

.sidebar {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.5rem;
    position: sticky;
    top: calc(var(--header-h) + 1rem);
}
.sidebar h3 {
    font-size: .95rem;
    font-weight: 600;
    margin-bottom: 1rem;
}
.sidebar a {
    display: block;
    padding: .4rem 0;
    font-size: .9rem;
    color: var(--text-muted);
}
.sidebar a:hover, .sidebar a.active { color: var(--accent); }
.sidebar .sub { padding-left: 1rem; font-size: .85rem; }

.product-list { display: flex; flex-direction: column; gap: 1rem; }

.product-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.5rem;
    display: grid;
    grid-template-columns: 120px 1fr auto;
    gap: 1.5rem;
    align-items: center;
    transition: border-color .2s;
    text-decoration: none;
}
.product-card:hover { border-color: var(--border-light); }
.product-card img {
    width: 120px;
    height: 120px;
    object-fit: contain;
    background: var(--bg);
    border-radius: 6px;
}
.product-card h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: .3rem;
}
.product-card .meta {
    color: var(--text-muted);
    font-size: .85rem;
}
.product-card .price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent);
    white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════════
   PRODUCT PAGE
   ═══════════════════════════════════════════════════════════ */

.product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

/* ── Product Carousel ── */
.product-carousel { margin-bottom: 1rem; }
.carousel-main {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    background: var(--surface);
    border: 1px solid var(--border);
}
.carousel-slide {
    display: none;
    aspect-ratio: 3/4;
    align-items: center;
    justify-content: center;
}
.carousel-slide.active { display: flex; }
.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 12px;
}
.carousel-prev, .carousel-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,.6);
    color: #fff;
    border: none;
    width: 40px; height: 40px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    opacity: 0;
    transition: opacity .2s;
}
.carousel-main:hover .carousel-prev,
.carousel-main:hover .carousel-next { opacity: 1; }
.carousel-prev { left: 8px; }
.carousel-next { right: 8px; }

.carousel-thumbs {
    display: flex;
    gap: .5rem;
    margin-top: .75rem;
    overflow-x: auto;
    padding-bottom: .25rem;
}
.carousel-thumb {
    flex: 0 0 64px;
    height: 64px;
    border: 2px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    padding: 0;
    background: var(--surface);
    opacity: .5;
    transition: opacity .2s, border-color .2s;
}
.carousel-thumb.active { opacity: 1; border-color: var(--accent); }
.carousel-thumb img {
    width: 100%; height: 100%;
    object-fit: cover;
    border-radius: 6px;
}
.carousel-thumb:hover { opacity: .8; }
.product-info h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: .5rem;
}
.product-info .brand {
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 1rem;
}
.product-info .sku {
    color: var(--text-dim);
    font-size: .85rem;
    margin-bottom: 1.5rem;
}
.product-price {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--accent);
    margin-bottom: 1.5rem;
}
.attr-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 2rem;
}
.attr-table tr { border-bottom: 1px solid var(--border); }
.attr-table td {
    padding: .6rem 0;
    font-size: .9rem;
}
.attr-table td:first-child {
    color: var(--text-muted);
    width: 40%;
}

/* Product attributes, description, documents (Kramp-style) */
.product-attrs { margin-top: 2rem; }
.product-attrs h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: .75rem;
    color: var(--text);
}
.attr-label { font-weight: 500; }

.product-desc { margin-top: 2rem; }
.product-desc h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: .75rem;
    color: var(--text);
}
.desc-text {
    color: var(--text-muted);
    font-size: .95rem;
    line-height: 1.7;
}

.product-docs { margin-top: 2rem; }
.product-docs h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: .75rem;
    color: var(--text);
}
.docs-list {
    display: flex;
    flex-direction: column;
    gap: .5rem;
}
.doc-link {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    color: var(--accent);
    font-size: .9rem;
    text-decoration: none;
    padding: .5rem .75rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    transition: all .2s;
    width: fit-content;
}
.doc-link:hover {
    border-color: var(--accent);
    background: rgba(184,148,62,0.05);
}

/* ── Kramp-style info sections ── */
.kramp-section {
    margin-top: 1.25rem;
    padding: 1rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
}
.kramp-section h4 {
    font-size: .9rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: .5rem;
    text-transform: none;
}
.kramp-section p {
    color: var(--text);
    font-size: .95rem;
    line-height: 1.6;
    margin: 0;
}
.kramp-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.kramp-section li {
    color: var(--text);
    font-size: .93rem;
    padding: .25rem 0;
    padding-left: 1rem;
    position: relative;
}
.kramp-section li::before {
    content: "—";
    position: absolute;
    left: 0;
    color: var(--accent);
}

/* ── Full variant table (Kramp-style) ── */
.variant-section {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}
.variant-section h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text);
}
.variant-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 10px;
    border: 1px solid var(--border);
}
.variant-table {
    width: 100%;
    min-width: 900px;
    border-collapse: collapse;
    font-size: .87rem;
}
.variant-table thead {
    background: var(--surface);
}
.variant-table th {
    padding: .65rem .75rem;
    text-align: left;
    font-weight: 600;
    color: var(--text-muted);
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .02em;
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
}
.variant-table td {
    padding: .6rem .75rem;
    border-bottom: 1px solid var(--border);
    color: var(--text);
    vertical-align: middle;
}
.variant-table tbody tr:hover {
    background: var(--surface-hover);
}
.variant-table .var-product {
    min-width: 200px;
}
.variant-table .var-brand {
    font-size: .75rem;
    color: var(--text-dim);
    margin-bottom: .15rem;
}
.variant-table .var-sku {
    font-size: .82rem;
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    display: block;
    margin: .1rem 0;
}
.variant-table .var-name {
    font-size: .82rem;
    color: var(--text-muted);
}

/* ── Media link ── */
.media-link {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    color: var(--accent);
    font-size: .9rem;
    text-decoration: none;
    padding: .5rem .75rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    margin-top: 1rem;
    transition: all .2s;
}
.media-link:hover {
    border-color: var(--accent);
    background: rgba(184,148,62,0.05);
}

/* ── Size chips ── */
.size-chips {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .4rem;
    margin-bottom: 1.5rem;
}
.size-label {
    font-size: .85rem;
    color: var(--text-muted);
    margin-right: .25rem;
}
.size-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 34px;
    padding: 0 .55rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: .82rem;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    transition: all .15s;
}
.size-chip:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(184,148,62,0.08);
}
.size-chip.active {
    border-color: var(--accent);
    background: var(--accent);
    color: #000;
    font-weight: 700;
}

.no-image {
    width: 100%;
    aspect-ratio: 1;
    background: var(--surface);
    border-radius: 12px;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dim);
    font-size: .9rem;
}

/* ═══════════════════════════════════════════════════════════
   BLOG / SOLUTIONS / GENERIC LIST
   ═══════════════════════════════════════════════════════════ */

.list-stack { display: flex; flex-direction: column; gap: 1.5rem; }
.list-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 2rem;
    transition: border-color .2s;
    text-decoration: none;
    display: block;
}
.list-item:hover { border-color: var(--border-light); }
.list-item h2 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: .5rem;
}
.list-item p { color: var(--text-muted); font-size: .95rem; }
.list-item .date {
    color: var(--text-dim);
    font-size: .8rem;
    margin-bottom: .5rem;
}

/* ═══════════════════════════════════════════════════════════
   BREADCRUMBS
   ═══════════════════════════════════════════════════════════ */

.breadcrumbs {
    display: flex;
    gap: .5rem;
    align-items: center;
    color: var(--text-dim);
    font-size: .85rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}
.breadcrumbs a { color: var(--text-muted); }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs .sep { color: var(--text-dim); }

/* ═══════════════════════════════════════════════════════════
   CONTACT PAGE
   ═══════════════════════════════════════════════════════════ */

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}
.contact-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 2rem;
}
.contact-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}
.contact-card p, .contact-card a {
    color: var(--text-muted);
    font-size: .95rem;
    margin-bottom: .5rem;
    display: block;
}

/* ═══════════════════════════════════════════════════════════
   EMPTY STATE
   ═══════════════════════════════════════════════════════════ */

.empty {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-dim);
}
.empty h3 { font-size: 1.2rem; margin-bottom: .5rem; color: var(--text-muted); }

/* ═══════════════════════════════════════════════════════════
   B2B NAV
   ═══════════════════════════════════════════════════════════ */

.b2b-nav { margin-left: auto; padding-left: 2rem; border-left: 1px solid var(--border); }
.b2b-nav .b2b-link {
    font-size: .82rem;
    color: var(--text-muted);
    padding: .3rem .7rem;
    border-radius: 4px;
    transition: all .15s;
}
.b2b-nav .b2b-link:hover, .b2b-nav .b2b-link.active {
    color: var(--accent);
    background: rgba(184, 148, 62, 0.08);
}

/* ═══════════════════════════════════════════════════════════
   MONITORING DASHBOARD
   ═══════════════════════════════════════════════════════════ */

.monitor-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.monitor-stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
}
.monitor-stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--accent);
    margin-bottom: .35rem;
}
.monitor-stat-label {
    font-size: .85rem;
    color: var(--text-muted);
}

.monitor-import-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.monitor-import-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}
.monitor-import-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
}
.monitor-import-body {
    display: flex;
    flex-direction: column;
    gap: .65rem;
}
.monitor-import-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .35rem 0;
}
.monitor-import-row .label {
    color: var(--text-muted);
    font-size: .9rem;
}
.monitor-import-row .value {
    color: var(--text);
    font-size: .95rem;
    font-weight: 500;
}

.monitor-table-wrap { overflow-x: auto; }
.monitor-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .9rem;
}
.monitor-table thead th {
    text-align: left;
    color: var(--text-dim);
    font-weight: 600;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding: .75rem;
    border-bottom: 1px solid var(--border);
}
.monitor-table tbody td {
    padding: .65rem .75rem;
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
}
.monitor-table tbody tr:hover { background: var(--surface-hover); }

/* Badges */
.badge {
    display: inline-block;
    padding: .2rem .65rem;
    border-radius: 4px;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .04em;
}
.badge-success { background: rgba(60,179,113,0.15); color: var(--success); }
.badge-warning { background: rgba(184,148,62,0.15); color: var(--accent); }
.badge-danger  { background: rgba(224,80,80,0.15); color: var(--danger); }
.badge-muted   { background: var(--surface-hover); color: var(--text-dim); }

/* ═══════════════════════════════════════════════════════════
   B2B CABINET
   ═══════════════════════════════════════════════════════════ */

.cabinet-section { margin-bottom: 2rem; }
.cabinet-section h2 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text);
}

/* Price Tier Grid */
.tier-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}
.tier-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    transition: border-color .2s;
}
.tier-card:hover { border-color: var(--border-light); }
.tier-name {
    font-size: .85rem;
    color: var(--text-muted);
    margin-bottom: .5rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .04em;
}
.tier-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: .25rem;
}
.tier-discount {
    display: inline-block;
    background: rgba(60,179,113,0.15);
    color: var(--success);
    font-size: .8rem;
    font-weight: 600;
    padding: .15rem .55rem;
    border-radius: 4px;
    margin-bottom: .5rem;
}
.tier-desc {
    font-size: .8rem;
    color: var(--text-dim);
    margin-top: .5rem;
}

/* Client Card */
.client-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.5rem;
}
.client-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .55rem 0;
    border-bottom: 1px solid var(--border);
}
.client-row:last-child { border-bottom: none; }
.client-row .label {
    color: var(--text-muted);
    font-size: .9rem;
}
.client-row .value {
    color: var(--text);
    font-size: .95rem;
    font-weight: 500;
}

/* Offers / Drafts List */
.offers-list { display: flex; flex-direction: column; gap: .65rem; }
.offer-row {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1rem 1.25rem;
    display: grid;
    grid-template-columns: 1fr 120px 120px auto;
    gap: 1rem;
    align-items: center;
    transition: border-color .2s;
}
.offer-row:hover { border-color: var(--border-light); }
.offer-title {
    font-weight: 600;
    font-size: .95rem;
}
.offer-status {
    font-size: .8rem;
    font-weight: 600;
    padding: .25rem .6rem;
    border-radius: 4px;
    text-align: center;
    white-space: nowrap;
}
.status-draft      { background: var(--surface-hover); color: var(--text-dim); }
.status-sent       { background: rgba(184,148,62,0.12); color: var(--accent); }
.status-negotiation{ background: rgba(100,149,237,0.12); color: #6495ed; }
.status-accepted   { background: rgba(60,179,113,0.12); color: var(--success); }
.status-rejected   { background: rgba(224,80,80,0.12); color: var(--danger); }
.status-expired    { background: var(--surface-hover); color: var(--text-dim); }
.status-confirmed  { background: rgba(60,179,113,0.08); color: var(--success); }
.status-processing { background: rgba(184,148,62,0.08); color: var(--accent); }
.status-shipped    { background: rgba(100,149,237,0.08); color: #6495ed; }
.status-delivered  { background: rgba(60,179,113,0.12); color: var(--success); }
.status-cancelled  { background: rgba(224,80,80,0.08); color: var(--danger); }
.offer-amount {
    font-weight: 600;
    color: var(--accent);
    font-size: .95rem;
    white-space: nowrap;
}
.offer-date {
    font-size: .8rem;
    color: var(--text-dim);
    white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════════
   SIZE CALCULATOR
   ═══════════════════════════════════════════════════════════ */

/*
═══════════════════════════════════════════════════════════ */

.size-calculator {
 background: var(--surface, #fff);
 border: 1px solid var(--border, #e2e2e2);
 border-radius: 12px;
 padding: 1.5rem;
 margin: 1.5rem 0;
}
.size-calculator h3 { font-size: 1.15rem; margin: 0 0 .3rem; color: var(--text, #1a1a1a); }
.sc-subtitle { font-size: .88rem; color: var(--text-muted, #666); margin: 0 0 1rem; }

/* Parameters */
.sc-params { display: flex; flex-direction: column; gap: .7rem; margin-bottom: 1rem; }
.sc-param {
 display: flex; flex-direction: column; gap: .25rem;
 padding: .5rem .75rem;
 background: var(--bg, #f9f9fb);
 border-radius: 8px;
 border: 1px solid var(--border, #e2e2e2);
}
.sc-param-header { display: flex; align-items: center; gap: .4rem; }
.sc-param-icon { font-size: 1rem; }
.sc-param-label { font-size: .82rem; font-weight: 600; color: var(--text, #1a1a1a); flex: 1; }
.sc-param-val { font-size: .82rem; font-weight: 700; color: #1a1a1a; min-width: 48px; text-align: right; }
.sc-param-hint { font-size: .7rem; color: var(--text-muted, #999); opacity: .7; }

/* Sliders */
.sc-slider {
 width: 100%; -webkit-appearance: none; appearance: none;
 height: 6px; border-radius: 3px;
 background: var(--border, #ddd);
 outline: none; cursor: pointer;
}
.sc-slider::-webkit-slider-thumb {
 -webkit-appearance: none; width: 20px; height: 20px;
 border-radius: 50%; background: #1a1a1a;
 cursor: pointer; border: 2px solid #fff;
 box-shadow: 0 1px 3px rgba(0,0,0,.15);
}

/* Result */
.sc-result {
 background: var(--bg, #f9f9f9);
 border-radius: 10px;
 padding: 1rem 1.2rem;
 margin-bottom: .75rem;
}
.sc-result-main { display: flex; align-items: center; gap: .75rem; margin-bottom: .3rem; flex-wrap: wrap; }
.sc-badge {
 display: inline-block; padding: .2rem .6rem;
 border-radius: 12px; font-size: .7rem; font-weight: 700;
 color: #fff; background: #1a1a1a; white-space: nowrap;
}
.sc-size { font-size: 1.8rem; font-weight: 800; color: #1a1a1a; }
.sc-confidence { font-size: .76rem; color: #888; }
.sc-detail { font-size: .8rem; color: #666; margin: .3rem 0; }
.sc-reason { font-size: .74rem; color: #d97706; font-style: italic; margin: .3rem 0; }
.sc-link {
 display: inline-block; margin-top: .3rem;
 font-size: .82rem; font-weight: 600; color: #1a1a1a;
 text-decoration: underline;
}
.sc-link:hover { color: #666; }

/* Chips */
.sc-chips { display: flex; flex-wrap: wrap; gap: .35rem; justify-content: center; }
.sc-chip {
 display: inline-block; padding: .3rem .65rem;
 border: 1px solid #ddd; border-radius: 6px;
 font-size: .78rem; font-weight: 500; color: #555;
 text-decoration: none; transition: all .15s;
}
.sc-chip:hover { border-color: #999; color: #1a1a1a; }
.sc-chip.active { background: #1a1a1a; color: #fff; border-color: #1a1a1a; }

/* Primary param (chest) */
.sc-param-primary {
    border: 2px solid #1a1a1a;
    background: #fff;
}
.sc-param-primary .sc-param-label { font-size: .9rem; }
.sc-param-primary .sc-param-val { font-size: .9rem; }

/* Badge variants */
.sc-badge-recommend { background: #1a1a1a; }
.sc-badge-correct { background: #d97706; }
.sc-badge-major { background: #dc2626; }

/* Refinement section (waist + height) */
.sc-refine {
    border: 1px solid var(--border, #e2e2e2);
    border-radius: 8px;
    margin-top: .5rem;
}
.sc-refine[open] { border-color: #1a1a1a; }
.sc-refine-summary {
    padding: .55rem .85rem;
    font-size: .82rem;
    font-weight: 600;
    color: #555;
    cursor: pointer;
    user-select: none;
    list-style: none;
}
.sc-refine-summary::-webkit-details-marker { display: none; }
.sc-refine-summary:hover { color: #1a1a1a; }
.sc-refine[open] .sc-refine-summary { color: #1a1a1a; }
.sc-refine-body {
    padding: 0 .85rem .85rem;
    display: flex;
    flex-direction: column;
    gap: .6rem;
}
.sc-refine-body .sc-param {
    background: var(--bg, #f9f9fb);
}

/* Measurement guide */
.sc-howto {
    border: 1px solid var(--border, #e2e2e2);
    border-radius: 8px;
    margin-top: .5rem;
}
.sc-howto-summary {
    padding: .55rem .85rem;
    font-size: .8rem;
    font-weight: 500;
    color: #888;
    cursor: pointer;
    user-select: none;
    list-style: none;
}
.sc-howto-summary::-webkit-details-marker { display: none; }
.sc-howto-summary:hover { color: #555; }
.sc-howto-body {
    padding: 0 .85rem .85rem;
    font-size: .78rem;
    color: #666;
    line-height: 1.5;
}
.sc-howto-body p { margin: .35rem 0; }
.sc-howto-note { font-size: .72rem; color: #999; font-style: italic; }

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
    nav { gap: 1rem; overflow-x: auto; }
    nav a { font-size: .82rem; }
    .catalog-layout { grid-template-columns: 1fr; }
    .sidebar { position: static; }
    .product-card { grid-template-columns: 80px 1fr; }
    .product-card .price { grid-column: 1/-1; text-align: left; }
    .product-layout { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
    .b2b-nav { margin-left: 0; padding-left: 0; border-left: none; }
    .b2b-nav .b2b-link { font-size: .75rem; }
    .offer-row { grid-template-columns: 1fr; gap: .5rem; }
    .tier-grid { grid-template-columns: 1fr 1fr; }
}

/* ── Logo Mockup ── */
.logo-mockup {
    margin-top: 2rem;
    padding: 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
}
.logo-mockup h3 { font-size: 1.15rem; font-weight: 600; margin: 0 0 .25rem; }
.mockup-subtitle {
    color: var(--text-muted);
    font-size: .88rem;
    margin: 0 0 1.25rem;
}

/* Dropzone */
.mockup-dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .5rem;
    padding: 2.5rem 1.5rem;
    border: 2px dashed var(--border);
    border-radius: 10px;
    cursor: pointer;
    transition: all .2s;
    text-align: center;
    color: var(--text-muted);
    font-size: .92rem;
}
.mockup-dropzone:hover,
.mockup-dropzone.drag-over {
    border-color: var(--accent);
    background: var(--accent-soft);
    color: var(--accent);
}
.mockup-dropzone.ready { border-style: solid; border-color: var(--success); }
.mockup-dropzone-icon { font-size: 2rem; }
.mockup-hint {
    font-size: .78rem;
    color: var(--text-muted);
    opacity: .7;
}

/* Presets — placement zone selector */
.mockup-presets {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .6rem;
    margin-bottom: 1rem;
}
.mockup-label {
    font-size: .82rem;
    font-weight: 600;
    color: var(--text-muted);
    white-space: nowrap;
    min-width: fit-content;
}
.mockup-chips {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}
.mockup-chip {
    padding: .4rem .75rem;
    border: 1px solid var(--border);
    border-radius: 20px;
    background: transparent;
    color: var(--text-muted);
    font-size: .82rem;
    cursor: pointer;
    transition: all .18s;
    white-space: nowrap;
}
.mockup-chip:hover {
    border-color: var(--accent);
    color: var(--accent);
}
.mockup-chip.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    font-weight: 600;
}

/* Canvas */
.mockup-canvas-wrap {
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--border);
    background: var(--surface);
}
.mockup-canvas-wrap canvas {
    display: block;
    width: 100%;
    height: auto;
}

/* Controls: size + rotation */
.mockup-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    margin-top: .75rem;
    padding: .75rem 1rem;
    background: var(--surface, #fafafa);
    border-radius: 10px;
    border: 1px solid var(--border);
}
.mockup-control {
    display: flex;
    align-items: center;
    gap: .5rem;
    flex: 1;
    min-width: 160px;
}
.mockup-slider {
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    border-radius: 3px;
    background: var(--border);
    outline: none;
    cursor: pointer;
}
.mockup-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    border: 2px solid #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,.15);
}
.mockup-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    border: 2px solid #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,.15);
}
.mockup-val {
    font-size: .82rem;
    font-weight: 600;
    color: var(--accent);
    min-width: 42px;
    text-align: right;
}

/* Actions */
.mockup-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
    margin-top: 1rem;
}
.btn-download {
    padding: .65rem 1.25rem;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background .2s;
}
.btn-download:hover { background: var(--accent-hover, #1a6ed4); }
.btn-download.btn-outline {
    background: transparent;
    color: var(--accent);
    border: 1.5px solid var(--accent);
}
.btn-download.btn-outline:hover {
    background: var(--accent-soft);
}
.btn-retry {
    padding: .65rem 1.25rem;
    background: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: .9rem;
    cursor: pointer;
}
.btn-retry:hover { border-color: var(--text-muted); color: var(--text); }
    .monitor-stats-grid { grid-template-columns: 1fr 1fr; }
}