/*------------------------------------*\
    #HARC-PROGRAM
    .harc-program ([harc_program] shortcode)
    Matches the theme's schedule rows (harc-styles.css #SCHEDULE) but
    stands on its own, so it keeps working when the theme changes.
\*------------------------------------*/

.harc-program {
    --program-row: var(--wp--preset--color--light-blue, #eef5f8);
    --program-row-hover: #ededed;
    --program-accent: var(--wp--preset--color--shidler-blue, #569bbd);
    --program-rule: var(--wp--preset--color--medium-blue, #1c6c93);
}

.harc-program .day {
    margin-top: 32px;
    margin-bottom: 16px;
    line-height: 1;
    letter-spacing: 0.1px;
}

.harc-program .day:first-child {
    margin-top: 16px;
}

.harc-program .row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 10px;
    background-color: var(--program-row);
    padding: 16px 24px;
    line-height: 1.61111111;
    letter-spacing: 0.1px;
    font-family: var(--wp--preset--font-family--raleway);
    font-size: 18px;
    font-weight: 700;
}

.harc-program .row.block {
    background-color: var(--program-row-hover);
}

.harc-program .divider {
    margin: 0 0.75em;
}

.harc-program .note {
    font-weight: 500;
}

.harc-program .sessions {
    padding-right: 48px;
    padding-left: 48px;
}

/* Open/close rows. The gap below an expandable row belongs to its <details>, so program.js can
   animate the details' height from the summary's alone to summary plus content. */

.harc-program details {
    margin-bottom: 10px;
}

.harc-program details > .row {
    margin-bottom: 0;
}

.harc-program summary {
    transition: background-color 0.3s ease;
    cursor: pointer;
    list-style: none;
}

.harc-program summary::-webkit-details-marker {
    display: none;
}

.harc-program summary:hover {
    background-color: var(--program-row-hover);
}

.harc-program summary:focus-visible {
    outline: 2px solid var(--program-rule);
    outline-offset: 2px;
}

.harc-program .icon {
    position: relative;
    flex: none;
    width: 12px;
    height: 12px;
}

.harc-program .icon::before,
.harc-program .icon::after {
    content: '';
    position: absolute;
    transition: transform 0.3s ease;
    background-color: var(--program-accent);
}

.harc-program .icon::before {
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    width: 100%;
    height: 2px;
}

.harc-program .icon::after {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
}

.harc-program details[open]:not(.closing) .icon::after {
    transform: scaleY(0);
}

/* What a session shows when open */

.harc-program .details {
    background-color: var(--program-row);
    padding: 8px 24px 16px;
}

.harc-program .details p {
    margin: 4px 0;
}

.harc-program .meta:first-child {
    margin-top: 8px;
}

.harc-program .notice {
    font-style: italic;
}

.harc-program .papers {
    margin: 12px 0 0;
    padding: 0;
    list-style: none;
}

.harc-program .paper {
    border-top: 1px solid var(--program-rule);
    padding: 12px 0 8px;
}

.harc-program .paper-title {
    font-family: var(--wp--preset--font-family--raleway);
    font-weight: 700;
}

@media (prefers-reduced-motion: reduce) {
    .harc-program summary,
    .harc-program .icon::before,
    .harc-program .icon::after {
        transition: none;
    }
}

@media (max-width: 600px) {
    .harc-program .row {
        padding: 12px 16px;
        font-size: 16px;
    }

    .harc-program .sessions {
        padding-right: 0;
        padding-left: 16px;
    }

    .harc-program .details {
        padding-right: 16px;
        padding-left: 16px;
    }
}
