html,
body {
    margin: 0;
    background: #000;
    color: #fff;
    font-family: system-ui, sans-serif;
}

#slideshow {
    position: fixed;
    inset: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
}

#photo-stage {
    position: relative;
    display: grid;
    place-items: center;
}

#photo-stage img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

#empty-message {
    padding: 1rem;
    text-align: center;
}

#photo-footer {
    min-width: 0;
    padding: 0.25rem 0.75rem;
    color: #aaa;
    text-align: center;
    transform: translateY(calc(-1 * var(--photo-space-below, 0px)));
}

#photo-caption {
    max-height: 4.5em;
    margin: 0;
    overflow: auto;
    overflow-wrap: anywhere;
    font-size: 0.875rem;
    line-height: 1.5;
}

#photo-controls {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.125rem 0.5rem;
}

#photo-controls button {
    min-height: 2rem;
    padding: 0 0.625rem;
    border: 0;
    border-radius: 0.25rem;
    background: transparent;
    color: #aaa;
    font: inherit;
    font-size: 0.875rem;
}

#photo-controls button:enabled {
    cursor: pointer;
}

#photo-controls button:enabled:hover {
    background: #222;
    color: #ddd;
}

#photo-controls button:focus-visible {
    outline: 1px solid #aaa;
}

#photo-controls button:disabled {
    color: #585858;
}
