/* Hide the content source */
.accordion-content-source {
    display: none;
}

/* Desktop Horizontal Accordion */
.accordion-container {
    display: flex;
    gap: var(--space-4);
    min-height: 480px;
}

.accordion-panel {
    width: 100%;
    max-width: 90px;
    transition: max-width .5s ease;
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    margin-top: 16px;
}

.accordion-panel::before {
    display: block;
    content: "";
    position: absolute;
    height: 16px;
    width: 45px;
    left: 0;
    top: -16px;
    border-radius: var(--space-2) var(--space-2) 0 0;
    background-color: #d77409;
    transition: width .5s ease;
}

.accordion-panel.expanded::before {
    width: 250px;
}

.accordion-panel.collapsed {
    align-items: end;
    padding: 25px;
    background: #37517e;
}

.accordion-panel.expanded {
    background: #37517e;
    color: var(--white);
    padding: 40px;
    max-width: 660px;
}

.accordion-panel .fade-in {
    opacity: 0;
    animation: fadeIn 0.4s forwards;
}
  
@keyframes fadeIn {
    to {
      opacity: 1;
    }
}

.panel-title {
    font-family: var(--font-heading);
    line-height: var(--leading-tight);
    font-size: var(--text-xl);
    font-weight: var(--font-semibold);
    writing-mode: vertical-rl;
    transform: rotate(180deg);
}

.panel-icon {
    font-size: var(--text-3xl);
    display: flex;
    justify-content: center;
}

.refresh-icon {
    font-size: var(--text-4xl);
    display: inline-flex;
    margin-bottom: 15px;
}

/* Mobile Vertical Accordion */
.mobile-accordion {
    display: none;
}

@media (max-width: 1199px) {
    .accordion-container {
        display: none;
    }

    .mobile-accordion {
        display: block;
        overflow: hidden;
        border-radius: 8px;
    }

    .mobile-panel {
        border-bottom: 1px solid var(--gray-300);
        margin: 0;
    }

    .mobile-panel:last-child {
        border-bottom: none;
    }

    .mobile-panel-header {
        background: #37517e; /* Changed to your color */
        padding: var(--space-4);
        cursor: pointer;
        display: flex;
        justify-content: space-between;
        align-items: center;
        gap: var(--space-2);
        color: white; /* Added for text color */
        transition: background-color 0.3s ease;
        margin-bottom: 5px;
    }

    .mobile-panel-header:hover {
        background: #2d4268; /* Darker shade on hover */
    }

    .mobile-panel-header.active {
        background: #2d4268; /* Active state darker color */
    }

    .mobile-panel-header h3 {
        font-size: var(--text-lg);
        color: white; /* Ensure text is white */
        margin: 0;
        font-weight: var(--font-semibold);
        display: flex;
        align-items: center;
        gap: var(--space-2);
    }

    /* Panel icon color */
    .panel-icon-mobile {
        color: white;
        font-size: var(--text-xl);
    }

    .mobile-panel-content {
        background: var(--gray-300); /* Changed to your color */
        color: var(--black); /* Changed to your color */
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        padding: 0;
        transition: max-height 0.3s ease, opacity 0.3s ease, padding 0.3s ease;
    }
    
    .mobile-panel-content.active {
        max-height: max-content;
        opacity: 1;
        padding: var(--space-4);
    }      

    .mobile-panel-content p {
        color: var(--black); /* Ensure paragraph text is black */
        margin: 0;
        line-height: 1.6;
    }

    .chevron {
        transition: transform 0.3s ease;
        color: white; /* Added chevron color */
    }

    .chevron::before {
        font-weight: var(--font-semibold) !important;
    }

    .mobile-panel-header.active .chevron {
        transform: rotate(180deg);
    }
}