/* ==========================================================================
   Kodecraft — public site (header, home, knowledge base, docs, changelog,
   tutorials, contact, footer, mobile tab bar)
   ========================================================================== */

.ks-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--kc-bg);
}

.ks-shell {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 24px;
}

.ks-main {
    flex: 1;
    padding: 26px 0 40px;
}

/* ------------------------------------------------------------------ header */

.ks-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: var(--kc-surface);
    border-bottom: 1px solid var(--kc-line);
}

.ks-header-inner {
    display: flex;
    align-items: center;
    gap: 18px;
    height: var(--kc-header-h);
}

.ks-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--kc-ink);
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -.4px;
    flex: none;
}

.ks-brand:hover {
    color: var(--kc-ink);
}

.ks-brand-mark {
    width: 44px;
    height: 44px;
    flex: none;
    object-fit: contain;
    border-radius: var(--kc-radius-sm);
}

.ks-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0 auto;
    min-width: 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.ks-nav::-webkit-scrollbar {
    display: none;
}

.ks-nav-link {
    position: relative;
    padding: 10px 12px;
    border-radius: 9px;
    color: var(--kc-ink-2);
    font-size: 0.8438rem;
    font-weight: 600;
    white-space: nowrap;
}

.ks-nav-link:hover {
    color: var(--kc-primary);
    background: var(--kc-primary-softer);
}

.ks-nav-active {
    color: var(--kc-primary);
}

.ks-nav-active::after {
    content: "";
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--kc-primary);
}

.ks-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: none;
}

.ks-bell {
    position: relative;
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: var(--kc-slate);
}

.ks-bell:hover {
    background: var(--kc-line-soft);
    color: var(--kc-ink);
}

.ks-bell-count {
    position: absolute;
    top: 2px;
    right: 2px;
    min-width: 17px;
    height: 17px;
    padding: 0 4px;
    border-radius: var(--kc-radius-pill);
    background: #EF4444;
    color: #FFF;
    font-size: 0.625rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.ks-user {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 4px 10px 4px 4px;
    border-radius: var(--kc-radius-pill);
    color: var(--kc-ink-2);
}

.ks-user-mobile,
.ks-login-mobile {
    display: none;
    flex: none;
}

.ks-user:hover {
    background: var(--kc-line-soft);
    color: var(--kc-ink);
}

.ks-user-name {
    font-size: 0.8438rem;
    font-weight: 600;
    line-height: 1.2;
}

.ks-user-role {
    color: var(--kc-muted);
    font-size: 0.7188rem;
}

.ks-bell-wrap {
    display: none;
}

.ks-burger {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--kc-ink-2);
}

/* mobile drawer — a fixed, self-scrolling overlay so a long menu scrolls on its
   own instead of pushing the whole page (header included) down the screen, and
   sits above the tabbar/chat launcher instead of having them float on top of it */
.ks-drawer {
    display: none;
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 80;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    border-top: 1px solid var(--kc-line);
    background: var(--kc-surface);
    padding: 10px 16px calc(24px + env(safe-area-inset-bottom));
}

.ks-drawer-open {
    display: block;
}

.ks-drawer-heading {
    margin-top: 10px;
    padding: 6px 4px 4px;
    color: var(--kc-muted-2);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    border-top: 1px solid var(--kc-line-soft);
}

.ks-drawer-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 4px;
    color: var(--kc-ink-2);
    font-weight: 600;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-drawer-link .kc-i {
    color: var(--kc-muted);
}

.ks-drawer-active {
    color: var(--kc-primary);
}

.ks-drawer-active .kc-i {
    color: var(--kc-primary);
}

.ks-drawer-link-btn {
    width: 100%;
    border: 0;
    background: none;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.ks-drawer-actions {
    display: flex;
    gap: 10px;
    margin-top: 14px;
}

.ks-drawer-actions > .kc-btn,
.ks-drawer-actions > form {
    flex: 1;
    min-width: 0;
}

/* ---------------------------------------------------------------- home hero */

.ks-hero {
    position: relative;
    background: linear-gradient(180deg, #F1EDFE 0%, #EBE6FD 100%);
    overflow: hidden;
}

:root[data-theme="dark"] .ks-hero {
    background: linear-gradient(180deg, var(--kc-primary-softer) 0%, var(--kc-primary-soft) 100%);
}

:root[data-theme="dark"] .ks-hero-sub {
    color: var(--kc-muted);
}

.ks-hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
    align-items: center;
    gap: 30px;
    padding: 54px 0 58px;
}

.ks-hero h1 {
    font-size: 2.5rem;
    letter-spacing: -1px;
}

.ks-hero-sub {
    color: #4B5563;
    font-size: 0.9688rem;
    margin-top: 10px;
    max-width: 520px;
}

.ks-hero-search {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 26px;
    max-width: 640px;
}

.ks-hero-search .kc-input-icon {
    flex: 1;
}

.ks-hero-search .kc-input {
    height: 52px;
    border-radius: var(--kc-radius);
    box-shadow: var(--kc-shadow-sm);
    border-color: transparent;
}

.ks-hero-search .kc-btn {
    height: 52px;
    padding: 0 26px;
    border-radius: var(--kc-radius);
}

.ks-hero-actions {
    margin-top: 18px;
}

.ks-hero-dots {
    position: absolute;
    width: 120px;
    height: 90px;
    opacity: .5;
    background-image: radial-gradient(var(--kc-primary-border) 1.6px, transparent 1.6px);
    background-size: 14px 14px;
}

.ks-hero-dots-left {
    left: 24px;
    top: 34px;
}

.ks-hero-dots-right {
    right: 34px;
    bottom: 26px;
}

.ks-hero-art {
    display: flex;
    justify-content: center;
}

.ks-hero-art svg {
    width: 100%;
    max-width: 420px;
    height: auto;
}

.ks-hero-art img {
    width: auto;
    height: auto;
    max-width: 460px;
    max-height: 480px;
    border-radius: var(--kc-radius-lg, var(--kc-radius));
}

/* ---------------------------------------------------- hero hover motion */

.ks-hero-dots {
    transition: transform .5s ease;
}

.ks-hero-art {
    transition: transform .35s ease;
}

.ks-hero-art img,
.ks-hero-art svg {
    transition: filter .35s ease, box-shadow .35s ease;
}

.ks-hero:hover .ks-hero-dots-left {
    transform: translate(-8px, -8px);
}

.ks-hero:hover .ks-hero-dots-right {
    transform: translate(8px, 8px);
}

.ks-hero:hover .ks-hero-art {
    transform: translateY(-6px) scale(1.03);
}

.ks-hero:hover .ks-hero-art svg {
    filter: drop-shadow(0 8px 24px rgba(16, 24, 40, .08));
}

@media (prefers-reduced-motion: reduce) {
    .ks-hero-dots,
    .ks-hero-art,
    .ks-hero-art img,
    .ks-hero-art svg {
        transition: none;
    }

    .ks-hero:hover .ks-hero-art {
        transform: none;
    }
}

/* full-width stats band under the hero */
.ks-statband {
    background: var(--kc-surface);
    border-bottom: 1px solid var(--kc-line);
}

.ks-statband-inner {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ks-statband-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 22px 24px;
}

.ks-statband-item + .ks-statband-item {
    border-left: 1px solid var(--kc-line-soft);
}

.ks-statband-icon {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--kc-primary-soft);
    color: var(--kc-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
}

.ks-statband-value {
    font-size: 1.3125rem;
    font-weight: 700;
    letter-spacing: -.3px;
}

.ks-statband-label {
    font-weight: 600;
    font-size: 0.8438rem;
}

.ks-statband-sub {
    color: var(--kc-muted);
    font-size: 0.7812rem;
}

/* ------------------------------------------------------- product carousel */

.ks-carousel-btn {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--kc-line);
    border-radius: 50%;
    background: var(--kc-surface);
    color: var(--kc-slate);
    flex: none;
}

.ks-carousel-btn:hover {
    border-color: var(--kc-primary-border);
    color: var(--kc-primary);
}

.ks-carousel {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(196px, 1fr);
    gap: 16px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding-bottom: 2px;
}

.ks-carousel::-webkit-scrollbar {
    display: none;
}

.ks-product {
    scroll-snap-align: start;
    display: flex;
    flex-direction: column;
    padding: 16px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
}

.ks-product:hover {
    border-color: var(--kc-primary-border);
    box-shadow: var(--kc-shadow-sm);
}

.ks-product-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 14px;
}

.ks-product-name {
    font-weight: 700;
    font-size: 0.9375rem;
}

.ks-product-sub {
    color: var(--kc-muted);
    font-size: 0.7812rem;
    line-height: 1.5;
    margin-top: 4px;
    flex: 1;
}

.ks-product-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.ks-product-foot .kc-btn {
    padding: 0 10px;
}

/* ------------------------------------------------------------- help tiles */

.ks-help-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 14px;
}

.ks-help-tile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    color: inherit;
}

.ks-help-tile:hover {
    border-color: var(--kc-primary-border);
    box-shadow: var(--kc-shadow-sm);
    color: inherit;
}

.ks-help-tile:hover .ks-help-title {
    color: var(--kc-primary);
}

.ks-help-tile .kc-tile {
    flex: none;
}

.ks-help-text {
    min-width: 0;
}

.ks-help-title {
    display: block;
    font-weight: 700;
    font-size: 0.8438rem;
}

.ks-help-sub {
    color: var(--kc-muted);
    font-size: 0.75rem;
    line-height: 1.5;
}

.ks-help-count {
    display: block;
    color: var(--kc-primary);
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 2px;
}

/* --------------------------------------------------------------- home grid */

.ks-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    align-items: start;
    gap: 22px;
}

.ks-layout-wide {
    grid-template-columns: minmax(0, 1fr) 300px;
}

.ks-stack {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* mobile-first: normal static flow by default, sidebar only sticks once the
   two-column layout is active (≥1025px) and there's a taller column to scroll past */
@media (min-width: 1025px) {
    .ks-home-aside {
        position: sticky;
        top: calc(var(--kc-header-h) + 20px);
        align-self: start;
    }
}

.ks-home-stack {
    display: flex;
    flex-direction: column;
    gap: 36px;
}

.ks-home-stack .kc-card-body,
.ks-home-stack > .kc-card.kc-card-pad,
.ks-home-stack .ks-side-deal {
    padding: 28px;
}

.ks-home-stack .kc-card-head {
    padding: 22px 28px;
}

.ks-topics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.ks-topic {
    display: block;
    padding: 18px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
    color: inherit;
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.ks-topic:hover {
    border-color: var(--kc-primary-border);
    box-shadow: var(--kc-shadow-sm);
    color: inherit;
    transform: translateY(-1px);
}

.ks-topic-title {
    font-weight: 700;
    font-size: 0.9062rem;
    margin: 14px 0 4px;
}

.ks-topic-sub {
    color: var(--kc-muted);
    font-size: 0.8125rem;
    line-height: 1.5;
}

.ks-topic-count {
    color: var(--kc-primary);
    font-size: 0.7812rem;
    font-weight: 600;
    margin-top: 12px;
}

.ks-update-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-update-row:last-child {
    border-bottom: 0;
}

.ks-update-title {
    font-weight: 600;
}

.ks-update-sub {
    color: var(--kc-muted);
    font-size: 0.8125rem;
}

.ks-update-date {
    color: var(--kc-muted);
    font-size: 0.8125rem;
    white-space: nowrap;
}

.ks-article-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--kc-line-soft);
    color: inherit;
}

.ks-article-row:last-child {
    border-bottom: 0;
}

.ks-article-row:hover {
    background: var(--kc-line-soft);
    color: inherit;
}

/* ------------------------------------------------------------ side widgets */

.ks-side-title {
    font-size: 0.9688rem;
    font-weight: 700;
}

.ks-author-head {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ks-author-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--kc-line-soft);
    text-align: center;
}

.ks-author-stat-value {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--kc-ink);
}

.ks-author-stat-label {
    font-size: 0.75rem;
    color: var(--kc-muted);
    margin-top: 2px;
}

.ks-p-brand {
    text-align: center;
}

.ks-p-brand-img {
    display: block;
    width: auto;
    height: auto;
    max-width: 260px;
    max-height: 220px;
    margin: 0 auto 10px;
}

.ks-p-brand-tagline {
    color: var(--kc-muted);
    font-size: 0.8125rem;
    line-height: 1.5;
}

.ks-related-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-related-row:last-child {
    border-bottom: 0;
}

.ks-related-info {
    flex: 1 1 0%;
    min-width: 0;
}

.ks-related-title {
    display: block;
    font-weight: 600;
    color: var(--kc-ink);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ks-related-title:hover {
    color: var(--kc-primary);
}

.ks-related-end {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: none;
}

.ks-side-list {
    display: flex;
    flex-direction: column;
}

.ks-side-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    color: var(--kc-ink-2);
    font-size: 0.8438rem;
    font-weight: 500;
}

.ks-side-link:hover {
    color: var(--kc-primary);
}

.ks-side-link .kc-i {
    color: var(--kc-primary);
}

.ks-side-link-arrow {
    margin-left: auto;
    color: var(--kc-muted-2);
}

.ks-hours-row {
    padding: 9px 0;
}

.ks-hours-day {
    font-weight: 600;
    font-size: 0.8438rem;
}

.ks-hours-time {
    color: var(--kc-muted);
    font-size: 0.8438rem;
}

.ks-hours-note {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    padding-top: 12px;
    border-top: 1px solid var(--kc-line-soft);
    color: var(--kc-primary);
    font-size: 0.7812rem;
    font-weight: 500;
}

.ks-help-card {
    background: var(--kc-primary-softer);
    border: 1px solid var(--kc-primary-border);
}

.ks-policy-card {
    background: #FFFBEB;
    border-color: #FDE9A9;
}

/* --------------------------------------------------------- knowledge base */

.ks-kb-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    align-items: center;
    gap: 20px;
    padding: 26px;
    border-radius: var(--kc-radius);
    background: linear-gradient(120deg, #F3EFFE 0%, #EFF3FE 100%);
    border: 1px solid #E5E0FB;
}

.ks-kb-hero h2 {
    font-size: 1.625rem;
    letter-spacing: -.5px;
}

.ks-kb-hero .kc-input {
    height: 48px;
    margin-top: 16px;
    border-color: transparent;
    box-shadow: var(--kc-shadow-xs);
}

.ks-kb-hero-art svg {
    width: 100%;
    max-width: 250px;
    margin-left: auto;
    height: auto;
}

.ks-pop-search {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 14px;
    color: var(--kc-muted);
    font-size: 0.8125rem;
}

.ks-cat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.ks-cat {
    display: block;
    padding: 18px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
    color: inherit;
}

.ks-cat:hover {
    border-color: var(--kc-primary-border);
    box-shadow: var(--kc-shadow-sm);
    color: inherit;
}

.ks-cat-title {
    font-weight: 700;
    margin: 12px 0 4px;
}

.ks-cat-sub {
    color: var(--kc-muted);
    font-size: 0.8125rem;
    line-height: 1.5;
    min-height: 39px;
}

.ks-cat-count {
    color: var(--kc-muted);
    font-size: 0.7812rem;
    margin-top: 12px;
}

.ks-kb-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 13px 20px;
    border-bottom: 1px solid var(--kc-line-soft);
    color: inherit;
}

.ks-kb-row:last-child {
    border-bottom: 0;
}

.ks-kb-row:hover {
    background: var(--kc-line-soft);
    color: inherit;
}

.ks-kb-views {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--kc-muted);
    font-size: 0.7812rem;
    white-space: nowrap;
}

.ks-res-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    color: inherit;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-res-link:last-child {
    border-bottom: 0;
}

.ks-res-link:hover {
    color: inherit;
}

.ks-res-title {
    display: block;
    font-weight: 600;
    font-size: 0.8438rem;
}

.ks-res-sub {
    display: block;
    color: var(--kc-muted);
    font-size: 0.7812rem;
}

/* ---------------------------------------------------------- documentation */

.ks-doc-filters {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.ks-doc-filters-search {
    flex: 1;
    min-width: 200px;
}

.ks-doc-filters-select {
    width: 200px;
}

@media (max-width: 640px) {
    .ks-doc-filters-search {
        min-width: 0;
    }

    .ks-doc-filters-select {
        width: 100%;
    }
}

.ks-doc-cats {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
}

.ks-doc-cat {
    padding: 16px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
    color: inherit;
    display: block;
}

.ks-doc-cat:hover {
    border-color: var(--kc-primary-border);
    color: inherit;
}

.ks-doc-cat-active {
    border-color: var(--kc-primary);
    background: var(--kc-primary-softer);
}

.ks-doc-cat-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 0.875rem;
}

.ks-doc-cat-sub {
    color: var(--kc-muted);
    font-size: 0.7812rem;
    margin-top: 8px;
    line-height: 1.5;
}

.ks-doc-body {
    display: grid;
    grid-template-columns: 230px minmax(0, 1fr);
    gap: 20px;
}

.ks-doc-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ks-doc-nav-link {
    padding: 10px 14px;
    border-radius: 9px;
    color: var(--kc-ink-2);
    font-size: 0.8438rem;
    font-weight: 500;
}

.ks-doc-nav-link:hover {
    background: var(--kc-line-soft);
    color: var(--kc-ink);
}

.ks-doc-nav-active {
    background: var(--kc-primary-soft);
    color: var(--kc-primary);
    font-weight: 700;
}

.ks-doc-toc {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ks-doc-toc a {
    padding: 8px 12px;
    border-radius: 8px;
    color: var(--kc-muted);
    font-size: 0.8125rem;
}

.ks-doc-toc a:hover {
    background: var(--kc-line-soft);
    color: var(--kc-ink-2);
}

.ks-doc-toc .ks-doc-toc-active {
    background: var(--kc-primary-soft);
    color: var(--kc-primary);
    font-weight: 600;
}

.ks-doc-nav-mobile {
    display: none;
}

.ks-doc-prevnext {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 18px;
    margin-top: 18px;
    border-top: 1px solid var(--kc-line-soft);
}

/* -------------------------------------------------------------- changelog */

.ks-timeline {
    position: relative;
    padding-left: 58px;
}

.ks-timeline::before {
    content: "";
    position: absolute;
    left: 21px;
    top: 10px;
    bottom: 10px;
    width: 2px;
    background: var(--kc-line);
}

.ks-tl-item {
    position: relative;
    margin-bottom: 16px;
}

.ks-tl-dot {
    position: absolute;
    left: -58px;
    top: 8px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 4px solid var(--kc-bg);
}

.ks-tl-card {
    display: block;
    padding: 18px 20px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
    color: inherit;
    box-shadow: var(--kc-shadow-xs);
}

.ks-tl-card:hover {
    border-color: var(--kc-primary-border);
    color: inherit;
}

.ks-tl-version {
    font-size: 0.9375rem;
    font-weight: 700;
}

.ks-tl-title {
    font-weight: 700;
    font-size: 0.9062rem;
    margin-top: 6px;
}

.ks-tl-desc {
    color: var(--kc-muted);
    font-size: 0.8438rem;
    margin-top: 4px;
}

.ks-cat-count-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    font-size: 0.8438rem;
    color: var(--kc-ink-2);
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-cat-count-row:last-child {
    border-bottom: 0;
}

.ks-cat-count-active {
    color: var(--kc-primary);
    font-weight: 600;
}

/* --------------------------------------------------------------- tutorials */

.ks-video-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.ks-video {
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
    overflow: hidden;
    display: block;
    color: inherit;
}

.ks-video:hover {
    border-color: var(--kc-primary-border);
    box-shadow: var(--kc-shadow-sm);
    color: inherit;
}

.ks-video-thumb {
    position: relative;
    aspect-ratio: 16 / 9;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    padding: 18px;
    color: #FFF;
}

.ks-video-thumb-violet { background: linear-gradient(135deg, #4C1D95, #6D28D9); }
.ks-video-thumb-green { background: linear-gradient(135deg, #064E3B, #0F766E); }
.ks-video-thumb-blue { background: linear-gradient(135deg, #1E3A8A, #2563EB); }
.ks-video-thumb-pink { background: linear-gradient(135deg, #831843, #A21CAF); }
.ks-video-thumb-orange { background: linear-gradient(135deg, #7C2D12, #C2410C); }
.ks-video-thumb-teal { background: linear-gradient(135deg, #134E4A, #0D9488); }
.ks-video-thumb-indigo { background: linear-gradient(135deg, #312E81, #4F46E5); }
.ks-video-thumb-red { background: linear-gradient(135deg, #7F1D1D, #DC2626); }

.ks-video-thumb-title {
    font-size: 1.0625rem;
    font-weight: 800;
    line-height: 1.25;
    text-align: left;
    max-width: 74%;
    letter-spacing: -.3px;
}

.ks-video-play {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .92);
    color: #1F2937;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    cursor: pointer;
}

.ks-video-play:hover {
    background: #FFF;
}

/* real YouTube embed: a clickable thumbnail that swaps itself for an iframe */
.ks-video-embed {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #0F172A;
    overflow: hidden;
}

.ks-video-embed img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ks-video-embed iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.ks-video-time {
    position: absolute;
    right: 8px;
    bottom: 8px;
    padding: 2px 7px;
    border-radius: 6px;
    background: rgba(15, 23, 42, .78);
    color: #FFF;
    font-size: 0.7188rem;
    font-weight: 600;
}

.ks-video-body {
    padding: 14px 16px 16px;
}

.ks-video-index {
    color: var(--kc-muted-2);
    font-size: 0.75rem;
    font-weight: 700;
}

.ks-video-title {
    font-weight: 700;
    font-size: 0.875rem;
    margin-bottom: 4px;
}

.ks-video-sub {
    color: var(--kc-muted);
    font-size: 0.7812rem;
    line-height: 1.5;
}

.ks-video-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 12px;
    color: var(--kc-muted);
    font-size: 0.75rem;
}

.ks-video-mini {
    width: 62px;
    height: 40px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #FFF;
    flex: none;
}

.ks-tut-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 20px;
    border-bottom: 1px solid var(--kc-line-soft);
    color: inherit;
}

.ks-tut-row:last-child {
    border-bottom: 0;
}

.ks-tut-row:hover {
    background: var(--kc-line-soft);
    color: inherit;
}

.ks-star {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #F59E0B;
    font-weight: 600;
    font-size: 0.7812rem;
}

/* ---------------------------------------------------------------- contact */

.ks-contact-grid {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr) 300px;
    gap: 20px;
    align-items: start;
}

.ks-contact-item {
    display: flex;
    gap: 14px;
    padding: 18px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
}

.ks-contact-title {
    font-weight: 700;
    margin-bottom: 3px;
}

.ks-contact-text {
    color: var(--kc-muted);
    font-size: 0.8438rem;
    line-height: 1.6;
}

.ks-contact-art svg {
    width: 100%;
    max-width: 300px;
    height: auto;
    margin: 0 auto;
}

.ks-contact-art img {
    display: block;
    width: auto;
    height: auto;
    max-width: 300px;
    max-height: 320px;
    margin: 0 auto;
}

.ks-faq-band {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 22px 24px;
    border-radius: var(--kc-radius);
    background: #F3F1FD;
    border: 1px solid #E6E2FA;
}

.ks-faq-item {
    border-bottom: 1px solid var(--kc-line-soft);
    padding: 16px 0;
}

.ks-faq-item:last-child {
    border-bottom: 0;
}

.ks-faq-q {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-weight: 600;
}

.ks-faq-a {
    color: var(--kc-muted);
    font-size: 0.8438rem;
    margin-top: 6px;
    padding-left: 28px;
}

/* ---------------------------------------------------------------- article */

.ks-article-head {
    padding: 26px;
}

.ks-article-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    color: var(--kc-muted);
    font-size: 0.8125rem;
    margin-top: 12px;
}

.ks-helpful {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* ----------------------------------------------------------------- footer */

.ks-footer {
    background: var(--kc-surface);
    border-top: 1px solid var(--kc-line);
    padding: 34px 0 26px;
    margin-top: auto;
}

.ks-footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, .85fr)) minmax(0, 1.25fr);
    gap: 26px;
}

.ks-footer-about {
    color: var(--kc-muted);
    font-size: 0.8125rem;
    margin-top: 12px;
    max-width: 260px;
    line-height: 1.6;
}

.ks-footer-title {
    font-size: 0.8438rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.ks-footer-link {
    display: block;
    padding: 5px 0;
    color: var(--kc-muted);
    font-size: 0.8125rem;
}

.ks-footer-link:hover {
    color: var(--kc-primary);
}

.ks-social {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.ks-social a {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--kc-line-soft);
    color: var(--kc-slate);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.ks-social a:hover {
    background: var(--kc-primary-soft);
    color: var(--kc-primary);
}

.ks-footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 26px;
    padding-top: 18px;
    border-top: 1px solid var(--kc-line-soft);
    color: var(--kc-muted);
    font-size: 0.7812rem;
}

.ks-footer-legal {
    display: flex;
    align-items: center;
    gap: 22px;
    flex-wrap: wrap;
}

.ks-footer-legal a {
    color: var(--kc-muted);
}

.ks-footer-legal a:hover {
    color: var(--kc-primary);
}

/* -------------------------------------------------------- mobile tab bar */

.ks-tabbar {
    display: none;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 45;
    background: var(--kc-surface);
    border-top: 1px solid var(--kc-line);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
}

.ks-tabbar-inner {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.ks-tabbar-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 6px 2px;
    color: var(--kc-muted);
    font-size: 0.6562rem;
    font-weight: 600;
}

.ks-tabbar-active {
    color: var(--kc-primary);
}

.ks-tabbar-text {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    text-align: center;
}

/* ------------------------------------------------------------- responsive */

@media (max-width: 1180px) {
    .ks-help-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .ks-nav-link {
        padding: 10px 10px;
        font-size: 0.8438rem;
    }

    .ks-doc-cats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .ks-video-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ks-cat-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 1024px) {
    .ks-layout,
    .ks-layout-wide {
        grid-template-columns: minmax(0, 1fr);
    }

    .ks-contact-grid {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }

    .ks-contact-art {
        display: none;
    }

    .ks-topics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ks-help-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .ks-nav {
        display: none;
    }

    .ks-burger {
        display: inline-flex;
    }

    .ks-hero-art {
        display: none;
    }

    .ks-hero-inner {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 768px) {
    .ks-shell {
        padding: 0 16px;
    }

    .ks-main {
        padding: 18px 0 30px;
    }

    .ks-page {
        padding-bottom: 66px;
    }

    .ks-tabbar {
        display: block;
    }

    .ks-header-inner {
        height: 60px;
        gap: 10px;
    }

    .ks-brand {
        font-size: 1.0625rem;
    }

    .ks-brand-badge {
        display: none;
    }

    .ks-brand-mark {
        width: 36px;
        height: 36px;
    }

    .ks-user-text {
        display: none;
    }

    /* .ks-user stays visible and tappable on mobile too (name/chevron hidden above,
       just the avatar) so tapping it opens the same account dropdown as desktop. */

    .ks-login-mobile {
        display: inline-flex;
    }

    .ks-brand {
        margin: 0 auto;
    }

    .ks-bell-wrap {
        display: block;
    }

    .ks-tickets-btn {
        display: none;
    }

    .ks-header-actions {
        gap: 6px;
    }

    .ks-hero-inner {
        padding: 30px 0 34px;
    }

    .ks-hero h1 {
        font-size: 1.6875rem;
    }

    .ks-hero-sub {
        font-size: 0.875rem;
    }

    .ks-hero-search {
        flex-direction: column;
        align-items: stretch;
        margin-top: 18px;
    }

    .ks-hero-search .kc-btn {
        width: 100%;
    }

    .ks-statband-inner {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ks-statband-item {
        padding: 14px 12px;
        gap: 12px;
    }

    .ks-statband-item:nth-child(odd) {
        border-left: 0;
    }

    .ks-statband-item:nth-child(n + 3) {
        border-top: 1px solid var(--kc-line-soft);
    }

    .ks-statband-icon {
        width: 38px;
        height: 38px;
    }

    .ks-statband-value {
        font-size: 1.125rem;
    }

    .ks-help-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ks-carousel {
        grid-auto-columns: minmax(200px, 82%);
    }

    .ks-product-foot {
        justify-content: flex-start;
    }

    .ks-hero-dots {
        display: none;
    }

    .ks-topics,
    .ks-cat-grid,
    .ks-doc-cats,
    .ks-video-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .ks-topic,
    .ks-cat {
        padding: 14px;
    }

    .ks-cat-title {
        font-size: 0.8438rem;
        margin-top: 10px;
    }

    .ks-cat-sub,
    .ks-topic-sub {
        display: none;
    }

    .ks-kb-hero {
        grid-template-columns: minmax(0, 1fr);
        padding: 18px;
    }

    .ks-kb-hero h2 {
        font-size: 1.1875rem;
    }

    .ks-kb-hero-art {
        display: none;
    }

    .ks-doc-body {
        grid-template-columns: minmax(0, 1fr);
    }

    .ks-doc-nav-desktop {
        display: none;
    }

    .ks-doc-nav-mobile {
        display: block;
    }

    .ks-contact-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .ks-timeline {
        padding-left: 44px;
    }

    .ks-timeline::before {
        left: 17px;
    }

    .ks-tl-dot {
        left: -44px;
        width: 36px;
        height: 36px;
    }

    .ks-footer {
        padding: 26px 0 20px;
    }

    .ks-footer-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 28px;
    }

    .ks-footer-about {
        max-width: none;
    }

    .ks-footer-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .ks-update-row,
    .ks-article-row,
    .ks-kb-row,
    .ks-tut-row {
        padding: 12px 16px;
    }

    .ks-update-date {
        font-size: 0.75rem;
    }
}

@media (max-width: 460px) {
    .ks-topics,
    .ks-cat-grid,
    .ks-doc-cats,
    .ks-video-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ks-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* documentation — recently updated strip */
.ks-doc-recent {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

@media (max-width: 900px) {
    .ks-doc-recent {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 520px) {
    .ks-doc-recent {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* ------------------------------------------------------------ system status */

.ks-status-ok {
    border-color: #BBF7D0;
    background: #F6FEF9;
}

.ks-status-bad {
    border-color: #FECACA;
    background: #FFFAFA;
}

.ks-status-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-status-row:last-child {
    border-bottom: 0;
}

@media (max-width: 768px) {
    .ks-status-row {
        padding: 12px 16px;
    }
}

/* product card image (falls back to the icon tile) */
.ks-product-image {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    overflow: hidden;
    flex: none;
}

.ks-product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ------------------------------------------------------------ storefront */

.ks-shop-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.ks-shop-grid .kc-empty {
    grid-column: 1 / -1;
}

.ks-shop-card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
    overflow: hidden;
}

.ks-shop-card:hover {
    border-color: var(--kc-primary-border);
    box-shadow: var(--kc-shadow-sm);
}

.ks-shop-media {
    position: relative;
    aspect-ratio: 16 / 10;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFF;
    overflow: hidden;
}

.ks-shop-media::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, .16) 1.5px, transparent 1.5px);
    background-size: 18px 18px;
}

.ks-shop-media::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, .22), transparent 72%);
    transform: translate(-50%, -50%);
}

.ks-shop-media img {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ks-shop-media-badge {
    position: relative;
    z-index: 1;
    width: 64px;
    height: 64px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .3);
    backdrop-filter: blur(2px);
}

.ks-shop-flag {
    position: absolute;
    z-index: 2;
    bottom: 10px;
    left: 10px;
    padding: 3px 10px;
    border-radius: var(--kc-radius-pill);
    background: var(--kc-surface);
    color: var(--kc-primary);
    font-size: 0.7188rem;
    font-weight: 700;
    box-shadow: var(--kc-shadow-sm);
}

.ks-shop-body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.ks-shop-title {
    display: block;
    font-weight: 700;
    font-size: 0.9375rem;
    margin: 10px 0 4px;
    color: var(--kc-ink);
}

.ks-shop-sub {
    color: var(--kc-muted);
    font-size: 0.8125rem;
    line-height: 1.5;
    flex: 1;
}

.ks-shop-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
}

.ks-shop-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 14px;
}

.ks-price {
    font-size: 1.0625rem;
    font-weight: 700;
}

.ks-price-was {
    color: var(--kc-muted-2);
    font-size: 0.8125rem;
    font-weight: 500;
    text-decoration: line-through;
    margin-left: 6px;
}

.ks-buy-price {
    font-size: 1.875rem;
    font-weight: 800;
    letter-spacing: -.6px;
}

/* gallery */
.ks-gallery-main {
    aspect-ratio: 16 / 9;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFF;
}

.ks-gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ks-gallery-thumbs {
    display: flex;
    gap: 10px;
    padding: 12px;
    overflow-x: auto;
    scrollbar-width: none;
}

.ks-gallery-thumbs::-webkit-scrollbar {
    display: none;
}

.ks-gallery-thumb {
    width: 92px;
    height: 62px;
    flex: none;
    padding: 0;
    border: 1px solid var(--kc-line);
    border-radius: 8px;
    overflow: hidden;
    background: var(--kc-surface);
}

.ks-gallery-thumb:hover {
    border-color: var(--kc-primary);
}

.ks-gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 1024px) {
    .ks-shop-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .ks-shop-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

.ks-spec-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 0;
    border-bottom: 1px solid var(--kc-line-soft);
    font-size: 0.8438rem;
}

.ks-spec-row:last-child {
    border-bottom: 0;
}

/* ------------------------------------------------------------------ product reviews */

.ks-rating-summary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    color: inherit;
}

.ks-review-form {
    padding-bottom: 20px;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-review-row {
    display: flex;
    gap: 12px;
    padding: 16px 0;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-review-row:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.kc-star-input {
    display: inline-flex;
    flex-direction: row-reverse;
    gap: 4px;
}

.kc-star-input input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.kc-star-input label {
    cursor: pointer;
    color: var(--kc-line);
}

.kc-star-input label:hover,
.kc-star-input label:hover ~ label,
.kc-star-input input:checked ~ label {
    color: var(--kc-yellow);
}

/* ------------------------------------------------------------------ product comments */

.ks-comment-thread {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.ks-comment-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.ks-comment-filter-search {
    flex: 1 1 220px;
}

@media (max-width: 560px) {
    .ks-comment-filter-search {
        flex-basis: 100%;
    }
}

.ka-msg-reply {
    margin-top: 12px;
    margin-left: 32px;
}

@media (max-width: 900px) {
    .ka-msg-reply {
        margin-left: 16px;
    }
}

@media (max-width: 900px) {
    .ks-layout-product {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 20px;
    }

    .ks-layout-product > .ks-stack {
        display: contents;
    }

    .ks-layout-product > .ks-stack > * {
        order: 4;
    }

    .ks-layout-product > .ks-stack > .ks-p-gallery {
        order: 1;
    }

    .ks-layout-product > .ks-stack > .ks-p-buy {
        order: 2;
    }

    .ks-layout-product > .ks-stack > .ks-p-info {
        order: 3;
    }
}

/* ------------------------------------------------------- custom solution CTA */

.ks-custom-cta {
    position: relative;
    overflow: hidden;
    border-radius: var(--kc-radius-lg, var(--kc-radius));
    background: linear-gradient(135deg, #2A1B6B 0%, #4A18D0 55%, #5B21F0 100%);
    padding: 48px 40px;
}

.ks-custom-cta-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
    align-items: center;
    gap: 30px;
}

.ks-custom-cta-title {
    color: #FFFFFF;
    font-size: 1.75rem;
    letter-spacing: -.5px;
    margin: 12px 0 10px;
}

.ks-custom-cta-sub {
    color: #DDD6FE;
    font-size: 0.9375rem;
    line-height: 1.6;
    max-width: 480px;
}

.ks-custom-cta-points {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 18px 0 0;
    padding: 0;
    list-style: none;
}

.ks-custom-cta-points li {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #EDE9FE;
    font-size: 0.875rem;
    font-weight: 600;
}

.ks-custom-cta-points .kc-i {
    color: #A78BFA;
    flex: none;
}

.ks-custom-cta-art {
    display: flex;
    justify-content: center;
}

.ks-custom-cta-art svg {
    width: 100%;
    max-width: 260px;
    height: auto;
    filter: drop-shadow(0 12px 24px rgba(0, 0, 0, .25));
}

.ks-custom-cta-art img {
    width: auto;
    height: auto;
    max-width: 340px;
    max-height: 300px;
    filter: drop-shadow(0 12px 24px rgba(0, 0, 0, .25));
}

.ks-custom-cta-dots {
    position: absolute;
    width: 140px;
    height: 100px;
    opacity: .35;
    background-image: radial-gradient(rgba(255, 255, 255, .5) 1.6px, transparent 1.6px);
    background-size: 14px 14px;
    z-index: 0;
}

.ks-custom-cta-dots-left {
    left: -20px;
    top: -20px;
}

.ks-custom-cta-dots-right {
    right: -20px;
    bottom: -20px;
}

@media (max-width: 768px) {
    .ks-custom-cta {
        padding: 32px 24px;
    }

    .ks-custom-cta-inner {
        grid-template-columns: minmax(0, 1fr);
        text-align: center;
    }

    .ks-custom-cta-sub {
        max-width: none;
    }

    .ks-custom-cta-points {
        align-items: center;
    }

    .ks-custom-cta-art {
        order: -1;
    }

    .ks-custom-cta-art svg {
        max-width: 200px;
    }

    .ks-custom-cta-art img {
        max-width: 260px;
        max-height: 220px;
    }
}

/* -------------------------------------------------------------- testimonials */

.ks-testimonial-card {
    max-width: 320px;
}

.ks-testimonial-top {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-cta-testimonial {
    position: relative;
    display: flex;
    flex-direction: column;
}

.ks-cta-quote-text {
    font-size: 0.9062rem;
    line-height: 1.6;
    margin: 10px 0 14px;
}

.ks-cta-carousel-nav {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
}

.ks-cta-dots {
    display: flex;
    align-items: center;
    gap: 6px;
}

.ks-cta-dot {
    width: 7px;
    height: 7px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: var(--kc-line);
}

.ks-cta-dot-active {
    width: 18px;
    border-radius: 4px;
    background: var(--kc-primary);
}


/* ------------------------------------------------------------------ home sidebar */

.ks-side-deal {
    padding: 22px;
    border-radius: var(--kc-radius);
    background: linear-gradient(135deg, var(--kc-primary), #4C1D95);
    color: #FFF;
}

.ks-side-deal-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .18);
    margin-bottom: 12px;
}

.ks-side-deal-title {
    color: #FFF;
    font-size: 1.0625rem;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 6px;
}

.ks-side-deal-sub {
    font-size: 0.8125rem;
    opacity: .85;
    margin-bottom: 12px;
}

.ks-side-deal-price {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 14px;
}

.ks-side-deal-was {
    font-size: 0.8125rem;
    font-weight: 500;
    text-decoration: line-through;
    opacity: .65;
    margin-left: 6px;
}

.ks-side-deal-btn {
    background: #FFF;
    color: var(--kc-primary);
    border-color: transparent;
}

.ks-side-deal-btn:hover {
    background: #F5F3FF;
}

.ks-side-feature {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid var(--kc-line-soft);
}

.ks-side-feature-last {
    padding-bottom: 0;
    margin-bottom: 0;
    border-bottom: none;
}

.ks-side-feature-title {
    font-weight: 600;
    font-size: 0.8438rem;
}

/* ------------------------------------------------------------------ checkout */

.ks-checkout {
    max-width: 480px;
    margin: 0 auto;
    padding: 40px 20px;
}

.ks-checkout-wide {
    max-width: 560px;
}

.ks-checkout-summary {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border: 1px solid var(--kc-line-soft);
    border-radius: 12px;
}

.ks-checkout-price {
    font-size: 1.125rem;
    font-weight: 700;
}

/* ------------------------------------------------------------------ cart */

.ks-cart {
    padding-top: 32px;
    padding-bottom: 60px;
}

.ks-cart-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 20px;
    align-items: start;
}

.ks-cart-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ks-cart-item {
    display: flex;
    align-items: center;
    gap: 14px;
}

.ks-cart-item-price {
    font-weight: 700;
    white-space: nowrap;
    text-align: right;
}

.ks-cart-summary {
    position: sticky;
    top: 84px;
}

.ks-cart-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 0.875rem;
}

.ks-cart-summary-total {
    border-top: 1px solid var(--kc-line-soft);
    margin-top: 4px;
    padding-top: 12px;
    font-weight: 700;
    font-size: 1rem;
}

@media (max-width: 860px) {
    .ks-cart-layout {
        grid-template-columns: 1fr;
    }

    .ks-cart-summary {
        position: static;
    }
}

/* ============================================ Maintenance page */
.ks-maintenance {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: var(--mt-bg, var(--kc-bg));
}

.ks-maintenance-card {
    max-width: 480px;
    width: 100%;
    text-align: center;
    background: var(--mt-bg, var(--kc-surface));
    color: var(--mt-text, var(--kc-ink));
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius-lg);
    padding: 40px 28px;
    box-shadow: var(--kc-shadow-sm);
}

.ks-maintenance-card svg {
    max-width: 220px;
    margin: 0 auto 20px;
    height: auto;
}

.ks-maintenance-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 8px;
}

.ks-maintenance-message {
    font-size: 0.9062rem;
    line-height: 1.6;
    opacity: .75;
}

/* ============================================ Cookie consent banner */
.ks-cookie-banner {
    position: fixed;
    z-index: 70;
    max-width: 480px;
    margin: 16px;
}

.ks-cookie-banner[data-position="bottom"] { left: 0; right: 0; bottom: 0; margin-left: auto; margin-right: auto; }
.ks-cookie-banner[data-position="top"] { left: 0; right: 0; top: 0; margin-left: auto; margin-right: auto; }
.ks-cookie-banner[data-position="bottom-left"] { left: 0; bottom: 0; }
.ks-cookie-banner[data-position="bottom-right"] { right: 0; bottom: 0; }

.ks-cookie-banner-inner {
    background: var(--kc-surface);
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius-lg);
    box-shadow: var(--kc-shadow-md);
    padding: 20px;
}

.ks-cookie-banner-text {
    font-size: 0.8438rem;
    line-height: 1.6;
    color: var(--kc-muted);
    margin: 0 0 14px;
}

@media (max-width: 640px) {
    .ks-cookie-banner {
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        top: auto !important;
        margin: 12px;
        max-width: none;
    }
}

/* ============================================ Invoice */
.ks-invoice {
    max-width: 720px;
    margin: 40px auto;
    padding: 0 20px;
}

.ks-invoice-card {
    background: var(--kc-surface);
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius-lg);
    padding: 40px;
}

.ks-invoice-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--kc-line);
    margin-bottom: 24px;
}

.ks-invoice-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.125rem;
}

.ks-invoice-meta {
    text-align: right;
}

.ks-invoice-title {
    font-size: 1.375rem;
    font-weight: 700;
    margin: 0 0 4px;
}

.ks-invoice-parties {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 28px;
}

.ks-invoice-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: var(--kc-muted);
    margin-bottom: 6px;
}

.ks-invoice-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 24px;
}

.ks-invoice-table th {
    text-align: left;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: var(--kc-muted);
    padding: 10px 0;
    border-bottom: 1px solid var(--kc-line);
}

.ks-invoice-table td {
    padding: 14px 0;
    border-bottom: 1px solid var(--kc-line);
}

.ks-invoice-total {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 14px;
    font-size: 1.125rem;
    font-weight: 700;
}

.ks-invoice-foot {
    text-align: center;
    margin-top: 32px;
    color: var(--kc-muted);
    font-size: 0.8125rem;
}

@media print {
    .ks-invoice-noprint { display: none; }
    .ks-invoice { margin: 0; max-width: none; }
    .ks-invoice-card { border: none; padding: 0; }
}

/* ------------------------------------------------------------ site search */

.ks-search-group {
    margin-bottom: 20px;
}

.ks-search-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    border-bottom: 1px solid var(--kc-line-soft);
    color: inherit;
}

.ks-search-item:last-child {
    border-bottom: 0;
}

.ks-search-item:hover {
    background: var(--kc-line-soft);
    color: inherit;
}

.ks-search-title {
    display: block;
    font-weight: 600;
    font-size: 0.875rem;
}

.ks-search-sub {
    display: block;
    color: var(--kc-muted);
    font-size: 0.7812rem;
    margin-top: 2px;
}

@media (max-width: 560px) {
    .ks-search-item { padding: 12px 4px; }
}

/* ==========================================================================
   Live chat widget
   ========================================================================== */

.kc-chat {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 70;
}

/* Google injects the reCAPTCHA badge with its own inline bottom offset, which sits directly
   under the chat launcher (56px tall, 20px from the bottom) and gets visually hidden behind it. */
.grecaptcha-badge {
    bottom: 90px !important;
}

/* below 768px the site tabbar occupies the bottom of the screen, so the chat
   launcher (and the reCAPTCHA badge beneath it) must sit above it, not under it */
@media (max-width: 768px) {
    .kc-chat {
        bottom: 86px;
    }

    .grecaptcha-badge {
        bottom: 156px !important;
    }
}

.kc-chat-bubble {
    position: relative;
    width: auto;
    height: 56px;
    padding: 0 20px 0 17px;
    border-radius: var(--kc-radius-pill);
    background: var(--kc-primary);
    color: #FFF;
    border: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: var(--kc-shadow-lg);
    cursor: pointer;
}

.kc-chat-bubble-label {
    font-size: 0.9375rem;
    font-weight: 700;
    white-space: nowrap;
}

.kc-chat-panel[hidden] {
    display: none;
}

.kc-chat-badge[hidden] {
    display: none;
}

.kc-chat-bubble:hover {
    background: var(--kc-primary-dark);
}

.kc-chat-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: var(--kc-radius-pill);
    background: var(--kc-red);
    color: #FFF;
    font-size: 0.6875rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--kc-surface);
}

.kc-chat-panel {
    position: fixed;
    right: 16px;
    bottom: 90px;
    left: 16px;
    width: auto;
    /* a fixed height, not max-height — with only a greeting message and the guest
       fields inside, content never reached the old ceiling, so raising it alone
       was invisible; the thread area's flex:1 now grows to fill the real space */
    height: min(78vh, 640px);
    background: var(--kc-surface);
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius-lg);
    box-shadow: var(--kc-shadow-lg);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.kc-chat-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 18px;
    background: var(--kc-primary);
    color: #FFF;
    flex: none;
}

.kc-chat-head-title {
    font-weight: 700;
    font-size: 0.9375rem;
}

.kc-chat-head-sub {
    font-size: 0.75rem;
    opacity: .85;
    margin-top: 2px;
}

.kc-chat-close {
    border: 0;
    background: rgba(255, 255, 255, .16);
    color: #FFF;
    width: 28px;
    height: 28px;
    border-radius: var(--kc-radius-pill);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
}

.kc-chat-thread {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.kc-chat-empty {
    color: var(--kc-muted);
    font-size: 0.8125rem;
    background: var(--kc-line-soft);
    border-radius: var(--kc-radius);
    padding: 12px 14px;
}

.kc-chat-msg {
    max-width: 82%;
    padding: 9px 12px;
    border-radius: var(--kc-radius);
    font-size: 0.8438rem;
    line-height: 1.4;
}

.kc-chat-msg-body {
    white-space: pre-wrap;
    word-break: break-word;
}

.kc-chat-msg-time {
    display: block;
    font-size: 0.6875rem;
    margin-top: 4px;
    opacity: .7;
}

.kc-chat-msg-visitor {
    align-self: flex-end;
    background: var(--kc-primary);
    color: #FFF;
    border-bottom-right-radius: 4px;
}

.kc-chat-msg-staff {
    align-self: flex-start;
    background: var(--kc-line-soft);
    color: var(--kc-ink);
    border-bottom-left-radius: 4px;
}

.kc-chat-msg-attachments {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.kc-chat-msg-attach {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
}

.kc-chat-msg-attach-image {
    width: 84px;
    height: 84px;
    border-radius: var(--kc-radius-sm);
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, .08);
}

.kc-chat-msg-attach-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.kc-chat-msg-attach-file {
    padding: 6px 10px;
    border-radius: var(--kc-radius-sm);
    background: var(--kc-surface);
    color: var(--kc-ink);
    font-size: 0.75rem;
    font-weight: 600;
}

.kc-chat-msg-attach-name {
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.kc-chat-guest-fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 8px;
    /* forces this onto its own row inside .kc-chat-form's wrapped flex layout,
       instead of being squeezed into the same row as the message box and send
       button — without this the whole row silently overflows past the panel */
    width: 100%;
}

.kc-chat-form {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 14px;
    border-top: 1px solid var(--kc-line);
    flex: none;
}

.kc-chat-input {
    flex: 1;
    min-width: 0;
    resize: none;
    max-height: 90px;
}

.kc-chat-send {
    width: 38px;
    height: 38px;
    border-radius: var(--kc-radius-pill);
    background: var(--kc-primary);
    color: #FFF;
    border: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
}

.kc-chat-send:disabled {
    opacity: .6;
    cursor: default;
}

@media (min-width: 640px) {
    .kc-chat-panel {
        left: auto;
        width: 360px;
        bottom: 88px;
        right: 0;
    }
}

/* ==========================================================================
   Checkout currency toggle
   ========================================================================== */

.ks-currency-toggle {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.ks-currency-toggle-btn {
    flex: 1;
    min-width: 140px;
    padding: 10px 14px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius);
    background: var(--kc-surface);
    color: var(--kc-ink);
    font-size: 0.8438rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
}

.ks-currency-toggle-btn:hover {
    border-color: var(--kc-primary-border);
}

.ks-currency-toggle-active {
    border-color: var(--kc-primary);
    background: var(--kc-primary-softer);
    color: var(--kc-primary);
}

/* -------------------------------------------------------- category pill row */

.ks-cat-pills {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.ks-cat-pill {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: none;
    min-width: 168px;
    padding: 14px 16px;
    border: 1px solid var(--kc-line);
    border-radius: var(--kc-radius-lg, var(--kc-radius));
    background: var(--kc-surface);
    color: inherit;
}

.ks-cat-pill:hover {
    border-color: var(--kc-primary-border);
    box-shadow: var(--kc-shadow-sm);
    color: inherit;
}

.ks-cat-pill:hover .ks-help-title {
    color: var(--kc-primary);
}

.ks-cat-pill .kc-tile {
    flex: none;
}

@media (min-width: 900px) {
    .ks-cat-pills {
        overflow-x: visible;
        flex-wrap: wrap;
    }

    .ks-cat-pill {
        flex: 1;
        min-width: 0;
    }
}

/* --------------------------------------------------------------- support cta */

.ks-support-cta-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.ks-support-cta-art svg {
    width: 100%;
    max-width: 160px;
    height: auto;
}

.ks-support-cta-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-top: 26px;
    padding-top: 26px;
    border-top: 1px solid var(--kc-line-soft);
}

.ks-support-cta-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

@media (max-width: 900px) {
    .ks-support-cta-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .ks-support-cta-top {
        flex-direction: column;
        text-align: center;
    }

    .ks-support-cta-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* ------------------------------------------------------------- wishlist heart */

.ks-shop-media-wrap {
    position: relative;
}

.ks-shop-wishlist {
    position: absolute;
    z-index: 2;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .92);
    color: var(--kc-muted);
    cursor: pointer;
    transition: transform .15s ease;
}

.ks-shop-wishlist:hover {
    color: var(--kc-red);
    transform: scale(1.08);
}

.ks-shop-wishlist.is-active {
    color: var(--kc-red);
}

.ks-shop-wishlist.is-active .kc-i {
    fill: currentColor;
}

.ks-shop-sales {
    margin-left: auto;
}
