/* ========================================
   VARIABLES & RESET
   ======================================== */

   :root {
    /* Colors - Dark Theme Inspired by X */
    --bg-primary: #000000;
    --bg-secondary: #16181c;
    --bg-tertiary: #1e2126;
    --bg-glass: rgba(22, 24, 28, 0.85);
    --bg-hover: rgba(255, 255, 255, 0.03);
    --bg-active: rgba(255, 255, 255, 0.08);
    
    --text-primary: #e7e9ea;
    --text-secondary: #71767b;
    --text-tertiary: #536471;
    
    --accent-primary: #1d9bf0;
    --accent-hover: #1a8cd8;
    --accent-light: rgba(29, 155, 240, 0.1);
    
    --border-color: #2f3336;
    --border-light: #38383d;
    
    --success: #00ba7c;
    --error: #f4212e;
    --warning: #ffd400;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 0.75rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-xxl: 3rem;
    
    /* Borders */
    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.5);
    --shadow-glass: 0 8px 32px rgba(0, 0, 0, 0.6);
    
    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 400ms cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ========================================
   AUTH SCREEN
   ======================================== */

.auth-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-lg);
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 100%);
    position: relative;
    overflow: hidden;
}

.auth-screen::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--accent-primary) 0%, transparent 70%);
    opacity: 0.1;
    top: -250px;
    right: -250px;
    animation: pulse 8s ease-in-out infinite;
}

.auth-screen::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, #9b59b6 0%, transparent 70%);
    opacity: 0.08;
    bottom: -200px;
    left: -200px;
    animation: pulse 10s ease-in-out infinite;
    animation-delay: 2s;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.1; }
    50% { transform: scale(1.2); opacity: 0.15; }
}

.auth-container {
    width: 100%;
    max-width: 420px;
    position: relative;
    z-index: 1;
    animation: slideUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-logo {
    text-align: center;
    margin-bottom: var(--spacing-xxl);
}

.logo-svg {
    width: 64px;
    height: 64px;
    color: var(--accent-primary);
    margin-bottom: var(--spacing-md);
    filter: drop-shadow(0 0 20px rgba(29, 155, 240, 0.3));
    animation: logoFloat 3s ease-in-out infinite;
}

.logo-img {
    width: 64px;
    height: 64px;
    margin-bottom: var(--spacing-md);
    filter: drop-shadow(0 0 20px rgba(29, 155, 240, 0.3));
    animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.auth-logo h1 {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent-primary) 0%, #8e44ad 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.auth-form {
    background: var(--bg-glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xxl);
    box-shadow: var(--shadow-glass);
}

.auth-form h2 {
    font-size: 1.75rem;
    margin-bottom: var(--spacing-xl);
    text-align: center;
    font-weight: 600;
}

.input-group {
    margin-bottom: var(--spacing-lg);
}

.input-group label {
    display: block;
    margin-bottom: var(--spacing-xs);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.input-group input,
.input-group textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--transition-fast);
    font-family: inherit;
}

.input-group input:focus,
.input-group textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: var(--bg-tertiary);
    box-shadow: 0 0 0 3px var(--accent-light);
}

.input-group textarea {
    resize: vertical;
    min-height: 100px;
}

.username-input {
    position: relative;
    display: flex;
    align-items: center;
}

.username-prefix {
    position: absolute;
    left: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
    pointer-events: none;
}

.username-input input {
    padding-left: 2rem;
}

.btn-primary {
    width: 100%;
    padding: 0.875rem;
    background: var(--accent-primary);
    color: white;
    border: none;
    border-radius: var(--radius-full);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    margin-top: var(--spacing-md);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(29, 155, 240, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

.auth-switch {
    text-align: center;
    margin-top: var(--spacing-lg);
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.auth-switch a {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--transition-fast);
}

.auth-switch a:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

/* ========================================
   MAIN APP
   ======================================== */

.main-app {
    min-height: 100vh;
    padding-top: 70px;
}

/* Header with Glass Effect */
.header-glass {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: var(--bg-glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 var(--spacing-lg);
}

.logo-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-weight: 700;
    font-size: 1.25rem;
}

.logo-svg-small {
    width: 32px;
    height: 32px;
    color: var(--accent-primary);
}

.logo-img-small {
    width: 32px;
    height: 32px;
}

.nav-menu {
    display: flex;
    gap: var(--spacing-xs);
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: 0.625rem 1.25rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.9375rem;
    font-weight: 500;
}

.nav-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-btn.active {
    color: var(--text-primary);
    background: var(--bg-active);
}

.nav-btn svg {
    transition: transform var(--transition-fast);
}

.nav-btn:hover svg {
    transform: scale(1.1);
}

.btn-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-logout:hover {
    background: rgba(244, 33, 46, 0.1);
    border-color: var(--error);
    color: var(--error);
}

/* ========================================
   FEED PAGE
   ======================================== */

.page-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--spacing-xl) var(--spacing-lg);
}

.feed-header {
    margin-bottom: var(--spacing-xl);
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.feed-header h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: var(--spacing-xs);
}

.feed-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
}

.posts-grid {
    display: grid;
    gap: var(--spacing-lg);
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.post-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    transition: all var(--transition-base);
    animation: slideInPost 0.4s cubic-bezier(0.4, 0, 0.2, 1) backwards;
    position: relative;
    overflow: hidden;
}

.post-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-primary), #8e44ad);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.post-card:hover {
    border-color: var(--border-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.post-card:hover::before {
    opacity: 1;
}

@keyframes slideInPost {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.post-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
}

.post-avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, var(--accent-primary), #8e44ad);
    object-fit: cover;
    border: 2px solid var(--border-color);
}

.post-author-info {
    flex: 1;
}

.post-author-name {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-primary);
}

.post-author-username {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.post-content {
    margin-bottom: var(--spacing-md);
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--text-primary);
    word-wrap: break-word;
}

.post-image {
    margin-bottom: var(--spacing-md);
    border-radius: var(--radius-md);
    overflow: hidden;
    max-width: 100%;
}

.post-image img {
    width: 100%;
    height: auto;
    display: block;
    max-height: 500px;
    object-fit: cover;
}

.post-timestamp {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
    margin-bottom: var(--spacing-md);
}

.post-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--border-color);
}

.vote-buttons {
    display: flex;
    gap: var(--spacing-xs);
}

.btn-action {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: 0.5rem 0.875rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.875rem;
    font-weight: 500;
}

.btn-action:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.btn-action svg {
    width: 18px;
    height: 18px;
}

.btn-vote {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.875rem;
    font-weight: 500;
    min-width: 60px;
    justify-content: center;
}

.btn-vote:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.btn-vote.voted {
    background: var(--accent-light);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.btn-upvote.voted {
    background: rgba(0, 186, 124, 0.1);
    border-color: var(--success);
    color: var(--success);
}

.btn-downvote.voted {
    background: rgba(244, 33, 46, 0.1);
    border-color: var(--error);
    color: var(--error);
}

.btn-vote svg {
    width: 16px;
    height: 16px;
}

.vote-count {
    font-weight: 600;
}

.btn-delete {
    margin-left: auto;
    border-color: rgba(244, 33, 46, 0.3);
    color: var(--error);
}

.btn-delete:hover {
    background: rgba(244, 33, 46, 0.1);
    border-color: var(--error);
}

.loading {
    text-align: center;
    padding: var(--spacing-xxl);
    color: var(--text-secondary);
}

/* ========================================
   LOAD MORE BUTTON
   ======================================== */

.load-more-container {
    display: flex;
    justify-content: center;
    padding: var(--spacing-xl) 0;
    border-top: 1px solid var(--border-color);
    margin-top: var(--spacing-lg);
}

.btn-load-more {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md) var(--spacing-xl);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    color: var(--accent-primary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.9375rem;
    font-weight: 500;
}

.btn-load-more:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
    transform: translateY(-1px);
}

.btn-load-more:active {
    transform: translateY(0);
}

.btn-load-more svg {
    transition: transform var(--transition-fast);
}

.btn-load-more:hover svg {
    transform: translateY(2px);
}

.loader {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-color);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    margin: 0 auto var(--spacing-md);
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ========================================
   POST FORM
   ======================================== */

.post-form-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    animation: slideInPost 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.post-form textarea {
    width: 100%;
    padding: var(--spacing-md);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 1rem;
    font-family: inherit;
    resize: none;
    transition: all var(--transition-fast);
    margin-bottom: var(--spacing-md);
}

.post-form textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: var(--bg-primary);
    box-shadow: 0 0 0 3px var(--accent-light);
}

.post-form textarea::placeholder {
    color: var(--text-tertiary);
}

.post-attachments {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
    flex-wrap: wrap;
}

.btn-attachment {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: 0.5rem 1rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.875rem;
    font-weight: 500;
}

.btn-attachment:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.image-preview {
    position: relative;
    display: inline-block;
}

.image-preview img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.btn-remove-image {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    background: var(--error);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.btn-remove-image:hover {
    background: #d32f2f;
    transform: scale(1.1);
}

.post-form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.char-counter {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.btn-post {
    padding: 0.75rem 1.5rem;
    background: var(--accent-primary);
    border: none;
    border-radius: var(--radius-full);
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.9375rem;
}

.btn-post:hover:not(:disabled) {
    background: var(--accent-hover);
    transform: translateY(-1px);
}

.btn-post:active:not(:disabled) {
    transform: translateY(0);
}

.btn-post:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* ========================================
   PROFILE PAGE
   ======================================== */

.profile-container {
    animation: fadeIn 0.5s ease-out;
}

.profile-header {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: var(--spacing-xl);
}

.profile-cover {
    height: 200px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, #8e44ad 100%);
    position: relative;
}

.profile-info {
    padding: var(--spacing-xl);
    padding-top: 0;
}

.profile-avatar-container {
    position: relative;
    margin-top: -60px;
    margin-bottom: var(--spacing-lg);
    width: 120px;
    height: 120px;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: var(--radius-full);
    border: 4px solid var(--bg-secondary);
    object-fit: cover;
    background: linear-gradient(135deg, var(--accent-primary), #8e44ad);
}



.verified-badge {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 36px;
    height: 36px;
    background: transparent;
    border: 3px solid var(--bg-secondary);
    border-radius: var(--radius-full);
    color: var(--accent-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.verified-badge svg {
    width: 20px;
    height: 20px;
}

.verified-badge-small {
    width: 16px;
    height: 16px;
    margin-left: 4px;
    color: var(--accent-primary);
    display: inline-block;
    vertical-align: middle;
}

.modera-container {
    max-width: 800px;
    margin: 0 auto;
    padding: var(--spacing-lg);
}

.users-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.user-card {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
}

.user-info {
    flex: 1;
}

.user-name {
    font-weight: 600;
}

.user-username {
    color: var(--text-secondary);
}

.verified-toggle {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.btn-save {
    padding: 0.5rem 1rem;
    background: var(--accent-primary);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
}

.profile-details {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.profile-name {
    font-size: 1.5rem;
    font-weight: 700;
}

.profile-username {
    color: var(--text-secondary);
    font-size: 1rem;
}

.profile-bio {
    color: var(--text-primary);
    font-size: 0.9375rem;
    margin-top: var(--spacing-sm);
    line-height: 1.6;
}

.btn-edit-profile {
    margin-top: var(--spacing-md);
    padding: 0.625rem 1.5rem;
    background: transparent;
    border: 1px solid var(--accent-primary);
    border-radius: var(--radius-full);
    color: var(--accent-primary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-weight: 600;
    align-self: flex-start;
}

.btn-edit-profile:hover {
    background: var(--accent-primary);
    color: white;
}

.profile-posts {
    animation: fadeIn 0.5s ease-out 0.2s backwards;
}

.profile-posts h3 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-lg);
    font-weight: 700;
}

.search-bar {
    margin-bottom: var(--spacing-lg);
}

.search-bar input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--transition-fast);
    font-family: inherit;
}

.search-bar input:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: var(--bg-tertiary);
    box-shadow: 0 0 0 3px var(--accent-light);
}

/* ========================================
   MODALS
   ======================================== */

.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: var(--spacing-lg);
    animation: fadeInModal 0.3s ease-out;
}

@keyframes fadeInModal {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
    animation: slideUpModal 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-small {
    max-width: 400px;
}

@keyframes slideUpModal {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-lg);
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
}

.btn-close-modal {
    width: 36px;
    height: 36px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.btn-close-modal:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.modal-body {
    padding: var(--spacing-lg);
}

.modal-footer {
    display: flex;
    gap: var(--spacing-md);
    padding: var(--spacing-lg);
    border-top: 1px solid var(--border-color);
}

.btn-secondary {
    flex: 1;
    padding: 0.75rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-weight: 600;
}

.btn-secondary:hover {
    background: var(--bg-hover);
    border-color: var(--border-light);
}

.share-text {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
}

.share-link {
    display: flex;
    gap: var(--spacing-sm);
}

.share-link input {
    flex: 1;
    padding: 0.75rem;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.875rem;
}

.btn-copy {
    padding: 0.75rem;
    background: var(--accent-primary);
    border: none;
    border-radius: var(--radius-md);
    color: white;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-copy:hover {
    background: var(--accent-hover);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 768px) {
    .header-content {
        padding: 0 var(--spacing-md);
    }

    .nav-btn span {
        display: none;
    }

    .nav-btn {
        padding: 0.625rem;
        width: 44px;
        height: 44px;
        justify-content: center;
    }

    .logo-header span {
        display: none;
    }

    .page-content {
        padding: var(--spacing-md);
    }

    .posts-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .feed-header h2 {
        font-size: 1.5rem;
    }

    .auth-container {
        max-width: 100%;
    }

    .auth-form {
        padding: var(--spacing-xl);
    }

    .auth-logo h1 {
        font-size: 2rem;
    }

    .profile-cover {
        height: 150px;
    }

    .profile-avatar-container {
        margin-top: -50px;
        width: 100px;
        height: 100px;
    }

    .profile-avatar {
        width: 100px;
        height: 100px;
    }

    .modal-content {
        max-width: 100%;
        border-radius: var(--radius-lg);
    }

    .post-actions {
        flex-direction: column;
        gap: var(--spacing-sm);
        align-items: flex-start;
    }

    .vote-buttons {
        order: -1;
    }

    .btn-delete {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .auth-logo h1 {
        font-size: 1.75rem;
    }

    .feed-header h2 {
        font-size: 1.25rem;
    }

    .profile-name {
        font-size: 1.25rem;
    }
}

/* ========================================
   NAVIGATION
   ======================================== */

.nav-icon {
    position: relative;
    width: 24px;
    height: 24px;
}

.nav-svg {
    width: 100%;
    height: 100%;
}

.nav-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--border-color);
}

/* ========================================
   UTILITIES
   ======================================== */

.hidden {
    display: none !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-tertiary);
}

/* Selection */
::selection {
    background: var(--accent-light);
    color: var(--accent-primary);
}

/* ========================================
   NOTIFICATION MODAL
   ======================================== */

.modal-notification {
    max-width: 400px;
    text-align: center;
}

.modal-notification .modal-body {
    padding: var(--spacing-xl);
}

.modal-notification .modal-body p {
    margin-bottom: var(--spacing-lg);
    font-size: 1rem;
    line-height: 1.5;
    color: var(--text-primary);
}

.modal-notification .btn-primary {
    min-width: 80px;
}

.modal-actions {
    display: flex;
    gap: var(--spacing-md);
    justify-content: flex-end;
    margin-top: var(--spacing-lg);
}

.modal-actions .btn-secondary {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 0.9375rem;
}

.modal-actions .btn-secondary:hover {
    background: var(--bg-hover);
    border-color: var(--text-secondary);
}