:root {
    --bg: #111111;
    --surface: #1b1b1b;
    --surface-2: #252525;
    --line: #303030;
    --text: #ffffff;
    --muted: #888888;
    --accent: #8BAE66;
    --accent-2: #9fc477;
    --gold: #e8c766;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background:
        radial-gradient(ellipse at top, rgba(139, 174, 102, 0.1), transparent 55%),
        var(--bg);
    color: var(--text);
    font-family: "Vazirmatn", Tahoma, sans-serif;
    line-height: 1.9;
}

.post-wrap {
    width: 100%;
    max-width: 820px;
    margin: 0 auto;
    padding: 30px 20px 90px;
}

.post-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 26px;
    padding: 7px 16px;
    color: var(--muted);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 50px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: 0.2s;
}

.post-back:hover {
    color: var(--accent-2);
    border-color: var(--accent);
}

.post-loading,
.post-error {
    padding: 80px 0;
    text-align: center;
    color: var(--muted);
}


/* ---------- Head ---------- */

.post-head {
    margin-bottom: 26px;
    text-align: center;
}

.post-cat {
    display: inline-block;
    padding: 3px 16px;
    color: var(--gold);
    background: rgba(232, 199, 102, 0.08);
    border: 1px solid rgba(232, 199, 102, 0.4);
    border-radius: 50px;
    font-size: 13px;
    font-weight: 700;
}

.post-title {
    margin: 16px 0 10px;
    font-size: 34px;
    font-weight: 800;
    line-height: 1.6;
}

.post-date {
    color: var(--muted);
    font-size: 13px;
}

.post-banner {
    display: block;
    width: 100%;
    max-height: 430px;
    margin-bottom: 34px;
    object-fit: cover;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 18px;
}


/* ---------- Body ---------- */

.post-body {
    font-size: 17px;
}

.post-body h1,
.post-body h2,
.post-body h3 {
    margin: 34px 0 12px;
    font-weight: 800;
    line-height: 1.6;
}

.post-body h1 {
    font-size: 30px;
    color: var(--text);
}

.post-body h2 {
    padding-right: 12px;
    border-right: 4px solid var(--accent);
    font-size: 24px;
    color: var(--text);
}

.post-body h3 {
    font-size: 19px;
    color: var(--accent-2);
}

.post-body p {
    margin: 0 0 18px;
    color: #d8d8d8;
    white-space: pre-wrap;
    word-break: break-word;
}

.post-body figure {
    margin: 28px 0;
}

.post-body figure img {
    display: block;
    max-width: 100%;
    margin: 0 auto;
    border: 1px solid var(--line);
    border-radius: 14px;
}

.post-body figcaption {
    margin-top: 8px;
    text-align: center;
    color: var(--muted);
    font-size: 13px;
}


/* ---------- Footer ---------- */

.post-foot {
    margin-top: 44px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
}

.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.post-tags span {
    padding: 4px 14px;
    color: var(--accent);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 13px;
}

@media (max-width: 576px) {
    .post-title {
        font-size: 26px;
    }

    .post-body {
        font-size: 16px;
    }

    .post-banner {
        max-height: 240px;
    }
}
