/* ============================================================
   WELCOME GUIDE MODAL
   ============================================================ */

.wg-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.wg-modal {
    background: #fff;
    border-radius: var(--ct-radius-lg);
    width: min(560px, calc(100vw - 48px));
    max-height: calc(100vh - 48px);
    max-height: calc(100dvh - 48px);
    padding: 20px 24px 16px;
    position: relative;
    display: grid;
    grid-template-rows: auto /* title */
    auto /* subtitle */
    auto /* video */
    auto /* transcript */
    minmax(0, 1fr) /* learn section */
    auto; /* footer */

    overflow: hidden;
}

.wg-close {
    position: absolute;
    top: 14px;
    right: 18px;
    background: none;
    border: none;
    font-size: 1.4rem;
    color: var(--ct-text-muted);
    cursor: pointer;
    line-height: 1;
    padding: 4px 8px;
}

    .wg-close:hover {
        color: var(--ct-text-primary);
    }

.wg-title {
    margin: 0 0 4px;
    color: var(--ct-text-primary);
}

.wg-subtitle {
    color: var(--ct-text-secondary);
    margin: 0 0 8px;
}

.wg-video-wrapper {
    width: 100%;
    aspect-ratio: 16 / 9;
    max-height: 315px;
    background: #111;
    border-radius: var(--ct-radius);
    overflow: hidden;
    margin-bottom: 6px;
    flex: none;
}

.wg-video-iframe {
    width: 100%;
    height: 100%;
    display: block;
    border: none;
}

.wg-video-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,.5);
    font-size: .875rem;
}

.wg-transcript-link {
    display: inline-block;
    color: var(--ct-brand-purple);
    margin-bottom: 8px;
    font-size: .875rem;
}

    .wg-transcript-link:hover {
        text-decoration: underline;
    }

.wg-learn-section {
    min-height: 0;
    overflow-y: auto;
    padding-right: 4px;
    margin-bottom: 10px;
}

.wg-learn-heading {
    margin: 0 0 6px;
}

.wg-learn-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

    .wg-learn-list li {
        display: flex;
        align-items: center; /* was flex-start */
        gap: 10px;
        color: var(--ct-text-primary);
        line-height: 1.3;
    }

.wg-star {
    color: #F5A623;
    font-size: 1rem;
    flex-shrink: 0;
    /* remove: margin-top: 1px; */
    display: inline-flex;
    align-items: center;
}

    .wg-star img {
        display: block; /* kills the inline-image baseline gap */
    }

.wg-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 10px;
    border-top: 1px solid var(--ct-border);
    background: #fff;
    z-index: 1;
}

.wg-dont-show {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: .875rem;
    color: var(--ct-text-secondary);
    cursor: pointer;
}

.wg-begin-btn {
    white-space: nowrap;
    flex-shrink: 0;
}

/* Large screens — expand */
@media (min-height: 900px) {
    .wg-modal {
        width: min(700px, calc(100vw - 48px));
        padding: 36px 40px 28px;
    }

    .wg-title {
        font-size: var(--kendo-h3-font-size, 36px);
        margin-bottom: 6px;
    }

    .wg-subtitle {
        margin-bottom: 20px;
    }

    .wg-video-wrapper {
        margin-bottom: 14px;
        /* aspect-ratio is already 16/9, no override needed */
    }

    .wg-transcript-link {
        margin-bottom: 20px;
    }

    .wg-learn-section {
        margin-bottom: 24px;
    }

    .wg-learn-heading {
        margin-bottom: 10px;
    }

    .wg-learn-list {
        gap: 8px;
    }

    .wg-footer {
        padding-top: 16px;
    }
}
