/* =========================================================
   AMS AGENDA
========================================================= */

.ams-agenda {
    width: 100%;
}


/* =========================================================
   DATE TABS
========================================================= */

.ams-agenda-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
}

.ams-agenda-tab {
    cursor: pointer;
    border: 0;
    background: transparent;
    padding: 10px 20px;
}

.ams-agenda-tab.is-active {
    font-weight: 700;
}


/* =========================================================
   AGENDA DAYS
========================================================= */

.ams-agenda-days {
    width: 100%;
}

.ams-agenda-day {
    display: none;
}

.ams-agenda-day.is-active {
    display: block;
}


/* =========================================================
   SESSION
========================================================= */

.ams-session {
    position: relative;
    width: 100%;
    margin-bottom: 10px;
}

.ams-session.no-content {
    cursor: default;
}


/* =========================================================
   SESSION ROW
========================================================= */

.ams-session-row {
    position: relative;
    display: flex;
    align-items: stretch;
    width: 100%;
}


/* =========================================================
   SESSION TIME
========================================================= */

.ams-session-time {
    flex: 0 0 220px;
    width: 220px;
    padding: 20px;
}

.ams-session-date,
.ams-session-hours {
    display: block;
}

.ams-session-date {
    margin-bottom: 4px;
}


/* =========================================================
   SESSION TOGGLE
========================================================= */

.ams-session-toggle {
    position: relative;

    display: flex;
    align-items: center;

    width: 100%;
    min-height: 70px;

    padding: 20px 60px 20px 20px;

    margin: 0;

    border: 0;
    background: transparent;

    text-align: left;

    cursor: pointer;

    appearance: none;
    -webkit-appearance: none;
}


/*
 * Remove browser button styling.
 */
.ams-session-toggle:focus {
    outline: none;
}


/*
 * Optional accessible focus state.
 */
.ams-session-toggle:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}


/* =========================================================
   SESSION TITLE
========================================================= */

.ams-session-title {
    display: block;
    width: 100%;
}


/*
 * Static title for sessions that cannot expand.
 */
.ams-session-title-static {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 20px;
}


/* =========================================================
   SESSION ICON
========================================================= */

/*
 * IMPORTANT:
 *
 * The actual "+" text inside the span is hidden.
 * The pseudo-element controls the visible icon.
 *
 * This prevents any existing "+" text from conflicting
 * with the open/close state.
 */

.ams-session-icon {
    position: absolute;

    top: 50%;
    right: 15px;

    display: flex;

    align-items: center;
    justify-content: center;

    width: 30px;
    height: 30px;

    margin: 0;
    padding: 0;

    transform: translateY(-50%);

    font-size: 0 !important;
    line-height: 1 !important;
    font-weight: 400;

    color: inherit;

    visibility: visible !important;
    opacity: 1 !important;

    pointer-events: none;
}


/*
 * PLUS ICON
 */
.ams-session-icon::before {
    content: '+' !important;

    display: block;

    width: 30px;
    height: 30px;

    font-size: 26px !important;
    line-height: 30px !important;

    font-weight: 400;
    text-align: center;

    visibility: visible !important;
    opacity: 1 !important;

    transform: none !important;
}


/*
 * OPEN SESSION = X ICON
 *
 * This is the important rule.
 */
.ams-session.is-open .ams-session-icon::before {
    content: '×' !important;

    font-size: 28px !important;
    line-height: 30px !important;

    transform: none !important;
}


/*
 * Also support aria-expanded in case another script
 * changes the state without adding .is-open.
 */
.ams-session-toggle[aria-expanded="true"] .ams-session-icon::before {
    content: '×' !important;
}

.ams-session-toggle[aria-expanded="false"] .ams-session-icon::before {
    content: '+' !important;
}


/* =========================================================
   SESSION CONTENT
========================================================= */

.ams-session-content {
    position: relative;
    width: 100%;
}


/*
 * Respect the HTML hidden attribute.
 */
.ams-session-content[hidden] {
    display: none !important;
}


/*
 * Open content.
 */
.ams-session.is-open .ams-session-content {
    display: block;
}


/* =========================================================
   SESSION CONTENT INNER
========================================================= */

.ams-session-content-inner {
    position: relative;
    width: 100%;
    padding: 30px;
}


/* =========================================================
   CLOSE BUTTON
========================================================= */

.ams-session-close {
    position: absolute;

    top: 15px;
    right: 15px;

    z-index: 10;

    display: flex;

    align-items: center;
    justify-content: center;

    width: 30px;
    height: 30px;

    margin: 0;
    padding: 0;

    border: 0;
    background: transparent;

    font-size: 26px;
    line-height: 1;

    cursor: pointer;

    appearance: none;
    -webkit-appearance: none;
}

.ams-session-close:hover {
    opacity: 0.7;
}


/* =========================================================
   SESSION DESCRIPTION
========================================================= */

.ams-session-description {
    margin-bottom: 30px;
}

.ams-session-description:last-child {
    margin-bottom: 0;
}


/* =========================================================
   SESSION SECTION TITLES
========================================================= */

.ams-session-section-title {
    display: flex;
    align-items: center;
    gap: 8px;

    margin: 0 0 20px;
}


/* =========================================================
   SECTION TITLE ICON
========================================================= */

.ams-session-section-icon {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    flex: 0 0 auto;
}


/* =========================================================
   SPEAKERS
========================================================= */

.ams-session-speakers {
    width: 100%;
    margin-top: 30px;
    margin-bottom: 30px;
}


/*
 * Speaker list
 */
.ams-session-speakers-list {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}


/*
 * Individual speaker
 */
.ams-session-speaker {
    display: flex;
    flex-direction: column;

    width: 150px;

    text-decoration: none;
}


/*
 * Speaker image
 */
.ams-session-speaker-image {
    width: 100%;
    aspect-ratio: 1 / 1;

    margin-bottom: 10px;

    overflow: hidden;
}


/*
 * Speaker image itself
 */
.ams-session-speaker-image img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
}


/*
 * Speaker name
 */
.ams-session-speaker-name {
    width: 100%;
}


/* =========================================================
   VIEW ALL SESSION BUTTON
========================================================= */

.ams-session-view-all {
    margin-top: 25px;
}


.ams-session-view-all-button {
    display: inline-block;

    padding: 10px 20px;

    text-decoration: none;
}


/* =========================================================
   REGISTRATION
========================================================= */

.ams-session-registration {
    width: 100%;
    margin-top: 30px;
    padding-top: 30px;
}


/*
 * Registration text
 */
.ams-session-registration-text {
    margin-bottom: 20px;
}


/*
 * Registration code
 */
.ams-session-registration-code {
    width: 100%;
}


/* =========================================================
   NO SESSIONS
========================================================= */

.ams-no-speaker-sessions {
    margin: 20px 0;
}


/* =========================================================
   SINGLE SPEAKER PAGE
========================================================= */

.single-speaker .ams-agenda {
    width: 100%;
}

.single-speaker .ams-session {
    width: 100%;
}


/* =========================================================
   SINGLE SPEAKER SESSION ICON OVERRIDE
========================================================= */

/*
 * Some theme styles can affect the icon on the
 * single speaker template.
 *
 * These rules deliberately use !important so the
 * accordion state always wins.
 */

.single-speaker .ams-session-icon {
    position: absolute !important;

    right: 15px !important;
    top: 50% !important;

    display: flex !important;

    width: 30px !important;
    height: 30px !important;

    transform: translateY(-50%) !important;

    font-size: 0 !important;

    visibility: visible !important;
    opacity: 1 !important;
}


.single-speaker .ams-session-icon::before {
    content: '+' !important;

    display: block !important;

    width: 30px !important;
    height: 30px !important;

    font-size: 26px !important;
    line-height: 30px !important;

    visibility: visible !important;
    opacity: 1 !important;

    transform: none !important;
}


.single-speaker .ams-session.is-open .ams-session-icon::before {
    content: '×' !important;

    font-size: 28px !important;
    line-height: 30px !important;
}


.single-speaker .ams-session-toggle[aria-expanded="true"] .ams-session-icon::before {
    content: '×' !important;
}


.single-speaker .ams-session-toggle[aria-expanded="false"] .ams-session-icon::before {
    content: '+' !important;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 767px) {

    /*
     * Session row becomes stacked.
     */
    .ams-session-row {
        display: block;
    }


    /*
     * Time
     */
    .ams-session-time {
        width: 100%;
        padding: 15px 20px 5px;
    }


    /*
     * Toggle
     */
    .ams-session-toggle {
        min-height: 60px;

        padding: 15px 55px 15px 20px;
    }


    /*
     * Icon
     */
    .ams-session-icon {
        right: 15px;
    }


    /*
     * Content
     */
    .ams-session-content-inner {
        padding: 25px 20px;
    }


    /*
     * Speakers
     */
    .ams-session-speakers-list {
        gap: 15px;
    }


    .ams-session-speaker {
        width: calc(50% - 8px);
    }


    /*
     * Date tabs
     */
    .ams-agenda-tabs {
        gap: 5px;
    }


    .ams-agenda-tab {
        padding: 8px 12px;
    }

}


/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 480px) {

    .ams-session-speaker {
        width: 100%;
    }


    .ams-session-content-inner {
        padding: 20px 15px;
    }


    .ams-session-toggle {
        padding-left: 15px;
        padding-right: 50px;
    }


    .ams-session-time {
        padding-left: 15px;
        padding-right: 15px;
    }

}