/* MAIN */

body:has(.main-header) {
    padding-top: 4rem;
    background-color: var(--wp--preset--color--tertiary);
}

.main-header {
    border-radius: 0 0 2rem 2rem;
    box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
}

#main-nav {
    padding: 0.8rem 0;
}

#main-nav .navbar-nav {
    position: absolute;
    right: 0;
}

.main-header.menu-fixed {
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
}

@media (min-width: 992px) {
    .main-header.menu-fixed .navbar-brand img {
        max-height: 2.5rem;
    }
}

.portal-content__card {
    padding: 1rem;
    background-color: var(--wp--preset--color--white);
    border-radius: var(--inz-radius);
    box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    overflow: hidden;
}

.portal-header__thumb {
    aspect-ratio: 2/1.15;
    border-radius: var(--inz-radius);
    overflow: hidden;
}

.portal-header__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.portal-status {
    padding: 0.2rem 0.8rem;
    background-color: #e1dfdc;
    border-radius: 0.5rem;
    display: table;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.05rem;
    text-transform: uppercase;
}

.portal-header .portal-status {
    position: absolute;
    left: 0.5rem;
    top: 0.5rem;
}

.status-pending {
    background-color: #ffe393;
}

.status-processing {
    background-color: #c1e7ee;
}

.status-completed {
    background-color: #c2ecce;
}

.status-cancelled {
    background-color: #ffb2a7;
}

.portal-header h1 {
    margin: 1rem 0 0;
}

.portal-header ul {
    padding: 0;
    list-style: none;
}

.portal-header ul li {
    padding: 0 0 0 1.8rem;
    position: relative;
}

.portal-header ul li .fi {
    color: var(--wp--preset--color--primary);
    position: absolute;
    left: 0;
    top: 0.35rem;
}

.portal-header__infos {
    display: flex;
    gap: 1rem;
}

.portal-header__infos span {
    padding: 0.5rem 1rem;
    background-color: #f6f6f6;
    border-radius: var(--inz-radius);
}

.portal-header__infos strong {
    display: table;
    font-size: 0.8rem;
    line-height: 1;
}

.portal-content__card h2 {
    margin-bottom: 1.5rem;
    font-size: clamp(1.2rem, 0.95rem + 0.8vw, 1.4rem);
}

.contact-block .fi.fi-whatsapp {
    color: #2dc163;
}

.alert {
    padding: 0.5rem;
    border: 1px solid #c0c0c0;
    border-radius: var(--inz-radius);
    font-size: 0.85rem;
    text-align: center;
}

.alert.alert-danger {
    background-color: #f3caca;
    border-color: #fb9999;
}

.back-button {
    padding: 0;
    margin-bottom: 2rem;
    background-color: transparent;
    display: table;
    font-size: 0.9rem;
}

.back-button:hover {
    text-decoration: underline;
}

.back-button .fi {
    margin-right: 0.5rem;
}

@media (min-width: 576px) {
    .page-template-page-portal #main-nav > .container {
        justify-content: center;
    }
    .portal-header__infos span {
        min-width: 10rem;
    }
}

/* PROGRESS */

.portal-content__progress {
    width: 100%;
}

.portal-content__progress-header {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    margin-bottom: 4px;
}

.portal-content__progress-bar {
    position: relative;
    height: 8px;
    background-color: var(--wp--preset--color--tertiary);
    border-radius: 4px;
    overflow: hidden;
}

.portal-content__progress-fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    background-color: #aa5e07;
    width: 0%;
    transition: width 0.4s ease;
}

/* EVENTS */

.portal-event__item {
    display: flex;
    gap: 0.8rem;
    z-index: 1;
}

.portal-event__item:not(.single) {
    padding: 1rem 0;
}

.portal-event__item-icon {
    min-width: 3.5rem;
    max-width: 3.5rem;
    max-height: 3.5rem;
}

.portal-timeline:before {
    content: "";
    width: 2px;
    height: calc(100% - 8rem);
    background-color: #c0c0c0;
    position: absolute;
    left: 1.55rem;
    top: 4.2rem;
}

.portal-timeline:has(.single):before {
    height: calc(100% - 4.2rem);
}

.portal-event__item-icon > span {
    width: 90%;
    height: 90%;
    background-color: var(--wp--preset--color--white);
    border: 2px solid #c0c0c0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.portal-event__item-icon > span svg {
    width: 70%;
    display: block;
    stroke: #c0c0c0;
}

.portal-event__item.completed .portal-event__item-icon > span {
    border-color: #14a952;
}

.portal-event__item.completed .portal-event__item-icon > span svg {
    stroke: #14a952;
}

.portal-event__item-infos {
    width: 100%;
}

.portal-event__item-header {
    width: 100%;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
}

.portal-event__item h3 {
    margin-bottom: 0;
    font-size: clamp(1rem, 0.8rem + 0.64vw, 1.16rem);
}

.portal-event__item h4 {
    margin: 2rem 0 0.5rem;
    font-size: clamp(0.9rem, 0.775rem + 0.4vw, 1rem);
    font-weight: 700;
}

.portal-event__item p {
    color: #787878;
    line-height: 1.5;
}

.portal-event__item-infos-ul {
    padding: 0;
    display: flex;
    gap: 1rem 2rem;
    flex-wrap: wrap;
    list-style: none;
}

.portal-event__item-infos-ul strong {
    display: block;
}

.portal-event__item .portal-status {
    letter-spacing: 0;
    text-transform: none;
}

.portal-event__item-btn {
    padding: 0;
    background-color: transparent;
    color: var(--wp--preset--color--secondary);
    font-weight: 600;
}

.portal-event__item-btn:hover {
    text-decoration: underline;
}

.portal-event__item-btn .fi {
    margin-left: 0.5rem;
    display: inline-table;
}

.portal-event__item-gallery img {
    border-radius: 1rem;
    transition: all .3s ease-in-out;
}

.portal-event__item-gallery img:hover {
    filter: brightness(80%);
}

@media (max-width: 575px) {
    .portal-event__item-icon {
        min-width: 2rem;
        max-width: 2rem;
        max-height: 2rem;
    }

    .portal-timeline:before {
        top: 5rem;
        left: 0.85rem;
    }
}

/* EVENTS - FILES */

.portal-event__item-archives {
    padding: 0;
    list-style: none;
}

.portal-event__item-archives li {
    padding: 0.5rem;
    margin-bottom: 0.8rem;
    background-color: #f5f5f5;
    border-radius: var(--inz-radius);
    position: relative;
}

.portal-event__item-archives li:hover {
    background-color: #f0f0f0;
}

.portal-event__item-archives li a {
    padding: 0.4rem 0 0.4rem 2.2rem;
    background: url(../../images/download.png) 0.6rem center no-repeat;
    background-size: 1rem;
    display: block;
    line-height: 1.2;
}

.portal-event__item-archives li span {
    padding: 0 0.5rem;
    margin-top: 0.5rem;
    background-color: var(--wp--preset--color--light);
    border-radius: 50px;
    display: table;
    font-size: 0.8rem;
    font-weight: 600;
}

@media (min-width: 576px) {
    .portal-event__item-archives li  {
        padding-right: 5rem;
    }
    .portal-event__item-archives li span {
        margin: 0;
        position: absolute;
        right: 0.6rem;
        top: 50%;
        transform: translateY(-50%);
    }
}

/* CALENDAR */

#portal-calendar {
    --fc-button-bg-color: var(--wp--preset--color--tertiary);
    --fc-button-border-color: var(--wp--preset--color--secondary);
    --fc-button-text-color: var(--wp--preset--color--dark);
    --fc-button-hover-bg-color: var(--wp--preset--color--primary);
    --fc-button-hover-border-color: var(--wp--preset--color--secondary);
}

.fc .fc-toolbar-title {
    font-size: clamp(1.2rem, 0.95rem + 0.8vw, 1.4rem);
}

.fc-theme-standard .fc-scrollgrid {
    border: 1px solid #ddd;
    border-radius: var(--inz-radius);
    overflow: hidden;
}

.fc-theme-standard td, 
.fc-theme-standard th {
    border-right: 0;
    border-bottom: 0;
}

.fc .fc-daygrid-day-frame {
    padding: 0.2rem;
}

.fc-h-event.calendar-status {
    border: none;
}

.fc-h-event.calendar-status .fc-event-main {
    padding: 0 0.2rem;
    color: var(--wp--preset--color--dark);
}

.portal-calendar__labels {
    padding: 0;
    margin-top: 1rem;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.2rem 1rem;
    font-size: 0.8rem;
    list-style: none;
}

.portal-calendar__labels span {
    width: 10px;
    height: 10px;
    margin-right: 0.2rem;
    border-radius: 50px;
    display: inline-table;
}

@media (max-width: 575px) {
    .fc .fc-button {
        padding: 0.4rem 0.25rem;
    }
}