/* digital-store-base.css */
/* Base styles, variables, and global elements */

:root {
    --primary: #7bc2bb;
    --dark-teal: #174c54;
    --medium-teal: #1f6f75;
    --gold: #e2bf94;
    --forest: #4d827c;
    --brown: #847648;
    --text-dark: #1a1a1a;
    --text-light: #f0f0f0;
    --bg-light: #ffffff;
    --bg-dark: #0a0a0a;
    --gradient-1: linear-gradient(135deg, #7bc2bb 0%, #1f6f75 100%);
    --gradient-2: linear-gradient(45deg, #174c54 0%, #4d827c 50%, #7bc2bb 100%);
    --gradient-3: linear-gradient(180deg, #7bc2bb 0%, #e2bf94 100%);
    --success: #4CAF50;
    --error: #f44336;
    --favorite: #e91e63;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --mobile-padding: 15px;
    --desktop-padding: 5%;
    --nav-height: 70px;
    --nav-height-scrolled: 60px;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    overflow-x: hidden;
    background: var(--bg-light);
    color: var(--text-dark);
    transition: var(--transition-smooth);
    position: relative;
    min-height: 100vh;
}

body.dark-mode {
    background: var(--bg-dark);
    color: var(--text-light);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(123, 194, 187, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-1);
    border-radius: 4px;
    transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
    box-shadow: 0 0 10px rgba(123, 194, 187, 0.5);
}

body.dark-mode ::-webkit-scrollbar-track {
    background: rgba(123, 194, 187, 0.05);
}

body.dark-mode ::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #7bc2bb 0%, #174c54 100%);
}

/* Hide cursor on touch devices */
@media (hover: none) and (pointer: coarse) {
    * {
        cursor: auto !important;
    }
    .cursor,
    .cursor-dot {
        display: none !important;
    }
}

/* Custom Cursor - Desktop Only */
@media (hover: hover) and (pointer: fine) {
    * {
        cursor: none;
    }
    
    .cursor {
        width: 12px;
        height: 12px;
        border: 1.5px solid var(--primary);
        border-radius: 3px;
        position: fixed;
        pointer-events: none;
        z-index: 9999;
        background: rgba(123, 194, 187, 0.1);
        transition: all 0.15s cubic-bezier(0.16, 1, 0.3, 1);
        transform: translate(-50%, -50%) rotate(45deg);
        display: none;
    }

    body:hover .cursor {
        display: block;
    }

    .cursor-dot {
        width: 4px;
        height: 4px;
        background: var(--primary);
        border-radius: 50%;
        position: fixed;
        pointer-events: none;
        z-index: 10000;
        transform: translate(-50%, -50%);
        transition: opacity 0.3s ease;
        display: none;
    }

    body:hover .cursor-dot {
        display: block;
    }

    .cursor.hover {
        width: 24px;
        height: 24px;
        background: rgba(123, 194, 187, 0.2);
        border-width: 1px;
        transform: translate(-50%, -50%) rotate(0deg);
        border-radius: 50%;
    }
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 1s cubic-bezier(0.7, 0, 0.3, 1);
}

body.dark-mode .preloader {
    background: rgba(10, 10, 10, 0.98);
}

.preloader.hide {
    opacity: 0;
    visibility: hidden;
    transform: scale(1.5);
}

.loader {
    position: relative;
    width: 150px;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loader-text {
    position: absolute;
    font-size: 2.5rem;
    font-weight: 900;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    z-index: 10;
    animation: text-pulse 2s ease infinite;
}

.loader-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    animation: loader-rotate 2s linear infinite;
}

.loader-ring:nth-child(2) {
    border: 3px solid transparent;
    border-top-color: var(--primary);
    animation-delay: 0s;
}

.loader-ring:nth-child(3) {
    border: 3px solid transparent;
    border-right-color: var(--gold);
    animation-delay: 0.2s;
    width: 80%;
    height: 80%;
    top: 10%;
    left: 10%;
}

.loader-ring:nth-child(4) {
    border: 3px solid transparent;
    border-bottom-color: var(--forest);
    animation-delay: 0.4s;
    width: 60%;
    height: 60%;
    top: 20%;
    left: 20%;
}

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

@keyframes text-pulse {
    0%, 100% { 
        opacity: 0.8; 
        transform: scale(1) rotate(0deg); 
    }
    50% { 
        opacity: 1; 
        transform: scale(1.1) rotate(5deg); 
    }
}

/* Scroll Progress */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--gradient-1);
    z-index: 10002;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px rgba(123, 194, 187, 0.8);
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 15px var(--desktop-padding);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    transition: var(--transition-smooth);
    height: var(--nav-height);
    display: flex;
    align-items: center;
}

body.dark-mode nav {
    background: rgba(10, 10, 10, 0.95);
}

nav.scrolled {
    padding: 10px var(--desktop-padding);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    height: var(--nav-height-scrolled);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.logo {
    font-size: 28px;
    font-weight: 900;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 3s ease infinite;
    letter-spacing: -1px;
}

@keyframes gradient-shift {
    0%, 100% { filter: hue-rotate(0deg) brightness(1); }
    50% { filter: hue-rotate(20deg) brightness(1.2); }
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
    justify-content: center;
    flex: 1;
    padding: 0 50px;
}

.nav-link {
    position: relative;
    color: inherit;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition-smooth);
    padding: 5px 0;
    letter-spacing: 0.5px;
    font-size: 15px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-1);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    transform: translateY(-2px);
}

.theme-toggle {
    width: 50px;
    height: 25px;
    background: var(--gradient-1);
    border-radius: 25px;
    position: relative;
    cursor: pointer;
    transition: var(--transition-smooth);
    box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.1);
}

.theme-toggle:hover {
    transform: scale(1.05);
}

.theme-toggle-ball {
    width: 21px;
    height: 21px;
    background: white;
    border-radius: 50%;
    position: absolute;
    top: 2px;
    left: 2px;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

body.dark-mode .theme-toggle-ball {
    transform: translateX(25px);
}

/* Mobile Menu */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    padding: 5px;
    z-index: 1001;
}

.menu-line {
    width: 25px;
    height: 2.5px;
    background: var(--primary);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border-radius: 2px;
}

.mobile-menu-toggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

.mobile-menu-toggle.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Particles Background */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--primary);
    border-radius: 50%;
    opacity: 0.3;
    animation: particle-float 20s infinite linear;
}

@keyframes particle-float {
    from {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.3;
    }
    90% {
        opacity: 0.3;
    }
    to {
        transform: translateY(-100px) rotate(360deg);
        opacity: 0;
    }
}

/* Store Hero Section */
.store-hero {
    padding: calc(var(--nav-height) + 50px) var(--desktop-padding) 50px;
    text-align: center;
    position: relative;
    overflow: hidden;
    background: radial-gradient(ellipse at top, rgba(123, 194, 187, 0.05) 0%, transparent 70%);
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    z-index: 1;
    position: relative;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 900;
    margin-bottom: 20px;
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: text-glow 3s ease infinite;
    letter-spacing: -1px;
    line-height: 1.2;
}

@keyframes text-glow {
    0%, 100% {
        filter: brightness(1) drop-shadow(0 0 20px rgba(123, 194, 187, 0.3));
    }
    50% {
        filter: brightness(1.2) drop-shadow(0 0 30px rgba(123, 194, 187, 0.5));
    }
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    opacity: 0.9;
    margin-bottom: 40px;
    line-height: 1.5;
}

/* Currency Modal */
.currency-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 5000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.currency-modal.active {
    opacity: 1;
    visibility: visible;
}

.currency-modal-content {
    background: white;
    border-radius: 20px;
    padding: 40px 30px;
    max-width: 500px;
    width: 100%;
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    max-height: 90vh;
    overflow-y: auto;
}

body.dark-mode .currency-modal-content {
    background: var(--dark-teal);
}

.currency-modal.active .currency-modal-content {
    transform: scale(1);
}

.currency-modal h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.currency-modal p {
    margin-bottom: 25px;
    opacity: 0.9;
    font-size: 0.95rem;
}

.currency-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.currency-input-container {
    position: relative;
}

.currency-input {
    width: 100%;
    padding: 15px;
    border: 2px solid rgba(123, 194, 187, 0.3);
    border-radius: 15px;
    font-size: 16px;
    background: rgba(123, 194, 187, 0.05);
    color: var(--text-dark);
    transition: var(--transition-smooth);
    outline: none;
}

body.dark-mode .currency-input {
    background: rgba(123, 194, 187, 0.1);
    color: var(--text-light);
}

.currency-input:focus {
    border-color: var(--primary);
    background: rgba(123, 194, 187, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(123, 194, 187, 0.2);
}

.currency-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 15px;
    margin-top: 10px;
    max-height: 280px;
    overflow-y: auto;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-20px) scale(0.95);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
}

body.dark-mode .currency-suggestions {
    background: var(--dark-teal);
}

.currency-suggestions.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.currency-item {
    padding: 15px;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid rgba(123, 194, 187, 0.1);
    position: relative;
    overflow: hidden;
}

.currency-item::before {
    content: '';
    position: absolute;
    left: -100%;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(123, 194, 187, 0.1);
    transition: left 0.3s ease;
}

.currency-item:hover::before {
    left: 0;
}

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

.currency-item:hover {
    padding-left: 25px;
}

.currency-flag {
    font-size: 1.3rem;
}

.currency-info {
    flex: 1;
}

.currency-name {
    font-weight: 600;
    display: block;
    font-size: 0.95rem;
}

.currency-code {
    font-size: 0.85rem;
    opacity: 0.7;
}

.location-btn {
    width: 100%;
    padding: 15px;
    background: var(--gradient-1);
    color: white;
    border: none;
    border-radius: 15px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.location-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(123, 194, 187, 0.4);
}

/* Footer */
footer {
    padding: 80px var(--desktop-padding) 40px;
    background: var(--dark-teal);
    color: white;
    position: relative;
    overflow: hidden;
    margin-top: 100px;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, var(--primary) 50%, transparent 100%);
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 50px;
    margin-bottom: 50px;
}

.footer-section h3 {
    margin-bottom: 25px;
    color: var(--primary);
    font-size: 1.5rem;
}

.footer-section p {
    margin-bottom: 15px;
    opacity: 0.9;
    line-height: 1.6;
}

.footer-links {
    list-style: none;
}

.footer-link {
    display: block;
    padding: 8px 0;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition-smooth);
}

.footer-link:hover {
    color: var(--primary);
    transform: translateX(10px);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.social-link {
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: var(--transition-smooth);
}

.social-link:hover {
    background: var(--primary);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(123, 194, 187, 0.4);
}

.footer-bottom {
    text-align: center;
    padding-top: 35px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.8;
}

/* Button Styles */
.btn {
    padding: 15px 40px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-primary {
    background: var(--gradient-1);
    color: white;
    box-shadow: 0 10px 30px rgba(123, 194, 187, 0.4);
}

.btn-primary:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(123, 194, 187, 0.6);
}

/* Notification System */
.notification {
    position: fixed;
    top: 80px;
    right: -400px;
    max-width: 350px;
    padding: 20px 25px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    transition: right 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 3000;
    display: flex;
    align-items: center;
    gap: 15px;
}

body.dark-mode .notification {
    background: var(--dark-teal);
}

.notification.show {
    right: 25px;
}

.notification-icon {
    width: 40px;
    height: 40px;
    background: var(--gradient-1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-weight: 700;
    margin-bottom: 3px;
    color: var(--dark-teal);
    font-size: 0.95rem;
}

body.dark-mode .notification-title {
    color: white;
}

.notification-message {
    font-size: 0.9rem;
    opacity: 0.8;
}

.notification-close {
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0.5;
    transition: var(--transition-smooth);
    font-size: 18px;
}

.notification-close:hover {
    opacity: 1;
    transform: rotate(90deg);
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus styles */
*:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .btn {
        border: 2px solid currentColor;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .particles {
        display: none;
    }
}

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

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 10px 30px rgba(123, 194, 187, 0.3);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 15px 40px rgba(123, 194, 187, 0.5);
    }
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* Ripple Effect */
.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: scale(0);
    animation: ripple 0.6s ease-out;
    pointer-events: none;
}

/* Touch device optimizations */
.touch-device {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}

/* Print styles */
@media print {
    nav, .cart-button, .favorites-button, .cart-sidebar, .favorites-sidebar, 
    .filters-section, .game-section, .telegram-promo, .scroll-progress, 
    .cursor, .cursor-dot, .particles {
        display: none !important;
    }

    .product-card {
        page-break-inside: avoid;
    }

    body {
        background: white !important;
        color: black !important;
    }
}