/* ==========================================================================
   Licenses Block (.sa-licenses)
   ========================================================================== */

.sa-licenses {
    padding: var(--section-spacing-desktop, 80px) 0;
    background-color: var(--sa-bg-body, #ffffff);
}

.sa-licenses .sa-section-header {
    text-align: center;
    margin-bottom: 40px;
}

.sa-licenses .sa-section-title,
.sa-licenses__title {
    font-family: var(--font-title);
    font-size: clamp(2rem, 3.2vw, 2.75rem);
    font-weight: 700;
    text-transform: uppercase;
    text-align: center;
    color: var(--sa-purple-primary, #614D8F) !important;
    line-height: 1.15;
    margin: 0;
    letter-spacing: -0.01em;
}

.sa-licenses__grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: var(--space-4, 16px);
    align-items: stretch;
}

.sa-licenses__item {
    position: relative;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    border-radius: var(--radius-md, 12px);
    overflow: hidden;
    background: #ffffff;
    box-shadow: var(--sa-shadow-card, 0 4px 16px rgba(0, 0, 0, 0.08));
    border: 1px solid rgba(0, 0, 0, 0.06);
    transition: transform var(--transition-fast, 0.25s ease), box-shadow var(--transition-fast, 0.25s ease);
    cursor: pointer;
}

.sa-licenses__item:hover,
.sa-licenses__item:focus-visible {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(97, 77, 143, 0.20);
    outline: none;
}

.sa-licenses__img {
    width: 100%;
    height: 100%;
    aspect-ratio: 566 / 814;
    object-fit: cover;
    display: block;
    border-radius: var(--radius-md, 12px);
    transition: transform 0.3s ease;
}

.sa-licenses__item:hover .sa-licenses__img {
    transform: scale(1.02);
}

.sa-licenses__zoom {
    position: absolute;
    right: 10px;
    bottom: 10px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(97, 77, 143, 0.90);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.85);
    transition: opacity 0.2s ease, transform 0.2s ease, background-color 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    pointer-events: none;
}

.sa-licenses__item:hover .sa-licenses__zoom,
.sa-licenses__item:focus-visible .sa-licenses__zoom {
    opacity: 1;
    transform: scale(1);
}

@media (hover: none) {
    .sa-licenses__zoom {
        opacity: 0.85;
        transform: scale(0.9);
    }
}

/* --------------------------------------------------------------------------
   Licenses Lightbox Modal (.sa-licenses-modal)
   -------------------------------------------------------------------------- */
.sa-licenses-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 100000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    box-sizing: border-box;
}

.sa-licenses-modal.is-open {
    display: flex;
}

.sa-licenses-modal__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(14, 10, 22, 0.90);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    cursor: pointer;
}

.sa-licenses-modal__container {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 94vw;
    max-height: 94vh;
}

.sa-licenses-modal__close {
    position: fixed;
    top: 20px;
    right: 24px;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.18);
    border: none;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    z-index: 100010;
    transition: background-color 0.2s ease, transform 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.sa-licenses-modal__close:hover,
.sa-licenses-modal__close:focus-visible {
    background: rgba(255, 255, 255, 0.35);
    transform: scale(1.1);
    outline: none;
}

.sa-licenses-modal__nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    color: var(--sa-purple-primary, #614D8F);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
    transition: background-color 0.2s, transform 0.2s, color 0.2s;
    z-index: 100010;
}

.sa-licenses-modal__nav:hover,
.sa-licenses-modal__nav:focus-visible {
    background: var(--sa-purple-primary, #614D8F);
    color: #ffffff;
    transform: translateY(-50%) scale(1.1);
    outline: none;
}

.sa-licenses-modal__nav--prev {
    left: 24px;
}

.sa-licenses-modal__nav--next {
    right: 24px;
}

.sa-licenses-modal__content {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: saLicensesModalZoom 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes saLicensesModalZoom {
    from {
        opacity: 0;
        transform: scale(0.96);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.sa-licenses-modal__image {
    max-width: 90vw;
    max-height: 92vh;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    border-radius: 6px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.6);
}

/* --------------------------------------------------------------------------
   Responsive Breakpoints
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
    .sa-licenses__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 14px;
    }

    .sa-licenses-modal__nav--prev {
        left: 14px;
    }

    .sa-licenses-modal__nav--next {
        right: 14px;
    }
}

@media (max-width: 768px) {
    .sa-licenses-modal {
        padding: 10px;
    }

    .sa-licenses-modal__close {
        top: 14px;
        right: 14px;
        width: 40px;
        height: 40px;
    }

    .sa-licenses-modal__nav {
        width: 44px;
        height: 44px;
    }

    .sa-licenses-modal__nav--prev {
        left: 10px;
    }

    .sa-licenses-modal__nav--next {
        right: 10px;
    }

    .sa-licenses-modal__image {
        max-width: 94vw;
        max-height: 88vh;
    }
}

@media (max-width: 600px) {
    .sa-licenses {
        padding: 48px 0;
    }

    .sa-licenses .sa-section-header {
        margin-bottom: 24px;
    }

    .sa-licenses__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
}
