/* style.css */
:root {
    --primary-color: #2c3e50; /* Dark Navy / Slate Gray */
    --secondary-color: #34495e;
    --accent-color: #3b82f6; /* Modern Blue for accents */
    --text-main: #1f2937;
    --text-muted: #6b7280;
    --bg-main: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-code: #f1f5f9;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --transition-fast: 0.2s ease;
    --transition-medium: 0.3s ease;
}

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

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

a {
    text-decoration: none;
    color: inherit;
}

/* Navbar */
.sticky-navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.5px;
}

.nav-menu a {
    margin: 0 1rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: color var(--transition-fast);
}

.nav-menu a:hover, .nav-menu a.active {
    color: var(--primary-color);
}

.nav-socials a {
    margin-left: 1rem;
    color: var(--text-muted);
    font-size: 1.2rem;
    transition: color var(--transition-fast);
}

.nav-socials a:hover {
    color: var(--primary-color);
}

/* Hero Section */
.hero-section {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
}

.hero-content {
    flex: 1;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--primary-color);
    line-height: 1.2;
    margin-bottom: 1rem;
}

.highlight {
    color: var(--accent-color);
}

.hero-subtitle {
    font-size: 1.8rem;
    font-weight: 500;
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
    height: 40px; /* to prevent layout shift */
}

.typing-text {
    border-right: 2px solid var(--primary-color);
    padding-right: 5px;
    animation: blink 0.75s step-end infinite;
}

@keyframes blink {
    from, to { border-color: transparent }
    50% { border-color: var(--primary-color); }
}

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    max-width: 600px;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.8rem;
    border-radius: 8px;
    font-weight: 600;
    transition: all var(--transition-fast);
    cursor: pointer;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    color: white;
}

.social-buttons {
    display: flex;
    gap: 1rem;
}

.btn-social {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background-color: var(--bg-secondary);
    color: var(--primary-color);
    font-size: 1.2rem;
    transition: all var(--transition-fast);
    border: 1px solid var(--border-color);
}

.btn-social:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.avatar-container {
    position: relative;
    width: 350px;
    height: 350px;
}

.avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    position: relative;
    z-index: 2;
    border: 8px solid white;
    box-shadow: var(--shadow-lg);
}

.glow-effect {
    position: absolute;
    top: -5%;
    left: -5%;
    width: 110%;
    height: 110%;
    background: linear-gradient(45deg, #e0e7ff, #bfdbfe);
    border-radius: 50%;
    z-index: 1;
    filter: blur(20px);
    animation: pulse 4s infinite alternate;
}

@keyframes pulse {
    0% { transform: scale(0.95); opacity: 0.6; }
    100% { transform: scale(1.05); opacity: 0.9; }
}

/* Blog Section */
.blog-section {
    background-color: var(--bg-secondary);
    padding: 6rem 2rem;
}

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

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.section-header p {
    color: var(--text-muted);
}

.filter-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.5rem 1.5rem;
    border: 1px solid var(--border-color);
    background-color: white;
    border-radius: 30px;
    font-family: inherit;
    font-weight: 500;
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.filter-btn:hover {
    background-color: var(--bg-code);
}

.filter-btn.active {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: var(--shadow-sm);
}

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

.task-card {
    background-color: white;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    padding: 1.5rem;
    transition: all var(--transition-medium);
    display: flex;
    flex-direction: column;
}

.task-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.card-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.tag {
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
}

.tag-laravel { background-color: #fee2e2; color: #ef4444; }
.tag-ui-ux { background-color: #e0e7ff; color: #4f46e5; }
.tag-database { background-color: #dcfce7; color: #22c55e; }
.tag-php { background-color: #f3e8ff; color: #9333ea; }

.card-title {
    font-size: 1.25rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    line-height: 1.4;
}

.card-title a {
    transition: color var(--transition-fast);
}

.card-title a:hover {
    color: var(--accent-color);
}

.card-excerpt {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.read-more {
    font-weight: 600;
    color: var(--accent-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.95rem;
    transition: gap var(--transition-fast);
}

.read-more:hover {
    gap: 0.8rem;
}

/* Single Post View */
.single-post {
    background-color: white;
}

.article-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

.post-header {
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 2rem;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.post-title {
    font-size: 2.8rem;
    color: var(--primary-color);
    line-height: 1.2;
    letter-spacing: -1px;
}

.post-body h2 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-top: 3rem;
    margin-bottom: 1rem;
}

.post-body p {
    font-size: 1.1rem;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.post-body .lead-text {
    font-size: 1.25rem;
    color: var(--secondary-color);
    font-weight: 300;
    line-height: 1.8;
}

/* Code Block Container */
.code-container {
    background-color: var(--bg-code);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin: 2rem 0;
    overflow: hidden;
}

.code-header {
    background-color: #e2e8f0;
    padding: 0.8rem 1.2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #cbd5e1;
}

.file-name {
    font-family: 'Fira Code', monospace;
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 500;
}

.copy-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: color var(--transition-fast);
    font-family: inherit;
}

.copy-btn:hover {
    color: var(--primary-color);
}

.code-container pre {
    padding: 1.5rem;
    overflow-x: auto;
    margin: 0;
}

.code-container code {
    font-family: 'Fira Code', monospace;
    font-size: 0.95rem;
    color: #334155;
    line-height: 1.6;
}

/* Inline Code */
p code {
    background-color: var(--bg-code);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: 'Fira Code', monospace;
    font-size: 0.9em;
    color: #e11d48;
}

.image-wrapper {
    margin: 2.5rem 0;
    text-align: center;
}

.post-image {
    max-width: 100%;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
}

.image-caption {
    margin-top: 0.8rem;
    font-size: 0.9rem !important;
    color: var(--text-muted) !important;
    font-style: italic;
}

.post-footer {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: var(--primary-color);
    transition: color var(--transition-fast);
}

.back-link:hover {
    color: var(--accent-color);
}

/* Footer */
.minimal-footer {
    text-align: center;
    padding: 2.5rem;
    background-color: white;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Responsive */
@media (max-width: 992px) {
    .hero-container {
        flex-direction: column-reverse;
        text-align: center;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .hero-desc {
        margin: 0 auto 2.5rem auto;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .avatar-container {
        width: 280px;
        height: 280px;
    }
    
    .post-title {
        font-size: 2.2rem;
    }
    
    .article-container {
        padding: 3rem 1.5rem;
    }
}

@media (max-width: 576px) {
    .nav-menu {
        display: none;
    }
    
    .filter-tabs {
        flex-direction: column;
        align-items: stretch;
    }
    
    .avatar-container {
        width: 220px;
        height: 220px;
    }
}
