/* =====================
   POST PAGE STYLES
===================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #0f172a;
    --text: #334155;
    --text-light: #64748b;
    --bg: #ffffff;
    --bg-gray: #f8fafc;
    --border: #e2e8f0;
    --white: #ffffff;
}

body {
    font-family:
        "Inter",
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

/* =====================
   REUSABLE
===================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-narrow {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 24px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s;
}

img {
    max-width: 100%;
    display: block;
}

/* =====================
   NAVBAR
===================== */
.header {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.navbar {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 32px;
    list-style: none;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    color: var(--text);
    font-size: 15px;
}

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

.btn-outline {
    border: 1.5px solid var(--primary);
    padding: 8px 18px;
    border-radius: 6px;
    color: var(--primary);
    font-weight: 500;
    transition: all 0.3s;
    font-size: 14px;
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--white) !important;
}

/* =====================
   POST HEADER
===================== */
.post-header {
    background: linear-gradient(135deg, #eff6ff 0%, #f8fafc 100%);
    padding: 80px 0 60px;
}

.post-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 14px;
}

.post-date {
    color: var(--text-light);
}

.post-category {
    color: var(--primary);
    font-weight: 600;
}

.post-header h1 {
    font-size: 42px;
    font-weight: 800;
    color: var(--secondary);
    margin-bottom: 20px;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.post-excerpt {
    font-size: 19px;
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 30px;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author-info img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--white);
}

.author-name {
    font-weight: 600;
    color: var(--secondary);
    font-size: 15px;
    margin-bottom: 2px;
}

.author-title {
    font-size: 14px;
    color: var(--text-light);
}

/* =====================
   POST CONTENT
===================== */
.post-content {
    padding: 80px 0;
}

.post-image {
    width: 100%;
    height: auto;
    border-radius: 16px;
    margin-bottom: 50px;
}

.post-content h2 {
    font-size: 32px;
    font-weight: 700;
    color: var(--secondary);
    margin: 50px 0 20px;
    letter-spacing: -0.5px;
}

.post-content h3 {
    font-size: 24px;
    font-weight: 600;
    color: var(--secondary);
    margin: 35px 0 15px;
}

.post-content h4 {
    font-size: 20px;
    font-weight: 600;
    color: var(--secondary);
    margin: 25px 0 12px;
}

.post-content p {
    margin-bottom: 20px;
    line-height: 1.8;
    color: var(--text);
    font-size: 17px;
}

.post-content ul,
.post-content ol {
    margin: 20px 0 20px 25px;
    line-height: 1.8;
}

.post-content li {
    margin-bottom: 12px;
    color: var(--text);
}

.post-content strong {
    font-weight: 600;
    color: var(--secondary);
}

.post-content pre {
    background: #282c34;
    color: #e2e8f0;
    padding: 10px;
    border-radius: 12px;
    overflow-x: auto;
    margin: 25px 0;
    font-size: 14px;
    line-height: 1.6;
    border: 1px solid #282c34;
}

.post-content code {
    font-family: "Consolas", "Monaco", "Courier New", monospace;
}

.post-content p code {
    background: #f1f5f9;
    color: #e11d48;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 14px;
}

/* =====================
   TIP BOXES
===================== */
.tip-box {
    background: #eff6ff;
    border-left: 4px solid var(--primary);
    padding: 20px 24px;
    border-radius: 8px;
    margin: 30px 0;
}

.tip-box h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--primary);
    margin: 0 0 10px 0;
}

.tip-box p,
.tip-box ul {
    margin: 0;
    color: var(--text);
    font-size: 15px;
}

.tip-box ul {
    margin-left: 20px;
    margin-top: 10px;
}

.tip-box li {
    margin-bottom: 6px;
}

.tip-box.warning {
    background: #fef3c7;
    border-left-color: #f59e0b;
}

.tip-box.warning h4 {
    color: #92400e;
}

.tip-box.success {
    background: #d1fae5;
    border-left-color: #10b981;
}

.tip-box.success h4 {
    color: #065f46;
}

/* =====================
   POST SHARE
===================== */
.post-share {
    margin: 60px 0;
    padding: 30px;
    background: var(--bg-gray);
    border-radius: 12px;
    text-align: center;
}

.post-share h3 {
    font-size: 20px;
    color: var(--secondary);
    margin-bottom: 20px;
}

.share-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.share-btn {
    padding: 10px 24px;
    border-radius: 8px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

.share-btn.telegram {
    background: #0088cc;
    color: white;
}

.share-btn.telegram:hover {
    background: #006699;
}

.share-btn.twitter {
    background: #1da1f2;
    color: white;
}

.share-btn.twitter:hover {
    background: #0d8bd9;
}

.share-btn.facebook {
    background: #1877f2;
    color: white;
}

.share-btn.facebook:hover {
    background: #0d5dca;
}

/* =====================
   AUTHOR BIO
===================== */
.author-bio {
    display: flex;
    gap: 20px;
    padding: 30px;
    background: var(--bg-gray);
    border-radius: 12px;
    margin: 40px 0;
    align-items: center;
}

.author-bio img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    flex-shrink: 0;
}

.author-bio h4 {
    font-size: 18px;
    color: var(--secondary);
    margin: 0 0 8px 0;
}

.author-bio p {
    margin: 0;
    color: var(--text-light);
    font-size: 15px;
    line-height: 1.6;
}

/* =====================
   RELATED POSTS
===================== */
.related-posts {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 2px solid var(--border);
}

.related-posts h3 {
    font-size: 24px;
    color: var(--secondary);
    margin-bottom: 25px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.related-card {
    display: block;
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border);
    transition: all 0.3s;
}

.related-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.related-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.related-card h4 {
    padding: 20px 20px 10px;
    font-size: 16px;
    color: var(--secondary);
    line-height: 1.4;
    margin: 0;
}

.related-card span {
    display: block;
    padding: 0 20px 20px;
    font-size: 13px;
    color: var(--text-light);
}

/* =====================
   FOOTER
===================== */
.footer {
    background: #020617;
    color: #cbd5e1;
    padding: 35px 0;
    margin-top: 60px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    font-size: 14px;
    opacity: 0.85;
    transition: opacity 0.3s;
}

.footer-links a:hover {
    opacity: 1;
    color: var(--white);
}

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

    .post-header {
        padding: 60px 0 40px;
    }

    .post-header h1 {
        font-size: 32px;
    }

    .post-excerpt {
        font-size: 16px;
    }

    .post-content {
        padding: 60px 0;
    }

    .post-content h2 {
        font-size: 26px;
        margin: 35px 0 15px;
    }

    .post-content h3 {
        font-size: 20px;
        margin: 25px 0 12px;
    }

    .post-content p {
        font-size: 16px;
    }

    .post-content pre {
        padding: 10px;
        font-size: 13px;
    }

    .related-grid {
        grid-template-columns: 1fr;
    }

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

    .share-buttons {
        flex-direction: column;
    }

    .share-btn {
        width: 100%;
    }
}
