/* Customer Rating Stars */
.trm-stars {
    display: inline-flex;
    gap: 2px;
    align-items: center;
}

.trm-star {
    font-size: 20px;
    cursor: pointer;
    color: #d1d5db;
    transition: color 0.15s;
    line-height: 1;
}

.trm-star.active,
.trm-star:hover,
.trm-stars:hover .trm-star {
    color: #f59e0b;
}

.trm-stars .trm-star:hover ~ .trm-star {
    color: #d1d5db;
}

.trm-star-display {
    display: inline-flex;
    gap: 1px;
    align-items: center;
}

.trm-star-display .trm-star {
    font-size: 14px;
    cursor: default;
}

/* VIP & Blocked badges */
.trm-badge-vip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 8px;
    background: #fef3c7;
    color: #92400e;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.trm-badge-blocked {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 8px;
    background: #fee2e2;
    color: #991b1b;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

/* Customer modal tabs */
.trm-cust-tabs {
    display: flex;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 16px;
    gap: 0;
}

.trm-cust-tab {
    padding: 10px 16px;
    background: none;
    border: none;
    font-size: 13px;
    font-weight: 500;
    color: #6b7280;
    cursor: pointer;
    position: relative;
    transition: color 0.2s;
}

.trm-cust-tab:hover {
    color: #38BDF8;
}

.trm-cust-tab.active {
    color: #38BDF8;
}

.trm-cust-tab.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: #38BDF8;
}

.trm-cust-tab-content {
    display: none;
}

.trm-cust-tab-content.active {
    display: block;
}

/* Customer info grid */
.trm-cust-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}

.trm-cust-info-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.trm-cust-info-field label {
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.trm-cust-info-field input,
.trm-cust-info-field textarea {
    padding: 8px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 13px;
    transition: border-color 0.2s;
}

.trm-cust-info-field input:focus,
.trm-cust-info-field textarea:focus {
    outline: none;
    border-color: #38BDF8;
    box-shadow: 0 0 0 3px rgba(56,189,248,0.1);
}

/* Stats row */
.trm-cust-stats {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.trm-cust-stat {
    flex: 1;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 10px 12px;
    text-align: center;
}

.trm-cust-stat-value {
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    line-height: 1;
}

.trm-cust-stat-label {
    font-size: 11px;
    color: #6b7280;
    margin-top: 4px;
}

/* Loyalty milestone */
.trm-loyalty-milestone {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 6px;
    padding: 12px 14px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.trm-loyalty-milestone .dashicons {
    color: #38BDF8;
    font-size: 20px;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.trm-loyalty-milestone-text {
    flex: 1;
    font-size: 13px;
    color: #374151;
}

.trm-loyalty-milestone-text strong {
    color: #111827;
}

/* Loyalty reached */
.trm-loyalty-reached {
    background: #ecfdf5;
    border: 1px solid #6ee7b7;
    border-radius: 6px;
    padding: 12px 14px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.trm-loyalty-reached .dashicons {
    color: #059669;
    font-size: 20px;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Reservation history items */
.trm-cust-res-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid #f3f4f6;
    font-size: 13px;
    color: #374151;
}

.trm-cust-res-item:last-child {
    border-bottom: none;
}

/* Customers table row */
#trm-customers-tbody tr {
    cursor: pointer;
}

#trm-customers-tbody tr:hover td {
    background: #f0f9ff;
}

/* Rating note textarea */
#trm-rating-note {
    width: 100%;
    margin-top: 8px;
    padding: 8px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 13px;
    resize: vertical;
    min-height: 60px;
}

/* Block reason input */
#trm-block-reason {
    width: 100%;
    margin-top: 8px;
    padding: 8px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 13px;
}

/* Toggle row */
.trm-cust-toggle-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid #f3f4f6;
    font-size: 13px;
    color: #374151;
}

.trm-cust-toggle-row:last-child {
    border-bottom: none;
}

.trm-cust-toggle-row > label:first-child {
    font-weight: 600;
    min-width: 80px;
}

/* Fix toggle size in customer modal */
#trm-cust-modal-body .cdmtv-toggle {
    width: 30px !important;
    height: 15px !important;
    flex-shrink: 0;
}

#trm-cust-modal-body .cdmtv-toggle-slider {
    border-radius: 15px !important;
}

#trm-cust-modal-body .cdmtv-toggle-slider:before {
    width: 11px !important;
    height: 11px !important;
    left: 2px !important;
    bottom: 2px !important;
}

/* Modal VIP + stars header row */
.trm-modal-vip-stars-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

/* Reservation Details — 2-column layout */
.trm-modal-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 16px;
    margin-bottom: 4px;
    align-items: start;
}

.trm-modal-two-col > div {
    align-self: start;
}

/* Customer inline header (name + email display) */
.trm-cust-inline-header {
    margin-bottom: 4px;
}

.trm-cust-inline-name {
    font-size: 15px;
    font-weight: 700;
    color: #111827;
    line-height: 1.3;
}

.trm-cust-inline-email {
    font-size: 12px;
    color: #6b7280;
    margin-top: 2px;
}

/* VIP toggle + stars row in customer tab */
.trm-cust-vip-stars-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

/* Stars in dropdown results */
.trm-result-stars {
    color: #f59e0b;
    font-size: 12px;
    letter-spacing: 1px;
}

/* Fix toggle size in customer tab inside timeline modal */
#trm-modal-customer-tab .cdmtv-toggle {
    width: 30px !important;
    height: 15px !important;
    flex-shrink: 0;
}

#trm-modal-customer-tab .cdmtv-toggle-slider {
    border-radius: 15px !important;
}

#trm-modal-customer-tab .cdmtv-toggle-slider:before {
    width: 11px !important;
    height: 11px !important;
    left: 2px !important;
    bottom: 2px !important;
}

/* Inline editable name/email in customer tab */
.trm-inline-editable {
    cursor: text;
    border-radius: 4px;
    transition: background 0.15s;
    padding: 2px 24px 2px 4px;
    margin: -2px -4px;
    display: block;
    position: relative;
}

.trm-inline-editable::after {
    content: '\f464';
    font-family: dashicons;
    font-size: 12px;
    color: #d1d5db;
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
}

.trm-inline-editable:hover {
    background: #f0f9ff;
    outline: 1px dashed #bae6fd;
}

.trm-inline-editable:hover::after {
    color: #38BDF8;
}

/* Loyalty reward badge on reservation block */
.trm-res-loyalty-badge {
    position: absolute;
    top: 2px;
    right: 4px;
    font-size: 13px;
    line-height: 1;
    filter: drop-shadow(0 1px 1px rgba(0,0,0,.2));
}

/* Loyalty badge v header riadku modalu */
.trm-loyalty-header-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 2px 8px;
    background: #f0f9ff;
    color: #0369a1;
    border: 1px solid #bae6fd;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.trm-loyalty-header-reached {
    background: #ecfdf5;
    color: #065f46;
    border-color: #6ee7b7;
}

/* Give reward row v Customer sekcii */
.trm-loyalty-give-row {
    display: flex;
    gap: 8px;
    align-items: center;
    margin: 8px 0;
}

/* Loyalty pill v pravom stĺpci modalu */
.trm-loyalty-pill {
    display: inline-flex;
    align-items: center;
    padding: 3px 8px;
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 6px;
    margin-bottom: 4px;
    font-size: 11px;
    color: #0369a1;
    font-weight: 500;
    white-space: nowrap;
}

.trm-loyalty-pill-reached {
    background: #ecfdf5;
    border-color: #6ee7b7;
    color: #065f46;
    font-weight: 600;
    transition: background 0.15s;
}

.trm-loyalty-pill-reached:hover {
    background: #d1fae5;
}

.trm-loyalty-pill-done {
    background: #f3f4f6;
    border-color: #d1d5db;
    color: #6b7280;
    font-weight: 500;
}

.trm-loyalty-pill-label {
    line-height: 1.4;
}

/* Give reward panel (pod pill) */
.trm-loyalty-give-panel {
    display: flex;
    gap: 6px;
    align-items: center;
    padding: 8px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-top: 6px;
    margin-bottom: 4px;
}
