.x-home-tour {
    --tour-ink: #0f172a;
    --tour-muted: #475569;
    --tour-line: #dce3f2;
    --tour-thumb: #eef2ff;
    --tour-panel: linear-gradient(180deg,rgba(255,255,255,.99),rgba(248,250,252,.96));
    --tour-accent: #5037c7;
    --tour-focus: #6044d5;
    --tour-gap: .85rem;
    max-width: 76rem;
    margin: clamp(2.5rem, 6vw, 4.5rem) auto 0;
    scroll-margin-top: 6rem;
    color: var(--tour-ink);
}
.launch-video-tour .x-home-tour { margin-bottom: clamp(2.5rem, 6vw, 4.5rem); }
html.dark .x-home-tour {
    --tour-ink: #f1f5ff;
    --tour-muted: #b6c1de;
    --tour-line: #39435f;
    --tour-thumb: #232c48;
    --tour-panel: #161e32;
    --tour-accent: #5b41d7;
    --tour-focus: #b3a5ff;
}
.x-home-tour__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    padding-inline: .25rem;
}
.x-home-tour__header h2 {
    margin: 0;
    font-size: clamp(1.6rem, 3.2vw, 2.4rem);
    font-weight: 650;
    letter-spacing: -.045em;
    line-height: 1.1;
}
.x-home-tour__header p { max-width: 48ch; margin: .55rem 0 0; color: var(--tour-muted); font-size: .94rem; }
.x-home-tour__header .x-home-tour__preview { font-size: .8rem; }
.x-home-tour__arrows { display: flex; flex: none; gap: .4rem; }
.x-home-tour__arrows[hidden] { display: none; }
.x-home-tour__arrows button { display: grid; width: 2.75rem; min-height: 2.75rem; padding: 0; place-items: center; }
.x-home-tour__arrows button:disabled { opacity: .46; cursor: default; }
.x-home-tour__arrows svg, .x-home-tour__dialog-header svg { width: 1rem; height: 1rem; }
.x-home-tour__track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: min(78%, 17rem);
    gap: var(--tour-gap);
    margin: .85rem 0 0;
    padding: .3rem .25rem .65rem;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scroll-padding-inline: .25rem;
    scroll-snap-type: x mandatory;
    scrollbar-color: var(--tour-line) transparent;
    scrollbar-width: thin;
    list-style: none;
}
.x-home-tour__track li { min-width: 0; scroll-snap-align: start; }
.x-home-tour :is(.x-home-tour__card, .x-home-tour__dialog) {
    border: 1px solid var(--tour-line);
    border-radius: 1rem;
    background: var(--tour-panel);
    color: var(--tour-ink);
}
.x-home-tour__card {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    overflow: hidden;
    text-align: left;
}
.x-home-tour button.x-home-tour__card { cursor: pointer; transition: border-color .2s ease; }
.x-home-tour button.x-home-tour__card:is(:hover, :focus-visible) { border-color: var(--tour-focus); }
.x-home-tour :is(button, .x-home-tour__track):focus-visible { outline: 2px solid var(--tour-focus); outline-offset: 2px; }
.x-home-tour__thumb {
    position: relative;
    display: grid;
    place-items: center;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-bottom: 1px solid var(--tour-line);
    background: var(--tour-thumb);
}
.x-home-tour__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.x-home-tour__play {
    position: relative;
    display: grid;
    place-items: center;
    width: 2.65rem;
    height: 2.65rem;
    border-radius: 50%;
    background: #171432;
    color: #fff;
    box-shadow: 0 2px 10px #0f172a55;
    transition: background-color .2s ease;
}
button.x-home-tour__card:is(:hover, :focus-visible) .x-home-tour__play { background: var(--tour-accent); }
.x-home-tour__play svg { width: 1rem; height: 1rem; margin-left: .1rem; fill: currentColor; }
.x-home-tour__duration {
    position: absolute;
    right: .45rem;
    bottom: .45rem;
    padding: .15rem .4rem;
    border-radius: .35rem;
    background: #0f172a;
    color: #fff;
    font-size: .72rem;
    font-variant-numeric: tabular-nums;
}
.x-home-tour__card-label { display: grid; gap: .15rem; padding: .7rem .8rem .8rem; }
.x-home-tour__card-label strong { font-size: .9rem; font-weight: 650; line-height: 1.25; }
.x-home-tour__card-label small { color: var(--tour-muted); font-size: .75rem; }
.x-home-tour__dialog {
    position: fixed;
    inset: 0;
    width: min(55rem, calc(100% - 1.5rem));
    max-height: calc(100dvh - 1.5rem);
    margin: auto;
    padding: 0;
    overflow: auto;
    box-shadow: 0 24px 80px #0f172a45;
}
.x-home-tour__dialog::backdrop { background: #080b1dcc; }
.x-home-tour__dialog-header { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .75rem 1rem; }
.x-home-tour__dialog-header h3 { margin: 0; font-size: clamp(1rem, 2.8vw, 1.25rem); font-weight: 650; line-height: 1.2; }
.x-home-tour__dialog-header button { display: inline-flex; align-items: center; min-height: 2.5rem; gap: .3rem; }
.x-home-tour__player video { display: block; width: 100%; max-height: calc(100dvh - 6rem); aspect-ratio: 16 / 9; background: #020617; }
.x-home-tour__error { margin: 0; padding: .8rem 1rem 1.15rem; color: var(--tour-muted); }
@media (max-width: 39.99rem) {
    .x-home-tour__arrows { display: none; }
}
@media (min-width: 40rem) {
    .x-home-tour__track { grid-auto-columns: calc((100% - 2 * var(--tour-gap)) / 3); }
}
@media (min-width: 64rem) {
    .x-home-tour__track { grid-auto-columns: calc((100% - 3 * var(--tour-gap)) / 4); }
}
