:root {
    --hk-primary: #b3161f;
    --hk-primary-dark: #8a1017;
    --hk-primary-light: #fbe9ea;
    --hk-ink: #1d2327;
    --hk-muted: #646970;
    --hk-bg: #f5f6f8;
    --hk-border: #e2e4e8;
    --hk-radius-sm: 8px;
    --hk-radius: 14px;
    --hk-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}

.hk-kiosk,
.hk-portal {
    margin: 2rem auto;
    padding: clamp(1rem, 4vw, 2.5rem);
    background: #fff;
    border-radius: var(--hk-radius);
    box-shadow: var(--hk-shadow);
    text-align: center;
}

.hk-kiosk { max-width: 1180px; }
.hk-portal { max-width: 1100px; }

.hk-kiosk h2 { font-size: clamp(24px, 4vw, 42px); }

.hk-startpanel { max-width: 560px; margin: 0 auto; text-align: left; }

.hk-scan {
    position: absolute;
    left: -9999px;
}

.hk-result {
    margin: 1rem 0;
    padding: 1rem;
    border-radius: var(--hk-radius);
    font-size: clamp(18px, 2vw, 25px);
}
.hk-result.ok { background: #d8f3dc; color: #14532d; }
.hk-result.bad { background: #fee2e2; color: #7f1d1d; }
.hk-result.warning { background: #fffbeb; color: #856404; }

.hk-manual {
    border-top: 1px solid #ddd;
    padding-top: 1.4rem;
    text-align: left;
}
.hk-searchrow { display: flex; gap: 8px; margin-top: 8px; }
.hk-name { flex: 1; padding: 12px; border: 1px solid #aaa; border-radius: var(--hk-radius-sm); }
.hk-search {
    background: var(--hk-primary);
    color: #fff;
    border: 0;
    border-radius: var(--hk-radius-sm);
    padding: 0 18px;
    cursor: pointer;
}

.hk-results { display: grid; gap: 7px; margin-top: 10px; }
.hk-person {
    display: flex;
    justify-content: space-between;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: var(--hk-radius-sm);
    background: #f7f8f9;
    cursor: pointer;
}

.hk-startpanel h2,
.hk-activebar h2 { margin: .6rem 0 .3rem; }

.hk-status {
    display: inline-flex;
    padding: .35rem .7rem;
    border-radius: 999px;
    font-size: .82rem;
    font-weight: 700;
}
.hk-inactive { background: #f1f1f1; color: #50575e; }
.hk-active { background: #d8f3dc; color: #14532d; }

.hk-startform {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1.25rem;
}
.hk-startform label {
    display: flex;
    flex-direction: column;
    gap: .4rem;
    font-weight: 700;
}
.hk-startform input,
.hk-startform select,
.hk-addrow select {
    width: 100%;
    padding: .75rem;
    border: 1px solid #aeb6bf;
    border-radius: var(--hk-radius-sm);
    background: #fff;
}
.hk-startform .hk-mainbutton { grid-column: 1 / -1; }

.hk-startform-assistants { grid-column: 1 / -1; text-align: left; }
.hk-startform-assistants > span {
    display: block;
    font-weight: 700;
    margin-bottom: .5rem;
}

.hk-checks {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: .5rem;
}
.hk-checks label {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    gap: .5rem;
    padding: .6rem .8rem;
    border: 1px solid #dcdcde;
    border-radius: var(--hk-radius-sm);
    background: #fafafa;
    font-weight: 400;
    cursor: pointer;
}
.hk-checks label span { text-align: left; }
.hk-checks input { width: 16px; height: 16px; }

.hk-mainbutton,
.hk-add-assistant {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 44px;
    padding: .7rem 1.2rem;
    border: 0;
    border-radius: var(--hk-radius-sm);
    background: var(--hk-primary);
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.hk-active-layout {
    display: grid;
    grid-template-columns: minmax(240px, 300px) 1fr;
    gap: 1.5rem;
    text-align: left;
}
.hk-kiosk-sidebar,
.hk-kiosk-main { min-width: 0; }

.hk-activebar {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: .3rem;
    text-align: left;
    padding: 1.1rem;
    border: 1px solid #dcdcde;
    border-radius: var(--hk-radius);
    background: #f7f8f9;
}
.hk-activebar h2 { font-size: clamp(20px, 2.5vw, 26px); }
.hk-activebar-time { color: #50575e; margin: 0 0 .5rem; }
.hk-closebutton {
    margin-top: .4rem;
    padding: .65rem 1rem;
    border: 1px solid #d63638;
    background: #fff;
    color: #b32d2e;
    border-radius: var(--hk-radius-sm);
    font-weight: 700;
    cursor: pointer;
    width: 100%;
}

.hk-trainerbeheer {
    margin: 1.25rem 0 0;
    border: 1px solid #dcdcde;
    border-radius: var(--hk-radius);
    text-align: left;
}
.hk-trainerbeheer summary {
    padding: 1rem;
    cursor: pointer;
    font-weight: 700;
    background: #f7f8f9;
}
.hk-assistants { padding: 1rem; }
.hk-assistant-list { display: grid; gap: .5rem; }
.hk-assistant {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .7rem .85rem;
    border-radius: var(--hk-radius-sm);
    background: #f6f7f7;
}
.hk-remove-assistant,
.hk-remove-attendee {
    border: 0;
    background: transparent;
    color: #b32d2e;
    text-decoration: underline;
    cursor: pointer;
}
.hk-addrow { display: flex; gap: .6rem; margin-top: 1rem; }
.hk-addrow select { flex: 1; }

.hk-actionmessage { margin-top: .8rem; padding: .65rem; border-radius: var(--hk-radius-sm); }
.hk-actionmessage:empty { display: none; }
.hk-actionmessage.ok { background: #d8f3dc; color: #14532d; }
.hk-actionmessage.bad { background: #fee2e2; color: #7f1d1d; }

.hk-register { margin-top: 0; }
.hk-register h3 { font-size: clamp(20px, 3vw, 28px); margin-bottom: .25rem; }

.hk-empty { color: #646970; padding: .5rem 0; }

.hk-attendance {
    margin-top: 1.5rem;
    border-top: 1px solid #ddd;
    padding-top: 1.2rem;
    text-align: left;
}
.hk-attendance h4 { margin: 0 0 .6rem; font-size: 1.05rem; }
.hk-attendance-list {
    display: grid;
    gap: .5rem;
    max-height: 340px;
    overflow-y: auto;
}
.hk-attendee {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .6rem .85rem;
    border-radius: var(--hk-radius-sm);
    background: #f6f7f7;
}
.hk-attendee[data-type="trainer"] { background: #eaf2ff; }
.hk-attendee[data-type="assistant"] { background: #f3f0ff; }

.hk-portal-member {
    text-align: left;
    padding: 1.25rem 0;
    border-top: 1px solid #eee;
}
.hk-portal-member:first-of-type { border-top: 0; padding-top: 0; }
.hk-portal-member h3 { margin: 0 0 1rem; }

.hk-portal-status {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: .75rem;
    margin-bottom: 1.25rem;
}
.hk-status-card {
    display: flex;
    flex-direction: column;
    gap: .2rem;
    padding: .9rem 1rem;
    border-radius: var(--hk-radius);
    background: #f6f7f7;
    border-left: 4px solid #dcdcde;
}
.hk-status-card.ok { background: #d8f3dc; border-left-color: #14532d; }
.hk-status-card.warning { background: #fffbeb; border-left-color: #b45309; }
.hk-status-label { font-size: .78rem; text-transform: uppercase; letter-spacing: .03em; color: #50575e; }
.hk-status-value { font-weight: 700; font-size: 1.05rem; }
.hk-status-meta { font-size: .82rem; color: #50575e; }

.hk-portal-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-top: 1.5rem;
    border-top: 1px solid #ddd;
    padding-top: 1.2rem;
}

.hk-portal-attendance h4,
.hk-portal-competitions h4 { margin: 0 0 .6rem; }
.hk-portal-attendance h4 small,
.hk-portal-competitions h4 small { font-weight: 400; color: #646970; }
.hk-attendance-history {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: .4rem;
}
.hk-attendance-history li {
    padding: .55rem .75rem;
    border-radius: var(--hk-radius-sm);
    background: #f6f7f7;
}

.hk-portal-children {
    text-align: left;
    padding: 1.25rem 0;
    border-top: 1px solid #eee;
}
.hk-portal-children h3 { margin: 0 0 1rem; }
.hk-portal-child {
    border: 1px solid #eee;
    border-radius: var(--hk-radius);
    margin-bottom: .75rem;
    overflow: hidden;
}
.hk-portal-child:last-child { margin-bottom: 0; }
.hk-portal-child summary {
    cursor: pointer;
    list-style: none;
    padding: 1rem 1.1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.hk-portal-child summary::-webkit-details-marker { display: none; }
.hk-portal-child summary::before { content: "▸ "; color: var(--hk-primary); flex-shrink: 0; }
.hk-portal-child[open] summary::before { content: "▾ "; }
.hk-portal-child-name { font-weight: 700; font-size: 1.05rem; flex-shrink: 0; }
.hk-portal-child summary .hk-portal-status {
    margin-bottom: 0;
    flex: 1 1 320px;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}
.hk-portal-child .hk-portal-columns { padding: 0 1.1rem 1.1rem; margin-top: 0; border-top: 1px solid #eee; }

.hk-show-more { margin-top: .5rem; }
.hk-show-more summary {
    cursor: pointer;
    color: var(--hk-primary);
    font-weight: 700;
    font-size: .9rem;
    padding: .3rem 0;
    list-style: none;
}
.hk-show-more summary::-webkit-details-marker { display: none; }
.hk-show-more summary::before { content: "+ "; }
.hk-show-more[open] summary::before { content: "− "; }
.hk-show-more .hk-attendance-history,
.hk-show-more .hk-competition-list { margin-top: .5rem; }
.hk-competition-list { display: grid; gap: .6rem; }
.hk-competition {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: .75rem .9rem;
    border-radius: var(--hk-radius-sm);
    background: #f6f7f7;
    flex-wrap: wrap;
}
.hk-competition-info { display: flex; flex-direction: column; gap: .15rem; }
.hk-competition-info span { color: #50575e; font-size: .88rem; }
.hk-comp-register,
.hk-comp-unregister {
    border: 0;
    border-radius: var(--hk-radius-sm);
    padding: .55rem 1rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}
.hk-comp-register { background: var(--hk-primary); color: #fff; }
.hk-comp-unregister { background: #fff; border: 1px solid #d63638; color: #b32d2e; }
.hk-comp-closed { color: #646970; font-size: .88rem; font-style: italic; }
.hk-comp-status { font-size: .85rem; font-weight: 700; }
.hk-comp-status.pending { color: #996800; }
.hk-comp-status.approved { color: #1e7e34; }
.hk-comp-status.rejected { color: var(--hk-primary); }

.hk-welcome-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(20, 83, 45, .97);
    color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
    animation: hk-fadein .2s ease-out;
}

.hk-chooser-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0, 0, 0, 0.75);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: hk-fadein .2s ease-out;
}

.hk-chooser-box {
    background: #fff;
    color: #1d2327;
    border-radius: var(--hk-radius);
    padding: 1.5rem;
    max-width: 520px;
    width: 100%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    text-align: left;
}

.hk-chooser-box h3 { margin: 0 0 0.25rem; }
.hk-chooser-box p { margin: 0 0 1rem; color: #646970; }

.hk-chooser-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 60vh;
    overflow-y: auto;
    margin-bottom: 1rem;
}

.hk-chooser-list .hk-person {
    width: 100%;
    text-align: left;
}

.hk-chooser-box .hk-secondarybutton {
    display: block;
    width: 100%;
    padding: 0.75rem;
    background: #f0f0f1;
    border: 1px solid #dcdcde;
    border-radius: var(--hk-radius-sm);
    cursor: pointer;
    font-size: 1rem;
}

.hk-chooser-box .hk-secondarybutton:hover {
    background: #e5e5e5;
}
.hk-welcome-overlay.hk-welcome-repeat { background: rgba(133, 100, 4, .96); }
.hk-welcome-name { font-size: clamp(2.2rem, 7vw, 4.5rem); font-weight: 800; line-height: 1.1; }
.hk-welcome-warning {
    font-size: clamp(1.05rem, 2.5vw, 1.4rem);
    background: rgba(255, 255, 255, .18);
    padding: .8rem 1.4rem;
    border-radius: var(--hk-radius);
    max-width: 40rem;
}
.hk-welcome-announcement {
    font-size: clamp(1rem, 2.2vw, 1.25rem);
    font-weight: 600;
    background: rgba(0, 0, 0, .18);
    border: 1px dashed rgba(255, 255, 255, .5);
    padding: .7rem 1.3rem;
    border-radius: var(--hk-radius);
    max-width: 40rem;
}
@keyframes hk-welcome-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@media (max-width: 900px) {
    .hk-active-layout { grid-template-columns: 1fr; }
}

@media (max-width: 800px) {
    .hk-portal-columns { grid-template-columns: 1fr; }
}

/* Notificaties, gezinsoverzicht, mijn inschrijvingen, documenten, gegevens wijzigen (2.18.0) */
.hk-notifications { text-align: left; margin-bottom: 1.25rem; }
.hk-notifications ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.hk-notification {
    padding: .7rem .9rem;
    border-radius: var(--hk-radius-sm);
    border-left: 4px solid #dcdcde;
    background: #f6f7f7;
    font-size: .92rem;
}
.hk-notification.warning { background: #fffbeb; border-left-color: #b45309; }
.hk-notification.info { background: #eaf2ff; border-left-color: var(--hk-primary); }
.hk-notification a { color: inherit; text-decoration: underline; }

.hk-portal-family {
    text-align: left;
    padding: 1.25rem 0;
    border-top: 1px solid #eee;
}
.hk-portal-family h3 { margin: 0 0 1rem; }
.hk-family-grid { display: grid; gap: .75rem; }
.hk-family-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    padding: .8rem 1rem;
    border-radius: var(--hk-radius);
    background: #f6f7f7;
}
.hk-family-name { font-weight: 700; flex-shrink: 0; min-width: 110px; }
a.hk-family-name { color: var(--hk-primary); }
.hk-family-row .hk-portal-status { margin-bottom: 0; flex: 1 1 320px; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.hk-family-alert {
    background: #b45309;
    color: #fff;
    font-size: .78rem;
    font-weight: 700;
    padding: .25rem .6rem;
    border-radius: 999px;
    white-space: nowrap;
}

.hk-portal-registrations { text-align: left; padding: 1.25rem 0; border-top: 1px solid #eee; }
.hk-portal-registrations h3 { margin: 0 0 1rem; }
.hk-registration-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.hk-registration-list li {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .6rem;
    padding: .65rem .9rem;
    border-radius: var(--hk-radius-sm);
    background: #f6f7f7;
}
.hk-registration-who { color: #50575e; font-size: .88rem; }

.hk-attendance-stats { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .6rem; }
.hk-stat-chip {
    background: #eaf2ff;
    color: var(--hk-primary);
    font-size: .82rem;
    padding: .3rem .7rem;
    border-radius: 999px;
}

.hk-portal-documents { text-align: left; margin: 1.25rem 0; border-top: 1px solid #eee; padding-top: 1.25rem; }
.hk-portal-documents summary { cursor: pointer; font-weight: 700; font-size: 1.1rem; list-style: none; }
.hk-portal-documents summary::-webkit-details-marker { display: none; }
.hk-document-list { list-style: none; margin: .8rem 0 0; padding: 0; display: grid; gap: .5rem; }
.hk-document-list li { padding: .6rem .8rem; border-radius: var(--hk-radius-sm); background: #f6f7f7; display: flex; flex-direction: column; gap: .15rem; }
.hk-document-list a { font-weight: 700; color: var(--hk-primary); }
.hk-document-list span { color: #50575e; font-size: .88rem; }

.hk-portal-changerequest { margin-top: 1rem; }
.hk-portal-changerequest .hk-section { border: 1px solid #eee; border-radius: var(--hk-radius); padding: .3rem 1rem; }
.hk-portal-changerequest summary { cursor: pointer; font-weight: 700; padding: .6rem 0; list-style: none; }
.hk-portal-changerequest summary::-webkit-details-marker { display: none; }
.hk-portal-changerequest .hk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: .75rem;
    margin-bottom: .5rem;
}
.hk-portal-changerequest label { display: flex; flex-direction: column; gap: .25rem; font-size: .88rem; font-weight: 600; }
.hk-portal-changerequest input {
    padding: .55rem .7rem;
    border: 1px solid #dcdcde;
    border-radius: var(--hk-radius-sm);
    font-size: .95rem;
}
.hk-portal-changerequest .hk-actions { padding: .8rem 0; }
.hk-primarybutton {
    background: var(--hk-primary);
    color: #fff;
    border: 0;
    border-radius: var(--hk-radius-sm);
    padding: .6rem 1.1rem;
    font-weight: 700;
    cursor: pointer;
}

@media (max-width: 650px) {
    .hk-startform { grid-template-columns: 1fr; }
    .hk-addrow { flex-direction: column; align-items: stretch; }
    .hk-competition { flex-direction: column; align-items: stretch; }
}
