.sample-page {
    background: #fff;
    color: var(--hc-text);
    overflow-x: hidden;
}

body.hicoding-sample-page {
    background: #101213;
}

.sample-shell {
    max-width: 1180px;
}

.sample-hero {
    background: #101213;
    color: #fff;
}

.sample-page .sample-hero {
    padding-top: 80px;
}

.sample-hero h1 {
    color: #fff;
}

.sample-hero .page-hero__desc {
    color: rgba(255, 255, 255, 0.76);
}

.sample-workspace {
    padding: 58px 0 112px;
}

.sample-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 620px;
    margin: 0 0 42px;
    padding: 6px;
    border: 1px solid #dedede;
    border-radius: 8px;
    background: #f6f7f7;
}

.sample-tabs button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 48px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #5c6065;
    font-weight: 900;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
    white-space: nowrap;
}

.sample-tabs button[aria-selected="true"] {
    background: #111;
    color: #fff;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}

.sample-tabs button:focus-visible,
.sample-card-button:focus-visible,
.sample-site-card__actions a:focus-visible,
.sample-site-card__actions button:focus-visible,
.sample-category-filter button:focus-visible,
.sample-modal__close:focus-visible {
    outline: 3px solid rgba(91, 191, 99, 0.45);
    outline-offset: 2px;
}

.sample-panel[hidden],
.sample-modal[hidden] {
    display: none;
}

.sample-section-head {
    display: grid;
    gap: 10px;
    margin-bottom: 28px;
}

.sample-section-head--with-tools {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
    align-items: end;
    gap: 24px;
}

.sample-section-head h2 {
    margin: 0;
    color: #0f1112;
    font-size: clamp(1.3rem, 2vw, 1.8rem);
    line-height: 1.2;
    letter-spacing: -0.02em;
    font-weight: 900;
}

.sample-section-head p {
    max-width: 720px;
    margin: 0;
    color: #5e646b;
    line-height: 1.72;
}

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

/* Split-pane experience layout */
.sample-experience-hint {
    margin: 0 0 20px;
    color: #5e646b;
    font-size: 0.9rem;
}

.sample-experience-layout {
    display: grid;
    grid-template-columns: 256px minmax(0, 1fr);
    border: 1px solid #e4e6e8;
    border-radius: 12px;
    overflow: hidden;
    min-height: 540px;
    background: #fff;
    box-shadow: 0 10px 32px rgba(11, 16, 20, 0.06);
}

.sample-feature-nav {
    border-right: 1px solid #e4e6e8;
    background: #f8f9fa;
    overflow-y: auto;
}

.sample-feature-nav-item {
    display: flex;
    align-items: center;
    gap: 11px;
    width: 100%;
    padding: 13px 14px;
    border: 0;
    border-bottom: 1px solid #eaecee;
    border-right: 3px solid transparent;
    background: transparent;
    text-align: left;
    cursor: pointer;
    transition: background 0.14s, border-color 0.14s;
}

.sample-feature-nav-item:hover {
    background: #eff0f3;
}

.sample-feature-nav-item.is-active {
    background: #fff;
    border-right-color: var(--hc-green, #5bbf63);
}

.sample-feature-nav-item__icon {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(91, 191, 99, 0.12);
    color: #2d7d37;
}

.sample-feature-nav-item__icon svg {
    width: 17px;
    height: 17px;
    stroke: currentColor;
}

.sample-feature-nav-item.is-active .sample-feature-nav-item__icon {
    background: rgba(91, 191, 99, 0.22);
    color: #1a5c1f;
}

.sample-feature-nav-item__body {
    flex: 1 1 0;
    min-width: 0;
}

.sample-feature-nav-item__body strong {
    display: block;
    color: #111;
    font-size: 0.875rem;
    font-weight: 900;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sample-feature-nav-item__body span {
    display: block;
    margin-top: 2px;
    color: #6b7278;
    font-size: 0.76rem;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sample-feature-nav-item.is-active .sample-feature-nav-item__body strong {
    color: #1a5c1f;
}

.sample-feature-nav-item__arrow {
    flex: 0 0 auto;
    color: #bcc2c8;
    font-size: 1.05rem;
    font-weight: 900;
    line-height: 1;
}

.sample-feature-nav-item.is-active .sample-feature-nav-item__arrow {
    color: var(--hc-green, #5bbf63);
}

.sample-demo-stage {
    padding: 24px;
    overflow-y: auto;
}

.sample-demo-stage__title {
    margin: 0 0 16px;
    font-size: 1.05rem;
    font-weight: 900;
    color: #111;
    letter-spacing: -0.01em;
}

/* Chat demo */
.sample-chat {
    display: flex;
    flex-direction: column;
    height: 460px;
    border: 1px solid #e4e6e8;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}

.sample-chat__header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 16px;
    background: #1a1c1e;
    color: #fff;
    flex-shrink: 0;
}

.sample-chat__header strong {
    font-size: 0.88rem;
    font-weight: 900;
}

.sample-chat__status {
    font-size: 0.76rem;
    color: rgba(255, 255, 255, 0.55);
}

.sample-chat__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--hc-green, #5bbf63);
    flex-shrink: 0;
}

.sample-chat__messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #f5f6f8;
}

.sample-chat__bubble {
    display: flex;
    gap: 8px;
    max-width: 82%;
}

.sample-chat__bubble--user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.sample-chat__bubble p {
    margin: 0;
    padding: 10px 13px;
    font-size: 0.875rem;
    line-height: 1.55;
}

.sample-chat__bubble--bot p {
    background: #fff;
    border: 1px solid #e4e6e8;
    border-radius: 4px 16px 16px 16px;
    color: #111;
}

.sample-chat__bubble--user p {
    background: var(--hc-green, #5bbf63);
    border-radius: 16px 16px 4px 16px;
    color: #fff;
    font-weight: 600;
}

.sample-chat__avatar {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #1a1c1e;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 900;
    margin-top: 2px;
}

.sample-chat__form {
    display: flex;
    gap: 8px;
    padding: 10px 12px;
    border-top: 1px solid #e4e6e8;
    background: #fff;
    flex-shrink: 0;
}

.sample-chat__form input {
    flex: 1;
    min-height: 38px;
    border: 1px solid #d7dce0;
    border-radius: 20px;
    padding: 0 14px;
    font: inherit;
    font-size: 0.875rem;
    color: #111;
    background: #f5f6f8;
    outline: none;
    transition: border-color 0.14s, background 0.14s;
}

.sample-chat__form input:focus {
    border-color: var(--hc-green, #5bbf63);
    background: #fff;
}

.sample-chat__form button {
    min-height: 38px;
    border: 0;
    border-radius: 20px;
    background: var(--hc-green, #5bbf63);
    color: #fff;
    padding: 0 16px;
    font: inherit;
    font-size: 0.875rem;
    font-weight: 900;
    cursor: pointer;
    transition: background 0.14s;
    flex-shrink: 0;
}

.sample-chat__form button:hover {
    background: #4aaa52;
}

.sample-chat__typing {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.sample-chat__typing-dots {
    display: flex;
    gap: 4px;
    padding: 10px 13px;
    background: #fff;
    border: 1px solid #e4e6e8;
    border-radius: 4px 16px 16px 16px;
}

.sample-chat__typing-dots span {
    display: block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #aab0b6;
    animation: sampleChatBounce 1.2s ease-in-out infinite;
}

.sample-chat__typing-dots span:nth-child(2) { animation-delay: 0.18s; }
.sample-chat__typing-dots span:nth-child(3) { animation-delay: 0.36s; }

@keyframes sampleChatBounce {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-5px); }
}

.sample-feature-card,
.sample-site-card {
    border: 1px solid #e4e6e8;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 36px rgba(11, 16, 20, 0.05);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.sample-feature-card:hover,
.sample-site-card:hover {
    transform: translateY(-4px);
    border-color: rgba(91, 191, 99, 0.42);
    box-shadow: 0 24px 52px rgba(11, 16, 20, 0.11);
}

.sample-feature-card {
    display: grid;
    gap: 18px;
    min-height: 280px;
    padding: 24px;
}

.sample-feature-card__type,
.sample-site-card__category {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    min-height: 26px;
    padding: 0 9px;
    border-radius: 999px;
    background: rgba(91, 191, 99, 0.12);
    color: #2d7d37;
    font-size: 0.78rem;
    font-weight: 900;
}

.sample-feature-card h3,
.sample-site-card h3 {
    margin: 12px 0 0;
    color: #111;
    font-size: 1.25rem;
    line-height: 1.28;
    letter-spacing: 0;
    font-weight: 900;
}

.sample-feature-card p,
.sample-site-card p {
    margin: 12px 0 0;
    color: #62676d;
    line-height: 1.66;
}

.sample-feature-card dl {
    margin: 0;
    padding-top: 16px;
    border-top: 1px solid #eceeef;
}

.sample-feature-card dt {
    margin-bottom: 7px;
    color: #181a1c;
    font-size: 0.84rem;
    font-weight: 900;
}

.sample-feature-card dd {
    margin: 0;
    color: #6c7278;
    line-height: 1.6;
}

.sample-card-button,
.sample-site-card__actions a,
.sample-site-card__actions button,
.sample-demo-form button,
.sample-flow button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border: 1px solid #111;
    border-radius: 6px;
    background: #111;
    color: #fff;
    padding: 0 16px;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.sample-card-button:hover,
.sample-site-card__actions a:hover,
.sample-site-card__actions button:hover,
.sample-demo-form button:hover,
.sample-flow button:hover {
    border-color: var(--hc-green);
    background: var(--hc-green);
    color: #101213;
}

.sample-search {
    display: grid;
    gap: 8px;
}

.sample-search span {
    color: #24272b;
    font-size: 0.88rem;
    font-weight: 900;
}

.sample-search input {
    width: 100%;
    min-height: 48px;
    border: 1px solid #dfe2e5;
    border-radius: 6px;
    padding: 0 14px;
    color: #111;
    font: inherit;
}

.sample-category-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.sample-category-filter button {
    min-height: 38px;
    border: 1px solid #d9dcdf;
    border-radius: 999px;
    background: #fff;
    color: #555b61;
    padding: 0 13px;
    font: inherit;
    font-size: 0.9rem;
    font-weight: 800;
    cursor: pointer;
}

.sample-category-filter button.is-active {
    border-color: #111;
    background: #111;
    color: #fff;
}

.sample-site-card {
    display: grid;
    overflow: hidden;
}

.sample-site-card__thumb {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    background: #f1f2f3;
    overflow: hidden;
}

.sample-site-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.22s ease;
}

.sample-site-card:hover .sample-site-card__thumb img {
    transform: scale(1.04);
}

.sample-site-card__body {
    padding: 22px 22px 4px;
}

.sample-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 16px;
}

.sample-tags span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 9px;
    border: 1px solid #e4e6e8;
    border-radius: 999px;
    color: #4d5359;
    font-size: 0.82rem;
    font-weight: 800;
}

.sample-site-card__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 20px 22px 22px;
}

.sample-site-card__actions button {
    background: #fff;
    color: #111;
}

.sample-empty {
    margin: 30px 0 0;
    border: 1px dashed #cfd3d7;
    border-radius: 8px;
    padding: 32px;
    color: #666;
    text-align: center;
    font-weight: 800;
}

.sample-modal {
    position: fixed;
    inset: 0;
    z-index: 500;
    display: grid;
    place-items: center;
    padding: 24px;
}

.sample-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.64);
}

.sample-modal__panel {
    position: relative;
    width: min(920px, calc(100vw - 40px));
    max-height: min(86vh, 820px);
    overflow: auto;
    border-radius: 8px;
    background: #fff;
    color: #111;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
}

.sample-modal__panel.sample-modal__panel--wide {
    width: min(1180px, calc(100vw - 40px));
}

.sample-modal__top {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    border-bottom: 1px solid #e8eaec;
    background: rgba(255, 255, 255, 0.96);
    padding: 22px 24px;
}

.sample-modal__top span {
    display: block;
    margin-bottom: 7px;
    color: #2d7d37;
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
}

.sample-modal__top h2 {
    margin: 0;
    font-size: clamp(1.35rem, 3vw, 2rem);
    line-height: 1.2;
    letter-spacing: 0;
}

.sample-modal__close {
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    border: 1px solid #dedede;
    border-radius: 6px;
    background: #fff;
    color: #111;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
}

.sample-modal__body {
    padding: 24px;
}

.sample-demo-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 0.55fr);
    gap: 18px;
}

.sample-demo-panel {
    border: 1px solid #e5e8eb;
    border-radius: 8px;
    background: #f8f9fa;
    padding: 20px;
}

.sample-demo-panel h3 {
    margin: 0 0 14px;
    font-size: 1.06rem;
}

.sample-demo-form {
    display: grid;
    gap: 14px;
}

.sample-demo-form label {
    display: grid;
    gap: 7px;
    color: #25282c;
    font-weight: 900;
}

.sample-demo-form input,
.sample-demo-form select,
.sample-demo-form textarea {
    width: 100%;
    min-height: 44px;
    border: 1px solid #d7dce0;
    border-radius: 6px;
    background: #fff;
    padding: 0 12px;
    color: #111;
    font: inherit;
}

.sample-demo-form textarea {
    min-height: 118px;
    padding-top: 12px;
    resize: vertical;
}

.sample-demo-status {
    min-height: 24px;
    margin: 0;
    color: #2d7d37;
    font-weight: 900;
}

.sample-demo-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sample-demo-list li {
    border: 1px solid #e1e4e7;
    border-radius: 8px;
    background: #fff;
    padding: 14px;
}

.sample-demo-list strong {
    display: block;
    margin-bottom: 5px;
}

.sample-demo-list span {
    color: #687078;
    font-size: 0.9rem;
}

.sample-demo-faq {
    display: grid;
    gap: 10px;
}

.sample-demo-faq details {
    border: 1px solid #e1e4e7;
    border-radius: 8px;
    background: #fff;
    padding: 14px 16px;
}

.sample-demo-faq summary {
    color: #111;
    font-weight: 900;
    cursor: pointer;
}

.sample-demo-faq p {
    margin: 12px 0 0;
    color: #62676d;
    line-height: 1.62;
}

.sample-mini-dashboard {
    display: grid;
    gap: 14px;
}

.sample-kpi-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.sample-kpi {
    border: 1px solid #e2e5e8;
    border-radius: 8px;
    background: #fff;
    padding: 14px;
}

.sample-kpi span {
    display: block;
    color: #6b7279;
    font-size: 0.82rem;
    font-weight: 800;
}

.sample-kpi strong {
    display: block;
    margin-top: 6px;
    font-size: 1.35rem;
}

.sample-product-grid,
.sample-search-results {
    display: grid;
    gap: 10px;
}

.sample-product-row,
.sample-search-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    border: 1px solid #e1e4e7;
    border-radius: 8px;
    background: #fff;
    padding: 14px;
}

.sample-product-row button {
    border: 1px solid #d7dce0;
    border-radius: 6px;
    background: #fff;
    padding: 8px 10px;
    color: #111;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
}

.sample-flow {
    display: grid;
    gap: 12px;
}

.sample-flow__steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.sample-flow__steps span {
    display: grid;
    place-items: center;
    min-height: 54px;
    border: 1px solid #e1e4e7;
    border-radius: 8px;
    background: #fff;
    color: #5b6269;
    font-weight: 900;
}

.sample-flow__steps span.is-active {
    border-color: var(--hc-green);
    background: rgba(91, 191, 99, 0.14);
    color: #153d1a;
}

.sample-preview-frame {
    width: 100%;
    height: min(68vh, 720px);
    border: 1px solid #dfe3e7;
    border-radius: 8px;
    background: #fff;
}

@media (max-width: 960px) {
    .sample-hero {
        padding: 84px 0 56px;
    }

    .sample-section-head--with-tools,
    .sample-site-grid,
    .sample-demo-grid {
        grid-template-columns: 1fr;
    }

    .sample-experience-layout {
        grid-template-columns: 1fr;
    }

    .sample-feature-nav {
        border-right: 0;
        border-bottom: 1px solid #e4e6e8;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        max-height: none;
    }

    .sample-feature-nav-item {
        border-right: 1px solid #eaecee;
        border-bottom-color: #eaecee;
    }

    .sample-feature-nav-item.is-active {
        border-right-color: #eaecee;
        border-bottom: 3px solid var(--hc-green, #5bbf63);
    }

    .sample-demo-stage {
        padding: 18px;
    }

    .sample-chat {
        height: 400px;
    }


    .sample-kpi-grid,
    .sample-flow__steps {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .sample-shell {
        width: calc(100% - 32px);
        max-width: var(--hc-shell);
    }

    .sample-workspace {
        padding: 38px 0 78px;
    }


    .sample-tabs {
        width: 100%;
        max-width: none;
    }

    .sample-tabs button {
        min-width: 0;
        padding: 0 8px;
        font-size: 0.92rem;
        white-space: nowrap;
    }

    .sample-feature-card {
        min-height: 0;
        padding: 20px;
    }

    .sample-site-card__actions {
        grid-template-columns: 1fr;
    }

    .sample-modal {
        padding: 10px;
    }

    .sample-modal__panel,
    .sample-modal__panel.sample-modal__panel--wide {
        width: calc(100vw - 20px);
        max-height: calc(100vh - 20px);
    }

    .sample-modal__top,
    .sample-modal__body {
        padding: 18px;
    }
}
