/* Reset CSS */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body Styling */
body {
    background-color: #071824;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Content Wrapper */
.content-wrapper {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Filter and Card Containers */
.filter-container, .card-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    box-sizing: border-box;
}

/* Filter Container Styling */
.filter-container {
    margin-top: 20px;
    padding-top: 1rem;
    padding-bottom: 1rem;
    background-color: #0f212e;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Row Layouts */
.row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.row-1 .button-group,
.row-2 .input-group {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}
/* Second Row Button and Input Styling for Consistent Width */
.row-2 .input-group input,
.row-2 .input-group select {
    min-width: 180px; /* Set a minimum width for uniformity */
}
.button-group button.active {
    background-color: #344a5e; /* Hover color used as active color */
    color: #ffffff; /* Keep text white for readability */
}

.row-1 .search-group {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    justify-content: flex-end;
    flex-grow: 1;
}

/* Button Styling in Options Bar */
button, input, select {
    padding: 0.5rem;
    border: 1px solid #2a4859;
    border-radius: 4px;
    font-size: 12px;
    background-color: #1e2a38;
    color: #ffffff;
    cursor: pointer;
    font-family: Arial, sans-serif;
    height: 30px; /* Set a fixed height for uniformity */
    box-sizing: border-box;
}

button:hover {
    background-color: #344a5e;
}

.search-group input {
    width: 150px;
}

/* Placeholder Text Styling */
input::placeholder, select::placeholder {
    color: #2a4859;
    opacity: 1;
}

/* Labels for Card Elements */
.labels {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
    position: relative;
    min-height: 20px; /* Ensures consistent space based on the info-label */
}

.label {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    color: white;
    cursor: pointer;
    pointer-events: auto;
    z-index: 10;
}

.label.new { background-color: #4CAF50; }
.label.hot { background-color: #f44336; }
.label.featured { background-color: #607d8b; }

/* Info Label Styling */
.label.info-label {
    color: #0271dc;
    border: 1px solid #0271dc;
    position: absolute;
    top: 0;
    right: 0;
    border-radius: 4px;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

/* Card Container Grid */
.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    padding: 20px 0;
    grid-auto-flow: dense; /* Ensures that cards automatically fill gaps */
}

/* Card Styling */
.card {
    background-color: #071824;
    border: 1px solid #0f212e;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    color: #fff;
    font-family: Arial, sans-serif;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
    box-sizing: border-box;
    transition: transform 0.2s ease-out;
    min-height: 300px;
}

/* Image Placeholder */
.image-placeholder {
    width: 100%;
    height: 200px;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 4px;
    margin-bottom: 20px;
    margin-top: -30px;
    flex-shrink: 0;
    z-index: 10;
    transition: transform 0.2s ease-out;
}

/* Product Name and Price Info */
.product-name {
    font-size: 12px;
    font-weight: bold;
}

.product-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.price {
    background-color: #eee;
    color: #333;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 12px;
    position: absolute;
    bottom: 16px;
    right: 16px;
    cursor: pointer;
    z-index: 10;
}

/* Rarity Indicators */
.rarity {
    display: flex;
    gap: 4px;
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
}

.rarity .common { background-color: #808080; }
.rarity .uncommon { background-color: #00FF00; }
.rarity .rare { background-color: #0000FF; }
.rarity .epic { background-color: #800080; }
.rarity .legendary { background-color: #FFD700; }

/* 3D Shine Effect */
.atvImg-shine {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 8px;
}

.atvImg-layer {
    pointer-events: none;
    z-index: 1;
}

/* Hover Effects for Labels and Other Elements */
.label, .price, .product-name, .info-label {
    cursor: pointer;
    transition: transform 0.1s ease;
}

.label:hover, .price:hover, .product-name:hover, .info-label:hover {
    transform: scale(1.08);
}

/* Middle Placeholder for Image Hover Effect */
.middle-placeholder {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50%;
    height: 40%;
    cursor: pointer;
    opacity: 0;
    background-color: transparent;
    z-index: 100;
    transform-origin: center;
}
