.talks {
    max-width: 75rem;
    padding: 1rem;
}

.talks > h1 {
    margin-top: 1rem;
}

.talks > p {
    line-height: 1.5;
}

#app {
    margin: calc(2 * var(--navbar-height)) 0;
    display: flex;
    flex-direction: column;
}

.agenda {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.agenda .snake-top {
    display: none;
}

#app .container {
    height: fit-content;
    position: relative;
    display: flex;
    flex-direction: column;
    gap: var(--padding-1);
    padding-bottom: var(--padding-2);
}

#app .container h3 {
    background-color: var(--theme-red);
    color: var(--theme-white);
    font-weight: 600;
    line-height: var(--navbar-height);
    padding: 0 var(--padding-2);
    margin-top: 0;
}

#app .container:nth-child(2n) h3 {
    text-align: right;
    border-top-right-radius: var(--border-radius);
    border-bottom-left-radius: var(--border-radius);
}

#app .container:nth-child(2n + 1) h3 {
    border-top-left-radius: var(--border-radius);
    border-bottom-right-radius: var(--border-radius);
}

#app .container:first-child h3 {
    border-bottom-right-radius: 0;
}

#app .container:nth-child(2n) .snake-vertical {
    position: absolute;
    right: 0;
    top: var(--navbar-height);
    width: var(--navbar-height);
    height: 100%;
    background-color: var(--theme-red);
    z-index: -1;
    border-bottom-right-radius: var(--border-radius);
}

#app .container:last-child .snake-vertical {
    border-bottom-right-radius: 0;
}

#app .container:nth-child(2n + 1) .snake-vertical {
    position: absolute;
    left: 0;
    top: var(--navbar-height);
    width: var(--navbar-height);
    height: 100%;
    background-color: var(--theme-red);
    z-index: -1;
    border-bottom-left-radius: var(--border-radius);
}

#app .container:nth-child(2n) {
    border-radius: 0 var(--border-radius) 0 var(--border-radius);
    display: flex;
    flex-direction: column;
}

#app .container:nth-child(2n + 1)::before {
    content: "";
    position: absolute;
    top: var(--navbar-height);
    left: var(--navbar-height);
    width: 16px;
    height: 16px;
    background:
      radial-gradient(
        circle 10px at 100% 100%,
        transparent 16px,
        var(--theme-red) 17px);  /* + 1 px so the edge is smooth */
}

#app .container:nth-child(2n + 1)::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: var(--navbar-height);
    width: 16px;
    height: 16px;
    background:
      radial-gradient(
        circle 10px at 100% 100%,
        transparent 16px,
        var(--theme-red) 17px);  /* + 1 px so the edge is smooth */
    transform: rotate(-90deg);
}

#app .container:nth-child(2n)::before {
    content: "";
    position: absolute;
    top: var(--navbar-height);
    right: var(--navbar-height);
    width: 16px;
    height: 16px;
    background:
      radial-gradient(
        circle 10px at 100% 100%,
        transparent 16px,
        var(--theme-red) 17px);  /* + 1 px so the edge is smooth */
    transform: rotate(90deg);
}

#app .container:nth-child(2n)::after {
    content: "";
    position: absolute;
    bottom: calc(-1 * var(--navbar-height));
    right: var(--navbar-height);
    width: 16px;
    height: 16px;
    background:
      radial-gradient(
        circle 10px at 100% 100%,
        transparent 16px,
        var(--theme-red) 17px);  /* + 1 px so the edge is smooth */
    transform: rotate(180deg);
}

#app .container:last-child .snake-vertical::before {
    content: "";
    position: absolute;
    top: 100%;
    right: 0;
    width: 1512px;
    height: var(--navbar-height);
    background-color: var(--theme-red);
    border-bottom-right-radius: var(--border-radius);
}

#app .container:nth-child(2n) .talk {
    align-self: flex-end;
    border-radius: var(--border-radius) 0 0 var(--border-radius);
}

#app .container:nth-child(2n) .talk .talk-title {
    border-top-left-radius: var(--border-radius);
}

#app .container:nth-child(2n + 1) .talk {
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

#app .container:nth-child(2n + 1) .talk .talk-title {
    border-top-right-radius: var(--border-radius);
}

@media(max-width: 600px) {
    .agenda {
        position: relative;
        margin-top: var(--navbar-height);
        width: 90%;
        border-radius: 0 var(--border-radius) var(--border-radius) 0;
    }

    .agenda::before {
        content: "";
        position: absolute;
        bottom: calc(100% + var(--padding-0));
        left: 0;
        height: var(--navbar-height);
        width: 100vw;
        background-color: var(--theme-red);
    }

    .agenda .snake-top {
        display: block;
        position: absolute;
        top: calc(-1 * var(--padding-0));
        right: calc(-1 * 11%);
        height: calc(100% + 2 * var(--navbar-height) + var(--padding-0));
        width: 12px;
        background-color: var(--theme-red);
    }

    .agenda .snake-top::before {
        content: "";
        position: absolute;
        top: 0;
        right: 12px;
        width: 16px;
        height: 16px;
        background:
        radial-gradient(
            circle 10px at 100% 100%,
            transparent 16px,
            var(--theme-red) 17px);  /* + 1 px so the edge is smooth */
        transform: rotate(90deg);
    }

    .agenda .snake-top::after {
        content: "";
        position: absolute;
        bottom: 0;
        right: 12px;
        width: 16px;
        height: 16px;
        background:
        radial-gradient(
            circle 10px at 100% 100%,
            transparent 16px,
            var(--theme-red) 17px);  /* + 1 px so the edge is smooth */
        transform: rotate(180deg);
    }
}