/* Midnight Surprises - Design System */

/* Base styles */
body {
    font-family: "Quicksand", sans-serif;
    background-color: #F8F4F4;
    color: #5D2A42;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: "Fredoka", sans-serif;
}

/* Organic Shapes */
.organic-squircle {
    border-radius: 35% 65% 65% 35% / 45% 45% 55% 55%;
}

.organic-squircle-alt {
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
}

.hero-squircle {
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
}

.card-squircle {
    border-radius: 24px;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #F8F4F4;
}

::-webkit-scrollbar-thumb {
    background: #6B2D5C;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #5D2A42;
}

/* Animations */
@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes sparkle {

    0%,
    100% {
        opacity: 0.3;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.2);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes flowBeam {
    0% {
        background-position: 0% 50%;
    }

    100% {
        background-position: 200% 50%;
    }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-sparkle {
    animation: sparkle 2s ease-in-out infinite;
}

.animate-slide-up {
    animation: slideUp 0.6s ease-out forwards;
}

.animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

/* Staggered animations */
.stagger-1 {
    animation-delay: 0.1s;
}

.stagger-2 {
    animation-delay: 0.2s;
}

.stagger-3 {
    animation-delay: 0.3s;
}

.stagger-4 {
    animation-delay: 0.4s;
}

.stagger-5 {
    animation-delay: 0.5s;
}

.stagger-6 {
    animation-delay: 0.6s;
}

.stagger-7 {
    animation-delay: 0.7s;
}

.stagger-8 {
    animation-delay: 0.8s;
}

/* Button styles */
.btn-primary {
    background: linear-gradient(135deg, #6B2D5C 0%, #5A2550 100%);
    color: white;
    padding: 1rem 2rem;
    border-radius: 9999px;
    font-weight: 700;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(107, 45, 92, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(107, 45, 92, 0.4);
}

.btn-secondary {
    background: white;
    color: #6B2D5C;
    padding: 1rem 2rem;
    border-radius: 9999px;
    font-weight: 700;
    border: 2px solid rgba(107, 45, 92, 0.2);
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: #F8F4F4;
    border-color: #6B2D5C;
}

/* Card styles */
.product-card {
    background: white;
    border-radius: 24px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(93, 42, 66, 0.08);
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(93, 42, 66, 0.15);
}

.product-card img {
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover img {
    transform: scale(1.08);
}

/* Badge styles */
.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.badge-photo {
    background: #F3E8FF;
    color: #7C3AED;
}

.badge-text {
    background: #FEF3C7;
    color: #D97706;
}

.badge-time {
    background: #DCFCE7;
    color: #16A34A;
}

/* Category card */
.category-card {
    background: white;
    border-radius: 32px;
    padding: 2rem;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(93, 42, 66, 0.08);
    cursor: pointer;
}

.category-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(93, 42, 66, 0.15);
}

.category-card .icon-wrapper {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    transition: transform 0.3s ease;
}

.category-card:hover .icon-wrapper {
    transform: scale(1.1) rotate(5deg);
}

/* Step card */
.step-card {
    text-align: center;
    padding: 2rem;
}

.step-number {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #6B2D5C 0%, #5A2550 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    margin: 0 auto 1.5rem;
}

.how-flow-line {
    position: absolute;
    left: 8%;
    right: 8%;
    top: 2.25rem;
    height: 2px;
    border-radius: 9999px;
    background: linear-gradient(90deg, rgba(107, 45, 92, 0.2), rgba(107, 45, 92, 0.75), rgba(107, 45, 92, 0.2));
    background-size: 200% 100%;
    animation: flowBeam 5s linear infinite;
    z-index: 0;
}

.how-step-card {
    position: relative;
    z-index: 1;
    background: rgba(255, 255, 255, 0.84);
    border: 1px solid rgba(107, 45, 92, 0.12);
    backdrop-filter: blur(8px);
    border-radius: 20px;
    padding: 1.25rem 0.9rem 1.1rem;
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.how-step-card:hover {
    transform: translateY(-6px);
    border-color: rgba(107, 45, 92, 0.28);
    box-shadow: 0 14px 30px rgba(93, 42, 66, 0.12);
}

.how-step-card .step-number {
    width: 40px;
    height: 40px;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    margin-bottom: 0.85rem;
}

/* Shop bestseller hub */
.shop-bestseller-shell {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(243, 232, 255, 0.45));
    border: 1px solid rgba(107, 45, 92, 0.12);
    border-radius: 28px;
    padding: 1.25rem;
}

.shop-bestseller-chip {
    border: 1px solid rgba(107, 45, 92, 0.2);
    background: rgba(255, 255, 255, 0.8);
    color: #5D2A42;
    border-radius: 9999px;
    padding: 0.55rem 0.95rem;
    font-size: 0.875rem;
    font-weight: 700;
    transition: all 0.25s ease;
}

.shop-bestseller-chip:hover {
    border-color: rgba(107, 45, 92, 0.45);
    transform: translateY(-1px);
}

.shop-bestseller-chip.active {
    background: linear-gradient(135deg, #6B2D5C 0%, #5A2550 100%);
    border-color: transparent;
    color: white;
    box-shadow: 0 8px 20px rgba(93, 42, 66, 0.22);
}

.shop-bestseller-card {
    background: white;
    border: 1px solid rgba(107, 45, 92, 0.08);
    border-radius: 18px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.shop-bestseller-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 28px rgba(93, 42, 66, 0.14);
}

.shop-bestseller-card img {
    transition: transform 0.35s ease;
}

.shop-bestseller-card:hover img {
    transform: scale(1.04);
}

/* Filter styles */
.filter-group label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.filter-group label:hover {
    background: #F8F4F4;
}

.filter-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: #6B2D5C;
    border-radius: 4px;
}

/* Personalisation steps */
.step-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.step-dot {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.3s ease;
}

.step-dot.active {
    background: #6B2D5C;
    color: white;
}

.step-dot.completed {
    background: #16A34A;
    color: white;
}

.step-dot.inactive {
    background: #E5E7EB;
    color: #9CA3AF;
}

.step-line {
    flex: 1;
    height: 2px;
    background: #E5E7EB;
}

.step-line.completed {
    background: #16A34A;
}

/* Color picker */
.color-option {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 3px solid transparent;
}

.color-option:hover {
    transform: scale(1.1);
}

.color-option.selected {
    border-color: #5D2A42;
    box-shadow: 0 0 0 3px white, 0 0 0 5px #6B2D5C;
}

/* Character counter */
.char-counter {
    font-size: 0.875rem;
    color: #9CA3AF;
}

.char-counter.warning {
    color: #F59E0B;
}

.char-counter.error {
    color: #EF4444;
}

/* Upload zone */
.upload-zone {
    border: 2px dashed #6B2D5C;
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #F8F4F4;
}

.upload-zone:hover {
    border-color: #5D2A42;
    background: white;
}

.upload-zone.dragover {
    border-color: #5D2A42;
    background: white;
    transform: scale(1.02);
}

/* Delivery box */
.delivery-box {
    background: white;
    border-radius: 20px;
    padding: 1.5rem;
    border: 2px solid rgba(107, 45, 92, 0.2);
}

/* Toast notification */
.toast {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: #5D2A42;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(93, 42, 66, 0.3);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1000;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

/* Mobile menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 320px;
    height: 100vh;
    background: white;
    box-shadow: -10px 0 30px rgba(93, 42, 66, 0.2);
    transition: right 0.3s ease;
    z-index: 100;
    padding: 2rem;
}

.mobile-menu.open {
    right: 0;
}

.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(93, 42, 66, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 99;
}

.mobile-overlay.open {
    opacity: 1;
    visibility: visible;
}

/* Cart drawer */
.cart-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 420px;
    height: 100vh;
    background: white;
    box-shadow: -10px 0 30px rgba(93, 42, 66, 0.2);
    transition: right 0.3s ease;
    z-index: 101;
    display: flex;
    flex-direction: column;
}

.cart-drawer.open {
    right: 0;
}

/* Trust strip */
.trust-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    margin-top: 2rem;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: rgba(93, 42, 66, 0.7);
}

/* Decorative sparkles */
.sparkle {
    position: absolute;
    pointer-events: none;
    opacity: 0.3;
}

/* Glassmorphism card */
.glass-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 24px;
}

/* Gradient text */
.gradient-text {
    background: linear-gradient(135deg, #6B2D5C 0%, #5D2A42 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Form styles */
.form-input {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid rgba(107, 45, 92, 0.2);
    border-radius: 12px;
    font-family: "Quicksand", sans-serif;
    font-size: 1rem;
    transition: all 0.2s ease;
    background: white;
}

.form-input:focus {
    outline: none;
    border-color: #6B2D5C;
    box-shadow: 0 0 0 3px rgba(107, 45, 92, 0.2);
}

.form-input::placeholder {
    color: #9CA3AF;
}

.form-label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #5D2A42;
}

/* Preset path cards */
.preset-card {
    background: white;
    border: 2px solid rgba(107, 45, 92, 0.2);
    border-radius: 20px;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.preset-card:hover {
    border-color: #6B2D5C;
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(107, 45, 92, 0.2);
}

.preset-card.selected {
    border-color: #6B2D5C;
    background: #F8F4F4;
}

/* Quantity selector */
.quantity-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #F3F4F6;
    border-radius: 12px;
    padding: 0.25rem;
}

.quantity-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.quantity-btn:hover {
    background: #6B2D5C;
    color: white;
}

.quantity-input {
    width: 48px;
    text-align: center;
    font-weight: 600;
    background: transparent;
    border: none;
    font-family: "Quicksand", sans-serif;
}

/* Image gallery */
.gallery-main {
    border-radius: 24px;
    overflow: hidden;
    aspect-ratio: 1;
}

.gallery-thumbs {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.gallery-thumb {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    opacity: 0.6;
    transition: all 0.2s ease;
    border: 2px solid transparent;
}

.gallery-thumb:hover,
.gallery-thumb.active {
    opacity: 1;
    border-color: #6B2D5C;
}

/* Responsive utilities */
@media (max-width: 768px) {
    .hide-mobile {
        display: none !important;
    }
}

@media (min-width: 769px) {
    .hide-desktop {
        display: none !important;
    }
}

/* Modal Specific Styles */
.step-dot-modal {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.step-dot-modal.active {
    transform: scale(1.5);
}

.modal-mug-float {
    animation: float 6s ease-in-out infinite;
}

#modal-content {
    will-change: transform, opacity;
}
