:root {
    --primary-text: #0f1419;
    --secondary-text: #536471;
    --border-color: #eff3f4;
    --link-color: #1d9bf0;
    --brand-purple: #675CFF;
    --brand-purple-hover: #554BCF;
    --brand-red: #E0245E;
    --retruth-green: #00BA7C;
    --like-pink: #F91880;
    --bg-color: #ffffff;
    /* Using system font stack that mimics Truth Social/Twitter */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

body {
    font-family: var(--font-family);
    background-color: var(--bg-color);
    color: var(--primary-text);
    display: flex;
    justify-content: center;
    min-height: 100vh;
    padding-bottom: 80px;
}

/* Layout Grid */
.page-wrapper {
    display: flex;
    justify-content: center;
    width: 100%;
}

.left-sidebar {
    width: 275px;
    padding: 12px 24px;
    display: none;
    align-items: flex-start;
    justify-content: flex-end;
    /* Align content to right of sidebar */
}

.main-column {
    width: 100%;
    max-width: 600px;
    /* Precise width */
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    min-height: 100vh;
}

.right-sidebar {
    width: 350px;
    padding: 12px 24px;
    display: none;
}



/* Logo */
.logo-container {
    width: 100%;
    display: flex;
    justify-content: flex-start;
    /* Or right if sticking to column edge */
    padding-top: 2px;
}

.truth-logo {
    width: auto;
    height: 30px;
    /* Smaller, more precise height usually */
    object-fit: contain;
}

/* Header */
.top-nav {
    display: flex;
    align-items: center;
    height: 53px;
    padding: 0 16px;
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    z-index: 100;
    border-bottom: 1px solid var(--border-color);
}

.back-button {
    margin-right: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.back-button:hover {
    background-color: rgba(15, 20, 25, 0.1);
}

.header-title-column {
    display: flex;
    flex-direction: column;
}

.header-title {
    font-weight: 800;
    font-size: 20px;
    line-height: 24px;
}

.header-subtitle {
    font-size: 13px;
    color: var(--secondary-text);
}


/* Post Container */
.post-container {
    padding: 0 16px;
}

.post-header {
    display: flex;
    margin-top: 12px;
    margin-bottom: 12px;
}

.avatar {
    margin-right: 12px;
    flex-shrink: 0;
}

.avatar img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

.user-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex-grow: 1;
}

.name-row {
    display: flex;
    align-items: center;
}

.display-name {
    font-weight: 700;
    font-size: 15px;
    color: var(--primary-text);
    margin-right: 4px;
}

.verified-badge {
    display: flex;
    align-items: center;
    gap: 2px;
}

.verified-badge svg {
    width: 18px;
    height: 18px;
    fill: #E0245E;
}

.verified-plus svg {
    width: 18px;
    height: 18px;
    fill: #000;
}

.handle-row {
    display: flex;
}

.handle {
    color: var(--secondary-text);
    font-size: 15px;
}

.header-menu {
    color: var(--secondary-text);
    padding: 4px;
}

/* UPDATED TYPOGRAPHY FOR POST TEXT */
.post-content {
    font-size: 17px;
    line-height: 24px;
    color: var(--primary-text);
    font-weight: 400;
    margin-top: 12px;
    margin-bottom: 12px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

@media (max-width: 400px) {
    .post-content {
        font-size: 16px;
        line-height: 22px;
    }
}

/* SPECIAL BUTTON - NATIVE STYLE */
.qfs-button-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-top: 16px;
    margin-bottom: 12px;
}

.qfs-gold-button {
    background-color: var(--brand-purple);
    /* Native Truth Social Purple */
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    padding: 10px 24px;
    font-size: 15px;
    border: none;
    border-radius: 9999px;
    /* Native pill shape */
    cursor: pointer;
    transition: background-color 0.2s;
    width: auto;
    min-width: 200px;
    max-width: 90%;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    box-shadow: none;
    /* Flat native look */
}

.qfs-gold-button:hover {
    background-color: var(--brand-purple-hover);
}

.qfs-gold-button:active {
    transform: translateY(1px);
}

@media (max-width: 480px) {
    .qfs-gold-button {
        width: 100%;
        max-width: 320px;
    }
}


.post-stats {
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
    color: var(--secondary-text);
    font-size: 15px;
}

.post-stats:hover {
    text-decoration: underline;
    /* Suggests clickability */
}

.stats-counts-border {
    height: 1px;
    background-color: var(--border-color);
}

.stats-counts {
    display: flex;
    padding: 16px 0;
    border-bottom: 1px solid var(--border-color);
}

.stat-item {
    margin-right: 20px;
    font-size: 15px;
}

.stat-value {
    font-weight: 700;
    color: var(--primary-text);
}

.stat-label {
    color: var(--secondary-text);
}

.action-bar {
    display: flex;
    justify-content: space-around;
    height: 48px;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    /* Separator for comments */
}

.action-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    color: var(--secondary-text);
    cursor: pointer;
}

.icon-container {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.action-item svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}


/* COMMENTS SECTION */
.comments-section {
    width: 100%;
}

.comment-item {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    cursor: pointer;
    transition: background-color 0.2s;
}

.comment-item:hover {
    background-color: rgba(0, 0, 0, 0.03);
}

.comment-avatar {
    margin-right: 12px;
    flex-shrink: 0;
}

.comment-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.comment-content {
    flex-grow: 1;
}

.comment-header {
    display: flex;
    align-items: center;
    margin-bottom: 2px;
}

.comment-name {
    font-weight: 700;
    font-size: 15px;
    margin-right: 4px;
}

.comment-handle {
    color: var(--secondary-text);
    font-size: 15px;
    margin-right: 4px;
}

.comment-time {
    color: var(--secondary-text);
    font-size: 15px;
}

.comment-text {
    font-size: 15px;
    line-height: 20px;
    color: var(--primary-text);
}

.comment-actions {
    display: flex;
    justify-content: space-between;
    max-width: 425px;
    margin-top: 12px;
    color: var(--secondary-text);
}

.comment-action {
    display: flex;
    align-items: center;
    font-size: 13px;
    group: hover;
}

.comment-action svg {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    fill: currentColor;
}


/* SIDEBARS */
.sidebar-section {
    background-color: #fff;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    padding: 16px;
    margin-bottom: 16px;
}

.sidebar-title {
    font-weight: 800;
    font-size: 20px;
    margin-bottom: 8px;
}

.sidebar-text {
    font-size: 15px;
    color: var(--secondary-text);
    margin-bottom: 16px;
    line-height: 20px;
}

.btn {
    width: 100%;
    border-radius: 9999px;
    padding: 10px 0;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    text-align: center;
    transition: background-color 0.2s;
    border: none;
    margin-bottom: 12px;
    display: block;
    text-decoration: none;
}

.btn-primary {
    background-color: var(--brand-purple);
    color: white;
}

.btn-primary:hover {
    background-color: var(--brand-purple-hover);
}

.btn-outline {
    background-color: transparent;
    border: 1px solid #cfd9de;
    color: var(--brand-purple);
}

.btn-outline:hover {
    background-color: rgba(103, 92, 255, 0.1);
}

.truth-plus-card {
    background-color: #fff;
}

/* FOOTER */
.sidebar-footer {
    display: flex;
    color: var(--secondary-text);
    font-size: 13px;
    gap: 12px;
    padding: 0 16px;
    flex-wrap: wrap;
}

.sidebar-footer a {
    color: var(--secondary-text);
    text-decoration: none;
}

.sidebar-footer a:hover {
    text-decoration: underline;
}

.us-flag {
    width: 16px;
    height: 12px;
    display: inline-block;
}

/* Bottom Banner */
.bottom-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #fff;
    border-top: 1px solid var(--border-color);
    padding: 12px 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

.banner-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 900px;
}

.banner-text-group {
    display: flex;
    flex-direction: column;
}

.banner-title {
    font-weight: 800;
    font-size: 22px;
}

.banner-sub {
    color: var(--secondary-text);
    font-size: 15px;
}

.banner-actions {
    display: flex;
    gap: 12px;
    flex-wrap: nowrap;
    /* Force single row */
}

.banner-btn-primary {
    background-color: var(--brand-purple);
    color: white;
    padding: 8px 24px;
    border-radius: 9999px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    /* Prevent text wrap */
    flex: 1;
    /* Distribute space evenly if needed, or remove if fixed width desired */
}

.banner-btn-outline {
    background-color: #fff;
    color: var(--primary-text);
    padding: 8px 24px;
    border-radius: 9999px;
    font-weight: 700;
    border: 1px solid #cfd9de;
    cursor: pointer;
    white-space: nowrap;
    /* Prevent text wrap */
    flex: 1;
}

.banner-actions button {
    /* flex: 1; removed as it is now in classes directly or handled above */
}
}

/* SPECIAL BUTTON - NATIVE STYLE */
.qfs-button-container {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-top: 16px;
    margin-bottom: 12px;
}

.qfs-gold-button {
    background-color: #675CFF;
    /* Native Truth Social Purple */
    color: white;
    font-weight: 700;
    text-transform: uppercase;
    padding: 10px 24px;
    font-size: 15px;
    border: none;
    border-radius: 9999px;
    cursor: pointer;
    transition: background-color 0.2s;
    width: auto;
    min-width: 200px;
    max-width: 90%;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    box-shadow: none;
}

.qfs-gold-button:hover {
    background-color: #554BCF;
}

.qfs-gold-button:active {
    transform: translateY(1px);
}

@media (max-width: 480px) {
    .qfs-gold-button {
        width: 100%;
        max-width: 320px;
    }
}

/* DESKTOP LAYOUT OVERRIDES */
@media (min-width: 1000px) {
    .page-wrapper {
        justify-content: center;
    }

    .left-sidebar {
        display: flex;
    }

    .right-sidebar {
        display: block;
    }

    .bottom-banner {
        display: none !important;
    }
}