:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #111111;
    --bg-card: #1a1a1a;
    --bg-hover: #222222;
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --text-muted: #666666;
    --border-color: #2a2a2a;
    --accent-color: #ffffff;
    --transition-speed: 0.3s;
    --border-radius: 12px;
    --max-width: 1200px;
    --header-height: 70px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.preloader {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-color: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.fade-out { opacity: 0; visibility: hidden; }

.preloader-content { text-align: center; }
.preloader-logo { margin-bottom: 20px; animation: pulse 2s ease-in-out infinite; }
.preloader-text {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 20px;
    letter-spacing: 2px;
}
.preloader-bar {
    width: 200px; height: 2px;
    background-color: var(--bg-secondary);
    border-radius: 1px;
    overflow: hidden;
}
.preloader-bar-fill {
    width: 0%; height: 100%;
    background-color: var(--text-primary);
    animation: loading 2s ease-in-out infinite;
}

@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }
@keyframes loading { 0% { width: 0%; } 50% { width: 100%; } 100% { width: 0%; } }

.header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--header-height);
    background-color: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
}

.header-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-left { display: flex; align-items: center; }
.logo-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-primary);
}
.header-title { font-size: 16px; font-weight: 500; letter-spacing: 0.5px; }
.header-right { display: flex; align-items: center; }

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    width: 30px; height: 30px;
    background: none;
    border: none;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 100%; height: 2px;
    background-color: var(--text-primary);
    margin: 3px 0;
    transition: all 0.3s ease;
}

.header-nav { display: flex; gap: 20px; align-items: center; }
.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: color var(--transition-speed) ease;
}
.nav-link:hover { color: var(--text-primary); }
.admin-link {
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    transition: all var(--transition-speed) ease;
}
.admin-link:hover { border-color: var(--text-primary); }

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding-top: var(--header-height);
}

.hero-content { text-align: center; z-index: 2; padding: 20px; }
.hero-title { font-size: 48px; font-weight: 700; margin-bottom: 16px; letter-spacing: -1px; }
.hero-subtitle { font-size: 18px; color: var(--text-secondary); max-width: 600px; margin: 0 auto; }

.hero-background {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 1;
}

.hero-grid {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: 
        linear-gradient(to right, var(--bg-secondary) 1px, transparent 1px),
        linear-gradient(to bottom, var(--bg-secondary) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.5;
}

.main-content {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 40px 20px;
}

.products-section { margin-bottom: 80px; }
.section-header { margin-bottom: 40px; text-align: center; }
.section-title { font-size: 32px; font-weight: 600; margin-bottom: 8px; }
.section-description { font-size: 16px; color: var(--text-secondary); }

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.product-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: all var(--transition-speed) ease;
    cursor: pointer;
}

.product-card:hover {
    transform: translateY(-4px);
    border-color: var(--text-muted);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.product-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background-color: var(--bg-secondary);
}

.product-content { padding: 20px; }
.product-logo { width: 48px; height: 48px; margin-bottom: 16px; }
.product-title { font-size: 20px; font-weight: 600; margin-bottom: 8px; }
.product-description {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 16px;
}

.product-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.product-link {
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 14px;
    transition: all var(--transition-speed) ease;
}
.product-link:hover {
    border-color: var(--text-primary);
    background-color: var(--bg-hover);
}
.product-link.primary {
    background-color: var(--text-primary);
    color: var(--bg-primary);
    border-color: var(--text-primary);
}
.product-link.primary:hover {
    background-color: transparent;
    color: var(--text-primary);
}

.footer {
    background-color: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    padding: 40px 20px;
    margin-top: 80px;
}

.footer-container {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-left { display: flex; align-items: center; gap: 16px; }
.footer-logo { font-size: 18px; font-weight: 600; }
.footer-copyright { font-size: 14px; color: var(--text-secondary); }
.footer-founder { font-size: 14px; color: var(--text-secondary); }

.no-products {
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
    font-size: 16px;
}

@media (max-width: 768px) {
    .hero-title { font-size: 32px; }
    .hero-subtitle { font-size: 16px; }
    .menu-toggle { display: flex; }
    
    .header-nav {
        position: fixed;
        top: var(--header-height);
        left: 0; right: 0;
        background-color: var(--bg-primary);
        flex-direction: column;
        padding: 20px;
        gap: 16px;
        transform: translateY(-100%);
        transition: transform var(--transition-speed) ease;
        border-bottom: 1px solid var(--border-color);
    }
    
    .header-nav.active { transform: translateY(0); }
    .products-grid { grid-template-columns: 1fr; gap: 16px; }
    .footer-container { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
    .header-title { font-size: 14px; }
    .hero-title { font-size: 28px; }
    .section-title { font-size: 24px; }
    .product-image { height: 160px; }
}
