/* SD Feedback - Frontend Styles */

.sd-feedback-form-wrapper {
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px;
    margin: 20px 0;
    max-width: 100%;
}

.sd-feedback-form-wrapper h3 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 1.3em;
}

.sd-field {
    margin-bottom: 15px;
}

.sd-field label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    font-size: 14px;
}

.sd-field input[type="text"],
.sd-field input[type="email"],
.sd-field select,
.sd-field textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
}

.sd-field textarea {
    resize: vertical;
    min-height: 100px;
}

.sd-star-rating {
    display: inline-flex;
    gap: 4px;
    cursor: pointer;
}

.sd-star {
    font-size: 24px;
    color: #ccc;
    cursor: pointer;
    transition: color 0.15s;
    user-select: none;
}

.sd-star:hover,
.sd-star.hover,
.sd-star.active {
    color: #f5b342;
}

.sd-star-filled {
    color: #f5b342;
}

.sd-field-optin label {
    font-weight: normal;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.sd-field-optin input[type="checkbox"] {
    margin: 0;
}

.sd-submit-btn {
    background: #2271b1;
    color: #fff;
    border: none;
    padding: 12px 30px;
    border-radius: 4px;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.2s;
}

.sd-submit-btn:hover {
    background: #135e96;
}

/* Success message */
.sd-feedback-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    padding: 15px 20px;
    margin-bottom: 20px;
}

.sd-feedback-success p {
    margin: 5px 0;
}

/* Feedback list */
.sd-feedback-list {
    margin: 20px 0;
}

.sd-feedback-item {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    padding: 20px;
    margin-bottom: 15px;
    transition: box-shadow 0.2s;
}

.sd-feedback-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.sd-feedback-header {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.sd-feedback-title {
    margin: 0;
    font-size: 1.1em;
}

.sd-feedback-type-label {
    font-size: 11px;
    background: #e8f0fe;
    color: #1967d2;
    padding: 2px 8px;
    border-radius: 3px;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.sd-feedback-status {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 3px;
    text-transform: uppercase;
    font-weight: 600;
}

.sd-status-reviewed { background: #e8f5e9; color: #2e7d32; }
.sd-status-in-progress { background: #fff3e0; color: #e65100; }
.sd-status-completed { background: #e8f5e9; color: #1b5e20; }
.sd-status-declined { background: #fbe9e7; color: #c62828; }

.sd-feedback-rating {
    margin-bottom: 10px;
}

.sd-feedback-content {
    font-size: 14px;
    line-height: 1.6;
    color: #333;
}

.sd-feedback-content p:last-child {
    margin-bottom: 0;
}

/* Voting */
.sd-feedback-votes {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.sd-vote-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border: 1px solid #ddd;
    background: #f8f8f8;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.15s;
}

.sd-vote-btn:hover {
    background: #eee;
}

.sd-vote-up:hover { color: #2e7d32; border-color: #2e7d32; }
.sd-vote-down:hover { color: #c62828; border-color: #c62828; }

.sd-vote-btn.voted {
    background: #e8f0fe;
    border-color: #1967d2;
}

/* Comments */
.sd-feedback-comments {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.sd-feedback-comments h5 {
    margin: 0 0 10px;
    font-size: 14px;
}

.sd-comment {
    background: #f8f9fa;
    border-radius: 4px;
    padding: 10px 15px;
    margin-bottom: 10px;
}

.sd-comment-date {
    font-size: 12px;
    color: #999;
    margin-left: 10px;
}

.sd-comment p {
    margin: 5px 0 0;
    font-size: 13px;
}

.sd-add-comment {
    margin-top: 10px;
}

.sd-add-comment input,
.sd-add-comment textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 8px;
    box-sizing: border-box;
    font-size: 13px;
}

.sd-comment-submit {
    background: #2271b1;
    color: #fff;
    border: none;
    padding: 8px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
}

.sd-comment-submit:hover {
    background: #135e96;
}

/* Poll */
.sd-poll {
    margin-top: 12px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 4px;
}

.sd-poll h5 {
    margin: 0 0 8px;
    font-size: 14px;
}

.sd-poll-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    border-bottom: 1px solid #eee;
}

.sd-poll-item:last-child {
    border-bottom: none;
}

.sd-poll-vote {
    background: #2271b1;
    color: #fff;
    border: none;
    padding: 3px 10px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
}

.sd-poll-vote:hover {
    background: #135e96;
}

.sd-poll-text {
    flex: 1;
    font-size: 13px;
}

.sd-poll-count {
    font-size: 12px;
    color: #999;
}

/* Testimonials */
.sd-testimonials {
    display: grid;
    gap: 20px;
}

.sd-testimonial {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    padding: 25px;
    position: relative;
}

.sd-testimonial blockquote {
    margin: 0;
    font-style: italic;
    font-size: 15px;
    line-height: 1.7;
    color: #444;
}

.sd-testimonial blockquote::before {
    content: '\201C';
    font-size: 40px;
    color: #ddd;
    position: absolute;
    top: 10px;
    left: 15px;
    font-family: Georgia, serif;
}

.sd-testimonial-meta {
    margin-top: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sd-testimonial-rating {
    color: #f5b342;
    font-size: 16px;
}

.sd-testimonial-meta cite {
    font-style: normal;
    font-size: 14px;
    color: #666;
}

/* Stats shortcode */
.sd-feedback-stats-shortcode {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.sd-stat-item {
    background: #f8f9fa;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    padding: 20px 30px;
    text-align: center;
    min-width: 120px;
}

.sd-stat-value {
    display: block;
    font-size: 28px;
    font-weight: 700;
    color: #1d2327;
}

.sd-stat-label {
    display: block;
    font-size: 13px;
    color: #666;
    margin-top: 5px;
}

/* Feedback button trigger */
.sd-feedback-btn {
    background: #2271b1;
    color: #fff;
    border: none;
    padding: 10px 24px;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
}

.sd-feedback-btn:hover {
    background: #135e96;
}

/* Empty state */
.sd-feedback-empty {
    text-align: center;
    padding: 40px 20px;
    color: #999;
}

/* Modal for feedback button trigger */
.sd-feedback-modal {
    display: none;
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    overflow-y: auto;
}

.sd-feedback-modal.open {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 50px;
}

.sd-feedback-modal-content {
    background: #fff;
    border-radius: 8px;
    max-width: 600px;
    width: 90%;
    padding: 30px;
    position: relative;
    margin-bottom: 50px;
}

.sd-feedback-modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #999;
    background: none;
    border: none;
    line-height: 1;
}

.sd-feedback-modal-close:hover {
    color: #333;
}

/* Responsive */
@media (max-width: 600px) {
    .sd-feedback-form-wrapper {
        padding: 15px;
    }
    .sd-feedback-item {
        padding: 15px;
    }
    .sd-feedback-stats-shortcode {
        flex-direction: column;
    }
}
