:root {
    --main-accent-color: #d6aaa7;
    --text-color: #666666;
    --text-color-dark: #222222;
    --background-color: #dddddd;

    --pacman-color: #ad5e76;

    --body-max-width: 1080px;
    --transition: 250ms all ease-in-out;

    --body-padding: 2em;
}

body {
    padding: var(--body-padding);
    max-width: var(--body-max-width);
    margin: 0 auto;
    line-height: 1.5;
    font-family: "Open Sans", Arial, sans-serif;
}

header {
    margin: calc(-1 * var(--body-padding));
    margin-bottom: var(--body-padding);
}

#main-logo {
    width: 100%;
    display: block;
    margin: auto;
}

#filters {
    margin-bottom: 2em;
    z-index: 99;
    position: fixed;
    bottom: 1em;
    right: 1em;
    left: 1em;
    max-width: 400px;
    filter: drop-shadow(2px 2px 3px #00000088);
}
#filters .rooms-filter {
    position: relative;
}
#filters .rooms-filter > summary {
    text-align: center;
    cursor: pointer;
    background: var(--main-accent-color);
    border-radius: 5px;
    width: auto;
    margin: 0;
    padding: 0.5em 1em;
}
#filters .rooms-filter > summary::before {
    content: "";
}
#filters .rooms-filter > ul {
    position: absolute;
    bottom: 100%;
    background: white;
    margin: auto;
    opacity: 0;
    transform: translateY(25px);
    transition: var(--transition);
    padding: 0;
    width: 100%;
}
#filters .rooms-filter[open] > ul {
    opacity: 1;
    transform: translateY(0);
}
#filters .rooms-filter > ul > li {
    list-style: none;
    cursor: pointer;
    padding: 0.5em;
    text-align: center;
}
#filters .rooms-filter > ul > li.selected {
    background: var(--main-accent-color);
}
#filters .rooms-filter > ul > li.selected::after {
    content: "×";
    margin-left: 1em;
    position: absolute;
}

#schedule {
    transition: var(--transition);
    margin-bottom: 4em;
}

.schedule-heading {
    text-align: center;
}

.time-slot {
    grid-column: times;
}

.room-slot {
    display: block;
    padding: 10px 5px 5px;
    position: sticky;
    text-align: center;
    top: 0;
    z-index: 98;
    background-color: rgba(255, 255, 255, 0.9);
}

.room-slot.selected {
    background-color: var(--main-accent-color);
}

.room-slot,
.time-slot {
    color: var(--text-color-dark);
    font-size: 0.75em;
    font-weight: normal;
    display: none;
}
@supports (display: grid) {
    @media screen and (min-width: 700px) {
        .room-slot,
        .time-slot {
            display: block;
        }
    }
}

/* Small-screen & fallback styles */
.session {
    margin-bottom: 1em;
    padding: 0.5em;
    border-radius: 2px;
    font-size: 14px;
    transition: var(--transition);
    background-color: var(--background-color);
    border: 1px solid white;
    color: var(--text-color);
    cursor: pointer;
}
.session.hide {
    display: none;
}
.session:not(.room-all):hover {
    background-color: hsl(from var(--background-color) h s calc(l - 10));
}
.session.room-all {
    cursor: default;
}
@supports (display: grid) {
    @media screen and (min-width: 700px) {
        .session {
            margin: 0;
        }
        #filters {
            display: none;
        }
    }
}

.session-title,
.session-time,
.session-room,
.session-presenter {
    display: block;
}
.session-presenter {
    margin-top: 1em;
}

.session-title {
    margin: 0;
    font-size: 1.25em;
}

.session-title {
    color: var(--text-color-dark);
    font-weight: normal;
    text-decoration: none;
}

.room-all {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: var(--main-accent-color);
    box-shadow: none;
}
.room-all > span {
    display: none;
}

.modal {
    position: fixed;
    visibility: hidden;
    opacity: 0;
    transition: var(--transition);
    z-index: 100;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 2rem;
    background: rgba(0,0,0,0.8);
    cursor: default;
}
.modal-content * { cursor: text; }
.modal.show {
    visibility: visible;
    opacity: 1;
}
.modal-content {
    transform: translateY(100px);
    background: white;
    border-radius: 5px;
    max-width: var(--body-max-width);
    padding: 2rem 3rem;
    margin: auto;
    height: calc(100% - 6rem);
    overflow-y: auto;
    position: relative;
    transition: var(--transition);
}
.modal.show .modal-content {
    transform: translateY(0px);
}

.modal div > i {
    width: 2em;
    color: var(--main-accent-color);
    text-align: center;
}
.modal .summary p, .modal .bio p {
    white-space: break-spaces;
}
.modal .cross {
    position: fixed;
    font-weight: bold;
    font-size: larger;
    cursor: pointer;
    width: 3em;
    height: 3em;
    line-height: 3em;
    top: 2em;
    right: 2em;
    text-align: center;
    vertical-align: middle;
    border-radius: 100%;
    transition: var(--transition);
}
.modal .cross:hover {
    color: var(--main-accent-color);
    background-color: var(--background-color);
    transform: rotate(90deg);
}

#landscape-warning p { font-weight: bold; text-align: center; }

@media screen and (min-width: 700px) {
    #landscape-warning {
        display: none;
    }
}

/* Pacman Easter Egg Styles */
#pacman {
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: var(--pacman-color);
    border-radius: 50%;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 0 0, 50% 50%);
    z-index: 1000;
    animation: chomp 0.3s linear infinite;
}

@keyframes chomp {
    0% { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 0 0, 50% 50%); }
    50% { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
    100% { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 0 0, 50% 50%); }
}

.pacman-dot {
    position: absolute;
    width: 6px;
    height: 6px;
    background-color: var(--pacman-color);
    border-radius: 50%;
    z-index: 999;
}

.pacman-ghost {
    position: absolute;
    width: 18px;
    height: 18px;
    border-radius: 50% 50% 0 0;
    z-index: 999;
}

.pacman-ghost::before {
    content: "";
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 100%;
    height: 3px;
    background: inherit;
    clip-path: polygon(0% 0%, 25% 100%, 50% 0%, 75% 100%, 100% 0%);
}

.pacman-ghost::after {
    content: "";
    position: absolute;
    top: 10px;
    left: 4px;
    width: 5px;
    height: 5px;
    background: white;
    border-radius: 50%;
    box-shadow: 12px 0 0 white;
}

#pacman-score {
    position: fixed;
    top: 10px;
    right: 10px;
    font-size: 16px;
    font-weight: bold;
    color: var(--pacman-color);
    text-shadow: 1px 1px 2px black;
    z-index: 1000;
    background-color: rgba(0, 0, 0, 0.5);
    padding: 5px 10px;
    border-radius: 10px;
}

#pacman-grid {
    pointer-events: none;
}

#game-on-button {
    position: fixed;
    top: 20px;
    right: 20px;
    background-color: var(--pacman-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    padding: 10px 15px;
    cursor: pointer;
    z-index: 999;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    transform: rotate(5deg);
    animation: pulse 1.5s infinite alternate;
    transition: transform 0.2s, background-color 0.2s;
}

@keyframes pulse {
    0% {
        transform: rotate(5deg) scale(1);
    }
    100% {
        transform: rotate(5deg) scale(1.1);
    }
}

#game-on-button:hover {
    animation: none;
    transform: rotate(5deg) scale(1.1);
    background-color: #ffcc00;
}
