/* =========================================================
 * SIAE Download Area
 * ========================================================= */

.siae-download-area {
    max-width: 980px;
    margin: 0 auto;
    padding: 10px 0 30px;
}

.siae-download-header {
    text-align: center;
    margin: 0 0 42px;
}

.siae-download-header h1 {
    margin: 0;
    font-size: 32px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.siae-download-header::after {
    content: "";
    display: block;
    width: 58%;
    max-width: 520px;
    height: 1px;
    margin: 16px auto 0;
    background: #21a9e1;
}

.siae-download-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: 42px;
    row-gap: 48px;
}

.siae-download-box {
    margin: 0;
}

.siae-download-box h2 {
    margin: 0 0 18px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e4e4e4;
    color: #008ecf;
    font-size: 19px;
    font-weight: 700;
}

.siae-download-folder-list,
.siae-download-file-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.siae-download-folder-list li,
.siae-download-file-list li {
    margin: 5px 0;
    line-height: 1.4;
}

.siae-download-folder-list a,
.siae-download-file-list a {
    text-decoration: none;
}

.siae-download-folder-list a:hover,
.siae-download-file-list a:hover {
    text-decoration: underline;
}

.siae-folder-icon {
    display: inline-block;
    width: 19px;
    margin-right: 4px;
    font-size: 14px;
    line-height: 1;
    vertical-align: -1px;
}

.siae-download-login-note {
    margin: -20px 0 30px;
    text-align: center;
}

.siae-download-back {
    margin: -20px 0 30px;
}

@media (max-width: 900px) {
    .siae-download-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 30px;
        row-gap: 36px;
    }
}

@media (max-width: 640px) {
    .siae-download-area {
        padding-left: 8px;
        padding-right: 8px;
    }

    .siae-download-header {
        margin-bottom: 30px;
    }

    .siae-download-header h1 {
        font-size: 26px;
    }

    .siae-download-header::after {
        width: 80%;
    }

    .siae-download-grid {
        grid-template-columns: 1fr;
        row-gap: 30px;
    }
}


/* =========================================================
 * Download category - file list
 * ========================================================= */

.siae-download-file-panel {
    margin-top: 20px;
    border: 1px solid #e5e5e5;
    background: #fff;
}

.siae-download-file-panel-title {
    padding: 12px 16px;
    border-bottom: 1px solid #e5e5e5;
    background: #fafafa;
    font-size: 22px;
    font-weight: 400;
}

.siae-download-file-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px 16px;
    border-bottom: 1px solid #eeeeee;
}

.siae-download-file-row:last-child {
    border-bottom: 0;
}

.siae-download-file-info {
    min-width: 0;
    flex: 1;
}

.siae-download-file-title {
    margin-bottom: 4px;
    font-size: 14px;
    font-weight: 600;
}

.siae-download-file-name {
    color: #159bd3;
    font-size: 13px;
    word-break: break-word;
}

.siae-download-file-icon {
    margin-right: 5px;
    font-size: 12px;
}

.siae-download-file-actions {
    display: flex;
    gap: 8px;
    flex: 0 0 auto;
}

.siae-download-btn {
    display: inline-block;
    padding: 7px 13px;
    border-radius: 2px;
    color: #fff !important;
    text-decoration: none !important;
    font-size: 13px;
    line-height: 1.2;
}

.siae-download-btn-details {
    background: #49b8df;
}

.siae-download-btn-download {
    background: #54b956;
}

.siae-download-btn:hover {
    opacity: .9;
}

@media (max-width: 640px) {
    .siae-download-file-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .siae-download-file-actions {
        width: 100%;
    }
}


/* =========================================================
 * Download Details tooltip
 * ========================================================= */

.siae-download-details {
    position: relative;
    display: inline-block;
}

.siae-download-btn-details {
    border: 0;
    cursor: default;
    font: inherit;
}

.siae-download-tooltip {
    position: absolute;
    z-index: 50;
    top: calc(100% + 8px);
    right: 0;
    width: 260px;
    padding: 10px 12px 12px;
    border: 1px solid #a9a9a9;
    background: #f2f2f2;
    box-shadow: 0 2px 5px rgba(0, 0, 0, .12);
    color: #777;
    font-size: 13px;
    line-height: 1.45;

    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-3px);
    transition:
        opacity .15s ease,
        transform .15s ease,
        visibility .15s ease;
}

.siae-download-details:hover .siae-download-tooltip,
.siae-download-details:focus-within .siae-download-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.siae-download-tooltip-heading {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    color: #888;
    font-size: 13px;
}

.siae-download-tooltip-title {
    margin-bottom: 10px;
    color: #777;
    font-size: 14px;
    font-weight: 700;
}

.siae-download-tooltip-row {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 8px;
    margin-top: 6px;
}

.siae-download-tooltip-row strong {
    color: #888;
    font-weight: 700;
}

.siae-download-tooltip-row span {
    color: #888;
}

@media (max-width: 640px) {
    .siae-download-tooltip {
        right: auto;
        left: 0;
        width: min(260px, calc(100vw - 40px));
    }
}


.siae-download-file-name > a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}

.siae-download-file-name > a:hover .siae-download-file-link {
    text-decoration: underline;
}

.siae-download-file-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 18px;
    margin: 0;
    border-radius: 2px;
    font-size: 8px;
    font-weight: 700;
    line-height: 1;
}

.siae-download-file-icon-pdf {
    border: 1px solid #d9534f;
    color: #d9534f;
    background: #fff;
}

.siae-download-file-icon-generic {
    border: 1px solid #999;
    color: #777;
    background: #fff;
}


.siae-download-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 14px;
    font-size: 13px;
    line-height: 1;
    font-weight: 400;
    vertical-align: middle;
    box-sizing: border-box;
}

.siae-download-btn-details,
.siae-download-btn-download {
    font: inherit;
}


/* Folder icon stile Joomla */
.siae-folder-icon {
    position: relative;
    display: inline-block;
    width: 14px;
    height: 10px;
    margin-right: 6px;
    border: 1px solid #b88a2a;
    border-radius: 1px;
    background: #d9ad53;
    vertical-align: -1px;
    box-sizing: border-box;
}

.siae-folder-icon::before {
    content: "";
    position: absolute;
    top: -4px;
    left: 1px;
    width: 7px;
    height: 4px;
    border: 1px solid #b88a2a;
    border-bottom: 0;
    border-radius: 2px 2px 0 0;
    background: #e2bb67;
    box-sizing: border-box;
}



/* Download Area breadcrumb */
.siae-download-area .siae-breadcrumb {
    margin: 0 0 18px;
    color: #68757f;
    font-size: 13px;
    line-height: 1.4;
}

.siae-download-area .siae-breadcrumb__list {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
}

.siae-download-area .siae-breadcrumb__item {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
}

.siae-download-area
.siae-breadcrumb__item + .siae-breadcrumb__item::before {
    content: "/";
    display: inline-block;
    margin: 0 7px;
    color: #a1aab1;
}

.siae-download-area .siae-breadcrumb a {
    color: #68757f;
    text-decoration: none;
}

.siae-download-area .siae-breadcrumb a:hover,
.siae-download-area .siae-breadcrumb a:focus {
    color: #008ac9;
}

.siae-download-area .siae-breadcrumb__item--current {
    color: #87929a;
}
