.ks-summary { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; justify-content: space-between; padding: 12px 16px; margin-bottom: 12px; border-radius: 10px; background: #eef1ff; color: #343a40; font-size: 14px; }
.ks-summary__meta { font-size: 12px; color: #74788d; }
.ks-toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.ks-toolbar .ks-filter { max-width: 260px; }
.ks-legend { font-size: 12px; color: #74788d; margin-bottom: 12px; }
.ks-section { font-size: 14px; font-weight: 600; margin: 18px 0 10px; color: #343a40; }
.ks-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.ks-group { border: 1px solid #e3e6f0; border-radius: 10px; background: #fff; overflow: hidden; }
.ks-group[hidden] { display: none; }
.ks-group--main { border-color: #b9c3f8; }
.ks-group__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 12px; background: #f8f9fc; border-bottom: 1px solid #eef0f6; font-size: 13px; font-weight: 600; }
.ks-group--main .ks-group__head { background: #eef1ff; }
.ks-letter { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 6px; background: #556ee6; color: #fff; font-size: 13px; }
.ks-count { flex-shrink: 0; font-size: 11px; font-weight: 600; padding: 1px 8px; border-radius: 999px; background: #e3e6f0; color: #495057; }
.ks-list { list-style: none; margin: 0; padding: 4px 0; }
.ks-item { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 5px 12px; font-size: 13px; cursor: pointer; transition: background .15s; }
.ks-item[hidden] { display: none; }
.ks-item:hover { background: #f4f6fb; }
.ks-item.is-copied { background: #ecfdf5; }
.ks-item.is-copied .ks-text::after { content: " ✓"; color: #047857; }
.ks-text { overflow-wrap: anywhere; }
.ks-rank { flex-shrink: 0; min-width: 28px; text-align: center; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 6px; }
.ks-rank.is-top { background: #d1fae5; color: #047857; }
.ks-rank.is-first { background: #dbeafe; color: #1d4ed8; }
.ks-rank.is-second { background: #fef3c7; color: #b45309; }
.ks-rank.is-far { background: #f1f3f7; color: #74788d; }
.ks-item--locked { cursor: default; }
.ks-item--locked:hover { background: transparent; }
.ks-blur { filter: blur(4px); user-select: none; color: #74788d; }
.ks-more { padding: 6px 12px 8px; font-size: 12px; color: #556ee6; font-weight: 600; }
.ks-lock { font-style: normal; }
.ks-cta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-top: 18px; padding: 16px 18px; border-radius: 12px; background: linear-gradient(135deg, #556ee6, #34c38f); color: #fff; }
.ks-cta b { font-size: 16px; }
.ks-cta p { margin: 4px 0 0; font-size: 13px; opacity: .92; }
.ks-cta a { flex-shrink: 0; background: #fff; color: #556ee6; font-weight: 700; padding: 8px 18px; border-radius: 999px; text-decoration: none; }
@media (max-width: 576px) { .ks-grid { grid-template-columns: 1fr; } }
.ksp-form input { direction: rtl; text-align: right; }
.ks-public { padding-bottom: 30px; font-size: 14px; line-height: 1.8; }
.ks-public .ks-summary { background: #fff; border: 1px solid #dcdcff; }
.ks-public .text-muted { color: #74788d; }
.ks-public .alert { padding: 10px 16px; margin-bottom: 12px; border-radius: 12px; border: 1px solid transparent; }
.ks-public .alert-warning { background: #fff8e6; border-color: #fde3a7; color: #8a5a00; }
.ks-public .alert-info { background: #eef6ff; border-color: #cfe3ff; color: #1d4ed8; }
.ks-public .ks-group { border-radius: 14px; }

/* phase2 public */
.ks-public .ks-letter { background: #1f5ae6; }
.ks-public .ks-more { color: #1f5ae6; }
.ks-public .ks-summary { border-color: #d6e2fb; }
.ks-public .ks-cta { background: linear-gradient(135deg, var(--night-2), #1f5ae6); }
.ks-public .ks-cta a { color: #1f5ae6; }
