/* Emoji Picker Styles */
.emoji-picker {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 320px;
    z-index: 1000;
    margin-bottom: 10px;
    border: 1px solid #e4e6eb;
}

.emoji-picker.show {
    display: block !important;
}

.emoji-header {
    padding: 10px;
    border-bottom: 1px solid #e4e6eb;
    display: flex;
    align-items: center;
    gap: 10px;
}

.emoji-header input {
    flex: 1;
    padding: 8px;
    border: 1px solid #e4e6eb;
    border-radius: 4px;
    font-size: 14px;
}

.emoji-header button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    color: #65676b;
}

.emoji-categories {
    display: flex;
    padding: 8px;
    gap: 5px;
    border-bottom: 1px solid #e4e6eb;
    overflow-x: auto;
}

.emoji-category-btn {
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    border-radius: 4px;
    font-size: 20px;
}

.emoji-category-btn.active {
    background: #e4e6eb;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 5px;
    padding: 10px;
    max-height: 300px;
    overflow-y: auto;
}

.emoji-button {
    padding: 8px;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 20px;
    border-radius: 4px;
    display: inline-block;
    width: 40px;
    height: 40px;
    text-align: center;
    line-height: 40px;
}

.emoji-button:hover {
    background-color: #e4e6eb;
}

/* Position the emoji picker relative to the input */
.create-post {
    position: relative;
}

/* Ensure the emoji button is clickable */
.emoji-btn {
    background: none;
    border: none;
    padding: 8px;
    color: #65676b;
    cursor: pointer;
    border-radius: 50%;
    transition: background-color 0.2s;
    font-size: 20px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.emoji-btn:hover {
    background-color: #e4e6eb;
}

/* Ensure the post input container is properly positioned */
.post-input-container {
    position: relative;
    flex: 1;
}

/* Ensure the emoji picker appears above other elements */
.emoji-picker {
    z-index: 9999;
}

.emoji-container {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 10px;
    max-height: 300px;
    width: 300px;
    overflow-y: auto;
    z-index: 1000;
    border: 1px solid #e4e6eb;
    margin-top: 5px;
}

.post {
    background: white;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.post-header {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.post-info {
    margin-left: 10px;
}

.post-info h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
}

.post-time {
    font-size: 12px;
    color: #65676b;
}

.post-content {
    margin-bottom: 10px;
    line-height: 1.5;
}

.post-photo {
    margin: 10px 0;
}

.post-photo img {
    width: 100%;
    border-radius: 8px;
    max-height: 500px;
    object-fit: cover;
}

.post-actions {
    display: flex;
    gap: 20px;
    border-top: 1px solid #e4e6eb;
    padding-top: 10px;
}

.action-btn {
    background: none;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    color: #65676b;
    font-size: 14px;
    transition: color 0.2s;
}

.action-btn:hover {
    color: #1877f2;
}

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

.action-btn span {
    font-size: 14px;
}

.search-box {
    display: flex;
    align-items: center;
    background: #f0f2f5;
    border-radius: 20px;
    padding: 8px 16px;
    width: 240px;
}

.search-button {
    background: none;
    border: none;
    padding: 0;
    margin-right: 8px;
    color: #65676b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-button:hover {
    color: #1877f2;
}

.search-box input {
    border: none;
    background: none;
    outline: none;
    width: 100%;
    font-size: 14px;
    color: #050505;
}

.search-box input::placeholder {
    color: #65676b;
}

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-height: 400px;
    overflow-y: auto;
    z-index: 1000;
    margin-top: 8px;
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.search-result-item:hover {
    background-color: #f0f2f5;
}

.search-result-item .profile-pic {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 12px;
}

.search-result-item .user-info {
    display: flex;
    flex-direction: column;
}

.search-result-item .user-info h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: #050505;
}

.search-result-item .user-info span {
    font-size: 12px;
    color: #65676b;
}

.no-results {
    padding: 24px;
    text-align: center;
    color: #65676b;
}

.no-results i {
    font-size: 24px;
    margin-bottom: 8px;
}

.no-results p {
    margin: 0;
    font-size: 14px;
}

.nav-middle {
    position: relative;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.modal-content {
    position: relative;
    background-color: white;
    margin: 50px auto;
    padding: 20px;
    width: 90%;
    max-width: 500px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

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

.modal-header h2 {
    margin: 0;
    font-size: 24px;
    color: #050505;
}

.close-modal {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #65676b;
    padding: 0;
}

.close-modal:hover {
    color: #050505;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #050505;
}

.form-group input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #e4e6eb;
    border-radius: 6px;
    font-size: 14px;
    color: #050505;
}

.form-group input:focus {
    outline: none;
    border-color: #1877f2;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
}

.cancel-btn, .save-btn {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s;
}

.cancel-btn {
    background: none;
    border: 1px solid #e4e6eb;
    color: #050505;
}

.cancel-btn:hover {
    background-color: #f0f2f5;
}

.save-btn {
    background-color: #1877f2;
    border: none;
    color: white;
}

.save-btn:hover {
    background-color: #166fe5;
}

/* Registration Button Styles */
.register-btn {
    background-color: #1877f2;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-right: 12px;
    transition: background-color 0.2s;
}

.register-btn:hover {
    background-color: #166fe5;
}

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

/* Video Page Styles */
#video-page {
    display: none;
    background: #f0f2f5;
    min-height: calc(100vh - 60px);
    padding: 20px;
    position: relative;
    z-index: 1;
}

#video-page.active {
    display: block;
}

.video-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Video Upload Section */
.video-upload-section {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.video-upload-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.video-upload-header h2 {
    margin: 0;
    font-size: 20px;
    color: #050505;
}

.video-upload-btn {
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.video-upload-btn:hover {
    background-color: #f0f2f5;
}

.video-upload-btn i {
    color: #1877f2;
    font-size: 1.2em;
}

.video-upload-form {
    display: none;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e4e6eb;
}

.video-upload-form.active {
    display: block;
}

/* Video Grid Section */
.video-grid-section {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.video-grid-section h2 {
    margin: 0 0 20px 0;
    font-size: 20px;
    color: #050505;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.video-item {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.3s;
}

.video-item:hover {
    transform: translateY(-5px);
}

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    background: #000;
}

.video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.video-info {
    padding: 12px;
}

.video-title {
    font-weight: 600;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #050505;
}

.video-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #65676b;
    font-size: 14px;
}

/* Main Content Area */
.main-content {
    display: flex;
    gap: 20px;
    padding: 20px;
}

/* Video Preview */
.video-preview {
    margin-top: 10px;
    max-width: 100%;
    max-height: 300px;
    overflow: hidden;
    border-radius: 8px;
}

.video-preview video {
    width: 100%;
    height: auto;
}

/* Right Sidebar */
.right-sidebar {
    width: 300px;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    height: fit-content;
    position: sticky;
    top: 20px;
}

/* Filter Buttons */
.filter-btn {
    background: none;
    border: 1px solid #e4e6eb;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    color: #65676b;
    transition: all 0.3s;
}

.filter-btn.active {
    background-color: #1a73e8;
    color: white;
    border-color: #1a73e8;
}

/* Tab Buttons */
.tab-btn {
    background: none;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    color: #65676b;
    cursor: pointer;
    position: relative;
    transition: color 0.3s;
}

.tab-btn.active {
    color: #1a73e8;
    font-weight: 600;
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -16px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #1a73e8;
}

.video-item {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.3s;
}

.video-item:hover {
    transform: translateY(-5px);
}

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    background: #000;
}

.video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.video-info {
    padding: 12px;
}

.video-title {
    font-weight: 600;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #666;
    font-size: 14px;
}

.video-stats {
    display: flex;
    gap: 20px;
    color: #666;
    margin-bottom: 15px;
}

.video-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.video-actions button {
    background: none;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #666;
    transition: background-color 0.3s;
}

.video-actions button:hover {
    background-color: #f0f0f0;
}

.video-description {
    margin-bottom: 20px;
    line-height: 1.5;
}

.video-comments {
    border-top: 1px solid #eee;
    padding-top: 20px;
}

.comment-input {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.comment-input input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 20px;
    outline: none;
}

.comments-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.comment {
    display: flex;
    gap: 12px;
}

.comment-content {
    flex: 1;
}

.comment-author {
    font-weight: 600;
    margin-bottom: 4px;
}

.comment-text {
    color: #333;
    line-height: 1.4;
}

.comment-actions {
    display: flex;
    gap: 12px;
    margin-top: 8px;
    color: #666;
    font-size: 14px;
}

.comment-actions span {
    cursor: pointer;
}

.comment-actions span:hover {
    color: #1a73e8;
}

/* Videos Section Styles */
.videos-section {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    display: block;
}

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

.videos-header h2 {
    margin: 0;
    font-size: 20px;
    color: #050505;
}

.video-filters {
    display: flex;
    gap: 10px;
}

.video-filters .filter-btn {
    padding: 8px 16px;
    border: 1px solid #e4e6eb;
    border-radius: 20px;
    background: none;
    color: #65676b;
    cursor: pointer;
    transition: all 0.2s;
}

.video-filters .filter-btn:hover {
    background: #f0f2f5;
}

.video-filters .filter-btn.active {
    background: #1877f2;
    color: white;
    border-color: #1877f2;
}

.videos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.video-item {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.3s;
}

.video-item:hover {
    transform: translateY(-5px);
}

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    background: #000;
}

.video-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.video-info {
    padding: 12px;
}

.video-title {
    font-weight: 600;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: #050505;
}

.video-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #65676b;
    font-size: 14px;
    margin-bottom: 12px;
}

.video-actions {
    display: flex;
    gap: 12px;
    border-top: 1px solid #e4e6eb;
    padding-top: 12px;
}

.video-actions button {
    background: none;
    border: none;
    padding: 6px 12px;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    color: #65676b;
    transition: background-color 0.2s;
}

.video-actions button:hover {
    background-color: #f0f2f5;
}

.video-actions .like-btn i {
    color: #e41e3f;
}

.video-actions .share-btn i {
    color: #1877f2;
} 