/* ========================================
   SKAR — Supreme-inspired Design
   ======================================== */

/* ========================================
   Reset & Base
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors */
    --color-black: #FFFFFF;
    --color-white: #000000;
    --color-gray-light: #1A1A1A;
    --color-gray-medium: #999999;
    
    /* Typography */
    --font-primary: -apple-system, BlinkMacSystemFont, "Helvetica Neue", "Segoe UI", Arial, sans-serif;
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-bold: 700;
    
    /* Layout */
    --sidebar-width: 180px;
    --transition: 200ms ease;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-primary);
    font-weight: var(--font-weight-normal);
    line-height: 1.6;
    color: var(--color-black);
    background-color: var(--color-white);
}

/* Prevent iOS Safari auto-zoom on buttons and inputs */
button,
input,
select,
textarea {
    font-size: 16px;
    -webkit-tap-highlight-color: transparent;
}

a {
    color: var(--color-black);
    text-decoration: none;
}

/* ========================================
   Sidebar Menu (Supreme Style)
   ======================================== */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background-color: var(--color-white);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
}

.sidebar-nav {
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}

.menu-item {
    font-size: 0.8125rem;
    letter-spacing: 0.02em;
    color: var(--color-black);
    padding: 4px 8px;
    transition: opacity var(--transition);
    text-align: right;
}

.menu-item:hover {
    opacity: 0.6;
}

.menu-item.active {
    text-decoration: underline;
}

/* Cart Menu Item */
.cart-menu-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

.cart-count {
    background-color: var(--color-black);
    color: var(--color-white);
    font-size: 0.625rem;
    font-weight: var(--font-weight-medium);
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 16px;
    text-align: center;
    line-height: 1.2;
}

/* ========================================
   Top Header (Logo + Location)
   ======================================== */
.top-header {
    position: fixed;
    top: 0;
    left: var(--sidebar-width);
    right: 0;
    background-color: var(--color-white);
    padding: 16px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.header-logo {
    font-size: 1.75rem;
    font-weight: var(--font-weight-bold);
    letter-spacing: 0.1em;
    color: var(--color-black);
    margin: 0 0 4px 0;
}

.logo-link {
    color: inherit;
    text-decoration: none;
    cursor: pointer;
    transition: opacity var(--transition);
}

.logo-link:hover {
    opacity: 0.7;
}

.header-location {
    font-size: 0.6875rem;
    letter-spacing: 0.02em;
    color: var(--color-gray-medium);
    text-align: center;
    margin: 0;
}

/* Keep location visible on mobile */
@media (max-width: 768px) {
    .header-location {
        display: block;
    }
}

/* ========================================
   Main Content Area
   ======================================== */
.main-content {
    margin-left: var(--sidebar-width);
    margin-top: 80px;
    min-height: calc(100vh - 80px);
}

/* ========================================
   Background Video Section
   ======================================== */
.video-background-section {
    position: relative;
    width: 100%;
    height: 25vh;
    min-height: 180px;
    overflow: hidden;
    background-color: var(--color-white);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background-image: linear-gradient(45deg, rgba(0,0,0,0.1) 25%, transparent 25%), 
                      linear-gradient(-45deg, rgba(0,0,0,0.1) 25%, transparent 25%), 
                      linear-gradient(45deg, transparent 75%, rgba(0,0,0,0.1) 75%), 
                      linear-gradient(-45deg, transparent 75%, rgba(0,0,0,0.1) 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
}

.background-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    object-position: center;
    z-index: 1;
    filter: grayscale(100%) contrast(1.1);
    opacity: 0.8;
    will-change: transform;
    animation: videoPan 30s cubic-bezier(0.4, 0, 0.2, 1) infinite alternate;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transform-style: preserve-3d;
    -webkit-transform-style: preserve-3d;
}

@keyframes videoPan {
    0% {
        transform: translate(-50%, -65%) scale(1.08);
    }
    25% {
        transform: translate(-50%, -55%) scale(1.12);
    }
    50% {
        transform: translate(-50%, -45%) scale(1.15);
    }
    75% {
        transform: translate(-50%, -35%) scale(1.12);
    }
    100% {
        transform: translate(-50%, -25%) scale(1.18);
    }
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.1) 0%,
        rgba(0, 0, 0, 0.3) 50%,
        rgba(0, 0, 0, 0.5) 100%
    );
    z-index: 2;
    pointer-events: none;
}

/* Performance optimizations for video animation */
@media (prefers-reduced-motion: reduce) {
    .background-video {
        animation: none;
    }
}

/* GPU acceleration for smoother performance */
.video-background-section,
.background-video {
    -webkit-transform: translateZ(0);
    -moz-transform: translateZ(0);
    -ms-transform: translateZ(0);
    -o-transform: translateZ(0);
    transform: translateZ(0);
}

/* ========================================
   Shop View (Product Grid)
   ======================================== */
.shop-view {
    display: block;
    padding: 64px 32px;
    min-height: calc(100vh - 80px);
}

.shop-view.hidden {
    display: none;
}

.shop-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 32px;
}

.shop-category {
    font-size: 1.25rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
}

.view-all-link {
    font-size: 0.875rem;
    text-decoration: underline;
    transition: opacity var(--transition);
}

.view-all-link:hover {
    opacity: 0.6;
}

/* ========================================
   Product Grid
   ======================================== */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 32px;
}

.product-card {
    cursor: pointer;
    transition: transform var(--transition);
}

.product-card:hover {
    transform: translateY(-4px);
}

.product-image-container {
    width: 100%;
    aspect-ratio: 1;
    background-color: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Stock Indicator */
.stock-indicator {
    position: absolute;
    top: 12px;
    right: 12px;
    font-size: 0.6875rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    color: var(--color-gray-medium);
    background-color: rgba(255, 255, 255, 0.05);
    padding: 4px 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-transform: lowercase;
}

.product-image-container img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

/* Locked Product Overlay */
.locked-product .product-image-container img {
    opacity: 0.3;
}

.lock-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.3);
}

.lock-overlay .lock-icon {
    width: 32px;
    height: 32px;
    color: rgba(255, 255, 255, 0.8);
}

/* Product Info */
.product-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.product-name {
    font-size: 0.875rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
}

.product-color {
    font-size: 0.8125rem;
    color: var(--color-gray-medium);
}

.product-description {
    font-size: 0.75rem;
    color: var(--color-gray-medium);
    letter-spacing: 0.02em;
    font-style: italic;
}

.product-price {
    font-size: 0.8125rem;
    color: var(--color-gray-medium);
    font-weight: var(--font-weight-medium);
    display: flex;
    align-items: center;
    gap: 4px;
}

.sar-symbol {
    width: 14px;
    height: 16px;
    filter: invert(1);
    opacity: 0.6;
}

.price-amount {
    font-weight: var(--font-weight-medium);
}

.product-status {
    font-size: 0.6875rem;
    color: var(--color-gray-medium);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: var(--font-weight-medium);
    margin-top: 4px;
    opacity: 0.7;
}

/* ========================================
   Mobile Navigation
   ======================================== */
.mobile-nav {
    display: none;
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    background-color: var(--color-white);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 998;
    padding: 0;
}

.mobile-nav-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 24px;
    padding: 16px 16px 8px;
}

.mobile-menu-item {
    font-size: 0.8125rem;
    letter-spacing: 0.02em;
    color: var(--color-black);
    padding: 4px 8px;
    transition: opacity var(--transition);
    text-align: center;
}

.mobile-menu-item:hover {
    opacity: 0.6;
}

.mobile-menu-item.active {
    text-decoration: underline;
}

/* Mobile Cart Menu Item */
.mobile-nav .cart-menu-item {
    position: relative;
    display: flex;
    align-items: center;
    gap: 6px;
}

.mobile-nav .cart-count {
    background-color: var(--color-black);
    color: var(--color-white);
    font-size: 0.5625rem;
    font-weight: var(--font-weight-medium);
    padding: 1px 5px;
    border-radius: 8px;
    min-width: 14px;
    text-align: center;
    line-height: 1.2;
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 768px) {
    :root {
        --sidebar-width: 0;
    }
    
    .sidebar {
        display: none;
    }
    
    .mobile-nav {
        display: block;
        top: 66px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.15);
        box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    }
    
    .main-content {
        margin-left: 0;
        margin-top: 116px;
    }
    
    .top-header {
        padding: 12px 0;
        left: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        text-align: center;
    }
    
    .header-logo {
        font-size: 1.25rem;
        margin: 0 0 4px 0;
    }
    
    .header-location {
        font-size: 0.625rem;
        text-align: center;
    }
    
    /* Video Background Mobile */
    .video-background-section {
        height: 20vh;
        min-height: 140px;
    }
    
    .background-video {
        filter: grayscale(100%) contrast(1.2);
        opacity: 0.7;
        animation: videoPanMobile 30s cubic-bezier(0.4, 0, 0.2, 1) infinite alternate;
        min-width: 100%;
        min-height: 100%;
        /* Better mobile centering for portrait video */
        object-position: center 40%;
    }
    
    @keyframes videoPanMobile {
        0% {
            transform: translate(-50%, -50%) scale(1.1);
        }
        50% {
            transform: translate(-50%, -45%) scale(1.15);
        }
        100% {
            transform: translate(-50%, -40%) scale(1.2);
        }
    }
    
    .shop-view {
        padding: 48px 24px;
    }
    
    .shop-header {
        margin-bottom: 24px;
    }
    
    .shop-category {
        font-size: 1rem;
    }
    
    .product-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .shop-view {
        padding: 32px 20px;
    }
    
    .product-image-container {
        aspect-ratio: 4/5;
    }
}

@media (max-width: 480px) {
    .mobile-nav-container {
        gap: 16px;
    }
    
    .mobile-menu-item {
        font-size: 0.75rem;
        padding: 4px 6px;
    }
    
    /* Video Background Small Mobile */
    .video-background-section {
        height: 18vh;
        min-height: 120px;
    }
    
    .background-video {
        filter: grayscale(100%) contrast(1.3);
        opacity: 0.6;
        animation: videoPanMobileSmall 35s cubic-bezier(0.4, 0, 0.2, 1) infinite alternate;
        /* Better positioning for small screens */
        object-position: center 45%;
    }
    
    @keyframes videoPanMobileSmall {
        0% {
            transform: translate(-50%, -50%) scale(1.08);
        }
        100% {
            transform: translate(-50%, -42%) scale(1.15);
        }
    }
    
    .product-grid {
        gap: 16px;
    }
    
    .product-info {
        font-size: 0.875rem;
    }
}

/* ========================================
   Cart Notification Toast
   ======================================== */
.cart-notification {
    position: fixed;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.cart-notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: all;
}

.cart-notification-content {
    background-color: var(--color-black);
    color: var(--color-white);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}

.cart-notification-text {
    font-size: 0.8125rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    white-space: nowrap;
}

.cart-notification-btn {
    background-color: transparent;
    color: var(--color-white);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 6px 16px;
    font-size: 0.75rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
}

.cart-notification-btn:hover {
    background-color: var(--color-white);
    color: var(--color-black);
    border-color: var(--color-white);
}

.cart-notification-btn:active {
    transform: scale(0.97);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .cart-notification {
        bottom: 24px;
        left: 50%;
        right: auto;
        width: auto;
        max-width: calc(100% - 48px);
    }
    
    .cart-notification-content {
        padding: 10px 16px;
        gap: 12px;
    }
    
    .cart-notification-text {
        font-size: 0.75rem;
    }
    
    .cart-notification-btn {
        padding: 5px 14px;
        font-size: 0.6875rem;
    }
}

@media (max-width: 480px) {
    .cart-notification {
        bottom: 20px;
        max-width: calc(100% - 40px);
    }
    
    .cart-notification-content {
        padding: 9px 14px;
        gap: 10px;
    }
}

/* ========================================
   Checkout Modal
   ======================================== */

/* Overlay */
.checkout-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    z-index: 9999;
    animation: fadeIn 0.3s ease;
    -webkit-tap-highlight-color: transparent;
}

.checkout-overlay.active {
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Modal Container */
.checkout-modal {
    background-color: var(--color-white);
    width: 100%;
    max-width: 540px;
    max-height: 85vh;
    border-radius: 0;
    position: relative;
    transform: translateY(100%);
    animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    display: flex;
    flex-direction: column;
}

@keyframes slideUp {
    to {
        transform: translateY(0);
    }
}

.checkout-modal.closing {
    animation: slideDown 0.3s cubic-bezier(0.7, 0, 0.84, 0) forwards;
}

@keyframes slideDown {
    to {
        transform: translateY(100%);
    }
}

/* Close Button */
.checkout-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: var(--color-black);
    font-size: 1.5rem;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.6;
    transition: opacity var(--transition);
    z-index: 10;
    padding: 0;
    line-height: 1;
}

.checkout-close:hover {
    opacity: 1;
}

/* Modal Content */
.checkout-content {
    padding: 48px 32px 32px;
    overflow-y: auto;
    flex: 1;
}

/* Product Display */
.checkout-product {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    margin-bottom: 32px;
}

.checkout-product-image {
    width: 100%;
    max-width: 280px;
    aspect-ratio: 4/5;
    background-color: var(--color-gray-light);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.checkout-product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.checkout-product-info {
    text-align: center;
    width: 100%;
}

.checkout-product-name {
    font-size: 1.25rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    margin-bottom: 12px;
    text-transform: lowercase;
}

.checkout-product-price {
    font-size: 1rem;
    color: var(--color-gray-medium);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.checkout-product-price .sar-symbol {
    width: 16px;
    height: 18px;
}

/* Divider */
.checkout-divider {
    height: 1px;
    background-color: rgba(255, 255, 255, 0.1);
    margin: 32px 0;
}

/* Actions */
.checkout-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0 32px 32px;
}

.checkout-btn {
    width: 100%;
    padding: 16px 24px;
    font-size: 0.875rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background-color: transparent;
    color: var(--color-black);
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.checkout-btn:hover {
    background-color: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
}

.checkout-btn.primary {
    background-color: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
}

.checkout-btn.primary:hover {
    opacity: 0.85;
}

/* Apple Pay Logo */
.applepay-logo {
    width: 40px;
    height: 16px;
    filter: invert(1);
}

.checkout-btn.primary .applepay-logo {
    filter: invert(0);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .checkout-modal {
        max-width: 100%;
        max-height: 90vh;
        border-radius: 16px 16px 0 0;
    }
    
    .checkout-content {
        padding: 40px 24px 24px;
    }
    
    .checkout-product-image {
        max-width: 220px;
    }
    
    .checkout-actions {
        padding: 0 24px 24px;
    }
    
    /* Fix for mobile overlay issues */
    .checkout-overlay:not(.active) {
        display: none !important;
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
    }
    
    /* Ensure proper z-index stacking on mobile */
    .checkout-overlay {
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
        -webkit-perspective: 1000;
        perspective: 1000;
    }
    
    /* Fix for iOS Safari */
    .checkout-modal {
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
    }
}

@media (max-width: 480px) {
    .checkout-content {
        padding: 36px 20px 20px;
    }
    
    .checkout-product-image {
        max-width: 180px;
    }
    
    .checkout-product-name {
        font-size: 1.125rem;
    }
    
    .checkout-actions {
        padding: 0 20px 20px;
    }
    
    .checkout-btn {
        padding: 14px 20px;
        font-size: 0.8125rem;
    }
}

/* ========================================
   Perfume Story View (Different from Cases Grid)
   ======================================== */
.perfume-view {
    display: block;
    padding: 64px 32px;
    min-height: calc(100vh - 80px);
}

.perfume-view.hidden {
    display: none;
}

.perfume-stories {
    display: flex;
    flex-direction: column;
    gap: 80px;
}

/* Perfume Story Card */
.perfume-story-card {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 64px;
    align-items: start;
    transition: transform var(--transition), opacity var(--transition);
}

/* Perfume Image */
.perfume-story-image {
    width: 100%;
    aspect-ratio: 4/5;
    background-color: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.perfume-story-image img {
    max-width: 85%;
    max-height: 85%;
    object-fit: contain;
    transition: transform 0.4s ease;
}

/* Locked Perfume */
.locked-perfume .perfume-story-image img {
    opacity: 0.3;
}

.locked-perfume {
    cursor: not-allowed;
}

.locked-perfume:hover {
    transform: none;
}

/* Perfume Content */
.perfume-story-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 24px;
    padding-top: 32px;
}

.perfume-story-title {
    font-size: 2rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    color: var(--color-black);
    margin-bottom: 8px;
}

.perfume-story-text {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.perfume-story-text p {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--color-gray-medium);
    letter-spacing: 0.01em;
}

/* Perfume Meta */
.perfume-story-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.perfume-notes {
    font-size: 0.875rem;
    color: var(--color-gray-medium);
    font-style: italic;
    letter-spacing: 0.02em;
}

.perfume-price {
    font-size: 1rem;
    color: var(--color-black);
    font-weight: var(--font-weight-medium);
    display: flex;
    align-items: center;
    gap: 6px;
}

.perfume-status {
    font-size: 0.875rem;
    color: var(--color-gray-medium);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 8px;
}

/* Perfume Action Buttons */
.perfume-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.perfume-btn {
    flex: 1;
    padding: 14px 24px;
    background-color: var(--color-black);
    color: var(--color-white);
    border: 2px solid var(--color-black);
    font-size: 0.8125rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.05em;
    text-transform: lowercase;
    cursor: pointer;
    transition: all 0.2s ease;
}

.perfume-btn:hover {
    background-color: var(--color-white);
    color: var(--color-black);
    transform: translateY(-2px);
}

.perfume-btn:active {
    transform: translateY(0);
}

/* Responsive for Perfume Stories */
@media (max-width: 968px) {
    .perfume-story-card {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .perfume-story-image {
        max-width: 400px;
        margin: 0 auto;
    }
    
    .perfume-story-content {
        padding-top: 0;
    }
}

@media (max-width: 768px) {
    .perfume-view {
        padding: 48px 24px;
    }
    
    .perfume-stories {
        gap: 64px;
    }
    
    .perfume-story-title {
        font-size: 1.5rem;
    }
    
    .perfume-story-text p {
        font-size: 0.9375rem;
        line-height: 1.7;
    }
    
    .perfume-story-image {
        max-width: 320px;
    }
    
    .perfume-btn {
        padding: 12px 20px;
        font-size: 0.75rem;
    }
}

@media (max-width: 480px) {
    .perfume-view {
        padding: 32px 20px;
    }
    
    .perfume-stories {
        gap: 48px;
    }
    
    .perfume-story-title {
        font-size: 1.25rem;
    }
    
    .perfume-story-text p {
        font-size: 0.875rem;
        line-height: 1.65;
    }
    
    .perfume-story-image {
        max-width: 280px;
    }
    
    .perfume-story-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .perfume-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .perfume-btn {
        padding: 12px 18px;
        font-size: 0.7rem;
    }
}

/* ========================================
   Archive View (Story Section)
   ======================================== */
.archive-view {
    display: block;
    padding: 64px 32px;
    min-height: calc(100vh - 80px);
}

.archive-view.hidden {
    display: none;
}

.archive-content {
    display: flex;
    flex-direction: column;
}

.archive-story {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.archive-title {
    font-size: 1.5rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.05em;
    text-transform: lowercase;
    color: var(--color-black);
}

.archive-text {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.archive-text p {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--color-gray-medium);
    letter-spacing: 0.02em;
}

@media (max-width: 768px) {
    .archive-view {
        padding: 48px 24px;
    }
    
    .archive-title {
        font-size: 1.25rem;
    }
    
    .archive-text p {
        font-size: 0.9375rem;
        line-height: 1.7;
    }
}

@media (max-width: 480px) {
    .archive-view {
        padding: 32px 20px;
    }
    
    .archive-title {
        font-size: 1.125rem;
    }
    
    .archive-text p {
        font-size: 0.875rem;
    }
}

/* ========================================
   Cart View
   ======================================== */
.cart-view {
    display: block;
    padding: 64px 32px;
    min-height: calc(100vh - 80px);
}

.cart-view.hidden {
    display: none;
}

.cart-content {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

/* Cart Header */
.cart-header {
    text-align: left;
}

.cart-title {
    font-size: 2rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    color: var(--color-black);
    margin-bottom: 8px;
}

.cart-subtitle {
    font-size: 0.875rem;
    color: var(--color-gray-medium);
    letter-spacing: 0.02em;
}

/* Cart Items */
.cart-items {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.cart-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 20px;
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all var(--transition);
}

.cart-item:hover {
    background-color: rgba(255, 255, 255, 0.03);
}

.cart-item-image {
    width: 90px;
    height: 110px;
    background-color: var(--color-gray-light);
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.cart-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.cart-item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.cart-item-name {
    font-size: 1rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    color: var(--color-black);
}

.cart-item-price {
    font-size: 0.875rem;
    color: var(--color-gray-medium);
    display: flex;
    align-items: center;
    gap: 4px;
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: flex-start;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 4px;
}

.quantity-btn {
    width: 32px;
    height: 32px;
    background-color: transparent;
    border: none;
    color: var(--color-black);
    font-size: 16px;
    font-weight: var(--font-weight-medium);
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 2px;
}

.quantity-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.quantity-btn:active {
    background-color: rgba(255, 255, 255, 0.15);
    transform: scale(0.95);
}

.quantity-btn:disabled {
    opacity: 0.2;
    cursor: not-allowed;
}

.quantity-btn:disabled:hover {
    background-color: transparent;
    transform: none;
}

.quantity-display {
    font-size: 0.875rem;
    font-weight: var(--font-weight-medium);
    color: var(--color-black);
    min-width: 32px;
    text-align: center;
    user-select: none;
}

.remove-item-btn {
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--color-gray-medium);
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 4px;
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    opacity: 0.4;
    flex-shrink: 0;
}

.remove-item-btn:hover {
    color: var(--color-black);
    border-color: rgba(255, 255, 255, 0.2);
    background-color: rgba(255, 255, 255, 0.05);
    opacity: 1;
}

.remove-item-btn:active {
    background-color: rgba(255, 255, 255, 0.1);
    transform: scale(0.95);
}

/* Empty Cart State */
.cart-empty {
    text-align: center;
    padding: 64px 32px;
    color: var(--color-gray-medium);
}

.cart-empty-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    opacity: 0.15;
    color: var(--color-gray-medium);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-empty-icon svg {
    width: 100%;
    height: 100%;
}

.cart-empty-title {
    font-size: 1.25rem;
    font-weight: var(--font-weight-medium);
    margin-bottom: 12px;
    color: var(--color-black);
}

.cart-empty-text {
    font-size: 0.875rem;
    line-height: 1.6;
    margin-bottom: 32px;
}

.cart-empty-btn {
    background-color: var(--color-black);
    color: var(--color-white);
    border: 2px solid var(--color-black);
    padding: 14px 32px;
    font-size: 0.875rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: all var(--transition);
}

.cart-empty-btn:hover {
    background-color: var(--color-white);
    color: var(--color-black);
}

/* Cart Summary */
.cart-summary {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 32px;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.125rem;
    font-weight: var(--font-weight-medium);
    color: var(--color-black);
}

.total-label {
    text-transform: lowercase;
    letter-spacing: 0.02em;
}

.total-amount {
    display: flex;
    align-items: center;
    gap: 6px;
}

.total-amount .sar-symbol {
    width: 18px;
    height: 20px;
}

/* Cart Actions */
.cart-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cart-btn {
    flex: 1;
    padding: 16px 24px;
    font-size: 0.875rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background-color: transparent;
    color: var(--color-black);
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.cart-btn:hover {
    background-color: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
}

.cart-btn.primary {
    background-color: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
}

.cart-btn.primary:hover {
    opacity: 0.85;
}

.cart-btn.secondary {
    background-color: transparent;
    color: var(--color-black);
    border-color: rgba(255, 255, 255, 0.2);
    opacity: 0.7;
}

.cart-btn.secondary:hover {
    background-color: transparent;
    color: var(--color-black);
    border-color: rgba(255, 255, 255, 0.4);
    opacity: 1;
    text-decoration: underline;
}

.cart-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.cart-btn:disabled:hover {
    background-color: transparent;
    color: var(--color-black);
    border-color: rgba(255, 255, 255, 0.2);
}

.cart-btn.primary:disabled:hover {
    background-color: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
    opacity: 0.3;
}

/* Responsive Design for Cart */
@media (max-width: 768px) {
    .cart-view {
        padding: 48px 24px;
    }
    
    .cart-content {
        gap: 32px;
    }
    
    .cart-title {
        font-size: 1.5rem;
    }
    
    .cart-item {
        flex-direction: row;
        align-items: flex-start;
        gap: 16px;
        padding: 16px;
    }
    
    .cart-item-image {
        width: 70px;
        height: 85px;
        flex-shrink: 0;
    }
    
    .cart-item-details {
        gap: 12px;
    }
    
    .cart-item-header {
        gap: 10px;
    }
    
    .cart-item-info {
        gap: 4px;
    }
    
    .cart-item-name {
        font-size: 0.875rem;
    }
    
    .cart-item-price {
        font-size: 0.75rem;
    }
    
    .cart-item-actions {
        gap: 10px;
    }
    
    .quantity-controls {
        gap: 6px;
        padding: 3px;
    }
    
    .quantity-btn {
        width: 30px;
        height: 30px;
    }
    
    .quantity-btn svg {
        width: 11px;
        height: 11px;
    }
    
    .quantity-display {
        font-size: 0.8125rem;
        min-width: 28px;
    }
    
    .remove-item-btn {
        width: 30px;
        height: 30px;
        min-width: 30px;
    }
    
    .remove-item-btn svg {
        width: 12px;
        height: 12px;
    }
    
    .cart-total {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .cart-view {
        padding: 32px 20px;
    }
    
    .cart-content {
        gap: 24px;
    }
    
    .cart-title {
        font-size: 1.25rem;
    }
    
    .cart-empty-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 20px;
    }
    
    .cart-empty-title {
        font-size: 1.125rem;
    }
    
    .cart-empty-text {
        font-size: 0.8125rem;
        margin-bottom: 24px;
    }
    
    .cart-empty-btn {
        padding: 12px 24px;
        font-size: 0.8125rem;
    }
    
    .cart-item {
        padding: 14px;
        gap: 12px;
    }
    
    .cart-item-image {
        width: 60px;
        height: 72px;
    }
    
    .cart-item-details {
        gap: 10px;
    }
    
    .cart-item-header {
        gap: 8px;
    }
    
    .cart-item-name {
        font-size: 0.8125rem;
    }
    
    .cart-item-price {
        font-size: 0.6875rem;
    }
    
    .cart-item-actions {
        gap: 8px;
    }
    
    .quantity-controls {
        gap: 4px;
        padding: 2px;
    }
    
    .quantity-btn {
        width: 28px;
        height: 28px;
    }
    
    .quantity-btn svg {
        width: 10px;
        height: 10px;
    }
    
    .quantity-display {
        font-size: 0.75rem;
        min-width: 24px;
    }
    
    .remove-item-btn {
        width: 28px;
        height: 28px;
        min-width: 28px;
    }
    
    .remove-item-btn svg {
        width: 10px;
        height: 10px;
    }
    
    .cart-btn {
        padding: 14px 20px;
        font-size: 0.8125rem;
    }
}

/* ========================================
   Individual Perfume Story Pages
   ======================================== */

/* Main Story Page Container */
.perfume-story-page {
    display: block;
    padding: 64px 32px;
    min-height: calc(100vh - 80px);
    position: relative;
}

.perfume-story-page.hidden {
    display: none;
}

/* Breadcrumb Navigation */
.story-breadcrumb {
    position: relative;
    margin-bottom: 48px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    letter-spacing: 0.02em;
    color: var(--color-gray-medium);
}

.breadcrumb-link {
    color: var(--color-gray-medium);
    transition: opacity var(--transition);
}

.breadcrumb-link:hover {
    opacity: 0.6;
}

.breadcrumb-divider {
    color: rgba(255, 255, 255, 0.3);
}

.breadcrumb-current {
    color: var(--color-black);
}

/* Story Media (Images & Videos) */
.story-media {
    width: 100%;
    margin: 48px 0;
}

.story-media-small {
    max-width: 500px;
    margin: 32px auto;
}

.story-image {
    width: 100%;
    height: auto;
    display: block;
    border: 1px solid rgba(255, 255, 255, 0.1);
    filter: grayscale(20%) contrast(1.05);
    transition: filter 0.4s ease;
}

.story-image:hover {
    filter: grayscale(0%) contrast(1.1);
}

.story-caption {
    font-size: 0.8125rem;
    color: var(--color-gray-medium);
    font-style: italic;
    text-align: center;
    margin-top: 12px;
    letter-spacing: 0.02em;
}

/* Video Container (16:9 responsive) */
.story-video {
    margin: 64px 0;
}

.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Story Content Container */
.story-content {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

/* Story Section */
.story-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Character Name (Main Title) */
.story-character-name {
    font-size: 3rem;
    font-weight: var(--font-weight-bold);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    color: var(--color-black);
    line-height: 1.1;
    margin-bottom: 8px;
}

/* Perfume Name (Subtitle) */
.story-perfume-name {
    font-size: 0.875rem;
    color: var(--color-gray-medium);
    letter-spacing: 0.1em;
    text-transform: lowercase;
}

/* Story Heading (Section Titles) */
.story-heading {
    font-size: 1.5rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    color: var(--color-black);
    margin-bottom: 12px;
}

/* Story Subheading */
.story-subheading {
    font-size: 1.125rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.02em;
    text-transform: lowercase;
    color: var(--color-black);
    margin-bottom: 16px;
}

/* Story Paragraph */
.story-paragraph {
    font-size: 1.0625rem;
    line-height: 1.9;
    color: var(--color-gray-medium);
    letter-spacing: 0.01em;
}

.story-paragraph strong {
    color: var(--color-black);
    font-weight: var(--font-weight-medium);
}

/* Story Dividers (Using Simple Symbols) */
.story-divider {
    text-align: center;
    font-size: 1.125rem;
    letter-spacing: 0.3em;
    color: rgba(255, 255, 255, 0.2);
    margin: 32px 0;
    user-select: none;
}

/* Technical Section */
.story-technical {
    background-color: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 32px;
}

.story-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.story-list li {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--color-gray-medium);
}

.story-list li strong {
    color: var(--color-black);
    font-weight: var(--font-weight-medium);
}

.story-meta {
    font-size: 0.875rem;
    color: var(--color-gray-medium);
    letter-spacing: 0.02em;
    margin: 8px 0;
}

/* Inline CTA Section (Natural Flow) */
.story-inline-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
    margin: 48px 0;
    padding: 48px 32px;
    background-color: rgba(255, 255, 255, 0.02);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.story-cta-intro {
    text-align: center;
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-black);
    max-width: 500px;
}

.story-cta-button {
    background-color: var(--color-black);
    color: var(--color-white);
    border: 2px solid var(--color-black);
    padding: 18px 56px;
    font-size: 0.9375rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.3s ease;
}

.story-cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 255, 255, 0.15);
}

.story-cta-button:active {
    transform: translateY(0);
}

/* Quick Buy Bar (Sticky and always visible) */
.quick-buy-bar {
    position: sticky;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 16px 32px;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 800;
}

.quick-buy-button {
    background-color: var(--color-black);
    color: var(--color-white);
    border: 2px solid rgba(255, 255, 255, 0.2);
    padding: 12px 40px;
    font-size: 0.875rem;
    font-weight: var(--font-weight-medium);
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.3s ease;
}

.quick-buy-button:hover {
    border-color: var(--color-black);
    background-color: var(--color-white);
    color: var(--color-black);
}

/* Responsive Design for Story Pages */
@media (max-width: 768px) {
    .perfume-story-page {
        padding: 48px 24px;
    }
    
    .story-breadcrumb {
        margin-bottom: 40px;
        font-size: 0.6875rem;
    }
    
    .story-content {
        gap: 40px;
    }
    
    .story-character-name {
        font-size: 2rem;
    }
    
    .story-perfume-name {
        font-size: 0.8125rem;
    }
    
    .story-heading {
        font-size: 1.25rem;
    }
    
    .story-subheading {
        font-size: 1rem;
    }
    
    .story-paragraph {
        font-size: 1rem;
        line-height: 1.8;
    }
    
    .story-media {
        margin: 40px 0;
    }
    
    .story-media-small {
        max-width: 100%;
        margin: 32px 0;
    }
    
    .story-video {
        margin: 48px 0;
    }
    
    .story-caption {
        font-size: 0.75rem;
    }
    
    .story-technical {
        padding: 24px;
    }
    
    .story-inline-cta {
        padding: 48px 24px;
        margin: 48px 0;
        gap: 24px;
    }
    
    .story-cta-intro {
        font-size: 1rem;
    }
    
    .story-cta-button {
        padding: 16px 40px;
        font-size: 0.875rem;
    }
    
    .quick-buy-bar {
        padding: 14px 24px;
    }
    
    .quick-buy-button {
        padding: 11px 32px;
        font-size: 0.8125rem;
    }
}

@media (max-width: 480px) {
    .perfume-story-page {
        padding: 32px 20px;
    }
    
    .story-breadcrumb {
        margin-bottom: 32px;
        font-size: 0.625rem;
    }
    
    .story-content {
        gap: 32px;
    }
    
    .story-character-name {
        font-size: 1.75rem;
    }
    
    .story-heading {
        font-size: 1.125rem;
    }
    
    .story-paragraph {
        font-size: 0.9375rem;
        line-height: 1.75;
    }
    
    .story-divider {
        font-size: 1rem;
    }
    
    .story-media {
        margin: 32px 0;
    }
    
    .story-media-small {
        margin: 24px 0;
    }
    
    .story-video {
        margin: 40px 0;
    }
    
    .story-caption {
        font-size: 0.6875rem;
        margin-top: 8px;
    }
    
    .story-technical {
        padding: 20px;
    }
    
    .story-list li {
        font-size: 0.875rem;
    }
    
    .story-meta {
        font-size: 0.8125rem;
    }
    
    .story-inline-cta {
        padding: 40px 20px;
        margin: 40px 0;
        gap: 20px;
    }
    
    .story-cta-intro {
        font-size: 0.9375rem;
    }
    
    .story-cta-button {
        padding: 14px 32px;
        font-size: 0.8125rem;
    }
    
    .quick-buy-bar {
        padding: 12px 20px;
    }
    
    .quick-buy-button {
        padding: 10px 28px;
        font-size: 0.75rem;
    }
}
