/* Base Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f7fa;
    margin: 0;
    padding: 0;
}

/* Navigation Buttons */
.nav-buttons {
    display: flex;
    justify-content: space-between;
    padding: 15px;
    background: #2c3e50;
    margin-bottom: 20px;
}

.nav-buttons .btn {
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 4px;
    background: #4361ee;
    transition: background 0.3s;
}

.nav-buttons .btn:hover {
    background: #3a56d4;
}

/* Notes Details Section */
.notes-details {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.notes-details h1 {
    color: #2c3e50;
    margin-bottom: 10px;
    text-align: center;
}

.notes-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.notes-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #7f8c8d;
}

.notes-description {
    margin: 25px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.notes-description h2 {
    margin-top: 0;
    color: #2c3e50;
}

/* Rating Section */
.rating-section {
    display: flex;
    justify-content: center;
    margin: 25px 0;
}

.rating-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    text-align: center;
    width: 100%;
    max-width: 500px;
}

.rating-card h3 {
    margin-top: 0;
    color: #2c3e50;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.rating-value {
    font-size: 2.5em;
    font-weight: bold;
    margin: 15px 0;
    color: #4361ee;
}

.stars {
    margin: 10px 0;
}

.stars .fa-star {
    color: #ddd;
    font-size: 1.5em;
    margin: 0 2px;
}

.stars .fa-star.filled {
    color: #ffc107;
}

.rating-count {
    font-size: 0.9em;
    color: #666;
}

.user-rating {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.user-rating h4 {
    margin-bottom: 10px;
    color: #2c3e50;
}

.rating-stars {
    font-size: 1.5em;
    margin: 10px 0;
    cursor: pointer;
}

.rating-stars .far,
.rating-stars .fas {
    margin: 0 2px;
    transition: all 0.2s;
}

.rating-stars .fas {
    color: #ffc107;
}

/* Recent Ratings */
.recent-ratings {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin: 25px 0;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.recent-ratings h3 {
    margin-top: 0;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ratings-list {
    margin-top: 15px;
}

.rating-item {
    display: flex;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.rating-user {
    flex: 1;
}

.rating-stars {
    width: 120px;
}

.rating-stars .fa-star {
    font-size: 0.9em;
    margin: 0 1px;
}

.rating-time {
    width: 120px;
    text-align: right;
    font-size: 0.8em;
    color: #666;
}

/* Notes Actions */
.notes-actions {
    text-align: center;
    margin: 30px 0;
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    background: #4361ee;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: #4361ee;
}

.btn-primary:hover {
    background: #3a56d4;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.btn-small {
    padding: 8px 15px;
    font-size: 0.9em;
}

/* Chat Section */
.chat-section {
    max-width: 1000px;
    margin: 30px auto;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.chat-section h2 {
    margin-top: 0;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.chat-messages {
    height: 400px;
    overflow-y: auto;
    display: flex;
    flex-direction: column-reverse;
    padding: 10px;
    background: #f9f9f9;
    border-radius: 8px;
    margin-bottom: 15px;
}

.no-messages {
    text-align: center;
    padding: 20px;
    color: #666;
}

.message {
    margin-bottom: 15px;
    padding: 10px;
    border-radius: 5px;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.message-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 10px;
}

.sender {
    font-weight: bold;
}

.time {
    font-size: 0.8em;
    color: #7f8c8d;
}

.message-content {
    line-height: 1.5;
}

/* Reply System */
.reply-btn {
    background: none;
    border: none;
    color: #4361ee;
    cursor: pointer;
    font-size: 0.8em;
    padding: 5px 0;
    margin-top: 10px;
    display: inline-block;
}

.reply-btn:hover {
    text-decoration: underline;
}

.reply-form {
    margin-top: 15px;
    padding-left: 20px;
    border-left: 2px solid #eee;
}

.reply-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-bottom: 10px;
    min-height: 80px;
}

.replies-container {
    margin-left: 30px;
    border-left: 2px solid #ddd;
    padding-left: 15px;
    margin-top: 15px;
}

.reply-message {
    background: #f9f9f9;
    padding: 10px;
    margin: 5px 0;
    border-radius: 5px;
}

/* Chat Form */
.chat-form {
    margin-top: 20px;
}

.chat-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    min-height: 100px;
    margin-bottom: 15px;
    font-family: inherit;
}

.login-prompt {
    text-align: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 5px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .notes-meta {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .rating-item {
        flex-wrap: wrap;
    }
    
    .rating-user,
    .rating-stars,
    .rating-time {
        width: auto;
        flex: 1 1 100%;
    }
    
    .rating-stars {
        margin: 5px 0;
    }
}