* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #121212;
    color: #f5f5f5;
    line-height: 1.6;
}

main {
    padding: 20px;
    min-height: calc(100vh - 140px);
}

.merchandise-container {
    width: 90%;
    max-width: 1200px;
    margin: 100px auto;
    padding-top: 80px;
    text-align: center;
}

.merchendise-title {
    margin-bottom: 40px;
    text-align: center;
    font-size: 48px;
    color: #fff;
    text-shadow: 0 2px 10px rgba(0, 170, 255, 0.5);
    position: relative;
    display: inline-block;
}

.merchendise-title:after {
    content: '';
    position: absolute;
    width: 60%;
    height: 4px;
    background: linear-gradient(90deg, transparent, #00aaff, transparent);
    bottom: -10px;
    left: 20%;
    border-radius: 2px;
}

.merchandise-grid {
    margin: 5% auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 30px;
}

.merchandise-card {
    background: linear-gradient(145deg, #1e1e1e, #2a2a2a);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4);
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid #333;
}

.merchandise-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 170, 255, 0.2);
    border-color: #00aaff;
}

.merchandise-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.merchandise-card:hover img {
    transform: scale(1.05);
}

.merchandise-card h3 {
    font-size: 18px;
    font-weight: 600;
    padding: 15px 15px 5px;
    color: #fff;
    text-align: center;
    margin: 0;
}

.merchandise-card h4 {
    font-size: 22px;
    font-weight: 700;
    padding: 5px 15px 10px;
    color: #00aaff;
    text-align: center;
}

.merchandise-card p {
    font-size: 14px;
    color: #aaa;
    padding: 0 15px 15px;
    text-align: center;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    color: white;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
    padding: 20px;
}

.modal.show {
    opacity: 1;
}

.modal-store {
    background: linear-gradient(145deg, #1a1a1a, #242424);
    border-radius: 20px;
    overflow: hidden;
    max-width: 700px;
    width: 100%;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
    animation: fadeInUp 0.4s ease;
    position: relative;
    border: 1px solid #333;
}

.modal-img {
    width: 100%;
    height: 320px;
    object-fit: cover;
}

.text {
    padding: 25px 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    color: #fff;
}

.text h3 {
    font-size: 28px;
    font-weight: bold;
    margin: 0;
    color: #fff;
}

#modalPrice {
    font-size: 24px !important;
    font-weight: bold !important;
    color: #00aaff !important;
    margin: 0 !important;
}

.text p {
    font-size: 16px;
    color: #ddd;
    line-height: 1.6;
    margin: 0;
}

.text span {
    color: #fff;
    font-weight: bold;
}

.btn-order {
    background: linear-gradient(45deg, #0088cc, #00aaff);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
    margin-top: 15px;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(0, 170, 255, 0.3);
    border: none;
}

.btn-order:hover {
    background: linear-gradient(45deg, #00aaff, #0088cc);
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(0, 170, 255, 0.4);
}

.close-store {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    background-color: rgba(0, 0, 0, 0.5);
    border: none;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    z-index: 2;
}

.close-store:hover {
    transform: scale(1.1);
    background-color: rgba(255, 255, 255, 0.9);
    color: #ff3333;
}

.no-merchandise {
    font-size: 20px;
    color: #aaa;
    text-align: center;
    margin: 60px auto;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    border: 1px dashed #444;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .merchandise-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }
    
    .merchendise-title {
        font-size: 36px;
    }
    
    .modal-img {
        height: 250px;
    }
}

@media (max-width: 480px) {
    .modal-store {
        width: 95%;
        max-height: 90vh;
        overflow-y: auto;
    }

    .merchandise-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 15px;
    }
    
    .merchendise-title {
        font-size: 28px;
    }
    
    .modal-img {
        height: 200px;
    }
    
    .text {
        padding: 15px 20px;
    }
    
    .text h3 {
        font-size: 24px;
    }
}