/* FORMA – farver: sand, sort og værktøjsturkis. Skrift: Jost. */
:root {
  --sand: #F3F1EC; --sand-2: #ECE9E2; --card: #FFFFFF; --ink: #1A1D1B; --ink-2: #2B302D;
  --muted: #5F6661; --line: #E2DFD8; --line-2: #EEEBE5; --chip: #F6F4EF;
  --teal: #007A8A; --teal-d: #005F6B; --teal-l: #2EC4D3; --teal-tint: #E3F3F5; --teal-ink: #032A30;
  --warn-bg: #E5E1D8; --warn-line: #D6D0C4;
  --over: #1A1D1B; --full: #4A514C;
    --r: 18px; --r-lg: 24px;
  --shadow: 0 1px 2px rgba(26,29,27,.06), 0 8px 24px rgba(26,29,27,.06);
  --font: 'Jost', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--sand); color: var(--ink); font: 400 16px/1.45 var(--font); font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; }
body.has-overlay { overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .45; cursor: not-allowed; }
:focus-visible { outline: 3px solid var(--teal-l); outline-offset: 2px; }
h1, h2, h3 { margin: 0; letter-spacing: -.02em; line-height: 1.1; }
h1 { font-size: 34px; font-weight: 700; }
h2 { font-size: 20px; font-weight: 600; }
small { font-size: 13px; }
.muted { color: var(--muted); }
.help { color: var(--muted); font-size: 14px; margin: 8px 0; }
.help.warn { color: var(--ink); font-weight: 500; }
.eyebrow { display: block; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ic { width: 20px; height: 20px; flex: none; }

/* ---------- Logo (pladsholder til det endelige) ---------- */
.logo { font-weight: 700; font-size: 26px; letter-spacing: -.04em; color: var(--ink); }
.logo::after { content: '.'; color: var(--teal-l); }
.logo.on-dark { color: #fff; }

/* ---------- Knapper ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 46px; padding: 0 18px; border-radius: 12px; border: 1px solid transparent; background: var(--card); font-weight: 600; font-size: 15px; text-decoration: none; color: var(--ink); white-space: nowrap; }
.btn.primary { background: var(--teal); color: #fff; }
.btn.primary:hover { background: var(--teal-d); }
.btn.accent { background: var(--teal); color: #fff; }
.btn.ghost { border-color: var(--line); background: var(--card); }
.btn.ghost:hover { border-color: #CBC6BB; }
.btn.outline { border-color: var(--ink); background: transparent; }
.btn.small { height: 34px; padding: 0 12px; font-size: 13px; border-radius: 9px; }
.btn.big { height: 56px; font-size: 16px; border-radius: 16px; width: 100%; }
.btn.stack { flex-direction: column; align-items: flex-start; height: auto; min-height: 64px; padding: 10px 18px; gap: 2px; text-align: left; }
.btn.stack small { font-weight: 400; opacity: .9; white-space: normal; }
.btn.danger { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.btn .ic { width: 18px; height: 18px; }
.iconbtn { width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); display: inline-grid; place-items: center; color: var(--ink); flex: none; }
.iconbtn.small { width: 34px; height: 34px; border-radius: 9px; }
.iconbtn.small .ic { width: 16px; height: 16px; }
.iconbtn.on-dark { background: transparent; border-color: #3A403C; color: #fff; }
.linkbtn { border: 0; background: none; color: var(--teal-d); font-weight: 600; padding: 6px 0; display: inline-flex; gap: 6px; align-items: center; font-size: 14px; }
.linkbtn.danger { color: var(--ink); margin-top: 14px; text-decoration: underline; text-underline-offset: 3px; }
.btnrow { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Mærkater ---------- */
.tagrow:empty { display: none; }
.tagrow { display: inline-flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 6px; background: var(--sand-2); color: var(--ink-2); white-space: nowrap; }
.tag .ic { width: 13px; height: 13px; }
.tag.amber { background: var(--warn-bg); color: var(--ink); }
.tag.red { background: var(--ink); color: #fff; }
.tag.teal { background: var(--teal-tint); color: var(--teal-d); }
.tag.blue { background: transparent; color: var(--teal-d); box-shadow: inset 0 0 0 1px var(--teal); }
.badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; margin-left: 6px; border-radius: 10px; background: var(--teal-l); color: var(--teal-ink); font-size: 12px; font-weight: 700; }
.avatar { width: var(--s); height: var(--s); border-radius: calc(var(--s) * .3); background: var(--c); color: #fff; display: inline-grid; place-items: center; font-weight: 600; font-size: calc(var(--s) * .38); flex: none; letter-spacing: .02em; line-height: 1; }

/* ---------- Mester: ramme ---------- */
.topbar { background: var(--ink); color: #fff; position: sticky; top: 0; z-index: 20; }
.topbar-inner { max-width: 1480px; margin: 0 auto; display: flex; align-items: center; gap: 22px; padding: 12px 28px; }
.mainnav { display: flex; gap: 2px; }
.navbtn { border: 0; background: transparent; color: #C9CCC9; padding: 10px 14px; border-radius: 10px; font-weight: 500; font-size: 15px; display: inline-flex; align-items: center; }
.navbtn:hover { color: #fff; background: #2A2F2C; }
.navbtn.on { background: #2F3431; color: #fff; }
.quickadd { flex: 1; display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 14px; border-radius: 12px; background: #262A28; border: 1px solid #3A403C; color: #A9AFAB; min-width: 220px; }
.quickadd:focus-within { border-color: var(--teal-l); }
.quickadd input { flex: 1; border: 0; background: transparent; color: #fff; outline: none; font-size: 15px; min-width: 0; }
.quickadd input::placeholder { color: #8F9692; }
.quickadd kbd { font: 500 12px var(--font); border: 1px solid #3A403C; border-radius: 6px; padding: 2px 6px; }
.whoami { display: flex; align-items: center; gap: 10px; border: 0; background: transparent; color: #fff; font-weight: 500; padding: 4px 6px; border-radius: 10px; }
.whoami:hover { background: #2A2F2C; }
.mester { max-width: 1480px; margin: 0 auto; padding: 24px 28px 64px; }
.bottomnav { display: none; }

/* Kræver handling */
.attention { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; background: var(--ink); border-radius: var(--r); padding: 12px 16px; margin-bottom: 20px; color: #E8EAE8; }
.attention strong { color: #fff; }
.attention .btn.accent { background: var(--teal-l); color: var(--teal-ink); }
.att-item { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; flex-wrap: wrap; }
.muted-dark { color: #B8BDB9; }

.planhead, .pagehead { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.weeknav { display: flex; gap: 8px; align-items: center; }
.planbody { display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap; }

/* Tavlen */
.board { flex: 1 1 260px; max-width: 320px; display: flex; flex-direction: column; gap: 10px; min-height: 200px; border-radius: var(--r-lg); padding: 2px; transition: background .15s; }
.board.drop-on { background: var(--teal-tint); }
.board-head { display: flex; justify-content: space-between; align-items: baseline; padding: 0 4px 2px; gap: 8px; }
.board-head h2 { font-size: 17px; font-weight: 600; }
.board-head .muted { font-size: 13px; }
.bcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; cursor: default; }
.bcard:hover { border-color: #CBC6BB; box-shadow: var(--shadow); }
.bcard-main { border: 0; background: none; padding: 0; text-align: left; display: flex; flex-direction: column; gap: 2px; cursor: default; }
.bcard-main:hover b { color: var(--teal-d); }
.bcard .row-between > .btn { margin-left: auto; }
.bcard-main b { font-weight: 600; font-size: 15px; }
.bcard-main small { color: var(--muted); }
.dragging { opacity: .5; }
.empty { border: 1.5px dashed var(--line); border-radius: var(--r); padding: 22px; text-align: center; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 8px; }
.empty .ic { width: 28px; height: 28px; color: var(--teal); }
.empty p { margin: 0; }
.empty.wide { padding: 48px; }

/* Ugeplan */
.week { flex: 999 1 720px; min-width: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.week-scroll { overflow-x: auto; }
.week-grid { display: grid; grid-template-columns: 210px repeat(var(--cols), minmax(132px, 1fr)); min-width: 860px; }
.wh { padding: 12px; border-left: 1px solid var(--line-2); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 1px; }
.wh span { font-size: 12px; font-weight: 600; letter-spacing: .1em; color: var(--muted); }
.wh b { font-weight: 600; font-size: 15px; }
.wh.first { border-left: 0; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); justify-content: center; padding-left: 16px; }
.wh.today { background: var(--teal-tint); }
.wh.today span { color: var(--teal-d); }
.wrow-head { border: 0; border-bottom: 1px solid var(--line-2); background: none; text-align: left; padding: 14px 16px; display: flex; gap: 10px; align-items: flex-start; }
.wrow-head:hover { background: #FAF9F6; }
.wrow-head span:not(.avatar) { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.wrow-head b { font-weight: 600; font-size: 15px; }
.wrow-head small { color: var(--muted); }
.wrow-head .free { color: var(--teal-d); font-weight: 600; margin-top: 2px; }
.wcell { border-left: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); padding: 8px; display: flex; flex-direction: column; gap: 5px; min-height: 122px; text-align: left; cursor: default; transition: background .12s; }
.wcell:hover { background: #FAF9F6; }
.wcell.past { background: #FBFAF7; }
.wcell.today { background: #F4FAFB; }
.wcell.today:hover { background: #EDF6F8; }
.wcell.past .chip { opacity: .7; }
.wcell.drop-on { background: var(--teal-tint); box-shadow: inset 0 0 0 2px var(--teal); }
.wcell.off { background: repeating-linear-gradient(135deg, #F1EFEA 0 8px, #ECE9E2 8px 16px); cursor: default; align-items: center; justify-content: center; }
.wcell.off span { font-weight: 600; color: var(--muted); font-size: 14px; }
.chip { display: flex; justify-content: space-between; gap: 6px; font-size: 13px; background: var(--chip); border-radius: 7px; padding: 4px 7px; cursor: default; border: 1px solid transparent; }
.chip:hover { border-color: var(--teal); background: #fff; }
.chip span { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chip small { color: var(--muted); font-size: 12px; }
.chip.hot { box-shadow: inset 3px 0 0 var(--teal); }
.chip.done { text-decoration: line-through; color: var(--muted); }
.more { color: var(--muted); font-size: 12px; }
.cap { margin-top: auto; display: flex; flex-direction: column; gap: 4px; }
.cap small { font-weight: 500; font-size: 12px; color: var(--muted); }
.cap small.full { color: var(--ink); font-weight: 600; }
.cap small.over { color: var(--ink); font-weight: 700; }
.capbar { display: block; height: 6px; border-radius: 3px; background: #ECE9E3; overflow: hidden; }
.capbar > span { display: block; height: 100%; border-radius: 3px; background: var(--teal); }
.capbar > span.full { background: var(--full); }
.capbar > span.over { background: var(--over); }
.capbar.big { height: 10px; border-radius: 5px; margin-top: 18px; }

/* Tabeller og lister */
.toolbar { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.seg { display: inline-flex; background: var(--sand-2); border-radius: 12px; padding: 4px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; padding: 8px 14px; border-radius: 9px; font-weight: 500; font-size: 14px; color: var(--ink-2); }
.seg button.on { background: var(--card); box-shadow: 0 1px 2px rgba(0,0,0,.08); color: var(--ink); font-weight: 600; }
.search { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); flex: 1 1 240px; max-width: 380px; color: var(--muted); }
.search input { border: 0; outline: none; flex: 1; background: transparent; min-width: 0; color: var(--ink); }
.table-wrap { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th { text-align: left; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 12px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.table tr[data-act] { cursor: pointer; }
.table tbody tr:hover { background: #FAF9F6; }
.table b { font-weight: 600; }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.empty-row { text-align: center; color: var(--muted); padding: 40px !important; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.pcard { display: flex; gap: 14px; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; }
.pcard:hover { box-shadow: var(--shadow); }
.pcard span:not(.avatar) { display: flex; flex-direction: column; gap: 2px; }
.pcard b { font-size: 17px; font-weight: 600; }
.pcard small { color: var(--muted); }
.pcard .free { color: var(--teal-d); font-weight: 600; margin-top: 4px; }
.msg { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; margin-bottom: 10px; }
.msg.done { opacity: .6; }
.msg b { font-weight: 600; }
.msg small { display: block; color: var(--muted); }
.msg p { margin: 8px 0 0; }
.msg-tools { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.settings { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 16px; align-items: start; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 22px; }
.card h2 { margin-bottom: 12px; }
.status { font-weight: 500; padding: 10px 12px; border-radius: 10px; background: var(--sand-2); }
.status.ok { background: var(--teal-tint); color: var(--teal-d); }
.status.warn { background: var(--warn-bg); color: var(--ink); }
.section-title { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 20px 0 8px; display: flex; align-items: center; gap: 8px; }

/* ---------- Formularer ---------- */
.form { display: flex; flex-direction: column; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span { font-size: 14px; font-weight: 500; color: var(--ink-2); }
.field input, .field select, .field textarea, .inline-add input, .inline-add select, .newcust input { height: 46px; border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; background: #fff; width: 100%; }
.field textarea { height: auto; padding: 10px 12px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--teal); outline: none; box-shadow: 0 0 0 3px rgba(46,196,211,.25); }
.check { display: flex; gap: 10px; align-items: center; font-size: 15px; }
.check input { width: 20px; height: 20px; accent-color: var(--teal); }
.check.big { font-size: 17px; font-weight: 500; padding: 10px 0; }
.inline-add { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; align-items: center; }
.plainlist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.plainlist li { padding: 8px 0; border-bottom: 1px solid var(--line-2); }
.rowbtn { border: 0; background: none; padding: 0; text-align: left; display: flex; flex-direction: column; gap: 4px; width: 100%; }
.visitlist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.visitlist li { display: flex; gap: 10px; align-items: center; }
.visitlist li > span:not(.avatar) { flex: 1; display: flex; flex-direction: column; }
.visitlist small { color: var(--muted); }

/* ---------- Overlejringer ---------- */
.scrim { position: fixed; inset: 0; background: rgba(26,29,27,.42); z-index: 40; animation: fade .15s ease; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(520px, 100%); background: var(--sand); z-index: 41; overflow-y: auto; box-shadow: -20px 0 60px rgba(0,0,0,.15); animation: slide .18s ease; }
.drawer-head { display: flex; justify-content: space-between; gap: 16px; padding: 22px 24px 16px; background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 2; }
.drawer-head h2 { font-size: 24px; font-weight: 600; }
.drawer-head .tagrow { margin-top: 8px; }
.drawer-head p { margin: 6px 0 0; }
.drawer-body { padding: 20px 24px 40px; }
.drawer-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 8px; }
.route { display: flex; flex-direction: column; margin-top: 12px; border-radius: var(--r); padding: 4px; }
.route.drop-on { background: var(--teal-tint); }
.stop { display: flex; gap: 12px; align-items: flex-start; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; }
.stop.home { background: transparent; border-style: dashed; color: var(--muted); font-size: 14px; align-items: center; padding: 10px 12px; }
.stop .time { font-weight: 600; width: 50px; flex: none; font-size: 16px; }
.stop-main { flex: 1; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.stop-main b { font-weight: 600; }
.stop-main small { color: var(--muted); }
.stop-tools { display: flex; gap: 4px; }
.leg { display: flex; align-items: center; gap: 8px; padding: 8px 4px 8px 22px; font-size: 13px; color: var(--muted); }
.leg .ic { width: 16px; height: 16px; }

.src { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.src .ic { width: 16px; height: 16px; }
.src.ok { color: var(--teal-d); }

.modal-wrap { position: fixed; inset: 0; z-index: 42; display: grid; place-items: start center; padding: 6vh 16px; overflow-y: auto; pointer-events: none; }
.modal { pointer-events: auto; width: 100%; max-width: 680px; background: var(--card); border-radius: 22px; box-shadow: 0 30px 80px rgba(0,0,0,.25); animation: pop .18s ease; }
.modal-head { display: flex; justify-content: space-between; gap: 16px; padding: 22px 26px 16px; border-bottom: 1px solid var(--line-2); }
.modal-head h2 { font-size: 26px; font-weight: 600; }
.modal-head p { margin: 4px 0 0; }
.modal-body { padding: 18px 26px; display: flex; flex-direction: column; gap: 10px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 26px 22px; border-top: 1px solid var(--line-2); flex-wrap: wrap; }
.nowbox { background: var(--chip); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.nowbox small { color: var(--muted); font-weight: 500; }
.nowbox b { font-weight: 600; }
.nowbox .red, .nowbox .amber { color: var(--ink); font-weight: 700; }
.nowbox.to { background: var(--teal-tint); border: 1px solid #B5E0E5; }
.nowbox.to small { color: var(--teal-d); }
.option { display: flex; gap: 14px; align-items: flex-start; border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; cursor: pointer; }
.option.on { border: 2px solid var(--teal); background: #F5FBFC; padding: 13px 15px; }
.option input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--teal); flex: none; }
.option-main { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.option-main b { font-weight: 600; }
.option-main small { color: var(--ink-2); font-size: 14px; }
.option-main small.muted { color: var(--muted); font-size: 12px; }
.plus { font-weight: 600; color: var(--teal-d); white-space: nowrap; }
.smsbox { background: var(--chip); border-radius: var(--r); padding: 14px 16px; margin-top: 6px; }
.smsbox small { color: var(--muted); font-weight: 500; }
.smsbox p { margin: 8px 0 0; }
.spinner { width: 14px; height: 14px; border: 2px solid var(--line); border-top-color: var(--teal); border-radius: 50%; display: inline-block; animation: spin .8s linear infinite; }

.sheet-wrap { position: fixed; inset: auto 0 0 0; z-index: 41; display: flex; justify-content: center; pointer-events: none; }
.sheet { pointer-events: auto; width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto; background: var(--sand); border-radius: 24px 24px 0 0; padding: 20px 16px calc(20px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 14px; box-shadow: 0 -20px 60px rgba(0,0,0,.18); animation: up .2s ease; }
.sheet-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 0 4px; }
.sheet-head h2 { font-size: 28px; font-weight: 700; }
.composer { background: var(--card); border: 2px solid var(--teal); border-radius: 18px; padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.composer label { font-size: 14px; font-weight: 500; color: var(--ink-2); }
.composer textarea { border: 0; outline: none; resize: none; font-size: 19px; line-height: 1.35; background: transparent; padding: 0; }
.mic { width: 52px; height: 52px; border-radius: 26px; border: 0; background: var(--teal); color: #fff; display: grid; place-items: center; flex: none; }
.mic.on { background: var(--ink); animation: pulse 1.2s infinite; }
.faded { opacity: .55; }
.parsed { background: var(--card); border: 1px solid var(--line); border-radius: 16px; display: flex; flex-direction: column; }
.prow { display: grid; grid-template-columns: 82px 1fr auto; gap: 10px; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line-2); min-height: 56px; }
.prow:last-child { border-bottom: 0; }
.prow .k { font-size: 13px; color: var(--muted); }
.prow .v { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.prow .v b { font-weight: 600; }
.prow .v small { color: var(--muted); }
.prow input, .prow select { height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; background: #fff; width: 100%; font-size: 16px; }
.prow input { border-color: transparent; padding: 0; font-weight: 600; }
.prow input:focus { border-color: var(--teal); padding: 0 10px; outline: none; }
.pick { position: relative; font-weight: 600; color: var(--teal-d); padding: 8px 4px; font-size: 15px; }
.pick select { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; cursor: pointer; }
.newcust { padding: 10px 14px; display: flex; flex-direction: column; gap: 8px; background: #FAF9F6; border-bottom: 1px solid var(--line-2); }
.newcust input { height: 42px; }
.sheet-actions { display: flex; flex-direction: column; gap: 8px; }

.menu { position: fixed; top: 64px; right: 16px; z-index: 42; width: min(340px, calc(100vw - 32px)); background: var(--card); border-radius: 18px; box-shadow: 0 20px 60px rgba(0,0,0,.25); padding: 10px; animation: pop .15s ease; }
.menu-head { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding: 8px 10px; }
.menu-item { display: flex; gap: 12px; align-items: center; width: 100%; border: 0; background: none; text-align: left; padding: 10px; border-radius: 12px; }
.menu-item:hover, .menu-item.on { background: var(--sand); }
.menu-item span:not(.avatar) { display: flex; flex-direction: column; }
.menu-item b { font-weight: 600; }
.menu-item small { color: var(--muted); }
.menu-links { display: flex; gap: 16px; padding: 8px 10px; border-top: 1px solid var(--line-2); margin-top: 6px; }
.menu .help { padding: 4px 10px; font-size: 12px; }

.toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 12px; font-weight: 500; z-index: 60; opacity: 0; transition: .2s; pointer-events: none; max-width: calc(100vw - 32px); box-shadow: 0 10px 30px rgba(0,0,0,.25); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.warn { background: var(--ink); box-shadow: 0 0 0 2px var(--teal-l), 0 10px 30px rgba(0,0,0,.25); }

@keyframes fade { from { opacity: 0; } }
@keyframes slide { from { transform: translateX(30px); opacity: 0; } }
@keyframes pop { from { transform: translateY(8px) scale(.98); opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: .5; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 50% { box-shadow: 0 0 0 10px rgba(0,122,138,.2); } }

/* ---------- Montør (mobil først) ---------- */
.phone { max-width: 480px; margin: 0 auto; min-height: 100vh; padding: calc(16px + env(safe-area-inset-top)) 16px 128px; position: relative; }
.m-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 4px 4px 14px; }
.m-date { font-size: 14px; color: var(--muted); font-weight: 500; }
.m-head h1 { font-size: 28px; font-weight: 700; margin-top: 2px; }
.avatarbtn { border: 0; background: none; padding: 0; border-radius: 14px; }
.m-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; background: var(--sand-2); border-radius: 12px; padding: 4px; }
.m-tabs button { height: 42px; border: 0; border-radius: 9px; background: transparent; font-weight: 500; font-size: 16px; color: var(--ink-2); }
.m-tabs button.on { background: var(--card); color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.m-main { padding-top: 14px; }
.m-sum { margin: 0 4px 12px; color: var(--ink-2); font-size: 15px; display: flex; justify-content: space-between; align-items: baseline; gap: 8px 14px; flex-wrap: wrap; }
.m-sum span { white-space: nowrap; }
.m-sum b { font-weight: 600; color: var(--ink); }
.next { background: var(--ink); color: #fff; border-radius: 22px; padding: 20px; display: flex; flex-direction: column; gap: 6px; }
.kicker { font-size: 12px; font-weight: 600; letter-spacing: .14em; color: var(--teal-l); }
.next-leg { font-size: 13px; color: #BFC4C0; }
.next-time { font-size: 48px; font-weight: 600; line-height: 1; letter-spacing: -.02em; margin-top: 6px; }
.next h2 { font-size: 22px; font-weight: 600; margin-top: 6px; }
.next-where { margin: 0; color: #D6D9D6; font-size: 16px; }
.next-note { margin: 8px 0 0; background: #262A28; color: #C9CCC9; border-radius: 12px; padding: 10px 12px; font-size: 15px; }
.next-note.light { background: var(--card); color: var(--ink-2); border: 1px solid var(--line); }
.next-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.next-actions.light { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.nbtn { min-height: 62px; padding: 8px 6px; border: 0; border-radius: 16px; background: #2F3431; color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-weight: 600; font-size: 15px; line-height: 1.15; text-align: center; text-decoration: none; }
.nbtn .ic { width: 22px; height: 22px; }
.nbtn.go { background: var(--teal-l); color: var(--teal-ink); }
.nbtn.disabled { opacity: .5; }
.next-actions.light .nbtn { background: var(--card); color: var(--ink); border: 1px solid var(--line); }
.m-section { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 20px 4px 4px; }
.m-stop { display: flex; gap: 12px; width: 100%; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 14px; align-items: flex-start; }
.m-stop.done { opacity: .6; }
.m-stop .time, .m-row .time { font-weight: 600; font-size: 17px; width: 50px; flex: none; }
.m-stop-main { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.m-stop-main b { font-weight: 600; font-size: 17px; }
.m-stop-main small { color: var(--muted); font-size: 15px; }
.m-foot { margin: 18px 4px; }
.m-empty { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 28px 22px; text-align: center; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.m-empty.small { padding: 22px; }
.m-empty h2 { font-size: 22px; }
.m-empty p { margin: 0; color: var(--ink-2); }
.m-weeknav { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.m-weeknav b { font-weight: 600; font-size: 17px; }
.m-day { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 6px 0; margin-bottom: 10px; }
.m-day.today { border: 2px solid var(--teal); }
.m-day.past { opacity: .7; }
.m-day-head { display: flex; justify-content: space-between; align-items: baseline; padding: 10px 16px; gap: 10px; }
.m-day-head b { font-weight: 600; font-size: 17px; }
.m-day-head small { color: var(--muted); }
.m-row { display: flex; gap: 12px; width: 100%; text-align: left; border: 0; border-top: 1px solid var(--line-2); background: none; padding: 12px 16px; align-items: flex-start; }
.m-row span:last-child { display: flex; flex-direction: column; }
.m-row b { font-weight: 600; }
.m-row small { color: var(--muted); font-size: 14px; }
.mgrid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; margin-bottom: 14px; }
.mh { text-align: center; font-size: 12px; font-weight: 600; color: var(--muted); padding: 4px 0; }
.mc { aspect-ratio: 1; border: 0; border-radius: 12px; background: var(--card); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-weight: 500; font-size: 16px; }
.mc.out { background: transparent; color: #A9AEA9; }
.mc.today { box-shadow: inset 0 0 0 2px var(--teal); }
.mc.sel { background: var(--ink); color: #fff; }
.mc i { display: flex; gap: 2px; height: 6px; }
.mc i b { width: 5px; height: 5px; border-radius: 50%; background: var(--teal); }
.mc.sel i b { background: var(--teal-l); }
.mc i.off { width: 14px; height: 4px; border-radius: 2px; background: #C9C4B8; }
.m-cust { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.m-cust b { font-weight: 600; font-size: 17px; }
.fab { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(18px + env(safe-area-inset-bottom)); width: min(448px, calc(100vw - 32px)); height: 60px; border: 0; border-radius: 18px; background: var(--teal); color: #fff; font-weight: 600; font-size: 18px; display: flex; align-items: center; justify-content: center; gap: 10px; box-shadow: 0 10px 30px rgba(0,122,138,.35); z-index: 10; }
.fab .ic { width: 24px; height: 24px; }

/* ---------- Mester på telefon ---------- */
@media (max-width: 860px) {
  .mainnav, .quickadd, .whoami > span:last-child, .topbar .iconbtn { display: none; }
  .attention { gap: 0; }
  .attention strong { margin-bottom: 4px; }
  .att-item { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; width: 100%; padding: 12px 0; border-top: 1px solid #2F3431; }
  .topbar-inner { justify-content: space-between; padding: 12px 16px; }
  .mester { padding: 16px 14px 100px; }
  h1 { font-size: 28px; }
  .board { max-width: none; }
  .bottomnav { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; background: var(--card); border-top: 1px solid var(--line); padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); z-index: 20; }
  .bottomnav button { border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 12px; color: var(--muted); padding: 6px 0; }
  .bottomnav button.on { color: var(--teal-d); font-weight: 600; }
  .bottomnav .bn-new { background: var(--teal); color: #fff; border-radius: 16px; margin: 0 8px; }
  .bottomnav .bn-new .ic { width: 26px; height: 26px; }
  .drawer { width: 100%; }
  .modal-wrap { padding: 0; place-items: end center; }
  .modal { border-radius: 22px 22px 0 0; }
  .grid2 { grid-template-columns: 1fr; }
  .modal .grid2, .sheet .grid2, .newcust .grid2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .table th:nth-child(1), .table td:nth-child(1), .table th:nth-child(4), .table td:nth-child(4) { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

body:not(.is-mester) .toast { bottom: calc(96px + env(safe-area-inset-bottom)); }

/* Detaljeret opgavevisning */
.drawer.wide { width: min(640px, 100%); }
.detail-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.custcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; display: flex; flex-direction: column; gap: 12px; }
.custcard b { font-weight: 600; font-size: 17px; display: block; }
.custcard small { color: var(--muted); }
.custlinks { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); background: var(--card); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; margin: 14px 0 0; }
.facts div { padding: 10px 14px; box-shadow: 1px 1px 0 var(--line); }
.facts dt { font-size: 12px; color: var(--muted); font-weight: 500; }
.facts dd { margin: 2px 0 0; font-weight: 600; }
.notes { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; margin: 0; white-space: pre-line; }
.visits { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.visit { display: flex; gap: 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; }
.visit.done { opacity: .75; }
.visit-when { width: 46px; flex: none; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding-top: 2px; }
.visit-when b { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.visit-when span { font-size: 18px; font-weight: 600; }
.visit-main { flex: 1; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.visit-who { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.visit-who b { font-weight: 600; }
.eta { font-weight: 600; color: var(--teal-d); white-space: nowrap; }
.visit-note { margin: 4px 0 0; font-size: 14px; background: var(--chip); border-radius: 8px; padding: 6px 10px; }
.visit-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 2px; }
.visit-actions .ic, .linkbtn .ic { width: 16px; height: 16px; }
.moveform { display: grid; grid-template-columns: 1fr 1fr auto auto; gap: 6px; margin-top: 6px; }
.moveform select, .moveform input { height: 36px; border: 1px solid var(--line); border-radius: 9px; padding: 0 8px; background: #fff; min-width: 0; }
.sms { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.sms li { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 10px 14px; }
.sms p { margin: 4px 0 0; font-size: 14px; }
.stop-main.clickable { cursor: default; }
.stop-main.clickable:hover b { color: var(--teal-d); }
@media (max-width: 860px) { .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } .moveform { grid-template-columns: 1fr 1fr; } }

/* Opgaven – arbejdsfladen */
.tv { display: flex; flex-direction: column; gap: 14px; }
.tv .facts { margin: 0; }
.tv-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.tv-card h3, .finishform h3 { font-size: 15px; font-weight: 600; margin: 0; }
.tv-card .help { margin: 0; }
.tv-card .big { font-size: 18px; font-weight: 600; display: block; }
.tv-card .addr { color: var(--ink-2); }
.access { display: flex; gap: 10px; align-items: flex-start; background: var(--teal-tint); border-radius: 10px; padding: 10px 12px; color: var(--teal-ink); }
.access .ic { width: 18px; height: 18px; color: var(--teal-d); margin-top: 2px; }
.access b { display: block; font-weight: 600; font-size: 13px; }
.notes-text { margin: 0; white-space: pre-line; font-size: 16px; }
.tv-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.btn.dark { background: var(--ink); color: #fff; }
.tv-quick { display: flex; gap: 8px; flex-wrap: wrap; }
.chipbtn { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 12px; border-radius: 19px; border: 1px solid var(--line); background: var(--card); font-weight: 500; font-size: 14px; }
.chipbtn .ic { width: 16px; height: 16px; }
.chipbtn:hover { border-color: var(--teal); }
.tv-status { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r); }
.tv-status span { display: flex; flex-direction: column; }
.tv-status b { font-weight: 600; }
.tv-status.live { background: var(--ink); color: #fff; }
.tv-status.live small { color: #BFC4C0; }
.tv-status.done { background: var(--teal-tint); color: var(--teal-ink); }
.tv-status.done .ic { color: var(--teal-d); }
.tv-status .btn { margin-left: auto; }
.pulse { width: 12px; height: 12px; border-radius: 50%; background: var(--teal-l); flex: none; animation: beat 1.4s infinite; }
@keyframes beat { 50% { box-shadow: 0 0 0 8px rgba(46,196,211,.18); } }
.live-txt { color: var(--teal-d); }
.tv-section .section-title { margin-top: 6px; }
.tv-section .capbar { margin-bottom: 8px; }
.lines { list-style: none; margin: 0; padding: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); }
.lines li { display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: center; padding: 10px 12px 10px 14px; border-bottom: 1px solid var(--line-2); }
.lines li:last-child { border-bottom: 0; }
.lines li > span:first-child { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-width: 0; }
.lines b { font-weight: 600; }
.ghostspace { visibility: hidden; }
.inlineform { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; background: var(--card); border: 1px solid var(--teal); border-radius: var(--r); padding: 10px; }
.inlineform input, .inlineform select { height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; background: #fff; min-width: 0; flex: 1 1 110px; }
.inlineform.mat input[name="name"] { flex: 3 1 200px; }
.inlineform.mat input[name="qty"] { flex: 0 1 70px; }
.inlineform .btn { height: 40px; }
.finishform { border: 2px solid var(--teal); }
.next-title { display: flex; align-items: center; gap: 8px; border: 0; background: none; color: inherit; padding: 0; text-align: left; margin-top: 6px; }
.next-title h2 { margin: 0; }
.next-title .ic { color: var(--teal-l); }

.chipbtn.on { border-color: var(--teal); background: var(--teal-tint); color: var(--teal-ink); }
.topform { display: flex; flex-direction: column; gap: 4px; margin-top: -4px; }
.topform-label { font-size: 13px; font-weight: 600; color: var(--teal-d); padding-left: 2px; }
.topform .inlineform { margin-top: 0; box-shadow: 0 6px 20px rgba(0,122,138,.12); }
.backbar { display: flex; align-items: center; gap: 6px; width: 100%; border: 0; border-bottom: 1px solid var(--line); background: var(--sand); padding: 10px 24px; font-weight: 500; font-size: 14px; color: var(--teal-d); text-align: left; position: sticky; top: 0; z-index: 3; }
.backbar .ic { width: 16px; height: 16px; }
.backbar + .drawer-head { top: 41px; }
.inlineform select { flex: 1 1 160px; }

.visit-when.today b { color: var(--teal-d); }
.visit-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 15px; }
.visit-line b { font-weight: 600; }
.visit-who { margin-bottom: 2px; }
.visit-actions .linkbtn.subtle { color: var(--muted); font-weight: 500; margin-left: auto; }
.visit-actions .linkbtn.subtle:hover { color: var(--ink); }
.toast.has-action { display: flex; align-items: center; gap: 14px; pointer-events: auto; }
.toast button { border: 0; background: none; color: var(--teal-l); font-weight: 600; padding: 4px 0; }

/* Opgavens faner */
.tv-cust { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; }
.tv-cust-txt { display: flex; flex-direction: column; min-width: 0; }
.tv-cust-txt b { font-weight: 600; font-size: 16px; }
.tv-cust-txt small { color: var(--ink-2); font-size: 14px; }
.tv-cust-btns { display: flex; gap: 8px; }
.btn.ghost.on { border-color: var(--teal); background: var(--teal-tint); }
.tv-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; background: var(--sand-2); border-radius: 12px; padding: 4px; position: sticky; top: 0; z-index: 2; margin-top: 4px; }
.backbar + .drawer-head + .drawer-body .tv-tabs { top: 0; }
.tv-tabs button { height: 42px; border: 0; border-radius: 9px; background: transparent; font-weight: 500; font-size: 15px; color: var(--ink-2); display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; padding: 0 4px; }
.tv-tabs button.on { background: var(--card); color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.tv-tabs .count { font-size: 12px; font-weight: 600; color: var(--teal-d); background: var(--teal-tint); border-radius: 8px; padding: 1px 6px; }
.tv-panel { display: flex; flex-direction: column; gap: 14px; }
.finsum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.finsum span { background: var(--chip); border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; }
.finsum b { font-weight: 600; font-size: 17px; }
.finsum small { color: var(--muted); font-size: 12px; }
.inlineform-title { width: 100%; font-size: 13px; font-weight: 600; color: var(--teal-d); }
.inlineform { margin-top: 0; }
.lines li.total { background: var(--chip); }
.big-num { font-size: 22px; font-weight: 600; }
.big-num small { font-size: 14px; color: var(--muted); font-weight: 500; }
.contact { margin: 0; line-height: 1.6; }
.contact a { color: var(--teal-d); text-decoration: none; }
.timeline li { grid-template-columns: 1fr auto 0; }
@media (max-width: 520px) { .tv-tabs button { font-size: 14px; } .tv-tabs .count { display: none; } }
/* Faste felter i tilføj-formularerne */
.inlineform.mat, .inlineform[data-form="timeentry"] { display: grid; gap: 8px; align-items: center; }
.inlineform.mat { grid-template-columns: minmax(0, 1fr) 64px 84px 128px auto; }
.inlineform[data-form="timeentry"] { grid-template-columns: minmax(0, 1fr) 150px 120px auto; }
.inlineform.mat > *, .inlineform[data-form="timeentry"] > * { min-width: 0; width: 100%; flex: none; }
.inlineform .btn { width: auto; }
.inlineform-title { grid-column: 1 / -1; }
.inlineform input[type="hidden"] { display: none; }
.lines { overflow: hidden; }
@media (max-width: 600px) {
  .inlineform.mat { grid-template-columns: 90px 1fr; }
  .inlineform.mat input[name="name"] { grid-column: 1 / -1; }
  .inlineform.mat input[name="price"] { grid-column: 1 / -1; }
  .inlineform.mat .btn, .inlineform[data-form="timeentry"] .btn { grid-column: 1 / -1; width: 100%; height: 44px; }
  .inlineform[data-form="timeentry"] { grid-template-columns: 1fr 1fr; }
  .inlineform[data-form="timeentry"] select { grid-column: 1 / -1; }
}

/* ---------- Materialer: søg og tryk ---------- */
.matsearch { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.ms-box { display: flex; align-items: center; gap: 8px; height: 48px; padding: 0 6px 0 12px; border: 2px solid var(--teal); border-radius: 12px; color: var(--muted); }
.ms-box input { flex: 1; border: 0; outline: none; font-size: 16px; background: transparent; min-width: 0; color: var(--ink); }
.ms-results { display: flex; flex-direction: column; max-height: 360px; overflow-y: auto; }
.ms-head { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 8px 6px 4px; }
.ms-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 36px; gap: 10px; align-items: center; text-align: left; border: 0; background: none; padding: 9px 6px; border-radius: 10px; cursor: default; }
.ms-row:hover, .ms-row:focus-visible { background: var(--teal-tint); outline: none; }
.ms-row > span:first-child { display: flex; flex-direction: column; min-width: 0; }
.ms-row b { font-weight: 600; }
.ms-row small { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ms-price { text-align: right; font-weight: 600; white-space: nowrap; display: flex; flex-direction: column; }
.ms-price small { font-weight: 400; }
.ms-add { width: 32px; height: 32px; border-radius: 9px; background: var(--teal); color: #fff; display: grid; place-items: center; }
.ms-add .ic { width: 18px; height: 18px; }
.ms-row.kit .ms-add { background: var(--ink); }
.ms-row.free .ms-add { background: var(--sand-2); color: var(--ink); }
.ms-row.free { border-top: 1px solid var(--line-2); border-radius: 0 0 10px 10px; margin-top: 4px; }
.matlines li { grid-template-columns: minmax(0, 1fr) auto auto 34px; }
.ml-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.qty { display: inline-flex; align-items: center; gap: 4px; }
.qty input { width: 52px; height: 34px; border: 1px solid var(--line); border-radius: 9px; text-align: center; font-weight: 600; background: #fff; }
.qty input:disabled { border-color: transparent; background: transparent; }
.qty small { color: var(--muted); min-width: 22px; }
.qty .iconbtn { font-size: 18px; font-weight: 600; }
.setprice input { height: 34px; border: 1px solid var(--teal); border-radius: 9px; padding: 0 10px; width: 170px; max-width: 100%; }
.lines li.total > span:first-child { flex-direction: column; align-items: flex-start; gap: 0; }
.matfoot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; }
.kitform { display: flex !important; flex: 1 1 100%; }
.kitform input { flex: 1 1 220px; }

/* Stregkode */
.scanwrap { position: fixed; inset: 0; z-index: 70; background: #000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; color: #fff; }
.scanwrap video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.scanframe { position: relative; width: min(80vw, 360px); height: 160px; border: 3px solid var(--teal-l); border-radius: 16px; box-shadow: 0 0 0 9999px rgba(0,0,0,.45); }
.scanwrap p, .scanwrap .btn { position: relative; }

/* ---------- Varer-siden ---------- */
.dropzone { display: flex; gap: 16px; align-items: center; border: 2px dashed #CFC9BA; border-radius: var(--r-lg); padding: 20px 22px; margin-bottom: 16px; color: var(--ink-2); background: rgba(255,255,255,.5); }
.dropzone .ic { width: 32px; height: 32px; color: var(--teal); flex: none; }
.dropzone b { font-weight: 600; font-size: 17px; color: var(--ink); }
.dropzone p { margin: 4px 0 0; font-size: 14px; color: var(--muted); max-width: 760px; }
.dropzone.drop-on { border-color: var(--teal); background: var(--teal-tint); }
.varer-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 16px; margin-bottom: 16px; align-items: start; }
.suplist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.suplist li { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto auto; gap: 12px; align-items: center; border: 1px solid var(--line); border-radius: var(--r); padding: 12px; }
.sup-rank { width: 28px; height: 28px; border-radius: 8px; background: var(--sand-2); display: grid; place-items: center; font-weight: 600; }
.sup-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; align-items: flex-start; }
.sup-main b { font-weight: 600; font-size: 16px; }
.sup-markup { display: flex; flex-direction: column; font-size: 12px; color: var(--muted); }
.sup-markup span { display: flex; align-items: center; gap: 4px; color: var(--ink); }
.sup-markup input { width: 64px; height: 36px; border: 1px solid var(--line); border-radius: 9px; padding: 0 8px; text-align: right; }
.sup-tools { display: flex; gap: 6px; align-items: center; }
.radios { border: 0; padding: 0; margin: 4px 0; display: flex; flex-direction: column; gap: 6px; }
.radios legend { font-size: 14px; font-weight: 500; color: var(--ink-2); margin-bottom: 4px; }
.search.wide { max-width: none; margin-bottom: 12px; }
.table-wrap.flat { border-radius: var(--r); }
.table.small td, .table.small th { padding: 8px 10px; font-size: 14px; }
.table .r { text-align: right; }
.table tr.alt td { color: var(--muted); font-size: 14px; }
.modal.wide { max-width: 880px; }
.mapgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.mapgrid select { height: 42px; }
.card + .card { margin-top: 16px; }
@media (max-width: 860px) {
  .varer-grid { grid-template-columns: 1fr; }
  .suplist li { grid-template-columns: 30px minmax(0, 1fr); }
  .sup-markup, .sup-tools { grid-column: 2; }
  .mapgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .matlines li { grid-template-columns: minmax(0, 1fr) auto 34px; }
  .matlines li > .num { display: none; }
}
.matlines li { grid-template-columns: minmax(0, 1fr) 168px 104px 34px; }
.matlines li > .num { text-align: right; }
.ml-main { align-items: flex-start; text-align: left; }
.matlines li.total { grid-template-columns: minmax(0, 1fr) auto; }
.matlines li.total > span:empty { display: none; }
@media (max-width: 860px) { .matlines li { grid-template-columns: minmax(0, 1fr) 168px 34px; } }
.lines li > span.ml-main { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; flex-wrap: nowrap; }
@media (max-width: 860px) {
  .matlines li:not(.total) { grid-template-columns: auto minmax(0, 1fr) 34px; row-gap: 8px; }
  .matlines li:not(.total) > .ml-main { grid-column: 1 / -1; }
  .matlines li:not(.total) > .num { display: block; text-align: right; }
}
.ft-sortbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 18px; }
.ft-sortbar .section-title { margin: 0; }
.ft-explain { margin: 6px 0 10px; }
.option .tagrow { margin: 4px 0 2px; }
.option-side { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; flex: none; }
.option-side .plus { white-space: nowrap; }
.option-side .btn { min-width: 132px; }
.modal-foot .help { margin: 0 auto 0 0; align-self: center; max-width: 420px; }
@media (max-width: 600px) { .option { flex-wrap: wrap; } .option-side { width: 100%; flex-direction: row; justify-content: space-between; align-items: center; padding-left: 34px; } .modal-foot .help { display: none; } }
.option { cursor: default; }
.option.top { border: 2px solid var(--teal); background: #F5FBFC; padding: 13px 15px; }

/* ---------- Helt runde knapper ---------- */
.btn, .linkbtn.pill, .quickadd, .seg, .seg button, .tv-tabs, .tv-tabs button, .tag, .ms-box { border-radius: 999px; }
.btn { padding-left: 20px; padding-right: 20px; }
.btn.small { padding-left: 14px; padding-right: 14px; }
.btn.big { border-radius: 999px; }
.btn.stack { border-radius: 22px; }
.iconbtn, .ms-add, .mic, .avatar { border-radius: 50%; }
.tv-tabs { padding: 4px; }
.qty input { border-radius: 999px; }
.m-tabs, .m-tabs button, .fab, .nbtn, .att-item .btn { border-radius: 999px; }
.nbtn { border-radius: 28px; }

/* Regel: alt man søger i er rundt, felter man udfylder er let afrundede */
.quickadd, .search, .ms-box { border-radius: 999px; padding-left: 18px; padding-right: 8px; }
.quickadd kbd { border-radius: 999px; padding: 2px 8px; }
.ms-box { padding-left: 16px; }
.navbtn, .whoami, .badge, .toast, .menu-item, .avatarbtn { border-radius: 999px; }
.nowbox, .parsed, .m-stop, .next-note, .status { border-radius: var(--r); }
.option, .matsearch, .suplist li, .dropzone { border-radius: var(--r); }
.chip { border-radius: 10px; }

/* ---------- Haster: mørk blok ---------- */
.chip.hot { background: var(--ink); color: #fff; box-shadow: none; }
.chip.hot small { color: #B9C0BC; }
.chip.hot:hover { background: #000; border-color: var(--teal-l); }
.chip .bang { color: var(--teal-l); font-weight: 700; margin-right: 5px; }
.legend { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; font-size: 13px; color: var(--ink-2); margin: 0 0 10px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend .muted { margin-left: auto; }
.chip-sw { width: 22px; height: 12px; border-radius: 4px; background: var(--chip); display: inline-block; }
.chip-sw.hot { background: var(--ink); }
.chip-sw.done { background: repeating-linear-gradient(135deg, var(--chip) 0 3px, #fff 3px 6px); }
.weekwrap { min-width: 0; }
.wrow-head:hover b { color: var(--teal); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Dagsvisning for én medarbejder ---------- */
.dayhead { display: flex; gap: 12px; align-items: center; }
.daynav { display: flex; align-items: center; gap: 6px; padding: 0 24px 6px; }
.daystrip { flex: 1; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
.daystrip button { border: 1px solid var(--line); background: var(--card); border-radius: 14px; padding: 6px 2px; display: flex; flex-direction: column; align-items: center; gap: 0; line-height: 1.2; }
.daystrip small { font-size: 12px; color: var(--muted); text-transform: capitalize; }
.daystrip b { font-size: 17px; font-weight: 600; }
.daystrip i { font-style: normal; font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.daystrip button.today b { color: var(--teal); }
.daystrip button.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.daystrip button.on small, .daystrip button.on i { color: #C9CCC9; }
.daystrip button.on.today b { color: var(--teal-l); }
.daysum { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 4px 24px 0; margin: 0; font-size: 14px; }

/* ---------- Måned ---------- */
.month { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 10px; overflow-x: auto; }
section.month .mgrid { display: grid; grid-template-columns: repeat(5, minmax(150px, 1fr)); gap: 6px; }
.mh { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 4px 8px; }
.mcell { border: 1px solid var(--line-2, #ECE8DF); border-radius: 14px; padding: 6px 8px 8px; display: flex; flex-direction: column; gap: 3px; min-height: 120px; }
.mcell.out { opacity: .45; }
.mcell.past { background: #FAF9F6; }
.mcell.today { border-color: var(--teal); background: var(--teal-tint); }
.mdate { align-self: flex-start; border: 0; background: none; font-weight: 600; font-size: 15px; padding: 2px 4px; border-radius: 999px; }
.mdate:hover { color: var(--teal); }
.mdate small { font-size: 11px; color: var(--teal); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.mrow { display: grid; grid-template-columns: 26px 1fr 8px; align-items: center; gap: 6px; border: 0; background: none; padding: 2px 4px; border-radius: 999px; text-align: left; }
.mrow:hover { background: var(--sand-2); }
.mrow .ini { font-size: 11px; font-weight: 600; color: var(--ink-2); }
.mrow .capbar { height: 6px; }
.mrow.off .mlabel { font-size: 11px; color: var(--muted); grid-column: 2 / 4; }
.hotdot { width: 8px; height: 8px; border-radius: 50%; background: var(--ink); display: block; }
.bar-sw { width: 22px; height: 6px; border-radius: 3px; background: var(--teal); display: inline-block; }
.bar-sw.full { background: var(--ink); }
.dot-sw { width: 8px; height: 8px; border-radius: 50%; background: var(--ink); display: inline-block; }
.weekwrap { flex: 999 1 720px; min-width: 0; }
.weekwrap > .week, .weekwrap > .month { width: 100%; }
.board { flex: 0 1 300px; }
.board-head { min-height: 32px; }
.legend { min-height: 32px; margin-bottom: 0; }
.tag.hot { background: var(--ink); color: #fff; font-weight: 600; }
.chip-sw { border: 1px solid #D9D4C8; }
.chip-sw.hot { border-color: var(--ink); }
.tag.hot.inv { background: var(--teal-l); color: var(--ink); align-self: flex-start; margin-top: 6px; }
.daynav { padding: 16px 24px 10px; }
.daysum { padding: 4px 24px 6px; }
.daystrip button { padding: 8px 2px; gap: 2px; }
@media (max-width: 600px) { .daynav { padding: 14px 16px 8px; } .daysum { padding: 4px 16px 6px; } }

/* ---------- Hvem og hvornår: øverst på opgaven ---------- */
.planbar { background: var(--ink); color: #fff; border-radius: var(--r-lg); padding: 6px 16px 10px; position: relative; }
.planbar .visits { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; }
.planbar .visit { background: none; border: 0; border-bottom: 1px solid #343935; border-radius: 0; padding: 12px 0; box-shadow: none; }
.planbar .visit:last-child { border-bottom: 0; }
.planbar .visit-when b { color: #A9AFAB; }
.planbar .visit-when span { color: #fff; }
.planbar .visit-when.today b { color: var(--teal-l); }
.planbar .visit-who b, .planbar .visit-line b { color: #fff; }
.planbar .visit-line { color: #DADDD9; }
.planbar .muted, .planbar small { color: #A9AFAB; }
.planbar .linkbtn { color: var(--teal-l); }
.planbar .linkbtn.subtle { color: #A9AFAB; }
.planbar .linkbtn .ic { color: var(--teal-l); }
.planbar .visit-note { background: #262A28; color: #DADDD9; }
.planbar .moveform select, .planbar .moveform input { background: #fff; color: var(--ink); }
.planbar .btn.ghost { background: transparent; color: #fff; border-color: #4A514C; }
.planbar-find { position: absolute; top: 18px; right: 16px; font-size: 14px; }
.planbar .visit:first-child .visit-main { padding-right: 120px; }
.planbar-empty { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 0 2px; color: #DADDD9; }
.planbar-empty .ic { width: 18px; height: 18px; vertical-align: -3px; color: var(--teal-l); }
.planbar-empty b { color: #fff; }
.planbar .tag.amber { background: #343935; color: #fff; }
@media (max-width: 600px) { .planbar-find { position: static; margin-top: 4px; } .planbar .visit:first-child .visit-main { padding-right: 0; } }
.planbar .moveform { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; margin-top: 8px; }
.planbar .moveform select, .planbar .moveform input { width: 100%; min-width: 0; height: 40px; border-radius: 12px; border: 0; padding: 0 10px; }
.planbar .moveform .btn { width: 100%; }
.planbar .visit:has(.moveform) .visit-main { padding-right: 0; }
.planbar .visit:has(.moveform) ~ .planbar-find, .planbar:has(.moveform) .planbar-find { display: none; }

/* ---------- Samlet boks: hvornår · hvem · hvor ---------- */
.planbar { padding: 18px 20px 16px; display: flex; flex-direction: column; gap: 0; }
.planbar hr { border: 0; border-top: 1px solid #343935; margin: 14px 0 12px; }
.pb-visit { display: flex; flex-direction: column; gap: 8px; }
.pb-visit + .pb-visit { border-top: 1px solid #2B302D; padding-top: 12px; margin-top: 12px; }
.pb-visit.done { opacity: .7; }
.pb-when { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.pb-day { font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: #A9AFAB; }
.pb-day.today { color: var(--teal-l); }
.pb-time { font-size: 24px; font-weight: 600; color: #fff; letter-spacing: -.01em; }
.pb-who { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pb-who b { color: #fff; font-weight: 600; font-size: 16px; }
.pb-who small { color: #A9AFAB; font-size: 13px; }
.pb-where { display: flex; flex-direction: column; gap: 2px; }
.pb-where b { color: #fff; font-size: 17px; font-weight: 600; }
.pb-where span { color: #DADDD9; }
.pb-where small { color: #A9AFAB; font-size: 13px; margin-top: 4px; }
.pb-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.pb-btns { display: flex; gap: 8px; }
.pb-acts { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.pb-acts .linkbtn { font-size: 14px; }
.btn.onDark { background: #2F3431; color: #fff; border-color: #2F3431; }
.btn.onDark:hover { background: #3A403C; }
.btn.onDark .ic { color: #fff; }
.pb-empty { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; color: #DADDD9; }
.pb-empty .ic { width: 18px; height: 18px; vertical-align: -3px; color: var(--teal-l); }
.pb-empty b { color: #fff; }
.planbar .tag { background: #343935; color: #fff; }
.planbar .tag.teal { background: var(--teal-l); color: var(--ink); }
@media (max-width: 600px) { .pb-foot { flex-direction: column; align-items: stretch; } .pb-btns .btn { flex: 1; } }
.pb-whorow { display: flex; justify-content: space-between; align-items: center; gap: 10px 16px; flex-wrap: wrap; }
.pb-whorow .pb-acts { gap: 12px; }
/* Avatarer skal kunne ses på den mørke boks */
.planbar .avatar { box-shadow: 0 0 0 2px #4A514C; }
.pb-name { display: flex; flex-direction: column; gap: 1px; }
.pb-name small { color: #A9AFAB; font-size: 13px; }
/* Tiden kører: teal, så den ikke smelter sammen med den mørke boks */
.tv-status.live { background: var(--teal); color: #fff; border-color: var(--teal); }
.tv-status.live small { color: #D7EEF1; }
.tv-status.live .pulse { background: #fff; }

/* ---------- Ugeplan: én bane pr. medarbejder ---------- */
.week { background: transparent; border: 0; border-radius: 0; overflow: visible; }
.week-grid { row-gap: 8px; }
.wh, .wrow-head, .wcell { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.wh.first, .wrow-head { border-left: 1px solid var(--line); border-radius: var(--r-lg) 0 0 var(--r-lg); }
.wh.last, .wcell.last { border-right: 1px solid var(--line); border-radius: 0 var(--r-lg) var(--r-lg) 0; }
.wh { padding: 10px 12px; }
.wh.today, .wcell.today { background: #F4FAFB; }
.wcell.past { background: #FBFAF7; }
.wcell.off { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.wrow-head:hover { background: #FAF9F6; }

/* ---------- Opgavekort: titel øverst, kunde under ---------- */
.chip { flex-direction: column; justify-content: flex-start; gap: 3px; padding: 6px 8px; }
.chip-top { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; min-width: 0; }
.chip-top b { font-weight: 600; font-size: 13px; line-height: 1.25; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; white-space: normal; }
.chip-top small { flex: none; }
.chip-sub { font-size: 12px; color: var(--muted); border-top: 1px solid #DCD7CC; padding-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 400 !important; }
.chip.hot .chip-sub { color: #B9C0BC; border-top-color: #3A403C; }
.chip .bang { font-style: normal; color: var(--teal-l); font-weight: 700; margin-right: 4px; }
.chip.done .chip-top b, .chip.done .chip-sub { text-decoration: line-through; }
.week-grid { grid-template-columns: 184px repeat(var(--cols), minmax(108px, 1fr)); min-width: 730px; }
.chip-top b { hyphens: auto; -webkit-hyphens: auto; overflow-wrap: anywhere; }
.weeknav .seg { flex-wrap: nowrap; }
.weeknav .seg button { white-space: nowrap; }
@media (max-width: 600px) { .weeknav { flex-wrap: wrap; } }
.chip-top b { hyphens: manual; -webkit-hyphens: manual; overflow-wrap: normal; word-break: normal; }
.chip-sub { display: flex; justify-content: space-between; gap: 6px; }
.chip-sub span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 400; }
.chip-sub small { flex: none; font-size: 12px; }
/* Smallere skærme: tavlen lægger sig over ugen, så ugen får hele bredden */
@media (max-width: 1280px) {
  .board { flex: 1 1 100%; max-width: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
  .board-head { grid-column: 1 / -1; }
  .board .empty { grid-column: 1 / -1; }
}
.week-grid { grid-template-columns: 210px repeat(var(--cols), minmax(108px, 1fr)); min-width: 760px; }
.wrow-head .free { white-space: nowrap; }

/* ---------- Søg eller opret ---------- */
.quickadd { position: relative; }
.qa-results { position: absolute; top: calc(100% + 8px); left: 0; right: 0; background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 18px 40px rgba(26,29,27,.18); padding: 8px; z-index: 40; max-height: 70vh; overflow-y: auto; }
.qa-head { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 8px 10px 6px; }
.qa-row { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; background: none; text-align: left; padding: 10px; border-radius: 14px; color: var(--ink); }
.qa-row:hover, .qa-row:focus-visible { background: var(--teal-tint); outline: none; }
.qa-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.qa-main b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qa-main small { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qa-meta { flex: none; font-size: 13px; color: var(--teal-d); font-weight: 500; white-space: nowrap; }
.qa-row.done .qa-meta { color: var(--muted); }
.qa-row .bang { font-style: normal; color: var(--ink); background: var(--teal-l); border-radius: 999px; padding: 0 6px; margin-right: 6px; font-size: 12px; }
.qa-new { border-top: 1px solid var(--line-2); border-radius: 0 0 14px 14px; margin-top: 4px; }
.qa-new > .ic { width: 20px; height: 20px; color: var(--teal); flex: none; }
.qa-new kbd { font: 500 12px var(--font); border: 1px solid var(--line); border-radius: 999px; padding: 2px 8px; color: var(--muted); }
.pb-cust { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; padding: 0; color: #fff; text-align: left; align-self: flex-start; }
.pb-cust b { font-size: 17px; font-weight: 600; }
.pb-cust .ic { width: 16px; height: 16px; color: var(--teal-l); }
.pb-cust:hover b { text-decoration: underline; text-underline-offset: 3px; }
.pb-addr { color: #DADDD9; text-decoration: none; align-self: flex-start; }
.pb-addr:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.pb-contact { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 6px; }
.pb-contact a { color: var(--teal-l); text-decoration: none; display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.pb-contact .ic { width: 15px; height: 15px; }

/* ---------- Afslut ---------- */
.fin-notime { border: 2px solid var(--ink); background: #F7F5F0; border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.fin-notime > b { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.fin-notime > b .ic { width: 18px; height: 18px; }
.fin-hours { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.fin-hours input { width: 72px; height: 40px; border: 1px solid var(--line); border-radius: 12px; text-align: center; font-weight: 600; font-size: 16px; background: #fff; }
.fin-hours input:disabled { opacity: .4; }
.fin-brief { margin: 4px 0 0; color: var(--muted); font-size: 14px; display: flex; gap: 8px; }
.fin-brief small { font-weight: 600; text-transform: uppercase; letter-spacing: .08em; font-size: 11px; padding-top: 2px; }
.dictate-wrap { position: relative; display: block; }
.dictate-wrap textarea { width: 100%; padding-right: 52px; }
.dictate-wrap .mic-btn { position: absolute; right: 8px; top: 8px; }
.mic-btn.on { background: var(--teal); color: #fff; border-color: var(--teal); animation: pulse 1.2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(0,122,138,.18); } }
.timelog li > span:first-child { display: flex; gap: 10px; align-items: flex-start; }
.tl-txt { display: flex; flex-direction: column; gap: 1px; }
.timelog li.deleted b, .timelog li.deleted .num { text-decoration: line-through; color: var(--muted); }
.timelog .del { color: var(--ink); font-size: 12px; font-weight: 500; }

/* ---------- Varer v2 ---------- */
.suppliers { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-bottom: 16px; }
.supcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); display: flex; flex-direction: column; }
.supcard-main { border: 0; background: none; text-align: left; padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; border-radius: var(--r-lg); flex: 1; }
.supcard-main:hover { background: #FAF9F6; }
.sup-name { display: flex; justify-content: space-between; align-items: center; width: 100%; }
.sup-name b { font-size: 18px; font-weight: 600; }
.sup-name .ic { color: var(--teal); }
.sup-stats { font-size: 15px; }
.sup-stats b { font-weight: 600; }
.sup-order { display: flex; align-items: center; gap: 6px; padding: 8px 14px; border-top: 1px solid var(--line-2); }
.sup-order small { color: var(--muted); margin-right: auto; }
.empty-sup { grid-column: 1 / -1; background: var(--card); border: 2px dashed #D9D4C8; border-radius: var(--r-lg); padding: 28px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.pricecard { margin-bottom: 16px; max-width: 760px; }
.tiers { display: flex; flex-direction: column; gap: 6px; padding: 10px 0; }
.tiers.dim { opacity: .55; }
.tier-head, .tier { display: grid; grid-template-columns: minmax(0, 1fr) 140px 40px; gap: 10px; align-items: center; }
.tier-head { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.tier input { width: 90px; height: 38px; border: 1px solid var(--line); border-radius: 12px; padding: 0 10px; text-align: right; background: #fff; }
.tier span:nth-child(2) input { width: 70px; }
.tiers .linkbtn { align-self: flex-start; }
.backbar.inline { background: none; border: 0; padding: 0; margin-bottom: 10px; color: var(--teal); display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.pagehead-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.dropzone.small { padding: 14px 18px; }
.dgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.pctin { display: flex; align-items: center; gap: 6px; }
.pctin input { width: 80px; }
.supfilter { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.supfilter select { height: 42px; border: 1px solid var(--line); border-radius: 999px; padding: 0 14px; background: #fff; }
.itemtable td { vertical-align: middle; }
.itemtable .block { display: block; }
.cellin { width: 96px; height: 34px; border: 1px solid transparent; border-radius: 10px; padding: 0 8px; background: transparent; }
.cellin:hover, .cellin:focus { border-color: var(--line); background: #fff; }
.itemtable .acts { white-space: nowrap; text-align: right; }
.itemform { margin: 0 0 16px; }
.itemtable .itemform { margin: 6px 0; box-shadow: none; }
.itemgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.itemgrid .wide { grid-column: span 2; }
.danger-row { margin: 16px 0 40px; }
.chips-pick { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.pick { border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 8px 14px; font-weight: 500; }
.pick:hover { border-color: var(--teal); }
.pick.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.pick:disabled { opacity: .35; }
.ns-foot { justify-content: flex-end; }
.btn.disabled { opacity: .45; pointer-events: none; }
.imp-sup { margin: 0 0 12px; }
.econ .lines li.total { font-weight: 600; }
@media (max-width: 860px) { .itemgrid { grid-template-columns: 1fr 1fr; } .itemtable th:nth-child(3), .itemtable td:nth-child(3) { display: none; } }
.varer-cols { display: grid; grid-template-columns: minmax(0, 3fr) minmax(280px, 2fr); gap: 16px; align-items: start; margin-bottom: 16px; }
.varer-cols .pricecard { max-width: none; margin: 0; }
.varer-cols .card + .card, .varer-cols > section { margin-top: 0; }
@media (max-width: 1000px) { .varer-cols { grid-template-columns: 1fr; } }
.tier-head, .tier { grid-template-columns: 130px 130px 120px 40px; justify-content: start; }
.tier input { width: 110px; text-align: right; }
.tier .pctcell input { width: 72px; }
.tier .pctcell { display: flex; align-items: center; gap: 6px; }
.tier-head, .tier { grid-template-columns: 140px 140px 120px 40px; }
.tier span:first-child input, .tier span:nth-child(2) input { width: 130px; }
.driftbox { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--teal-tint); border: 1px solid #BFE0E4; border-radius: var(--r); padding: 12px 14px; margin-bottom: 10px; }
.driftbox > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.driftbox small { color: var(--ink-2); font-size: 13px; }
.econ .vatline { color: var(--muted); font-size: 14px; }
.econ .total.sub { color: var(--ink-2); font-weight: 500; }
.vatlines { margin-top: 10px; }
.big-num small { font-size: 12px; font-weight: 500; color: var(--muted); }
[hidden] { display: none !important; }

/* ---------- Overblik ---------- */
.home-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin: 8px 0 20px; }
.home-head h1 { font-size: clamp(30px, 4vw, 44px); margin: 0; letter-spacing: -.02em; }
.home-sub { margin: 6px 0 0; font-size: 18px; color: var(--ink-2); }
.home-acts { display: flex; gap: 8px; flex-wrap: wrap; }
.kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px 18px; text-align: left; display: flex; flex-direction: column; gap: 4px; color: var(--ink); }
.kpi:not(:disabled):hover { border-color: var(--teal); }
.kpi:disabled { opacity: 1; cursor: default; }
.kpi small { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.kpi b { font-size: 28px; font-weight: 600; letter-spacing: -.01em; line-height: 1.15; }
.kpi span { font-size: 13px; color: var(--ink-2); }
.kpis .kpi:first-child b { color: var(--ink); }
.home-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; margin-bottom: 40px; }
.home-grid .card { margin: 0; }
.hlist { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; }
.hlist li { border-top: 1px solid var(--line-2); }
.hlist li:first-child { border-top: 0; }
.hrow { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; background: none; text-align: left; padding: 10px 4px; border-radius: 12px; color: var(--ink); }
.hrow:hover { background: #FAF9F6; }
.hrow > span:not(.num) { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.hrow b { font-weight: 600; }
.hrow small { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hrow > .ic { color: var(--muted); flex: none; }
.hrow .num { display: flex; flex-direction: column; align-items: flex-end; font-weight: 600; white-space: nowrap; }
.hrow .bang { font-style: normal; color: #fff; background: var(--ink); border-radius: 999px; padding: 0 6px; margin-right: 6px; font-size: 12px; }
.hinv { display: flex; align-items: center; gap: 10px; }
.hinv .hrow { flex: 1; }
.hfree { display: grid; grid-template-columns: 28px 80px minmax(0, 1fr) 90px; gap: 10px; align-items: center; padding: 8px 4px; }
.hfree .num { text-align: right; font-size: 14px; }
.home-ok { color: var(--ink-2); display: flex; gap: 8px; align-items: center; }
.home-ok .ic { color: var(--teal); }
.count { background: var(--ink); color: #fff; border-radius: 999px; padding: 2px 10px; font-weight: 600; font-size: 13px; }
.inv-done { color: var(--teal-d); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-weight: 500; }
.inv-ready { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; background: var(--teal-tint); border-radius: var(--r); padding: 12px 14px; margin: 8px 0; }
.inv-ready span { display: flex; flex-direction: column; }
.inv-ready small { color: var(--ink-2); }
.m-greet { margin: 4px 0 14px; }
.m-greet h1 { font-size: 28px; margin: 0; letter-spacing: -.01em; }
.m-greet p { margin: 2px 0 0; color: var(--ink-2); }
@media (max-width: 1100px) { .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .home-grid { grid-template-columns: 1fr; } .kpi b { font-size: 22px; } }
.hrow > .avatar, .hfree > .avatar { flex: none; }
.hrow > span.avatar { flex: 0 0 auto !important; }
.m-subline { margin: 2px 0 0; color: var(--ink-2); font-size: 15px; }
@media (max-width: 760px) { .kpis .kpi:last-child { grid-column: 1 / -1; } }
.hrow > span.avatar { display: grid !important; place-items: center; flex-direction: initial; }

/* ---------- Kontrast: kort løfter sig fra baggrunden ---------- */
body { background: #ECE9E2; }
.card, .kpi, .supcard, .month, .tv-card, .week .wh, .week .wrow-head, .week .wcell { box-shadow: none; }
.home-grid .card, .kpi { background: #fff; border: 1px solid #E4E0D7; box-shadow: 0 1px 2px rgba(26,29,27,.05), 0 6px 18px rgba(26,29,27,.06); }
.kpi { position: relative; padding: 16px 18px 16px; gap: 2px; }
.kpi-ic { width: 38px; height: 38px; border-radius: 12px; background: var(--teal-tint); color: var(--teal); display: grid; place-items: center; margin-bottom: 10px; }
.kpi-ic .ic { width: 20px; height: 20px; }
.kpi b { font-size: 30px; }
.kpi.alertk { background: var(--ink); border-color: var(--ink); color: #fff; }
.kpi.alertk small, .kpi.alertk span { color: #B9C0BC; }
.kpi.alertk .kpi-ic { background: #2F3431; color: var(--teal-l); }
.kpi:not(:disabled):hover { transform: translateY(-1px); box-shadow: 0 2px 4px rgba(26,29,27,.06), 0 12px 28px rgba(26,29,27,.1); }
.h-ic { display: flex; align-items: center; gap: 10px; }
.h-ic .ic { width: 30px; height: 30px; padding: 6px; border-radius: 10px; background: var(--sand); color: var(--ink-2); }
.home-head h1 { font-weight: 600; }
.kpi.alertk b, .kpis .kpi.alertk:first-child b { color: #fff; }
@keyframes flash { 0% { box-shadow: 0 0 0 0 rgba(0,122,138,.0); } 30% { box-shadow: 0 0 0 4px rgba(0,122,138,.35); } 100% { box-shadow: 0 1px 2px rgba(26,29,27,.05), 0 6px 18px rgba(26,29,27,.06); } }
.card.flash { animation: flash 1.1s ease-out; border-color: var(--teal); }

/* Mobil: nøgletal som ét kompakt bånd, man swiper i */
@media (max-width: 760px) {
  .kpis { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 10px; margin: 0 -16px 16px; padding: 2px 16px 8px; scrollbar-width: none; }
  .kpis::-webkit-scrollbar { display: none; }
  .kpis .kpi, .kpis .kpi:last-child { flex: 0 0 auto; min-width: 140px; max-width: 170px; grid-column: auto; scroll-snap-align: start; padding: 12px 14px; display: grid; grid-template-columns: 28px 1fr; column-gap: 8px; row-gap: 0; align-items: center; }
  .kpi-ic { width: 28px; height: 28px; border-radius: 9px; margin: 0; grid-row: 1; }
  .kpi-ic .ic { width: 16px; height: 16px; }
  .kpi small { grid-row: 1; grid-column: 2; font-size: 11px; line-height: 1.2; }
  .kpi b { grid-column: 1 / -1; font-size: 24px; margin-top: 6px; }
  .kpi span { grid-column: 1 / -1; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .kpi:not(:disabled):hover { transform: none; }
}
@media (max-width: 760px) {
  .kpis { margin: 0 -14px 16px; padding: 2px 14px 8px; scroll-padding-inline: 14px; max-width: none; width: calc(100% + 28px); }
  main.mester { overflow-x: hidden; }
}
.kpi-dots { display: none; }
@media (max-width: 760px) {
  .kpis { margin-bottom: 4px; }
  .kpi-dots { display: flex; justify-content: center; gap: 6px; margin: 0 0 18px; }
  .kpi-dots i { width: 6px; height: 6px; border-radius: 3px; background: rgba(26,29,27,.2); transition: width .2s, background .2s; }
  .kpi-dots i.on { width: 18px; background: #1A1D1B; }
}
@media (max-width: 420px) {
  .home-acts { display: grid; grid-template-columns: auto 1fr; gap: 8px; }
  .home-acts .btn { padding-left: 14px; padding-right: 14px; font-size: 15px; justify-content: center; white-space: nowrap; }
  .home-acts .btn.ghost .ic { display: none; }
}
/* Overblik: to selvstændige søjler, så kortene lægger sig tæt uden huller */
.home-col { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
@media (max-width: 760px) {
  .home-col { display: contents; }
  #h-att { order: 1; } #h-today { order: 2; } #h-inv { order: 3; } #h-free { order: 4; }
}
/* Overblik: korte kort side om side øverst (Kræver handling | Klar til faktura), lange nederst (I dag | Ledig tid). Samme højde i hver række. */
.home-grid { align-items: stretch; }
@media (max-width: 760px) {
  #h-att { order: 1; } #h-today { order: 2; } #h-inv { order: 3; } #h-free { order: 4; }
}
/* Arbejdsdage fra firmaindstillingerne */
.daystrip { grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); }
section.month .mgrid { grid-template-columns: repeat(var(--mcols, 5), minmax(150px, 1fr)); }
.wh.closed span::after { content: ' · LUKKET'; }
.wh.closed { opacity: .6; }
.wdays { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.wday { position: relative; }
.wday input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.wday span { display: inline-flex; align-items: center; justify-content: center; min-width: 48px; height: 38px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: #fff; font-weight: 500; }
.wday input:checked + span { background: #1A1D1B; color: #fff; border-color: #1A1D1B; }
.wday input:focus-visible + span { outline: 2px solid #007A8A; outline-offset: 2px; }
fieldset.field { border: 0; padding: 0; margin: 0 0 14px; }
fieldset.field legend { font-size: 13px; font-weight: 500; color: var(--muted); padding: 0; }
.pb-addr.ws { display: inline-flex; align-items: center; gap: 6px; }
.pb-addr.ws .ic { width: 15px; height: 15px; }
.pb-addr.ws:hover { color: #DADDD9; text-decoration: none; }
/* Opgavekø: skal tydeligt kalde på handling */
.board-head h2 { display: inline-flex; align-items: center; gap: 8px; }
.qcount { display: inline-flex; align-items: center; justify-content: center; min-width: 24px; height: 24px; padding: 0 8px; border-radius: 999px; background: #007A8A; color: #fff; font-size: 13px; font-weight: 600; }
.qtag { display: inline-block; padding: 1px 8px; border-radius: 999px; background: #E3F1F3; color: #00616E; font-size: 12px; font-weight: 600; }
.board-head { flex-direction: column; align-items: flex-start; gap: 2px; }
@media (max-width: 760px) {
  .drag-hint { display: none; }
  .weeknav { display: grid; grid-template-columns: auto 1fr auto auto auto; gap: 6px; width: 100%; }
  .weeknav .seg { grid-column: 1; }
  .weeknav > .iconbtn, .weeknav > .btn { grid-row: 1; }
}
@media (max-width: 420px) {
  .weeknav { grid-template-columns: auto auto auto 1fr; }
  .weeknav .seg { grid-column: 1 / -1; justify-self: start; }
  .weeknav > .iconbtn, .weeknav > .btn { grid-row: 2; }
  .weeknav > .btn { padding-left: 14px; padding-right: 14px; }
}
/* Mellemstore skærme (fx 1000 px): topbaren må ikke skubbe ud over kanten */
@media (min-width: 861px) and (max-width: 1240px) {
  .topbar-inner { gap: 12px; padding: 12px 18px; }
  .quickadd { min-width: 44px; }
  .quickadd kbd, .whoami > span:last-child { display: none; }
  .mainnav .navbtn { padding-left: 10px; padding-right: 10px; }
}
@media (min-width: 861px) and (max-width: 1060px) {
  .quickadd { min-width: 0; flex: 1 1 0; }
  .mainnav .navbtn { padding-left: 8px; padding-right: 8px; font-size: 14px; }
}
.still { animation: none !important; }

/* ===== Mørk venstremenu (computer) ===== */
.side { display: none; }
@media (min-width: 861px) {
  body.is-mester { padding-left: 248px; }
  .side { display: flex; flex-direction: column; position: fixed; top: 0; left: 0; bottom: 0; width: 248px; background: #1A1D1B; color: #fff; padding: 22px 14px 16px; z-index: 30; gap: 6px; }
  .side-top { padding: 4px 12px 18px; }
  .side-top .logo { font-size: 30px; }
  .side-new { display: flex; align-items: center; justify-content: center; gap: 8px; height: 46px; border: 0; border-radius: 999px; background: #007A8A; color: #fff; font: 600 15px var(--font); margin: 0 2px 18px; cursor: pointer; }
  .side-new .ic { width: 18px; height: 18px; }
  .side-nav { display: flex; flex-direction: column; gap: 2px; }
  .side-item { display: flex; align-items: center; gap: 12px; width: 100%; height: 44px; padding: 0 14px; border: 0; border-radius: 999px; background: transparent; color: #C9CECA; font: 500 15px var(--font); cursor: pointer; text-align: left; }
  .side-item .ic { width: 19px; height: 19px; opacity: .85; }
  .side-item:hover { background: #262A28; color: #fff; }
  .side-item.on { background: #F3F1EC; color: #1A1D1B; font-weight: 600; }
  .side-item.on .ic { opacity: 1; color: #007A8A; }
  .side-item .badge { margin-left: auto; }
  .side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 8px; border-top: 1px solid #2E3330; padding-top: 12px; }
  .side-me { display: flex; align-items: center; gap: 10px; border: 0; background: transparent; color: #fff; padding: 6px 10px; border-radius: 14px; text-align: left; cursor: pointer; font-family: var(--font); }
  .side-me:hover { background: #262A28; }
  .side-me b { display: block; font-size: 14px; } .side-me small { display: block; font-size: 12px; color: #9AA19D; }
  /* Topbjælken bliver lys og rummer kun søgningen */
  .topbar { background: #ECE9E2; color: var(--ink); position: sticky; top: 0; border-bottom: 1px solid #E0DCD3; }
  .topbar .logo, .topbar .whoami { display: none; }
  .topbar-inner { padding: 14px 28px; }
  .quickadd { background: #fff; border: 1px solid #DDD8CE; color: #6B716D; max-width: 640px; box-shadow: 0 1px 2px rgba(26,29,27,.04); }
  .quickadd input { color: var(--ink); } .quickadd input::placeholder { color: #8A908C; }
  .quickadd kbd { border-color: #DDD8CE; color: #6B716D; }
  .home-acts .btn.primary { display: none; }
}
/* Klar til fakturering */
.invtable td.money { white-space: nowrap; }
.invtable td.money b { display: block; font-weight: 600; }
.invtable td.money small { display: block; font-size: 12px; color: var(--muted); }
.invtable td.acts { white-space: nowrap; text-align: right; }
.invtable td.acts .btn + .btn { margin-left: 6px; }
.inv-help { margin: -4px 0 12px; }
.seg .qcount { min-width: 20px; height: 20px; font-size: 12px; padding: 0 6px; margin-left: 4px; }
/* Mindre computerskærme: menuen klapper sammen til ikoner, så ugeplanen får pladsen */
@media (min-width: 861px) and (max-width: 1279px) {
  body.is-mester { padding-left: 76px; }
  .side { width: 76px; padding: 18px 10px 14px; align-items: center; }
  .side-top { padding: 4px 0 16px; }
  .side-top .logo { font-size: 0; }
  .side-top .logo::before { content: 'f'; font-size: 30px; }
  .side-top .logo::after { font-size: 30px; }
  .side-new { width: 48px; height: 48px; padding: 0; margin: 0 0 16px; font-size: 0; gap: 0; }
  .side-new .ic { width: 20px; height: 20px; }
  .side-item { width: 52px; height: 48px; padding: 0; justify-content: center; position: relative; }
  .side-item > span:not(.badge) { display: none; }
  .side-item .badge { position: absolute; top: 4px; right: 2px; margin: 0; }
  .side-me { padding: 6px; } .side-me > span:last-child { display: none; }
}
@media (min-width: 1280px) { .side-item > span:not(.badge) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .side-item { font-size: 14.5px; } }
.invtable th.inv-pick, .invtable td.inv-pick { width: 40px; padding-right: 0; }
.invtable input[type="checkbox"] { width: 18px; height: 18px; accent-color: #007A8A; cursor: pointer; }
.invtable input[type="checkbox"]:disabled { cursor: not-allowed; opacity: .35; }
.invtable tr.picked td { background: #EEF6F7; }
.inv-prob { display: flex; align-items: center; gap: 5px; margin-top: 3px; color: #8A5A00; font-size: 12.5px; font-weight: 500; }
.inv-prob .ic { width: 14px; height: 14px; }
.muted-s { display: block; font-size: 12px; color: var(--muted); }
.inv-test { display: flex; gap: 10px; align-items: flex-start; background: #FFF6E0; border: 1px solid #F0DCA8; color: #5C4300; border-radius: 14px; padding: 12px 16px; margin-bottom: 14px; font-size: 14px; }
.inv-test .ic { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.inv-bar { position: sticky; bottom: 16px; margin-top: 14px; display: flex; align-items: center; gap: 16px; background: #1A1D1B; color: #fff; border-radius: 999px; padding: 10px 10px 10px 24px; box-shadow: 0 12px 32px rgba(26,29,27,.25); }
.inv-bar > span { margin-right: auto; }
.linkbtn.on-dark { color: #C9CECA; }
.ic-list { list-style: none; margin: 0 0 12px; padding: 0; max-height: 280px; overflow-y: auto; }
.ic-list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.ic-list small { display: block; color: var(--muted); font-size: 12.5px; }
.ic-sum { display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; padding: 10px 0 6px; font-size: 14px; }
@media (max-width: 760px) { .inv-bar { flex-wrap: wrap; border-radius: 20px; padding: 12px 14px; bottom: 90px; } }
.invtable input[type="checkbox"] { appearance: auto; -webkit-appearance: checkbox; padding: 0; margin: 0; border: 0; background: none; box-shadow: none; min-height: 0; display: block; }
.invtable td.inv-pick, .invtable th.inv-pick { padding-left: 18px; }

/* ===== Login og opret firma ===== */
.auth { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 32px 16px; background: #ECE9E2; }
.auth-card { width: 100%; max-width: 420px; background: #fff; border: 1px solid #E4E0D7; border-radius: 24px; padding: 32px 28px; box-shadow: 0 1px 2px rgba(26,29,27,.05), 0 12px 32px rgba(26,29,27,.08); }
.auth-card.wide { max-width: 520px; }
.auth-logo { margin-bottom: 22px; }
.auth-logo .logo { font-size: 32px; }
.auth h1 { font-size: 26px; margin: 0 0 6px; letter-spacing: -.01em; }
.auth .muted { margin: 0 0 18px; }
.auth .form { display: flex; flex-direction: column; gap: 4px; margin-top: 12px; }
.auth .btn.big { width: 100%; justify-content: center; margin-top: 8px; }
.auth-switch { text-align: center; margin: 14px 0 0; font-size: 14px; color: var(--muted); }
.auth-switch.subtle { margin-top: 22px; }
.auth-foot { margin-top: 18px; font-size: 13px; color: var(--muted); }
.auth-msg { display: flex; gap: 8px; align-items: flex-start; border-radius: 12px; padding: 10px 12px; font-size: 14px; margin: 8px 0 0; }
.auth-msg .ic { width: 17px; height: 17px; flex: none; margin-top: 1px; }
.auth-msg.err { background: #FDECEA; color: #8A1F14; }
.auth-msg.ok { background: #E3F1F3; color: #00515C; }
.auth-wait { display: flex; align-items: center; gap: 10px; color: var(--muted); }
.auth-or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; margin: 14px 0 2px; }
.auth-or::before, .auth-or::after { content: ''; flex: 1; height: 1px; background: #E4E0D7; }
.auth .google { width: 100%; justify-content: center; }
.auth-opts { border: 0; padding: 0; margin: 10px 0 4px; display: flex; flex-direction: column; gap: 8px; }
.auth-opts legend { font-size: 13px; font-weight: 500; color: var(--muted); margin-bottom: 6px; }
.auth-opt { display: flex; gap: 12px; align-items: flex-start; border: 1px solid #E4E0D7; border-radius: 14px; padding: 12px 14px; cursor: pointer; }
.auth-opt:has(input:checked) { border-color: #007A8A; background: #F2F8F9; }
.auth-opt input { margin-top: 3px; accent-color: #007A8A; width: 18px; height: 18px; flex: none; }
.auth-opt b { display: block; font-weight: 600; }
.auth-opt small { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.auth-list { display: flex; flex-direction: column; gap: 8px; }
.auth-co { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; border: 1px solid #E4E0D7; background: #fff; border-radius: 14px; padding: 12px 14px; cursor: pointer; font-family: var(--font); }
.auth-co:hover { border-color: #007A8A; }
.auth-co b { flex: 1; } .auth-co small { color: var(--muted); }
.menu-foot { display: flex; align-items: center; gap: 10px; border-top: 1px solid var(--line); margin-top: 8px; padding-top: 10px; }
.menu-foot span { flex: 1; min-width: 0; } .menu-foot b, .menu-foot small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu-foot small { color: var(--muted); font-size: 12px; }
.login-ok { display: flex; align-items: center; gap: 6px; color: #00515C; font-weight: 500; }
.login-ok .ic { width: 16px; height: 16px; }
/* Kom i gang */
.startguide { margin-bottom: 16px; }
.sg-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.sg-step { width: 100%; height: 100%; display: flex; align-items: flex-start; gap: 10px; text-align: left; border: 1px solid #E4E0D7; background: #fff; border-radius: 16px; padding: 12px 14px; cursor: pointer; font-family: var(--font); color: var(--ink); }
.sg-step:hover { border-color: #007A8A; }
.sg-step > .ic { width: 16px; height: 16px; margin-left: auto; color: var(--muted); flex: none; }
.sg-step b { display: block; font-weight: 600; } .sg-step small { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.sg-dot { width: 22px; height: 22px; border-radius: 50%; border: 2px solid #C9CECA; flex: none; display: inline-flex; align-items: center; justify-content: center; margin-top: 1px; }
.sg-list li.done .sg-dot { background: #007A8A; border-color: #007A8A; color: #fff; }
.sg-dot .ic { width: 13px; height: 13px; }
.sg-list li.done b { text-decoration: line-through; color: var(--muted); }
.wk-empty { padding: 22px; color: var(--muted); background: #fff; border-radius: 0 0 var(--r-lg) var(--r-lg); }
@media (max-width: 900px) { .sg-list { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .sg-list { grid-template-columns: 1fr; } }
