/*
Theme Name: Navedalam Child Theme
Theme URI: https://navedalam.com
Description: SEO-optimized child theme with modern header, footer, and single post template
Author: Naveed Alam
Author URI: https://navedalam.com
Template: astra
Version: 1.0.0
License: GNU General Public License v2 or later
Text Domain: navedalam-child
*/

:root {
    --primary: #2563eb;
    --dark: #0f172a;
    --light: #f8fafc;
    --text: #334155;
    --border: #e2e8f0;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: #fff;
}

.site-header, #masthead, .site-footer, #colophon {
    display: none !important;
}

/* ===== HEADER ===== */
.site-header-custom {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.header-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.site-branding {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 20px;
    color: var(--dark);
    flex-shrink: 0;
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: var(--primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 16px;
    font-weight: 800;
}

.primary-nav {
    display: flex;
    gap: 30px;
    list-style: none;
    margin: 0 auto;
}

.primary-nav a {
    color: var(--text);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.2s;
}

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

.header-cta {
    background: var(--primary);
    color: #fff;
    padding: 10px 24px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: transform 0.2s;
    flex-shrink: 0;
}

.header-cta:hover {
    transform: translateY(-2px);
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--dark);
}

.mobile-nav {
    display: none;
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    background: #fff;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    padding: 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s;
}

.mobile-nav.active {
    max-height: 400px;
}

.mobile-nav ul {
    list-style: none;
}

.mobile-nav a {
    display: block;
    padding: 12px 0;
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 1px solid var(--border);
}

/* ===== SINGLE POST ===== */
.single-post .site-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

.entry-header {
    margin-bottom: 32px;
}

.entry-title {
    font-size: 36px;
    font-weight: 800;
    line-height: 1.2;
    color: var(--dark);
    margin-bottom: 16px;
}

.entry-meta {
    display: flex;
    gap: 20px;
    color: #64748b;
    font-size: 14px;
    margin-bottom: 24px;
}

.entry-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.featured-image {
    margin-bottom: 32px;
    border-radius: 12px;
    overflow: hidden;
}

.featured-image img {
    width: 100%;
    height: auto;
    display: block;
}

.entry-content {
    font-size: 18px;
    line-height: 1.8;
    color: #1e293b;
}

.entry-content h2 {
    font-size: 28px;
    font-weight: 700;
    margin: 40px 0 16px;
    color: var(--dark);
}

.entry-content h3 {
    font-size: 24px;
    font-weight: 600;
    margin: 32px 0 12px;
    color: var(--dark);
}

.entry-content p {
    margin-bottom: 20px;
}

.entry-content a {
    color: var(--primary);
    text-decoration: underline;
}

.entry-content ul,
.entry-content ol {
    margin: 20px 0;
    padding-left: 30px;
}

.entry-content li {
    margin-bottom: 8px;
}

.entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 24px 0;
}

.entry-content blockquote {
    border-left: 4px solid var(--primary);
    padding: 16px 24px;
    margin: 24px 0;
    background: var(--light);
    font-style: italic;
}

.entry-content code {
    background: #f1f5f9;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: 'Courier New', monospace;
}

.entry-content pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 24px 0;
}

.entry-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.author-box {
    background: var(--light);
    border-radius: 12px;
    padding: 24px;
    margin: 40px 0;
    display: flex;
    gap: 20px;
}

.author-avatar {
    flex-shrink: 0;
}

.author-avatar img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
}

.author-info h4 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--dark);
}

.author-info p {
    font-size: 14px;
    color: var(--text);
    line-height: 1.6;
}

.post-navigation {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    padding: 24px 0;
    margin: 40px 0;
    display: flex;
    justify-content: space-between;
}

.post-navigation a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

/* ===== FOOTER ===== */
.site-footer-custom {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: #e2e8f0;
    padding: 80px 20px 0;
    margin-top: 100px;
    position: relative;
    overflow: hidden;
}

.site-footer-custom::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.5), transparent);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 60px;
}

.footer-about {
    padding-right: 30px;
}

.footer-about h3 {
    color: #fff;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #fff 0%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-about p {
    font-size: 15px;
    line-height: 1.8;
    margin-bottom: 24px;
    color: #cbd5e1;
}

.footer-social {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.footer-social a {
    width: 44px;
    height: 44px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    transition: all 0.3s ease;
}

.footer-social a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3);
}

.footer-links h4 {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 12px;
}

.footer-links h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), transparent);
}

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

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
    display: inline-block;
}

.footer-links a:hover {
    color: #fff;
    transform: translateX(5px);
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px 0;
    border-top: 1px solid rgba(255,255,255,0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
}

.footer-bottom p {
    color: #94a3b8;
}

.footer-legal {
    display: flex;
    gap: 24px;
    list-style: none;
}

.footer-legal a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-legal a:hover {
    color: #fff;
}

.footer-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.2);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: #22c55e;
    margin-top: 16px;
}

.footer-badge::before {
    content: '';
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    animation: pulse-footer 2s ease infinite;
}

@keyframes pulse-footer {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    }
    50% {
        opacity: 0.8;
        box-shadow: 0 0 0 6px rgba(34, 197, 94, 0);
    }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .primary-nav,
    .header-cta {
        display: none;
    }

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

    .entry-title {
        font-size: 28px;
    }

    .entry-content {
        font-size: 16px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-about {
        padding-right: 0;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    .author-box {
        flex-direction: column;
        text-align: center;
    }

    .post-navigation {
        flex-direction: column;
        gap: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}
