/* Version: movie-wall.css */

:root {
    --max-wall-width: 100%;
    --num-cols: 3;
    --min-col-width: 80px;
    --max-col-width: 300px;
}

main.grid {
    max-width: var(--max-wall-width);
    line-height: 0;
    display: grid;
    grid-template-columns: repeat(var(--num-cols), minmax(var(--min-col-width), 1fr));
    gap: 2px;
}

main.grid .almost-ready {
    grid-column: 1 / -1;
}

article.grid-item {
    max-width: var(--max-col-width);
    margin: 0;
    position: relative;
}

article.grid-item img.image-grid-item {
    width: 100%;
    height: auto;
    aspect-ratio: 2/3;
}

article.grid-item div.text-movies-grid-item {
    width: 100%;
    aspect-ratio: 2/3;
    background: none;
    text-align: center;
    font-family: Impact;
    font-size: calc(1em + 0.5vw);
    line-height: 1.2;
    word-wrap: break-word;
    white-space: normal;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-sizing: border-box;
    padding: 1rem;
}

article.grid-item div.section-title {
    color: #BEBEBE;
}

/* ----- overlays ----------------------------------------------------------- */

header table tr td:nth-child(1) {
    padding-left: 0px;
    padding-right: 2px;
    text-align: right;
}

header table tr td:nth-child(2) {
    padding-left: 0px;
    padding-right: 0px;
}

.myRatingOverlay,
.ratingOverlay,
.seriesOverlay,
.streamOverlay,
.yearOverlay,
.collectionOverlay {
    position: absolute;
}

.myRatingOverlay,
.ratingOverlay,
.yearOverlay {
    font-size: calc(1em + 0.5vw);
    font-weight: bold;
    line-height: 1.6;
    padding-left: 5%;
    padding-right: 5%;
    padding-top: 1%;
    padding-bottom: 1%;
    border-radius: 40%;
}

.myRatingOverlay,
.ratingOverlay {
    color: white;
}

.yearOverlay {
    background-color: rgba(0, 0, 0, 0.6);
}

.yearOverlay {
    color: yellow;
}

.myRatingOverlay {
    bottom: 0;
    right: 0;
}

.ratingOverlay {
    bottom: 0;
    left: 0;
}

.seriesOverlay {
    width: 7vw;
    max-width: 64px;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
}

.streamOverlay {
    height: 2.5vh;
    max-height: 64px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.yearOverlay {
    top: 0;
    left: 0;
}

.yearOverlay span.futureReleaseDate {
    font-size: 0.75em;
    color: white;    
}

.yearOverlay span.futureEstimatedReleaseDate {
    font-size: 0.75em;
    color: #FFD1DC;
}

.collectionOverlay {
    max-width: 24px;
    top: 0;
    right: 0;
}

article img.full-flag {
    width: 64px;
    height: auto;
    vertical-align: middle;
}

/* ----- user options  ------------------------------------------------------ */

#showTable td {
    padding-right: 10px;
}

#sortAndFilter summary .header-expand-button {
    background-color: lightgreen;
}

#sortAndFilter p {
    padding-bottom: 0.5rem;
}

#viewTitle:empty {
    display: none;
}

@media (min-width: 430px) { :root { --min-col-width: 130px; } }
@media (min-width: 900px) { :root { --max-wall-width: 97%; --num-cols: 4; --min-col-width: 133px; } }
@media (min-width: 1200px) { :root { --num-cols: 5; } }
@media (min-width: 1500px) { :root { --num-cols: 6; } }
@media (min-width: 1800px) { :root { --num-cols: 7; } }
@media (min-width: 2100px) { :root { --num-cols: 8; } }
@media (min-width: 2400px) { :root { --num-cols: 9; } }
@media (min-width: 2700px) { :root { --num-cols: 10; } }
@media (min-width: 3000px) { :root { --num-cols: 11; } }
@media (min-width: 3300px) { :root { --num-cols: 12; } }
@media (min-width: 3600px) { :root { --num-cols: 13; } }