/*
 * Main Stylesheet for Imran Khan Farooq Personal Website
 * Author: IKF Trading
 * Version: 1.0
 */

/* ==========================================================================
   1. BASE STYLES
   ========================================================================== */

:root {
    --primary-color: #ffcd38;
    --secondary-color: #f5f5f5;
    --text-color: #d5d5d5;
    --heading-color: #f5f5f5;
    --bg-dark: #000000;
    --bg-gray: #222222;
    --bg-light: #333333;
    --border-color: #333333;
    --transition: all 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'PT Sans', Helvetica, sans-serif;
    font-size: 14px;
    line-height: 1.75em;
    color: var(--text-color);
    background-color: var(--bg-dark);
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Oswald', Helvetica, sans-serif;
    font-weight: 400;
    color: var(--heading-color);
    margin-bottom: 20px;
}

h1 { font-size: 32px; }
h2 { font-size: 27px; }
h3 { font-size: 21px; }
h4 { font-size: 18px; }
h5 { font-size: 16px; }
h6 { font-size: 14px; }

p {
    margin-bottom: 15px;
}

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

a:hover {
    color: var(--secondary-color);
}

img {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   2. PRELOADER
   ========================================================================== */

.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-dark);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.preloader-animation {
    width: 60px;
    height: 60px;
}

.preloader-spinner {
    width: 100%;
    height: 100%;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ==========================================================================
   3. LAYOUT
   ========================================================================== */

.page-layout {
    display: flex;
    min-height: 100vh;
}

/* ==========================================================================
   4. HEADER / SIDEBAR
   ========================================================================== */

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 22%;
    height: 100vh;
    background: var(--bg-gray);
    padding: 40px 30px;
    overflow-y: auto;
    z-index: 100;
}

.header-content {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.header-image {
    text-align: center;
    margin-bottom: 30px;
}

.header-image img {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary-color);
}

.site-title-block {
    text-align: center;
    margin-bottom: 40px;
}

.site-title {
    font-size: 30px;
    margin-bottom: 10px;
    line-height: 1.1em;
}

.site-subtitle {
    font-size: 16px;
    font-weight: 300;
    color: #eeeeee;
}

/* Navigation */
.site-nav {
    margin-bottom: auto;
}

.site-main-menu {
    list-style: none;
}

.site-main-menu li {
    margin-bottom: 5px;
}

.site-main-menu li a {
    display: block;
    padding: 12px 20px;
    color: var(--secondary-color);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

.site-main-menu li:first-child a {
    border-top: 1px solid var(--border-color);
}

.site-main-menu li a:hover,
.site-main-menu li.active a {
    background-color: var(--bg-light);
    color: var(--primary-color);
}

.site-main-menu li a i {
    margin-right: 10px;
    width: 20px;
    display: inline-block;
}

/* Social Links */
.header-social-links {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 20px;
}

.header-social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border-radius: 50%;
    color: var(--secondary-color);
    font-size: 18px;
    margin: 0 5px;
    transition: var(--transition);
}

.header-social-links a:hover {
    background-color: var(--primary-color);
    color: var(--bg-dark);
}

/* Copyrights */
.header-copyrights {
    text-align: center;
    font-size: 12px;
    color: #999;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 101;
}

.menu-toggle {
    background: var(--primary-color);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 5px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--bg-dark);
    transition: var(--transition);
}

/* ==========================================================================
   5. MAIN CONTENT
   ========================================================================== */

.site-main {
    margin-left: 22%;
    width: 78%;
    padding: 60px;
}

.page-content {
    max-width: 1200px;
    margin: 0 auto;
}

/* ==========================================================================
   6. SECTIONS
   ========================================================================== */

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

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 36px;
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.section-title h2:after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--primary-color);
}

.section-subtitle {
    font-size: 16px;
    color: #999;
}

/* ==========================================================================
   7. PAGE HEADER
   ========================================================================== */

.page-header {
    background: var(--bg-gray);
    padding: 60px 0;
    margin-bottom: 60px;
}

.page-title {
    font-size: 42px;
    margin-bottom: 10px;
}

/* ==========================================================================
   8. BUTTONS
   ========================================================================== */

.btn {
    display: inline-block;
    padding: 12px 30px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    border-radius: 3px;
    transition: var(--transition);
    border: 2px solid transparent;
    cursor: pointer;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--bg-dark);
}

.btn-primary:hover {
    background: transparent;
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-secondary {
    background: transparent;
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--bg-dark);
}

.btn-lg {
    padding: 15px 40px;
    font-size: 16px;
}

.btn-block {
    display: block;
    width: 100%;
}

/* ==========================================================================
   9. FORMS
   ========================================================================== */

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--heading-color);
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    border-radius: 3px;
    font-size: 14px;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* ==========================================================================
   10. BLOG STYLES
   ========================================================================== */

.blog-post {
    background: var(--bg-gray);
    padding: 30px;
    margin-bottom: 40px;
    border-radius: 5px;
}

.post-image {
    margin-bottom: 20px;
    overflow: hidden;
    border-radius: 5px;
}

.post-image img {
    transition: transform 0.5s ease;
}

.post-image:hover img {
    transform: scale(1.05);
}

.post-meta {
    margin-bottom: 15px;
    font-size: 13px;
    color: #999;
}

.post-meta span {
    margin-right: 15px;
}

.post-meta i {
    margin-right: 5px;
}

.post-title a {
    color: var(--heading-color);
}

.post-title a:hover {
    color: var(--primary-color);
}

.post-excerpt {
    margin-bottom: 20px;
}

/* ==========================================================================
   11. PORTFOLIO STYLES
   ========================================================================== */

.portfolio-filters {
    margin-bottom: 50px;
}

.filter-btn {
    background: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-color);
    padding: 10px 25px;
    margin: 0 5px;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--bg-dark);
}

.portfolio-card {
    background: var(--bg-gray);
    margin-bottom: 30px;
    border-radius: 5px;
    overflow: hidden;
    transition: var(--transition);
}

.portfolio-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.portfolio-image {
    position: relative;
    overflow: hidden;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.portfolio-image:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-info {
    text-align: center;
    color: white;
}

.portfolio-actions a {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    background: var(--primary-color);
    color: var(--bg-dark);
    margin: 5px;
    border-radius: 50%;
}

.portfolio-content {
    padding: 20px;
}

/* ==========================================================================
   12. TIMELINE (Resume)
   ========================================================================== */

.timeline {
    position: relative;
    padding-left: 50px;
}

.timeline:before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-color);
}

.timeline-item {
    position: relative;
    margin-bottom: 40px;
}

.timeline-icon {
    position: absolute;
    left: -35px;
    width: 30px;
    height: 30px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.timeline-icon i {
    color: var(--bg-dark);
    font-size: 12px;
}

.timeline-content {
    background: var(--bg-gray);
    padding: 25px;
    border-radius: 5px;
}

.timeline-date {
    display: inline-block;
    background: var(--primary-color);
    color: var(--bg-dark);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 15px;
}

/* ==========================================================================
   13. SKILLS
   ========================================================================== */

.skill-item {
    margin-bottom: 25px;
}

.skill-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.skill-name {
    font-weight: 600;
    color: var(--heading-color);
}

.skill-percentage {
    color: var(--primary-color);
    font-weight: 600;
}

.progress {
    height: 10px;
    background: var(--bg-gray);
    border-radius: 10px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color) 0%, #ffd700 100%);
    border-radius: 10px;
    transition: width 1.5s ease;
}

/* ==========================================================================
   14. CONTACT
   ========================================================================== */

.contact-info-block {
    background: var(--bg-gray);
    padding: 30px;
    border-radius: 5px;
    height: 100%;
}

.contact-info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
}

.contact-info-item .icon {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: var(--bg-dark);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
    flex-shrink: 0;
}

.contact-info-item .icon i {
    font-size: 20px;
}

.contact-info-item h4 {
    margin-bottom: 5px;
    font-size: 16px;
}

.contact-form-block {
    background: var(--bg-gray);
    padding: 40px;
    border-radius: 5px;
}

.contact-social-links a {
    display: inline-block;
    width: 45px;
    height: 45px;
    line-height: 45px;
    text-align: center;
    background: var(--bg-dark);
    color: var(--text-color);
    margin-right: 10px;
    border-radius: 5px;
    font-size: 18px;
    transition: var(--transition);
}

.contact-social-links a:hover {
    background: var(--primary-color);
    color: var(--bg-dark);
}

/* ==========================================================================
   15. FOOTER
   ========================================================================== */

.site-footer {
    background: var(--bg-gray);
    padding: 30px 0;
    text-align: center;
    margin-top: 80px;
}

.footer-text {
    margin-bottom: 10px;
}

.footer-tagline {
    color: #999;
    font-size: 13px;
}

/* ==========================================================================
   16. UTILITIES
   ========================================================================== */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }
.mb-3 { margin-bottom: 30px; }
.mb-4 { margin-bottom: 40px; }
.mb-5 { margin-bottom: 50px; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 30px; }
.mt-4 { margin-top: 40px; }
.mt-5 { margin-top: 50px; }

.bg-light { background: var(--bg-gray); }
.bg-primary { background: var(--primary-color); }

.text-white { color: white; }

.rounded { border-radius: 5px; }
.shadow { box-shadow: 0 5px 20px rgba(0,0,0,0.3); }

/* ==========================================================================
   17. RESPONSIVE
   ========================================================================== */

@media (max-width: 991px) {
    .header {
        position: fixed;
        left: -100%;
        width: 80%;
        max-width: 300px;
        transition: left 0.3s ease;
    }

    .header.active {
        left: 0;
    }

    .site-main {
        margin-left: 0;
        width: 100%;
        padding: 30px 20px;
    }

    .mobile-menu-toggle {
        display: block;
    }

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

@media (max-width: 767px) {
    h1 { font-size: 28px; }
    h2 { font-size: 24px; }

    .page-title {
        font-size: 32px;
    }

    .section-title h2 {
        font-size: 28px;
    }

    .site-main {
        padding: 20px 15px;
    }
}

@media (max-width: 575px) {
    .btn {
        padding: 10px 20px;
        font-size: 13px;
    }

    .filter-btn {
        padding: 8px 15px;
        margin: 5px 3px;
        font-size: 12px;
    }
}
