.shop-page {
    background: linear-gradient(180deg, #ffffff 0%, #ffffff 50%, #ffffff 100%);
    overflow-y: auto;
    min-height: 100vh;
}

.shop-main {
    position: relative;
    z-index: 1;
}

.shop-frame {
    max-width: 1200px;
    margin: 40px auto;
    padding: 50px 60px 60px;
    background: linear-gradient(145deg, #b0cce0 0%, #9ec0d8 40%, #8db4cd 100%);
    border: 1px solid rgba(100, 150, 200, 1);
    border-radius: 40px;
    box-shadow:
        0 0 60px rgba(255, 255, 255, 0.5),
        inset 0 0 100px rgba(255, 255, 255, 0.5);
    position: relative;
    overflow: visible;
}

.shop-frame::before {
    content: '✦ · ˚ ✧ · ˚ ✦ · ˚ ✧ · ˚ ✦ · ˚ ✧ · ˚ ✦';
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.8rem;
    color: #000000;
    letter-spacing: 0.3em;
    white-space: nowrap;
}

.shop-frame::after {
    content: '✦ · ˚ ✧ · ˚ ✦ · ˚ ✧ · ˚ ✦ · ˚ ✧ · ˚ ✦';
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.8rem;
    color: #000000;
    letter-spacing: 0.3em;
    white-space: nowrap;
}

.shop-frame .fairy-decorations {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
}

.shop-frame .fairy-star {
    position: absolute;
    color: #000000;
    font-size: 1.2rem;
    animation: shopTwinkle 3s ease-in-out infinite;
}

.shop-frame .fairy-star:nth-child(1) { top: 10%; left: 5%; animation-delay: 0s; }
.shop-frame .fairy-star:nth-child(2) { top: 20%; right: 8%; animation-delay: 0.5s; }
.shop-frame .fairy-star:nth-child(3) { bottom: 25%; left: 3%; animation-delay: 1s; }
.shop-frame .fairy-star:nth-child(4) { bottom: 15%; right: 5%; animation-delay: 1.5s; }
.shop-frame .fairy-star:nth-child(5) { top: 50%; left: 2%; animation-delay: 2s; }
.shop-frame .fairy-star:nth-child(6) { top: 40%; right: 3%; animation-delay: 2.5s; }

@keyframes shopTwinkle {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 0.8; transform: scale(1.2); }
}

.shop-frame .archive-header {
    text-align: center;
    margin-bottom: 10px;
    position: relative;
}

.shop-archive-title {
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 4rem;
    color: #000000;
    margin: 0;
    font-weight: 300;
    letter-spacing: 0.15em;
    text-shadow: 0 2px 10px rgba(100, 150, 200, 1);
}

.shop-frame .archive-header::after {
    content: '';
    display: block;
    width: 200px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(100, 150, 200, 0.5), transparent);
    margin: 15px auto 0;
}

.shop-subtitle {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 1rem;
    color: #000000;
    margin: 10px 0 0 0;
    letter-spacing: 0.05em;
    text-align: center;
}

.shop-layout {
    display: flex;
    gap: 40px;
    margin-top: 20px;
    align-items: flex-start;
}

.products-scatter {
    position: relative;
    flex: 1;
    min-height: 700px;
}

.shop-cart-area {
    width: 450px;
    flex-shrink: 0;
    position: sticky;
    top: 120px;
}

.scatter-item {
    position: absolute;
    cursor: pointer;
    transition: transform 0.3s ease, filter 0.3s ease;
    text-align: center;
}

.scatter-item:hover {
    filter: brightness(1.05);
    z-index: 10;
}

.scatter-item img {
    display: block;
    max-width: 150%;
    height: auto;
    filter: drop-shadow(0 8px 20px rgba(0,0,0,0.12));
}

.scatter-item .scatter-icon {
    font-size: 5rem;
    display: block;
    filter: drop-shadow(0 8px 20px rgba(0,0,0,0.12));
}

.scatter-1 {
    top: -150px;
    left: 0;
    width: 185px;
    transform: rotate(-2deg);
}

.scatter-2 {
    top: -110px;
    left: 260px;
    width: 230px;
    transform: rotate(1deg);
}

.scatter-3 {
    top: 160px;
    left: 0;
    width: 180px;
    transform: rotate(-1deg);
}

.scatter-4 {
    top: 120px;
    left: 300px;
    width: 170px;
    transform: rotate(2.5deg);
}

.scatter-5 {
    top: 360px;
    left: 0;
    width: 200px;
    transform: rotate(1.5deg);
}

.scatter-6 {
    top: 370px;
    left: 375px;
    width: 170px;
    transform: rotate(-2deg);
}

.scatter-1:hover { transform: rotate(-2deg) scale(1.06); }
.scatter-2:hover { transform: rotate(1deg) scale(1.06); }
.scatter-3:hover { transform: rotate(-1deg) scale(1.06); }
.scatter-4:hover { transform: rotate(2.5deg) scale(1.06); }
.scatter-5:hover { transform: rotate(1.5deg) scale(1.06); }
.scatter-6:hover { transform: rotate(-2deg) scale(1.06); }

.cart-box {
    background: linear-gradient(145deg, rgba(255,255,255,0.5) 0%, rgba(200, 225, 245, 0.3) 100%);
    border-radius: 25px;
    padding: 25px;
    border: 1px solid rgba(100, 150, 200, 0.25);
    box-shadow:
        0 10px 40px rgba(100, 150, 200, 0.1),
        inset 0 0 30px rgba(255, 255, 255, 0.5);
}

.cart-title {
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 1.6rem;
    color: #000000;
    margin: 0 0 15px 0;
    letter-spacing: 0.1em;
    font-weight: 300;
    text-align: center;
}

.cart-items {
    min-height: 50px;
}

.cart-empty {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.85rem;
    color: #000000;
    text-align: center;
    padding: 15px 0;
    margin: 0;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(100, 150, 200, 0.15);
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.8rem;
    color: #000000;
    display: block;
}

.cart-item-qty {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.7rem;
    color: #000000;
}

.cart-item-price {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.85rem;
    color: #000000;
    font-weight: 600;
    margin-right: 8px;
}

.cart-item-remove {
    background: none;
    border: none;
    color: #000000;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0 4px;
    transition: color 0.2s;
}

.cart-item-remove:hover {
    color: #000000;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    margin-top: 8px;
    border-top: 2px solid rgba(100, 150, 200, 0.3);
}

.total-label {
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 1.1rem;
    color: #000000;
    letter-spacing: 0.1em;
}

.total-amount {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 1.2rem;
    color: #000000;
    font-weight: 600;
}

.checkout-btn {
    width: 100%;
    padding: 12px;
    margin-top: 12px;
    background: linear-gradient(145deg, rgba(100, 150, 200, 0.9) 0%, rgba(80, 130, 180, 0.9) 100%);
    color: #000000;
    border: 1px solid rgba(100, 150, 200, 0.4);
    border-radius: 15px;
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 1rem;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(100, 150, 200, 0.15);
}

.checkout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(100, 150, 200, 0.25);
}

.product-popup-overlay,
.checkout-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.product-popup-overlay.active,
.checkout-popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.product-popup {
    background: linear-gradient(145deg, #d6e8f5 0%, #c5dff0 100%);
    border-radius: 25px;
    padding: 40px;
    max-width: 550px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    animation: popupSlideIn 0.3s ease;
    border: 1px solid rgba(100, 150, 200, 0.4);
}

.checkout-popup {
    background: linear-gradient(145deg, #d6e8f5 0%, #c5dff0 100%);
    border-radius: 25px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    animation: popupSlideIn 0.3s ease;
    border: 1px solid rgba(100, 150, 200, 0.4);
}

@keyframes popupSlideIn {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.popup-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    background: none;
    border: none;
    color: #000000;
    cursor: pointer;
    transition: color 0.2s ease;
    line-height: 1;
}

.popup-close:hover {
    color: #000000;
}

.popup-content {
    text-align: center;
}

.popup-image {
    width: 150px;
    height: 150px;
    margin: 0 auto 20px;
    border-radius: 18px;
    background: linear-gradient(145deg, rgba(255,255,255,0.7) 0%, rgba(200, 225, 245, 0.5) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
    border: 1px solid rgba(100, 150, 200, 0.3);
    box-shadow: inset 0 0 20px rgba(255, 255, 255, 0.4);
    overflow: hidden;
}

.popup-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 18px;
    padding: 5px;
}

.popup-title {
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 1.8rem;
    color: #000000;
    margin: 0 0 8px 0;
    letter-spacing: 0.1em;
    font-weight: 300;
}

.popup-price {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 1.4rem;
    color: #000000;
    margin: 0 0 15px 0;
    font-weight: 600;
}

.popup-description {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.95rem;
    color: #000000;
    margin: 0 0 10px 0;
    line-height: 1.6;
}

.popup-note {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.85rem;
    color: #000000;
    margin: 0 0 20px 0;
    font-style: italic;
}

.size-selector {
    margin-bottom: 15px;
}

.size-options {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.size-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid rgba(100, 150, 200, 0.3);
    background: rgba(255, 255, 255, 0.5);
    color: #000000;
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.size-btn:hover {
    background: rgba(255, 255, 255, 0.8);
    border-color: rgba(100, 150, 200, 0.6);
}

.size-btn.active {
    background: rgba(100, 150, 200, 0.9);
    color: #000000;
    border-color: rgba(80, 130, 180, 1);
}

.add-to-cart-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.popup-quantity {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

.qty-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(100, 150, 200, 0.3);
    background: rgba(255, 255, 255, 0.6);
    color: #000000;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover {
    background: rgba(255, 255, 255, 0.8);
    border-color: rgba(100, 150, 200, 0.6);
}

.qty-number {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 1.2rem;
    color: #000000;
    min-width: 30px;
    text-align: center;
}

.add-to-cart-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(145deg, rgba(100, 150, 200, 0.9) 0%, rgba(80, 130, 180, 0.9) 100%);
    color: #000000;
    border: 1px solid rgba(100, 150, 200, 0.4);
    border-radius: 15px;
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(100, 150, 200, 0.15);
}

.add-to-cart-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(100, 150, 200, 0.25);
}

.checkout-popup-title {
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 2rem;
    color: #000000;
    margin: 0 0 20px 0;
    letter-spacing: 0.1em;
    font-weight: 300;
    text-align: center;
}

.checkout-summary {
    margin-bottom: 15px;
}

.checkout-summary-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.9rem;
    color: #000000;
    border-bottom: 1px solid rgba(100, 150, 200, 0.15);
}

.checkout-total {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    margin-bottom: 20px;
    border-top: 2px solid rgba(100, 150, 200, 0.3);
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 1.3rem;
    color: #000000;
    font-weight: 600;
}

.checkout-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.checkout-form input,
.checkout-form textarea {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.95rem;
    padding: 12px 15px;
    border: 1px solid rgba(100, 150, 200, 0.25);
    border-radius: 12px;
    outline: none;
    background: rgba(255, 255, 255, 0.5);
    color: #000000;
    transition: border-color 0.2s ease;
}

.checkout-form input:focus,
.checkout-form textarea:focus {
    border-color: rgba(100, 150, 200, 0.6);
    background: rgba(255, 255, 255, 0.7);
}

.checkout-form textarea {
    min-height: 60px;
    resize: vertical;
}

.place-order-btn {
    padding: 14px;
    background: linear-gradient(145deg, rgba(100, 150, 200, 0.9) 0%, rgba(80, 130, 180, 0.9) 100%);
    color: #000000;
    border: 1px solid rgba(100, 150, 200, 0.4);
    border-radius: 15px;
    font-family: 'DreamerTM', 'Times New Roman', Georgia, serif;
    font-size: 1.1rem;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 5px;
}

.place-order-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(100, 150, 200, 0.25);
}

.checkout-disclaimer {
    font-family: 'OffsetTM', 'Pestetrial', sans-serif;
    font-size: 0.75rem;
    color: #000000;
    text-align: center;
    margin: 15px 0 0 0;
    line-height: 1.4;
}

@media (max-width: 768px) {
    .shop-frame {
        margin: 15px;
        padding: 30px 25px;
        border-radius: 25px;
    }

    .shop-layout {
        flex-direction: column;
    }

    .products-scatter {
        position: static;
        min-height: auto;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
        padding: 10px;
        justify-items: center;
        align-items: start;
        max-width: 400px;
        margin: 0 auto;
    }

    .scatter-item {
        position: static !important;
        transform: none !important;
        width: 100% !important;
        top: auto !important;
        left: auto !important;
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }

    .scatter-item:hover {
        transform: scale(1.05) !important;
    }

    .scatter-item img {
        max-width: 140px;
        margin: 0 auto;
        display: block;
    }

    .shop-cart-area {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .shop-frame {
        margin: 10px;
        padding: 25px 18px;
    }

    .products-scatter {
        gap: 20px;
    }

    .scatter-item img {
        max-width: 110px;
    }

    .product-popup,
    .checkout-popup {
        padding: 25px;
    }
}
