.release-modal {
    position: fixed;
    inset: 0;
    z-index: 20000;

    display: none;
    align-items: center;
    justify-content: center;

    padding: 20px;
}

.release-modal.visible {
    display: flex;
}

.release-modal-backdrop {
    position: absolute;
    inset: 0;

    background: rgba(15, 23, 42, 0.58);

    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.release-modal-dialog {
    position: relative;
    z-index: 1;

    width: 100%;
    max-width: 580px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;

    padding: 36px;

    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);

    animation: releaseModalIn 0.25s ease;
}

.release-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;
    padding: 0;

    background: #f1f5f9;
    color: #64748b;

    border: none;
    border-radius: 10px;

    font-size: 1rem;
    cursor: pointer;

    transition:
        background-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease;
}

.release-modal-close:hover {
    background: #e2e8f0;
    color: #0f172a;
    transform: translateY(-1px);
}

.release-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 64px;
    height: 64px;
    margin: 0 auto 20px;

    background: #dbeafe;
    color: #2563eb;

    border-radius: 18px;
    font-size: 1.8rem;
}

.release-modal-dialog h2 {
    margin: 0 45px 8px;
    color: #0f172a;
    text-align: center;
}

.release-version {
    color: #2563eb;
    font-size: 1.05rem;
    font-weight: 700;
    text-align: center;
}

.release-date {
    margin-top: 5px;
    color: #94a3b8;
    font-size: 0.85rem;
    text-align: center;
}

.release-intro {
    margin: 24px 0 18px;
    color: #475569;
    line-height: 1.7;
    text-align: center;
}

/* Sekcje changelogu */

.release-changelog-sections {
    margin-top: 24px;
}

.release-changelog-section {
    margin-bottom: 24px;
}

.release-changelog-section:last-child {
    margin-bottom: 0;
}

.release-section-title {
    display: flex;
    align-items: center;
    gap: 10px;

    margin: 0 0 12px;

    color: #0f172a;
    font-size: 1.08rem;
    font-weight: 700;
}

.release-section-title i {
    width: 22px;
    flex-shrink: 0;
    text-align: center;
}

/* Kolory poszczególnych sekcji */

.release-section-new .release-section-title i {
    color: #16a34a;
}

.release-section-improvements .release-section-title i {
    color: #2563eb;
}

.release-section-fix .release-section-title i {
    color: #f59e0b;
}

/* Listy zmian */

.release-changelog {
    display: flex;
    flex-direction: column;
    gap: 10px;

    margin: 0;
    padding: 0;

    list-style: none;
}

.release-changelog li {
    display: flex;
    align-items: flex-start;
    gap: 12px;

    padding: 13px 14px;

    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 11px;

    color: #334155;
    line-height: 1.55;
}

.release-changelog li > i {
    flex-shrink: 0;
    margin-top: 4px;
    color: #64748b;
}

/* Opcjonalne różnicowanie tła wpisów */

.release-section-new .release-changelog li {
    background: #f0fdf4;
    border-color: #dcfce7;
}

.release-section-new .release-changelog li > i {
    color: #16a34a;
}

.release-section-improvements .release-changelog li {
    background: #eff6ff;
    border-color: #dbeafe;
}

.release-section-improvements .release-changelog li > i {
    color: #2563eb;
}

.release-section-fix .release-changelog li {
    background: #fffbeb;
    border-color: #fef3c7;
}

.release-section-fix .release-changelog li > i {
    color: #f59e0b;
}

/* Przycisk potwierdzenia */

.release-modal-confirm {
    display: block;
    width: 100%;
    margin-top: 28px;
    padding: 13px 22px;

    background: #2563eb;
    color: #ffffff;

    border: none;
    border-radius: 10px;

    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;

    transition:
        background-color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.release-modal-confirm:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.22);
}

body.release-modal-open {
    overflow: hidden;
}

@keyframes releaseModalIn {
    from {
        opacity: 0;
        transform: translateY(15px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (max-width: 768px) {
    .release-modal {
        padding: 12px;
    }

    .release-modal-dialog {
        max-height: calc(100vh - 24px);
        padding: 30px 20px 22px;
        border-radius: 15px;
    }

    .release-modal-dialog h2 {
        margin-left: 35px;
        margin-right: 35px;
        font-size: 1.4rem;
    }

    .release-modal-icon {
        width: 56px;
        height: 56px;
        font-size: 1.5rem;
    }

    .release-section-title {
        font-size: 1rem;
    }

    .release-changelog li {
        padding: 12px;
        font-size: 0.92rem;
    }
}
