/* Olesen Oppmøte v3.2.7 */
.olesen-wrap,.olesen-oppmote-container{
    width:min(1400px,calc(100vw - 40px));
    max-width:none;
    margin:0;
    padding:0 20px;
    box-sizing:border-box;
    font-size:14px;
    position:relative;
}
.olesen-wrap h1,.olesen-oppmote-container h1{font-size:28px;line-height:1.2;margin-top:0}
.olesen-wrap h2,.olesen-oppmote-container h2{font-size:22px;line-height:1.25;margin:0 0 12px}
.olesen-grid{display:grid;grid-template-columns:minmax(220px,280px) minmax(0,1fr);gap:20px;align-items:start;width:100%;max-width:100%;box-sizing:border-box}
.olesen-main,.olesen-card,.olesen-sidebar{min-width:0;max-width:100%;box-sizing:border-box}
.olesen-card{background:#fff;border:1px solid #ddd;border-radius:14px;padding:16px;margin-bottom:20px}
.olesen-form-grid{display:grid;gap:12px;min-width:0}
.olesen-form-grid.cols-2{grid-template-columns:minmax(0,1fr) minmax(220px,320px)}
.olesen-form-grid.cols-3{grid-template-columns:minmax(160px,220px) minmax(120px,1fr) minmax(120px,1fr)}
.olesen-tools-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;min-width:0}
.olesen-card input,.olesen-card select,.olesen-card textarea,.olesen-card button{max-width:100%;box-sizing:border-box}
.olesen-card input,.olesen-card select,.olesen-card textarea{width:100%;padding:10px;border:1px solid #ccc;border-radius:8px}
.olesen-course-list{list-style:none;padding:0;margin:0}
.olesen-course-list a{display:block;padding:12px 14px;border-radius:10px;text-decoration:none}
.olesen-course-list a.active{background:#eaf2ff}
.olesen-topbar{display:flex;justify-content:space-between;gap:16px;align-items:flex-start}
.olesen-topbar-actions{white-space:nowrap}
.olesen-notice{padding:12px 14px;border-radius:10px;margin:12px 0}
.olesen-notice.success{background:#e7f6ea;color:#166534}
.olesen-notice.error{background:#fde8e8;color:#b91c1c}
.olesen-table-wrap{width:100%;max-width:100%;overflow-x:auto;overflow-y:visible;box-sizing:border-box;-webkit-overflow-scrolling:touch}
.olesen-table,.attendance-grid{width:max-content;min-width:100%;border-collapse:collapse;table-layout:auto}
.olesen-table th,.olesen-table td,.attendance-grid th,.attendance-grid td{border:1px solid #ddd;padding:8px 10px;background:#fff}
.sticky-col{position:sticky;left:0;z-index:2;background:#fff}
.sticky-col.level-col{left:220px}
.sticky-col.level-col-2{left:320px}
.sticky-head{position:sticky;top:0;z-index:1;background:#fff}
.attendance-grid .left{min-width:220px}
.olesen-attendance-cell{min-width:42px;min-height:36px;border:1px solid #ccc;border-radius:8px;background:#fff;cursor:pointer}
.status-present{background:#d1fae5}
.status-absent{background:#fee2e2}
.status-excused{background:#fef3c7}
.status-empty{background:#fff}
.olesen-grid-actions{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:10px}
.button,.button-primary,.olesen-toggle-button{display:inline-block;padding:8px 12px;border-radius:8px;text-decoration:none;border:1px solid #ccc;background:#fff;cursor:pointer}
.button-primary{background:#1d4ed8;color:#fff;border-color:#1d4ed8}
.olesen-login-card{max-width:460px;margin:40px auto}
.description{font-size:13px;color:#666}
.olesen-collapsible-card{padding:12px 16px}
.olesen-toggle-button{font-weight:600}
.olesen-collapsible-panel{margin-top:12px}
.olesen-legend{display:flex;flex-wrap:wrap;gap:14px;margin:0 0 12px;font-size:13px;color:#555}
.olesen-legend span{display:inline-flex;align-items:center;gap:6px;padding:6px 10px;border:1px solid #e5e7eb;border-radius:999px;background:#fafafa}
.olesen-inline-row{display:flex;gap:8px;align-items:center}
.olesen-row-actions{margin:10px 0 0}
.olesen-schedule-row .olesen-remove-row{white-space:nowrap}

/* JS applies the exact viewport-centering offset because the active theme places
   the shortcode inside an asymmetrical content wrapper. */
.olesen-wrap.olesen-viewport-centered{will-change:transform}

@media (max-width:1100px){
    .olesen-grid,.olesen-form-grid.cols-2,.olesen-form-grid.cols-3,.olesen-tools-grid{grid-template-columns:1fr}
    .sticky-col,.sticky-head{position:static}
    .olesen-inline-row{flex-direction:column;align-items:stretch}
}
@media (max-width:640px){
    .olesen-wrap,.olesen-oppmote-container{width:calc(100vw - 20px);padding:0 10px;font-size:13px}
    .olesen-wrap h1,.olesen-oppmote-container h1{font-size:24px}
    .olesen-wrap h2,.olesen-oppmote-container h2{font-size:20px}
    .olesen-card{padding:12px;border-radius:10px}
}
html,body{overflow-x:hidden}

/* v3.2.7 – calmer course workspace */
.olesen-grid{grid-template-columns:minmax(190px,230px) minmax(0,1fr);gap:16px}
.olesen-sidebar{padding:14px}
.olesen-sidebar h3{font-size:18px;margin:0 0 10px}
.olesen-course-list a{padding:9px 11px;font-size:14px}
.olesen-card{padding:14px;margin-bottom:14px}
.olesen-course-summary{display:flex;align-items:baseline;justify-content:space-between;gap:16px;flex-wrap:wrap;margin-bottom:10px}
.olesen-course-summary h2{margin:0!important;font-size:20px!important}
.olesen-course-summary p{margin:0;color:#667085;font-size:13px}
.olesen-tool-buttons{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}
.olesen-tool-button{font-size:13px;padding:7px 10px}
.olesen-tool-panels{margin-top:10px}
.olesen-tool-panel{border-top:1px solid #e5e7eb;padding-top:12px}
.olesen-tool-panel h3{font-size:16px;margin:0 0 10px}
.olesen-tool-panel .compact{display:grid;gap:8px}
.olesen-grid-actions{gap:6px;margin-bottom:8px}
.olesen-grid-actions .button{padding:6px 9px;font-size:12px}
.olesen-legend{gap:6px;margin-bottom:8px;font-size:11px}
.olesen-legend span{padding:4px 7px}
.attendance-grid th,.attendance-grid td{padding:6px 7px;font-size:12px}
.attendance-grid .left{min-width:180px;width:180px}
.sticky-col.level-col{left:180px;width:72px;min-width:72px}
.sticky-col.level-col-2{left:252px;width:72px;min-width:72px}
.attendance-grid select.olesen-level{min-width:62px;width:62px;padding:5px 3px;font-size:12px}
.attendance-grid .day-col{min-width:72px;text-align:center;line-height:1.25}
.attendance-grid .day-col small{font-size:10px;font-weight:500;white-space:normal}
.olesen-attendance-cell{min-width:34px;width:34px;min-height:32px;height:32px;padding:2px;font-size:14px}
@media(max-width:1100px){.olesen-grid{grid-template-columns:1fr}.olesen-sidebar{padding:12px}.olesen-course-list{display:flex;gap:6px;flex-wrap:wrap}.olesen-course-list li{margin:0}.olesen-course-list a{padding:7px 10px}}
@media(max-width:640px){.olesen-course-summary{display:block}.olesen-course-summary p{margin-top:5px}.olesen-tool-buttons{display:grid;grid-template-columns:1fr}.olesen-tool-button{width:100%}}

/* v3.2.8 – tydelig horisontal navigasjon og roligere oppmøtetabell */
.olesen-attendance-toolbar{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:12px 20px;
    flex-wrap:wrap;
    margin-bottom:10px;
}
.olesen-attendance-toolbar .olesen-grid-actions,
.olesen-attendance-toolbar .olesen-legend{margin:0}
.olesen-legend{justify-content:flex-end}
.olesen-legend span{background:#fff}
.olesen-legend strong{
    width:22px;height:22px;display:inline-flex;align-items:center;justify-content:center;
    border:1px solid #d1d5db;border-radius:6px;font-size:13px;line-height:1
}
.olesen-legend .legend-present strong{background:#d1fae5;border-color:#86efac;color:#166534}
.olesen-legend .legend-absent strong{background:#fee2e2;border-color:#fca5a5;color:#b91c1c}
.olesen-legend .legend-excused strong{background:#fef3c7;border-color:#fbbf24;color:#92400e}
.olesen-legend .legend-empty strong{background:#fff}

.olesen-scroll-help{
    display:flex;align-items:center;justify-content:space-between;gap:14px;
    padding:8px 10px;margin:8px 0 6px;
    border:1px solid #4f7cff;border-radius:8px;
    background:linear-gradient(90deg,#f7faff 0%,#edf4ff 100%);
    color:#1749b1;font-size:12px
}
.olesen-scroll-help-text{display:flex;align-items:center;gap:7px;min-width:0}
.olesen-scroll-help-text>strong:first-child{font-size:19px;line-height:1}
.olesen-scroll-buttons{display:flex;gap:6px;flex:0 0 auto}
.olesen-scroll-button{
    width:32px;height:28px;padding:0;border:1px solid #cbd5e1;border-radius:6px;
    background:#fff;color:#334155;font-size:16px;font-weight:700;cursor:pointer
}
.olesen-scroll-button:hover{background:#eff6ff;border-color:#93c5fd;color:#1d4ed8}
.olesen-scroll-button:active{transform:translateY(1px)}

.olesen-table-wrap{
    border:1px solid #dbe3ee;border-radius:9px;
    scrollbar-width:auto;scrollbar-color:#9ca3af #f1f5f9;
    cursor:grab;outline:none
}
.olesen-table-wrap:focus{box-shadow:0 0 0 2px rgba(59,130,246,.18);border-color:#93c5fd}
.olesen-table-wrap.olesen-dragging{cursor:grabbing;user-select:none}
.olesen-table-wrap::-webkit-scrollbar{height:14px}
.olesen-table-wrap::-webkit-scrollbar-track{background:#f1f5f9;border-radius:999px}
.olesen-table-wrap::-webkit-scrollbar-thumb{background:#9ca3af;border:3px solid #f1f5f9;border-radius:999px}
.olesen-table-wrap::-webkit-scrollbar-thumb:hover{background:#6b7280}

.olesen-scroll-footer{
    display:flex;align-items:center;justify-content:center;gap:18px;
    color:#2563eb;font-size:11px;padding:5px 4px 1px;letter-spacing:.01em
}
.olesen-scroll-footer span{font-size:18px;line-height:1}
.olesen-keyboard-tip{
    margin:8px 0 0;padding:8px 10px;border:1px solid #dbeafe;border-radius:8px;
    background:#eff6ff;color:#1e40af;font-size:11px
}

.attendance-grid thead th{background:#fbfdff}
.attendance-grid tbody tr:nth-child(even) td{background:#fcfcfd}
.attendance-grid tbody tr:hover td{background:#f8fbff}
.attendance-grid tbody tr:hover .sticky-col{background:#f8fbff}

@media(max-width:900px){
    .olesen-attendance-toolbar{align-items:flex-start}
    .olesen-legend{justify-content:flex-start}
}
@media(max-width:640px){
    .olesen-scroll-help{align-items:flex-start}
    .olesen-scroll-help-text{display:block}
    .olesen-scroll-footer{display:none}
}

/* v3.3.0 - Moodle-integrasjon */
.olesen-moodle-login { margin-bottom: 18px; }
.olesen-moodle-login h2 { margin: 0 0 6px; }
.olesen-wp-login-fallback { margin-top: 18px; padding-top: 14px; border-top: 1px solid #d9dee7; }
.olesen-wp-login-fallback summary { cursor: pointer; font-weight: 600; }
.olesen-moodle-course-setup { margin: 12px 0 14px; padding: 12px 14px; border: 1px solid #cfe0ff; background: #f7faff; border-radius: 10px; }
.olesen-moodle-course-setup p { margin-top: 0; }
.olesen-moodle-badge { display: inline-block; margin: 8px 0 12px; padding: 5px 9px; border-radius: 999px; background: #eef5ff; border: 1px solid #cfe0ff; font-size: 12px; }


/* Moodle-deltaker som ikke lenger er aktivt påmeldt beholdes i historikken. */
.olesen-participant-history {
    display: inline-block;
    margin-left: 6px;
    padding: 1px 6px;
    border: 1px solid #c9cdd3;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 600;
    line-height: 1.5;
    color: #646970;
    background: #f6f7f7;
    vertical-align: middle;
}

/* v3.3.5 – varierende øktlengde og kursadministrasjon */
.olesen-form-grid.cols-4{grid-template-columns:minmax(150px,220px) minmax(115px,1fr) minmax(115px,1fr) minmax(135px,190px)}
.olesen-duration-preview{display:inline-flex;align-items:center;min-height:34px;padding:0 10px;border:1px solid #dcdcde;border-radius:6px;background:#f6f7f7;font-weight:600;color:#3c434a;white-space:nowrap}
.olesen-course-management{margin-top:12px;padding-top:12px;border-top:1px solid #e5e7eb}
.olesen-edit-course-panel{margin-top:10px;padding:12px;border:1px solid #dbe3ee;border-radius:9px;background:#fbfdff}
.olesen-inline-form{display:inline-flex;align-items:center;margin:0}
.olesen-danger-button{border-color:#d63638!important;color:#b32d2e!important;background:#fff!important}
.olesen-danger-button:hover{border-color:#b32d2e!important;color:#fff!important;background:#b32d2e!important}
.olesen-delete-note{margin:8px 0 0}
.olesen-archived-courses{margin-top:14px;padding-top:10px;border-top:1px solid #e5e7eb}
.olesen-archived-courses summary{cursor:pointer;font-weight:600;color:#646970}
.olesen-course-list.archived{margin-top:8px}
.olesen-archived-course-item{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 0;color:#646970}
@media(max-width:1100px){.olesen-form-grid.cols-4{grid-template-columns:1fr 1fr}}
@media(max-width:640px){.olesen-form-grid.cols-4{grid-template-columns:1fr}.olesen-course-management .olesen-tool-buttons{display:grid;grid-template-columns:1fr}.olesen-inline-form{display:block}.olesen-inline-form .button{width:100%}}

/* v3.3.8 – oppmøteprosent */
.sticky-col.attendance-rate-col{left:324px;width:78px;min-width:78px;text-align:center;z-index:2}
.olesen-attendance-rate{display:inline-flex;align-items:center;justify-content:center;min-width:54px;padding:5px 8px;border:1px solid #d8e3f3;border-radius:999px;background:#f5f9ff;font-weight:700;font-size:11px;white-space:nowrap;color:#2454a6}
@media (max-width:900px){.sticky-col.attendance-rate-col{position:static;left:auto}}

/* v3.3.9 – eksport */
.olesen-export-button {
    white-space: nowrap;
}


/* v3.3.10 – redigering av enkelte kursdager */
.olesen-edit-days-panel {
    margin-top: 12px;
}
.olesen-edit-days-list {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}
.olesen-edit-day-row {
    display: grid;
    grid-template-columns: minmax(150px, 1.2fr) minmax(135px, .9fr) minmax(105px, .65fr) minmax(105px, .65fr) minmax(170px, 1.2fr) auto;
    gap: 10px;
    align-items: end;
    padding: 10px 12px;
    border: 1px solid #dcdcde;
    border-radius: 8px;
    background: #fff;
}
.olesen-edit-day-row label {
    margin: 0;
    font-size: 13px;
}
.olesen-edit-day-row input {
    width: 100%;
    min-width: 0;
}
.olesen-edit-day-type {
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-self: center;
}
.olesen-edit-day-type small {
    color: #646970;
    font-size: 11px;
}
.olesen-edit-day-action {
    align-self: end;
}
@media (max-width: 1050px) {
    .olesen-edit-day-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .olesen-edit-day-type,
    .olesen-edit-day-action {
        grid-column: 1 / -1;
    }
}
@media (max-width: 620px) {
    .olesen-edit-day-row {
        grid-template-columns: 1fr;
    }
    .olesen-edit-day-type,
    .olesen-edit-day-action {
        grid-column: auto;
    }
}


/* v3.3.11 – tydelig historikkmerking og norsk kursdagvisning */
.attendance-grid tbody tr.olesen-history-row > td {
    background: #f4f4f4;
    opacity: .82;
}
.attendance-grid tbody tr.olesen-history-row > td.sticky-col {
    background: #f4f4f4;
}
.olesen-participant-history {
    display: inline-block;
    margin-left: 6px;
    padding: 2px 6px;
    border: 1px solid #b8b8b8;
    border-radius: 999px;
    background: #ececec;
    color: #555;
    font-size: 10px;
    font-weight: 600;
    line-height: 1.2;
    vertical-align: middle;
    white-space: nowrap;
}
.olesen-edit-day-type strong {
    color: #1d2327;
}


/* v3.3.13 – Moodle- og kalenderstatus på kursnivå */
.olesen-sync-status {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    margin: 8px 0 14px;
    padding: 8px 10px;
    border: 1px solid #dfe5ec;
    border-radius: 9px;
    background: #f8fafc;
}
.olesen-sync-item {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-width: 0;
    color: #50575e;
}
.olesen-sync-item > span:last-child {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.olesen-sync-item strong {
    font-size: 12px;
    line-height: 1.2;
    color: #2c3338;
}
.olesen-sync-item small {
    font-size: 11px;
    line-height: 1.25;
    color: #646970;
}
.olesen-sync-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    flex: 0 0 9px;
    background: #8c8f94;
}
.olesen-sync-item.is-ok .olesen-sync-dot {
    background: #2e9b50;
    box-shadow: 0 0 0 3px rgba(46,155,80,.12);
}
.olesen-sync-item.is-warning .olesen-sync-dot {
    background: #dba617;
    box-shadow: 0 0 0 3px rgba(219,166,23,.13);
}
.olesen-sync-item.is-muted .olesen-sync-dot {
    background: #8c8f94;
}
@media (max-width: 700px) {
    .olesen-sync-status {
        flex-direction: column;
        align-items: flex-start;
    }
}


/* v3.3.14 – varsel om tidligere kursdager uten oppmøteføring */
.olesen-attendance-warning {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    margin: 10px 0;
    padding: 9px 12px;
    border: 1px solid #e3b341;
    border-radius: 8px;
    background: #fff8e5;
    color: #6d4d00;
    font-size: 12px;
}
.olesen-attendance-warning strong {
    color: #5c4300;
}
.attendance-grid thead th.olesen-missing-day {
    background: #fff2cc !important;
    box-shadow: inset 0 -3px 0 #dba617;
}
.olesen-missing-label {
    display: inline-block;
    margin-top: 3px;
    padding: 1px 5px;
    border-radius: 999px;
    background: #f2c94c;
    color: #5c4300;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.25;
}


/* v3.3.15 – søk i deltakerlisten */
.olesen-participant-search {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 12px;
    margin: 10px 0;
}
.olesen-participant-search > label {
    font-size: 12px;
    font-weight: 700;
    color: #3c434a;
    white-space: nowrap;
}
.olesen-participant-search-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    width: min(520px, 100%);
}
.olesen-participant-search-input {
    flex: 1 1 auto;
    min-width: 150px;
    margin: 0 !important;
}
.olesen-participant-search-count {
    min-width: 90px;
    color: #646970;
    font-size: 11px;
    white-space: nowrap;
    text-align: right;
}
.attendance-grid tbody tr[hidden] {
    display: none !important;
}
@media (max-width: 700px) {
    .olesen-participant-search {
        align-items: stretch;
        flex-direction: column;
    }
    .olesen-participant-search-controls {
        width: 100%;
        flex-wrap: wrap;
    }
    .olesen-participant-search-count {
        width: 100%;
        text-align: left;
    }
}


/* v3.3.16 – kompakt kursoversikt */
.olesen-course-stats {
    display: grid;
    grid-template-columns: repeat(6, minmax(110px, 1fr));
    gap: 8px;
    margin: 10px 0 14px;
}
.olesen-stat-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 64px;
    padding: 8px 10px;
    border: 1px solid #dfe5ec;
    border-radius: 8px;
    background: #fff;
}
.olesen-stat-value {
    color: #1d2327;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.15;
}
.olesen-stat-label {
    margin-top: 3px;
    color: #646970;
    font-size: 10px;
    line-height: 1.25;
}
.olesen-stat-card.is-warning {
    border-color: #e3b341;
    background: #fff8e5;
}
.olesen-stat-card.is-warning .olesen-stat-value,
.olesen-stat-card.is-warning .olesen-stat-label {
    color: #6d4d00;
}
@media (max-width: 1100px) {
    .olesen-course-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
@media (max-width: 650px) {
    .olesen-course-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}


/* v3.3.17 – utskrifts-/PDF-visning */
.olesen-print-heading {
    display: none;
}

@media print {
    @page {
        size: landscape;
        margin: 10mm;
    }

    html,
    body {
        background: #fff !important;
        overflow: visible !important;
    }

    body * {
        visibility: hidden !important;
    }

    .olesen-wrap,
    .olesen-wrap * {
        visibility: visible !important;
    }

    .olesen-wrap {
        position: absolute !important;
        inset: 0 auto auto 0 !important;
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
        transform: none !important;
        font-size: 9pt !important;
    }

    .olesen-topbar,
    .olesen-sidebar,
    .olesen-collapsible-card,
    .olesen-course-summary,
    .olesen-sync-status,
    .olesen-course-stats,
    .olesen-tools-grid,
    .olesen-course-management,
    .olesen-attendance-toolbar,
    .olesen-scroll-help,
    .olesen-participant-search,
    .olesen-attendance-warning,
    .olesen-table-scroll-tip,
    .olesen-main > .olesen-card:first-child {
        display: none !important;
    }

    .olesen-grid,
    .olesen-main,
    .olesen-card {
        display: block !important;
        width: 100% !important;
        max-width: none !important;
        min-width: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        border: 0 !important;
        box-shadow: none !important;
        background: transparent !important;
    }

    .olesen-print-heading {
        display: block !important;
        margin: 0 0 8mm !important;
        padding: 0 0 4mm !important;
        border-bottom: 1px solid #bbb !important;
    }

    .olesen-print-heading h1 {
        margin: 0 0 2mm !important;
        font-size: 16pt !important;
        line-height: 1.2 !important;
    }

    .olesen-print-heading p {
        margin: 1mm 0 !important;
        font-size: 9pt !important;
    }

    .olesen-table-wrap {
        overflow: visible !important;
        width: 100% !important;
        max-width: none !important;
        border: 0 !important;
    }

    .olesen-table,
    .attendance-grid {
        width: 100% !important;
        min-width: 0 !important;
        table-layout: auto !important;
        border-collapse: collapse !important;
        font-size: 7.5pt !important;
    }

    .attendance-grid th,
    .attendance-grid td {
        position: static !important;
        min-width: 0 !important;
        width: auto !important;
        padding: 2mm 1.2mm !important;
        border: 1px solid #aaa !important;
        background: #fff !important;
        color: #000 !important;
        box-shadow: none !important;
        opacity: 1 !important;
        white-space: nowrap !important;
    }

    .attendance-grid th:first-child,
    .attendance-grid td:first-child {
        min-width: 32mm !important;
        white-space: normal !important;
    }

    .attendance-grid select {
        border: 0 !important;
        appearance: none !important;
        -webkit-appearance: none !important;
        background: transparent !important;
        color: #000 !important;
        padding: 0 !important;
        font-size: 7.5pt !important;
    }

    .olesen-attendance-cell {
        min-width: 5mm !important;
        width: 100% !important;
        height: auto !important;
        padding: 0 !important;
        border: 0 !important;
        background: transparent !important;
        color: #000 !important;
        font-size: 9pt !important;
    }

    .olesen-participant-history {
        border: 0 !important;
        background: transparent !important;
        color: #555 !important;
        padding: 0 !important;
    }

    .attendance-grid tbody tr.olesen-history-row > td {
        background: #f2f2f2 !important;
    }

    .olesen-missing-label {
        display: none !important;
    }

    a[href]:after {
        content: none !important;
    }
}


/* v3.3.18 – manuell Moodle-synk fra kursvisningen */
.olesen-sync-now-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px 10px;
    margin: -6px 0 14px;
}
.olesen-sync-now-form small {
    color: #646970;
    font-size: 11px;
}
.olesen-sync-now-button {
    white-space: nowrap;
}
@media (max-width: 650px) {
    .olesen-sync-now-form {
        align-items: flex-start;
        flex-direction: column;
    }
}


/* v3.3.19 – hurtigføring */
.olesen-bulk-attendance {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px 8px;
    margin: 8px 0 10px;
    padding: 8px 10px;
    border: 1px solid #dfe5ec;
    border-radius: 8px;
    background: #f8fafc;
}
.olesen-bulk-attendance label {
    font-size: 12px;
    font-weight: 700;
    color: #3c434a;
}
.olesen-bulk-day {
    min-width: 190px;
    max-width: 310px;
}
.olesen-bulk-result {
    color: #50575e;
    font-size: 11px;
}
@media (max-width: 650px) {
    .olesen-bulk-attendance {
        align-items: stretch;
        flex-direction: column;
    }
    .olesen-bulk-day {
        width: 100%;
        max-width: none;
    }
}


/* v3.3.20 – tydelig lagringsstatus */
.olesen-save-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin: 7px 0 2px;
    min-height: 24px;
    color: #50575e;
    font-size: 11px;
    font-weight: 600;
}
.olesen-save-status-dot {
    width: 9px;
    height: 9px;
    flex: 0 0 9px;
    border-radius: 50%;
    background: #8c8f94;
}
.olesen-save-status.is-saving .olesen-save-status-dot {
    background: #dba617;
    box-shadow: 0 0 0 3px rgba(219,166,23,.13);
}
.olesen-save-status.is-saved .olesen-save-status-dot {
    background: #2e9b50;
    box-shadow: 0 0 0 3px rgba(46,155,80,.12);
}
.olesen-save-status.is-error {
    color: #b32d2e;
}
.olesen-save-status.is-error .olesen-save-status-dot {
    background: #d63638;
    box-shadow: 0 0 0 3px rgba(214,54,56,.12);
}
.olesen-attendance-cell:disabled,
.olesen-level:disabled {
    cursor: wait;
    opacity: .7;
}
@media print {
    .olesen-save-status {
        display: none !important;
    }
}


/* v3.3.21 – ferdig/delvis/mangler per tidligere kursdag */
.attendance-grid thead th.olesen-complete-day {
    background: #edf8f0 !important;
    box-shadow: inset 0 -3px 0 #2e9b50;
}
.attendance-grid thead th.olesen-partial-day {
    background: #fff8e5 !important;
    box-shadow: inset 0 -3px 0 #dba617;
}
.olesen-day-status-label {
    display: inline-block;
    margin-top: 3px;
    padding: 1px 5px;
    border-radius: 999px;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.25;
    white-space: nowrap;
}
.olesen-day-status-label.is-complete {
    background: #d7f0dd;
    color: #176b33;
}
.olesen-day-status-label.is-partial {
    background: #f8dfa0;
    color: #725100;
}
.olesen-day-status-label.is-missing {
    background: #f2c94c;
    color: #5c4300;
}

/* Den eldre v3.3.14-labelen er erstattet av den nye felles statuslabelen. */
.olesen-missing-label {
    display: none !important;
}

@media print {
    .olesen-day-status-label {
        display: none !important;
    }
}


/* v3.3.22 – framdrift i kurstimer */
.olesen-hours-progress {
    margin: 10px 0 12px;
    padding: 10px 12px;
    border: 1px solid #dfe5ec;
    border-radius: 9px;
    background: #f8fafc;
}
.olesen-hours-progress-head,
.olesen-hours-progress-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.olesen-hours-progress-head {
    margin-bottom: 7px;
}
.olesen-hours-progress-head strong {
    color: #2c3338;
    font-size: 12px;
}
.olesen-hours-progress-head span,
.olesen-hours-progress-foot {
    color: #646970;
    font-size: 11px;
}
.olesen-hours-progress-track {
    position: relative;
    width: 100%;
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: #e4e9ef;
}
.olesen-hours-progress-track > span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #2e9b50;
    transition: width .2s ease;
}
.olesen-hours-progress-foot {
    margin-top: 6px;
}
@media (max-width: 650px) {
    .olesen-hours-progress-head,
    .olesen-hours-progress-foot {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
    }
}
@media print {
    .olesen-hours-progress {
        display: none !important;
    }
}


/* v3.3.23 – neste kursdag */
.olesen-next-day {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 8px 0 12px;
    padding: 10px 12px;
    border: 1px solid #dfe5ec;
    border-radius: 9px;
    background: #f8fafc;
}
.olesen-next-day > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.olesen-next-day strong {
    color: #2c3338;
    font-size: 12px;
}
.olesen-next-day span {
    color: #646970;
    font-size: 11px;
}
.olesen-next-day.is-today {
    border-color: #2e9b50;
    background: #edf8f0;
}
.olesen-next-day.is-today strong {
    color: #176b33;
}
.olesen-next-day.is-finished {
    opacity: .85;
}
@media (max-width: 650px) {
    .olesen-next-day {
        align-items: flex-start;
        flex-direction: column;
    }
}
@media print {
    .olesen-next-day {
        display: none !important;
    }
}


/* v3.3.24 – uferdige datoer */
.olesen-filter-unfinished.is-active {
    font-weight: 700;
}
.olesen-unfinished-filter-result {
    display: inline-block;
    margin-left: 8px;
    color: #646970;
    font-size: 11px;
}
.attendance-grid th[hidden],
.attendance-grid td[hidden] {
    display: none !important;
}
@media (max-width: 650px) {
    .olesen-unfinished-filter-result {
        display: block;
        margin: 4px 0 0;
    }
}
@media print {
    .olesen-filter-unfinished,
    .olesen-unfinished-filter-result {
        display: none !important;
    }
}


/* v3.3.25 – oppfølging ved lavt oppmøte */
.olesen-attendance-followup {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 12px;
    margin: 6px 0 10px;
}
.olesen-attendance-followup > label {
    color: #3c434a;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}
.olesen-attendance-followup-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    width: min(520px, 100%);
}
.olesen-attendance-threshold {
    min-width: 120px;
}
.olesen-filter-low-attendance.is-active {
    font-weight: 700;
}
.olesen-attendance-followup-count {
    min-width: 95px;
    color: #646970;
    font-size: 11px;
    white-space: nowrap;
    text-align: right;
}
@media (max-width: 700px) {
    .olesen-attendance-followup {
        align-items: stretch;
        flex-direction: column;
    }
    .olesen-attendance-followup-controls {
        width: 100%;
        flex-wrap: wrap;
    }
    .olesen-attendance-followup-count {
        width: 100%;
        text-align: left;
    }
}
@media print {
    .olesen-attendance-followup {
        display: none !important;
    }
}


/* v3.3.26 – timevektet oppmøte */
.olesen-absence-hours {
    display: block;
    margin-top: 2px;
    color: #646970;
    font-size: 9px;
    font-weight: 400;
    line-height: 1.15;
    white-space: nowrap;
}
.attendance-rate-col > small {
    font-size: 9px;
    font-weight: 400;
}


/* v3.3.27 – sortering av deltakerlisten */
.olesen-participant-sort {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin: 4px 0 10px;
}
.olesen-participant-sort > label {
    color: #3c434a;
    font-size: 12px;
    font-weight: 700;
}
.olesen-participant-sort-select {
    min-width: 190px;
}
@media (max-width: 700px) {
    .olesen-participant-sort {
        align-items: stretch;
        flex-direction: column;
    }
    .olesen-participant-sort-select {
        width: 100%;
    }
}
@media print {
    .olesen-participant-sort {
        display: none !important;
    }
}


/* v3.3.28 – fargekoding av oppmøteprosent */
.olesen-attendance-rate {
    display: inline-block;
    min-width: 46px;
    padding: 2px 6px;
    border-radius: 999px;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
}
.olesen-attendance-rate.is-good {
    background: #d7f0dd;
    color: #176b33;
}
.olesen-attendance-rate.is-watch {
    background: #fff0c2;
    color: #725100;
}
.olesen-attendance-rate.is-low {
    background: #f8d7da;
    color: #9b1c1f;
}
.olesen-attendance-rate.is-neutral {
    background: #eef1f4;
    color: #646970;
}
.olesen-attendance-followup-label {
    display: block;
    margin-top: 2px;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.15;
    white-space: nowrap;
}
.olesen-attendance-followup-label.is-good {
    color: #176b33;
}
.olesen-attendance-followup-label.is-watch {
    color: #725100;
}
.olesen-attendance-followup-label.is-low {
    color: #b32d2e;
}
@media print {
    .olesen-attendance-rate {
        padding: 0 !important;
        background: transparent !important;
        color: #000 !important;
    }
    .olesen-attendance-followup-label {
        display: none !important;
    }
}


/* v3.3.29 – deltakernotater */
.olesen-participant-note-wrap {
    margin-top: 4px;
}
.olesen-participant-note-toggle {
    padding: 0;
    border: 0;
    background: transparent;
    color: #2271b1;
    cursor: pointer;
    font-size: 10px;
    line-height: 1.3;
}
.olesen-participant-note-toggle.has-note {
    font-weight: 700;
}
.olesen-participant-note-panel {
    width: min(280px, 70vw);
    margin-top: 5px;
    padding: 7px;
    border: 1px solid #dfe5ec;
    border-radius: 7px;
    background: #fff;
}
.olesen-participant-note {
    display: block;
    width: 100%;
    min-height: 62px;
    resize: vertical;
    font-size: 11px;
}
.olesen-participant-note-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 5px;
}
.olesen-participant-note-status {
    color: #646970;
    font-size: 10px;
}
@media print {
    .olesen-participant-note-wrap {
        display: none !important;
    }
}


/* v3.3.30 */
.olesen-bulk-absent{white-space:nowrap;}


/* v3.3.31 – tydelig dagens kursdag */
.attendance-grid thead th.olesen-today-day {
    position: sticky;
    outline: 2px solid #2271b1;
    outline-offset: -2px;
    box-shadow: inset 0 -4px 0 #2271b1;
}
.attendance-grid thead th.olesen-today-day::before {
    content: "I dag";
    display: block;
    width: fit-content;
    margin: 0 auto 3px;
    padding: 1px 5px;
    border-radius: 999px;
    background: #2271b1;
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.2;
}
.olesen-go-today {
    white-space: nowrap;
}
@media print {
    .olesen-go-today {
        display: none !important;
    }
    .attendance-grid thead th.olesen-today-day {
        outline: 0 !important;
        box-shadow: none !important;
    }
    .attendance-grid thead th.olesen-today-day::before {
        display: none !important;
    }
}


/* v3.3.32 – angre hurtigføring */
.olesen-bulk-undo {
    white-space: nowrap;
}
.olesen-bulk-undo:not([hidden]) {
    display: inline-flex;
}


/* v3.3.33 – live kursdagstatus */
.attendance-grid thead th.day-col {
    transition: background .15s ease, box-shadow .15s ease;
}
.olesen-attendance-warning {
    transition: opacity .15s ease;
}


/* v3.3.34 – oppmøteregistrering prioritert øverst */
.olesen-course-top-card {
    padding-bottom: 14px;
}
.olesen-attendance-primary-card {
    border: 2px solid #2271b1;
    box-shadow: 0 3px 12px rgba(34,113,177,.10);
}
.olesen-attendance-primary-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}
.olesen-attendance-primary-heading h2 {
    margin: 1px 0 0;
}
.olesen-primary-kicker {
    display: block;
    color: #646970;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.olesen-primary-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 9px;
    border-radius: 999px;
    background: #e6f2fb;
    color: #135e96;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}
.olesen-course-details-card {
    margin-top: 12px;
}
.olesen-create-course-card {
    margin-top: 12px;
}
@media (max-width: 700px) {
    .olesen-attendance-primary-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }
}
@media print {
    .olesen-primary-kicker,
    .olesen-primary-badge,
    .olesen-course-details-card,
    .olesen-create-course-card {
        display: none !important;
    }
    .olesen-attendance-primary-card {
        border: 0 !important;
        box-shadow: none !important;
    }
}


/* v3.3.35 – tydelig valgt kurs ved oppmøteføring */
.olesen-attendance-course-banner {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin: 0 0 14px;
    padding: 11px 13px;
    border: 1px solid #b8d7ee;
    border-left: 4px solid #2271b1;
    border-radius: 8px;
    background: #f0f7fc;
}
.olesen-attendance-course-label {
    color: #50575e;
    font-size: 12px;
    font-weight: 600;
}
.olesen-attendance-course-name {
    color: #0a4b78;
    font-size: 19px;
    line-height: 1.25;
}
.olesen-bulk-course-context {
    display: flex;
    align-items: baseline;
    gap: 5px;
    width: 100%;
    margin-bottom: 5px;
    color: #50575e;
    font-size: 11px;
}
.olesen-bulk-course-context strong {
    color: #0a4b78;
    font-size: 12px;
}
@media (max-width: 700px) {
    .olesen-attendance-course-banner {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
    }
    .olesen-attendance-course-name {
        font-size: 17px;
    }
}
@media print {
    .olesen-attendance-course-banner {
        border: 0 !important;
        padding: 0 0 8px !important;
        background: transparent !important;
    }
    .olesen-attendance-course-label {
        display: none !important;
    }
}


/* v3.3.36 – kursbytte direkte i oppmøteområdet */
.olesen-attendance-course-banner {
    justify-content: space-between;
}
.olesen-attendance-course-current {
    display: flex;
    align-items: baseline;
    gap: 8px;
    min-width: 0;
}
.olesen-attendance-course-switch {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-left: auto;
}
.olesen-attendance-course-switch label {
    color: #50575e;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}
.olesen-attendance-course-switch-select {
    max-width: 260px;
    min-width: 180px;
}
@media (max-width: 800px) {
    .olesen-attendance-course-banner {
        align-items: stretch;
        flex-direction: column;
        gap: 9px;
    }
    .olesen-attendance-course-current {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
    }
    .olesen-attendance-course-switch {
        width: 100%;
        margin-left: 0;
    }
    .olesen-attendance-course-switch-select {
        width: 100%;
        max-width: none;
    }
}
@media print {
    .olesen-attendance-course-switch {
        display: none !important;
    }
}


/* v3.3.37 – kursnavn synlig under oppmøteføring */
.olesen-attendance-course-banner {
    position: sticky;
    top: 8px;
    z-index: 45;
    box-shadow: 0 2px 8px rgba(0,0,0,.07);
}
.admin-bar .olesen-attendance-course-banner {
    top: 40px;
}
.olesen-attendance-sticky-hint {
    display: none;
    color: #646970;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}
.olesen-attendance-course-banner.is-stuck .olesen-attendance-sticky-hint {
    display: inline;
}
@media (max-width: 782px) {
    .admin-bar .olesen-attendance-course-banner {
        top: 54px;
    }
}
@media (max-width: 700px) {
    .olesen-attendance-course-banner {
        top: 4px;
    }
    .admin-bar .olesen-attendance-course-banner {
        top: 50px;
    }
}
@media print {
    .olesen-attendance-course-banner {
        position: static !important;
        box-shadow: none !important;
    }
    .olesen-attendance-sticky-hint {
        display: none !important;
    }
}


/* v3.3.38 – neste uferdige dato */
.olesen-go-next-unfinished {
    white-space: nowrap;
}
.attendance-grid thead th.olesen-day-focus {
    outline: 3px solid #d63638 !important;
    outline-offset: -3px;
    animation: olesen-day-focus-pulse .9s ease-in-out 2;
}
@keyframes olesen-day-focus-pulse {
    0%,100% { box-shadow: inset 0 0 0 0 rgba(214,54,56,.18); }
    50% { box-shadow: inset 0 0 0 999px rgba(214,54,56,.10); }
}
@media print {
    .olesen-go-next-unfinished {
        display: none !important;
    }
}


/* v3.3.39 – dagsoppsummering */
.olesen-day-summary {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    width: 100%;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #e2e8ef;
}
.olesen-day-summary-title {
    width: 100%;
    color: #50575e;
    font-size: 11px;
    font-weight: 700;
}
.olesen-day-summary-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 7px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}
.olesen-day-summary-item strong {
    font-size: 11px;
}
.olesen-day-summary-item.is-present {
    background: #d7f0dd;
    color: #176b33;
}
.olesen-day-summary-item.is-absent {
    background: #f8d7da;
    color: #9b1c1f;
}
.olesen-day-summary-item.is-excused {
    background: #fff0c2;
    color: #725100;
}
.olesen-day-summary-item.is-empty {
    background: #eef1f4;
    color: #50575e;
}
@media print {
    .olesen-day-summary {
        display: none !important;
    }
}


/* v3.3.40 – filter for ikke registrerte */
.olesen-filter-unregistered-day {
    margin-left: auto;
    white-space: nowrap;
}
.olesen-filter-unregistered-day.is-active {
    font-weight: 700;
}
@media (max-width: 700px) {
    .olesen-filter-unregistered-day {
        width: 100%;
        margin-left: 0;
    }
}
@media print {
    .olesen-filter-unregistered-day {
        display: none !important;
    }
}


/* v3.3.41 – fokusmodus for valgt dato */
.olesen-focus-selected-day {
    white-space: nowrap;
}
.olesen-focus-selected-day.is-active {
    font-weight: 700;
}
.olesen-day-focus-mode .olesen-table-wrap {
    border-color: #2271b1;
    box-shadow: inset 0 0 0 1px rgba(34,113,177,.18);
}
.olesen-day-focus-mode .attendance-grid thead th[data-course-day-id]:not([hidden]) {
    min-width: 120px;
}
@media (max-width: 700px) {
    .olesen-focus-selected-day {
        width: 100%;
    }
}
@media print {
    .olesen-focus-selected-day {
        display: none !important;
    }
}


/* v3.3.42 – framdrift for valgt kursdag */
.olesen-day-progress {
    width: 100%;
    margin: 2px 0 4px;
    padding: 7px 9px;
    border: 1px solid #dfe5ec;
    border-radius: 7px;
    background: #fff;
}
.olesen-day-progress-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 5px;
    color: #3c434a;
    font-size: 11px;
}
.olesen-day-progress-percent {
    font-weight: 700;
    white-space: nowrap;
}
.olesen-day-progress-track {
    width: 100%;
    height: 7px;
    overflow: hidden;
    border-radius: 999px;
    background: #e9edf1;
}
.olesen-day-progress-bar {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #2271b1;
    transition: width .2s ease;
}
.olesen-day-summary.is-complete .olesen-day-progress {
    border-color: #9fd5ad;
    background: #f3fbf5;
}
.olesen-day-summary.is-complete .olesen-day-progress-bar {
    background: #218739;
}
.olesen-day-summary.is-complete .olesen-day-progress-text,
.olesen-day-summary.is-complete .olesen-day-progress-percent {
    color: #176b33;
}
@media print {
    .olesen-day-progress {
        display: none !important;
    }
}


/* v3.3.43 – start dagens oppmøte */
.olesen-attendance-primary-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.olesen-start-today-attendance {
    white-space: nowrap;
    font-weight: 700;
}
@media (max-width: 700px) {
    .olesen-attendance-primary-actions {
        width: 100%;
        align-items: stretch;
        flex-direction: column;
    }
    .olesen-start-today-attendance {
        width: 100%;
    }
}
@media print {
    .olesen-start-today-attendance {
        display: none !important;
    }
}


/* v3.3.44 – avslutt dagens oppmøte */
.olesen-finish-today-attendance {
    white-space: nowrap;
    font-weight: 700;
}
.olesen-primary-badge.is-complete {
    background: #d7f0dd;
    color: #176b33;
}
@media (max-width: 700px) {
    .olesen-finish-today-attendance {
        width: 100%;
    }
}
@media print {
    .olesen-finish-today-attendance {
        display: none !important;
    }
}


/* v3.3.45 – eksport av valgt kursdag */
.olesen-export-selected-day {
    white-space: nowrap;
}
.olesen-export-selected-day.is-disabled {
    opacity: .55;
    pointer-events: none;
}
@media print {
    .olesen-export-selected-day {
        display: none !important;
    }
}


/* v3.3.46 – gjør oppmøteregistreringen enda tydeligere */
.olesen-attendance-primary-card {
    position: relative;
    border: 2px solid #1d5f95;
    border-radius: 14px;
    background: linear-gradient(180deg, #f7fbfe 0%, #ffffff 120px);
    box-shadow: 0 8px 24px rgba(19, 94, 150, 0.10);
}

.olesen-attendance-primary-card::before {
    content: "Hovedområde";
    position: absolute;
    top: -12px;
    right: 14px;
    z-index: 3;
    padding: 4px 10px;
    border-radius: 999px;
    background: #2271b1;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.olesen-attendance-title-wrap h2 {
    margin: 2px 0 4px;
    color: #0a4b78;
    font-size: 28px;
    line-height: 1.15;
}

.olesen-attendance-lead {
    margin: 0;
    color: #50575e;
    font-size: 13px;
    line-height: 1.45;
}

.olesen-attendance-primary-actions {
    align-items: center;
    flex-wrap: wrap;
}

.olesen-attendance-work-banner {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 14px;
    padding: 12px 14px;
    border: 1px solid #c9deef;
    border-left: 5px solid #2271b1;
    border-radius: 10px;
    background: #eef6fc;
    color: #1f2933;
    font-size: 13px;
    line-height: 1.4;
}

.olesen-attendance-work-banner strong {
    white-space: nowrap;
    color: #0a4b78;
}

.olesen-attendance-grid-shell {
    margin-top: 2px;
    padding: 12px;
    border: 1px solid #d7e5f1;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.7);
}

.olesen-attendance-grid-shell .olesen-table-wrap {
    border: 2px solid #c7dcef;
    border-radius: 10px;
    background: #fff;
}

.olesen-attendance-grid-shell .olesen-bulk-attendance {
    position: sticky;
    top: 72px;
    z-index: 20;
    margin-bottom: 10px;
    padding: 10px 12px;
    border: 1px solid #c7dcef;
    border-radius: 10px;
    background: #f8fbfe;
    box-shadow: 0 2px 10px rgba(34,113,177,.06);
}

.admin-bar .olesen-attendance-grid-shell .olesen-bulk-attendance {
    top: 104px;
}

.olesen-attendance-grid-shell .attendance-grid thead th {
    box-shadow: inset 0 -1px 0 rgba(0,0,0,.04);
}

.olesen-attendance-grid-shell .attendance-grid tbody td.olesen-attendance-cell {
    cursor: pointer;
}

@media (max-width: 900px) {
    .olesen-attendance-title-wrap h2 {
        font-size: 24px;
    }
}

@media (max-width: 700px) {
    .olesen-attendance-primary-card::before {
        top: -11px;
        right: 10px;
    }

    .olesen-attendance-title-wrap h2 {
        font-size: 22px;
    }

    .olesen-attendance-lead {
        font-size: 12px;
    }

    .olesen-attendance-work-banner {
        align-items: flex-start;
        flex-direction: column;
        gap: 3px;
        font-size: 12px;
    }

    .olesen-attendance-grid-shell {
        padding: 8px;
    }

    .olesen-attendance-grid-shell .olesen-bulk-attendance {
        top: 62px;
        padding: 9px 10px;
    }

    .admin-bar .olesen-attendance-grid-shell .olesen-bulk-attendance {
        top: 96px;
    }
}

@media print {
    .olesen-attendance-primary-card::before,
    .olesen-attendance-lead,
    .olesen-attendance-work-banner {
        display: none !important;
    }

    .olesen-attendance-primary-card,
    .olesen-attendance-grid-shell,
    .olesen-attendance-grid-shell .olesen-table-wrap,
    .olesen-attendance-grid-shell .olesen-bulk-attendance {
        border: 0 !important;
        box-shadow: none !important;
        background: transparent !important;
    }

    .olesen-attendance-grid-shell {
        padding: 0 !important;
    }
}


/* v3.3.47 – UI-opprydding */
.olesen-grid-actions-primary {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.olesen-more-options,
.olesen-day-more-options,
.olesen-participant-tools {
    position: relative;
}

.olesen-more-options > summary,
.olesen-day-more-options > summary,
.olesen-participant-tools > summary {
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.olesen-more-options > summary::-webkit-details-marker,
.olesen-day-more-options > summary::-webkit-details-marker,
.olesen-participant-tools > summary::-webkit-details-marker {
    display: none;
}

.olesen-more-options > summary {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    border: 1px solid #c3c4c7;
    border-radius: 4px;
    background: #fff;
    color: #2c3338;
    font-size: 12px;
    line-height: 2.3;
}

.olesen-more-options > summary::after,
.olesen-day-more-options > summary::after,
.olesen-participant-tools > summary::after {
    content: "▾";
    margin-left: 6px;
    font-size: 10px;
}

.olesen-more-options[open] > summary::after,
.olesen-day-more-options[open] > summary::after,
.olesen-participant-tools[open] > summary::after {
    content: "▴";
}

.olesen-more-options-panel {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    width: min(520px, 80vw);
    margin-top: 6px;
    padding: 9px;
    border: 1px solid #dcdcde;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 4px 14px rgba(0,0,0,.08);
}

.olesen-day-more-options {
    margin-left: auto;
}

.olesen-day-more-options > summary {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 2px 7px;
    border: 1px solid #c3c4c7;
    border-radius: 4px;
    background: #fff;
    color: #2c3338;
    font-size: 10px;
    font-weight: 600;
}

.olesen-day-more-options-panel {
    margin-top: 5px;
    padding: 7px;
    border: 1px solid #dcdcde;
    border-radius: 7px;
    background: #fff;
}

.olesen-participant-tools {
    margin: 6px 0 10px;
    border: 1px solid #dfe5ec;
    border-radius: 8px;
    background: #fafbfc;
}

.olesen-participant-tools > summary {
    padding: 8px 10px;
    color: #3c434a;
    font-size: 11px;
    font-weight: 700;
}

.olesen-participant-tools-panel {
    padding: 0 10px 10px;
}

.olesen-participant-tools .olesen-attendance-followup,
.olesen-participant-tools .olesen-participant-sort {
    margin-top: 5px;
    margin-bottom: 5px;
}

@media (max-width: 700px) {
    .olesen-grid-actions-primary > .button,
    .olesen-grid-actions-primary > a.button,
    .olesen-more-options,
    .olesen-more-options > summary {
        width: 100%;
    }

    .olesen-more-options-panel {
        width: 100%;
        box-sizing: border-box;
    }

    .olesen-more-options-panel .button,
    .olesen-more-options-panel a.button {
        width: 100%;
        text-align: center;
    }

    .olesen-day-more-options {
        width: 100%;
        margin-left: 0;
    }

    .olesen-day-more-options > summary {
        width: 100%;
        box-sizing: border-box;
    }
}

@media print {
    .olesen-more-options,
    .olesen-day-more-options,
    .olesen-participant-tools {
        display: none !important;
    }
}


/* v3.3.49 – tydelig synkstatus og feil */
.olesen-sync-item.is-error {
    border-color: #e6a7aa;
    background: #fff5f5;
}
.olesen-sync-item.is-error .olesen-sync-dot {
    background: #d63638;
}
.olesen-sync-item.is-error strong,
.olesen-sync-item.is-error small {
    color: #8a1f22;
}
.olesen-sync-alert {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin: 7px 0 8px;
    padding: 8px 10px;
    border: 1px solid #e6a7aa;
    border-left: 4px solid #d63638;
    border-radius: 7px;
    background: #fff7f7;
    color: #6f1d1f;
    font-size: 11px;
    line-height: 1.35;
}
.olesen-sync-alert strong {
    white-space: nowrap;
}
@media (max-width: 700px) {
    .olesen-sync-alert {
        flex-direction: column;
        gap: 2px;
    }
}
@media print {
    .olesen-sync-alert {
        display: none !important;
    }
}
