.kskm {
    --kskm-primary: #e92b5f;
    --kskm-primary-dark: #bf1746;
    --kskm-border: #e7e7e7;
    --kskm-muted: #666;
    --kskm-bg: #fff;
    --kskm-soft: #f8f8f8;
    max-width: 1100px;
    margin: 24px auto;
}

.kskm *, .kskm-box * {
    box-sizing: border-box;
}

.kskm-box,
.kskm-hero,
.kskm-stat {
    background: var(--kskm-bg);
    border: 1px solid var(--kskm-border);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,.06);
}

.kskm-box,
.kskm-hero {
    padding: 24px;
    margin-bottom: 22px;
}

.kskm-hero h2,
.kskm-box h3,
.kskm-leaderboard h3 {
    margin-top: 0;
}

.kskm-rules {
    color: var(--kskm-muted);
    max-width: 760px;
}

.kskm-progress {
    height: 18px;
    background: #eee;
    border-radius: 999px;
    overflow: hidden;
    margin-top: 20px;
}

.kskm-progress span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--kskm-primary), #ff8a00);
    border-radius: inherit;
}

.kskm-progress-label,
.kskm-help {
    color: var(--kskm-muted);
    font-size: .95rem;
}

.kskm-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin: 20px 0;
}

.kskm-stats-grid-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.kskm-stat {
    padding: 20px;
    text-align: center;
}

.kskm-stat strong {
    display: block;
    font-size: clamp(1.35rem, 3vw, 2.1rem);
    line-height: 1.1;
    color: var(--kskm-primary-dark);
}

.kskm-stat span {
    display: block;
    margin-top: 8px;
    color: var(--kskm-muted);
    font-size: .95rem;
}

.kskm-button,
.kskm input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 999px;
    padding: 12px 20px;
    background: var(--kskm-primary);
    color: #fff !important;
    text-decoration: none !important;
    font-weight: 700;
    cursor: pointer;
    transition: transform .15s ease, background .15s ease;
}

.kskm-button:hover,
.kskm input[type="submit"]:hover {
    background: var(--kskm-primary-dark);
    transform: translateY(-1px);
}

.kskm-form input[type="text"],
.kskm-form input[type="email"],
.kskm-form input[type="password"],
.kskm-form input[type="date"],
.kskm-copy-input {
    width: 100%;
    max-width: 460px;
    border: 1px solid var(--kskm-border);
    border-radius: 10px;
    padding: 11px 12px;
    background: #fff;
}

.kskm-entry-form {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    align-items: end;
}

.kskm-entry-form p {
    margin: 0;
}

.kskm-entry-form p:last-child {
    grid-column: 1 / -1;
}

.kskm-table-wrap {
    overflow-x: auto;
    border: 1px solid var(--kskm-border);
    border-radius: 14px;
    background: #fff;
}

.kskm-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.kskm-table th,
.kskm-table td {
    padding: 13px 14px;
    border-bottom: 1px solid var(--kskm-border);
    text-align: left;
}

.kskm-table th {
    background: var(--kskm-soft);
    font-weight: 700;
}

.kskm-table tr:last-child td {
    border-bottom: 0;
}

.kskm-message {
    border-radius: 12px;
    padding: 13px 15px;
    margin: 0 0 18px;
    border: 1px solid #bde5c8;
    background: #effaf2;
    color: #1b6b2a;
}

.kskm-message-error {
    border-color: #f1b8b8;
    background: #fff1f1;
    color: #9d1d1d;
}

.kskm-invite-info {
    border-radius: 12px;
    padding: 13px 15px;
    margin-bottom: 18px;
    background: #fff7e6;
    border: 1px solid #ffe0a3;
}

.kskm-badge,
.kskm-badge-warning {
    display: inline-block;
    border-radius: 999px;
    padding: 3px 9px;
    font-size: .8rem;
    font-weight: 700;
}

.kskm-badge {
    background: #eef5ff;
    color: #1c5d99;
}

.kskm-badge-warning {
    background: #fff1d8;
    color: #9a5a00;
}

.kskm-members {
    margin-left: 1.2em;
}

@media (max-width: 800px) {
    .kskm-stats-grid,
    .kskm-stats-grid-compact,
    .kskm-entry-form {
        grid-template-columns: 1fr;
    }
}

/* Rozšířené fialové bloky, žebříčky a validace */
.kskm-purple-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin: 20px 0;
}

.kskm-purple-card {
    position: relative;
    overflow: hidden;
    min-height: 132px;
    padding: 22px;
    border-radius: 20px;
    color: #fff;
    background: radial-gradient(circle at top right, rgba(255,255,255,.24), transparent 34%), linear-gradient(135deg, #7b2cff, #b428c9 54%, #ec2f86);
    box-shadow: 0 16px 38px rgba(93, 31, 150, .22);
}

.kskm-purple-card::after {
    content: '';
    position: absolute;
    right: -36px;
    bottom: -52px;
    width: 120px;
    height: 120px;
    border-radius: 999px;
    background: rgba(255,255,255,.16);
}

.kskm-purple-card strong {
    display: block;
    position: relative;
    z-index: 1;
    font-size: clamp(1.35rem, 2.4vw, 2.25rem);
    line-height: 1.1;
}

.kskm-purple-card span {
    display: block;
    position: relative;
    z-index: 1;
    margin-top: 9px;
    font-weight: 700;
    opacity: .92;
}

.kskm-form-errors {
    display: none;
    grid-column: 1 / -1;
    width: 100%;
    border-radius: 14px;
    padding: 14px 16px;
    margin-bottom: 8px;
    background: #fff0f3;
    border: 1px solid #ffb8c8;
    color: #8d1633;
}

.kskm-form-errors.is-visible {
    display: block;
}

.kskm-form-errors ul {
    margin: 8px 0 0 20px;
}

.kskm .kskm-field-error {
    border-color: #e92b5f !important;
    box-shadow: 0 0 0 3px rgba(233,43,95,.14) !important;
    outline: 0;
}

.kskm-mini-button {
    border: 0;
    border-radius: 999px;
    padding: 7px 12px;
    background: #f0e8ff;
    color: #6226b6;
    font-weight: 700;
    cursor: pointer;
}

.kskm-mini-button:hover {
    background: #e3d3ff;
}

.kskm-rankings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.kskm-ranking-panel {
    margin: 0;
}
.kskm-standalone-ranking .kskm-ranking-panel {
    margin-bottom: 0;
}

.kskm-standalone-ranking .kskm-ranking-list {
    margin-bottom: 0;
}


.kskm-ranking-list {
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: kskm-rank;
}

.kskm-ranking-list li {
    counter-increment: kskm-rank;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid var(--kskm-border);
}

.kskm-ranking-list li:last-child {
    border-bottom: 0;
}

.kskm-ranking-list li::before {
    content: counter(kskm-rank) '.';
    flex: 0 0 34px;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, #7b2cff, #ec2f86);
    color: #fff;
    font-weight: 800;
}

.kskm-ranking-list li > .kskm-ranking-main {
    flex: 1 1 auto;
}

.kskm-ranking-list li small {
    display: block;
    margin-top: 3px;
    color: var(--kskm-muted);
}

.kskm-ranking-list li b {
    white-space: nowrap;
    color: var(--kskm-primary-dark);
}

.kskm-ranking-list .kskm-empty-ranking::before {
    display: none;
}

.kskm-chart-box h3 {
    margin-top: 0;
}

.kskm-chart {
    display: flex;
    align-items: end;
    gap: 7px;
    min-height: 310px;
    padding: 48px 0 42px;
    overflow-x: auto;
    overflow-y: hidden;
}

.kskm-chart-item {
    position: relative;
    flex: 1 0 28px;
    min-width: 28px;
    height: 220px;
    display: flex;
    align-items: end;
    justify-content: center;
}

.kskm-chart-bar {
    width: 100%;
    max-width: 34px;
    min-height: 4px;
    border-radius: 10px 10px 3px 3px;
    background: linear-gradient(180deg, #ec2f86, #7b2cff);
    box-shadow: 0 10px 18px rgba(123, 44, 255, .22);
}

.kskm-chart-value {
    position: absolute;
    top: -42px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
    font-size: .72rem;
    font-weight: 800;
    line-height: 1;
    color: var(--kskm-primary-dark);
    white-space: nowrap;
}

.kskm-chart-number,
.kskm-chart-unit {
    display: block;
}

.kskm-chart-unit {
    font-size: .66em;
    font-weight: 700;
    line-height: 1;
    text-transform: lowercase;
}

.kskm-chart-label {
    position: absolute;
    bottom: -26px;
    left: 50%;
    transform: translateX(-50%) rotate(-38deg);
    transform-origin: top left;
    font-size: .76rem;
    color: var(--kskm-muted);
    white-space: nowrap;
}

@media (max-width: 900px) {
    .kskm-purple-grid,
    .kskm-rankings-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .kskm-purple-grid,
    .kskm-rankings-grid {
        grid-template-columns: 1fr;
    }

    .kskm-chart-item {
        flex-basis: 34px;
    }
}

/* Profil účastníka a souhlasové checkboxy */
.kskm-profile-box {
    margin: 18px 0;
}

.kskm-checkbox-line label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    max-width: 720px;
    line-height: 1.45;
}

.kskm-checkbox-line input[type="checkbox"] {
    width: auto;
    min-width: 18px;
    height: 18px;
    margin-top: .15em;
}

.kskm-checkbox-line a {
    color: var(--kskm-primary-dark);
    font-weight: 700;
}


.kskm-invite-email-form {
    margin-top: 12px;
    padding: 16px;
    border-radius: 16px;
    background: #faf7ff;
    border: 1px solid rgba(110, 58, 180, .18);
}

.kskm-invite-list {
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
}

.kskm-invite-list li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0, 0, 0, .08);
}


/* Verze 0.6.0 – osobní nástěnka, týmový detail a profilový plugin */
.kskm-account-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.kskm-account-hero-main {
    display: flex;
    align-items: center;
    gap: 16px;
}

.kskm-avatar,
.kskm img.kskm-avatar,
.kskm .avatar.kskm-avatar {
    width: 44px;
    height: 44px;
    border-radius: 999px;
    object-fit: cover;
    flex: 0 0 auto;
    box-shadow: 0 5px 14px rgba(0,0,0,.12);
}

.kskm-account-hero .kskm-avatar,
.kskm-account-hero img.kskm-avatar,
.kskm-account-hero .avatar.kskm-avatar {
    width: 74px;
    height: 74px;
}

.kskm-avatar-empty,
.kskm-team-icon {
    width: 44px;
    height: 44px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 800;
    background: linear-gradient(135deg, #7b2cff, #ec2f86);
    box-shadow: 0 5px 14px rgba(123, 44, 255, .22);
    flex: 0 0 auto;
}

.kskm-team-icon-large {
    width: 74px;
    height: 74px;
    font-size: 1.75rem;
}

.kskm-ranking-main {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.kskm-ranking-main strong a {
    color: inherit;
    text-decoration: none;
}

.kskm-ranking-main strong a:hover {
    text-decoration: underline;
}

.kskm-button-secondary {
    background: #f0e8ff !important;
    color: #6226b6 !important;
}

.kskm-button-secondary:hover {
    background: #e3d3ff !important;
    color: #4d168d !important;
}

.kskm-profile-layout,
.kskm-dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.kskm-profile-core-plugin .ksupf-profile-wrap {
    margin: 0;
    max-width: none;
}

.kskm-profile-core-plugin .ksupf-section {
    border-radius: 16px;
}

.kskm-card-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.kskm-mini-card {
    border: 1px solid var(--kskm-border);
    border-radius: 14px;
    padding: 14px;
    background: #fff;
}

.kskm-mini-card strong,
.kskm-mini-card span,
.kskm-mini-card small {
    display: block;
}

.kskm-mini-card span {
    margin-top: 4px;
    color: var(--kskm-primary-dark);
    font-weight: 800;
}

.kskm-mini-card small {
    margin-top: 4px;
    color: var(--kskm-muted);
}

.kskm-member-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.kskm-member-card {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    border: 1px solid var(--kskm-border);
    border-radius: 16px;
    padding: 14px;
    background: #fff;
}

.kskm-member-card small {
    display: block;
    margin-top: 3px;
    color: var(--kskm-muted);
}

.kskm-member-card b {
    color: var(--kskm-primary-dark);
    white-space: nowrap;
}

.kskm-empty-state {
    background: #fff8fb;
}

@media (max-width: 900px) {
    .kskm-profile-layout,
    .kskm-dashboard-grid,
    .kskm-member-cards,
    .kskm-card-list {
        grid-template-columns: 1fr;
    }

    .kskm-account-hero {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 560px) {
    .kskm-member-card {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .kskm-member-card b {
        grid-column: 1 / -1;
    }
}


.kskm-inline-delete-form {
    display: inline-flex;
    margin-left: 6px;
}

.kskm-mini-button-danger {
    background: #fff1f1 !important;
    color: #9d1d1d !important;
    border-color: #f1b8b8 !important;
}


/* Verze 0.7.1 – profilový obrázek týmu a oprava ikon v žebříčku */
.kskm-team-avatar,
.kskm img.kskm-team-avatar {
    border-radius: 999px;
    object-fit: cover;
    flex: 0 0 auto;
    box-shadow: 0 5px 14px rgba(0,0,0,.12);
}

.kskm-ranking-main .kskm-team-icon,
.kskm-ranking-main .kskm-team-avatar,
.kskm-ranking-main img.kskm-team-avatar,
.kskm-ranking-main .kskm-avatar,
.kskm-ranking-main img.kskm-avatar {
    flex: 0 0 44px !important;
    width: 44px !important;
    height: 44px !important;
    max-width: 44px !important;
}

.kskm-ranking-list li::after,
.kskm-ranking-list li > .kskm-ranking-main::before,
.kskm-ranking-list li > .kskm-ranking-main::after,
.kskm-ranking-main .kskm-team-icon::before,
.kskm-ranking-main .kskm-team-icon::after,
.kskm-ranking-main .kskm-team-avatar::before,
.kskm-ranking-main .kskm-team-avatar::after {
    content: none !important;
    display: none !important;
}

.kskm-team-manage-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.kskm-team-manage-header h3 {
    margin-bottom: 4px;
}

.kskm-team-image-form-wrap {
    margin: 18px 0 20px;
    padding: 16px;
    border: 1px solid var(--kskm-border);
    border-radius: 16px;
    background: #faf8ff;
}

.kskm-team-image-form input[type="file"] {
    display: block;
    width: 100%;
    padding: 10px;
    border: 1px dashed var(--kskm-border);
    border-radius: 12px;
    background: #fff;
}

@media (max-width: 600px) {
    .kskm-team-manage-header {
        align-items: flex-start;
    }
}


/* Verze 0.7.2 – sjednocené nahrávání obrázku týmu s profilovým pluginem */
.kskm-team-image-form-wrap {
    background: #f8f8f8;
    border-color: var(--kskm-border);
    box-shadow: 0 2px 8px rgba(0,0,0,.05);
}

.kskm-team-picture-container {
    margin-top: 12px;
}

.kskm-team-picture-preview {
    width: 100px;
    height: 100px;
    margin-bottom: 12px;
}

.kskm-team-picture-preview .kskm-team-avatar,
.kskm-team-picture-preview img.kskm-team-avatar,
.kskm-team-picture-preview .kskm-team-icon {
    width: 100px !important;
    height: 100px !important;
    max-width: 100px !important;
    display: inline-flex;
    border-radius: 50%;
    object-fit: cover;
}

.kskm-team-file-upload {
    position: relative;
    display: inline-block;
    margin: 8px 10px 8px 0;
    padding: 9px 16px;
    border: 0;
    border-radius: 4px;
    background: var(--kskm-primary);
    color: #fff !important;
    cursor: pointer;
    font-weight: 700;
    line-height: 1.3;
    text-decoration: none !important;
    transition: background .2s ease, transform .08s ease;
}

.kskm-team-file-upload:hover,
.kskm-team-file-upload:focus {
    background: var(--kskm-primary-dark);
    color: #fff !important;
}

.kskm-team-file-upload:active {
    transform: translateY(1px);
}

.kskm-team-file-upload input[type="file"],
.kskm-team-image-form .kskm-team-picture-input {
    display: none !important;
}

.kskm-team-upload-progress {
    width: 100%;
    max-width: 420px;
    height: 8px;
    margin: 0 0 12px;
    overflow: hidden;
    border-radius: 999px;
    background: #eee;
}

.kskm-team-upload-progress .bar {
    width: 0;
    height: 100%;
    border-radius: 999px;
    background: var(--kskm-primary);
    transition: width .25s ease;
}

.kskm-team-upload-message {
    min-height: 1.6em;
}

.kskm-upload-success,
.kskm-upload-error {
    display: inline-block;
    margin: 8px 0 10px;
    font-weight: 700;
}

.kskm-upload-success {
    color: #1d7f38;
}

.kskm-upload-error {
    color: #b00020;
}

.kskm-team-delete-image {
    display: none !important;
}

.kskm-js .kskm-team-delete-image:not(.is-hidden) {
    display: inline-block !important;
}

.kskm-team-delete-image.is-hidden {
    display: none !important;
}

.kskm-js .kskm-team-image-fallback {
    display: none !important;
}

@media (max-width: 600px) {
    .kskm-team-file-upload,
    .kskm-team-delete-image,
    .kskm-team-image-fallback {
        width: 100%;
        margin-right: 0;
        margin-bottom: 8px;
        text-align: center;
    }
}


/* Payments */
.kskm-payment-box .kskm-payment-status-row{margin:0 0 12px;display:flex;gap:10px;align-items:center;flex-wrap:wrap}.kskm-badge-danger{display:inline-block;padding:3px 8px;border-radius:999px;background:#fee2e2;color:#991b1b;font-weight:700;font-size:.85em}.kskm-payment-options{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:18px;margin-top:16px}.kskm-payment-option{border:1px solid rgba(140,42,190,.16);border-radius:18px;padding:18px;background:#fff}.kskm-payment-option h4{margin-top:0}.kskm-bank-grid{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:18px;align-items:start}.kskm-bank-grid code{font-size:1.05em}.kskm-bank-qr{text-align:center}.kskm-bank-qr img{display:block;max-width:240px;height:auto;border-radius:14px;background:#fff;padding:8px;border:1px solid #eee}@media(max-width:640px){.kskm-bank-grid{grid-template-columns:1fr}.kskm-bank-qr{text-align:left}}


/* Verze 0.8.6 – izolace frontendu od globálních stylů šablony Twenty Twenty a podobných šablon.
   Twenty Twenty nastavuje html { font-size: 62.5%; }, široká pravidla pro .entry-content, tabulky,
   seznamy a tlačítka. Plugin proto uvnitř .kskm používá vlastní typografický základ a u drobných
   prvků používá px místo rem, aby texty grafů a štítků nebyly nečekaně malé. */
.entry-content > .kskm,
.entry-content > .kskm:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.is-style-wide),
[class*="__inner-container"] > .kskm,
[class*="__inner-container"] > .kskm:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.is-style-wide) {
    max-width: 1100px;
    width: calc(100% - 40px);
}

.kskm,
.kskm *:not(svg):not(path),
.kskm-box,
.kskm-box *:not(svg):not(path) {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    letter-spacing: normal;
}

.kskm,
.kskm-box {
    font-size: 16px;
    line-height: 1.5;
    color: #1f1f1f;
    text-align: left;
}

.kskm p,
.kskm li,
.kskm label,
.kskm input,
.kskm select,
.kskm textarea,
.kskm button,
.kskm table,
.kskm th,
.kskm td,
.kskm small,
.kskm code,
.kskm-box p,
.kskm-box li,
.kskm-box label,
.kskm-box input,
.kskm-box select,
.kskm-box textarea,
.kskm-box button,
.kskm-box table,
.kskm-box th,
.kskm-box td,
.kskm-box small,
.kskm-box code {
    font-size: inherit;
    line-height: inherit;
    letter-spacing: normal;
}

.kskm p,
.kskm-box p {
    margin: 0 0 14px;
}

.kskm h1,
.kskm h2,
.kskm h3,
.kskm h4,
.kskm h5,
.kskm h6,
.kskm-box h1,
.kskm-box h2,
.kskm-box h3,
.kskm-box h4,
.kskm-box h5,
.kskm-box h6 {
    font-family: inherit;
    letter-spacing: normal;
    line-height: 1.18;
    font-weight: 800;
    color: inherit;
    margin: 0 0 16px;
}

.kskm h1,
.kskm-box h1 { font-size: 36px; }
.kskm h2,
.kskm-box h2 { font-size: 30px; }
.kskm h3,
.kskm-box h3 { font-size: 22px; }
.kskm h4,
.kskm-box h4 { font-size: 18px; }
.kskm h5,
.kskm-box h5 { font-size: 16px; }
.kskm h6,
.kskm-box h6 { font-size: 14px; text-transform: none; }

.kskm ul,
.kskm ol,
.kskm-box ul,
.kskm-box ol {
    margin: 0 0 16px 22px;
    padding: 0;
}

.kskm li,
.kskm-box li {
    margin: 4px 0 0;
}

.kskm a,
.kskm-box a {
    transition: color .15s ease, background-color .15s ease, transform .15s ease;
}

.kskm table,
.kskm-box table {
    font-size: 15px;
    line-height: 1.4;
    margin: 0;
    border-collapse: collapse;
    border-spacing: 0;
    width: 100%;
}

.kskm th,
.kskm td,
.kskm-box th,
.kskm-box td {
    line-height: 1.4;
    padding: 13px 14px;
    text-align: left;
}

.kskm label,
.kskm-box label {
    display: block;
    font-size: 15px;
    line-height: 1.35;
    font-weight: 700;
    margin: 0 0 6px;
}

.kskm input[type="text"],
.kskm input[type="password"],
.kskm input[type="email"],
.kskm input[type="url"],
.kskm input[type="date"],
.kskm input[type="number"],
.kskm textarea,
.kskm select,
.kskm-box input[type="text"],
.kskm-box input[type="password"],
.kskm-box input[type="email"],
.kskm-box input[type="url"],
.kskm-box input[type="date"],
.kskm-box input[type="number"],
.kskm-box textarea,
.kskm-box select {
    font-size: 16px;
    line-height: 1.35;
    letter-spacing: normal;
    min-height: auto;
}

.kskm button,
.kskm .kskm-button,
.kskm .kskm-mini-button,
.kskm .kskm-team-file-upload,
.kskm input[type="button"],
.kskm input[type="submit"],
.kskm-box button,
.kskm-box .kskm-button,
.kskm-box .kskm-mini-button,
.kskm-box input[type="button"],
.kskm-box input[type="submit"] {
    font-family: inherit;
    font-size: 15px;
    line-height: 1.25;
    letter-spacing: normal;
    text-transform: none;
}

.kskm .kskm-mini-button,
.kskm-box .kskm-mini-button {
    font-size: 13px;
}

.kskm-progress-label,
.kskm-help {
    font-size: 15px;
}

.kskm-stat strong {
    font-size: clamp(22px, 3vw, 34px);
}

.kskm-stat span {
    font-size: 15px;
}

.kskm-badge,
.kskm-badge-warning,
.kskm-badge-danger {
    font-size: 13px;
    line-height: 1.3;
}

.kskm-purple-card strong {
    font-size: clamp(22px, 2.4vw, 36px);
}

.kskm-purple-card span {
    font-size: 15px;
    line-height: 1.35;
}

.kskm-ranking-list {
    margin: 0;
    padding: 0;
}

.kskm-ranking-list li {
    margin: 0;
    line-height: 1.35;
}

.kskm-ranking-list li small,
.kskm-mini-card small,
.kskm-member-card small {
    font-size: 13px;
    line-height: 1.35;
}

.kskm-chart {
    font-size: 16px;
    line-height: 1.2;
}

.kskm-chart-value {
    font-size: 12px;
    line-height: 1;
}

.kskm-chart-value .kskm-chart-unit {
    font-size: 9px;
    line-height: 1;
}

.kskm-chart-label {
    font-size: 12px;
    line-height: 1.15;
}

.kskm-team-icon-large {
    font-size: 28px;
}

.kskm code,
.kskm-box code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: .92em;
    padding: 2px 5px;
}

@media (max-width: 700px) {
    .entry-content > .kskm,
    .entry-content > .kskm:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.is-style-wide),
    [class*="__inner-container"] > .kskm,
    [class*="__inner-container"] > .kskm:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.is-style-wide) {
        width: calc(100% - 24px);
    }

    .kskm h1,
    .kskm-box h1 { font-size: 30px; }
    .kskm h2,
    .kskm-box h2 { font-size: 26px; }
    .kskm h3,
    .kskm-box h3 { font-size: 20px; }
}


/* Verze 0.8.7 – karty vlastních zápisů a sjednocená správa týmu */
.kskm-section-heading,
.kskm-team-panel-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.kskm-section-heading h3,
.kskm-team-panel-header h4 {
    margin: 0 0 4px;
}

.kskm-entry-history {
    margin-top: 22px;
}

.kskm-entry-list {
    display: grid;
    gap: 12px;
}

.kskm-entry-card {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--kskm-border);
    border-radius: 16px;
    background: linear-gradient(180deg, #fff, #fffafd);
    box-shadow: 0 8px 22px rgba(0,0,0,.035);
}


.kskm-entry-date {
    width: 82px;
    min-height: 64px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: #f5efff;
    color: #5b229f;
    text-align: center;
}

.kskm-entry-date strong {
    display: block;
    font-size: 18px;
    line-height: 1.1;
}

.kskm-entry-date span {
    display: block;
    margin-top: 3px;
    font-size: 13px;
    color: var(--kskm-muted);
}

.kskm-entry-main {
    min-width: 0;
}

.kskm-entry-km {
    display: flex;
    align-items: baseline;
    gap: 5px;
    color: var(--kskm-primary-dark);
}

.kskm-entry-km strong {
    font-size: 24px;
    line-height: 1;
}

.kskm-entry-km span {
    font-size: 14px;
    font-weight: 800;
}

.kskm-entry-note {
    margin: 7px 0 0;
    color: #333;
    line-height: 1.35;
}

.kskm-muted {
    color: var(--kskm-muted);
}


.kskm-entry-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.kskm-entry-actions .kskm-inline-delete-form {
    margin-left: 0;
}

.kskm-entry-empty,
.kskm-compact-empty {
    padding: 16px;
    border-radius: 14px;
    border: 1px dashed rgba(123, 44, 255, .25);
}

.kskm-team-sections {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr);
    gap: 18px;
    margin-top: 22px;
}

.kskm-team-panel {
    padding: 18px;
    border: 1px solid var(--kskm-border);
    border-radius: 18px;
    background: linear-gradient(180deg, #fff, #fffafd);
    box-shadow: 0 8px 22px rgba(0,0,0,.035);
}

.kskm-member-cards-manage {
    grid-template-columns: 1fr;
}

.kskm-member-cards-manage .kskm-member-card {
    border-radius: 15px;
    box-shadow: none;
}

.kskm-member-avatar .avatar,
.kskm-member-avatar img {
    display: block;
    width: 48px;
    height: 48px;
    border-radius: 999px;
}

.kskm-member-main {
    min-width: 0;
}

.kskm-member-main strong {
    display: block;
    color: #251229;
    overflow-wrap: anywhere;
}

.kskm-member-total {
    display: block;
    margin-top: 4px;
    color: var(--kskm-primary-dark);
    font-size: 13px;
    font-weight: 800;
    line-height: 1.35;
}

.kskm-member-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
}

.kskm-member-remove-form {
    margin: 0;
}

.kskm-team-note {
    margin: 12px 0 0;
}

.kskm-invite-email-form {
    margin-top: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

.kskm-invite-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 12px;
}

.kskm-invite-row label {
    margin: 0;
}

.kskm-invite-row .kskm-button {
    min-height: 44px;
}

.kskm-copy-card {
    margin-top: 14px;
    padding: 14px;
    border-radius: 14px;
    background: #faf7ff;
    border: 1px solid rgba(110,58,180,.16);
}

.kskm-copy-card label {
    margin: 0;
}

.kskm-copy-card .kskm-copy-input {
    margin-top: 7px;
    max-width: none;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 14px;
}

.kskm-invites-recent {
    margin-top: 16px;
}

.kskm-invites-recent h5 {
    margin: 0 0 8px;
    font-size: 16px;
}

.kskm-invite-list-modern li {
    align-items: center;
    margin: 0;
    padding: 9px 0;
}

@media (max-width: 820px) {
    .kskm-entry-card,
    .kskm-team-sections,
    .kskm-invite-row {
        grid-template-columns: 1fr;
    }

    .kskm-entry-card {
        align-items: stretch;
    }

    .kskm-entry-date {
        width: 100%;
        min-height: auto;
        align-items: flex-start;
        padding: 12px;
        text-align: left;
    }

    .kskm-entry-actions,
    .kskm-member-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 560px) {
    .kskm-member-cards-manage .kskm-member-card {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .kskm-member-actions {
        grid-column: 1 / -1;
    }
}

/* Verze 0.8.9 – kompaktní správa obrázku týmu, kopírování pozvánky a jednodušší osobní nástěnka */
.kskm-team-image-inline {
    flex: 0 0 auto;
    width: 140px;
}

.kskm-team-image-form-inline {
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    text-align: center;
}

.kskm-team-image-form-inline .kskm-team-picture-container,
.kskm-team-image-form-inline .kskm-team-picture-preview,
.kskm-team-image-form-inline .kskm-team-picture-preview-small {
    margin: 0 auto 8px;
}

.kskm-team-picture-preview-small,
.kskm-team-picture-preview-small .kskm-team-avatar,
.kskm-team-picture-preview-small img.kskm-team-avatar,
.kskm-team-picture-preview-small .kskm-team-icon {
    width: 74px !important;
    height: 74px !important;
    max-width: 74px !important;
}

.kskm-team-image-form-inline .kskm-team-upload-progress {
    max-width: 118px;
    height: 6px;
    margin: 8px auto;
}

.kskm-team-image-form-inline .kskm-team-upload-message {
    min-height: 0;
    font-size: 12px;
    line-height: 1.25;
}

.kskm-team-image-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
}

.kskm-team-image-form-inline .kskm-team-file-upload,
.kskm-team-image-form-inline .kskm-team-delete-image,
.kskm-team-image-form-inline .kskm-team-image-fallback {
    width: 100%;
    max-width: 132px;
    margin: 0;
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 12px;
    line-height: 1.2;
    text-align: center;
}

.kskm-team-title-meta {
    min-width: 0;
}

.kskm-copy-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 46px;
    gap: 8px;
    align-items: stretch;
    margin-top: 7px;
}

.kskm-copy-card .kskm-copy-field .kskm-copy-input {
    margin-top: 0;
}

.kskm-copy-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 46px;
    min-height: 44px;
    border: 1px solid rgba(110,58,180,.22);
    border-radius: 12px;
    background: #fff;
    color: #6226b6;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    transition: background .15s ease, transform .15s ease, border-color .15s ease;
}

.kskm-copy-button:hover,
.kskm-copy-button:focus,
.kskm-copy-button.is-copied {
    background: #f0e8ff;
    border-color: rgba(110,58,180,.38);
    transform: translateY(-1px);
}

.kskm-copy-feedback {
    min-height: 18px;
    margin-top: 6px;
    color: #1d7f38;
    font-size: 13px;
    font-weight: 700;
}

.kskm-copy-feedback.is-error {
    color: #b00020;
}

@media (max-width: 640px) {
    .kskm-team-manage-header {
        display: grid;
        grid-template-columns: 1fr;
        text-align: left;
    }

    .kskm-team-image-inline,
    .kskm-team-image-form-inline .kskm-team-file-upload,
    .kskm-team-image-form-inline .kskm-team-delete-image,
    .kskm-team-image-form-inline .kskm-team-image-fallback {
        max-width: none;
        width: 100%;
    }

    .kskm-team-image-actions {
        align-items: stretch;
    }
}


.kskm-suspicious-tooltip {
    display: none;
    position: relative;
    width: 100%;
    box-sizing: border-box;
    margin: 8px 0 10px;
    padding: 11px 13px 11px 40px;
    border: 1px solid rgba(255, 150, 0, 0.35);
    border-radius: 14px;
    background: linear-gradient(135deg, #fff7df, #fff0f7);
    color: #5f3200;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
    box-shadow: 0 10px 24px rgba(90, 44, 0, 0.08);
}

.kskm-suspicious-tooltip::before {
    content: "🏃";
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    line-height: 1;
}

.kskm-suspicious-tooltip.is-visible {
    display: block;
}

/* Ochrana běžných textů pluginu před barevnými pravidly aktivní šablony. */
.kskm,
.kskm-box,
.kskm-hero,
.kskm-stat,
.kskm-ranking-panel,
.kskm-team-panel,
.kskm-entry-card,
.kskm-mini-card,
.kskm-member-card {
    color: #1f1f1f !important;
}

.kskm p,
.kskm li,
.kskm label,
.kskm legend,
.kskm th,
.kskm td,
.kskm caption,
.kskm small,
.kskm strong,
.kskm h1,
.kskm h2,
.kskm h3,
.kskm h4,
.kskm h5,
.kskm h6,
.kskm-box p,
.kskm-box li,
.kskm-box label,
.kskm-box legend,
.kskm-box th,
.kskm-box td,
.kskm-box caption,
.kskm-box small,
.kskm-box strong,
.kskm-box h1,
.kskm-box h2,
.kskm-box h3,
.kskm-box h4,
.kskm-box h5,
.kskm-box h6 {
    color: inherit !important;
}

.kskm a:not(.kskm-button),
.kskm-box a:not(.kskm-button) {
    color: var(--kskm-primary-dark) !important;
}

.kskm input:not([type="submit"]):not([type="button"]),
.kskm select,
.kskm textarea,
.kskm-box input:not([type="submit"]):not([type="button"]),
.kskm-box select,
.kskm-box textarea {
    color: #1f1f1f !important;
    background-color: #fff !important;
}

/* Zachování záměrných barev zvláštních prvků. */
.kskm-purple-card {
    color: #fff !important;
}

.kskm-stat strong,
.kskm-ranking-list li b,
.kskm-mini-card span,
.kskm-member-card b,
.kskm-entry-km {
    color: var(--kskm-primary-dark) !important;
}

.kskm-rules,
.kskm-progress-label,
.kskm-help,
.kskm-stat span,
.kskm-ranking-list li small,
.kskm-mini-card small,
.kskm-member-card small,
.kskm-entry-date span,
.kskm-muted {
    color: var(--kskm-muted) !important;
}

.kskm-message {
    color: #1b6b2a !important;
}

.kskm-message-error {
    color: #9d1d1d !important;
}

.kskm-form-errors {
    color: #8d1633 !important;
}

.kskm-entry-date {
    color: #5b229f !important;
}

.kskm-member-main strong {
    color: #251229 !important;
}


/* Volitelná vyšší platba */
.kskm-payment-form{margin:0}.kskm-payment-amount-selector{margin:18px 0 4px;padding:18px;border:1px solid rgba(140,42,190,.16);border-radius:18px;background:rgba(140,42,190,.035)}.kskm-payment-amount-intro>*:first-child{margin-top:0}.kskm-payment-amount-intro>*:last-child{margin-bottom:14px}.kskm-payment-amount-input{display:flex;align-items:center;gap:10px;max-width:300px;margin-top:7px}.kskm-payment-amount-input input{width:100%;min-width:0;font-size:1.15em;font-weight:700}.kskm-payment-amount-input span{font-weight:700}.kskm-payment-amount-choices{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}.kskm-amount-choice{appearance:none;border:1px solid rgba(140,42,190,.28);border-radius:999px;background:#fff;padding:7px 12px;cursor:pointer;font:inherit;font-weight:700;color:inherit}.kskm-amount-choice:hover,.kskm-amount-choice:focus,.kskm-amount-choice.is-selected{border-color:currentColor;box-shadow:0 0 0 2px rgba(140,42,190,.08)}.kskm-payment-extra{font-size:.9em;opacity:.8}.kskm-button-secondary{margin-top:8px}

/* Volba částky před zobrazením platebních údajů */
.kskm-payment-step {
    margin-top: 20px;
    padding: 20px;
    border: 1px solid rgba(140,42,190,.16);
    border-radius: 18px;
    background: rgba(140,42,190,.035);
}

.kskm-payment-step-heading {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
}

.kskm-payment-step-heading h4,
.kskm-payment-step-heading p {
    margin-top: 0;
}

.kskm-payment-step-heading h4 {
    margin-bottom: 4px;
}

.kskm-payment-step-heading p {
    margin-bottom: 0;
}

.kskm-payment-amount-form {
    margin: 0;
}

.kskm-payment-amount-choices {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 14px 0;
}

.kskm-amount-preset {
    appearance: none;
    border: 1px solid rgba(140,42,190,.28);
    border-radius: 999px;
    background: #fff;
    padding: 9px 15px;
    cursor: pointer;
    font: inherit;
    font-weight: 750;
    color: inherit;
}

.kskm-amount-preset:hover,
.kskm-amount-preset:focus {
    border-color: #8c2abe;
    box-shadow: 0 0 0 3px rgba(140,42,190,.09);
}

.kskm-custom-amount-details {
    margin-top: 10px;
    max-width: 460px;
}

.kskm-custom-amount-details summary {
    display: inline-flex;
    align-items: center;
    min-height: 42px;
    padding: 8px 14px;
    border: 1px solid rgba(140,42,190,.28);
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
    font-weight: 750;
}

.kskm-custom-amount-details[open] summary {
    margin-bottom: 12px;
}

.kskm-custom-amount-fields {
    padding: 16px;
    border: 1px solid rgba(140,42,190,.14);
    border-radius: 14px;
    background: #fff;
}

.kskm-custom-amount-fields .kskm-button {
    margin-top: 12px;
}

.kskm-payment-change-amount {
    margin: -4px 0 16px;
}

.kskm-payment-change-amount .kskm-button-secondary {
    margin-top: 0;
}

@media (max-width: 640px) {
    .kskm-payment-step {
        padding: 16px;
    }

    .kskm-amount-preset,
    .kskm-custom-amount-details summary {
        width: 100%;
        justify-content: center;
    }

    .kskm-payment-amount-choices {
        display: grid;
        grid-template-columns: repeat(2, minmax(0,1fr));
    }
}


/* Verze 0.9.12 – bezpečné smazání týmu kapitánem */
.kskm-team-delete-zone {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    margin-top: 20px;
    padding: 17px 18px;
    border: 1px solid rgba(190, 24, 69, .18);
    border-radius: 16px;
    background: #fff8fa;
}

.kskm-team-delete-copy {
    min-width: 0;
}

.kskm-team-delete-copy strong {
    display: block;
    margin-bottom: 3px;
    color: #8f1233;
}

.kskm-team-delete-copy p {
    margin: 0;
    color: #6f5360;
    font-size: 13px;
    line-height: 1.5;
}

.kskm-team-delete-form {
    flex: 0 0 auto;
    margin: 0;
}

.kskm-delete-team-button {
    min-width: 118px;
    white-space: nowrap;
}

@media (max-width: 640px) {
    .kskm-team-delete-zone {
        align-items: stretch;
        flex-direction: column;
    }

    .kskm-team-delete-form,
    .kskm-delete-team-button {
        width: 100%;
    }
}

/* Verze 0.9.13 – bezpečné opuštění týmu běžným členem */
.kskm-team-leave-zone {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    margin-top: 20px;
    padding: 17px 18px;
    border: 1px solid rgba(104, 70, 119, .18);
    border-radius: 16px;
    background: #fbf8fc;
}

.kskm-team-leave-copy {
    min-width: 0;
}

.kskm-team-leave-copy strong {
    display: block;
    margin-bottom: 3px;
    color: #35143d;
}

.kskm-team-leave-copy p {
    margin: 0;
    color: #6f5c75;
    font-size: 13px;
    line-height: 1.5;
}

.kskm-team-leave-form {
    flex: 0 0 auto;
    margin: 0;
}

.kskm-leave-team-button {
    min-width: 118px;
    white-space: nowrap;
}

@media (max-width: 640px) {
    .kskm-team-leave-zone {
        align-items: stretch;
        flex-direction: column;
    }

    .kskm-team-leave-form,
    .kskm-leave-team-button {
        width: 100%;
    }
}


/* Verze 0.9.14 – vyrovnané platební karty a přejmenování týmu */
.kskm-payment-box .kskm-payment-status-row {
    justify-content: flex-start !important;
    text-align: left !important;
}

.kskm-payment-box .kskm-payment-status-row > span,
.kskm-payment-box .kskm-payment-status-row > strong {
    margin-left: 0 !important;
    margin-right: 0;
}

.kskm-payment-options {
    align-items: stretch;
}

.kskm-payment-options-1 {
    grid-template-columns: minmax(0, 1fr);
}

.kskm-payment-options-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kskm-payment-options > .kskm-payment-option {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    max-width: none;
    height: 100%;
}

.kskm-payment-option .kskm-stripe-payment-form {
    width: 100%;
    margin: 0;
}

.kskm-payment-change-amount .kskm-button {
    margin-top: 0;
}

.kskm-team-rename-details {
    margin-top: 10px;
    max-width: 560px;
}

.kskm-team-rename-details > summary {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 7px 13px;
    border: 1px solid rgba(140, 42, 190, .22);
    border-radius: 999px;
    background: #fff;
    color: var(--kskm-primary-dark);
    cursor: pointer;
    font-size: 13px;
    font-weight: 750;
    line-height: 1.2;
}

.kskm-team-rename-details[open] > summary {
    margin-bottom: 12px;
}

.kskm-team-rename-form {
    margin: 0;
    padding: 14px;
    border: 1px solid rgba(140, 42, 190, .14);
    border-radius: 14px;
    background: #faf7ff;
}

.kskm-team-rename-form > label {
    display: block;
    margin-bottom: 7px;
    font-weight: 700;
}

.kskm-team-rename-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: stretch;
}

.kskm-team-rename-row input[type="text"] {
    width: 100%;
    max-width: none;
    min-width: 0;
}

.kskm-team-rename-row .kskm-button {
    white-space: nowrap;
}

@media (max-width: 720px) {
    .kskm-payment-options-2 {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 560px) {
    .kskm-team-rename-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .kskm-team-rename-row .kskm-button {
        width: 100%;
    }
}

/* Verze 0.9.15 – přímá volba vlastní částky a sjednocená tlačítka */
.kskm .kskm-payment-amount-choices,
.kskm-box .kskm-payment-amount-choices {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
    gap: 10px;
    margin: 14px 0 18px;
    text-align: left;
}

.kskm .kskm-payment-amount-choices .kskm-amount-preset,
.kskm-box .kskm-payment-amount-choices .kskm-amount-preset {
    width: auto;
    min-width: 0;
    margin: 0;
    padding: 12px 20px;
    border: 0;
    border-radius: 999px;
    background: var(--kskm-primary);
    box-shadow: none;
    color: #fff !important;
    font-weight: 700;
    white-space: nowrap;
}

.kskm .kskm-payment-amount-choices .kskm-amount-preset:hover,
.kskm .kskm-payment-amount-choices .kskm-amount-preset:focus,
.kskm-box .kskm-payment-amount-choices .kskm-amount-preset:hover,
.kskm-box .kskm-payment-amount-choices .kskm-amount-preset:focus {
    border: 0;
    background: var(--kskm-primary-dark);
    box-shadow: none;
    color: #fff !important;
    transform: translateY(-1px);
}

.kskm-custom-amount-section {
    width: 100%;
    max-width: 520px;
    margin-top: 4px;
}

.kskm-custom-amount-fields {
    margin: 0;
    padding: 16px;
    border: 1px solid rgba(140, 42, 190, .14);
    border-radius: 14px;
    background: #fff;
}

.kskm-custom-amount-fields > label {
    display: block;
    margin: 0 0 8px;
}

.kskm .kskm-payment-amount-input,
.kskm-box .kskm-payment-amount-input {
    display: grid;
    grid-template-columns: minmax(0, 250px) max-content;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 340px;
    margin-top: 7px;
}

.kskm-number-control {
    position: relative;
    min-width: 0;
}

.kskm .kskm-number-control input[type="number"],
.kskm-box .kskm-number-control input[type="number"] {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding-right: 44px;
    font-size: 1.15em;
    font-weight: 700;
    -moz-appearance: textfield;
    appearance: textfield;
}

.kskm .kskm-number-control input[type="number"]::-webkit-outer-spin-button,
.kskm .kskm-number-control input[type="number"]::-webkit-inner-spin-button,
.kskm-box .kskm-number-control input[type="number"]::-webkit-outer-spin-button,
.kskm-box .kskm-number-control input[type="number"]::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

.kskm-number-stepper {
    position: absolute;
    top: 1px;
    right: 1px;
    bottom: 1px;
    display: grid;
    grid-template-rows: repeat(2, minmax(0, 1fr));
    width: 38px;
    overflow: hidden;
    border-left: 1px solid var(--kskm-border);
    border-radius: 0 9px 9px 0;
    background: #faf5fc;
}

.kskm .kskm-number-step,
.kskm-box .kskm-number-step {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-width: 0;
    min-height: 0;
    margin: 0;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--kskm-primary-dark) !important;
    font-family: Arial, sans-serif;
    font-size: 9px;
    line-height: 1;
    cursor: pointer;
    transform: none !important;
}

.kskm .kskm-number-step + .kskm-number-step,
.kskm-box .kskm-number-step + .kskm-number-step {
    border-top: 1px solid var(--kskm-border) !important;
}

.kskm .kskm-number-step:hover,
.kskm .kskm-number-step:focus-visible,
.kskm-box .kskm-number-step:hover,
.kskm-box .kskm-number-step:focus-visible {
    background: #f1e2f7 !important;
    color: var(--kskm-primary) !important;
}

.kskm-payment-currency {
    display: inline-flex;
    align-items: center;
    align-self: stretch;
    flex: 0 0 auto;
    white-space: nowrap;
    word-break: normal;
    overflow-wrap: normal;
    font-weight: 700;
    line-height: 1;
}

@media (max-width: 640px) {
    .kskm .kskm-payment-amount-choices,
    .kskm-box .kskm-payment-amount-choices {
        display: flex;
        justify-content: flex-start;
    }

    .kskm .kskm-payment-amount-choices .kskm-amount-preset,
    .kskm-box .kskm-payment-amount-choices .kskm-amount-preset {
        width: auto;
    }

    .kskm-custom-amount-section {
        max-width: none;
    }

    .kskm .kskm-payment-amount-input,
    .kskm-box .kskm-payment-amount-input {
        grid-template-columns: minmax(0, 1fr) max-content;
        max-width: none;
    }
}


/* Verze 0.9.17 – zjednodušené potvrzení uhrazené platby v profilu */
.kskm-paid-summary .kskm-paid-summary-line {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 10px 14px;
    margin: 0;
    text-align: left;
}

.kskm-paid-summary .kskm-badge-info {
    flex: 0 0 auto;
}

/* Verze 0.9.20 – postupné AJAXové načítání vlastních zápisů */
.kskm-entry-load-more {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-top: 18px;
}

.kskm-entry-load-more .kskm-button {
    margin: 0;
}

.kskm-entry-load-more .kskm-button[disabled] {
    cursor: wait;
    opacity: .72;
}

.kskm-load-more-status {
    margin: 9px 0 0;
    color: var(--kskm-muted);
    font-size: 14px;
}

.kskm-load-more-status.is-error {
    color: #9d1d1d !important;
}

/* Verze 0.9.23 – dvojice průběhových karet na veřejném dashboardu */
.kskm-dashboard-progress-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    margin-bottom: 22px;
}

.kskm-dashboard-progress-grid .kskm-progress-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    margin-bottom: 0;
}

.kskm-progress-card h3 {
    margin: 4px 0 0;
    font-size: clamp(1.35rem, 2.2vw, 1.8rem);
    line-height: 1.2;
}

.kskm-progress-kicker {
    display: inline-block;
    color: var(--kskm-primary-dark);
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .08em;
    line-height: 1.2;
    text-transform: uppercase;
}

.kskm-progress-card .kskm-progress {
    margin-top: 20px;
}

.kskm-progress-card .kskm-progress-label {
    margin: 12px 0 0;
    line-height: 1.45;
}

.kskm-progress-card .kskm-progress-label strong {
    color: #251229 !important;
    font-size: 1.08em;
}

.kskm-progress-note {
    margin: 10px 0 0;
    color: var(--kskm-muted) !important;
    font-size: .95rem;
    line-height: 1.55;
}

.kskm-progress-card .kskm-actions {
    margin: auto 0 0;
    padding-top: 18px;
}

.kskm-progress-card-amount .kskm-progress span {
    background: linear-gradient(90deg, #8c2abe, var(--kskm-primary));
}

@media (max-width: 760px) {
    .kskm-dashboard-progress-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}
