@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

/* General Styles */
body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #121212;
    color: white;
}

header {
    background: #1E1E1E;
    padding: 20px;
    text-align: center;
    border-bottom: 2px solid #333;
}

header a {
    color: #1E90FF;
    text-decoration: none;
    margin: 0 15px;
}

header a:hover {
    text-decoration: underline;
}

.container {
    padding: 20px;
    margin: auto;
}

.search-container {
    text-align: center;
    margin-bottom: 20px;
}

#searchBar {
    width: 100%; /* Full width on small screens */
    padding: 10px;
    font-size: 16px;
    box-sizing: border-box; /* Include padding and border in the width */
    background-color: #2C2C2C;
    color: white;
    border: 1px solid #444;
}
.dropdown-container {
    display: flex;
    justify-content: center;
    gap: 20px; /* Space between the dropdowns */
    margin-bottom: 20px; /* Space below the dropdowns */
    align-items: center; /* Ensure dropdowns are aligned center vertically */
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
}

.dropdown-container select {
    padding: 10px;
    font-size: 16px;
    box-sizing: border-box; /* Include padding and border in width */
    flex: 1 1 auto; /* Allow dropdowns to grow and shrink as needed */
    background-color: #2C2C2C;
    color: white;
    border: 1px solid #444;
}

#seriesFilter,
#rarityFilter,
#bloomTypeFilter {
    margin-top: 20px;
    padding: 10px;
    font-size: 16px;
    background-color: #2C2C2C;
    color: white;
    border: 1px solid #444;
}

#cardList {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.card {
    border: 1px solid #333;
    padding: 10px;
    margin: 10px;
    border-radius: 5px;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.3);
    background-color: #1E1E1E;
    max-width: 200px;
    display: inline-block;
    vertical-align: top;
    cursor: pointer;
    transition: transform 0.2s; /* Smooth scaling effect */
}
.card:hover {
    transform: scale(1.02); /* Slight zoom effect on hover */
}
.card img {
    max-width: 100%;
    height: auto; /* Maintain aspect ratio */
}

.card p {
    margin: 0;
    padding: 5px 0;
    font-weight: bold;
}

.colored-yes {
    color: #ff6347;
    font-weight: bold;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: #1E1E1E;
    border-radius: 5px;
    padding: 20px;
    max-width: 1000px;
    width: 90%;
    display: flex;
    flex-direction: row;
    align-items: center;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    overflow: hidden; /* Ensure content does not overflow out of the modal */
}

.modal-content img {
    max-width: 300px;
    height: auto;
    margin-right: 20px;
}

.modal-content div {
    font-family: Arial, sans-serif;
}

.modal-content p {
    margin: 0;
    padding: 5px 0;
}

.modal-content h3 {
    margin: 0 0 0px 0;
    font-size: 24px;
}

.modal-content strong {
    font-weight: bold;
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 24px;
    cursor: pointer;
    z-index: 1001; /* Ensure it's above other content */
}

.skills h3 {
    margin-top: 5px;
}

.hidden {
    display: none;
}

/* Badge Styles */
.badge {
    font-weight: bold;
}

.badge.foils {
    color: #888888; /* Least important */
}

.badge.full-art {
    color: #007bff; 
}

.badge.alt-art {
    color: #9b59b6; 
}

.badge.signed { 
    color: #e74c3c; /* Most important */
}
/* Loading Indicator Styles */
#loadingIndicator {
    text-align: center;
    padding: 20px;
    font-size: 18px;
    color: #AAA;
    display: none; /* Initially hidden */
}

/* Media Query for Mobile Devices */
@media (max-width: 768px) {
    .modal-content {
        width: 100%;
        height: 100%;
        margin: 0;
        border-radius: 0;
        max-height: 100vh;
        overflow-y: auto;
        display: flex;
        flex-direction: column; /* Stack content vertically on mobile */
    }
    
    .modal-content img {
        margin: 0 0 20px 0; /* Margin below the image */
        max-width: 90%; /* Ensure image takes full width */
        height: auto; /* Maintain aspect ratio */
        max-height: 60vh; /* Limit image height to 60% of viewport height */
        object-fit: contain; /* Ensure the image fits within its container */
    }

    #cardList {
        flex-direction: column; /* Stack cards vertically on small screens */
        align-items: center; /* Center cards */
    }

    .card {
        max-width: 90%; /* Increase card width on small screens */
    }

    #searchBar {
        font-size: 14px; /* Slightly smaller font size on small screens */
    }

    .dropdown-container {
        display: flex;
        flex-direction: column; /* Stack dropdowns vertically on small screens */
        align-items: stretch; /* Ensure dropdowns take full width */
    }

    .dropdown-container select {
        width: 100%; /* Full width for each dropdown on small screens */
        margin-bottom: 10px; /* Space between dropdowns */
    }
}
html {
    scroll-behavior: smooth;
}
/* Lazy Loading Styles */
img.lazy-load {
    opacity: 0;
    transition: opacity 0.3s ease; /* Smooth transition for fading in images */
}

img.lazy-load[src] {
    opacity: 1; /* Fully visible when the src is set */
}

.dropdown-container select option:checked {
    background-color: #1E90FF;
    color: white;
}
