/* ==========================================================================
   𝕏 CODER THEME ARCHITECTURE — HIGH FIDELITY LAYOUT CONSTRAINTS
   ========================================================================== */

:root {
    --bg-main: #000000;
    --bg-hover: rgba(231, 233, 234, 0.1);
    --bg-card: #16181c;
    --border-dim: #2f3336;
    --text-primary: #e7e9ea;
    --text-muted: #71767b;
    --x-blue: #1d9bf0;
    --x-blue-hover: #1a8cd8;
    --x-white: #ffffff;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

/* 3-Column Core Flexbox Layout */
.x-wrapper {
    display: flex;
    width: 100%;
    max-width: 1250px;
    min-height: 100vh;
    box-sizing: border-box;
}

/* ==========================================================================
   COLUMN 1: STICKY LEFT HAND MAIN NAVIGATION
   ========================================================================== */
.left-sidebar {
    width: 275px;
    padding: 0 12px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--border-dim);
    position: sticky;
    top: 0;
    height: 100vh;
}

.x-logo {
    font-size: 30px;
    font-weight: 900;
    padding: 12px;
    margin: 4px 0;
    color: var(--x-white);
    cursor: pointer;
    width: fit-content;
}

.nav-link-item {
    font-size: 20px;
    font-weight: 500;
    padding: 12px 24px 12px 12px;
    border-radius: 9999px;
    color: var(--text-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 20px;
    width: fit-content;
    transition: background-color 0.2s ease;
    margin-bottom: 4px;
}

.nav-link-item:hover {
    background-color: var(--bg-hover);
}

.nav-link-item.active {
    font-weight: 700;
}

/* Sidebar Profile Block */
.sidebar-user-footer {
    margin-top: auto;
    margin-bottom: 20px;
    padding: 12px;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.sidebar-user-footer:hover {
    background-color: var(--bg-hover);
}

.sidebar-user-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.sidebar-user-info .display-name {
    font-weight: 700;
    font-size: 15px;
    color: var(--x-white);
}

.sidebar-user-info .username-handle {
    color: var(--text-muted);
    font-size: 15px;
}

/* ==========================================================================
   COLUMN 2: MID STREAM SOCIAL CHANNELS (600px Hard Lock)
   ========================================================================== */
.main-feed-column {
    width: 600px;
    min-width: 600px;
    border-right: 1px solid var(--border-dim);
    min-height: 100vh;
    box-sizing: border-box;
}

.feed-header-sticky {
    position: sticky;
    top: 0;
    background-color: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 16px;
    font-size: 20px;
    font-weight: 700;
    border-bottom: 1px solid var(--border-dim);
    z-index: 10;
    color: var(--x-white);
}

/* Composition Module Box */
.composer-box {
    display: flex;
    padding: 16px;
    border-bottom: 1px solid var(--border-dim);
    gap: 12px;
}

.user-avatar-circle {
    width: 40px;
    height: 40px;
    background-color: #333639;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    color: var(--x-white);
    flex-shrink: 0;
}

.composer-right {
    flex-grow: 1;
}

textarea {
    width: 100%;
    background: transparent;
    border: none;
    color: var(--x-white);
    resize: none;
    font-size: 20px;
    outline: none;
    font-family: inherit;
    margin-top: 4px;
    line-height: 1.4;
}

textarea::placeholder {
    color: var(--text-muted);
}

.composer-actions-bar {
    border-top: 1px solid var(--border-dim);
    padding-top: 12px;
    display: flex;
    justify-content: flex-end;
}

.btn-x-action {
    background-color: var(--x-blue);
    color: var(--x-white);
    border: none;
    padding: 10px 24px;
    border-radius: 9999px;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-x-action:hover {
    background-color: var(--x-blue-hover);
}

/* Timeline Cards */
.tweet-card {
    padding: 16px;
    border-bottom: 1px solid var(--border-dim);
    display: flex;
    gap: 12px;
}

.tweet-content-holder {
    flex-grow: 1;
}

.tweet-meta-info {
    font-size: 15px;
    margin-bottom: 2px;
}

.display-name-txt {
    font-weight: 700;
    color: var(--x-white);
}

.username-handle-txt {
    color: var(--text-muted);
    margin-left: 4px;
}

.tweet-body-payload {
    font-size: 15px;
    line-height: 1.5;
    color: var(--text-primary);
    white-space: pre-wrap;
    word-break: break-word;
}

/* ==========================================================================
   COLUMN 3: RIGHT SIDEBAR SYSTEMS PANELS (350px Lock)
   ========================================================================== */
.right-sidebar {
    width: 350px;
    min-width: 350px;
    padding: 12px 0 0 30px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.search-box-widget {
    background-color: #202327;
    border-radius: 9999px;
    padding: 12px 20px;
    color: var(--text-primary);
    font-size: 15px;
    border: 1px solid transparent;
    outline: none;
    width: 100%;
    box-sizing: border-box;
}

.search-box-widget:focus {
    background-color: var(--bg-main);
    border-color: var(--x-blue);
}

.trending-card {
    background-color: var(--bg-card);
    border-radius: 16px;
    padding: 16px;
    border: 1px solid var(--border-dim);
}

.trending-card h3 {
    margin-top: 0;
    margin-bottom: 8px;
    color: var(--x-white);
    font-size: 20px;
    font-weight: 800;
}

.trending-card p {
    font-size: 14px;
    line-height: 1.4;
    color: var(--text-primary);
    margin-bottom: 16px;
    margin-top: 0;
}