/* Kundportalen för styrelser. Bygger på norrvik.css. */
.pt-page { background: var(--bone); }
.login { min-height: calc(100vh - 48px); display: grid; grid-template-columns: minmax(340px, 520px) 1fr; }
.login-card { margin: auto; width: min(440px, calc(100% - 32px)); padding: 32px; display: grid; gap: 16px; border-radius: 22px; animation: upp .8s var(--ease) both; }
.login-card h1 { font-size: 30px; letter-spacing: -.03em; }
.login-img { width: 100%; height: 100%; object-fit: cover; }
.bankid { gap: 12px; }
.bid { width: 26px; height: 26px; border-radius: 6px; background: #fff; color: var(--ink); font-size: 11px; font-weight: 700; display: grid; place-items: center; }
.login-wait { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); }
.spin { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line); border-top-color: var(--copper); animation: snurr .8s linear infinite; }
@keyframes snurr { to { transform: rotate(360deg); } }
.fine { font-size: 12px; color: var(--muted); }
.field input[readonly] { background: var(--bone); }

.pt-top { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 24px; padding: 12px var(--gutter); background: rgba(250,248,243,.9); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.pt-nav { display: flex; gap: 2px; margin: 0 auto; }
.pt-nav a { position: relative; padding: 8px 14px; border-radius: 999px; font-size: 14px; font-weight: 500; color: var(--muted); text-decoration: none; transition: background .25s, color .25s; }
.pt-nav a:hover { color: var(--ink); }
.pt-nav a[aria-current="page"] { background: var(--ink); color: var(--bone); }
.pt-nav b { margin-left: 6px; font-size: 11px; padding: 1px 7px; border-radius: 999px; background: var(--copper); color: #fff; }
.pt-nav b:empty { display: none; }
.pt-me { display: flex; align-items: center; gap: 10px; }
.pt-me b { display: block; font-size: 14px; } .pt-me small { font-size: 12px; color: var(--muted); }
.av-l { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--copper); color: #fff; font-weight: 600; font-size: 13px; }

.pt-main { max-width: 1180px; margin: 0 auto; padding: 32px var(--gutter) 80px; }
.pt-main > section { animation: in .5s var(--ease) both; }
.pt-hello { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 24px; flex-wrap: wrap; }
.pt-hello h1, .pt-head h1 { font-size: clamp(34px, 4.5vw, 52px); letter-spacing: -.04em; margin-top: 8px; }
.pt-head { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 22px; flex-wrap: wrap; }
.pt-head p { max-width: 60ch; }
.pt-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 14px; }
.pt-kpi { padding: 18px 20px; display: grid; gap: 4px; }
.pt-kpi small { font-size: 13px; color: var(--muted); }
.pt-kpi b { font-size: 30px; font-weight: 600; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.pt-kpi span { font-size: 13px; color: var(--muted); }
.pt-kpi .bar { height: 6px; border-radius: 3px; background: var(--bone); overflow: hidden; margin-top: 6px; }
.pt-kpi .bar i { display: block; height: 100%; border-radius: 3px; background: var(--ink); transition: width 1s var(--ease); }
.pt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.pt-card { padding: 22px; }
.pt-card.wide { grid-column: 1 / -1; }
.pt-card-h { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.pt-card-h.mt { margin-top: 24px; }
.pt-card-h h2 { font-size: 18px; letter-spacing: -.02em; }
.pt-card-h a { font-size: 14px; color: var(--copper); text-decoration: none; font-weight: 500; }
.pt-list { list-style: none; margin: 0; padding: 0; }
.pt-list li { border-top: 1px solid var(--line); }
.pt-list li:first-child { border-top: 0; }
.pt-row { width: 100%; display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 12px 0; text-align: left; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; }
.pt-row:hover b { text-decoration: underline; }
.pt-row small { color: var(--muted); font-size: 13px; }
.st { justify-self: end; align-self: center; grid-row: span 2; display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; background: var(--bone); white-space: nowrap; }
.st i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.st.ny i { background: var(--copper); } .st.planerad i { background: #2F6F8F; } .st.pagar i { background: #2E8B57; } .st.vantar i { background: #B8892B; } .st.klar { background: #E3F2E9; color: #1F7A47; } .st.klar i { background: #2E8B57; }
.besok { display: flex; gap: 14px; align-items: center; padding: 14px; border-radius: 14px; background: var(--bone); }
.besok img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; }
.besok b { display: block; } .besok span { font-size: 14px; color: var(--muted); }
.pt-feed { list-style: none; margin: 0; padding: 0; }
.pt-feed li { display: grid; grid-template-columns: 14px 1fr; gap: 10px; padding: 8px 0; font-size: 14px; }
.pt-feed li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--line); margin-top: 6px; }
.pt-feed li.ny::before { background: var(--copper); }
.pt-feed small { display: block; color: var(--muted); font-size: 12px; }
.pt-seg { display: inline-flex; padding: 3px; border-radius: 11px; background: var(--white); box-shadow: 0 0 0 1px var(--line); }
.pt-seg button { border: 0; background: none; padding: 7px 14px; border-radius: 8px; font: 500 14px var(--sans); color: var(--muted); cursor: pointer; }
.pt-seg button[aria-selected="true"] { background: var(--ink); color: var(--bone); }
.pt-arenden { display: grid; gap: 10px; }
.pt-a { display: grid; grid-template-columns: 1fr auto; gap: 14px; align-items: center; padding: 18px 20px; text-align: left; border: 0; font: inherit; color: inherit; cursor: pointer; transition: transform .3s var(--ease), box-shadow .3s; }
.pt-a:hover { transform: translateY(-2px); }
.pt-a.du { box-shadow: 0 0 0 2px var(--copper), var(--shadow); }
.pt-a b { font-size: 17px; letter-spacing: -.01em; }
.pt-a .meta { display: block; font-size: 13px; color: var(--muted); margin-top: 3px; }
.mini-tl { display: flex; gap: 4px; margin-top: 10px; }
.mini-tl i { width: 46px; height: 4px; border-radius: 2px; background: var(--line); }
.mini-tl i.on { background: var(--ink); } .mini-tl i.klar { background: var(--copper); }
.pt-a-r { display: grid; justify-items: end; gap: 6px; }
.pt-a-r small { font-size: 12px; color: var(--muted); }

.legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); flex-wrap: wrap; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 10px; height: 10px; border-radius: 3px; }
.lg-a { background: var(--ink); } .lg-b { background: var(--copper); } .lg-c { background: #D8D2C4; }
.chart { display: grid; grid-template-columns: repeat(12, 1fr); gap: 8px; align-items: end; height: 220px; padding-top: 10px; border-bottom: 1px solid var(--line); }
.col { display: flex; flex-direction: column-reverse; gap: 2px; height: 100%; position: relative; cursor: default; }
.col span { display: block; border-radius: 4px 4px 0 0; transition: height .9s var(--ease); }
.col span + span { border-radius: 4px 4px 0 0; }
.col .a { background: var(--ink); } .col .b { background: var(--copper); } .col .c { background: #D8D2C4; }
.col em { position: absolute; bottom: -22px; left: 0; right: 0; text-align: center; font-style: normal; font-size: 11px; color: var(--muted); }
.col.framtid span { opacity: .25; }
.col .tip { position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); white-space: nowrap; padding: 6px 9px; border-radius: 8px; background: var(--ink); color: var(--bone); font-size: 12px; opacity: 0; pointer-events: none; transition: opacity .2s; z-index: 2; }
.col:hover .tip, .col:focus .tip { opacity: 1; }
.chart-wrap { padding-bottom: 26px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.kat-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.kat-list li { display: grid; gap: 6px; font-size: 14px; }
.kat-list .r { display: flex; justify-content: space-between; } .kat-list .r b { font-variant-numeric: tabular-nums; }
.kat-list .b { height: 8px; border-radius: 4px; background: var(--bone); overflow: hidden; } .kat-list .b i { display: block; height: 100%; background: var(--ink); border-radius: 4px; }
.fakt .pt-row b, .docs .pt-row b { font-weight: 500; }
.pt-dl { margin: 14px 0; }
.pt-dl div { display: grid; grid-template-columns: 140px 1fr; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; }
.pt-dl dt { color: var(--muted); } .pt-dl dd { margin: 0; font-weight: 500; }
.avtal-kort { background: var(--ink); color: var(--bone); }
.avtal-kort h2 { font-size: 34px; letter-spacing: -.04em; margin: 4px 0; }
.avtal-kort .pt-dl div { border-color: var(--line-l); } .avtal-kort .pt-dl dt { color: var(--muted-l); }
.avtal-kort .eyebrow { color: var(--copper-2); }
.ingar { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: 14px; color: var(--muted-l); }
.plan { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.plan li { padding: 14px; border-radius: 14px; background: var(--bone); display: grid; gap: 4px; align-content: start; }
.plan li.nasta { background: #FFF4EC; box-shadow: 0 0 0 1px rgba(194,98,45,.35); }
.plan .ar { font-size: 22px; font-weight: 600; letter-spacing: -.03em; }
.plan small { color: var(--muted); font-size: 13px; }
.plan b { font-variant-numeric: tabular-nums; font-size: 14px; }

.anslag { padding: 34px; display: grid; gap: 14px; justify-items: center; text-align: center; background: var(--white); }
.anslag-k { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.anslag h2 { font-size: 36px; letter-spacing: -.035em; }
.anslag p { max-width: 36ch; }
.qr { width: 196px; height: 196px; padding: 10px; border-radius: 14px; background: #fff; box-shadow: 0 0 0 1px var(--line); display: grid; place-items: center; }
.qr img, .qr canvas { width: 176px !important; height: 176px !important; }
.anslag-url { font-size: 13px; color: var(--muted); word-break: break-all; }
.anslag-jour { padding: 12px 16px; border-radius: 12px; background: var(--ink); color: var(--bone); font-size: 14px; }
.anslag-fot { font-weight: 700; letter-spacing: -.02em; }
.steg-l { margin: 0 0 18px; padding-left: 20px; display: grid; gap: 8px; color: var(--muted); }
.pt-btns { display: flex; gap: 10px; flex-wrap: wrap; }

.pt-drawer { position: fixed; inset: 0; z-index: 120; }
.pt-scrim { position: absolute; inset: 0; background: rgba(20,32,27,.3); }
.pt-panel { position: absolute; top: 0; right: 0; bottom: 0; width: min(480px, 100%); background: var(--paper); padding: 26px 24px 40px; overflow: auto; animation: slide .45s var(--ease) both; box-shadow: -20px 0 50px -20px rgba(20,32,27,.35); }
@keyframes slide { from { transform: translateX(40px); opacity: 0; } }
.pt-x { position: absolute; top: 14px; right: 14px; width: 34px; height: 34px; border-radius: 9px; border: 0; background: var(--bone); font-size: 20px; cursor: pointer; }
.pt-panel h2 { font-size: 26px; letter-spacing: -.03em; margin: 6px 0 4px; padding-right: 40px; }
.pt-steps { list-style: none; margin: 18px 0; padding: 0; display: grid; gap: 0; }
.pt-steps li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; padding: 0 0 16px; position: relative; font-size: 14px; color: var(--muted); }
.pt-steps li::before { content: ""; width: 12px; height: 12px; border-radius: 50%; background: var(--line); margin-top: 4px; z-index: 1; }
.pt-steps li::after { content: ""; position: absolute; left: 5px; top: 16px; bottom: 0; width: 2px; background: var(--line); }
.pt-steps li:last-child::after { display: none; }
.pt-steps li.klar::before { background: var(--copper); } .pt-steps li.on::before { background: var(--ink); box-shadow: 0 0 0 4px rgba(20,32,27,.12); }
.pt-steps li.klar, .pt-steps li.on { color: var(--ink); }
.pt-steps b { display: block; }
.pt-thread { display: grid; gap: 8px; padding: 14px; border-radius: 14px; background: var(--bone); margin-bottom: 14px; }
.pt-msg { max-width: 88%; padding: 9px 12px; border-radius: 12px 12px 12px 4px; background: var(--white); font-size: 14px; }
.pt-msg.n { justify-self: end; border-radius: 12px 12px 4px 12px; background: var(--ink); color: var(--bone); }
.pt-msg small { display: block; font-size: 11px; color: var(--muted); margin-top: 3px; } .pt-msg.n small { color: var(--muted-l); }
.pt-skriv { display: flex; gap: 8px; }
.pt-skriv input { flex: 1; min-width: 0; padding: 0 12px; height: 44px; border: 0; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--line); font: inherit; background: var(--white); }

@media (max-width: 960px) {
  .login { grid-template-columns: 1fr; } .login-img { display: none; }
  .pt-top { flex-wrap: wrap; gap: 10px; } .pt-nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; } .pt-nav a { flex: none; }
  .pt-me div { display: none; }
  .pt-kpis { grid-template-columns: 1fr 1fr; } .pt-grid { grid-template-columns: 1fr; }
  .plan { grid-template-columns: 1fr 1fr; }
  .chart { gap: 4px; } .col em { font-size: 10px; }
}
@media print {
  body * { visibility: hidden; } .anslag, .anslag * { visibility: visible; }
  .anslag { position: fixed; inset: 0; box-shadow: none; padding: 60px; justify-content: center; align-content: center; }
}

/* Demo 2.0 (27 nov): siffrorna på en rad i mobilen, och flikarna visar att de går att scrolla */
@media (max-width: 760px) {
  .pt-kpi { padding: 14px 14px; }
  .pt-kpi b { font-size: 24px; white-space: nowrap; }
  .pt-kpi span { font-size: 12px; }
  .pt-nav { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); padding-right: 28px; }
  .pt-nav::-webkit-scrollbar { display: none; }
}
