:root {
  --bg: #f5f3ef; --card: #fff; --ink: #1f2a37; --ink-2: #5b6573; --line: #e4e0d8;
  --accent: #e8792b; --accent-ink: #fff; --ok: #2f8f5b; --warn: #c9871a; --bad: #c2413b;
  --r: 12px; --nav-h: 64px;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--ink); background: var(--bg);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }

/* Layout */
.shell { display: grid; grid-template-columns: 220px 1fr; min-height: 100vh; }
.side { background: var(--ink); color: #fff; padding: 20px 14px; display: flex; flex-direction: column; gap: 4px; }
.brand { font-weight: 800; font-size: 20px; padding: 4px 10px 18px; letter-spacing: -.02em; }
.brand span { color: var(--accent); }
.nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; text-decoration: none; color: #d6dbe2; font-weight: 600; }
.nav a.on { background: rgba(255,255,255,.1); color: #fff; }
.side .who { margin-top: auto; font-size: 13px; color: #aab3bf; padding: 10px 12px; }
main { padding: 24px; max-width: 1000px; width: 100%; }
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
h1 { font-size: 24px; margin: 0; letter-spacing: -.01em; }
h2 { font-size: 16px; margin: 22px 0 10px; color: var(--ink-2); text-transform: uppercase; letter-spacing: .06em; }

@media (max-width: 760px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; bottom: 0; left: 0; right: 0; height: calc(var(--nav-h) + env(safe-area-inset-bottom)); flex-direction: row;
          padding: 6px 6px env(safe-area-inset-bottom); z-index: 10; }
  .side .brand, .side .who { display: none; }
  .nav { display: flex; width: 100%; }
  .nav a { flex: 1; flex-direction: column; gap: 2px; font-size: 11px; padding: 8px 2px; justify-content: center; }
  main { padding: 16px 16px calc(var(--nav-h) + 24px); }
}
.nav .ic { font-size: 18px; line-height: 1; }

/* Komponenter */
.btn { border: 0; background: var(--accent); color: var(--accent-ink); padding: 11px 16px; border-radius: 10px; font-weight: 700; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.btn.sec { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn.link { background: none; color: var(--ink-2); padding: 8px; }
.btn:disabled { opacity: .5; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; }
.list { display: grid; gap: 8px; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--card); border: 1px solid var(--line);
       border-radius: var(--r); padding: 14px 16px; text-decoration: none; }
.row:hover { border-color: #cfc8bb; }
.row .t { font-weight: 700; }
.row .s { color: var(--ink-2); font-size: 14px; margin-top: 2px; }
.empty { text-align: center; color: var(--ink-2); padding: 40px 16px; }
.search { width: 100%; padding: 11px 14px; border-radius: 10px; border: 1px solid var(--line); background: #fff; margin-bottom: 12px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.chip { border: 1px solid var(--line); background: #fff; padding: 6px 12px; border-radius: 999px; font-size: 14px; cursor: pointer; }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.badge { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.b-offert { background: #eef1f6; color: #4a5568; } .b-planerat { background: #fdf3e2; color: #8a5a0b; }
.b-pagar { background: #e5f4ec; color: #1f6f45; } .b-klart { background: #e8eefb; color: #2b4ea2; } .b-fakturerat { background: #efe9f8; color: #5b3a96; }

form .grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; }
form .full { grid-column: 1 / -1; }
@media (max-width: 560px) { form .grid { grid-template-columns: 1fr; } }
label { display: grid; gap: 5px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
input, select, textarea { padding: 11px 12px; border-radius: 10px; border: 1px solid var(--line); background: #fff; font-weight: 400; width: 100%; }
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: transparent; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--ink); }
.check input { width: auto; }
.hint { font-size: 13px; color: var(--ink-2); font-weight: 400; }
.actions { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.err { color: var(--bad); font-weight: 600; min-height: 1.2em; margin-top: 10px; }

/* Inloggning */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.auth .card { width: 100%; max-width: 420px; padding: 28px; }
.auth .brand { color: var(--ink); padding: 0 0 6px; font-size: 26px; }
.auth p.lead { color: var(--ink-2); margin: 0 0 20px; }
.auth form { display: grid; gap: 12px; }
.auth .switch { margin-top: 14px; text-align: center; font-size: 14px; color: var(--ink-2); }

.kv { display: grid; grid-template-columns: 160px 1fr; gap: 8px 14px; font-size: 15px; }
.kv dt { color: var(--ink-2); } .kv dd { margin: 0; }
@media (max-width: 560px) { .kv { grid-template-columns: 1fr; } .kv dd { margin-bottom: 6px; } }

#toast { position: fixed; left: 50%; bottom: calc(var(--nav-h) + 20px); transform: translateX(-50%); background: var(--ink); color: #fff;
         padding: 10px 16px; border-radius: 10px; opacity: 0; transition: opacity .2s; pointer-events: none; z-index: 20; }
#toast.show { opacity: 1; }
.notice { background: #fff8ea; border: 1px solid #f1d9a6; border-radius: var(--r); padding: 12px 14px; margin-bottom: 14px; }

/* ---------- Teman (förslag) ---------- */
/* A: Verkstad – mörk marin + signalorange (standard ovan, lite skarpare) */
[data-theme="verkstad"] { --bg:#f3f1ec; --ink:#16202c; --accent:#ec6a1e; --side:#16202c; --side-ink:#c9d1db; --r:10px; }

/* B: Byggplats – svart + varningsgul, kantigt, kraftigt */
[data-theme="byggplats"] { --bg:#f2f2ef; --card:#fff; --ink:#111; --ink-2:#55595e; --line:#d9d9d4; --accent:#ffc400; --accent-ink:#111;
  --side:#111; --side-ink:#bdbdb8; --r:4px; }
[data-theme="byggplats"] h1 { text-transform: uppercase; letter-spacing: .02em; font-weight: 900; }
[data-theme="byggplats"] .btn { text-transform: uppercase; letter-spacing: .04em; font-weight: 900; }
[data-theme="byggplats"] .side { background-image: repeating-linear-gradient(135deg, #111 0 14px, #1b1b1b 14px 28px); }
[data-theme="byggplats"] .row { border-left: 5px solid var(--accent); }
[data-theme="byggplats"] .brand span { color: var(--accent); }

/* C: Skog – skandinaviskt, skogsgrön + sand, mjukt */
[data-theme="skog"] { --bg:#f4f1ea; --card:#fffdf8; --ink:#1e2b26; --ink-2:#5f6b65; --line:#e3ddd0; --accent:#2f6b53; --accent-ink:#fff;
  --side:#1f3a30; --side-ink:#c8d6cf; --r:18px; }
[data-theme="skog"] .btn { border-radius: 999px; }
[data-theme="skog"] .brand span { color: #e9b872; }
[data-theme="skog"] .chip.on { background: var(--accent); border-color: var(--accent); }

[data-theme] .side { background-color: var(--side); }
[data-theme] .nav a { color: var(--side-ink); }
[data-theme] input:focus, [data-theme] select:focus, [data-theme] textarea:focus { outline-color: var(--accent); }

/* ---------- Byggplats v2: grafiska element (subtila) ---------- */
.top h1 { flex: 1; min-width: 0; overflow-wrap: break-word; hyphens: auto; -webkit-hyphens: auto; }
.top .btn { flex-shrink: 0; }
@media (max-width: 560px) { h1 { font-size: 21px; } [data-theme="byggplats"] h1 { font-size: 19px; } }

[data-theme="byggplats"] body {
  background:
    linear-gradient(162deg, transparent 0 58%, rgba(255,196,0,.10) 58% 72%, rgba(17,17,17,.035) 72% 100%) fixed,
    var(--bg);
}
/* varningsrand överst i innehållet */
[data-theme="byggplats"] main { position: relative; }
[data-theme="byggplats"] main::before {
  content: ""; display: block; height: 6px; margin: -24px -24px 22px; 
  background: repeating-linear-gradient(135deg, var(--accent) 0 12px, #111 12px 24px);
}
@media (max-width: 760px) { [data-theme="byggplats"] main::before { margin: -16px -16px 16px; } }
/* sned gul markering bakom sidrubriken */
[data-theme="byggplats"] .top h1 { position: relative; padding-left: 16px; }
[data-theme="byggplats"] .top h1::before {
  content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 7px; background: var(--accent);
  transform: skewX(-14deg);
}
/* sektionsrubriker: diskret text i accentfärg med tunn linje */
[data-theme="byggplats"] h2 {
  display: inline-block; background: #111; color: var(--accent); padding: 6px 26px 6px 12px; font-size: 13px;
  clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 100%, 0 100%); letter-spacing: .1em;
}
/* kort med avskuret hörn */
[data-theme="byggplats"] .card, [data-theme="byggplats"] .row {
  clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%);
}
[data-theme="byggplats"] .row { border-left-width: 6px; }
/* sidomenyn: diagonal gul kil nederst */
@media (min-width: 761px) { [data-theme="byggplats"] .side { position: relative; overflow: hidden; } }
[data-theme="byggplats"] .side::after {
  content: ""; position: absolute; left: -40px; right: -40px; bottom: -60px; height: 140px; background: var(--accent);
  transform: skewY(-12deg); opacity: .9; pointer-events: none;
}
[data-theme="byggplats"] .side .who { position: relative; z-index: 1; color: #111; font-weight: 700; }
@media (max-width: 760px) {
  [data-theme="byggplats"] .side::after { display: none; }
  [data-theme="byggplats"] .side { border-top: 4px solid var(--accent); }
  [data-theme="byggplats"] .nav a.on { background: var(--accent); color: #111; }
}
[data-theme="byggplats"] .nav a.on { background: var(--accent); color: #111; }
/* inloggning */
[data-theme="byggplats"] .auth { background: linear-gradient(160deg, #111 0 38%, var(--accent) 38% 44%, transparent 44%); }
[data-theme="byggplats"] .chip.on { background: #111; color: var(--accent); }
[data-theme="byggplats"] .badge { border-radius: 3px; }

/* ---------- Grafit: seriöst och lugnt, med subtila bågar ---------- */
[data-theme="grafit"] {
  --bg: #f6f5f2; --card: #fff; --ink: #18202b; --ink-2: #5d6673; --line: #e6e3dd;
  --accent: #b8612f; --accent-ink: #fff; --side: #18202b; --side-ink: #b9c1cc; --r: 14px;
  font-feature-settings: "ss01", "cv11";
}
[data-theme="grafit"] body {
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='900' height='900' viewBox='0 0 900 900' fill='none' stroke='%23b8612f' stroke-opacity='.10'%3E%3Ccircle cx='900' cy='0' r='300'/%3E%3Ccircle cx='900' cy='0' r='420'/%3E%3Ccircle cx='900' cy='0' r='540'/%3E%3Ccircle cx='900' cy='0' r='660'/%3E%3Ccircle cx='900' cy='0' r='780'/%3E%3C/svg%3E") no-repeat right top / 900px 900px fixed,
    radial-gradient(1200px 700px at 110% -10%, rgba(184,97,47,.07), transparent 60%) fixed,
    var(--bg);
}
[data-theme="grafit"] h1 { font-weight: 750; letter-spacing: -.02em; }
[data-theme="grafit"] h2 { font-size: 12px; letter-spacing: .12em; color: var(--ink-2); font-weight: 700; }
[data-theme="grafit"] .btn { border-radius: 10px; box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 4px 14px rgba(184,97,47,.22); }
[data-theme="grafit"] .btn.sec, [data-theme="grafit"] .btn.link { box-shadow: none; }
[data-theme="grafit"] .card, [data-theme="grafit"] .row { border-color: transparent; box-shadow: 0 1px 2px rgba(24,32,43,.05), 0 6px 20px rgba(24,32,43,.05); }
[data-theme="grafit"] .row:hover { box-shadow: 0 2px 4px rgba(24,32,43,.06), 0 10px 28px rgba(24,32,43,.08); }
[data-theme="grafit"] .search, [data-theme="grafit"] input, [data-theme="grafit"] select, [data-theme="grafit"] textarea { border-color: #e2ded6; }
[data-theme="grafit"] .chip { border-color: #e2ded6; }
[data-theme="grafit"] .chip.on { background: var(--ink); border-color: var(--ink); }
[data-theme="grafit"] .brand span { color: #e09a6b; }
[data-theme="grafit"] .badge { font-weight: 650; }
/* sidomeny med en svag båge */
[data-theme="grafit"] .side {
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='400' height='400' viewBox='0 0 400 400' fill='none' stroke='%23ffffff' stroke-opacity='.06'%3E%3Ccircle cx='0' cy='400' r='160'/%3E%3Ccircle cx='0' cy='400' r='230'/%3E%3Ccircle cx='0' cy='400' r='300'/%3E%3C/svg%3E") no-repeat left bottom / 400px 400px,
    var(--side);
}
[data-theme="grafit"] .nav a.on { background: rgba(255,255,255,.08); color: #fff; box-shadow: inset 3px 0 0 #e09a6b; }
@media (max-width: 760px) { [data-theme="grafit"] .nav a.on { box-shadow: inset 0 3px 0 #e09a6b; } }
/* inloggning */
[data-theme="grafit"] .auth {
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1200' height='1200' viewBox='0 0 1200 1200' fill='none' stroke='%23ffffff' stroke-opacity='.07'%3E%3Ccircle cx='1200' cy='0' r='380'/%3E%3Ccircle cx='1200' cy='0' r='520'/%3E%3Ccircle cx='1200' cy='0' r='660'/%3E%3Ccircle cx='1200' cy='0' r='800'/%3E%3Ccircle cx='1200' cy='0' r='940'/%3E%3C/svg%3E") no-repeat right top / 1200px,
    radial-gradient(900px 600px at 100% 0%, rgba(224,154,107,.18), transparent 60%), #18202b;
}
[data-theme="grafit"] .auth .card { border: 0; box-shadow: 0 30px 80px rgba(0,0,0,.35); }

/* ---------- Nord: sval, ljus, indigo + mjuk våg ---------- */
[data-theme="nord"] { --bg:#f3f5f9; --card:#fff; --ink:#141a2e; --ink-2:#5a6480; --line:#e1e6f0; --accent:#4f46e5; --accent-ink:#fff;
  --side:#ffffff; --side-ink:#4a5470; --r:14px; }
[data-theme="nord"] body { background:
  radial-gradient(900px 500px at 85% -5%, rgba(79,70,229,.14), transparent 60%) fixed,
  radial-gradient(700px 500px at -10% 110%, rgba(56,189,248,.12), transparent 60%) fixed, var(--bg); }
[data-theme="nord"] .side { border-right: 1px solid var(--line); }
[data-theme="nord"] .brand { color: var(--ink); } [data-theme="nord"] .brand span { color: var(--accent); }
[data-theme="nord"] .side .who { color: var(--ink-2); }
[data-theme="nord"] .nav a.on { background: #eef0ff; color: var(--accent); }
[data-theme="nord"] .card, [data-theme="nord"] .row { border-color: transparent; box-shadow: 0 1px 2px rgba(20,26,46,.04), 0 8px 24px rgba(20,26,46,.06); }
[data-theme="nord"] .chip.on { background: var(--accent); border-color: var(--accent); }
[data-theme="nord"] .auth { background: radial-gradient(800px 500px at 80% 0%, rgba(79,70,229,.25), transparent 60%), radial-gradient(600px 400px at 0% 100%, rgba(56,189,248,.2), transparent 60%), #f3f5f9; }
@media (max-width:760px){ [data-theme="nord"] .side { border-right:0; border-top:1px solid var(--line); } }

/* ---------- Midnatt: mörkt läge, turkos glöd ---------- */
[data-theme="midnatt"] { --bg:#0e131d; --card:#161d2a; --ink:#e8edf5; --ink-2:#93a0b4; --line:#253045; --accent:#2dd4bf; --accent-ink:#06231f;
  --side:#0a0e16; --side-ink:#93a0b4; --r:14px; color-scheme: dark; }
[data-theme="midnatt"] body { background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='900' height='900' fill='none' stroke='%232dd4bf' stroke-opacity='.08'%3E%3Ccircle cx='900' cy='0' r='320'/%3E%3Ccircle cx='900' cy='0' r='460'/%3E%3Ccircle cx='900' cy='0' r='600'/%3E%3C/svg%3E") no-repeat right top / 900px fixed,
  radial-gradient(900px 600px at 100% 0%, rgba(45,212,191,.10), transparent 60%) fixed, var(--bg); }
[data-theme="midnatt"] input, [data-theme="midnatt"] select, [data-theme="midnatt"] textarea, [data-theme="midnatt"] .search, [data-theme="midnatt"] .chip, [data-theme="midnatt"] .btn.sec { background:#111827; border-color: var(--line); color: var(--ink); }
[data-theme="midnatt"] .chip.on { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
[data-theme="midnatt"] .nav a.on { background: rgba(45,212,191,.12); color: var(--accent); }
[data-theme="midnatt"] .badge { background: rgba(255,255,255,.08) !important; color: var(--ink) !important; }
[data-theme="midnatt"] .b-pagar { color: #5eead4 !important; } [data-theme="midnatt"] .b-planerat { color: #fcd34d !important; }
[data-theme="midnatt"] .notice { background:#1f2a1f; border-color:#2f4a3a; }
[data-theme="midnatt"] .auth { background: radial-gradient(800px 500px at 100% 0%, rgba(45,212,191,.18), transparent 60%), var(--bg); }

/* ---------- Redaktion: varm papper, serif-rubriker, tegel ---------- */
[data-theme="redaktion"] { --bg:#f7f2ea; --card:#fffdf9; --ink:#22201c; --ink-2:#6b6358; --line:#e7dfd2; --accent:#b4432b; --accent-ink:#fff;
  --side:#22201c; --side-ink:#cfc6b8; --r:6px; }
[data-theme="redaktion"] h1, [data-theme="redaktion"] .brand, [data-theme="redaktion"] .row .t { font-family: "Iowan Old Style", "Palatino Linotype", Georgia, serif; }
[data-theme="redaktion"] h1 { font-weight: 600; font-size: 28px; letter-spacing: -.01em; }
[data-theme="redaktion"] .brand span { color: #e08a72; }
[data-theme="redaktion"] body { background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1000' height='600' fill='none' stroke='%23b4432b' stroke-opacity='.10'%3E%3Cpath d='M0 520 C 300 380, 650 640, 1000 420'/%3E%3Cpath d='M0 560 C 300 420, 650 680, 1000 460'/%3E%3C/svg%3E") no-repeat center bottom / 100% auto fixed, var(--bg); }
[data-theme="redaktion"] .row, [data-theme="redaktion"] .card { box-shadow: none; }
[data-theme="redaktion"] h2 { border-bottom: 1px solid var(--line); padding-bottom: 6px; }
[data-theme="redaktion"] .chip.on { background: var(--accent); border-color: var(--accent); }
[data-theme="redaktion"] .nav a.on { background: rgba(255,255,255,.08); color:#fff; box-shadow: inset 3px 0 0 #e08a72; }
[data-theme="redaktion"] .auth { background: var(--ink); }
@media (max-width:760px){ [data-theme="redaktion"] h1 { font-size: 23px; } [data-theme="redaktion"] .nav a.on { box-shadow: inset 0 3px 0 #e08a72; } }

/* ---------- Plommon: vitt, djup plommon, mjuk lila båge ---------- */
[data-theme="plommon"] { --bg:#faf8fc; --card:#fff; --ink:#24152f; --ink-2:#6d5f7a; --line:#ece6f2; --accent:#6b2fa3; --accent-ink:#fff;
  --side:#2a1838; --side-ink:#cbbcd9; --r:16px; }
[data-theme="plommon"] body { background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1400' height='500' viewBox='0 0 1400 500'%3E%3Cpath d='M0 330 C 350 180, 700 470, 1400 230 L1400 0 L0 0Z' fill='%236b2fa3' fill-opacity='.05'/%3E%3Cpath d='M0 260 C 420 120, 800 400, 1400 160' fill='none' stroke='%236b2fa3' stroke-opacity='.12'/%3E%3C/svg%3E") no-repeat center top / 100% auto, var(--bg); }
[data-theme="plommon"] .btn { border-radius: 999px; }
[data-theme="plommon"] .card, [data-theme="plommon"] .row { border-color: transparent; box-shadow: 0 1px 2px rgba(36,21,47,.04), 0 8px 26px rgba(107,47,163,.07); }
[data-theme="plommon"] .chip.on { background: var(--accent); border-color: var(--accent); }
[data-theme="plommon"] .brand span { color: #d5a6ff; }
[data-theme="plommon"] .nav a.on { background: rgba(213,166,255,.14); color:#fff; }
[data-theme="plommon"] .auth { background: radial-gradient(900px 500px at 90% 0%, rgba(213,166,255,.35), transparent 60%), #2a1838; }

/* ======================= Omgång 3 ======================= */
/* gemensamt för glas-teman */
[data-glass] .card, [data-glass] .row { background: rgba(255,255,255,.72); backdrop-filter: blur(16px) saturate(140%); -webkit-backdrop-filter: blur(16px) saturate(140%);
  border: 1px solid rgba(255,255,255,.6); box-shadow: 0 8px 30px rgba(20,20,40,.08); }
[data-glass] .search, [data-glass] .chip { background: rgba(255,255,255,.7); border-color: rgba(255,255,255,.7); backdrop-filter: blur(10px); }

/* 1 Aurora: mörk marin med mjuka norrskensfält, glaskort */
[data-theme="aurora"] { --bg:#0b1020; --ink:#eef2ff; --ink-2:#a9b3d1; --line:rgba(255,255,255,.12); --accent:#8b7cf6; --accent-ink:#fff;
  --side:rgba(10,14,30,.55); --side-ink:#b9c2e0; --r:16px; color-scheme: dark; }
[data-theme="aurora"] body { background:
  radial-gradient(40vw 40vw at 85% 5%, rgba(139,124,246,.45), transparent 70%),
  radial-gradient(45vw 35vw at 10% 30%, rgba(34,211,238,.25), transparent 70%),
  radial-gradient(50vw 40vw at 60% 100%, rgba(236,72,153,.22), transparent 70%), #0b1020; background-attachment: fixed; }
[data-theme="aurora"] .card, [data-theme="aurora"] .row { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.10);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); box-shadow: 0 10px 40px rgba(0,0,0,.25); }
[data-theme="aurora"] .side { backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-right: 1px solid rgba(255,255,255,.08); }
[data-theme="aurora"] input, [data-theme="aurora"] select, [data-theme="aurora"] textarea, [data-theme="aurora"] .search, [data-theme="aurora"] .chip, [data-theme="aurora"] .btn.sec
  { background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.14); color: var(--ink); }
[data-theme="aurora"] .chip.on { background: #fff; color: #0b1020; }
[data-theme="aurora"] .btn { background: linear-gradient(135deg, #8b7cf6, #22d3ee); box-shadow: 0 8px 24px rgba(139,124,246,.35); }
[data-theme="aurora"] .badge { background: rgba(255,255,255,.12) !important; color: #fff !important; }
[data-theme="aurora"] .brand span { background: linear-gradient(90deg,#a78bfa,#22d3ee); -webkit-background-clip: text; color: transparent; }
[data-theme="aurora"] .nav a.on { background: rgba(255,255,255,.10); color: #fff; }
[data-theme="aurora"] .auth .card { background: rgba(255,255,255,.08); }
[data-theme="aurora"] .auth .brand { color: #fff; }
[data-theme="aurora"] .row .s { color: var(--ink-2); }

/* 2 Topografi: varmt ljust med höjdkurvor, grafit-meny */
[data-theme="topo"] { --bg:#f4f1ec; --card:#fff; --ink:#1b222c; --ink-2:#5d6673; --line:#e5e0d8; --accent:#c0602c; --accent-ink:#fff;
  --side:#1b222c; --side-ink:#b9c1cc; --r:14px; }
[data-theme="topo"] body { background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='600' viewBox='0 0 600 600' fill='none' stroke='%23c0602c' stroke-opacity='.13' stroke-width='1.2'%3E%3Cpath d='M-20 120 C 80 60 160 180 260 120 S 460 40 620 110'/%3E%3Cpath d='M-20 150 C 90 95 170 210 270 150 S 470 75 620 140'/%3E%3Cpath d='M-20 180 C 100 130 180 240 280 180 S 480 110 620 170'/%3E%3Cpath d='M-20 360 C 60 300 200 420 300 350 S 500 300 620 380'/%3E%3Cpath d='M-20 390 C 70 335 210 450 310 380 S 510 335 620 410'/%3E%3Cpath d='M-20 420 C 80 370 220 480 320 410 S 520 370 620 440'/%3E%3Cpath d='M-20 450 C 90 405 230 510 330 440 S 530 405 620 470'/%3E%3Cellipse cx='470' cy='250' rx='60' ry='34'/%3E%3Cellipse cx='470' cy='250' rx='100' ry='58'/%3E%3Cellipse cx='470' cy='250' rx='140' ry='82'/%3E%3Cellipse cx='120' cy='560' rx='50' ry='26'/%3E%3Cellipse cx='120' cy='560' rx='90' ry='48'/%3E%3C/svg%3E") repeat 0 0 / 600px fixed,
  radial-gradient(900px 600px at 100% 0%, rgba(192,96,44,.10), transparent 60%) fixed, var(--bg); }
[data-theme="topo"] .card, [data-theme="topo"] .row { border-color: transparent; box-shadow: 0 1px 2px rgba(27,34,44,.05), 0 10px 28px rgba(27,34,44,.07); }
[data-theme="topo"] .chip.on { background: var(--ink); border-color: var(--ink); }
[data-theme="topo"] .brand span { color: #e5935f; }
[data-theme="topo"] .nav a.on { background: rgba(255,255,255,.08); color:#fff; box-shadow: inset 3px 0 0 #e5935f; }
[data-theme="topo"] .btn { box-shadow: 0 6px 18px rgba(192,96,44,.28); } [data-theme="topo"] .btn.sec { box-shadow:none; }
[data-theme="topo"] .auth { background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='600' viewBox='0 0 600 600' fill='none' stroke='%23ffffff' stroke-opacity='.07' stroke-width='1.2'%3E%3Cpath d='M-20 120 C 80 60 160 180 260 120 S 460 40 620 110'/%3E%3Cpath d='M-20 150 C 90 95 170 210 270 150 S 470 75 620 140'/%3E%3Cpath d='M-20 180 C 100 130 180 240 280 180 S 480 110 620 170'/%3E%3Cpath d='M-20 360 C 60 300 200 420 300 350 S 500 300 620 380'/%3E%3Cpath d='M-20 390 C 70 335 210 450 310 380 S 510 335 620 410'/%3E%3Cellipse cx='470' cy='250' rx='60' ry='34'/%3E%3Cellipse cx='470' cy='250' rx='100' ry='58'/%3E%3Cellipse cx='470' cy='250' rx='140' ry='82'/%3E%3C/svg%3E") repeat 0 0 / 600px,
  radial-gradient(700px 500px at 100% 0%, rgba(229,147,95,.22), transparent 60%), #1b222c; }
@media (max-width:760px){ [data-theme="topo"] .nav a.on { box-shadow: inset 0 3px 0 #e5935f; } }

/* 3 Skymning: persika → lavendel, glaskort */
[data-theme="skymning"] { --bg:#f7efe9; --ink:#2a2238; --ink-2:#6f6680; --line:rgba(42,34,56,.10); --accent:#3b2d5c; --accent-ink:#fff;
  --side:rgba(255,255,255,.55); --side-ink:#4b4160; --r:18px; }
[data-theme="skymning"] body { background:
  radial-gradient(60vw 50vw at 0% 0%, #ffd8c2 0, transparent 60%),
  radial-gradient(60vw 60vw at 100% 20%, #e3d4ff 0, transparent 60%),
  radial-gradient(60vw 50vw at 50% 110%, #ffe9d6 0, transparent 60%), #f6eef3; background-attachment: fixed; }
[data-theme="skymning"] .side { backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-right: 1px solid rgba(255,255,255,.7); }
[data-theme="skymning"] .brand { color: var(--ink); } [data-theme="skymning"] .brand span { color: #c2547a; }
[data-theme="skymning"] .side .who { color: var(--ink-2); }
[data-theme="skymning"] .nav a.on { background: rgba(255,255,255,.75); color: var(--ink); box-shadow: 0 4px 14px rgba(59,45,92,.12); }
[data-theme="skymning"] .btn { border-radius: 999px; }
[data-theme="skymning"] .chip.on { background: var(--accent); border-color: var(--accent); color:#fff; }
[data-theme="skymning"] .auth .card { background: rgba(255,255,255,.65); backdrop-filter: blur(20px); }
@media (max-width:760px){ [data-theme="skymning"] .side { border-right:0; border-top:1px solid rgba(255,255,255,.7); } }

/* 4 Linjer: vitt, precis, med en stor koppar-båge och prickrutnät */
[data-theme="linjer"] { --bg:#fbfbfa; --card:#fff; --ink:#111418; --ink-2:#626a75; --line:#e7e8ea; --accent:#111418; --accent-ink:#fff;
  --side:#fbfbfa; --side-ink:#4b525c; --r:12px; }
[data-theme="linjer"] body { background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1600' height='1000' viewBox='0 0 1600 1000' fill='none'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' x2='1'%3E%3Cstop offset='0' stop-color='%23d97745' stop-opacity='0'/%3E%3Cstop offset='.5' stop-color='%23d97745' stop-opacity='.55'/%3E%3Cstop offset='1' stop-color='%23f2b07e' stop-opacity='0'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M-100 900 C 400 200, 1100 100, 1700 450' stroke='url(%23g)' stroke-width='60' stroke-linecap='round' opacity='.35'/%3E%3Cpath d='M-100 940 C 420 260, 1120 160, 1700 500' stroke='%23d97745' stroke-opacity='.25' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat center / cover fixed,
  radial-gradient(#d9dbde 1px, transparent 1.2px) 0 0 / 22px 22px fixed, var(--bg); }
[data-theme="linjer"] .side { border-right: 1px solid var(--line); }
[data-theme="linjer"] .brand { color: var(--ink); } [data-theme="linjer"] .brand span { color: #d97745; }
[data-theme="linjer"] .side .who { color: var(--ink-2); }
[data-theme="linjer"] .nav a.on { background: #111418; color: #fff; }
[data-theme="linjer"] .card, [data-theme="linjer"] .row { box-shadow: 0 1px 0 rgba(17,20,24,.04); }
[data-theme="linjer"] .row:hover { border-color: #111418; }
[data-theme="linjer"] .chip.on { background: #111418; border-color:#111418; }
[data-theme="linjer"] .btn { box-shadow: 0 6px 16px rgba(17,20,24,.18); } [data-theme="linjer"] .btn.sec{box-shadow:none;}
@media (max-width:760px){ [data-theme="linjer"] .side { border-right:0; border-top:1px solid var(--line); background: rgba(251,251,250,.92); backdrop-filter: blur(10px); } }

/* 5 Djuphav: mörkblått sidhuvud med vågor, ljust innehåll som överlappar */
[data-theme="djuphav"] { --bg:#eef3f6; --card:#fff; --ink:#0f2233; --ink-2:#56697a; --line:#dde6ec; --accent:#0e7490; --accent-ink:#fff;
  --side:#0b1d2c; --side-ink:#a7bccb; --r:14px; }
[data-theme="djuphav"] body { background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1440' height='320' viewBox='0 0 1440 320' preserveAspectRatio='none'%3E%3Cpath d='M0 0h1440v210c-240 60-480-50-720 0S240 270 0 220Z' fill='%230b1d2c'/%3E%3Cpath d='M0 0h1440v170c-260 70-500-40-740 10S220 230 0 180Z' fill='%23123a52'/%3E%3Cpath d='M0 0h1440v120c-300 60-520-30-760 15S200 170 0 130Z' fill='%23175d78' fill-opacity='.85'/%3E%3C/svg%3E") no-repeat top / 100% 260px,
  var(--bg); }
[data-theme="djuphav"] .top h1 { color: #fff; }
[data-theme="djuphav"] .card, [data-theme="djuphav"] .row { border-color: transparent; box-shadow: 0 2px 4px rgba(15,34,51,.04), 0 12px 30px rgba(15,34,51,.08); }
[data-theme="djuphav"] .btn { background: #22d3ee; color: #062430; } [data-theme="djuphav"] .btn.sec { background:#fff; color: var(--ink); }
[data-theme="djuphav"] .chip { background: rgba(255,255,255,.9); }
[data-theme="djuphav"] .chip.on { background: #22d3ee; color:#062430; border-color:#22d3ee; }
[data-theme="djuphav"] .brand span { color: #5eead4; }
[data-theme="djuphav"] .nav a.on { background: rgba(94,234,212,.12); color: #fff; }
[data-theme="djuphav"] .auth { background: linear-gradient(180deg, #0b1d2c, #175d78); }

/* =================== STUDIO: plant, kantigt, lager av sneda färgfält =================== */
.eyebrow { display: none; }
.kpis { display: none; }
.mark { display: none; }

[data-theme="studio"] {
  --ink:#14202b; --ink-2:#4a5563; --ink-3:#8a93a0; --line:#e4e7ec; --bg:#f5f6f8; --card:#fff; --soft:#f7f8fa;
  --accent:#d9622b; --accent-2:#f29a62; --accent-ink:#fff; --r:16px;
  --mint:#12a37a; --mint-bg:#e3f6ef; --amber:#e8a019; --amber-bg:#fff4dd; --blue:#3b6fe0; --blue-bg:#e9efff; --slate:#64748b; --slate-bg:#eef1f5;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased;
}
[data-theme="studio"][data-palette="smaragd"] { --ink:#0d2421; --accent:#0f9d76; --accent-2:#6ed3b3; }
[data-theme="studio"][data-palette="indigo"]  { --ink:#16142e; --accent:#5b45d6; --accent-2:#a594ff; }
[data-theme="studio"][data-palette="karmin"]  { --ink:#1d1418; --accent:#c8304a; --accent-2:#f07f8f; }

[data-theme="studio"] body { background: var(--bg); color: var(--ink); }
[data-theme="studio"] main { padding: 0 32px 40px; max-width: 1080px; }

/* sidomeny */
[data-theme="studio"] .side { background: var(--ink); }
@media (min-width: 761px) { [data-theme="studio"] .side { position: relative; overflow: hidden; } }
[data-theme="studio"] .side::after { content:""; position:absolute; left:-30%; bottom:-6%; width:90%; height:34%; background: var(--accent);
  clip-path: polygon(0 40%, 100% 0, 70% 100%, 0 100%); opacity:.95; pointer-events:none; }
[data-theme="studio"] .side::before { content:""; position:absolute; left:-10%; bottom:-6%; width:70%; height:24%; background: var(--accent-2);
  clip-path: polygon(20% 55%, 100% 20%, 85% 100%, 0 100%); opacity:.9; pointer-events:none; z-index:1; }
[data-theme="studio"] .side .who { position: relative; z-index: 2; color: #fff; font-weight: 600; }
[data-theme="studio"] .brand { display:flex; align-items:center; gap:0; font-weight:800; letter-spacing:-.02em; color:#fff; }
[data-theme="studio"] .brand span { color: var(--accent-2); }
[data-theme="studio"] .mark { display:inline-block; margin-right:10px; width:28px; height:28px; border-radius:8px; background: var(--accent); position:relative; overflow:hidden; flex:none; }
[data-theme="studio"] .mark::after { content:""; position:absolute; inset:0; background: var(--accent-2); clip-path: polygon(55% 0,100% 0,100% 100%,20% 100%); }
[data-theme="studio"] .nav a { color:#b8c0cb; border-radius:10px; position:relative; }
[data-theme="studio"] .nav a.on { background: rgba(255,255,255,.08); color:#fff; }
[data-theme="studio"] .nav a.on::before { content:""; position:absolute; left:0; top:8px; bottom:8px; width:4px; border-radius:4px; background: var(--accent); }

/* sidhuvud: mörkt band med sneda färgfält */
[data-theme="studio"] .top {
  margin: 0 -32px 0; padding: 34px 32px 76px; background: var(--ink); color:#fff; position: relative; overflow: hidden; align-items: flex-end;
}
[data-theme="studio"] .top::before { content:""; position:absolute; top:0; bottom:0; right:-3%; width:34%; background: var(--accent);
  clip-path: polygon(38% 0,100% 0,100% 100%,0 100%); }
[data-theme="studio"] .top::after { content:""; position:absolute; top:0; bottom:0; right:-3%; width:17%; background: var(--accent-2); opacity:.9;
  clip-path: polygon(58% 0,100% 0,100% 100%,14% 100%); }
[data-theme="studio"] .top > * { position: relative; z-index: 1; }
[data-theme="studio"] .top h1 { color:#fff; font-size: 34px; font-weight: 800; letter-spacing: -.025em; line-height: 1.1; }
[data-theme="studio"] .eyebrow { display:block; font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--accent-2); margin-bottom: 8px; }
[data-theme="studio"] .top .btn { background:#fff; color: var(--ink); box-shadow: 0 10px 30px rgba(0,0,0,.25); }
[data-theme="studio"] .top .btn.sec { background: rgba(255,255,255,.12); color:#fff; border: 1.5px solid rgba(255,255,255,.3); box-shadow:none; }
/* innehållet lyfts upp över bandet */
[data-theme="studio"] .top + * { margin-top: -44px; position: relative; z-index: 2; }
[data-theme="studio"] .top + .kpis + .search { margin-top: 18px; }

/* KPI-kort */
[data-theme="studio"] .kpis { display:grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 18px; }
[data-theme="studio"] .kpi { background:#fff; border-radius: var(--r); padding: 18px 18px 16px; border-top: 6px solid var(--c); text-decoration:none;
  box-shadow: 0 14px 34px rgba(20,32,43,.10); transition: transform .15s; }
[data-theme="studio"] .kpi:hover { transform: translateY(-2px); }
[data-theme="studio"] .kpi b { display:block; font-size: 38px; font-weight: 800; line-height: 1; color: var(--c); letter-spacing: -.03em; }
[data-theme="studio"] .kpi span { display:block; margin-top: 8px; font-size: 13.5px; font-weight: 600; color: var(--ink-2); }
.k-pagar { --c: var(--mint); } .k-planerat { --c: var(--amber); } .k-offert { --c: var(--blue); } .k-klart { --c: var(--accent); }

/* knappar & fält */
[data-theme="studio"] .btn { border-radius: 999px; padding: 12px 20px; font-weight: 700; background: var(--accent); color:#fff;
  box-shadow: 0 8px 22px color-mix(in srgb, var(--accent) 35%, transparent); }
[data-theme="studio"] .btn.sec { background:#fff; color: var(--ink); border: 1.5px solid var(--line); box-shadow:none; }
[data-theme="studio"] .btn.link { background:none; box-shadow:none; color: var(--ink-2); }
[data-theme="studio"] .search, [data-theme="studio"] input, [data-theme="studio"] select, [data-theme="studio"] textarea {
  border: 1.5px solid var(--line); border-radius: 12px; background: #fff; }
[data-theme="studio"] .search { box-shadow: 0 6px 20px rgba(20,32,43,.06); }
[data-theme="studio"] input:focus, [data-theme="studio"] select:focus, [data-theme="studio"] textarea:focus { outline: none; border-color: var(--accent); }
[data-theme="studio"] .chip { border: 1.5px solid var(--line); font-weight: 600; font-size: 13.5px; background:#fff; }
[data-theme="studio"] .chip.on { background: var(--ink); color:#fff; border-color: var(--ink); }

/* listor */
[data-theme="studio"] .row { border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; position: relative; overflow: hidden;
  box-shadow: 0 1px 2px rgba(20,32,43,.04); transition: box-shadow .15s, transform .15s; }
[data-theme="studio"] .row:hover { box-shadow: 0 12px 30px rgba(20,32,43,.10); transform: translateY(-1px); border-color: var(--line); }
[data-theme="studio"] .row::before { content:""; position:absolute; left:0; top:0; bottom:0; width:5px; background: var(--c, var(--line)); }
.r-pagar { --c: var(--mint); } .r-planerat { --c: var(--amber); } .r-offert { --c: var(--blue); } .r-klart { --c: var(--accent); } .r-fakturerat { --c: var(--slate); }
[data-theme="studio"] .row .t { font-weight: 700; font-size: 15.5px; }
[data-theme="studio"] .row .num { color: var(--ink-3); font-weight: 700; }
[data-theme="studio"] .row .s { color: var(--ink-2); }

/* status som sned tagg */
[data-theme="studio"] .badge { border-radius: 999px; padding: 4px 11px; font-size: 11.5px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color:#fff; }
[data-theme="studio"] .b-pagar { background: var(--mint); } [data-theme="studio"] .b-planerat { background: var(--amber); }
[data-theme="studio"] .b-offert { background: var(--blue); } [data-theme="studio"] .b-klart { background: var(--accent); }
[data-theme="studio"] .b-fakturerat { background: var(--slate); }

/* sektionsrubriker: diskret text i accentfärg med tunn linje */
[data-theme="studio"] h2 { display:flex; align-items:center; gap:10px; background:none; color: var(--accent); font-size: 12.5px; font-weight: 800; letter-spacing: .14em;
  text-transform: uppercase; padding: 0; margin: 30px 0 12px; }
[data-theme="studio"] h2::after { content:""; flex:1; height:1px; background: var(--line); }

/* kort */
[data-theme="studio"] .card { border: 1px solid var(--line); border-radius: var(--r); box-shadow: 0 14px 34px rgba(20,32,43,.08); padding: 22px; }
[data-theme="studio"] .kv dt { color: var(--ink-3); font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; padding-top: 3px; }
[data-theme="studio"] .kv dd { font-weight: 500; }
[data-theme="studio"] label { color: var(--ink-2); font-size: 13px; }
[data-theme="studio"] .notice { background: var(--amber-bg); border: 0; border-left: 4px solid var(--amber); border-radius: 10px; }
[data-theme="studio"] .empty { background:#fff; border:1px dashed var(--line); border-radius: var(--r); }

/* inloggning */
[data-theme="studio"] .auth { background: var(--ink); position: relative; overflow: hidden; }
[data-theme="studio"] .auth::before { content:""; position:absolute; top:0; bottom:0; right:-4%; width:42%; background: var(--accent); clip-path: polygon(36% 0,100% 0,100% 100%,0 100%); }
[data-theme="studio"] .auth::after { content:""; position:absolute; top:0; bottom:0; right:-4%; width:22%; background: var(--accent-2); opacity:.9; clip-path: polygon(55% 0,100% 0,100% 100%,15% 100%); }
[data-theme="studio"] .auth .card { position: relative; z-index: 1; border: 0; border-radius: 22px; box-shadow: 0 30px 80px rgba(0,0,0,.35); padding: 32px; }
[data-theme="studio"] .auth .brand { color: var(--ink); font-size: 24px; margin-bottom: 4px; }
[data-theme="studio"] .auth .brand span { color: var(--accent); }

/* mobil */
@media (max-width: 760px) {
  [data-theme="studio"] main { padding: 0 16px calc(var(--nav-h) + 24px); }
  [data-theme="studio"] .top { margin: 0 -16px; padding: 26px 16px 66px; }
  [data-theme="studio"] .top::before { width: 30%; } [data-theme="studio"] .top::after { width: 15%; }
  [data-theme="studio"] .top h1 { font-size: 26px; }
  [data-theme="studio"] .top .btn { padding: 10px 14px; font-size: 14px; }
  [data-theme="studio"] .kpis { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  [data-theme="studio"] .kpi { padding: 14px; } [data-theme="studio"] .kpi b { font-size: 30px; }
  [data-theme="studio"] .side::before, [data-theme="studio"] .side::after { display: none; }
  [data-theme="studio"] .side .brand { display: none; }
  [data-theme="studio"] .side { border-top: 3px solid var(--accent); }
  [data-theme="studio"] .nav a.on::before { left: 20%; right: 20%; top: 0; bottom: auto; width: auto; height: 3px; }
  [data-theme="studio"] .auth::before { width: 30%; } [data-theme="studio"] .auth::after { width: 16%; }
}
[data-theme="studio"][data-palette="ocean"]   { --ink:#0b1f33; --accent:#1479c9; --accent-2:#6cc2ff; }
[data-theme="studio"][data-palette="petrol"]  { --ink:#0a2328; --accent:#0e7c86; --accent-2:#5fc4c9; }
[data-theme="studio"][data-palette="kobolt"]  { --ink:#0c1440; --accent:#2747d9; --accent-2:#8aa0ff; }
[data-theme="studio"][data-palette="plommon"] { --ink:#221329; --accent:#8e3fa8; --accent-2:#d39be6; }
[data-theme="studio"][data-palette="korall"]  { --ink:#1b1e2e; --accent:#ef4f57; --accent-2:#ffa3a6; }
[data-theme="studio"][data-palette="guld"]    { --ink:#101a33; --accent:#b8892c; --accent-2:#ecd08f; }
[data-theme="studio"][data-palette="senap"]   { --ink:#1c1a14; --accent:#c99512; --accent-2:#f2d27a; }
[data-theme="studio"][data-palette="oliv"]    { --ink:#1b1f14; --accent:#66792a; --accent-2:#b6c96a; }
[data-theme="studio"][data-palette="skiffer"] { --ink:#1a1d22; --accent:#4b5563; --accent-2:#a3abb7; }

/* ---------- Offerter ---------- */
.linkbox { display: flex; gap: 8px; margin-top: 10px; }
.linkbox input { flex: 1; font-size: 13px; }
.line { display: grid; grid-template-columns: 110px 1fr 70px 64px 110px 96px 32px; gap: 6px; align-items: center; margin-bottom: 6px; }
.line input, .line select { padding: 9px 10px; }
.line .lsum { text-align: right; font-weight: 700; font-size: 14px; white-space: nowrap; }
.line .x { border: 0; background: none; font-size: 22px; line-height: 1; color: var(--ink-3, #999); cursor: pointer; }
@media (max-width: 760px) {
  .line { grid-template-columns: 1fr 1fr 1fr 32px; padding: 10px; background: var(--soft, #f7f8fa); border-radius: 12px; }
  .line [data-k=kind] { grid-column: 1 / 2; } .line [data-k=description] { grid-column: 2 / 4; }
  .line [data-k=qty] { grid-column: 1; } .line [data-k=unit] { grid-column: 2; } .line [data-k=price] { grid-column: 3; }
  .line .lsum { grid-column: 1 / 4; text-align: left; } .line .x { grid-row: 1; grid-column: 4; }
}
.sums { margin-top: 16px; display: grid; gap: 6px; max-width: 380px; margin-left: auto; font-size: 15px; }
.sums div { display: flex; justify-content: space-between; gap: 20px; }
.sums .big { font-size: 20px; font-weight: 800; border-top: 2px solid var(--ink); padding-top: 8px; }
.sums .rotline { color: var(--mint, #12a37a); font-weight: 700; }
table.qt { width: 100%; border-collapse: collapse; font-size: 15px; }
table.qt th { text-align: left; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3, #888); padding: 6px; border-bottom: 1px solid var(--line); }
table.qt td { padding: 11px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.qt td small { display: block; color: var(--ink-3, #888); font-size: 12px; }
table.qt .n { text-align: right; white-space: nowrap; }
@media (max-width: 560px) { table.qt th:nth-child(2), table.qt td:nth-child(2), table.qt th:nth-child(3), table.qt td:nth-child(3) { display: none; } }
.card.ai { margin-bottom: 16px; }
.aih { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.spark { background: var(--accent); color: #fff; font-size: 11px; font-weight: 800; letter-spacing: .1em; padding: 4px 10px; border-radius: 999px; }
.card.ai textarea { margin-top: 10px; min-height: 110px; }
.notice.ok { background: var(--mint-bg, #e3f6ef); border-left-color: var(--mint, #12a37a); }
.notice.bad { background: #fdecee; border-left-color: #d9474f; }
.notice { margin-bottom: 16px; }
[data-theme="studio"] .b-q-utkast { background: var(--slate); } [data-theme="studio"] .b-q-skickad { background: var(--amber); }
[data-theme="studio"] .b-q-godkand { background: var(--mint); } [data-theme="studio"] .b-q-avbojd { background: #d9474f; }
.r-q-utkast { --c: var(--slate); } .r-q-skickad { --c: var(--amber); } .r-q-godkand { --c: var(--mint); } .r-q-avbojd { --c: #d9474f; }
[data-theme="studio"] .top + .kpis + .chips { margin-top: 4px; }

/* ---------- Tid ---------- */
.clock { margin-bottom: 14px; }
.clockrow { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.clockrow label { min-width: 120px; }
.clockon { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.clockon .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--mint, #12a37a); box-shadow: 0 0 0 6px color-mix(in srgb, var(--mint, #12a37a) 20%, transparent); animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 10px transparent; } }
.weeknav { display: flex; justify-content: space-between; gap: 8px; margin: 6px 0 4px; flex-wrap: wrap; }
.row .tr { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; white-space: nowrap; }
.row .tr b { font-size: 16px; }
.r-t-new { --c: var(--amber, #e8a019); } .r-t-ok { --c: var(--mint, #12a37a); } .r-t-abs { --c: var(--slate, #64748b); }
.tcheck { cursor: pointer; } .tcheck input { width: 20px; height: 20px; margin-right: 4px; flex: none; accent-color: var(--accent); }
.tcheck > div:first-of-type { flex: 1; }
.actions.sticky { position: sticky; bottom: calc(var(--nav-h) + 12px); justify-content: flex-end; }
@media (min-width: 761px) { .actions.sticky { bottom: 16px; } }
.tstats { display: flex; gap: 28px; flex-wrap: wrap; }
.tstats b { display: block; font-size: 28px; font-weight: 800; color: var(--accent); line-height: 1; }
.tstats span { font-size: 13px; color: var(--ink-2); font-weight: 600; }

/* ---------- Steg 5–8 ---------- */
@media (max-width: 760px) { .nav a.desk { display: none; } }
.btn.small { padding: 6px 10px; font-size: 13px; min-height: 0; }
.plhead { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.plhead b { font-size: 18px; }
.present { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.present span { background: var(--soft, #f2f5f6); border-radius: 999px; padding: 6px 12px; font-weight: 600; font-size: 14px; }
.present small { font-weight: 400; color: var(--ink-2); }
.filter { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 10px; }
.filter label { margin: 0; }
.tablewrap { overflow-x: auto; padding: 8px 12px !important; }
table.qt td small { display: block; color: var(--ink-2); font-size: 12px; font-weight: 400; }
table.qt tr.old td { color: var(--ink-3, #9aa); text-decoration: line-through; text-decoration-color: rgba(0,0,0,.25); }
table.qt tr.old td small { text-decoration: none; }
table.log td { vertical-align: top; }
.go { color: var(--ink-2); font-weight: 700; }
button.row { width: 100%; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.checks { display: grid; gap: 10px; margin-bottom: 14px; }
.citem { background: var(--card, #fff); border: 1px solid var(--line); border-left: 5px solid var(--line); border-radius: 14px; padding: 14px 16px; display: grid; gap: 10px; }
.citem.c-ok { border-left-color: #2f9e6b; } .citem.c-ej_ok { border-left-color: #d0453a; } .citem.c-ej_aktuell { border-left-color: #a7b0b6; }
.ctext { font-weight: 600; } .cn { display: inline-block; min-width: 26px; color: var(--ink-2); font-weight: 800; }
.cres { display: flex; gap: 6px; flex-wrap: wrap; }
.citem.c-ej_ok .chip.on { background: #d0453a; border-color: #d0453a; }
.citem.c-ok .chip.on { background: #2f9e6b; border-color: #2f9e6b; }
.thumbs { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.thumb { position: relative; } .thumb img { width: 84px; height: 84px; object-fit: cover; border-radius: 10px; display: block; border: 1px solid var(--line); }
.thumb .x { position: absolute; top: -6px; right: -6px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: #111; color: #fff; cursor: pointer; line-height: 1; }
.addphoto { display: inline-flex; align-items: center; justify-content: center; width: 84px; height: 84px; border: 1.5px dashed var(--line); border-radius: 10px; cursor: pointer; font-weight: 600; font-size: 13px; color: var(--ink-2); margin: 0; }
.tline { grid-template-columns: 1fr 90px 32px !important; }
.iline { grid-template-columns: 110px 1fr 64px 58px 100px 80px 96px 32px; }
.iline .hrs:disabled { visibility: hidden; }
@media (max-width: 760px) {
  .tline { padding: 8px; }
  .iline .hrs { grid-column: 1 / 2; } .iline .lsum { grid-column: 2 / 4; text-align: right; }
}
.buyer { align-items: end; }
/* Tyck till-knapp och dialog (8 nov) */
.fb-btn { position: fixed; right: 18px; bottom: 18px; z-index: 40; border: 0; border-radius: 999px; padding: 10px 16px; font: inherit; font-size: 14px; font-weight: 600;
  background: var(--ink); color: #fff; box-shadow: 0 4px 14px rgba(0,0,0,.18); cursor: pointer; }
.fb-btn:hover { background: var(--accent); color: var(--accent-ink); }
@media (max-width: 760px) { .fb-btn { bottom: calc(var(--nav-h) + 12px + env(safe-area-inset-bottom)); right: 12px; padding: 8px 13px; font-size: 13px; }
  .shell main, [data-theme] .shell main { padding-bottom: calc(var(--nav-h) + 72px + env(safe-area-inset-bottom)); } }
.fb-dlg { border: 0; border-radius: 14px; padding: 22px; width: min(480px, calc(100vw - 32px)); background: var(--card); color: var(--ink); box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.fb-dlg::backdrop { background: rgba(15,20,30,.45); }
.fb-dlg h2 { margin: 0 0 6px; font-size: 19px; }
.fb-dlg textarea { width: 100%; box-sizing: border-box; }
.fb-mood { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
.fb-mood label { margin: 0; }
.fb-mood input { position: absolute; opacity: 0; pointer-events: none; }
.fb-mood span { display: inline-block; padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; font-size: 14px; }
.fb-mood input:checked + span { border-color: var(--accent); background: var(--accent); color: var(--accent-ink); }
.fb-mood input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.tbl { border-collapse: collapse; width: 100%; font-size: 13px; background: var(--card); }
.tbl th, .tbl td { padding: 7px 9px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.tbl tr.warnrow td { color: var(--bad); }
@media print {
  .fb-btn,
  .side, .top .btn, .actions, .addphoto, .thumb .x, #toast { display: none !important; }
  main { padding: 0 !important; } .citem { break-inside: avoid; }
  [data-theme] body, body { background: #fff !important; } main::before, main::after { display: none !important; }
}
@media (max-width: 560px) {
  table.qt.log th:nth-child(2), table.qt.log td:nth-child(2), table.qt.wide th, table.qt.wide td { display: table-cell; }
  table.qt.wide { min-width: 560px; font-size: 14px; }
}
main { min-width: 0; } .tablewrap { max-width: 100%; }
@media (max-width: 760px) {
  .iline { grid-template-columns: 1fr 1fr 1fr 32px; padding: 10px; background: var(--soft, #f7f8fa); border-radius: 12px; }
  .iline [data-k=kind] { grid-column: 1 / 2; } .iline [data-k=description] { grid-column: 2 / 4; }
  .iline [data-k=qty] { grid-column: 1; } .iline [data-k=unit] { grid-column: 2; } .iline [data-k=price] { grid-column: 3; }
  .iline .hrs { grid-column: 1 / 2; } .iline .lsum { grid-column: 2 / 4; text-align: right; } .iline .x { grid-row: 1; grid-column: 4; }
  .buyer { grid-template-columns: 1fr 1fr; }
}
/* Bildbank */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.ph { margin: 0; background: var(--card, #fff); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.ph.pf { border-color: #e0a526; box-shadow: 0 0 0 2px #e0a52655; }
.ph img { width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; }
.ph figcaption { display: flex; align-items: center; gap: 6px; padding: 8px; flex-wrap: wrap; }
.ph .star { border: 0; background: none; font-size: 22px; line-height: 1; cursor: pointer; color: #e0a526; padding: 0 2px; }
a.chip { text-decoration: none; color: inherit; display: inline-block; }
@media (max-width: 560px) { .linkbox { flex-wrap: wrap; } .linkbox input { flex: 1 1 100%; width: 100%; } }

/* Finputs 2 nov: konto-ruta, rollfärger, menytext, innerhörn */
.nav .ml { display: none; }
@media (max-width: 760px) { .nav .dl { display: none; } .nav .ml { display: inline; } }
.side .who { margin: 14px 0 12px; padding: 10px 12px; border-radius: 12px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08);
  display: flex; flex-direction: column; gap: 2px; text-decoration: none; font-size: 13px; line-height: 1.35; color: #c9d3d8; }
.side .who b { color: #fff; font-weight: 700; font-size: 13.5px; }
.side .who:hover { background: rgba(255,255,255,.1); }
[data-theme="studio"] .side .who { color: #c9d3d8; font-weight: 500; }
@media (max-width: 760px) { .side .who { display: none; } }
[data-theme="studio"] .badge.b-role { background: var(--ink-2, #3d4f55); }
[data-theme="studio"] .badge.b-role.r-owner { background: var(--accent); }
main { position: relative; }
main > .corner { display: none; }
@media (min-width: 761px) {
  [data-theme="studio"] main > .corner { display: block; position: absolute; left: 0; width: 22px; height: 22px; z-index: 1; pointer-events: none;
    background: radial-gradient(circle at 100% 100%, transparent 21.5px, var(--ink) 22px); }
}
details.card.ai > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 10px; }
details.card.ai > summary::-webkit-details-marker { display: none; }
details.card.ai > summary::after { content: "Visa ▾"; margin-left: auto; font-size: 13px; color: var(--ink-2); font-weight: 600; white-space: nowrap; }
details.card.ai[open] > summary::after { content: "Dölj ▴"; }
details.card.ai[open] > summary { margin-bottom: 8px; }
.card.soft { background: var(--soft, #f4f7f7); box-shadow: none; margin-top: 10px; }
code { background: rgba(0,0,0,.05); padding: 1px 5px; border-radius: 5px; font-size: 12.5px; }

/* Publika sidor */
.pub { min-height: 100vh; background: var(--bg); }
.pub .w { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.pub-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px max(20px, calc((100% - 1000px) / 2)); background: var(--ink); }
.pub-h .brand { color: #fff; text-decoration: none; font-size: 20px; padding: 0; margin: 0; line-height: 1; }
.pub-h nav { display: flex; gap: 14px; align-items: center; } .pub-h nav a:not(.btn) { color: #cfe3e6; text-decoration: none; font-weight: 600; }
.pub-hero { background: var(--ink); color: #fff; padding: 40px 0 90px; position: relative; overflow: hidden; }
.pub-hero::before { content: ""; position: absolute; top: 0; bottom: 0; right: -3%; width: 34%; background: var(--accent); clip-path: polygon(38% 0,100% 0,100% 100%,0 100%); }
.pub-hero::after { content: ""; position: absolute; top: 0; bottom: 0; right: -3%; width: 17%; background: var(--accent-2); opacity: .9; clip-path: polygon(58% 0,100% 0,100% 100%,14% 100%); }
.pub-hero .w { position: relative; z-index: 1; }
.pub-hero .eyebrow { color: var(--accent-2); font-weight: 800; letter-spacing: .16em; text-transform: uppercase; font-size: 12px; }
.pub-hero h1 { font-size: clamp(30px, 5vw, 50px); line-height: 1.08; letter-spacing: -.03em; margin: 12px 0 14px; max-width: 700px; color: #fff; }
.pub-hero p { font-size: 18px; color: #c9d7da; max-width: 600px; line-height: 1.5; }
.pub-hero .btn.sec { background: rgba(255,255,255,.12); color: #fff; border: 1.5px solid rgba(255,255,255,.3); }
.btn.big { padding: 14px 22px; font-size: 16px; }
.pub-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin-top: -50px; position: relative; z-index: 2; }
.pub-card { background: #fff; border-radius: 16px; padding: 20px; box-shadow: 0 14px 34px rgba(20,32,43,.08); }
.pub-card h3 { margin: 10px 0 6px; font-size: 17px; } .pub-card p { margin: 0; color: var(--ink-2); line-height: 1.5; font-size: 14.5px; } .pi { font-size: 26px; }
.pub-faq { margin-top: 40px; } .pub-faq details { background: #fff; border-radius: 14px; padding: 14px 18px; margin-bottom: 8px; border: 1px solid var(--line); }
.pub-faq summary { cursor: pointer; font-weight: 700; } .pub-faq p { color: var(--ink-2); line-height: 1.55; margin: 8px 0 0; }
.pub-cta { text-align: center; padding: 40px 20px 20px; }
.pub-doc { max-width: 760px; padding-top: 30px; padding-bottom: 20px; line-height: 1.6; } .pub-doc h1 { font-size: 32px; margin-bottom: 0; }
.pub-doc h2 { text-transform: none; letter-spacing: 0; color: var(--ink); font-size: 18px; margin-top: 26px; background: none !important; padding: 0 !important; display: block !important; clip-path: none !important; }
.pub-doc li { margin-bottom: 6px; color: var(--ink-2); } .pub-doc p { color: var(--ink-2); }
.pub-f { display: flex; flex-wrap: wrap; gap: 18px; justify-content: center; padding: 30px 20px 40px; font-size: 14px; color: var(--ink-2); }
.pub-f a { color: var(--ink-2); }

/* 2 nov kväll: meny, inställningsflikar, prislista */
.nav a.mob { display: none; }
@media (max-width: 760px) { .nav a.mob { display: flex; } }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.tabs a { padding: 8px 14px; border-radius: 999px; text-decoration: none; color: var(--ink-2); font-weight: 700; font-size: 14px; border: 1.5px solid var(--line); }
.tabs a.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.logoprev { max-height: 56px; max-width: 220px; border: 1px solid var(--line); border-radius: 10px; padding: 6px; background: #fff; }
.card.danger { border-color: #f1c4c7; }
.btn.bad { background: #c0392b; color: #fff; box-shadow: none; }
input.pin { width: 90px; text-align: right; padding: 6px 8px; }
.whocard { display: flex; flex-direction: column; gap: 2px; }
section[hidden] { display: none; }


/* ---------- 10 nov: anslagstavla, ekonomi, planering, dokument ---------- */
.board { margin-bottom: 14px; }
.boardhead { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.post { padding: 8px 0; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.post.pinned { background: #fff8ea; margin: 0 -16px; padding: 8px 16px; }
.postform { display: flex; gap: 8px; margin-top: 10px; align-items: flex-end; }
.postform textarea { flex: 1; min-width: 0; }
.btn.sm { padding: 2px 4px; font-size: 13px; font-weight: 600; }
.neg { color: var(--bad) !important; }
.bars { display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; align-items: end; height: 170px; }
.bar { display: flex; flex-direction: column; align-items: center; height: 100%; min-width: 0; }
.bar span { font-size: 11px; color: var(--ink-2); margin-top: 4px; }
.bb { flex: 1; width: 100%; display: flex; gap: 2px; align-items: flex-end; justify-content: center; }
.bb i { display: block; width: 42%; min-height: 1px; border-radius: 3px 3px 0 0; }
.b1 { background: var(--accent); } .b2 { background: #8fb9a8; }
i.lg { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin: 0 4px 0 10px; vertical-align: -1px; }
.gwrap { overflow-x: auto; padding: 10px !important; }
.gantt { display: grid; gap: 4px 0; min-width: 760px; align-items: center; font-size: 13px; }
.gantt .gl { grid-column: 1; padding-right: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gantt .gh { text-align: center; color: var(--ink-2); font-size: 11px; border-bottom: 1px solid var(--line); padding-bottom: 3px; line-height: 1.2; }
.gantt .gh small { display: block; font-weight: 700; color: var(--ink); }
.gantt .gh.we { background: rgba(0,0,0,.04); } .gantt .gh.today { color: var(--accent); font-weight: 800; }
.gbar { border-radius: 6px; padding: 4px 8px; color: #fff; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-weight: 600; min-height: 24px; margin: 0 1px; }
.g-pagar { background: #2f8f5b; } .g-planerat { background: #c9871a; } .g-offert { background: #4a78c2; } .g-klart { background: #6b7b8c; }
.g-item { background: var(--accent); cursor: pointer; }
.tplgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.tpl { background: var(--c); color: #fff; border-radius: var(--r); padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.tpl b { font-size: 17px; } .tpl p { margin: 0; flex: 1; font-size: 14px; opacity: .92; }
.tpl .btn.sec { justify-content: center; }
.docwrap { display: grid; grid-template-columns: 230px 1fr; gap: 16px; align-items: start; }
@media (max-width: 760px) { .docwrap { grid-template-columns: 1fr; } }
.steps { list-style: none; margin: 0; padding: 0; background: var(--ink); border-radius: var(--r); overflow: hidden; }
.steps li a { display: flex; justify-content: space-between; color: #e8edf2; text-decoration: none; padding: 9px 12px; border-bottom: 1px solid rgba(255,255,255,.08); font-size: 14px; }
.steps li.on a { background: rgba(255,255,255,.14); color: #fff; font-weight: 700; }
.steps li.done a::after { content: '✓'; color: #7fd6a5; font-weight: 800; }
fieldset.chk { border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin: 0; }
fieldset.chk legend { font-weight: 600; padding: 0 4px; }
.lbl { font-weight: 600; margin-bottom: 4px; }
table.dtab td { padding: 3px; } table.dtab input { width: 100%; min-width: 90px; padding: 6px; box-sizing: border-box; }
.doctabs .chip.on { background: #5fc4c9 !important; color: #0b2a2e !important; border-color: #5fc4c9 !important; }
.todo { margin-bottom: 14px; padding: 6px 16px; }
.todo-h { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-2); margin: 12px 0 4px; }
.todo-i, .todo-clock { display: flex; align-items: center; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.todo-i:last-child { border-bottom: 0; }
.todo-i .go, .todo-clock .go { margin-left: auto; color: var(--ink-2); font-weight: 700; }
.todo-clock.on b { color: #1f6f45; } .todo-clock .dot { width: 10px; height: 10px; border-radius: 50%; background: #2f8f5b; display: inline-block; }
@media (max-width: 560px) { #kpis { display: none; } }
.quick { display: flex; gap: 8px; overflow-x: auto; margin: 0 0 14px; padding-bottom: 2px; }
.qb { flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 64px; padding: 10px 8px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); font: inherit; font-size: 20px; cursor: pointer; }
.qb span { font-size: 12px; font-weight: 700; }
@media (max-width: 560px) { .fb-btn { display: none; } }
.planlist { display: none; margin-bottom: 14px; }
@media (max-width: 760px) { .planlist { display: block; } }
.planlist [data-pi] { cursor: pointer; }
.pwwrap { position: relative; display: block; }
.pwwrap input { width: 100%; padding-right: 48px !important; box-sizing: border-box; }
.pweye { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); width: 40px; height: 36px; border: 0; background: none; cursor: pointer; font-size: 18px; opacity: .55; border-radius: 8px; }
.pweye.on { opacity: 1; } .pweye:focus-visible { outline: 2px solid var(--accent); }
/* iPhone zoomar in när man trycker i fält med text under 16 px – och zoomar inte ut igen. 16 px på pekskärmar stoppar det. */
@media (pointer: coarse), (max-width: 760px) { input, select, textarea { font-size: 16px !important; } }
.pub-doc h2::after { display: none; }
.pub-cta h2::before { content: ""; flex: 1; height: 1px; background: var(--line); }
[data-theme] .fb-dlg h2 { display: block; text-transform: none; letter-spacing: 0; color: var(--ink); font-size: 19px; background: none; padding: 0; margin: 0 0 6px; }
[data-theme] .fb-dlg h2::after { display: none; }
.addphoto { flex-direction: column; gap: 2px; font-size: 22px; }
.addphoto span { font-size: 12px; font-weight: 700; }
.navsec { font-size: 10.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--side-ink, #9fb0b6); opacity: .6; padding: 14px 12px 4px; }
@media (max-width: 760px) { .navsec { display: none; } }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.tile { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 96px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); font: inherit; font-size: 28px; cursor: pointer; }
.tile span { font-size: 14px; font-weight: 700; }
@media (max-width: 560px) { .tiles { grid-template-columns: 1fr 1fr; } }
main > .card + .card { margin-top: 14px; }
.sm2 { padding: 6px 12px; font-size: 14px; margin-left: 6px; }
dialog.viewer { border: 0; padding: 0; width: 100vw; height: 100vh; max-width: 100vw; max-height: 100vh; margin: 0; background: var(--bg); display: flex; flex-direction: column; }
dialog.viewer:not([open]) { display: none; }
.viewer .vbar { display: flex; align-items: center; gap: 8px; padding: 10px 12px; padding-top: max(10px, env(safe-area-inset-top)); background: var(--card); border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.viewer .vbar b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 40vw; } .viewer .vsp { flex: 1; }
.viewer iframe { flex: 1; width: 100%; border: 0; background: #fff; }
@media (max-width: 560px) { .viewer .vbar .link { display: none; } }
.steps li { display: flex; align-items: center; }
.steps li .inc { margin: 0 0 0 10px; width: 18px; height: 18px; flex: none; accent-color: #5fc4c9; }
.steps li a { flex: 1; }
.steps li.off a { opacity: .45; text-decoration: line-through; }
.newtag { background: var(--accent); color: #fff; border-radius: 999px; font-size: 11px; font-weight: 800; padding: 2px 8px; }

/* Lägg till på hemskärmen */
.todo-inst{display:flex;align-items:center;gap:6px}.todo-inst .todo-i{flex:1}.steps-list{padding-left:22px;line-height:1.6}.steps-list li{margin:8px 0}
