#ymcp-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.55);
    box-sizing: border-box;
}

#ymcp-modal,
#ymcp-modal * {
    box-sizing: border-box;
}

.ymcp-modal {
    position: relative;
    width: min(520px, 100%);
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    padding: 32px;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    font-family: inherit;
    color: #111;
}

.ymcp-modal h2 {
    margin: 0 42px 12px 0;
    font-size: 25px;
    line-height: 1.2;
}

.ymcp-intro {
    margin: 0 0 16px;
    font-size: 16px;
    line-height: 1.5;
}

.ymcp-close {
    position: absolute;
    top: 12px;
    right: 15px;
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #222;
    font-size: 30px;
    line-height: 38px;
    cursor: pointer;
}

.ymcp-close:hover {
    background: #f1f1f1;
}

.ymcp-copybox {
    margin: 0 0 22px;
    padding: 16px;
    background: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 10px;
}

.ymcp-credit {
    white-space: pre-line;
    font-size: 15px;
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.ymcp-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.ymcp-copy,
.ymcp-download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 10px 18px;
    border-radius: 8px;
    border: 1px solid #222;
    font: inherit;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
}

.ymcp-copy {
    background: #fff;
    color: #111;
}

.ymcp-download {
    background: #111;
    color: #fff;
}

.ymcp-copy:hover,
.ymcp-download:hover {
    opacity: 0.88;
}

@media (max-width: 600px) {
    .ymcp-modal {
        padding: 25px 20px;
        border-radius: 15px;
    }

    .ymcp-actions {
        flex-direction: column;
    }

    .ymcp-copy,
    .ymcp-download {
        width: 100%;
    }
}
