/*
Theme Name: Visionary Portfolio
Theme URI: https://example.com
Author: Your Name
Description: A fully editable, Elementor-ready portfolio theme with dynamic blog support.
Version: 2.0.0
Text Domain: visionary
*/

/* =========================================
   1. CORE VARIABLES (Editable in Customizer)
   ========================================= */
:root {
    --primary-color: #FFD700;       /* Gold */
    --primary-dim: #b39700;
    --bg-color: #050505;            /* Black */
    --bg-soft: #0a0a0a;
    --text-main: #ffffff;
    --text-muted: #a0a0a0;
    --sidebar-width: 100px;
    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Space Grotesk', sans-serif;
}

/* =========================================
   2. GLOBAL RESET & BASE STYLES
   ========================================= */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
img { max-width: 100%; height: auto; }

/* Scrollbar */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-color); }
::-webkit-scrollbar-thumb { background: var(--primary-dim); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary-color); }

/* =========================================
   3. LAYOUT & STRUCTURE
   ========================================= */
.main-content {
    margin-left: var(--sidebar-width);
    width: calc(100% - var(--sidebar-width));
    min-height: 100vh;
    position: relative;
    transition: margin 0.3s ease;
}

.container {
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    max-width: 1400px;
}

.section-padding { padding: 100px 0; }

/* Mobile Responsive */
@media (max-width: 768px) {
    :root { --sidebar-width: 0px; }
    .main-content { margin-left: 0; width: 100%; }
    .sidebar { display: none; }
    .mobile-toggle { display: flex; }
}

/* =========================================
   4. SIDEBAR & NAVIGATION
   ========================================= */
.sidebar {
    position: fixed;
    left: 0; top: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: rgba(10, 10, 10, 0.95);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 0;
}

.logo-area {
    width: 50px; height: 50px;
    margin-bottom: auto;
}
.logo-area img { width: 100%; height: 100%; object-fit: contain; }

.nav-menu ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.nav-menu a {
    color: var(--text-muted);
    font-size: 20px;
    position: relative;
}

.nav-menu a:hover, .current-menu-item a {
    color: var(--primary-color);
    transform: scale(1.1);
}

/* =========================================
   5. BLOG & POST STYLES
   ========================================= */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 50px;
}

.post-card {
    background: var(--bg-soft);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
    overflow: hidden;
    transition: 0.3s;
}

.post-card:hover { transform: translateY(-5px); border-color: var(--primary-color); }

.post-thumb { height: 200px; overflow: hidden; }
.post-thumb img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s; }
.post-card:hover .post-thumb img { transform: scale(1.1); }

.post-content { padding: 25px; }
.post-title { font-family: var(--font-heading); font-size: 1.5rem; margin-bottom: 10px; }
.post-meta { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 15px; }

.btn-read {
    display: inline-block;
    margin-top: 10px;
    color: var(--primary-color);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
}

/* Single Post */
.single-post-container { max-width: 800px; margin: 0 auto; padding: 60px 20px; }
.single-post-title { font-size: 3rem; margin-bottom: 20px; font-family: var(--font-heading); }
.single-post-content { font-size: 1.1rem; line-height: 1.8; color: #ddd; }
.single-post-content p { margin-bottom: 25px; }

/* =========================================
   6. ELEMENTOR & WP UTILS
   ========================================= */
.mobile-toggle {
    display: none;
    position: fixed;
    top: 25px; right: 25px;
    z-index: 2001;
    width: 50px; height: 50px;
    background: rgba(0,0,0,0.8);
    border: 1px solid var(--primary-color);
    border-radius: 50%;
    color: var(--primary-color);
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

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