@import url('https://fonts.googleapis.com/css2?family=Bodoni+Moda:ital,wght@0,400;0,700;1,400&family=Jost:wght@300;400;500;600;700&family=Cormorant:wght@400;500;600;700&family=Montserrat:wght@300;400;500;600;700&display=swap');

:root {
    /* DEFAULT: DARK THEME */
    --primary: #1C1917;
    --on-primary: #FFFFFF;
    --secondary: #44403C;
    --accent: #A16207;
    --background: #0C0A09;
    --foreground: #FAFAF9;
    --muted: rgba(232, 236, 240, 0.1);
    --border: rgba(214, 211, 209, 0.2);
    --glass-bg: rgba(28, 25, 23, 0.7);
    --glass-blur: blur(12px);
    --header-bg: rgba(12, 10, 9, 0.8);
    --nav-bg: rgba(12, 10, 9, 0.85);
    --card-bg: rgba(28, 25, 23, 1);
    --durbox-bg: linear-gradient(135deg, rgba(28,25,23,1), rgba(161,98,7,0.15));
    --purchases-bg: linear-gradient(135deg, rgba(28,25,23,1), rgba(251,191,36,0.1));
    --balance-bg: rgba(28, 25, 23, 0.6);
    --item-bg: rgba(255, 255, 255, 0.03);
    --input-bg: rgba(255, 255, 255, 0.05);
    --input-color: #FAFAF9;
    --input-border: rgba(255, 255, 255, 0.1);
    --vip-bg: linear-gradient(135deg, rgba(28, 25, 23, 0.98) 0%, rgba(45, 40, 38, 0.9) 50%, rgba(28, 25, 23, 0.98) 100%);
    --vip-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.7), inset 0 0 20px rgba(161, 98, 7, 0.1);
}

[data-theme="light"] {
    /* PREMIUM LIGHT THEME */
    --primary: #FFFFFF;
    --on-primary: #1C1917;
    --secondary: #D6D3D1;
    --accent: #854D0E;
    --background: #FAFAF9;
    --foreground: #0C0A09;
    --muted: rgba(0, 0, 0, 0.05);
    --border: rgba(0, 0, 0, 0.1);
    --glass-bg: rgba(255, 255, 255, 0.75);
    --header-bg: rgba(250, 250, 249, 0.85);
    --nav-bg: rgba(255, 255, 255, 0.9);
    --card-bg: rgba(255, 255, 255, 0.9);
    --durbox-bg: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(161,98,7,0.08));
    --purchases-bg: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(251,191,36,0.08));
    --balance-bg: rgba(255, 255, 255, 0.7);
    --item-bg: rgba(0, 0, 0, 0.03);
    --input-bg: rgba(0, 0, 0, 0.03);
    --input-color: #0C0A09;
    --input-border: rgba(0, 0, 0, 0.08);
    --vip-bg: linear-gradient(135deg, rgba(255, 250, 240, 0.98) 0%, rgba(250, 245, 235, 0.95) 50%, rgba(255, 250, 240, 0.98) 100%);
    --vip-shadow: 0 20px 40px -10px rgba(161, 98, 7, 0.15), inset 0 0 20px rgba(161, 98, 7, 0.05);
}

:root {
    /* Tokens */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    
    --transition-fast: 200ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 400ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-liquid: 600ms cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    transition: background-color 0.4s ease, color 0.4s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--background);
    color: var(--foreground);
    font-family: 'Jost', sans-serif;
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .luxury-text {
    font-family: 'Bodoni Moda', serif;
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Liquid Glass Elements */
.liquid-glass {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border);
    border-radius: 16px;
    transition: var(--transition-smooth);
}

.liquid-glass:hover {
    border-color: rgba(161, 98, 7, 0.4);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Gold Text Gradient - Ultra Premium */
.gold-text {
    background: linear-gradient(135deg, #A16207 0%, #EAB308 25%, #FFF7ED 50%, #EAB308 75%, #A16207 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: goldShimmer 4s linear infinite;
}

@keyframes goldShimmer {
    to { background-position: 200% center; }
}

/* Shimmer Effect for Loading/Cards */
.shimmer {
    background: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.05) 50%, rgba(255,255,255,0) 100%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* Premium Primary Button */
.btn-primary {
    background: var(--accent);
    color: white;
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 600;
    font-family: 'Jost', sans-serif;
    border: none;
    cursor: pointer;
    transition: var(--transition-fast);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-primary:active {
    transform: scale(0.96);
    opacity: 0.9;
}

.btn-primary:hover {
    filter: brightness(1.1);
    box-shadow: 0 0 20px rgba(161, 98, 7, 0.3);
}

/* Tab Bar - Advanced Design */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border);
    padding-bottom: var(--tg-content-safe-area-inset-bottom, env(safe-area-inset-bottom));
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--secondary);
    font-size: 11px;
    text-decoration: none;
    transition: var(--transition-fast);
    gap: 4px;
    font-weight: 500;
}

.nav-item i {
    font-size: 18px;
}

.nav-item.active {
    color: var(--accent);
}

/* Animations */
@keyframes fluidEntrance {
    from { opacity: 0; transform: translateY(20px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.animate-fluid {
    animation: fluidEntrance 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Utility - Cursor Pointer */
button, a, .clickable {
    cursor: pointer;
}

/* Premium Loader */
.premium-loader {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(161, 98, 7, 0.1);
    border-top: 3px solid var(--accent);
    border-radius: 50%;
    animation: premiumSpin 1s radial infinite;
    margin: 20px auto;
}

@keyframes premiumSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.hide { display: none !important; }

/* Premium Dur Shell Animation */
.mini-pearl {
    width: 14px;
    height: 14px;
    background: radial-gradient(circle at 30% 30%, #fff 0%, #fbd38d 50%, #b45309 100%);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(251, 211, 141, 0.4);
}

/* Float Badge (+N) */
.dur-float-badge.show {
    display: none;
}


.unread-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: radial-gradient(circle at 30% 30%, #fcd34d 0%, #a16207 100%);
    color: #fff;
    font-size: 8px;
    font-weight: 900;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid var(--background);
    box-shadow: 0 0 15px rgba(161,98,7,0.5);
    z-index: 10;
}

.unread-card {
    background: rgba(161,98,7,0.12) !important;
    border: 1px solid rgba(251,191,36,0.3) !important;
    box-shadow: 0 15px 35px rgba(161,98,7,0.2) !important;
}

.notif-card {
    background: var(--glass-bg);
    border: 1px solid var(--border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 24px;
    border-radius: 24px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    display: flex;
    gap: 20px;
}

.notif-card:hover {
    transform: translateY(-4px) scale(1.01);
    background: rgba(255,255,255,0.05);
    border-color: rgba(255,255,255,0.15);
}

.notif-icon-box {
    width: 50px;
    height: 50px;
    min-width: 50px;
    border-radius: 16px;
    background: rgba(161,98,7,0.1);
    border: 1px solid rgba(161,98,7,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--accent);
}

/* Category Filter Pills */
.category-btn {
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    color: var(--secondary);
    white-space: nowrap;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    background: var(--muted);
    border: 1px solid var(--border);
}

.category-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.category-btn.active {
    background: var(--accent);
    color: #fff;
    font-weight: 600;
    border-color: var(--accent);
    box-shadow: 0 8px 20px rgba(161, 98, 7, 0.3);
}

/* Product Cards & Grids */
.product-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.horizontal-scroll-container {
    display: flex;
    overflow-x: auto;
    gap: 12px;
    padding: 10px 0 20px 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
}

.horizontal-scroll-container::-webkit-scrollbar { display: none; }

.scroll-item {
    width: 140px !important;
    min-width: 140px !important;
    max-width: 140px !important;
    flex-shrink: 0;
    scroll-snap-align: start;
    display: inline-block;
}

.scroll-item .product-card {
    width: 100% !important;
    height: auto;
    margin: 0;
}

.scroll-item .product-image {
    height: 140px; /* Square images for scroll */
}

.scroll-item .product-info h3 {
    font-size: 11px;
    margin-bottom: 2px;
    height: 32px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
}

.scroll-item .price-box {
    font-size: 13px;
}

.notif-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.notif-title {
    color: var(--foreground);
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 6px;
    letter-spacing: -0.01em;
}

.notif-text {
    color: var(--secondary);
    font-size: 14px;
    line-height: 1.6;
    font-weight: 400;
}

/* iOS Style Page Transitions */
.page-enter-right { animation: iosEnterRight 0.4s cubic-bezier(0.33, 1, 0.68, 1) forwards; }
.page-exit-left { animation: iosExitLeft 0.4s cubic-bezier(0.33, 1, 0.68, 1) forwards; }
.page-enter-left { animation: iosEnterLeft 0.4s cubic-bezier(0.33, 1, 0.68, 1) forwards; }
.page-exit-right { animation: iosExitRight 0.4s cubic-bezier(0.33, 1, 0.68, 1) forwards; }

@keyframes iosEnterRight {
    from { transform: translateX(30px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}
@keyframes iosExitLeft {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(-30px); opacity: 0; }
}
@keyframes iosEnterLeft {
    from { transform: translateX(-30px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}
@keyframes iosExitRight {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(30px); opacity: 0; }
}

.page-transitioning {
    pointer-events: none;
    will-change: transform, opacity;
}

/* AI Voice Assistant Styles */
.voice-assistant-overlay {
    position: fixed;
    inset: 0;
    z-index: 5000;
    background: rgba(0,0,0,0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s var(--transition-liquid);
    opacity: 0;
    pointer-events: none;
}

.voice-assistant-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.voice-wave-container {
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-bottom: 40px;
}

.voice-wave-bar {
    width: 6px;
    height: 20px;
    background: var(--accent);
    border-radius: 50px;
    animation: voiceWavePulse 1.2s ease-in-out infinite;
    box-shadow: 0 0 15px var(--accent);
}

.voice-wave-bar:nth-child(2) { animation-delay: 0.1s; }
.voice-wave-bar:nth-child(3) { animation-delay: 0.2s; height: 40px; }
.voice-wave-bar:nth-child(4) { animation-delay: 0.3s; height: 60px; }
.voice-wave-bar:nth-child(5) { animation-delay: 0.4s; height: 40px; }
.voice-wave-bar:nth-child(6) { animation-delay: 0.5s; }

@keyframes voiceWavePulse {
    0%, 100% { transform: scaleY(1); opacity: 0.5; }
    50% { transform: scaleY(1.5); opacity: 1; }
}

.voice-text-preview {
    font-size: 1.6rem;
    font-weight: 500;
    color: #fff;
    text-align: center;
    max-width: 80%;
    margin-bottom: 20px;
    font-family: 'Bodoni Moda', serif;
    min-height: 2em;
}

.mic-active-pulse {
    animation: micPulse 1.5s infinite;
}

@keyframes micPulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(161, 98, 7, 0.4); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 15px rgba(161, 98, 7, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(161, 98, 7, 0); }
}

.close-voice-btn {
    position: absolute;
    bottom: 60px;
    width: 60px;
    height: 60px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 20px;
    transition: all 0.3s;
}

.close-voice-btn:active {
    transform: scale(0.9);
    background: rgba(255,0,0,0.2);
}

/* --- Restored Bottom Navigation UI --- */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--nav-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-top: 1px solid var(--border);
    padding-bottom: env(safe-area-inset-bottom);
    box-shadow: 0 -10px 30px rgba(0,0,0,0.1);
}

.nav-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    height: 70px;
    max-width: 600px;
    margin: 0 auto;
    padding: 0 10px;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: #888;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    flex: 1;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
}

.nav-item i {
    font-size: 20px;
    transition: transform 0.3s;
}

.nav-item span {
    opacity: 0.7;
}

.nav-item.active {
    color: var(--accent);
}

.nav-item.active i {
    transform: translateY(-4px);
    text-shadow: 0 0 15px rgba(161, 98, 7, 0.4);
}

.nav-item.active span {
    opacity: 1;
    font-weight: 800;
}

/* Active indicator dot */
.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    width: 4px;
    height: 4px;
    background: var(--accent);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent);
}


/* --- Premium Navigation Overhaul (v3.1.4) --- */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2000;
    background: var(--nav-bg);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-top: 1px solid var(--border);
    padding-bottom: env(safe-area-inset-bottom);
    height: 75px;
    box-shadow: 0 -10px 40px rgba(0,0,0,0.1);
}

/* Premium Icon Glow Animation */
.nav-item.active .nav-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-item.active .nav-icon-wrapper::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 40px;
    background: radial-gradient(circle, rgba(161, 98, 7, 0.4) 0%, transparent 75%);
    border-radius: 50%;
    z-index: -1;
    animation: premiumGlowPulse 2s infinite alternate;
}

@keyframes premiumGlowPulse {
    from { opacity: 0.4; transform: scale(0.85); }
    to { opacity: 1; transform: scale(1.15); }
}

.nav-item .badge {
    position: absolute;
    top: -5px;
    right: -8px;
    background: var(--accent);
    color: #fff;
    font-size: 9px;
    min-width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    border: 2px solid var(--nav-bg);
    box-shadow: 0 2px 8px rgba(161, 98, 7, 0.4);
    z-index: 5;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cart-pop {
    animation: cartBounce 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes cartBounce {
    0% { transform: scale(1); }
    30% { transform: scale(1.4) rotate(-10deg); }
    50% { transform: scale(1.1) rotate(5deg); }
    100% { transform: scale(1); }
}

.nav-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    height: 100%;
    max-width: 500px;
    margin: 0 auto;
    padding: 0 10px;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.2, 1, 0.3, 1);
    color: #555;
    flex: 1;
    min-width: 45px;
}

.nav-item i {
    font-size: 20px;
    margin-bottom: 2px;
    transition: all 0.3s ease;
}

.nav-item span {
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.2, 1, 0.3, 1);
    white-space: nowrap;
}

/* Active State: The label appears elegantly */
.nav-item.active {
    color: var(--accent) !important;
    flex: 2; /* Expands to make room for text */
}

.nav-item.active i {
    transform: translateY(-2px);
    filter: drop-shadow(0 0 10px rgba(161, 98, 7, 0.5));
}

.nav-item.active span {
    max-height: 20px;
    opacity: 1;
    margin-top: 4px;
}

/* Page Transition Animation */
.animate-page-enter {
    animation: premiumFadeUp 0.6s cubic-bezier(0.2, 1, 0.3, 1) forwards;
}

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


/* --- Premium Search UI (v3.1.5) --- */
.premium-search-container {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    padding: 12px 18px;
    transition: all 0.4s cubic-bezier(0.2, 1, 0.3, 1);
    box-shadow: inset 0 2px 5px rgba(0,0,0,0.2);
}

.premium-search-container:focus-within {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(161, 98, 7, 0.4);
    box-shadow: 0 0 25px rgba(161, 98, 7, 0.15), inset 0 1px 2px rgba(255,255,255,0.05);
    transform: translateY(-1px);
}

.premium-search-container input {
    background: transparent !important;
    border: none !important;
    outline: none !important;
    color: var(--foreground) !important;
    font-size: 15px !important;
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    font-weight: 500;
}

.premium-search-container input::placeholder {
    color: rgba(255,255,255,0.25);
    font-weight: 400;
}

.premium-search-container i.search-icon {
    font-size: 18px;
    color: rgba(161, 98, 7, 0.6);
    margin-right: 15px;
    transition: all 0.3s ease;
}

.premium-search-container:focus-within i.search-icon {
    color: var(--accent);
    transform: scale(1.1);
}

#clear-search-btn {
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    cursor: pointer;
    color: #444;
}

/* --- Checkout Delivery Options --- */
.delivery-option {
    display: block;
    cursor: pointer;
}

.delivery-option input {
    display: none;
}

.delivery-box {
    padding: 16px;
    border-radius: 16px;
    background: var(--item-bg);
    border: 1px solid var(--border);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.delivery-option input:checked + .delivery-box {
    background: rgba(161, 98, 7, 0.1);
    border-color: var(--accent);
    box-shadow: 0 5px 15px rgba(161, 98, 7, 0.15);
}

.delivery-option input:checked + .delivery-box i {
    color: var(--accent);
}

.liquid-glass.active {
    background: var(--accent) !important;
    color: #fff !important;
    border-color: var(--accent) !important;
}

#clear-search-btn.visible {
    opacity: 1;
    pointer-events: auto;
}

#clear-search-btn:hover {
    color: var(--accent);
}

/* --- Premium Profile Redesign (v3.1.6) --- */
.profile-group-header {
    font-size: 11px;
    font-weight: 800;
    color: #666;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin: 35px 20px 12px;
}

.profile-list-item {
    background: var(--item-bg);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.profile-list-item:active {
    background: rgba(255, 255, 255, 0.05);
    transform: scale(0.99);
}

.profile-list-item:first-of-type { border-radius: 20px 20px 0 0; }
.profile-list-item:last-of-type { border-radius: 0 0 20px 20px; }
.profile-list-item:only-of-type { border-radius: 20px; }

/* Separator between items */
.profile-list-item:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.id-badge {
    background: rgba(161, 98, 7, 0.1);
    border: 1px solid rgba(161, 98, 7, 0.4);
    border-radius: 50px;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 800;
    color: var(--accent);
    display: inline-block;
    letter-spacing: 0.05em;
    font-family: 'Montserrat', sans-serif;
}

.modern-toggle {
    width: 50px;
    height: 30px;
    background: #333;
    border-radius: 50px;
    position: relative;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255,255,255,0.05);
}

.modern-toggle.active {
    background: #4ade80; /* Premium Green */
    border-color: #22c55e;
}

.modern-toggle .dot {
    position: absolute;
    left: 4px;
    top: 4px;
    width: 22px;
    height: 22px;
    background: #fff;
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
}

.modern-toggle.active .dot {
    left: 24px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 24px;
    padding: 24px;
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:active {
    transform: scale(0.97);
    background: rgba(255, 255, 255, 0.05);
}

.avatar-large {
    width: 100px;
    height: 100px;
    border-radius: 28px;
    background: linear-gradient(135deg, var(--accent) 0%, #D4A017 100%);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 800;
    color: #000;
    box-shadow: 0 10px 30px rgba(161, 98, 7, 0.3);
}

/* --- Premium Light Mode Overrides (v3.1.7) --- */
[data-theme="light"] .profile-list-item {
    background: rgba(255, 255, 255, 0.4);
    border-color: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .stat-card {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.03);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03), inset 0 0 0 1px rgba(255,255,255,0.8);
}

[data-theme="light"] .profile-group-header {
    color: #a0aec0; /* Lighter grey for headers in light mode */
}

[data-theme="light"] .id-badge {
    background: rgba(161, 98, 7, 0.05);
    border-color: rgba(161, 98, 7, 0.2);
}

[data-theme="light"] .avatar-large {
    box-shadow: 0 8px 25px rgba(161, 98, 7, 0.15);
}

[data-theme="light"] .profile-list-item i.fa-chevron-right {
    color: #cbd5e0 !important;
}

[data-theme="light"] #profile-email-header, 
[data-theme="light"] #profile-email-val, 
[data-theme="light"] #profile-phone-val, 
[data-theme="light"] #profile-birthday-val, 
[data-theme="light"] #profile-region-val,
[data-theme="light"] #vip-expiry-text {
    color: #718096 !important;
}

/* --- Profile Edit UI (v3.1.8) --- */
.edit-pencil {
    font-size: 14px;
    color: var(--accent);
    margin-left: 10px;
    cursor: pointer;
    opacity: 0.6;
    transition: all 0.3s ease;
}

.edit-pencil:hover {
    opacity: 1;
    transform: scale(1.1);
}

.avatar-container {
    position: relative;
    cursor: pointer;
}

.avatar-edit-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.4);
    border-radius: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s auto;
    color: #fff;
    font-size: 20px;
}

.avatar-container:hover .avatar-edit-overlay {
    opacity: 1;
}

/* Modal for Editing (v3.3.1 - Centered Fix) */
.premium-modal {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.85);
    backdrop-filter: blur(15px);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.premium-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    background: var(--glass-bg);
    border: 1px solid var(--border);
    border-radius: 32px;
    padding: 35px 30px;
    width: 100%;
    max-width: 380px;
    transform: scale(0.9) translateY(20px);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 30px 60px rgba(0,0,0,0.6);
}

.premium-modal.active .modal-card {
    transform: scale(1) translateY(0);
}

/* --- Premium Product Detail --- */
.detail-gallery {
    position: relative;
    width: 100%;
    height: 480px;
    background: #000;
}

.detail-slider-track {
    display: flex;
    height: 100%;
    transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.detail-slide {
    flex: 0 0 100%;
    height: 100%;
}

.detail-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-dots {
    position: absolute;
    bottom: 25px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 8px;
    z-index: 5;
}

.detail-dot {
    width: 30px;
    height: 4px;
    background: rgba(255,255,255,0.2);
    border-radius: 2px;
    transition: 0.3s;
}

.detail-dot.active {
    background: var(--accent);
    width: 45px;
}

.detail-content-card {
    background: #0c0a09;
    border-radius: 40px 40px 0 0;
    margin-top: -40px;
    position: relative;
    padding: 35px 20px;
    box-shadow: 0 -20px 40px rgba(0,0,0,0.5);
    z-index: 10;
}

/* Tabs */
.premium-tabs {
    display: flex;
    gap: 30px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    margin-bottom: 25px;
}

.premium-tab {
    padding: 12px 5px;
    font-size: 14px;
    font-weight: 700;
    color: #666;
    position: relative;
    cursor: pointer;
    transition: 0.3s;
}

.premium-tab.active {
    color: var(--accent);
}

.premium-tab.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent);
    box-shadow: 0 0 15px var(--accent);
}

.tab-pane {
    display: none;
    animation: fadeIn 0.4s ease;
}

.tab-pane.active {
    display: block;
}

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

.spec-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px dashed rgba(255,255,255,0.05);
    font-size: 14px;
}

.spec-label { color: #666; }
.spec-value { color: #eee; font-weight: 600; }

.detail-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: rgba(5,5,5,0.8);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    gap: 15px;
    z-index: 100;
}

/* =========================================
   ULTRA-PREMIUM VIP DESIGN SYSTEM
   ========================================= */


.vip-premium-card {
    position: relative;
    padding: 32px 28px; /* Increased top padding */
    border-radius: 35px;
    /* Luxury Gradient with Silk Texture hint */
    background: 
        var(--vip-bg),
        url('data:image/svg+xml,<svg width="100" height="100" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h100v100H0z" fill="none"/><path d="M10 10l80 80M90 10L10 90" stroke="rgba(161,98,7,0.03)" stroke-width="0.5"/></svg>');
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid rgba(161, 98, 7, 0.4);
    overflow: hidden;
    box-shadow: var(--vip-shadow);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Central Watermark Logo */
.vip-card-watermark {
    position: absolute;
    top: 50%;
    right: -30px;
    transform: translateY(-50%) rotate(-10deg);
    width: 250px;
    height: 250px;
    opacity: 0.12; /* Increased opacity for better visibility */
    pointer-events: none;
    z-index: 1;
    filter: drop-shadow(0 0 15px rgba(161, 98, 7, 0.3));
}

.vip-premium-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at center, rgba(161, 98, 7, 0.12) 0%, transparent 70%);
    animation: vipPulse 10s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

.vip-shine-line {
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0) 30%, 
        rgba(255, 247, 237, 0.15) 50%, 
        rgba(255, 255, 255, 0) 70%, 
        transparent 100%
    );
    transform: skewX(-25deg);
    animation: vipShine 4s infinite;
    pointer-events: none;
}

@keyframes vipShine {
    0% { left: -150%; }
    40% { left: 150%; }
    100% { left: 150%; }
}

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

.vip-badge-floating {
    position: absolute;
    top: 15px; /* Moved higher */
    right: 15px; /* Moved further right */
    background: linear-gradient(135deg, #a16207 0%, #ca8a04 100%);
    color: #fff;
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3), 0 0 15px rgba(161, 98, 7, 0.4);
    z-index: 5;
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
}

.avatar-premium-wrap {
    position: relative;
    padding: 4px;
    border-radius: 30px;
    background: linear-gradient(45deg, #A16207, #FDE68A, #A16207);
    background-size: 200% 200%;
    animation: borderRotate 4s linear infinite;
    display: inline-block;
}

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

.profile-id-pill {
    background: rgba(161, 98, 7, 0.15);
    border: 1px solid rgba(161, 98, 7, 0.2);
    color: #EAB308;
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* =========================================
   VIP CLUB MODAL
   ========================================= */
.vip-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.vip-modal.active {
    opacity: 1;
    pointer-events: all;
}

.vip-modal-card {
    width: 90%;
    max-width: 400px;
    background: linear-gradient(135deg, rgba(28,25,23,0.95), rgba(40,30,20,0.95));
    border: 1px solid rgba(161, 98, 7, 0.4);
    border-radius: 32px;
    padding: 30px 25px;
    position: relative;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 30px 60px rgba(0,0,0,0.5), inset 0 0 20px rgba(161,98,7,0.1);
    overflow: hidden;
}

.vip-modal.active .vip-modal-card {
    transform: scale(1) translateY(0);
}

[data-theme="light"] .vip-modal-card {
    background: linear-gradient(135deg, rgba(255,250,240,0.95), rgba(255,255,255,0.95));
    border: 1px solid rgba(161, 98, 7, 0.2);
    box-shadow: 0 30px 60px rgba(161,98,7,0.15), inset 0 0 20px rgba(161,98,7,0.05);
}

.vip-feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255,255,255,0.03);
    border-radius: 16px;
    margin-bottom: 10px;
    border: 1px solid rgba(255,255,255,0.02);
}

[data-theme="light"] .vip-feature-item {
    background: rgba(0,0,0,0.02);
    border: 1px solid rgba(0,0,0,0.05);
}

.vip-feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(161,98,7,0.2), rgba(202,138,4,0.1));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #EAB308;
    font-size: 18px;
}

.pay-btn-vip {
    width: 100%;
    padding: 16px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 12px;
    transition: transform 0.2s, filter 0.2s;
    border: 1px solid transparent;
}

.pay-btn-vip:active {
    transform: scale(0.98);
    filter: brightness(0.9);
}

.pay-btn-payme {
    background: rgba(0, 193, 175, 0.1);
    border-color: rgba(0, 193, 175, 0.3);
    color: #00c1af;
}

.pay-btn-click {
    background: rgba(0, 135, 255, 0.1);
    border-color: rgba(0, 135, 255, 0.3);
    color: #0087ff;
}

[data-theme="light"] .pay-btn-payme { background: #e0f8f6; }
[data-theme="light"] .pay-btn-click { background: #e0f0ff; }

::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

[data-theme="light"] ::placeholder {
    color: rgba(0, 0, 0, 0.35);
}

[data-theme="light"] select {
    color: #000;
}

/* Premium Heart Fix for v6.0.0 */
.premium-heart-fix {
    mix-blend-mode: multiply;
}
[data-theme="dark"] .premium-heart-fix {
    filter: invert(1) hue-rotate(180deg) brightness(1.1);
    mix-blend-mode: screen;
}
