/* =========================================================
   MEDIA LIBRARY
   ========================================================= */

.media-content {
    padding-bottom: 30px;
}

.media-intro {
    text-align: center;
    margin-bottom: 20px;
}

.media-intro h2 {
    margin-bottom: 5px;
}


/* =========================
   FILTERS
   ========================= */

.media-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 7px;
    margin: 20px auto 25px;
}

.media-filter {
    padding: 6px 12px;

    font-family: Tahoma, Verdana, Arial, sans-serif;
    font-size: 11px;
    font-weight: bold;
    letter-spacing: 1px;

    color: #075b78;

    background: linear-gradient(
        to bottom,
        #ffffff,
        #d8f6fc
    );

    border: 2px outset #8bd3e4;
    border-radius: 3px;

    cursor: pointer;
}

.media-filter:hover {
    background: linear-gradient(
        to bottom,
        #ffffff,
        #aeeafa
    );
}

.media-filter:active,
.media-filter.active {
    border-style: inset;

    color: white;

    background: linear-gradient(
        to bottom,
        #38b8dc,
        #087da5
    );

    text-shadow:
        1px 1px 0 #075b78;
}

/* =========================
   ADVANCED FILTERS
   ========================= */

.media-filters {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;

    margin: 20px auto 25px;
    width: 100%;
}

.filter-group {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.filter-label {
    margin-right: 4px;

    font-family: "Courier New", monospace;
    font-size: 10px;
    font-weight: bold;
    letter-spacing: 1px;

    color: #075b78;
}


/* =========================
   TAG SELECT
   ========================= */

.genre-filter {
    min-width: 150px;

    padding: 5px 8px;

    font-family: Tahoma, Verdana, Arial, sans-serif;
    font-size: 11px;
    font-weight: bold;

    color: #075b78;

    background: linear-gradient(
        to bottom,
        #ffffff,
        #d8f6fc
    );

    border: 2px outset #8bd3e4;
    border-radius: 3px;

    cursor: pointer;
}

.genre-filter:hover {
    background: linear-gradient(
        to bottom,
        #ffffff,
        #aeeafa
    );
}

.genre-filter:focus {
    outline: 1px dotted #075b78;
    outline-offset: 2px;
}


/* =========================
   MEDIA GRID
   ========================= */

.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 18px;
    width: 100%;

    /* SCROLL */
    max-height: 650px;
    overflow-y: auto;
    overflow-x: hidden;

    /* Espacio para que las tarjetas no choquen con la scrollbar */
    padding: 5px 12px 15px 5px;
    box-sizing: border-box;
}

/* =========================
   MEDIA SCROLLBAR
   ========================= */

.media-grid::-webkit-scrollbar {
    width: 12px;
}

.media-grid::-webkit-scrollbar-track {
    background: #d9f8ff;
    border: 1px solid #75c9da;
    border-radius: 3px;
}

.media-grid::-webkit-scrollbar-thumb {
    background: linear-gradient(
        to bottom,
        #8ee8f7,
        #38b8dc,
        #087da5
    );
    border: 2px outset #b8f3ff;
    border-radius: 3px;
}

.media-grid::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(
        to bottom,
        #a8f2ff,
        #4cc8e8,
        #0a8eb8
    );
}


/* =========================
   MEDIA CARD
   ========================= */

.media-card {
    position: relative;

    background: linear-gradient(
        to bottom,
        #ffffff,
        #e4faff 55%,
        #b8eaf4
    );

    border: 2px solid #075b78;

    outline: 1px solid rgba(255,255,255,.9);

    box-shadow:
        3px 4px 0 #075b78,
        5px 6px 0 rgba(0,80,100,.25);

    border-radius: 5px;

    overflow: hidden;

    transition:
        transform .12s steps(2),
        filter .12s;
}

.media-card:hover {
    transform: translate(-2px, -2px);
    filter: brightness(1.05);
}


/* =========================
   COVER
   ========================= */

.media-cover {
    position: relative;

    width: 100%;
    aspect-ratio: 3 / 4;

    background:
        repeating-linear-gradient(
            0deg,
            #d9f8ff 0px,
            #d9f8ff 2px,
            #c3edf5 2px,
            #c3edf5 4px
        );

    border-bottom: 2px solid #075b78;

    overflow: hidden;
}

.media-cover img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
}


/* =========================
   INFO
   ========================= */

.media-info {
    padding: 10px;
}

.media-title {
    min-height: 32px;

    font-family:
        Tahoma,
        Verdana,
        Arial,
        sans-serif;

    font-size: 13px;
    font-weight: bold;

    color: #064e6c;

    margin-bottom: 7px;
}


/* =========================
   TYPE LABEL
   ========================= */

.media-type {
    display: inline-block;

    padding: 3px 6px;

    margin-bottom: 8px;

    font-family:
        "Courier New",
        monospace;

    font-size: 9px;
    font-weight: bold;

    border: 1px solid #075b78;
    border-radius: 2px;
}

.media-type.anime {
    background: #d9f7ff;
    color: #087395;
}

.media-type.manga {
    background: #e9e2ff;
    color: #60458c;
}

.media-type.movie {
    background: #fff0c9;
    color: #946200;
}


/* =========================
   TAGS
   ========================= */

.media-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.media-tags span {
    padding: 2px 5px;

    font-family:
        "Courier New",
        monospace;

    font-size: 8px;
    font-weight: bold;

    color: #075b78;

    background: #effcff;

    border: 1px dotted #4ca8be;
}



/* =========================
   +18 BADGE
   ========================= */

.adult-badge {
    position: absolute;

    top: 7px;
    right: 7px;

    padding: 4px 6px;

    background: #ff0000;
    color: #ffffff;

    border: 2px solid #ffffff;
    outline: 1px solid #111;

    font-family:
        "Courier New",
        monospace;

    font-size: 10px;
    font-weight: bold;

    box-shadow:
        2px 2px 0 rgba(0,0,0,.5);
}


/* =========================
   EMPTY
   ========================= */

.media-empty {
    padding: 25px;

    margin-top: 20px;

    text-align: center;

    font-family:
        "Courier New",
        monospace;

    font-size: 12px;
    font-weight: bold;

    color: #075b78;

    background: #e9fbff;

    border: 2px dashed #4ca8be;
}


/* =========================
   MOBILE
   ========================= */

@media (max-width: 600px) {

    .media-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;

        max-height: 600px;
    }

    .media-title {
        font-size: 11px;
    }
}

@media (max-width: 400px) {

    .media-grid {
        grid-template-columns: 1fr;
        max-height: 550px;
    }
}

