body {
    background: linear-gradient(135deg, #f5f5f7, #e8e8f0); /* Gradient background */
    color: #333;
}

.feed-container {
    padding: 100px 5% 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.feed-container h1 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    background: linear-gradient(45deg, var(--primary-blue), var(--primary-red));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
}

.post-card {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.post-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.post-header {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
}

.author-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    margin-right: 0.75rem;
}

.author-info {
    flex-grow: 1;
}

.author-name {
    font-weight: 600;
    color: var(--primary-blue);
    font-size: 0.95rem;
}

.post-timestamp {
    font-size: 0.75rem;
    color: #888;
}

.post-content {
    margin-bottom: 0.75rem;
    white-space: pre-wrap;
    font-size: 0.95rem;
    line-height: 1.5;
    color: #444;
}

.post-image {
    width: 100%;
    max-height: 400px;
    object-fit: contain;
    border-radius: 8px;
    margin: 0.75rem 0;
    background: #f8f9fa;
}

.post-image-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #f8f9fa;
    border-radius: 8px;
    overflow: hidden;
    margin: 0.75rem 0;
    min-height: 100px;
    max-height: 400px;
}

.post-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding-top: 0.75rem;
    margin-top: 0.75rem;
}

.action-buttons {
    display: flex;
    gap: 0.75rem;
}

.like-button, .follow-button {
    background: none;
    border: none;
    color: #777;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.like-button:hover, .follow-button:hover {
    background-color: rgba(0, 0, 0, 0.05);
    color: var(--primary-blue);
}

.like-button.liked {
    color: var(--primary-red);
}

.follow-button {
    background: var(--primary-blue);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
}

.follow-button:hover {
    background: var(--primary-red);
    color: white;
}

.political-leaning {
    position: relative;
    width: 200px;
    height: 20px;
    background: linear-gradient(to right, 
        var(--primary-blue) 0%, 
        var(--primary-blue) 30%, 
        #808080 45%,
        #808080 55%,
        var(--primary-red) 70%, 
        var(--primary-red) 100%
    );
    border-radius: 10px;
    padding: 2px;
    margin: 1rem auto;
}

.political-leaning::before {
    content: 'Left';
    position: absolute;
    left: 10px;
    top: -20px;
    font-size: 0.8rem;
    color: var(--primary-blue);
    font-weight: 500;
}

.political-leaning::after {
    content: 'Right';
    position: absolute;
    right: 10px;
    top: -20px;
    font-size: 0.8rem;
    color: var(--primary-red);
    font-weight: 500;
}

.leaning-indicator {
    position: absolute;
    width: 8px;
    height: 16px;
    background: white;
    border-radius: 4px;
    top: 2px;
    transition: left 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Loading and error states */
.loading-indicator {
    text-align: center;
    padding: 2rem;
    color: #666;
}

.error-message {
    text-align: center;
    padding: 2rem;
    color: #dc3545;
    background: rgba(220, 53, 69, 0.1);
    border-radius: 8px;
}

.no-posts {
    text-align: center;
    padding: 2rem;
    color: #666;
}

@media (max-width: 768px) {
    .feed-container {
        padding-top: 80px;
    }
    
    .post-card {
        padding: 1rem;
    }
    
    .political-leaning {
        width: 150px;
    }
    
    .post-image,
    .post-image-container {
        max-height: 300px;
    }
    
    .post-image {
        object-fit: contain;
    }
}

.follow-button.following {
    background: #28a745;
}

.follow-button.following:hover {
    background: #dc3545;
}

.follow-button.following:hover::after {
    content: 'Unfollow';
}

.notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 12px 24px;
    border-radius: 8px;
    color: white;
    z-index: 1000;
    animation: slideIn 0.3s ease forwards;
}

.notification.success {
    background: #28a745;
}

.notification.error {
    background: #dc3545;
}

.notification.fade-out {
    opacity: 0;
    transition: opacity 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Add these scrollbar styles to polifeed.css */

/* For Webkit browsers (Chrome, Safari) */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 102, 255, 0.3);
    border-radius: 10px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 102, 255, 0.5);
}

/* For Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 102, 255, 0.3) rgba(255, 255, 255, 0.1);
}

/* Add smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Update the feed container header section */
.feed-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2rem;
    gap: 1rem;
}

.search-container {
    width: 100%;
    max-width: 600px;
    position: relative;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    padding: 0.8rem 1rem 0.8rem 2.5rem;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
}

.search-icon {
    position: absolute;
    left: 0.8rem;
    top: 50%;
    transform: translateY(-50%);
    color: #888;
    pointer-events: none;
}

.search-results {
    margin-bottom: 2rem;
    display: none; /* Hide by default */
}

.search-results:not(:empty) {
    display: block; /* Show when there are results */
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.no-results {
    text-align: center;
    padding: 2rem;
    color: #666;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    margin-top: 1rem;
}

/* Update loading state for search */
.loading-indicator {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-blue);
}

.loading-indicator i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
 