/* ===================================
   COMMENT SYSTEM STYLES
   Model Detail - Yorum Sistemi
   =================================== */

/* Comment Menu (Düzenle/Sil) */
.comment-menu {
    position: absolute;
    top: 32px;
    right: 0;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    min-width: 160px;
    z-index: 10;
    overflow: hidden;
}

.comment-menu button {
    display: block;
    width: 100%;
    text-align: left;
    padding: 12px 16px;
    background: none;
    border: none;
    cursor: pointer;
    color: #374151;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.comment-menu button:hover {
    background: #f3f4f6;
}

.comment-menu button i {
    width: 18px;
    text-align: center;
}

.comment-menu .btn-delete-comment,
.comment-menu .btn-delete-reply {
    color: #dc2626;
}

.comment-menu .btn-delete-comment:hover,
.comment-menu .btn-delete-reply:hover {
    background: #fef2f2;
}

.comment-menu-toggle {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: #9ca3af;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.comment-menu-toggle:hover {
    background: #f3f4f6;
    color: #374151;
}

/* Inline Comment Editor */
.comment-inline-editor,
.reply-inline-editor {
    margin-top: 16px;
    padding: 20px;
    background: #f9fafb;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
}

.comment-inline-editor .rating-input {
    margin-bottom: 16px;
}

.comment-inline-editor .star-rating.small i,
.reply-inline-editor .star-rating.small i {
    font-size: 1.2rem;
}

.comment-edit-text,
.reply-edit-text {
    width: 100%;
    min-height: 120px;
    resize: vertical;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.95rem;
    margin-bottom: 12px;
    transition: border-color 0.2s ease;
}

.comment-edit-text:focus,
.reply-edit-text:focus {
    outline: none;
    border-color: #b10000;
}

.comment-edit-image,
.reply-edit-image {
    margin-bottom: 12px;
    padding: 10px;
    border: 2px dashed #d1d5db;
    border-radius: 10px;
    width: 100%;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

.comment-edit-image:hover,
.reply-edit-image:hover {
    border-color: #b10000;
}

.comment-inline-editor .actions,
.reply-inline-editor .actions {
    display: flex;
    gap: 12px;
    margin-top: 12px;
}

/* Reply Form */
.comment-replies {
    margin-top: 20px;
    padding-left: 0;
}

.comment.reply {
    margin-left: 60px;
    padding: 16px;
    background: #f9fafb;
    border-left: 3px solid #e5e7eb;
}

.comment.reply .comment-avatar img {
    width: 40px;
    height: 40px;
}

.reply-form {
    margin-top: 16px;
    padding: 20px;
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
}

.reply-input-row {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.reply-input-wrap {
    flex: 1;
}

.reply-text {
    width: 100%;
    min-height: 100px;
    resize: vertical;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color 0.2s ease;
}

.reply-text:focus {
    outline: none;
    border-color: #b10000;
}

.reply-actions {
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.attach-reply,
.attach-picture {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: #6b7280;
    font-size: 0.9rem;
    padding: 8px 12px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.attach-reply:hover,
.attach-picture:hover {
    background: #f3f4f6;
    color: #374151;
}

.attach-reply i,
.attach-picture i {
    font-size: 1.1rem;
}

.reply-error,
.error-text {
    min-height: 1.2em;
    color: #dc2626;
    font-size: 0.9rem;
    margin-top: 8px;
}

/* Comment Image */
.comment-image {
    margin-top: 12px;
}

.comment-image img {
    max-width: 100%;
    max-height: 400px;
    border-radius: 12px;
    object-fit: cover;
}

/* Comment Meta (Like, Reply buttons) */
.comment-meta {
    margin-top: 12px;
    display: flex;
    align-items: center;
    gap: 16px;
    color: #6b7280;
    font-size: 0.9rem;
}

.btn-like-comment,
.btn-like-reply,
.btn-reply {
    background: none;
    border: none;
    padding: 6px 12px;
    color: #6b7280;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.btn-like-comment:hover,
.btn-like-reply:hover,
.btn-reply:hover {
    background: #f3f4f6;
    color: #374151;
}

.btn-like-comment i,
.btn-like-reply i {
    font-size: 1rem;
}

.btn-like-comment.active,
.btn-like-reply.active {
    color: #b10000;
}

.like-count {
    font-weight: 600;
    color: #374151;
}

/* Loading & Success States */
.btn-primary:disabled,
.btn-secondary:disabled,
.btn-send-comment:disabled,
.btn-send-reply:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-send-comment,
.btn-send-reply {
    background: linear-gradient(135deg, #b10000 0%, #800101 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-send-comment:not(:disabled):hover,
.btn-send-reply:not(:disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(177, 0, 0, 0.3);
}

.btn-save-edit,
.btn-save-reply {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-save-edit:hover,
.btn-save-reply:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(5, 150, 105, 0.3);
}

.btn-cancel-edit,
.btn-cancel-reply {
    background: #f3f4f6;
    color: #374151;
    border: 2px solid #e5e7eb;
    padding: 8px 18px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-cancel-edit:hover,
.btn-cancel-reply:hover {
    background: #e5e7eb;
}

/* Responsive Design */
@media (max-width: 768px) {
    .comment {
        padding: 16px;
        flex-direction: column;
        gap: 12px;
    }
    
    .comment.reply {
        margin-left: 20px;
        padding: 12px;
    }
    
    .comment-avatar {
        align-self: flex-start;
    }
    
    .comment-menu {
        min-width: 140px;
    }
    
    .comment-menu button {
        padding: 10px 14px;
        font-size: 0.9rem;
    }
    
    .reply-form {
        padding: 16px;
    }
    
    .comment-inline-editor,
    .reply-inline-editor {
        padding: 16px;
    }
    
    .comment-meta {
        flex-wrap: wrap;
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .comment.reply {
        margin-left: 10px;
    }
    
    .comment-inline-editor .actions,
    .reply-inline-editor .actions {
        flex-direction: column;
    }
    
    .comment-inline-editor .actions button,
    .reply-inline-editor .actions button {
        width: 100%;
        justify-content: center;
    }
}

/* Animation */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.comment-menu {
    animation: slideIn 0.2s ease;
}

.comment-inline-editor,
.reply-inline-editor,
.reply-form {
    animation: slideIn 0.3s ease;
}
