/* DataCapture-specifikt oven på den fælles ProTechie-stil (style.css fra IntraNET). */
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.sub { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; overflow-wrap: anywhere; }
.num { text-align: right; white-space: nowrap; }
.row-actions { white-space: nowrap; }
tr[data-open] { cursor: pointer; }
tr[data-open]:hover td { background: #f8fafc; }
.stat { text-align: left; color: inherit; font-weight: inherit; }
button.stat { cursor: pointer; }
.toolbar select { max-width: 220px; }
.wide { width: 100%; }
dialog.wide { width: min(980px, calc(100vw - 32px)); }

.dropzone { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 34px 20px; margin-top: 18px; border: 2px dashed var(--line); border-radius: 14px; background: white; color: var(--muted); text-align: center; cursor: pointer; transition: border-color .15s, background .15s; }
.dropzone strong { color: var(--ink); font-size: 16px; }
.dropzone input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.dropzone.over, .dropzone:hover { border-color: var(--primary); background: #f5f8ff; }
.dropzone:focus-within { outline: 2px solid var(--primary); outline-offset: 4px; }

/* Kontrolvisning: PDF til venstre, felter til højre. */
.review { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(320px, 1fr); gap: 20px; align-items: start; margin-top: 18px; }
.pdf-panel { position: sticky; top: 16px; padding: 0; overflow: hidden; }
.pdf-panel iframe { display: block; width: 100%; height: calc(100vh - 210px); min-height: 520px; border: 0; background: #e9edf3; }
/* PDF-visning med markering af felter (pdf.js) */
.pdfv { display: flex; flex-direction: column; }
.pdfv-loading { padding: 16px; margin: 0; }
.pdfv-bar { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 8px 12px; border-bottom: 1px solid var(--line); background: #fff; }
.pdfv-bar button { min-width: 40px; min-height: 40px; padding: 4px 10px; font-size: 18px; line-height: 1; }
.pdfv-bar .pdfv-zoom { font-size: 13px; min-width: 64px; }
.pdfv-page { font-size: 13px; color: var(--muted); min-width: 82px; text-align: center; }
.pdfv-sep { flex: 1 1 8px; }
.pdfv-all { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); min-height: 40px; }
.pdfv-status { padding: 8px 12px; font-size: 13px; color: #94641d; background: #fff8ea; border-bottom: 1px solid var(--line); }
.pdfv-status[hidden] { display: none; }
.pdfv-scroll { height: calc(100vh - 290px); min-height: 440px; overflow: auto; background: #e9edf3; -webkit-overflow-scrolling: touch; }
.pdfv-sheet { position: relative; margin: 0 auto; background: #fff; box-shadow: 0 1px 6px rgba(13, 17, 23, .25); }
.pdfv-sheet canvas { display: block; width: 100%; height: 100%; }
.pdfv-marks { position: absolute; inset: 0; pointer-events: none; }
.pdfv-mark { position: absolute; box-sizing: border-box; min-width: 10px; min-height: 10px; padding: 0; margin: 0; border: 2px solid var(--product); border-radius: 3px; background: rgba(236, 72, 153, .16); pointer-events: auto; cursor: pointer; transform: scale(1.04); }
.pdfv-mark.active { background: rgba(236, 72, 153, .3); border-color: #be185d; box-shadow: 0 0 0 3px rgba(236, 72, 153, .35); z-index: 1; }
.pdfv-tag { position: absolute; left: -2px; bottom: 100%; max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 1px 5px; border-radius: 3px 3px 0 0; background: var(--product); color: var(--product-ink); font-size: 10px; line-height: 14px; pointer-events: none; }
.pdfv-mark.blink { animation: pdfv-blink .5s ease-in-out 4; }
@keyframes pdfv-blink { 50% { background: rgba(250, 204, 21, .75); border-color: #b45309; } }
@media (prefers-reduced-motion: reduce) { .pdfv-mark.blink { animation: none; background: rgba(250, 204, 21, .6); } }
[data-review-field].pdf-active { box-shadow: -4px 0 0 var(--product); }
.pdf-links { padding: 10px 16px; font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); }
.fields-form { padding: 20px; gap: 12px; }
.fields-form label { font-size: 13px; position: relative; }
.conf { position: absolute; top: 0; right: 0; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 999px; }
.conf.high { background: #e7f6ec; color: #17663a; }
.conf.mid { background: #fff4de; color: #8a5300; }
.conf.low { background: #fde8e7; color: #b42318; }

/* Outputkonfigurator: én række pr. kolonne. */
.column-row { display: grid; grid-template-columns: 28px minmax(0, 1fr) minmax(0, 1fr) auto auto; gap: 8px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); }
.column-row:has([data-col=const]) { grid-template-columns: 28px minmax(0, 1fr) minmax(0, 1fr) minmax(0, .8fr) auto auto; }
.column-required { white-space: nowrap; }
.column-required input[type=checkbox] { flex: 0 0 auto; width: 14px; min-width: 14px; }
.column-controls { display: flex; justify-content: flex-end; gap: 2px; }
.required-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 8px; }
.export-problems li { margin-bottom: 12px; }
.bulk-approval, .review-tools { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.bulk-approval > label:not(.check-label), .review-tools > label:not(.check-label) { min-width: 200px; }
.bulk-approval input[type=checkbox], .review-tools input[type=checkbox] { width: 14px; flex: 0 0 auto; }
[data-review-field][hidden] { display: none !important; }
[data-review-field].needs-attention { border-left: 3px solid #d89b26; padding-left: 10px; }
.review-reasons { display: block; color: #94641d; margin-top: 5px; }
.mail-summary { display: block; margin-top: 6px; line-height: 1.5; }
.column-row .handle { color: var(--muted); font-size: 12px; text-align: center; }
.column-row input, .column-row select { margin: 0; }
#preview { white-space: pre-wrap; overflow-wrap: anywhere; }

@media (max-width: 900px) {
  .review { grid-template-columns: 1fr; }
  .pdf-panel { position: static; }
  .pdf-panel iframe { height: 70vh; }
  .pdfv-scroll { height: 70vh; min-height: 360px; }
  .grid3 { grid-template-columns: 1fr; }
  .column-row, .column-row:has([data-col=const]) { grid-template-columns: 24px 1fr 1fr; }
  .column-required { grid-column: 2; }
  .column-controls { grid-column: 3; }
  .column-row [data-col=const] { grid-column: 2 / -1; }
}

.invoice-lines input { min-width: 100px; }
.invoice-lines td:first-child input { min-width: 200px; }
.sidebar nav { overflow-y: auto; min-height: 0; }

/* Første opsætning og licensforbindelse: samme gule disclaimer i alle ProTechie-produkter. */
.setup-notice { background: #fff6e0; border: 1px solid #f0dca8; border-radius: 6px; padding: 12px 16px; color: #16392f; font-size: 13px; line-height: 1.55; text-align: left; flex-basis: 100%; }
.setup-notice p { margin: 6px 0; }
.setup-notice ul { margin: 6px 0; padding-left: 20px; }
.setup-notice li { margin: 4px 0; }

/* Licens: små streg-ikoner (samme sæt som Signage) på menupunktet og licenssidens knapper. */
.svg-icon { flex: none; vertical-align: -3px; }
button .svg-icon, .button-link .svg-icon { margin-right: 6px; }
.license-card h2 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.license-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
details.license-card > summary { cursor: pointer; padding: 16px 20px; font-weight: 600; }
.license-choice { align-items: flex-start; line-height: 1.5; }
.license-choice input { width: 14px; flex: 0 0 auto; margin-top: 3px; }
.license-choice small { display: block; color: var(--muted); }
.license-pay { background: var(--primary); color: #fff; }
.license-card hr { border: 0; border-top: 1px solid var(--line); margin: 18px 0; }
.license-inline input { flex: 1 1 220px; width: auto; margin: 0; }
/* Licenskøb (LICENSKOEB-STANDARD punkt 8): knapper i fuld bredde på små skærme, og intet løber ud over kanten. */
.license-card { overflow-wrap: anywhere; }
.license-card .notice .license-actions { margin-top: 10px; }
@media (max-width: 480px) {
  .license-actions > button, .license-actions > .button-link, .license-actions > a { flex: 1 1 100%; width: 100%; justify-content: center; text-align: center; min-height: 44px; }
  .license-inline input { flex-basis: 100%; }
}

.license-banner { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; border-radius: 0; border-width: 0 0 1px; }
.license-banner span { flex: 1 1 240px; }

/* Knap-ikoner (public/icons.js): lille streg-ikon til venstre for teksten på alle knapper. */
.btn-icon { flex: none; width: 1.15em; height: 1.15em; vertical-align: -0.22em; margin-right: 0.4em; }
button svg, .button-link svg { pointer-events: none; }
.page-heading > button { flex: none; white-space: nowrap; }

/* SaaS: superadmins side Kunder */
.customer-actions { justify-content: flex-start; flex-wrap: wrap; margin-bottom: 12px; }
.detail-row > td { background: var(--canvas, #f6f8fb); padding: 16px 20px; }
.detail-row h3 { margin: 16px 0 8px; font-size: 14px; }
.secondary.danger { color: #b42318; }

/* Markering i menuen, når der er en version, brugeren ikke har set (Nyt i versionen). */
.new-dot { display: inline-block; width: 8px; height: 8px; margin-left: 8px; border-radius: 50%; background: var(--primary, #00e5a0); vertical-align: middle; }

/* Optankning af AI-puljen: den fælles widget (AiCore-JS) arver produktets farver. */
.license-card .ptu { --ptu-accent: var(--primary); --ptu-fg: var(--ink); --ptu-muted: var(--muted); --ptu-bg: #fff; --ptu-border: var(--line); margin-top: 16px; max-width: 560px; }

/* Supportadgang: banner på alle sider under en supportsession (kan ikke lukkes). */
.support-banner { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0; border-radius: 0; font-weight: 600; }
.support-banner button { flex: none; }

/* Bunden af venstremenuen (KONTO-STANDARD afsnit 1): Min profil-kort, Log ud og versionslinjen. */
.profile-card { gap: 10px; padding: 8px 10px; margin: 0 0 4px; }
.profile-card .profile-text { display: grid; min-width: 0; text-align: left; }
.profile-card .profile-text strong { font-size: 13px; color: inherit; }
.profile-card .profile-text small { font-size: 11px; color: #90a2c0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-card.active .profile-text small { color: #c8d4ea; }
.logout-item { padding: 10px 14px; }
.sidebar-bottom { padding-bottom: 14px; }
/* Min profil: én række pr. udbyder under Log ind med Microsoft eller Google. */
.login-row { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line); }
.login-logo { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; flex: none; background: #fff; }
.login-info { display: grid; gap: 2px; flex: 1; min-width: 0; }
.login-info small { color: var(--muted); }
.login-action { flex: none; }
.profile-logins .notice { margin: 12px 0; }
@media (max-width: 640px) { .login-row { flex-wrap: wrap; } .login-action { width: 100%; } .login-action button { width: 100%; } }

/* Techies (AiCore-JS 1.4.0): robot nederst til højre, rundvisning, chat og søgning. */
.ask-techies { margin-left: auto; }
.techies { position: fixed; right: 22px; bottom: 18px; z-index: 1100; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; max-width: calc(100vw - 32px); color: var(--ink); }
.techies[hidden] { display: none !important; }
.techies-launch { position: relative; display: flex; align-items: center; }
/* Udseende (22.11.2026): robot, bobbel og rund × fra AiCore-JS techies-launcher.css; her kun farver og placering. */
.techies .techies-x { position: absolute; right: 0; bottom: calc(100% + 6px); width: 32px; height: 32px; font-size: 18px; }
.techies-fab:focus-visible, .techies-x:focus-visible, .techies-close:focus-visible, .techies-tabs button:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
.techies-x, .techies-close { background: #fff; color: var(--muted); border: 1px solid var(--line); border-radius: 50%; width: 26px; height: 26px; padding: 0; line-height: 1; font-size: 16px; }
/* Panelet (0.16.0, TECHIES-PANEL.md): kortet er en flex-kolonne; samtalen får al resterende højde. Se bunden af filen for svævende, fastgjort og mobil. */
.techies-card { position: relative; display: flex; flex-direction: column; min-height: 0; overflow: hidden; background: #fff; border: 1px solid #b9e7dd; box-shadow: 0 12px 48px #12384a30; padding: 0; }
.techies-tabs { display: flex; gap: 2px; margin: 0; min-width: 0; }
.techies-tabs button { background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: 2px 8px; min-height: 28px; font-size: 12px; white-space: nowrap; }
.techies-tabs button[aria-selected=true] { background: #e6fff8; color: #0b3a33; border-color: #27c9b0; font-weight: 700; }
.techies-body h3 { margin: 4px 0; }
.techies-muted { color: var(--muted); font-size: 13px; }
.techies-status { font-size: 13px; font-weight: 600; }
.techies-status.done { color: #087f70; }
.techies-actions { display: flex; gap: 8px; margin: 12px 0; flex-wrap: wrap; }
.techies-messages { display: grid; gap: 8px; margin: 0 0 8px; }
.techies-message { border-radius: 12px; padding: 8px 12px; background: var(--background); }
.techies-message.assistant { background: #e6fff8; }
.techies-message p { margin: 4px 0 0; white-space: pre-wrap; }
.techies-md p { white-space: normal; }
.techies-md ul, .techies-md ol { margin: 4px 0 0; padding-left: 20px; }
.techies-md li { margin: 2px 0; }
.techies-md blockquote { margin: 4px 0 0; padding-left: 8px; border-left: 3px solid currentColor; opacity: .85; }
.techies-ai { font-size: 12px; color: var(--muted); }
.techies-results ul { margin: 4px 0; padding-left: 18px; }
.techies-search { display: flex; gap: 6px; margin: 8px 0; }
.techies-search input { flex: 1; }
.techies textarea { width: 100%; }
.techies-error:empty { display: none; }
[data-techies].techies-target { outline: 3px solid #27c9b0; outline-offset: 3px; border-radius: 8px; animation: techies-pulse 1.1s ease-in-out 4; }
/* Links fra Techies: det konkrete element rulles frem, får fokus og blinker (techies-open.js). */
.focus-flash { outline: 3px solid #27c9b0; outline-offset: 3px; border-radius: 8px; animation: focus-flash 1.1s ease-in-out 2; scroll-margin: 96px; }
tr.focus-flash { outline-offset: -3px; }
@keyframes focus-flash { 0%, 100% { background-color: transparent; box-shadow: 0 0 0 0 transparent; } 50% { background-color: #e6fff8; box-shadow: 0 0 0 8px #27c9b055; } }
@media (prefers-reduced-motion: reduce) { .focus-flash { animation: none; background-color: #e6fff8; } }
.techies-message { overflow-wrap: anywhere; }
.techies-plan { margin: 8px 0 4px; padding: 8px; border: 1px solid #27c9b0; border-radius: 10px; background: #fff; }
.techies-plan ol { margin: 6px 0; padding-left: 20px; display: grid; gap: 8px; }
.techies-plan .check-label { color: inherit; font-size: 14px; display: flex; gap: 6px; align-items: flex-start; }
.techies-plan .check-label input { margin-top: 3px; flex: none; }
.techies-plan .notice { margin: 6px 0; padding: 6px 10px; font-size: 13px; }
/* Siden selv har kun lys tilstand: blinket bruger lyse farver i begge temaer (kun Techies-kortet skifter til mørk). */
.techies-step.done > label span { color: #087f70; }
.techies-step.failed > label span, .techies-step.blocked > label span { color: #b42318; }
.techies-step-done { color: #087f70; }
.techies-step-failed, .techies-step-blocked { color: #b42318; }
.techies-step button { margin-top: 4px; }
.techies-step ul { margin: 2px 0; padding-left: 16px; }
.techies-settings { margin-top: 12px; }
.techies-actionlist { list-style: none; margin: 6px 0; padding: 0; display: grid; gap: 4px; }
@keyframes techies-pulse { 0%, 100% { box-shadow: 0 0 0 0 transparent; } 50% { box-shadow: 0 0 0 8px #27c9b066; } }
@media (prefers-reduced-motion: reduce) { [data-techies].techies-target { animation: none; } }
@media (prefers-color-scheme: dark) { .techies-card, .techies-x, .techies-close, .techies-tabs button { background: #1b2433; color: #e8eef7; } .techies-message { background: #222c3d; } .techies-message.assistant { background: #123a35; } .techies-tabs button[aria-selected=true] { background: #123a35; color: #e8eef7; border-color: #27c9b0; } }
@media (prefers-color-scheme: dark) { .techies-plan { background: #1b2433; } .techies-step.failed > label span, .techies-step.blocked > label span, .techies-step-failed, .techies-step-blocked { color: #ff9b91; } }
@media (max-width: 700px) { .techies { right: 10px; bottom: 10px; } }

.demo-note { color: var(--muted); font-size: 13px; margin: 6px 0 0; }

/* Brugere: handlinger på rækken (Redigér, Aktivér, Slet) ombrydes på små skærme; dialogens bekræftelsesknap og henvisningen til admin.protechie.dk. */
.user-actions { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; align-items: center; }
.user-actions small { color: var(--muted); }
td:has(> .user-actions) { white-space: normal; min-width: 150px; }
p[data-users-deleted-in-account] { margin: 0; }
p[data-users-deleted-in-account] .button-link { margin-left: 8px; }
/* Mobil: handlingerne på brugerens række (Redigér, Aktivér, Slet) står altid i højre side, også når tabellen ruller vandret. */
@media (max-width: 760px) {
  td:has(> .user-actions) { position: sticky; right: 0; background: #fff; box-shadow: -10px 0 10px -10px rgba(15, 23, 42, 0.25); min-width: 120px; }
}

/* Filer i Techies (0.14.0): slip-zone, chips, papirclips og planens forhåndsvisning. */
.techies-attach { margin: 0 0 8px; }
/* Overlay, mens en FIL trækkes hen over panelet: vejledningen vises kun her (og som title på papirclipsen). */
.techies-drop { position: absolute; inset: 0; z-index: 4; display: grid; place-items: center; text-align: center; padding: 16px; font-weight: 600; background: #e6fffaf2; color: #0b3a33; border: 3px dashed #27c9b0; pointer-events: none; }
.techies-drop span { display: grid; gap: 6px; }
.techies-drop small { font-weight: 400; font-size: 12.5px; color: #3d5a55; }
.techies-chips { list-style: none; margin: 0 0 6px; padding: 0; display: grid; gap: 6px; }
.techies-chip { display: flex; gap: 8px; align-items: center; padding: 4px 6px; border: 1px solid #d4eee8; border-radius: 10px; }
.techies-chip.failed { border-color: #ff9b91; }
.techies-chip img { width: 36px; height: 36px; object-fit: cover; border-radius: 6px; flex: none; }
.techies-chip-icon { font-size: 22px; flex: none; }
.techies-chip-text { display: grid; min-width: 0; flex: 1; }
.techies-chip-text strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.techies-chip-text small { font-size: 12px; opacity: .8; }
.techies-chip-error { color: #b3261e; opacity: 1 !important; }
.techies-chip-x { min-width: 32px; min-height: 32px; padding: 0; background: transparent; color: inherit; border: 0; font-size: 20px; cursor: pointer; }
.techies-clip-wrap { display: inline-flex; }
.techies-preview { margin: 6px 0; padding: 6px 8px; border-left: 3px solid #27c9b0; display: grid; gap: 6px; font-size: 13px; }
.techies-preview p, .techies-preview ul { margin: 2px 0; }
.techies-preview textarea { width: 100%; }
.techies-thumbs { display: flex; gap: 6px; flex-wrap: wrap; }
.techies-thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; border: 1px solid #d4eee8; }
.techies-docs { margin: 4px 0; padding-left: 16px; display: grid; gap: 4px; font-size: 13px; }
.techies-docs small { display: block; }
@media (prefers-color-scheme: dark) { .techies-attach.dragging { background: #123a35; } .techies-chip, .techies-thumb { border-color: #2f4660; } .techies-chip-error { color: #ff9b91; } }

/* ---------- Techies-panelet (0.16.0, TECHIES-PANEL.md): svævende, fastgjort i højre side eller (mobil) et fuldskærmsark ---------- */
.techies.is-open { max-width: none; }
/* Åbent panel: robotknappen er skjult (Luk i panelets top lukker det; Esc også). Er panelet lukket, vises robotknappen og intet skubbes. */
.techies-card.is-floating { position: fixed; right: 12px; bottom: 12px; width: 380px; height: 640px; min-width: 360px; min-height: 420px; max-width: calc(100vw - 24px); max-height: calc(100dvh - 24px); border-radius: 16px; }
.techies-card.is-docked { position: fixed; top: 0; right: 0; bottom: 0; width: 400px; height: auto; border-width: 0 0 0 1px; border-radius: 0; box-shadow: -6px 0 24px #12384a1f; }
.techies-card.is-sheet { position: fixed; inset: 0; width: auto; height: auto; border-width: 0; border-radius: 0; box-shadow: none; }
/* Mobil (højst 900 px): altid et fuldskærmsark, også før koden har målt vinduet. Ingen træk, ingen fastgør og ingen Fuld højde. */
@media (max-width: 900px) {
  .techies-card { position: fixed; inset: 0; width: auto !important; height: auto !important; min-width: 0; min-height: 0; max-width: none; max-height: none; border-width: 0; border-radius: 0; box-shadow: none; }
  .techies-resize, .techies-dock-toggle, .techies-full-height { display: none !important; }
}
/* Fastgjort og åbent: indholdet (og rækker, der blinker efter et Techies-link) skubbes til venstre med panelets bredde (--techies-dock sættes af koden). Kun over 900 px. */
@media (min-width: 901px) {
  html.techies-docked .workspace { margin-right: var(--techies-dock, 0px); }
}
/* Træk-håndtag: svævende øverst, til venstre og i hjørnet; fastgjort i venstre kant. */
.techies-resize { position: absolute; z-index: 3; touch-action: none; }
.techies-resize-top { top: 0; left: 14px; right: 14px; height: 10px; cursor: ns-resize; }
.techies-resize-left { top: 14px; bottom: 0; left: 0; width: 10px; cursor: ew-resize; }
.techies-resize-corner { top: 0; left: 0; width: 16px; height: 16px; cursor: nwse-resize; }
.techies-resize-dock { top: 0; bottom: 0; left: 0; width: 10px; cursor: ew-resize; }
.techies-resize-top::after, .techies-resize-left::after, .techies-resize-dock::after { content: ""; position: absolute; background: #b9e7dd; border-radius: 3px; opacity: .7; transition: opacity .12s; }
.techies-resize-top::after { left: 50%; top: 3px; width: 44px; height: 4px; transform: translateX(-50%); }
.techies-resize-left::after, .techies-resize-dock::after { top: 50%; left: 3px; width: 4px; height: 44px; transform: translateY(-50%); }
.techies-resize:hover::after, .techies-resize:focus-visible::after { opacity: 1; background: #27c9b0; }
.techies-resize:focus-visible { outline: 3px solid var(--primary); outline-offset: -3px; }
/* Kompakt top: én linje med navn, faner og ikonknapper. */
.techies-top { flex: none; display: flex; align-items: center; flex-wrap: wrap; gap: 4px 6px; padding: 8px 6px 6px 12px; border-bottom: 1px solid #d4eee8; }
.techies-name { margin: 0; font-size: 14px; line-height: 1.2; flex: none; display: inline-flex; align-items: center; gap: 8px; }
.techies-robot.techies-robot-head { width: 30px; height: 33px; flex: none; }
/* Robotten i toppen tager plads: fanerne står i egen række under navn og knapper i alle visninger, så intet løber ud over panelet. */
.techies-top .techies-tabs { order: 3; flex: 1 1 100%; flex-wrap: wrap; }
.techies-tools { display: flex; gap: 1px; margin-left: auto; flex: none; }
.techies button.techies-icon-button { width: 28px; min-width: 28px; height: 28px; min-height: 0; padding: 0; display: inline-grid; place-items: center; line-height: 1; border-radius: 8px; border: 1px solid transparent; background: transparent; color: var(--ink); cursor: pointer; }
.techies button.techies-icon-button:hover { background: #e6fff8; }
.techies button.techies-icon-button[aria-pressed="true"] { background: #e6fff8; color: #087f70; }
.techies button.techies-icon-button.techies-close { border-radius: 8px; width: 28px; height: 28px; }
.techies button.techies-icon-button:focus-visible { outline: 3px solid var(--primary); outline-offset: 1px; }
/* Brødtekst: samtalen får al resterende højde; indtastningsfeltet står fast i bunden. */
.techies-body { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.techies-chat { position: relative; flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.techies-scroll { flex: 1 1 auto; min-height: 0; overflow: auto; padding: 10px 14px; overflow-wrap: anywhere; }
.techies-composer { flex: none; padding: 8px 14px 12px; border-top: 1px solid #d4eee8; background: inherit; }
.techies-composer textarea { min-height: 0; resize: none; display: block; width: 100%; }
.techies-composer .techies-actions { margin: 8px 0 0; align-items: center; flex-wrap: nowrap; }
.techies-composer .techies-new { margin-right: auto; min-height: 32px; padding: 4px 10px; font-size: 12.5px; }
.techies-composer .techies-send { min-height: 34px; padding: 4px 16px; }
.techies button.techies-clip { width: 34px; min-width: 34px; height: 34px; border: 1px solid var(--line); }
.techies-composer.is-limit .techies-new { outline: 3px solid #27c9b0; outline-offset: 2px; }
.techies-about { font-size: 13.5px; margin: 0 0 10px; padding: 10px 12px; border-radius: 12px; background: var(--background); border: 1px solid var(--line); }
.techies-about p { margin: 0 0 6px; }
.techies-about > :last-child { margin-bottom: 0; }
.techies-about .techies-demo, .techies-about .techies-settings { margin-top: 8px; }
.techies-message.from-user { background: #e8eef7; }
.techies-message strong { font-size: 12px; color: var(--muted); }
.techies-tab-scroll { flex: 1 1 auto; min-height: 0; overflow: auto; padding: 10px 14px 14px; overflow-wrap: anywhere; }
.techies-demo { margin: 10px 0; padding-top: 8px; border-top: 1px solid var(--line); }
.techies-demo p { margin: 4px 0; }
.techies-critical { margin: 8px 0; padding: 8px 10px; border: 2px solid #b42318; border-radius: 10px; background: #fff4f2; color: #7a1710; }
.techies-critical p { margin: 0 0 6px; font-weight: 600; }
.techies-critical .techies-actions { margin: 6px 0 0; }
.techies-pill { display: inline-block; margin: 0 6px 0 0; padding: 1px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; background: #e6fff8; color: #0b3a33; border: 1px solid #27c9b0; }
.techies-pill.danger { background: #fff4f2; color: #7a1710; border-color: #b42318; }
.techies-input-need { margin: 4px 0; padding: 6px 8px; border-radius: 8px; border: 1px dashed #b42318; font-size: 13px; }
@media (prefers-color-scheme: dark) {
  .techies { color: #e8eef7; }
  .techies-top, .techies-composer { border-color: #2f4660; }
  .techies-composer { background: #1b2433; }
  .techies-about { background: #222c3d; border-color: #2f4660; }
  .techies-message.from-user { background: #2a3a52; }
  .techies button.techies-icon-button { color: #e8eef7; }
  .techies button.techies-icon-button:hover, .techies button.techies-icon-button[aria-pressed="true"] { background: #123a35; color: #e8eef7; }
  .techies-resize-top::after, .techies-resize-left::after, .techies-resize-dock::after { background: #4a6a86; }
  .techies-drop { background: #0f2e2af2; color: #e8eef7; } .techies-drop small { color: #b6d5cf; }
  .techies-critical { background: #3a1814; color: #ffd9d4; border-color: #ff9b91; }
  .techies-pill { background: #123a35; color: #e8eef7; } .techies-pill.danger { background: #3a1814; color: #ffd9d4; border-color: #ff9b91; }
  .techies-input-need { border-color: #ff9b91; }
  .techies .techies-muted, .techies-message strong, .techies-ai { color: #a9b6c9; }
  .techies-card { border-color: #2f4660; } .techies-demo { border-color: #2f4660; }
  .techies textarea, .techies input[type=search] { background: #141b27; color: #e8eef7; border-color: #2f4660; }
  .techies button.secondary, .techies button.ghost { background: #222c3d; color: #e8eef7; border-color: #2f4660; }
  .techies button.techies-icon-button { background: transparent; border-color: transparent; }
  .techies button.techies-icon-button:hover, .techies button.techies-icon-button[aria-pressed="true"] { background: #123a35; }
  .techies-tabs button[aria-selected=true] { background: #123a35; color: #e8eef7; border-color: #27c9b0; }
  .techies button.secondary:hover { background: #2a3a52; }
}

.techies-message { font-size: 14px; }
.techies-tabs button { flex: none; }

/* Mobil: Techies-knappen må aldrig overlappe navigationen (Development#24, 0.16.2). Navigationen har forrang; Techies flyttes.
   Trykfelter mindst 44 x 44 px og mindst 8 px imellem. iOS safe-area kommer via --safe-*, som testen kan overstyre (Chromium emulerer den ikke). */
:root { --safe-top: env(safe-area-inset-top, 0px); --safe-right: env(safe-area-inset-right, 0px); --safe-bottom: env(safe-area-inset-bottom, 0px); --safe-left: env(safe-area-inset-left, 0px); }
@media (max-width: 900px) {
  .techies { right: calc(10px + var(--safe-right)); bottom: calc(10px + var(--safe-bottom)); }
  .techies-fab { min-width: 44px; min-height: 44px; }
  .techies .techies-x { width: 44px; height: 44px; font-size: 20px; bottom: calc(100% + 8px); }
  .ask-techies { min-height: 44px; }
  /* Fanen Notifikationer (0.20.0): panelets faner og værktøjsknapper er mindst 44 x 44 px, og fanerne ombrydes under navnet i stedet for at løbe ud over panelet (fire faner med tal). */
  .techies-top { flex-wrap: wrap; }
  .techies-tabs { order: 3; flex: 1 1 100%; flex-wrap: wrap; gap: 4px; }
  .techies-tabs button { min-height: 44px; min-width: 44px; padding: 2px 12px; }
  .techies button.techies-icon-button, .techies button.techies-icon-button.techies-close { width: 44px; min-width: 44px; height: 44px; }
  /* Åben menu (skuffen): knappen vises ikke, så den ikke dækker menuens nederste punkter (Log ud, Min profil). */
  body:has(.app.menu-open) .techies-launch { visibility: hidden; }
}
@media (max-width: 900px) {
  /* Topbaren (burgermenu og "Spørg Techies") skubbes ned og ind under iOS safe-area, så burgermenuen aldrig står i hak eller kant. */
  .topbar { box-sizing: border-box; height: calc(68px + var(--safe-top)); padding-top: var(--safe-top); padding-left: calc(16px + var(--safe-left)); padding-right: calc(16px + var(--safe-right)); }
}

/* Fanen Notifikationer (0.20.0, AiCore-JS 1.13.0, TECHIES-PANEL.md afsnit 7): kort med et lille kryds (trykfelt 44 x 44 px), Vis fjernede og Hent tilbage, besked med Fortryd og tal på fanen, robotknappen og Spørg Techies. */
.techies-fab { position: relative; }
.techies .techies-fab .techies-badge { position: absolute; top: 0; left: 66px; right: auto; display: inline-flex !important; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 6px; box-sizing: border-box; border-radius: 999px; background: #b4281f; color: #fff; font-size: 12px; font-weight: 800; line-height: 1; border: 2px solid #fff; }
.digest-today h3 { font-size: 17px; line-height: 1.25; margin: 6px 0 10px; }
.digest-today ul { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 8px; }
.techies .digest-item { position: relative; display: grid; gap: 3px; padding: 9px 46px 9px 11px; border: 1px solid #d1ece5; border-radius: 12px; background: #f7fffd; color: #173448; }
.digest-item strong { font-size: 13px; line-height: 1.35; }
.digest-item small { font-size: 12px; }
.techies .digest-item button.digest-x { position: absolute; top: 0; right: 0; width: 44px; height: 44px; min-height: 44px; min-width: 0; margin: 0; padding: 0; display: flex; align-items: center; justify-content: center; border: 0; border-radius: 12px; background: transparent; color: inherit; font-size: 20px; line-height: 1; cursor: pointer; opacity: .7; box-shadow: none; }
.techies .digest-item button.digest-x:hover { opacity: 1; background: #0000000f; }
.techies .digest-item button.digest-x:focus-visible, .techies .digest-toast button:focus-visible { outline: 3px solid #1b6ec2; outline-offset: -3px; opacity: 1; }
.techies .digest-item button:not(.digest-x) { justify-self: start; font-size: 13px; padding: 6px 12px; margin-top: 2px; min-height: 44px; min-width: 44px; }
.techies .digest-removed { opacity: .92; border-style: dashed; }
.techies .digest-removed-box { margin-top: 12px; display: grid; gap: 8px; }
.techies .digest-removed-box > button.digest-removed-toggle, .techies button[data-t=digest-retry] { justify-self: start; min-height: 44px; min-width: 44px; padding: 6px 14px; font-size: 13px; }
.techies .digest-removed-box ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
/* Antallet på "Spørg Techies" i toppen: mærket står i selve knappen (ikke over den), så det aldrig dækker nabo-knapper. */
.ask-techies .techies-badge.ask-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; margin-left: 8px; padding: 0 6px; box-sizing: border-box; border-radius: 999px; background: #b4281f; color: #fff; font-size: 12px; font-weight: 800; line-height: 1; vertical-align: middle; }
/* Læst (AiCore-JS 1.15.0): dæmpet kort med en lille markering; rundvisningens "Gjort – vis ikke igen" og "N trin skjult" */
.techies .digest-item.is-read { opacity: .72; }
.techies .digest-item.is-link { cursor: pointer; }
.techies .digest-item .digest-read { justify-self: start; font-size: 11px; font-weight: 700; color: #4f6272; background: #0000000d; border-radius: 8px; padding: 2px 8px; }
.techies .techies-ignore { display: flex; align-items: center; gap: 8px; margin: 10px 0; font-size: 13px; cursor: pointer; min-height: 44px; }
.techies .techies-ignore input { width: 20px; height: 20px; margin: 0; flex: none; }
.techies .techies-hidden-steps { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; font-size: 12px; }
.techies .techies-hidden-steps button { min-height: 44px; min-width: 44px; padding: 0 10px; font-size: 12px; }
.digest-sev { font-size: 10px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: #4f6272; }
.techies .digest-urgent { border-color: #e4a0a0; background: #fff5f5; color: #601410; }
.digest-urgent .digest-sev { color: #9b1c1c; }
.techies .digest-warn { border-color: #ecd28a; background: #fffaf0; color: #4a3200; }
.digest-warn .digest-sev { color: #8a5a00; }
.techies .digest-toast { position: sticky; bottom: 0; display: flex; align-items: center; gap: 8px; margin-top: 10px; padding: 8px 8px 8px 12px; border-radius: 12px; background: #173448; color: #fff; font-size: 13px; box-shadow: 0 3px 14px #12384a40; }
.techies .digest-toast.is-error { background: #9b1c1c; }
.digest-toast span { flex: 1; }
.techies .digest-toast button { min-height: 44px; min-width: 44px; padding: 0 12px; border: 1px solid #ffffff80; border-radius: 10px; background: transparent; color: #fff; font-size: 13px; font-weight: 700; cursor: pointer; }
.techies .digest-toast button.digest-toast-close { border: 0; font-size: 20px; font-weight: 400; }
@media (prefers-color-scheme: dark) {
  .techies .digest-item { background: #14302d; border-color: #2b5a52; color: #e8eef7; }
  .techies .digest-urgent { background: #3a1a1a; border-color: #8a3a3a; color: #ffd9d4; }
  .techies .digest-warn { background: #3a2f12; border-color: #7a6320; color: #ffe9b0; }
  .digest-sev, .digest-urgent .digest-sev, .digest-warn .digest-sev { color: inherit; opacity: .85; }
  .techies .digest-item .digest-read { color: inherit; background: #ffffff1f; }
  .techies .digest-item button.digest-x:hover { background: #ffffff1f; }
}

/* Flere knapper i sidens overskrift (Brugere): knapperne ombrydes i stedet for at presse introteksten sammen eller løbe ud over skærmen. */
.page-heading:has(> .page-actions) { flex-wrap: wrap; align-items: flex-start; }
.page-heading:has(> .page-actions) > div:first-child { flex: 1 1 320px; min-width: 0; }
.page-heading > .page-actions { flex: 0 1 auto; min-width: 0; max-width: 100%; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-left: auto; }
.page-actions > button { flex: none; white-space: nowrap; max-width: 100%; }
@media (max-width: 700px) { .page-heading > .page-actions { justify-content: flex-start; margin-left: 0; width: 100%; } }

@media (max-width: 900px) { .techies .techies-fab .techies-badge { left: 42px; } }

@media (prefers-color-scheme: dark) { .techies { --techies-bubble-bg: #1b2433; --techies-bubble-fg: #e8eef7; --techies-bubble-border: #34425a; --techies-x-bg: #1b2433; --techies-x-fg: #e8eef7; --techies-x-border: #34425a; } }
