.ksc-wrap {
    padding-bottom: 48px;
}
.ksc-hero {
    background: linear-gradient(135deg, #1b2a4e 0%, #3a1d73 48%, #d4a017 100%);
    border-radius: 22px;
    color: #fff;
    padding: 28px 32px;
    margin-bottom: 24px;
    box-shadow: 0 18px 40px rgba(27, 42, 78, 0.28);
    position: relative;
    overflow: hidden;
}
.ksc-hero:after {
    content: "";
    position: absolute;
    width: 220px;
    height: 220px;
    right: -60px;
    top: -80px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
}
.ksc-hero h1,
.ksc-hero h2 {
    color: #fff;
    margin: 0 0 8px;
    font-weight: 700;
    position: relative;
    z-index: 1;
}
.ksc-hero p {
    color: rgba(255, 255, 255, 0.88);
    margin: 0;
    max-width: 720px;
    position: relative;
    z-index: 1;
}
.ksc-hero .ksc-hero-actions {
    margin-top: 18px;
    position: relative;
    z-index: 1;
}
.ksc-btn {
    border: 0;
    border-radius: 999px !important;
    padding: 10px 22px !important;
    font-weight: 600;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
}
.ksc-btn-gold {
    background: linear-gradient(135deg, #f5d76e, #d4a017) !important;
    color: #1b2a4e !important;
}
.ksc-btn-gold:hover {
    color: #111 !important;
}
.ksc-btn-light {
    background: rgba(255, 255, 255, 0.16) !important;
    color: #fff !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
}
.ksc-btn-primary {
    background: linear-gradient(135deg, #4f46e5, #7c3aed) !important;
    color: #fff !important;
}
.ksc-btn-soft {
    background: #f3f0ff !important;
    color: #4f46e5 !important;
}
.ksc-stat {
    border: 0;
    border-radius: 18px;
    padding: 18px 12px;
    text-align: center;
    color: #fff;
    min-height: 118px;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.08);
    margin-bottom: 16px;
}
.ksc-stat small {
    display: block;
    opacity: 0.9;
    font-size: 12px;
    letter-spacing: 0.2px;
}
.ksc-stat strong {
    display: block;
    font-size: 32px;
    margin-top: 8px;
    line-height: 1;
}
.ksc-stat-info { background: linear-gradient(135deg, #2563eb, #38bdf8); }
.ksc-stat-warning { background: linear-gradient(135deg, #f59e0b, #f97316); }
.ksc-stat-primary { background: linear-gradient(135deg, #7c3aed, #ec4899); }
.ksc-stat-success { background: linear-gradient(135deg, #059669, #34d399); }
.ksc-stat-muted { background: linear-gradient(135deg, #475569, #94a3b8); }
.ksc-card {
    background: #fff;
    border: 0;
    border-radius: 20px;
    box-shadow: 0 14px 32px rgba(27, 42, 78, 0.08);
    padding: 22px;
    margin-bottom: 20px;
    height: calc(100% - 20px);
    transition: transform .2s ease, box-shadow .2s ease;
}
.ksc-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 36px rgba(27, 42, 78, 0.14);
}
.ksc-ticket {
    border-inline-start: 6px solid #7c3aed;
}
.ksc-ticket.is-success { border-inline-start-color: #10b981; }
.ksc-ticket.is-warning { border-inline-start-color: #f59e0b; }
.ksc-ticket.is-info { border-inline-start-color: #0ea5e9; }
.ksc-ticket.is-muted { border-inline-start-color: #94a3b8; }
.ksc-chip {
    display: inline-block;
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    background: #7c3aed;
}
.ksc-chip-success { background: #10b981; }
.ksc-chip-warning { background: #f59e0b; }
.ksc-chip-info { background: #0ea5e9; }
.ksc-chip-muted { background: #64748b; }
.ksc-section-title {
    font-size: 22px;
    font-weight: 700;
    color: #1b2a4e;
    margin: 8px 0 18px;
}
.ksc-dept {
    text-align: center;
    min-height: 180px;
}
.ksc-dept-icon {
    width: 54px;
    height: 54px;
    margin: 0 auto 12px;
    border-radius: 16px;
    color: #fff;
    font-size: 22px;
    line-height: 54px;
    text-align: center;
}
.ksc-tone-1 .ksc-dept-icon { background: linear-gradient(135deg, #2563eb, #06b6d4); }
.ksc-tone-2 .ksc-dept-icon { background: linear-gradient(135deg, #f59e0b, #ef4444); }
.ksc-tone-3 .ksc-dept-icon { background: linear-gradient(135deg, #8b5cf6, #ec4899); }
.ksc-tone-4 .ksc-dept-icon { background: linear-gradient(135deg, #10b981, #84cc16); }
.ksc-tone-5 .ksc-dept-icon { background: linear-gradient(135deg, #0ea5e9, #6366f1); }
.ksc-tone-6 .ksc-dept-icon { background: linear-gradient(135deg, #f97316, #eab308); }
.ksc-tone-0 .ksc-dept-icon { background: linear-gradient(135deg, #64748b, #1e293b); }
.ksc-form .form-control,
.ksc-form .select2-container .select2-selection {
    border-radius: 12px !important;
    min-height: 44px;
    border-color: #e2e8f0;
}
.ksc-form label {
    font-weight: 700;
    color: #1b2a4e;
}
.ksc-thread {
    max-width: 920px;
}
.ksc-msg {
    max-width: 82%;
    border-radius: 18px;
    padding: 14px 16px;
    margin-bottom: 14px;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}
.ksc-msg p {
    margin: 8px 0 0;
    white-space: pre-wrap;
}
.ksc-msg--customer {
    margin-inline-start: auto;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
}
.ksc-msg--customer .ksc-msg-meta {
    color: rgba(255, 255, 255, 0.8);
}
.ksc-msg--admin,
.ksc-msg--automated,
.ksc-msg--system {
    margin-inline-end: auto;
    background: #fff;
    border: 1px solid #eef2ff;
}
.ksc-msg--admin {
    background: linear-gradient(180deg, #ecfdf5, #fff);
    border-color: #a7f3d0;
}
.ksc-msg--automated {
    background: linear-gradient(180deg, #eff6ff, #fff);
    border-color: #bfdbfe;
}
.ksc-msg-meta {
    font-size: 12px;
    opacity: 0.8;
    display: flex;
    justify-content: space-between;
    gap: 12px;
}
.ksc-empty {
    border-radius: 16px;
    padding: 18px 20px;
    background: #eef2ff;
    color: #3730a3;
    border: 0;
}
.ksc-rate {
    background: linear-gradient(135deg, #ecfdf5, #fff);
    border: 1px solid #bbf7d0;
}
.ksc-stars {
    display: inline-flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 6px;
    direction: ltr;
    unicode-bidi: isolate;
    margin: 10px 0 16px;
}
.ksc-stars input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.ksc-stars label {
    margin: 0;
    cursor: pointer;
    color: #d1d5db;
    font-size: 34px;
    line-height: 1;
    transition: color .15s ease, transform .15s ease;
}
.ksc-stars label .fa {
    color: inherit !important;
    font-size: inherit;
}
.ksc-stars label:hover {
    transform: scale(1.12);
}
.ksc-stars input:checked + label,
.ksc-stars input:checked + label .fa,
.ksc-stars input:checked ~ label,
.ksc-stars input:checked ~ label .fa,
.ksc-stars label:hover,
.ksc-stars label:hover .fa,
.ksc-stars label:hover ~ label,
.ksc-stars label:hover ~ label .fa {
    color: #f5c518 !important;
}
.ksc-stars-readonly {
    display: inline-flex;
    gap: 4px;
    direction: ltr;
}
.ksc-stars-readonly i {
    font-size: 22px;
    color: #d1d5db;
}
.ksc-stars-readonly i.is-on {
    color: #f5c518;
}
.ksc-legacy {
    background: linear-gradient(180deg, #fff7ed, #fff);
    border-inline-start: 5px solid #f97316;
}
@media (max-width: 767px) {
    .ksc-hero { padding: 22px 18px; border-radius: 16px; }
    .ksc-msg { max-width: 100%; }
}
