/*
 * SHADE TRY-ON (Widgets.ShadeTryOn) - the icon on the photo (the theme's pill draws it: .tc-gact), the button under the
 * variants, and the sheet: a full-height sheet on a phone, a dialog of two columns on a desktop - the photo, and the
 * tools, the model's reading and the shades beside it. Sizes and weights are the theme's (--tc-fs-*, --tc-fw-*).
 */
.tc-sto,
.tc-sto-card {
    --tc-sto-ink: #1d1d1f;
    --tc-sto-muted: #6e6e73;
    --tc-sto-line: #e7e3e0;
    --tc-sto-soft: #f8f4f1;
    --tc-sto-cream: #fbf7f4;
    --tc-sto-brand: var(--ryan-primary, #e45a80);
    --tc-sto-good: #1f8a5b;
    --tc-sto-warn: #b4690e;
}

html.tc-sto-open,
html.tc-sto-open body {
    overflow: hidden !important;
}

/* ----- the icon on the photo: the pill's own row; the sparkle in the store's colour ----- */

.tc-gact--tryon[hidden] {
    display: none !important;
}

.tc-gact--tryon {
    cursor: pointer;
}

.tc-gact--tryon .tc-sto-icon__spark {
    color: var(--ryan-primary, #e45a80);
    fill: currentColor;
    stroke: none;
}

/* ----- the button under the variants ----- */

.tc-sto-card {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    margin: 14px 0 4px;
    padding: 11px 13px;
    border: 1px solid var(--tc-sto-line);
    border-radius: 14px;
    background: linear-gradient(135deg, #fff 0%, var(--tc-sto-cream) 100%);
    font: inherit;
    text-align: right;
    color: var(--tc-sto-ink);
    cursor: pointer;
    transition: border-color .2s, box-shadow .2s, transform .2s;
}

.tc-sto-card--mobile {
    width: calc(100% - 32px);
    margin: 4px 16px 12px;
}

.tc-sto-card:hover {
    border-color: #d9d2cd;
    box-shadow: 0 6px 18px rgba(60, 35, 20, .07);
}

.tc-sto-card:active {
    transform: scale(.995);
}

.tc-sto-card:focus-visible {
    outline: 2px solid var(--tc-sto-brand);
    outline-offset: 2px;
}

.tc-sto-card__dots {
    display: flex;
    flex: 0 0 auto;
    flex-direction: row-reverse;
    padding-inline-end: 8px;
}

.tc-sto-card__dots i {
    width: 24px;
    height: 24px;
    margin-inline-end: -8px;
    border: 2px solid #fff;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .12);
}

.tc-sto-card__text {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.tc-sto-card__title {
    font-size: var(--tc-fs-h4, 15px);
    font-weight: var(--tc-fw-label, 600);
    line-height: 1.5;
}

.tc-sto-card__sub {
    font-size: var(--tc-fs-caption, 13px);
    font-weight: var(--tc-fw-text, 400);
    line-height: 1.6;
    color: var(--tc-sto-muted);
}

.tc-sto-card__go {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #fff;
    color: var(--tc-sto-brand);
    box-shadow: 0 1px 4px rgba(0, 0, 0, .08);
}

/* ----- the sheet ----- */

.tc-sto[hidden],
.tc-sto__intro[hidden],
.tc-sto__studio[hidden] {
    display: none !important;
}

.tc-sto {
    position: fixed;
    inset: 0;
    z-index: 100050;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    direction: rtl;
    font-size: var(--tc-fs-body, 15px);
    color: var(--tc-sto-ink);
}

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

.tc-sto__scrim {
    position: absolute;
    inset: 0;
    background: rgba(20, 14, 10, .45);
    opacity: 0;
    transition: opacity .25s ease;
}

.tc-sto__panel {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    height: 100dvh;
    background: #fff;
    transform: translateY(24px);
    opacity: 0;
    transition: transform .3s cubic-bezier(.2, .8, .2, 1), opacity .25s ease;
}

.tc-sto.is-open .tc-sto__scrim {
    opacity: 1;
}

.tc-sto.is-open .tc-sto__panel {
    transform: none;
    opacity: 1;
}

@media (min-width: 992px) {
    .tc-sto {
        align-items: center;
        padding: 24px;
    }

    /* a fixed height: the photo stays in view while the side scrolls */
    .tc-sto__panel {
        width: min(1040px, 100%);
        height: min(860px, calc(100vh - 48px));
        border-radius: 20px;
        box-shadow: 0 24px 60px rgba(30, 18, 10, .25);
        overflow: hidden;
    }
}

.tc-sto__head {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 16px 10px;
    border-bottom: 1px solid var(--tc-sto-line);
}

.tc-sto__heading {
    min-width: 0;
}

.tc-sto__title {
    margin: 0;
    font-size: var(--tc-fs-section, 19px);
    font-weight: var(--tc-fw-title, 700);
    line-height: 1.5;
}

.tc-sto__product {
    margin: 0;
    overflow: hidden;
    font-size: var(--tc-fs-caption, 13px);
    color: var(--tc-sto-muted);
    white-space: nowrap;
    text-overflow: ellipsis;
}

.tc-sto__close {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--tc-sto-soft);
    color: var(--tc-sto-ink);
    cursor: pointer;
}

.tc-sto__close:hover {
    background: #efe9e5;
}

.tc-sto__body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

/* ----- first: where the photo is from, how to take it ----- */

.tc-sto__intro {
    max-width: 560px;
    margin: 0 auto;
    padding: 18px 16px 24px;
    border-radius: 16px;
    transition: background .2s;
}

.tc-sto__intro.is-drag {
    background: var(--tc-sto-soft);
}

.tc-sto__intro.is-busy {
    opacity: .55;
    pointer-events: none;
}

.tc-sto__lead {
    margin: 0 0 16px;
    font-size: var(--tc-fs-body, 15px);
    line-height: 1.9;
    color: #3a3a3c;
}

.tc-sto__areas {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 16px;
}

.tc-sto__area {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 16px 10px 14px;
    border: 1.5px solid var(--tc-sto-line);
    border-radius: 16px;
    background: #fff;
    font: inherit;
    color: var(--tc-sto-ink);
    text-align: center;
    cursor: pointer;
    transition: border-color .2s, background .2s, box-shadow .2s;
}

.tc-sto__area:hover {
    border-color: #d6cec8;
}

.tc-sto__area.is-on {
    border-color: var(--tc-sto-brand);
    background: var(--tc-sto-cream);
    box-shadow: 0 0 0 3px rgba(228, 90, 128, .08);
}

.tc-sto__area-icon {
    display: flex;
    margin-bottom: 4px;
    color: #8a6f62;
}

.tc-sto__area.is-on .tc-sto__area-icon {
    color: var(--tc-sto-brand);
}

.tc-sto__area-name {
    font-size: var(--tc-fs-h4, 15px);
    font-weight: var(--tc-fw-label, 600);
}

.tc-sto__area-hint {
    font-size: var(--tc-fs-caption, 13px);
    line-height: 1.6;
    color: var(--tc-sto-muted);
}

.tc-sto__area-tick {
    position: absolute;
    top: 8px;
    left: 8px;
    display: none;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--tc-sto-brand);
    color: #fff;
}

.tc-sto__area.is-on .tc-sto__area-tick {
    display: flex;
}

.tc-sto__tips {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: 14px;
    background: var(--tc-sto-soft);
    list-style: none;
}

.tc-sto__tips li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: var(--tc-fs-small, 14px);
    line-height: 1.7;
    color: #3a3a3c;
}

.tc-sto__tips svg {
    flex: 0 0 auto;
    color: #8a6f62;
}

.tc-sto__pick {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tc-sto__btn {
    display: inline-flex;
    flex: 1 1 160px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 10px 16px;
    border: 1.5px solid var(--tc-sto-line);
    border-radius: 14px;
    background: #fff;
    font: inherit;
    font-size: var(--tc-fs-h4, 15px);
    font-weight: var(--tc-fw-label, 600);
    color: var(--tc-sto-ink);
    cursor: pointer;
    transition: background .2s, border-color .2s, opacity .2s;
}

.tc-sto__btn:hover {
    border-color: #d6cec8;
}

.tc-sto__btn--primary {
    border-color: var(--tc-sto-brand);
    background: var(--tc-sto-brand);
    color: #fff;
}

.tc-sto__btn--primary:hover {
    border-color: var(--tc-sto-brand);
    opacity: .92;
}

.tc-sto__btn:disabled {
    border-color: var(--tc-sto-line);
    background: var(--tc-sto-soft);
    color: var(--tc-sto-muted);
    cursor: default;
    opacity: 1;
}

.tc-sto__btn:focus-visible,
.tc-sto__area:focus-visible,
.tc-sto__chip:focus-visible,
.tc-sto__seg-item:focus-visible,
.tc-sto__close:focus-visible {
    outline: 2px solid var(--tc-sto-brand);
    outline-offset: 2px;
}

.tc-sto__drop {
    margin: 10px 0 0;
    font-size: var(--tc-fs-caption, 13px);
    color: var(--tc-sto-muted);
    text-align: center;
}

.tc-sto__error {
    margin: 12px 0 0;
    padding: 10px 12px;
    border-radius: 12px;
    background: #fdf0ef;
    font-size: var(--tc-fs-small, 14px);
    color: #b3261e;
}

.tc-sto__privacy {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 16px 0 0;
    font-size: var(--tc-fs-caption, 13px);
    line-height: 1.8;
    color: var(--tc-sto-muted);
}

.tc-sto__privacy svg {
    flex: 0 0 auto;
    margin-top: 3px;
}

/* ----- then: the photo and the shades ----- */

.tc-sto__studio {
    display: flex;
    flex-direction: column;
}

@media (min-width: 992px) {
    .tc-sto__studio {
        flex-direction: row;
        align-items: stretch;
        height: 100%;
        min-height: 0;
    }
}

.tc-sto__stage-wrap {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 12px 4px;
    background: #f4f1ee;
}

@media (min-width: 992px) {
    .tc-sto__stage-wrap {
        flex: 1 1 58%;
        min-height: 0;
        padding: 20px;
    }
}

.tc-sto__stage {
    --tc-sto-cut: 50%;
    position: relative;
    display: inline-block;
    max-width: 100%;
    line-height: 0;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(40, 25, 15, .12);
    touch-action: pan-y;
    user-select: none;
    -webkit-user-select: none;
    cursor: ew-resize;
}

.tc-sto__after {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 50vh;
    max-height: 50dvh;
}

@media (min-width: 992px) {
    .tc-sto__after {
        max-height: min(700px, calc(100vh - 230px));
    }
}

.tc-sto__before {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    clip-path: inset(0 calc(100% - var(--tc-sto-cut)) 0 0);
    pointer-events: none;
}

.tc-sto__cut {
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--tc-sto-cut);
    width: 2px;
    margin-left: -1px;
    background: rgba(255, 255, 255, .95);
    box-shadow: 0 0 6px rgba(0, 0, 0, .25);
    pointer-events: none;
}

.tc-sto__cut-knob {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin: -15px 0 0 -15px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .25);
}

.tc-sto__cut-knob::before,
.tc-sto__cut-knob::after {
    content: "";
    position: absolute;
    top: 50%;
    width: 0;
    height: 0;
    margin-top: -5px;
    border: 5px solid transparent;
}

.tc-sto__cut-knob::before {
    left: 3px;
    border-right-color: #6e6e73;
}

.tc-sto__cut-knob::after {
    right: 3px;
    border-left-color: #6e6e73;
}

.tc-sto__tag {
    position: absolute;
    top: 10px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgba(20, 14, 10, .5);
    font-size: 12px;
    font-weight: var(--tc-fw-label, 600);
    line-height: 1.7;
    color: #fff;
    pointer-events: none;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.tc-sto__tag--before {
    left: 10px;
}

.tc-sto__tag--after {
    right: 10px;
}

.tc-sto__stage.is-swatch {
    cursor: default;
}

.tc-sto__stage.is-swatch .tc-sto__before,
.tc-sto__stage.is-swatch .tc-sto__cut,
.tc-sto__stage.is-swatch .tc-sto__tag {
    display: none;
}

.tc-sto__stage.is-picking {
    cursor: crosshair;
}

.tc-sto__stage.is-picking .tc-sto__before,
.tc-sto__stage.is-picking .tc-sto__cut {
    display: none;
}

.tc-sto__picker {
    position: absolute;
    bottom: 10px;
    right: 10px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, .88);
    font: inherit;
    font-size: 12.5px;
    font-weight: var(--tc-fw-label, 600);
    line-height: 1.6;
    color: var(--tc-sto-ink);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.tc-sto__stage.is-picking .tc-sto__picker {
    background: var(--tc-sto-brand);
    color: #fff;
}

/* zoom: the picture scaled from its corner (the script sets where); zoomed it is the «after» alone, moved by a finger */
.tc-sto__after {
    transform-origin: 0 0;
}

.tc-sto__zoom {
    position: absolute;
    bottom: 10px;
    left: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .88);
    color: var(--tc-sto-ink);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.tc-sto__stage.is-zoomed {
    touch-action: none;
    cursor: grab;
}

.tc-sto__stage.is-zoomed .tc-sto__before,
.tc-sto__stage.is-zoomed .tc-sto__cut,
.tc-sto__stage.is-zoomed .tc-sto__tag {
    display: none;
}

.tc-sto__stage.is-live .tc-sto__zoom {
    display: none;
}

/* live: the camera as a mirror - the shade on the whole frame, a shutter to keep it as a photo */
.tc-sto__btn--live {
    flex-basis: 100%;
}

.tc-sto__tag--live,
.tc-sto__shutter {
    display: none;
}

.tc-sto__stage.is-live {
    cursor: default;
}

.tc-sto__stage.is-live .tc-sto__before,
.tc-sto__stage.is-live .tc-sto__cut,
.tc-sto__stage.is-live .tc-sto__tag--before,
.tc-sto__stage.is-live .tc-sto__tag--after {
    display: none;
}

.tc-sto__stage.is-live .tc-sto__tag--live {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    right: 10px;
}

.tc-sto__tag--live::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #ff3b30;
    animation: tc-sto-live 1.6s ease-in-out infinite;
}

@keyframes tc-sto-live {
    50% {
        opacity: .35;
    }
}

.tc-sto__stage.is-live .tc-sto__shutter {
    display: block;
    position: absolute;
    bottom: 14px;
    left: 50%;
    width: 60px;
    height: 60px;
    margin-left: -30px;
    box-sizing: border-box;
    padding: 4px;
    border: 3px solid #fff;
    border-radius: 50%;
    background: #fff content-box;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .3);
    cursor: pointer;
    transition: transform .15s;
}

.tc-sto__stage.is-live .tc-sto__shutter:active {
    transform: scale(.9);
}

.tc-sto__shutter:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 3px;
}

.tc-sto__video {
    position: absolute;
    top: 0;
    left: 0;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.tc-sto__stage-hint {
    position: absolute;
    top: 10px;
    right: 10px;
    left: 10px;
    margin: 0;
    padding: 8px 12px;
    border-radius: 12px;
    background: rgba(20, 14, 10, .62);
    font-size: 13px;
    line-height: 1.7;
    color: #fff;
    text-align: center;
    pointer-events: none;
}

.tc-sto__scan[hidden] {
    display: none !important;
}

.tc-sto__scan {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.tc-sto__scan-line {
    position: absolute;
    right: 0;
    left: 0;
    height: 30%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, .28) 85%, rgba(255, 255, 255, .85) 100%);
    animation: tc-sto-scan 2.2s cubic-bezier(.45, 0, .55, 1) infinite;
}

.tc-sto__scan-text {
    position: absolute;
    bottom: 12px;
    left: 50%;
    padding: 5px 14px;
    border-radius: 999px;
    background: rgba(20, 14, 10, .55);
    font-size: 12.5px;
    font-weight: var(--tc-fw-label, 600);
    line-height: 1.7;
    color: #fff;
    white-space: nowrap;
    transform: translateX(-50%);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

@keyframes tc-sto-scan {
    0% { top: -30%; }
    100% { top: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .tc-sto__scan-line {
        animation: none;
        top: 35%;
    }

    .tc-sto__tag--live::before {
        animation: none;
    }
}

.tc-sto__legend[hidden] {
    display: none !important;
}

.tc-sto__legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px 14px;
    margin: 0;
    padding: 0 4px;
    font-size: var(--tc-fs-caption, 13px);
    line-height: 1.6;
}

.tc-sto__legend-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.tc-sto__legend-item b {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    font-size: 11.5px;
    font-weight: 700;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .15);
}

.tc-sto__legend-item i {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1);
}

.tc-sto__side {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
    padding: 14px 16px 0;
}

@media (min-width: 992px) {
    .tc-sto__side {
        flex: 0 0 42%;
        max-width: 440px;
        padding: 20px 22px 0;
        overflow-y: auto;
    }
}

.tc-sto__tools {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tc-sto__tool {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.tc-sto__tool-name {
    font-size: var(--tc-fs-small, 14px);
    font-weight: var(--tc-fw-label, 600);
    color: #3a3a3c;
}

/* a lipstick's finish (the product's, not a choice): a quiet line under the tools */
.tc-sto__finish {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    font-size: var(--tc-fs-caption, 13px);
    color: var(--tc-sto-muted);
}

.tc-sto__finish b {
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--tc-sto-soft);
    font-weight: var(--tc-fw-label, 600);
    color: var(--tc-sto-ink);
}

.tc-sto__seg {
    display: flex;
    padding: 3px;
    border-radius: 12px;
    background: var(--tc-sto-soft);
}

.tc-sto__tools > .tc-sto__seg {
    width: 100%;
}

.tc-sto__seg-item {
    flex: 1 1 0;
    min-width: 58px;
    padding: 6px 12px;
    /* one line each: «دور و داخل لب» must not grow the row */
    white-space: nowrap;
    border: 0;
    border-radius: 9px;
    background: transparent;
    font: inherit;
    font-size: var(--tc-fs-small, 14px);
    font-weight: var(--tc-fw-label, 600);
    line-height: 1.6;
    color: var(--tc-sto-muted);
    cursor: pointer;
    transition: background .2s, color .2s, box-shadow .2s;
}

.tc-sto__seg-item.is-on {
    background: #fff;
    color: var(--tc-sto-ink);
    box-shadow: 0 1px 4px rgba(0, 0, 0, .1);
}

/* ----- the model's reading ----- */

.tc-sto__ai[hidden] {
    display: none !important;
}

.tc-sto__ai {
    padding: 12px 14px;
    border: 1px solid #efe5de;
    border-radius: 16px;
    background: linear-gradient(160deg, #fff 0%, var(--tc-sto-cream) 100%);
}

.tc-sto__ai.is-warn {
    border-color: #f2dcc0;
    background: #fdf7ee;
}

.tc-sto__ai.is-quiet {
    border-style: dashed;
    background: #fff;
}

.tc-sto__ai-head,
.tc-sto__ai-busy {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--tc-fs-h4, 15px);
    font-weight: var(--tc-fw-label, 600);
}

.tc-sto__ai-head svg,
.tc-sto__ai-busy svg {
    color: var(--tc-sto-brand);
}

.tc-sto__ai.is-warn .tc-sto__ai-head svg {
    color: var(--tc-sto-warn);
}

.tc-sto__ai-busy svg {
    animation: tc-sto-pulse 1.4s ease-in-out infinite;
}

@keyframes tc-sto-pulse {
    50% { transform: scale(.75); opacity: .55; }
}

.tc-sto__shimmer {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
}

.tc-sto__shimmer i {
    display: block;
    height: 10px;
    border-radius: 6px;
    background: linear-gradient(90deg, #f1ebe6 0%, #faf6f3 50%, #f1ebe6 100%);
    background-size: 200% 100%;
    animation: tc-sto-shimmer 1.3s linear infinite;
}

.tc-sto__shimmer i:last-child {
    width: 62%;
}

@keyframes tc-sto-shimmer {
    to { background-position: -200% 0; }
}

.tc-sto__facts {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 8px;
    margin: 10px 0 0;
}

.tc-sto__fact {
    display: flex;
    flex-direction: column;
    padding: 6px 10px;
    border-radius: 10px;
    background: #fff;
    box-shadow: inset 0 0 0 1px #efe7e1;
}

.tc-sto__fact dt {
    font-size: 11.5px;
    font-weight: var(--tc-fw-text, 400);
    line-height: 1.6;
    color: var(--tc-sto-muted);
}

.tc-sto__fact dd {
    margin: 0;
    font-size: var(--tc-fs-small, 14px);
    font-weight: var(--tc-fw-label, 600);
    line-height: 1.6;
}

.tc-sto__fact--skin {
    flex-direction: row;
    align-items: center;
    gap: 8px;
}

.tc-sto__fact--skin i {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08);
}

.tc-sto__ai-summary,
.tc-sto__ai-msg,
.tc-sto__ai-note {
    margin: 10px 0 0;
    font-size: var(--tc-fs-small, 14px);
    line-height: 1.85;
    color: #3a3a3c;
}

.tc-sto__ai-msg {
    margin: 0;
    color: var(--tc-sto-muted);
}

.tc-sto__ai-note {
    padding-top: 8px;
    border-top: 1px dashed #eadfd7;
}

.tc-sto__ai-note[hidden] {
    display: none;
}

/* a sofa's AI picture: one button, its note above the way back */
.tc-sto__ai--picture {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tc-sto__ai--picture .tc-sto__ai-note {
    margin: 0;
    padding: 0;
    border: 0;
}

.tc-sto__ai--picture .tc-sto__btn {
    flex: 0 0 auto;
    width: 100%;
}

.tc-sto__btn--ai {
    border-color: var(--tc-sto-brand);
    color: var(--tc-sto-brand);
}

.tc-sto__btn--ai svg,
.tc-sto__btn--small svg {
    color: var(--tc-sto-brand);
}

.tc-sto__btn--small {
    min-height: 40px;
    font-size: var(--tc-fs-small, 14px);
}

.tc-sto__stage.is-ai .tc-sto__tag--after {
    background: var(--tc-sto-brand);
    color: #fff;
}

.tc-sto__problems {
    margin: 8px 0 0;
    padding: 0 18px 0 0;
    font-size: var(--tc-fs-small, 14px);
    line-height: 1.8;
    color: var(--tc-sto-warn);
}

/* ----- the shades ----- */

.tc-sto__shades {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tc-sto__group-head {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: var(--tc-fs-small, 14px);
    font-weight: var(--tc-fw-label, 600);
    color: #3a3a3c;
}

.tc-sto__group-head svg {
    color: var(--tc-sto-brand);
}

.tc-sto__group-head--all {
    margin-top: 4px;
    font-weight: var(--tc-fw-text, 400);
    color: var(--tc-sto-muted);
}

.tc-sto__picks {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tc-sto__rail {
    display: flex;
    gap: 4px;
    margin: 0 -16px;
    padding: 2px 16px 6px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
}

@media (min-width: 992px) {
    .tc-sto__rail {
        flex-wrap: wrap;
        margin: 0;
        padding: 2px 0;
        overflow: visible;
    }
}

.tc-sto__chip {
    position: relative;
    display: flex;
    flex: 0 0 68px;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    padding: 4px 2px;
    border: 0;
    border-radius: 12px;
    background: none;
    font: inherit;
    color: var(--tc-sto-ink);
    cursor: pointer;
}

.tc-sto__chip-dot {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    color: transparent;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08);
    transition: box-shadow .2s, transform .2s;
}

.tc-sto__chip.is-on .tc-sto__chip-dot {
    color: #fff;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--tc-sto-ink);
}

.tc-sto__chip.is-on .tc-sto__chip-dot.is-light {
    color: var(--tc-sto-ink);
}

.tc-sto__chip:hover .tc-sto__chip-dot {
    transform: scale(1.05);
}

.tc-sto__chip.is-off .tc-sto__chip-dot {
    background-image: linear-gradient(135deg, transparent 47%, rgba(255, 255, 255, .9) 47%, rgba(255, 255, 255, .9) 53%, transparent 53%) !important;
}

.tc-sto__chip-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* a name in Latin («306 Light Peach») keeps its own order, and its digits Latin as on the page */
.tc-sto__chip-name,
.tc-sto__legend-item span {
    unicode-bidi: plaintext;
    font-family: IRANYekanXEn, IRANYekanX, sans-serif;
}

.tc-sto__chip-name {
    display: -webkit-box;
    max-width: 66px;
    overflow: hidden;
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.tc-sto__chip.is-on .tc-sto__chip-name {
    font-weight: var(--tc-fw-label, 600);
}

.tc-sto__chip-num {
    position: absolute;
    top: 0;
    left: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--tc-sto-ink);
    font-size: 11px;
    font-weight: 700;
    color: #fff;
}

/* a suggestion: the dot beside its name and how well it fits */
.tc-sto__chip--big {
    flex: 0 1 auto;
    flex-direction: row;
    gap: 9px;
    padding: 6px 8px 6px 14px;
    border: 1px solid var(--tc-sto-line);
    border-radius: 999px;
    background: #fff;
    transition: border-color .2s, background .2s;
}

.tc-sto__chip--big.is-on {
    border-color: var(--tc-sto-ink);
    background: var(--tc-sto-cream);
}

.tc-sto__chip--big .tc-sto__chip-dot {
    width: 32px;
    height: 32px;
}

.tc-sto__chip--big .tc-sto__chip-num {
    top: -5px;
    right: 2px;
    left: auto;
}

.tc-sto__chip--big.is-on .tc-sto__chip-dot {
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08);
}

.tc-sto__chip--big .tc-sto__chip-text {
    align-items: flex-start;
}

.tc-sto__chip--big .tc-sto__chip-name {
    max-width: 150px;
    font-size: var(--tc-fs-small, 14px);
    text-align: right;
    -webkit-line-clamp: 1;
}

.tc-sto__chip-fit {
    font-size: 11.5px;
    line-height: 1.5;
    color: var(--tc-sto-muted);
}

.tc-sto__chip-fit--best {
    font-weight: var(--tc-fw-label, 600);
    color: var(--tc-sto-good);
}

.tc-sto__chip-fit--good {
    color: #2f7a99;
}

.tc-sto__note {
    margin: 0;
    font-size: var(--tc-fs-caption, 13px);
    line-height: 1.8;
    color: var(--tc-sto-muted);
}

.tc-sto__note.is-warn {
    color: var(--tc-sto-warn);
}

.tc-sto__actions {
    position: sticky;
    bottom: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: auto -16px 0;
    padding: 10px 16px calc(12px + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid var(--tc-sto-line);
    background: #fff;
}

@media (min-width: 992px) {
    .tc-sto__actions {
        margin: auto -22px 0;
        padding: 12px 22px 16px;
    }
}

.tc-sto__choose {
    flex: 1 1 0;
    min-width: 0;
}

.tc-sto__choose span {
    line-height: 1.45;
    font-family: IRANYekanXEn, IRANYekanX, sans-serif;
}

.tc-sto__choose[hidden] {
    display: none;
}

.tc-sto__again {
    flex: 0 0 auto;
    padding-inline: 14px;
}
