/* Thaidit Nail Feedback v1.7.0 -- selectors are scoped to avoid Elementor/theme clashes. */
.tnf-feedback, .tnf-dashboard {
    font-family: Kanit, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    box-sizing: border-box;
}
.tnf-feedback *, .tnf-dashboard * { box-sizing: border-box; }
.tnf-feedback {
    width: 100%; max-width: 500px; margin: 0 auto; padding: 25px;
    background: #fff; border: 1px solid #eee; border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,.05); color: #444;
}
.tnf-feedback .tnf-form-title {
    text-align: center; color: #ff66a3; margin: 0 0 20px;
    font-size: 23px; font-weight: 700; line-height: 1.5;
}
.tnf-feedback .tnf-field { margin: 0 0 20px; }
.tnf-feedback .tnf-field > label, .tnf-feedback .tnf-rating-field > legend {
    display: block; margin: 0 0 8px; color: #444; font-size: 15px; font-weight: 700;
}
.tnf-feedback .tnf-field input[type="text"],
.tnf-feedback .tnf-field input[type="tel"],
.tnf-feedback .tnf-field textarea {
    width: 100%; min-height: 42px; padding: 12px; border: 1px solid #ddd;
    border-radius: 8px; background: #fff; color: #333;
    font: inherit; transition: border-color .2s, box-shadow .2s;
}
.tnf-feedback .tnf-field input:focus, .tnf-feedback .tnf-field textarea:focus {
    outline: none; border-color: #ff66a3; box-shadow: 0 0 0 2px rgba(255,102,163,.15);
}
.tnf-feedback .tnf-rating-field { border: 0; padding: 0; min-width: 0; }
.tnf-feedback .tnf-emoji-rating {
    display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px; padding: 15px 5px; background: #fdfdfd;
    border: 1px solid #f0f0f0; border-radius: 12px; text-align: center;
}
.tnf-feedback .tnf-rating-option {
    position: relative; display: block; margin: 0; padding: 3px 2px;
    cursor: pointer; font-weight: 400; -webkit-tap-highlight-color: transparent;
}
.tnf-feedback .tnf-rating-option input[type="radio"] {
    position: absolute; width: 1px; height: 1px; opacity: 0;
    overflow: hidden; clip: rect(0,0,0,0);
}
.tnf-feedback .tnf-emoji { display: block; font-size: 38px; line-height: 1.5; transition: transform .2s; }
.tnf-feedback .tnf-emoji-text { display: block; color: #888; font-size: 13px; line-height: 1.5; }
.tnf-feedback .tnf-rating-option input:checked ~ .tnf-emoji { transform: scale(1.23); }
.tnf-feedback .tnf-rating-option input:checked ~ .tnf-emoji-text { color: #d72f74; font-weight: 700; }
.tnf-feedback .tnf-rating-option input:focus-visible ~ .tnf-emoji { outline: 2px solid #ff66a3; outline-offset: 3px; border-radius: 6px; }
.tnf-feedback .tnf-submit, .tnf-feedback .tnf-history-button {
    display: block; width: 100%; border-radius: 8px; border: 0;
    padding: 13px 16px; cursor: pointer; font: inherit; font-size: 16px;
    text-align: center; transition: background-color .2s;
}
.tnf-feedback .tnf-submit { background: #ff66a3; color: #fff; font-weight: 700; }
.tnf-feedback .tnf-submit:hover { background: #e65590; }
.tnf-feedback button:disabled { opacity: .65; cursor: wait; }
.tnf-feedback .tnf-response { text-align: center; font-weight: 700; margin: 15px 0 0; }
.tnf-feedback .tnf-response.tnf-success { color: #187b4d; }
.tnf-feedback .tnf-response.tnf-error { color: #d63638; }
.tnf-feedback [hidden] { display: none !important; }
.tnf-feedback .tnf-history-section hr { border: 0; border-top: 1px dashed #ddd; margin: 25px 0; }
.tnf-feedback .tnf-history-button { background: #f5f5f5; color: #555; border: 1px solid #ddd; font-size: 15px; }
.tnf-feedback .tnf-history-button:hover { background: #e8e8e8; }
.tnf-feedback .tnf-history-container { margin-top: 15px; font-size: 14px; }
.tnf-feedback .tnf-history-title { margin: 0 0 10px; text-align: center; font-size: 15px; }
.tnf-feedback .tnf-history-card { padding: 13px 15px; margin-bottom: 10px; background: #fff;
    border: 1px solid #ffe0ec; border-left: 4px solid #ff66a3;
    border-radius: 8px; box-shadow: 0 2px 5px rgba(255,102,163,.05); }
.tnf-feedback .tnf-history-card > div { margin-bottom: 5px; }
.tnf-feedback .tnf-history-card > div:last-child { margin-bottom: 0; }
.tnf-feedback .tnf-history-card strong { color: #d72f74; }
.tnf-feedback .tnf-history-comment { margin-top: 8px; padding-top: 8px; border-top: 1px dashed #ffe0ec; }
.tnf-feedback .tnf-history-comment p { margin: 5px 0 0; font-size: 13px; color: #666; overflow-wrap: anywhere; }

.tnf-dashboard { max-width: 1120px; margin: 0 auto; color: #333; }
.tnf-dashboard.tnf-dashboard-admin { max-width: none; margin: 20px 20px 20px 0; }
.tnf-dashboard .tnf-dashboard-title { text-align: center; font-size: 24px; line-height: 1.5;
    color: #e84e91; margin: 0 0 25px; font-weight: 700; }
.tnf-dashboard .tnf-stats-grid { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 15px; margin: 0 0 24px; }
.tnf-dashboard .tnf-stat { background: #fff; border-radius: 12px; padding: 20px 10px;
    border: 1px solid #f2f2f2; border-bottom: 5px solid #ddd; text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,.05); }
.tnf-dashboard .tnf-stat h3 { margin: 0 0 8px; font-size: 14px; color: #666; font-weight: 500; line-height: 1.6; }
.tnf-dashboard .tnf-stat p { margin: 0; font-size: 32px; line-height: 1.3; font-weight: 700; color: #333; }
.tnf-dashboard .tnf-stat-total { border-bottom-color: #4a90e2; }
.tnf-dashboard .tnf-stat-excellent { border-bottom-color: #2ecc71; }
.tnf-dashboard .tnf-stat-good { border-bottom-color: #f1c40f; }
.tnf-dashboard .tnf-stat-fair { border-bottom-color: #e67e22; }
.tnf-dashboard .tnf-stat-poor { border-bottom-color: #e74c3c; }
.tnf-dashboard .tnf-filter-box { padding: 20px; margin: 0 0 18px; background: #fff;
    border-radius: 12px; border-left: 5px solid #ff66a3; box-shadow: 0 4px 10px rgba(0,0,0,.05); }
.tnf-dashboard .tnf-filter-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 15px; margin: 0; }
.tnf-dashboard .tnf-filter-field { flex: 1 1 200px; min-width: 0; }
.tnf-dashboard .tnf-filter-field label { display: block; margin: 0 0 8px; font-size: 14px; color: #555; font-weight: 700; }
.tnf-dashboard .tnf-filter-field input { width: 100%; min-height: 42px; padding: 10px 14px;
    border: 1px solid #ddd; background: #fff; border-radius: 8px; font: inherit; font-size: 14px; }
.tnf-dashboard .tnf-filter-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.tnf-dashboard .tnf-button { display: inline-flex; align-items: center; justify-content: center;
    min-height: 42px; padding: 10px 18px; font: inherit; font-size: 14px; font-weight: 700;
    border-radius: 8px; border: 0; text-decoration: none; cursor: pointer; }
.tnf-dashboard .tnf-button-primary { background: #ff66a3; color: #fff; }
.tnf-dashboard .tnf-button-primary:hover { background: #e65590; color: #fff; }
.tnf-dashboard .tnf-button-secondary { background: #f0f0f0; color: #555; }
.tnf-dashboard .tnf-button-secondary:hover { background: #e4e4e4; color: #333; }
.tnf-dashboard .tnf-list-meta { font-size: 14px; color: #666; margin: 0 0 10px; }
.tnf-dashboard .tnf-table-scroll { max-width: 100%; overflow-x: auto; border-radius: 12px;
    background: #fff; box-shadow: 0 4px 10px rgba(0,0,0,.05); }
.tnf-dashboard .tnf-data-table { border-collapse: collapse; width: 100%; min-width: 780px; margin: 0;
    font-size: 14px; background: #fff; border: 0; }
.tnf-dashboard .tnf-data-table th, .tnf-dashboard .tnf-data-table td { text-align: left;
    padding: 15px 12px; border: 0; border-bottom: 1px solid #f0f0f0; vertical-align: top; }
.tnf-dashboard .tnf-data-table th { background: #ff66a3; color: #fff;
    font-weight: 600; white-space: nowrap; }
.tnf-dashboard .tnf-data-table td { color: #333; overflow-wrap: anywhere; }
.tnf-dashboard .tnf-data-table tbody tr:hover { background: #fff9fc; }
.tnf-dashboard .tnf-data-table .tnf-empty { text-align: center; padding: 30px; color: #888; }
.tnf-dashboard .tnf-pagination { display: flex; align-items: center; justify-content: center;
    flex-wrap: wrap; gap: 7px; margin: 22px 0; }
.tnf-dashboard .tnf-page-link, .tnf-dashboard .tnf-page-current { min-width: 38px; min-height: 38px;
    display: inline-flex; justify-content: center; align-items: center; padding: 7px 11px;
    border-radius: 7px; font-size: 14px; text-decoration: none; }
.tnf-dashboard .tnf-page-link { border: 1px solid #efcadb; color: #b72d72; background: #fff; }
.tnf-dashboard .tnf-page-link:hover { background: #fff0f6; color: #a22363; }
.tnf-dashboard .tnf-page-current { background: #ff66a3; border: 1px solid #ff66a3; color: #fff; font-weight: 700; }
.tnf-dashboard .tnf-page-ellipsis { color: #888; padding: 0 3px; }
@media (max-width: 800px) {
    .tnf-dashboard .tnf-stats-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@media (max-width: 550px) {
    .tnf-feedback { padding: 17px; }
    .tnf-feedback .tnf-emoji { font-size: 31px; }
    .tnf-dashboard .tnf-stats-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; }
    .tnf-dashboard .tnf-stat { padding: 12px 5px; }
    .tnf-dashboard .tnf-stat h3 { font-size: 12px; }
    .tnf-dashboard .tnf-stat p { font-size: 26px; }
    .tnf-dashboard .tnf-filter-box { padding: 15px; }
    .tnf-dashboard .tnf-filter-field { flex-basis: 100%; }
    .tnf-dashboard .tnf-filter-actions { width: 100%; }
    .tnf-dashboard .tnf-filter-actions > * { flex: 1; }
}
