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

:root {
    --primary-dark: #1a2332;
    --secondary-dark: #2d3e50;
    --accent-gold: #d4af37;
    --accent-copper: #b87333;
    --light-bg: #f8f9fa;
    --card-bg: #ffffff;
    --text-dark: #2c3e50;
    --text-light: #ecf0f1;
    --border-light: #e0e6ed;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.16);
}

body {
    font-family: 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #1a2332 0%, #2d3e50 50%, #1a2332 100%);
    background-attachment: fixed;
    min-height: 100vh;
    color: var(--text-dark);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--secondary-dark) 100%);
    box-shadow: var(--shadow-md);
    padding: 40px 0;
    margin-bottom: 40px;
    border-bottom: 3px solid var(--accent-gold);
}

header h1 {
    font-size: 3.5em;
    color: var(--text-light);
    text-align: center;
    margin-bottom: 10px;
    font-weight: 300;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.tagline {
    text-align: center;
    font-size: 1.3em;
    color: var(--accent-gold);
    font-style: italic;
    font-weight: 300;
}

/* Information Box */
.info-box {
    background: linear-gradient(135deg, var(--card-bg) 0%, #fafbfc 100%);
    padding: 30px 40px;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--accent-gold);
}

.info-box h2 {
    color: var(--primary-dark);
    font-size: 1.8em;
    margin-bottom: 15px;
    font-weight: 400;
}

.info-box p {
    color: var(--text-dark);
    line-height: 1.8;
    font-size: 1.1em;
    margin-bottom: 10px;
}

.info-box strong {
    color: var(--accent-copper);
    font-weight: 600;
}

/* Filters */
.filters {
    background: var(--card-bg);
    padding: 25px 30px;
    border-radius: 12px;
    margin-bottom: 30px;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
    box-shadow: var(--shadow-md);
}

.search-box {
    flex: 1;
    min-width: 250px;
}

.search-box input {
    width: 100%;
    padding: 14px 20px;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    font-size: 1em;
    transition: all 0.3s;
    background: var(--light-bg);
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent-gold);
    background: white;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.sort-box {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sort-box label {
    font-weight: 600;
    color: var(--text-dark);
    white-space: nowrap;
}

.sort-box select {
    padding: 12px 18px;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    font-size: 1em;
    background: var(--light-bg);
    cursor: pointer;
    transition: all 0.3s;
    color: var(--text-dark);
}

.sort-box select:focus {
    outline: none;
    border-color: var(--accent-gold);
    background: white;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.sort-box select:hover {
    border-color: var(--accent-copper);
}

/* Gallery */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    padding-bottom: 60px;
}

.loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px;
    font-size: 1.5em;
    color: var(--text-light);
    font-weight: 300;
}

.radio-card {
    background: var(--card-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid var(--border-light);
}

.radio-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-gold);
}

.radio-card-image {
    width: 100%;
    height: 280px;
    object-fit: cover;
    background: var(--light-bg);
}

.radio-card-content {
    padding: 24px;
}

.radio-card-title {
    font-size: 1.3em;
    margin-bottom: 12px;
    color: var(--primary-dark);
    font-weight: 500;
}

.radio-card-description {
    color: #6c757d;
    margin-bottom: 18px;
    font-size: 0.95em;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.radio-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 18px;
    border-top: 1px solid var(--border-light);
}

.radio-card-price {
    font-size: 1.6em;
    color: var(--accent-copper);
    font-weight: 600;
}

.radio-card-id {
    font-size: 0.9em;
    color: #95a5a6;
    font-weight: 500;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(26, 35, 50, 0.92);
    overflow-y: auto;
    backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--card-bg);
    margin: 3% auto;
    padding: 0;
    border-radius: 16px;
    max-width: 1100px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    position: relative;
    animation: modalSlideIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid var(--accent-gold);
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close {
    position: absolute;
    right: 20px;
    top: 20px;
    color: #95a5a6;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: white;
    transition: all 0.3s;
    box-shadow: var(--shadow-sm);
}

.close:hover,
.close:focus {
    color: var(--accent-copper);
    background: var(--light-bg);
    transform: rotate(90deg);
}

.modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 50px 40px;
}

.modal-images {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.main-image-container {
    position: relative;
    background: var(--light-bg);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

#modalMainImage {
    width: 100%;
    height: auto;
    display: block;
    max-height: 500px;
    object-fit: contain;
}

.image-label {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(26, 35, 50, 0.85);
    color: var(--accent-gold);
    padding: 8px 18px;
    border-radius: 20px;
    font-size: 0.9em;
    font-weight: 500;
    backdrop-filter: blur(4px);
}

.thumbnail-container {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.thumbnail {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 10px;
    cursor: pointer;
    border: 3px solid transparent;
    transition: all 0.3s;
    box-shadow: var(--shadow-sm);
}

.thumbnail:hover {
    border-color: var(--accent-copper);
    transform: scale(1.05);
}

.thumbnail.active {
    border-color: var(--accent-gold);
    box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.3);
}

.modal-info {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.modal-info h2 {
    font-size: 2.2em;
    color: var(--primary-dark);
    margin-bottom: 10px;
    font-weight: 400;
}

.modal-info p {
    color: #6c757d;
    line-height: 1.9;
    font-size: 1.1em;
}

.price-tag {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--secondary-dark) 100%);
    color: white;
    padding: 24px 28px;
    border-radius: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--accent-gold);
}

.price-label {
    font-size: 1.2em;
    color: var(--text-light);
    font-weight: 300;
}

.price {
    font-size: 2.2em;
    font-weight: 600;
    color: var(--accent-gold);
}

.item-id {
    color: #95a5a6;
    font-size: 1em;
    padding: 12px 0;
    border-top: 1px solid var(--border-light);
}

.item-id span:first-child {
    font-weight: 500;
}

/* Footer */
footer {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--secondary-dark) 100%);
    padding: 30px 0;
    text-align: center;
    color: var(--text-light);
    margin-top: 60px;
    border-top: 3px solid var(--accent-gold);
}

footer p {
    font-size: 0.95em;
    font-weight: 300;
}

/* Responsive Design */
@media (max-width: 768px) {
    header h1 {
        font-size: 2.2em;
    }

    .info-box {
        padding: 20px 25px;
    }

    .info-box h2 {
        font-size: 1.5em;
    }

    .filters {
        flex-direction: column;
        align-items: stretch;
        padding: 20px;
    }

    .sort-box {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }

    .sort-box select {
        width: 100%;
    }

    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }

    .modal-body {
        grid-template-columns: 1fr;
        padding: 30px 20px;
        gap: 30px;
    }

    .modal-content {
        margin: 20px;
        max-width: calc(100% - 40px);
    }

    #modalMainImage {
        max-height: 300px;
    }

    .modal-info h2 {
        font-size: 1.8em;
    }
}

.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px;
    font-size: 1.5em;
    color: var(--text-light);
    font-weight: 300;
}
