/*
 * SalesX case study — page styles.
 *
 * Loaded only by resources/views/web/projects/case-studies/salesx.blade.php.
 * Same structure as the New Bay ERP case study, kept as a separate file so
 * either page can change without touching the other. Every class is prefixed
 * `sx-` and every colour, radius, font and easing comes from the site's own
 * tokens (--c-*, --radius, --font-*, --ease-out), so the page follows the
 * dashboard theme, light/dark mode and RTL without a Tailwind rebuild.
 */

/* ---------------------------------------------------------------- basics */
.sx-ico    { width: 1.35rem; height: 1.35rem; }
.sx-ico-sm { width: 1rem; height: 1rem; flex: none; }
.sx-ico-xs { width: .8rem; height: .8rem; flex: none; color: var(--c-primary); margin-top: .35em; }

/* The shared hero sizes its h1 for a project name; this one is a sentence
   sharing the row with a screenshot, so it is set a step smaller. */
.page-open h1 { font-size: clamp(2.1rem, 4.6vw, 3.7rem); line-height: 1.06; max-width: 20ch; }
html[dir='rtl'] .page-open h1 { line-height: 1.3; }

.sx-lede { margin-top: 1.75rem; max-width: 46ch; }
.sx-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2.25rem; }
.sx-hint {
    font-family: var(--font-mono);
    font-size: .65rem;
    letter-spacing: .12em;
    color: var(--c-text-muted);
    margin-inline-start: .15rem;
}
html[dir='rtl'] .sx-hint { letter-spacing: 0; font-size: .75rem; }

.sx-section { position: relative; }
.sx-band {
    background:
        radial-gradient(60rem 30rem at 85% 0%, color-mix(in srgb, var(--c-primary) 7%, transparent), transparent 70%),
        var(--c-surface);
    border-block: 1px solid var(--c-border);
}
html[dir='rtl'] .sx-band {
    background:
        radial-gradient(60rem 30rem at 15% 0%, color-mix(in srgb, var(--c-primary) 7%, transparent), transparent 70%),
        var(--c-surface);
}

.sx-head { max-width: 46rem; margin-bottom: clamp(2.25rem, 5vw, 3.5rem); }
.sx-head--split { max-width: none; display: grid; gap: 1.25rem; align-items: end; }
@media (min-width: 1024px) {
    .sx-head--split { grid-template-columns: 1.15fr .85fr; gap: 4rem; }
}
.sx-h2 {
    margin-top: 1rem;
    font-size: clamp(1.9rem, 4.4vw, 3.2rem);
    line-height: 1.08;
    max-width: 20ch;
}
.sx-lead { color: var(--c-text-muted); font-size: 1.075rem; line-height: 1.7; max-width: 52ch; }

/* ------------------------------------------------------- framed screens */
.sx-frame {
    position: relative;
    overflow: hidden;
    border-radius: calc(var(--radius) * .75);
    border: 1px solid var(--c-border);
    background: var(--c-surface-raised);
    box-shadow:
        0 1px 0 color-mix(in srgb, #fff 6%, transparent) inset,
        0 30px 60px -28px rgba(3, 8, 20, .55),
        0 12px 24px -16px rgba(3, 8, 20, .35);
}
.sx-frame img { display: block; width: 100%; height: auto; background: #f4f4f4; }
.sx-frame-bar {
    display: flex;
    align-items: center;
    gap: .4rem;
    height: 2rem;
    padding-inline: .85rem;
    border-bottom: 1px solid var(--c-border);
    background: color-mix(in srgb, var(--c-surface) 85%, var(--c-text) 4%);
    direction: ltr;
}
.sx-frame-bar i {
    width: .55rem; height: .55rem; border-radius: 50%;
    background: color-mix(in srgb, var(--c-text) 22%, transparent);
}
.sx-frame-bar span {
    margin-inline: auto;
    font-family: var(--font-mono);
    font-size: .66rem;
    letter-spacing: .08em;
    color: var(--c-text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-inline-end: 2.2rem;
}

/* --------------------------------------------------------------- hero art */
.sx-hero-visual { position: relative; margin: 0; padding-bottom: 2.5rem; }
.sx-frame--hero { transform: perspective(1800px) rotateY(-4deg) rotateX(2deg); transform-origin: 70% 50%; }
html[dir='rtl'] .sx-frame--hero { transform: perspective(1800px) rotateY(4deg) rotateX(2deg); transform-origin: 30% 50%; }
.sx-frame--float {
    position: absolute;
    width: 46%;
    inset-inline-start: -6%;
    bottom: 0;
    border-color: color-mix(in srgb, var(--c-primary) 35%, var(--c-border));
    animation: sx-float 7s ease-in-out infinite;
}
@keyframes sx-float { 50% { transform: translateY(-8px); } }
.sx-note {
    position: absolute;
    inset-inline-end: 0;
    bottom: 0;
    font-size: .75rem;
    color: var(--c-text-muted);
}
@media (max-width: 1023px) {
    .sx-frame--hero, html[dir='rtl'] .sx-frame--hero { transform: none; }
    .sx-frame--float { inset-inline-start: auto; inset-inline-end: 4%; width: 42%; bottom: 1.6rem; }
    .sx-note { position: static; display: block; margin-top: .75rem; }
    .sx-hero-visual { padding-bottom: 0; }
}
@media (max-width: 639px) { .sx-frame--float { display: none; } }

/* ------------------------------------------------------------ facts/stats */
.sx-facts-wrap { padding-block: 0 clamp(3.5rem, 7vw, 5.5rem); }
/* Five facts here, not the shared four: keep them on one row on wide screens. */
@media (min-width: 1024px) {
    .sx-facts-wrap .facts { grid-template-columns: repeat(5, minmax(0, 1fr)); column-gap: 1.75rem; }
}
.sx-credits { margin-top: 1.75rem; }
.sx-stats {
    margin-top: clamp(2.5rem, 5vw, 3.5rem);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border: 1px solid var(--c-border);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--c-surface);
}
.sx-stat {
    padding: clamp(1.25rem, 3vw, 2rem);
    display: flex;
    flex-direction: column;
    gap: .35rem;
    border-inline-end: 1px solid var(--c-border);
    border-bottom: 1px solid var(--c-border);
}
.sx-stat:nth-child(2n) { border-inline-end: 0; }
.sx-stat:nth-last-child(-n+2) { border-bottom: 0; }
@media (min-width: 900px) {
    .sx-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .sx-stat { border-bottom: 0; border-inline-end: 1px solid var(--c-border); }
    .sx-stat:nth-child(2n) { border-inline-end: 1px solid var(--c-border); }
    .sx-stat:last-child { border-inline-end: 0; }
}
.sx-stat-num {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(2.1rem, 4.6vw, 3.25rem);
    line-height: 1;
    color: var(--c-text);
    font-variant-numeric: tabular-nums;
}
.sx-stat-label { color: var(--c-text-muted); font-size: .92rem; line-height: 1.45; }

/* ------------------------------------------------------------------ story */
.sx-story-steps {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 1px;
    background: var(--c-border);
    border: 1px solid var(--c-border);
    border-radius: var(--radius);
    overflow: hidden;
}
@media (min-width: 900px) { .sx-story-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .sx-story-steps { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.sx-story-step { background: var(--c-bg); padding: clamp(1.5rem, 3vw, 2.25rem); }
.sx-story-step:last-child { background: color-mix(in srgb, var(--c-primary) 8%, var(--c-bg)); }
.sx-step-num {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: .75rem;
    color: var(--c-primary);
    letter-spacing: .12em;
}
.sx-story-step h3 { margin-top: .9rem; font-size: 1.25rem; }
.sx-story-step p, .sx-module p, .sx-quality p, .sx-flow-step p {
    margin-top: .7rem;
    color: var(--c-text-muted);
    line-height: 1.7;
    font-size: .975rem;
}

/* ---------------------------------------------------------------- modules */
.sx-modules { display: grid; gap: 1.25rem; }
@media (min-width: 720px)  { .sx-modules { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .sx-modules { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.sx-module { padding: clamp(1.5rem, 3vw, 2rem); background: var(--c-bg); }
.sx-module:hover { border-color: color-mix(in srgb, var(--c-primary) 45%, transparent); }
.sx-module-icon {
    display: inline-grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: .85rem;
    color: var(--c-primary);
    background: color-mix(in srgb, var(--c-primary) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--c-primary) 25%, transparent);
}
.sx-module h3, .sx-quality h3 { margin-top: 1.1rem; font-size: 1.2rem; }
.sx-module ul { list-style: none; margin: 1.1rem 0 0; padding: 1.1rem 0 0; border-top: 1px solid var(--c-border); display: grid; gap: .5rem; }
.sx-module li { display: flex; gap: .6rem; font-size: .925rem; line-height: 1.5; }

/* --------------------------------------------------------------- lifecycle */
.sx-flow { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.5rem; counter-reset: sx; }
@media (min-width: 720px)  { .sx-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .sx-flow { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1rem; } }
.sx-flow-step { position: relative; padding-top: 3.4rem; }
.sx-flow-step::before {
    content: '';
    position: absolute;
    top: 1.15rem;
    inset-inline-start: 2.6rem;
    inset-inline-end: -1rem;
    height: 1px;
    background: linear-gradient(90deg, color-mix(in srgb, var(--c-primary) 55%, transparent), var(--c-border));
}
html[dir='rtl'] .sx-flow-step::before { background: linear-gradient(-90deg, color-mix(in srgb, var(--c-primary) 55%, transparent), var(--c-border)); }
.sx-flow-step:last-child::before { display: none; }
@media (max-width: 1099px) { .sx-flow-step::before { display: none; } }
.sx-flow-dot {
    position: absolute;
    top: 0;
    inset-inline-start: 0;
    display: grid;
    place-items: center;
    width: 2.3rem;
    height: 2.3rem;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-size: .85rem;
    font-weight: 700;
    color: var(--c-button-text, #fff);
    background: linear-gradient(140deg, var(--c-primary), var(--c-primary-deep));
    box-shadow: 0 0 0 6px color-mix(in srgb, var(--c-primary) 14%, transparent);
}
.sx-flow-step h3 { font-size: 1.1rem; }
.sx-flow-step p { font-size: .925rem; }

/* -------------------------------------------------------------------- tour */
.sx-tour-tabs {
    display: flex;
    gap: .5rem;
    overflow-x: auto;
    padding: .35rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--c-border);
    border-radius: 999px;
    background: var(--c-bg);
    scrollbar-width: none;
}
.sx-tour-tabs::-webkit-scrollbar { display: none; }
.sx-tour-tabs[hidden] { display: none; }
.sx-tab {
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .6rem 1rem;
    border-radius: 999px;
    font-size: .875rem;
    color: var(--c-text-muted);
    background: transparent;
    border: 0;
    cursor: pointer;
    transition: color var(--dur-base) var(--ease-out), background-color var(--dur-base) var(--ease-out);
}
.sx-tab:hover { color: var(--c-text); }
.sx-tab[aria-selected='true'] { color: var(--c-button-text, #fff); background: var(--c-primary); }
.sx-tab:focus-visible { outline: 2px solid var(--c-primary); outline-offset: 2px; }
.sx-tab-num { font-family: var(--font-mono); font-size: .68rem; opacity: .7; }

.sx-tour-panels { display: grid; gap: 3rem; }
.sx-tour.is-tabbed .sx-tour-panels { display: block; }
.sx-panel { margin: 0; }
.sx-panel[hidden] { display: none; }
.sx-tour.is-tabbed .sx-panel:not([hidden]) { animation: sx-in .45s var(--ease-out) both; }
@keyframes sx-in { from { opacity: 0; transform: translateY(10px); } }
.sx-panel figcaption {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem 1rem;
    align-items: baseline;
    margin-top: 1.1rem;
    color: var(--c-text-muted);
    line-height: 1.6;
}
.sx-panel figcaption strong { color: var(--c-text); font-family: var(--font-display); font-size: 1.05rem; }

/* -------------------------------------------------------------- deep dives */
.sx-deep { display: grid; gap: clamp(3.5rem, 8vw, 6rem); }
.sx-deep-item { display: grid; gap: 2rem; align-items: center; }
@media (min-width: 1024px) {
    .sx-deep-item { grid-template-columns: .9fr 1.1fr; gap: 4rem; }
    .sx-deep-item--flip .sx-deep-copy { order: 2; }
}
.sx-deep-copy h3 { font-size: clamp(1.45rem, 2.6vw, 2rem); line-height: 1.2; }
.sx-deep-copy dl { margin: 1.5rem 0 0; display: grid; gap: 1.15rem; }
.sx-deep-copy dt {
    font-family: var(--font-mono);
    font-size: .7rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--c-primary);
}
html[dir='rtl'] .sx-deep-copy dt { letter-spacing: 0; font-size: .85rem; font-family: var(--font-display); font-weight: 700; }
.sx-deep-copy dd { margin: .35rem 0 0; color: var(--c-text-muted); line-height: 1.7; }
.sx-deep-value {
    padding: 1rem 1.15rem;
    border-radius: calc(var(--radius) * .6);
    border-inline-start: 3px solid var(--c-primary);
    background: color-mix(in srgb, var(--c-primary) 8%, transparent);
}
.sx-deep-value dd { color: var(--c-text); }

/* -------------------------------------------------------------- qualities */
.sx-qualities { display: grid; gap: 2.25rem 2rem; }
@media (min-width: 720px)  { .sx-qualities { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .sx-qualities { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* -------------------------------------------------------------------- tech */
.sx-tech { display: grid; gap: 2.5rem; }
@media (min-width: 1024px) { .sx-tech { grid-template-columns: .9fr 1.1fr; gap: 4rem; align-items: start; } }
.sx-tech .sx-head { margin-bottom: 0; }
.sx-tech .sx-lead { margin-top: 1rem; }
.sx-brochures { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem; margin-top: 2rem; }
.sx-alt-link { font-size: .9rem; color: var(--c-text-muted); text-decoration: underline; text-underline-offset: 4px; }
.sx-alt-link:hover { color: var(--c-text); }
.sx-tech-list { margin: 0; border-top: 1px solid var(--c-border); }
.sx-tech-list > div {
    display: grid;
    gap: .25rem 2rem;
    padding-block: 1.1rem;
    border-bottom: 1px solid var(--c-border);
}
@media (min-width: 640px) { .sx-tech-list > div { grid-template-columns: 11rem 1fr; } }
.sx-tech-list dt { color: var(--c-text-muted); font-size: .9rem; }
.sx-tech-list dd { margin: 0; font-weight: 600; text-align: start; }

/* ----------------------------------------------------------------- motion */
@media (prefers-reduced-motion: reduce) {
    .sx-frame--float, .sx-tour.is-tabbed .sx-panel:not([hidden]) { animation: none; }
}

/* ------------------------------------------------- inline icons (page-only) */
.sx-svg { width: 1.35rem; height: 1.35rem; }

/* ----------------------------------------------------------- operating model
   One approved session in the middle, the four records it updates around it.
   A plain grid with connector rules: no images, mirrors itself in RTL. */
.sx-hub {
    display: grid;
    gap: 1rem;
    align-items: stretch;
}
@media (min-width: 960px) {
    .sx-hub {
        grid-template-columns: 1fr minmax(15rem, .9fr) 1fr;
        grid-template-rows: auto auto;
        gap: 1.25rem 3.5rem;
    }
    .sx-hub-core { grid-column: 2; grid-row: 1 / span 2; }
    .sx-hub-node:nth-of-type(1) { grid-column: 1; grid-row: 1; }
    .sx-hub-node:nth-of-type(2) { grid-column: 1; grid-row: 2; }
    .sx-hub-node:nth-of-type(3) { grid-column: 3; grid-row: 1; }
    .sx-hub-node:nth-of-type(4) { grid-column: 3; grid-row: 2; }
}
.sx-hub-core {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: .75rem;
    padding: clamp(1.5rem, 3vw, 2.25rem);
    border-radius: var(--radius);
    color: var(--c-button-text, #fff);
    background:
        radial-gradient(22rem 16rem at 30% 0%, color-mix(in srgb, #fff 16%, transparent), transparent 70%),
        linear-gradient(150deg, var(--c-primary), var(--c-primary-deep));
    box-shadow: 0 30px 60px -30px color-mix(in srgb, var(--c-primary) 70%, transparent);
}
.sx-hub-core .sx-hub-kicker {
    font-family: var(--font-mono);
    font-size: .7rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    opacity: .8;
}
html[dir='rtl'] .sx-hub-core .sx-hub-kicker { letter-spacing: 0; font-size: .85rem; font-family: inherit; }
.sx-hub-core h3 { font-size: clamp(1.35rem, 2.4vw, 1.75rem); line-height: 1.2; color: inherit; }
.sx-hub-core p { line-height: 1.7; opacity: .92; }
.sx-hub-core ol { list-style: none; margin: .5rem 0 0; padding: 0; display: grid; gap: .45rem; counter-reset: sxhub; }
.sx-hub-core li {
    counter-increment: sxhub;
    display: flex;
    gap: .6rem;
    align-items: baseline;
    font-size: .95rem;
}
.sx-hub-core li::before {
    content: counter(sxhub);
    flex: none;
    display: inline-grid;
    place-items: center;
    width: 1.45rem;
    height: 1.45rem;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-size: .72rem;
    background: color-mix(in srgb, #fff 22%, transparent);
}
.sx-hub-node {
    position: relative;
    padding: 1.35rem 1.5rem;
    border: 1px solid var(--c-border);
    border-radius: var(--radius);
    background: var(--c-bg);
}
.sx-hub-node h3 { display: flex; align-items: center; gap: .75rem; font-size: 1.1rem; }
.sx-hub-node p { margin-top: .6rem; color: var(--c-text-muted); line-height: 1.65; font-size: .95rem; }
.sx-hub-node .sx-module-icon { width: 2.4rem; height: 2.4rem; flex: none; }
.sx-hub-tag {
    display: inline-block;
    margin-top: .8rem;
    padding: .2rem .6rem;
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: .68rem;
    letter-spacing: .06em;
    color: var(--c-primary);
    background: color-mix(in srgb, var(--c-primary) 10%, transparent);
}
html[dir='rtl'] .sx-hub-tag { font-family: inherit; letter-spacing: 0; font-size: .8rem; }
/* Connector from each node towards the core (wide screens only). */
@media (min-width: 960px) {
    .sx-hub-node::after {
        content: '';
        position: absolute;
        top: 50%;
        width: 3.5rem;
        height: 1px;
        background: linear-gradient(90deg, var(--c-border), color-mix(in srgb, var(--c-primary) 60%, transparent));
    }
    .sx-hub-node:nth-of-type(1)::after, .sx-hub-node:nth-of-type(2)::after { inset-inline-start: 100%; }
    .sx-hub-node:nth-of-type(3)::after, .sx-hub-node:nth-of-type(4)::after { inset-inline-end: 100%; transform: scaleX(-1); }
    html[dir='rtl'] .sx-hub-node:nth-of-type(1)::after, html[dir='rtl'] .sx-hub-node:nth-of-type(2)::after { transform: scaleX(-1); }
    html[dir='rtl'] .sx-hub-node:nth-of-type(3)::after, html[dir='rtl'] .sx-hub-node:nth-of-type(4)::after { transform: none; }
}
.sx-hub-note { margin-top: 1.5rem; color: var(--c-text-muted); font-size: .9rem; line-height: 1.6; max-width: 70ch; }

/* ------------------------------------------------------------- the numbers
   Demonstration figures from SalesX's own reports. Chart shapes carry `fc-*`
   classes (App\Support\CaseStudies\FinancialCharts); colours live here so the
   charts follow the site theme in light and dark mode. */
.sx-numbers { --fc-products: color-mix(in srgb, var(--c-text) 22%, var(--c-bg));
              --fc-commissions: #E8A33D;
              --fc-operating: color-mix(in srgb, var(--c-text) 42%, var(--c-bg));
              --fc-salaries: color-mix(in srgb, var(--c-text) 42%, var(--c-bg));
              --fc-rent: color-mix(in srgb, var(--c-text) 32%, var(--c-bg));
              --fc-marketing: color-mix(in srgb, #E8A33D 55%, var(--c-bg));
              --fc-other: color-mix(in srgb, var(--c-text) 14%, var(--c-bg));
              --fc-net: var(--c-primary); }
.fc-products { fill: var(--fc-products); background: var(--fc-products); }
.fc-commissions { fill: var(--fc-commissions); background: var(--fc-commissions); }
.fc-operating { fill: var(--fc-operating); background: var(--fc-operating); }
.fc-salaries { fill: var(--fc-salaries); background: var(--fc-salaries); }
.fc-rent { fill: var(--fc-rent); background: var(--fc-rent); }
.fc-marketing { fill: var(--fc-marketing); background: var(--fc-marketing); }
.fc-other { fill: var(--fc-other); background: var(--fc-other); }
.fc-net { fill: var(--fc-net); background: var(--fc-net); }
.fc { display: block; width: 100%; height: auto; overflow: visible; }
.fc text { font-family: var(--font-body, inherit); }
.fc-grid { stroke: var(--c-border); stroke-width: 1; }
.fc-axis { fill: var(--c-text-muted); font-size: 12px; }
.fc-unit { fill: var(--c-text-muted); font-size: 11px; }
.fc-value { fill: var(--c-text); font-size: 13px; font-weight: 700; }
.fc-in { fill: var(--c-button-text, #fff); font-size: 12px; font-weight: 700; }
.fc-month { font-size: 13px; }

.sx-disclaimer {
    display: flex; flex-wrap: wrap; align-items: baseline; gap: .5rem .85rem;
    margin: -1rem 0 2rem; max-width: 70rem;
    padding: .9rem 1.1rem; border-radius: calc(var(--radius) * .6);
    border: 1px dashed color-mix(in srgb, #E8A33D 55%, var(--c-border));
    background: color-mix(in srgb, #E8A33D 7%, transparent);
    color: var(--c-text-muted); font-size: .92rem; line-height: 1.6;
}
.sx-badge {
    flex: none; padding: .2rem .65rem; border-radius: 999px;
    font-family: var(--font-mono); font-size: .68rem; letter-spacing: .1em; text-transform: uppercase;
    color: #1b1206; background: #E8A33D;
}
html[dir='rtl'] .sx-badge { font-family: inherit; letter-spacing: 0; font-size: .82rem; text-transform: none; }

.sx-kpis { margin: 0 0 1.5rem; display: grid; gap: 1px; grid-template-columns: repeat(2, minmax(0, 1fr));
           background: var(--c-border); border: 1px solid var(--c-border); border-radius: var(--radius); overflow: hidden; }
@media (min-width: 720px)  { .sx-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .sx-kpis { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.sx-kpi { background: var(--c-bg); padding: 1.1rem 1.2rem; display: flex; flex-direction: column; gap: .3rem; }
.sx-kpi dt { color: var(--c-text-muted); font-size: .82rem; line-height: 1.4; }
.sx-kpi dd { margin: 0; }
.sx-kpi-num { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.45rem, 2.4vw, 1.9rem); line-height: 1.1; font-variant-numeric: tabular-nums; }
.sx-kpi-unit { font-size: .78rem; color: var(--c-text-muted); }
.sx-kpi-sub { font-size: .8rem; color: var(--c-text-muted); }
.sx-kpi--key { background: color-mix(in srgb, var(--c-primary) 10%, var(--c-bg)); }
.sx-kpi--key .sx-kpi-num { color: var(--c-primary); }

.sx-chart { margin: 0; padding: clamp(1.1rem, 2.5vw, 1.6rem); background: var(--c-bg); }
.sx-chart-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1.5rem; margin-bottom: 1rem; }
.sx-chart-head strong { font-family: var(--font-display); font-size: 1.1rem; }
.sx-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem 1rem; font-size: .82rem; color: var(--c-text-muted); }
.sx-legend li, .sx-shares li { display: flex; align-items: center; gap: .45rem; }
.sx-sw { flex: none; width: .8rem; height: .8rem; border-radius: .2rem; display: inline-block; }
.sx-chart-body { overflow-x: auto; }
.sx-chart-body .fc { min-width: 520px; }
.sx-chart-note { margin-top: .75rem; font-size: .82rem; color: var(--c-text-muted); }

.sx-numbers-grid { display: grid; gap: 1.25rem; margin-top: 1.25rem; }
@media (min-width: 1024px) { .sx-numbers-grid { grid-template-columns: 1.15fr .85fr; } }
.sx-numbers-side { display: grid; gap: 1.25rem; align-content: start; }
.sx-split .fc { height: 2.6rem; border-radius: .5rem; overflow: hidden; }
.sx-shares { list-style: none; margin: 1.1rem 0 0; padding: 0; display: grid; gap: .55rem; }
.sx-shares li { display: grid; grid-template-columns: auto 1fr auto auto; gap: .65rem; font-size: .92rem; }
.sx-shares b { font-variant-numeric: tabular-nums; }
.sx-shares em { font-style: normal; color: var(--c-text-muted); font-size: .82rem; min-width: 7.5rem; text-align: end; }
.sx-shares li.is-net { padding-top: .55rem; border-top: 1px solid var(--c-border); font-weight: 600; }
.sx-shares li.is-net b { color: var(--c-primary); }

.sx-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: .9rem; }
.sx-bars li { display: grid; grid-template-columns: 1fr; gap: .3rem; }
.sx-bar-label { font-size: .92rem; font-weight: 600; }
.sx-bar-track { height: .7rem; border-radius: 999px; background: color-mix(in srgb, var(--c-text) 8%, transparent); overflow: hidden; }
.sx-bar-fill { display: block; height: 100%; width: var(--w); border-radius: inherit; background: linear-gradient(90deg, var(--c-primary), color-mix(in srgb, var(--c-primary) 70%, #fff)); }
html[dir='rtl'] .sx-bar-fill { background: linear-gradient(-90deg, var(--c-primary), color-mix(in srgb, var(--c-primary) 70%, #fff)); }
.sx-bar-value { font-size: .8rem; color: var(--c-text-muted); }

.sx-people { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; counter-reset: sxp; }
.sx-people li { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; font-size: .92rem; padding-bottom: .55rem; border-bottom: 1px solid var(--c-border); }
.sx-people li:last-child { border-bottom: 0; padding-bottom: 0; }
.sx-people small { display: block; color: var(--c-text-muted); font-size: .78rem; }
.sx-people b { white-space: nowrap; font-variant-numeric: tabular-nums; }

.sx-pl { margin: 2.5rem 0 0; }
.sx-pl figcaption { margin-top: .9rem; color: var(--c-text-muted); font-size: .92rem; }
.sx-source { margin-top: 1.5rem; font-size: .8rem; color: var(--c-text-muted); max-width: 80ch; line-height: 1.6; }

/* ------------------------------------------------- one model, two industries */
.sx-industries { margin-top: clamp(2.5rem, 5vw, 3.5rem); display: grid; gap: 1.25rem; }
.sx-ind-head { max-width: 60rem; }
.sx-ind-head h3 { font-size: clamp(1.35rem, 2.4vw, 1.75rem); }
.sx-ind-head p { margin-top: .6rem; color: var(--c-text-muted); line-height: 1.7; }
.sx-ind-cards { display: grid; gap: 1.25rem; }
@media (min-width: 820px) { .sx-ind-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.sx-ind-card { position: relative; padding: clamp(1.4rem, 3vw, 1.9rem); background: var(--c-bg); }
.sx-ind-card .sx-hub-tag { position: absolute; top: 1.4rem; inset-inline-end: 1.4rem; margin: 0; }
.sx-ind-card h4 { margin-top: 1rem; font-size: 1.2rem; }
.sx-ind-card p { margin-top: .6rem; color: var(--c-text-muted); line-height: 1.7; }
.sx-ind-card--alt { border-color: color-mix(in srgb, var(--c-primary) 40%, var(--c-border)); background: color-mix(in srgb, var(--c-primary) 6%, var(--c-bg)); }
.sx-map { overflow-x: auto; border: 1px solid var(--c-border); border-radius: var(--radius); background: var(--c-bg); }
.sx-map table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.sx-map caption { text-align: start; padding: 1rem 1.2rem .4rem; font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; }
.sx-map th { text-align: start; padding: .7rem 1.2rem; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; color: var(--c-text-muted); border-bottom: 1px solid var(--c-border); }
html[dir='rtl'] .sx-map th { letter-spacing: 0; text-transform: none; font-size: .88rem; }
.sx-map td { padding: .7rem 1.2rem; border-bottom: 1px solid var(--c-border); vertical-align: top; line-height: 1.5; }
.sx-map tr:last-child td { border-bottom: 0; }
.sx-map td:first-child { color: var(--c-text-muted); width: 45%; }
.sx-map td:last-child { font-weight: 600; }
