/* Timeline Layout - Row Layout */
.timeline-layout {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

/* Timeline Form Styling */
.timeline-form-container {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 1px solid #e0e0e0;
    flex: 0 0 400px; /* Fixed width for form */
    min-width: 350px;
}

.timeline-form-container h3 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
    font-size: 20px;
    font-weight: 600;
}

.timeline-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.form-group input,
.form-group textarea {
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: "Roboto", serif;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #1c539f;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

.btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-family: "Roboto", serif;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-primary {
    background-color: #1c539f;
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background-color: #154080;
    transform: translateY(-2px);
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background-color: #c82333;
    transform: translateY(-2px);
}

/* Timeline Posts Styling */
.timeline-posts-container {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 1px solid #e0e0e0;
    flex: 1; /* Takes up remaining space */
    min-width: 0; /* Allows shrinking */
    display: flex;
    flex-direction: column;
    max-height: 600px; /* Limit height to prevent excessive scrolling */
}

.timeline-posts-container h3 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
    font-size: 20px;
    font-weight: 600;
}

.timeline-posts {
    display: flex;
    flex-direction: column;
    gap: 20px;
    flex: 1;
    overflow-y: auto;
    padding-right: 10px; /* Space for scrollbar */
}

.timeline-post {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    border-left: 4px solid #1c539f;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-post:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.post-header {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 15px;
}

.post-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #1c539f;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    flex-shrink: 0;
}

.post-info {
    flex: 1;
}

.post-name {
    margin: 0 0 5px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.post-email {
    margin: 0 0 5px 0;
    font-size: 14px;
    color: #666;
}

.post-date {
    margin: 0;
    font-size: 12px;
    color: #888;
}

.post-content {
    margin-left: 55px;
}

.post-content p {
    margin: 0;
    color: #333;
    line-height: 1.6;
    word-wrap: break-word;
}

/* Message Styling */
.message {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    animation: slideIn 0.3s ease;
}

.message-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Loading and Error States */
.loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

.error {
    text-align: center;
    padding: 40px;
    color: #dc3545;
    font-weight: 500;
}

.no-posts {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .timeline-layout {
        flex-direction: column;
        gap: 20px;
    }
    
    .timeline-form-container {
        flex: none;
        min-width: auto;
    }
    
    .timeline-posts-container {
        flex: none;
        max-height: none; /* Remove height limit on smaller screens */
    }
    
    .timeline-posts {
        overflow-y: visible; /* Remove scrolling on smaller screens */
    }
}

@media (max-width: 768px) {
    .timeline-layout {
        gap: 20px;
    }
    
    .timeline-form-container,
    .timeline-posts-container {
        padding: 20px;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .post-header {
        gap: 10px;
    }
    
    .post-content {
        margin-left: 0;
        margin-top: 10px;
    }
    
    .timeline-post {
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .timeline-form-container,
    .timeline-posts-container {
        padding: 15px;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 10px;
    }
    
    .btn {
        padding: 10px 15px;
        font-size: 13px;
    }
    
    .post-avatar {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
    
    .post-name {
        font-size: 15px;
    }
    
    .post-email {
        font-size: 13px;
    }
} 