/* Stories Section at Top */
.stories-section {
    background: var(--white);
    border-radius: 16px;
    padding: 20px;
    margin: 0 0 24px 0;
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.stories-container {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 8px;
    scrollbar-width: thin;
    -ms-overflow-style: none;
}

.stories-container::-webkit-scrollbar {
    height: 4px;
}

.stories-container::-webkit-scrollbar-track {
    background: var(--hover-bg);
    border-radius: 4px;
}

.stories-container::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

/* Story Card Styles */
.story-card {
    min-width: 110px;
    max-width: 110px;
    height: 180px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    transition: transform 0.2s ease;
    background: var(--hover-bg);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.story-card:hover {
    transform: translateY(-4px);
}

.story-card.add-story {
    background: var(--hover-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px dashed var(--border-color);
}

.story-add-icon {
    font-size: 24px;
    color: var(--primary-color);
    margin-bottom: 8px;
}

/* Create Post Section pushed down */
.create-post {
    margin-top: 24px;
}

/* Create Post Section */
.create-post {
    background: var(--white);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 24px;
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.post-input-wrapper {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

.post-input {
    flex: 1;
    background: var(--hover-bg);
    border-radius: 30px;
    padding: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.post-input:hover {
    background: var(--border-color);
}

.post-input input {
    width: 100%;
    padding: 12px 20px;
    border: none;
    background: transparent;
    font-size: 15px;
    cursor: pointer;
}

.post-actions {
    display: flex;
    gap: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.post-action-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: var(--secondary-color);
    cursor: pointer;
    transition: all 0.2s ease;
}

.post-action-btn:hover {
    background: var(--hover-bg);
    color: var(--primary-color);
}

/* Feed Filters */
.feed-filters {
    background: var(--white);
    padding: 8px;
    border-radius: 12px;
    margin: 16px 0;
    border: 1px solid var(--border-color);
}

.filters-scroll {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: thin;
    -ms-overflow-style: none;
}

.filters-scroll::-webkit-scrollbar {
    height: 4px;
}

.filters-scroll::-webkit-scrollbar-track {
    background: var(--hover-bg);
    border-radius: 4px;
}

.filters-scroll::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

.filter-btn {
    font-size: 14px;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    background: var(--white);
    color: var(--secondary-color);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.filter-btn i {
    font-size: 16px;
}

.filter-btn:hover {
    background: var(--hover-bg);
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Feed Cards */
.feed-card {
    background: var(--white);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid var(--border-color);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.user-info {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.badge-pro {
    background: linear-gradient(45deg, #FF6B6B, #FF8E53);
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    margin-left: 8px;
}

.content-preview {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    margin: 16px 0;
    max-height: 300px;
}

.preview-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.content-preview:hover .preview-overlay {
    opacity: 1;
}

/* Right Sidebar */
.right-sidebar {
    width: 320px;
    padding: 24px;
    position: sticky;
    top: 24px;
    height: calc(100vh - 48px);
    overflow: hidden;
    border-left: 1px solid var(--border-color);
}

/* Custom Scrollbar for Webkit browsers */
.right-sidebar::-webkit-scrollbar {
    width: 4px;
}

.right-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.right-sidebar::-webkit-scrollbar-thumb {
    background-color: var(--border-color);
    border-radius: 20px;
}

/* Container heights for sections */
.trending-topics {
    margin-bottom: 20px;
    max-height: 35vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) transparent;
}

.suggested-connections {
    max-height: calc(65vh - 48px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) transparent;
}

/* Custom Scrollbar for sections */
.trending-topics::-webkit-scrollbar,
.suggested-connections::-webkit-scrollbar {
    width: 4px;
}

.trending-topics::-webkit-scrollbar-track,
.suggested-connections::-webkit-scrollbar-track {
    background: transparent;
}

.trending-topics::-webkit-scrollbar-thumb,
.suggested-connections::-webkit-scrollbar-thumb {
    background-color: var(--border-color);
    border-radius: 20px;
}

/* Responsive Design */
@media (max-width: 1400px) {
    .right-sidebar {
        width: 280px;
    }
}

@media (min-height: 900px) {
    .trending-topics {
        max-height: 400px;
    }
    
    .suggested-connections {
        max-height: calc(100vh - 500px);
    }
}

@media (max-width: 1200px) {
    .right-sidebar {
        display: none;
    }
}

@media (max-width: 768px) {
    .stories-container {
        gap: 12px;
    }

    .story-card {
        width: 100px;
        height: 160px;
    }

    .feed-filters {
        overflow-x: auto;
        padding-bottom: 8px;
    }

    .filter-btn {
        flex-shrink: 0;
    }
}

/* Story Card Styles */
.story-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.story-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 12px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.story-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    margin-bottom: 8px;
    border: 2px solid var(--primary-color);
}

.story-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.story-info span {
    font-size: 12px;
    display: block;
    text-align: center;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

/* Create Post Section */
.post-input-wrapper .user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
}

/* Feed Card Images */
.content-preview img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.3s ease;
}

.content-preview:hover img {
    transform: scale(1.02);
}

/* User Avatars in Comments */
.comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border-color);
}

/* Right Sidebar User Images */
.connection-item img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .story-card {
        width: 100px;
        height: 160px;
    }

    .story-avatar {
        width: 36px;
        height: 36px;
    }
}

@media (max-width: 576px) {
    .story-card {
        width: 90px;
        height: 140px;
    }

    .story-avatar {
        width: 32px;
        height: 32px;
    }
}

/* Post Stats Styling */
.card-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-top: 1px solid var(--border-color);
    margin-top: 16px;
}

.stat-group {
    display: flex;
    gap: 20px;
}

.stat-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border: none;
    background: transparent;
    color: var(--secondary-color);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.stat-btn:hover {
    background: var(--hover-bg);
    color: var(--primary-color);
}

.stat-btn i {
    font-size: 18px;
}

/* Like button specific */
.stat-btn.liked {
    color: #FF4B4B;
}

.stat-btn.liked i {
    animation: likeAnimation 0.3s ease;
}

/* Save button specific */
.stat-btn.saved {
    color: var(--primary-color);
}

/* Connection List Styling */
.connection-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 16px;
}

.connection-item {
    background: var(--white);
    padding: 16px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    transition: all 0.2s ease;
}

.user-info-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 200px;
}

.connection-info {
    flex: 1;
    min-width: 0;
    margin-bottom: 8px;
}

.connection-item .btn-small {
    margin-left: 56px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
    min-width: 90px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    background: transparent;
    border: 1.5px solid var(--primary-color);
    color: var(--primary-color);
}

.connection-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.connection-item .user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--white);
}

.connection-name {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 15px;
    margin-bottom: 4px;
    line-height: 1.4;
    white-space: normal;
    overflow: visible;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.connection-title {
    color: var(--secondary-color);
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-small {
    padding: 6px 12px;
    font-size: 13px;
    min-width: 80px;
    height: 32px;
    white-space: nowrap;
    flex-shrink: 0;
}

/* Like Animation */
@keyframes likeAnimation {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
} 

/* Additional Responsive Styles */
@media (max-width: 992px) {
    .main-content {
        padding: 20px;
    }

    .feed-card {
        padding: 20px;
    }

    .post-actions {
        flex-wrap: wrap;
    }

    .post-action-btn {
        flex: 1;
        justify-content: center;
    }

    .btn-primary {
        width: 100%;
        margin-top: 10px;
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 16px;
    }

    .create-post {
        padding: 16px;
    }

    .post-input-wrapper {
        gap: 12px;
    }

    .post-input input {
        font-size: 14px;
    }

    .feed-card {
        padding: 16px;
    }

    .card-stats {
        flex-wrap: wrap;
        gap: 12px;
    }

    .stat-group {
        width: 100%;
        justify-content: space-between;
    }

    .stat-btn {
        padding: 6px 10px;
        font-size: 13px;
    }
}

@media (max-width: 576px) {
    .stories-section {
        margin: -16px -16px 16px -16px;
        padding: 16px;
        background: var(--white);
        border-bottom: 1px solid var(--border-color);
    }

    .feed-filters {
        margin: 15px 0;
        padding: 8px;
    }

    .post-action-btn span {
        display: none;
    }

    .post-action-btn i {
        font-size: 20px;
    }

    .user-details {
        max-width: 160px;
    }

    .user-name, .post-meta {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

@media (max-width: 360px) {
    .main-content {
        padding: 12px;
    }

    .create-post,
    .feed-card {
        padding: 12px;
    }

    .post-input-wrapper .user-avatar {
        width: 40px;
        height: 40px;
    }

    .filter-btn {
        padding: 8px 12px;
        font-size: 13px;
    }

    .stat-btn {
        padding: 4px 8px;
        font-size: 12px;
    }

    .stat-btn i {
        font-size: 16px;
    }
}

/* Touch Device Optimizations */
@media (hover: none) {
    .story-card:hover {
        transform: none;
    }

    .content-preview:hover .preview-overlay {
        opacity: 1;
    }

    .stat-btn {
        padding: 12px;  /* Larger touch target */
    }

    .filter-btn {
        padding: 12px 20px;  /* Larger touch target */
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    :root {
        --primary-color: #E2E8F0;
        --secondary-color: #94A3B8;
        --background-color: #0F172A;
        --border-color: #1E293B;
        --white: #1E293B;
        --hover-bg: #1E293B;
    }

    .story-card {
        background: var(--background-color);
    }

    .story-info {
        background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    }
}

/* Suggested Connections Styling */
.suggested-connections {
    background: var(--white);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid var(--border-color);
    margin-top: 24px;
    margin-bottom: 24px;
}

.suggested-connections h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 16px;
}

.connection-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.connection-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-radius: 12px;
    background: var(--hover-bg);
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.connection-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.connection-item .user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--white);
}

.connection-info {
    flex: 1;
    min-width: 0;
    padding-right: 8px;
}

.connection-name {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 15px;
    margin-bottom: 4px;
    line-height: 1.4;
    white-space: normal;
    overflow: visible;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.connection-title {
    color: var(--secondary-color);
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.connection-item .btn-small {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
    min-width: 90px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    background: transparent;
    border: 1.5px solid var(--primary-color);
    color: var(--primary-color);
}

.connection-item .btn-small:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
}

/* Connected state */
.connection-item .btn-small.connected {
    background: var(--hover-bg);
    border-color: var(--border-color);
    color: var(--secondary-color);
}

.connection-item .btn-small.connected:hover {
    background: #fee2e2;
    border-color: #ef4444;
    color: #ef4444;
}

/* Responsive adjustments for connections */
@media (max-width: 1200px) {
    .connection-item {
        padding: 10px;
    }

    .connection-item .user-avatar {
        width: 40px;
        height: 40px;
    }

    .connection-name {
        font-size: 14px;
    }

    .connection-title {
        font-size: 12px;
    }
}

@media (max-width: 576px) {
    .suggested-connections {
        padding: 16px;
    }

    .connection-item {
        padding: 8px;
        gap: 8px;
    }

    .connection-item .user-avatar {
        width: 36px;
        height: 36px;
    }

    .connection-item .btn-small {
        padding: 6px 12px;
        min-width: 80px;
        height: 30px;
        font-size: 12px;
    }
}

/* Responsive adjustments for post images */
@media (max-width: 992px) {
    .content-preview {
        max-height: 280px;
    }
    
    .content-preview img {
        height: 280px;
    }
}

@media (max-width: 768px) {
    .content-preview {
        max-height: 250px;
    }
    
    .content-preview img {
        height: 250px;
    }
}

@media (max-width: 576px) {
    .content-preview {
        max-height: 220px;
    }
    
    .content-preview img {
        height: 220px;
    }
}

@media (max-width: 360px) {
    .content-preview {
        max-height: 200px;
    }
    
    .content-preview img {
        height: 200px;
    }
}

/* Trending Topics Styling */
.trending-topics {
    background: var(--white);
    border-radius: 16px;
    padding: 20px;
    border: 1px solid var(--border-color);
    margin-bottom: 24px;
}

.trending-topics h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 16px;
}

.topic-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.topic-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--hover-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.topic-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.topic-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.topic-tag {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 15px;
}

.topic-count {
    color: var(--secondary-color);
    font-size: 13px;
}

.topic-item i {
    color: var(--secondary-color);
    font-size: 16px;
    transition: transform 0.2s ease;
}

.topic-item:hover i {
    transform: translateX(2px);
    color: var(--primary-color);
}

/* Updated Suggested Connections Styling */
.connection-item {
    background: var(--white);
    padding: 16px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s ease;
}

.connection-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    background: var(--hover-bg);
}

.connection-item .user-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--white);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.connection-info {
    flex: 1;
    min-width: 0;
}

.connection-name {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 4px;
    display: block;
}

.connection-title {
    color: var(--secondary-color);
    font-size: 13px;
    display: block;
}

.connection-item .btn-small {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
    min-width: 90px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    background: transparent;
    border: 1.5px solid var(--primary-color);
    color: var(--primary-color);
}

.connection-item .btn-small:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
}

/* Connected state */
.connection-item .btn-small.connected {
    background: var(--hover-bg);
    border-color: var(--border-color);
    color: var(--secondary-color);
}

.connection-item .btn-small.connected:hover {
    background: #fee2e2;
    border-color: #ef4444;
    color: #ef4444;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .topic-item {
        padding: 10px 14px;
    }
    
    .connection-item {
        padding: 14px;
    }
}

@media (max-width: 576px) {
    .trending-topics,
    .suggested-connections {
        padding: 16px;
    }

    .topic-item {
        padding: 10px 12px;
    }

    .topic-tag {
        font-size: 14px;
    }

    .connection-item {
        padding: 12px;
    }

    .connection-item .user-avatar {
        width: 40px;
        height: 40px;
    }

    .connection-name {
        font-size: 14px;
    }

    .connection-item .btn-small {
        padding: 6px 12px;
        min-width: 80px;
        height: 32px;
    }
}

/* Feed Card Author Styling */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.card-header .user-info {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.card-header .user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--white);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    margin-top: 4px;
}

.user-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.user-name {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--secondary-color);
    font-size: 13px;
}

.card-content {
    padding-left: 54px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .card-header .user-avatar {
        width: 38px;
        height: 38px;
    }
    
    .card-content {
        padding-left: 50px;
    }
}

@media (max-width: 576px) {
    .card-header .user-avatar {
        width: 36px;
        height: 36px;
    }
    
    .card-content {
        padding-left: 48px;
    }
}

/* Auth Buttons in Sidebar */
.auth-buttons {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-login, .btn-signup {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s ease;
}

.btn-login {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

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

.btn-login:hover {
    background: var(--hover-bg);
}

.btn-signup:hover {
    opacity: 0.9;
}

/* Popup Styles */
.popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    z-index: 1000;
    padding-top: 5vh;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.create-post-popup {
    max-width: 552px;
    width: 95%;
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.15), 0 12px 24px rgba(0,0,0,0.3);
}

.popup-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.popup-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: rgba(0,0,0,0.9);
}

.close-popup {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: rgba(0,0,0,0.6);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.close-popup:hover {
    background: rgba(0,0,0,0.08);
}

.post-creator {
    padding: 0;
    max-height: 80vh;
    overflow-y: auto;
}

.creator-info {
    display: flex;
    gap: 12px;
    padding: 16px 24px;
}

.creator-info .user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
}

.creator-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.creator-name {
    font-size: 16px;
    font-weight: 600;
    color: rgba(0,0,0,0.9);
}

.privacy-selector {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 16px;
    border: 1px solid rgba(0,0,0,0.3);
    font-size: 12px;
    color: rgba(0,0,0,0.6);
    cursor: pointer;
    background: transparent;
}

.privacy-selector:hover {
    background: rgba(0,0,0,0.08);
    border-color: rgba(0,0,0,0.6);
}

.post-creator textarea {
    width: 100%;
    min-height: 120px;
    padding: 16px 24px;
    border: none;
    resize: none;
    font-size: 16px;
    color: rgba(0,0,0,0.9);
    background: transparent;
}

.post-creator textarea::placeholder {
    color: rgba(0,0,0,0.6);
    font-size: 16px;
}

.post-creator textarea:focus {
    outline: none;
}

.media-preview {
    margin: 0 24px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.media-preview img,
.media-preview video {
    width: 100%;
    max-height: 400px;
    object-fit: contain;
    background: #f9fafb;
}

.post-options {
    padding: 8px 24px;
    border-top: 1px solid var(--border-color);
    margin-top: 16px;
}

.option-label {
    font-size: 14px;
    font-weight: 600;
    color: rgba(0,0,0,0.6);
    margin-bottom: 8px;
}

.option-buttons {
    display: flex;
    gap: 8px;
}

.option-btn {
    min-width: 40px;
    height: 40px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: rgba(0,0,0,0.6);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.option-btn:hover {
    background: rgba(0,0,0,0.08);
    color: var(--primary-color);
}

.post-submit-wrapper {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
}

.post-submit-btn {
    min-width: 64px;
    padding: 6px 16px;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 600;
    background: var(--primary-color);
    color: white;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.post-submit-btn:disabled {
    background: rgba(0,0,0,0.08);
    color: rgba(0,0,0,0.3);
    cursor: not-allowed;
}

.post-submit-btn:not(:disabled):hover {
    background: #0056b3;
}

/* LinkedIn Style Create Post Box */
.create-post-box {
    background: var(--white);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    padding: 16px;
    margin-bottom: 24px;
}

.post-input-container {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    cursor: pointer;
}

.post-input-container .user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
}

.start-post-button {
    flex: 1;
    padding: 12px 16px;
    border-radius: 35px;
    border: 1px solid var(--border-color);
    color: rgba(0,0,0,0.6);
    font-size: 14px;
    transition: all 0.2s ease;
    background: var(--hover-bg);
}

.start-post-button:hover {
    background: rgba(0,0,0,0.08);
}

.quick-post-options {
    display: flex;
    justify-content: space-between;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    margin-top: 8px;
}

.quick-post-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: rgba(0,0,0,0.6);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quick-post-btn i {
    font-size: 20px;
}

.quick-post-btn:hover {
    background: rgba(0,0,0,0.08);
}

.text-primary {
    color: #70B5F9;
}

.text-warning {
    color: #E7A33E;
}

.text-success {
    color: #7FC15E;
}

/* Remove floating create button */
.floating-create-btn {
    display: none;
}

/* Event Creation Styles */
.create-event-popup {
    max-width: 700px;
}

.event-creator {
    padding: 0;
    max-height: 80vh;
    overflow-y: auto;
}

.event-banner-upload {
    height: 200px;
    background: #f9fafb;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}

.banner-placeholder {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(0,0,0,0.6);
    gap: 8px;
}

.banner-placeholder i {
    font-size: 32px;
}

.event-fields {
    padding: 24px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: rgba(0,0,0,0.9);
    margin-bottom: 8px;
}

.form-group input[type="text"],
.form-group input[type="datetime-local"] {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 14px;
}

.time-slots {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.event-type-selector {
    display: flex;
    gap: 16px;
}

.event-type {
    flex: 1;
    padding: 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.event-type input[type="radio"] {
    display: none;
}

.event-type i {
    font-size: 24px;
    color: rgba(0,0,0,0.6);
}

.event-type.selected {
    border-color: var(--primary-color);
    background: rgba(0,123,255,0.1);
}

/* Article Creation Styles */
.create-article-popup {
    max-width: 800px;
}

.article-creator {
    padding: 0;
    max-height: 80vh;
    overflow-y: auto;
}

.article-cover-upload {
    height: 250px;
    background: #f9fafb;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
}

.cover-placeholder {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(0,0,0,0.6);
    gap: 8px;
}

.article-fields {
    padding: 24px;
}

.article-title {
    width: 100%;
    padding: 16px 0;
    border: none;
    font-size: 32px;
    font-weight: 600;
    color: rgba(0,0,0,0.9);
}

.article-content {
    width: 100%;
    min-height: 400px;
    padding: 16px 0;
    border: none;
    font-size: 18px;
    line-height: 1.6;
    resize: none;
}

.article-tools {
    padding: 16px 0;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 8px;
}

.tool-btn {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    border: none;
    background: transparent;
    color: rgba(0,0,0,0.6);
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.tool-btn:hover {
    background: rgba(0,0,0,0.08);
}