/* WebLuxe Hub — sign in, first-time setup, and the client request page. */
:root { --ink: #0a1633; --ink-2: #3b4866; --ink-3: #5f6b85; --line: #dde4ef; --blue: #0066ff; --bad: #c8233a; --ok: #0b7d53; }
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { min-height: 100dvh; background: #06102a; color: var(--ink); font: 400 15px/1.5 'Figtree', system-ui, sans-serif; -webkit-font-smoothing: antialiased; overflow-x: hidden; }

/* three slow blobs in the logo's blues */
.aurora { position: fixed; inset: 0; overflow: hidden; z-index: 0; }
.aurora i { position: absolute; width: 60vmax; height: 60vmax; border-radius: 50%; filter: blur(70px); opacity: .55; animation: drift 22s ease-in-out infinite alternate; }
.aurora i:nth-child(1) { background: #0066ff; left: -18vmax; top: -22vmax; }
.aurora i:nth-child(2) { background: #00d9ff; right: -22vmax; top: 10vmax; animation-duration: 26s; opacity: .35; }
.aurora i:nth-child(3) { background: #3b2bff; left: 10vmax; bottom: -30vmax; animation-duration: 30s; opacity: .4; }
@keyframes drift { to { transform: translate(8vmax, 6vmax) scale(1.15); } }

.auth { position: relative; z-index: 1; min-height: 100dvh; display: grid; place-content: center; justify-items: center; gap: 16px; padding: 28px 16px; padding-bottom: max(28px, env(safe-area-inset-bottom)); }
.auth-card {
  width: min(440px, calc(100vw - 32px)); background: #fff; border-radius: 26px; padding: 30px 28px 28px;
  box-shadow: 0 40px 90px -30px rgb(0 0 0 / .6), 0 0 0 1px rgb(255 255 255 / .1);
  animation: up .6s cubic-bezier(.2, .8, .2, 1) both;
}
@keyframes up { from { opacity: 0; transform: translateY(24px) scale(.98); } }
.auth-logo { display: block; height: 72px; width: auto; margin: 0 auto 18px; }
.auth h1 { margin: 0 0 6px; font: 800 26px/1.15 'Schibsted Grotesk', system-ui, sans-serif; letter-spacing: -.03em; text-align: center; }
.auth-kicker { margin: 0 0 6px; text-align: center; font: 700 11.5px/1 'Figtree', sans-serif; letter-spacing: .14em; text-transform: uppercase; color: var(--blue); }
.auth-sub { margin: 0 0 20px; text-align: center; color: var(--ink-2); }
.auth-err, .auth-ok { margin: 0 0 16px; padding: 10px 12px; border-radius: 12px; font-weight: 600; font-size: 14px; }
.auth-err { background: #fde7ea; color: var(--bad); border: 1px solid #f2a9b3; animation: shake .4s; }
.auth-ok { background: #e2f5ec; color: var(--ok); border: 1px solid #a7dcc4; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
form { display: grid; gap: 14px; }
.fld { display: grid; gap: 6px; }
.fld > span { font-weight: 600; font-size: 13px; color: var(--ink-2); }
input, select, textarea {
  width: 100%; min-height: 46px; padding: 0 14px; font: inherit; color: var(--ink); background: #fff;
  border: 1px solid #c8d2e2; border-radius: 12px; transition: border-color .15s, box-shadow .15s;
}
textarea { padding: 12px 14px; resize: vertical; }
input[type=file] { padding: 10px; min-height: 0; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px #e6f0ff; }
.pw { position: relative; display: block; }
.pw input { padding-right: 70px; }
.pw-btn { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); height: 34px; padding: 0 12px; border: 0; border-radius: 9px; background: #eef3fa; color: var(--ink-2); font: 600 13px 'Figtree', sans-serif; cursor: pointer; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.check input { width: 18px; height: 18px; min-height: 0; margin-top: 2px; accent-color: var(--blue); }
.btn-main {
  position: relative; overflow: hidden; height: 50px; margin-top: 4px; border: 0; border-radius: 14px; cursor: pointer;
  color: #fff; font: 700 15.5px 'Figtree', sans-serif; background: linear-gradient(135deg, #0047d6, #0066ff);
  box-shadow: 0 14px 30px -14px rgb(0 82 230 / .9);
}
.btn-main::after { content: ''; position: absolute; inset: 0; transform: translateX(-120%); background: linear-gradient(100deg, transparent 30%, rgb(255 255 255 / .3) 50%, transparent 70%); transition: transform .8s ease; }
.btn-main:hover::after { transform: translateX(120%); }
.btn-main.busy { color: transparent; pointer-events: none; }
.btn-main.busy::before { content: ''; position: absolute; left: 50%; top: 50%; width: 18px; height: 18px; margin: -9px; border-radius: 50%; border: 2.5px solid rgb(255 255 255 / .4); border-top-color: #fff; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
:focus-visible { outline: 2.5px solid var(--blue); outline-offset: 2px; }
.auth-hint { margin: 2px 0 0; font-size: 12.5px; color: var(--ink-3); text-align: center; }
.auth-foot { margin: 0; color: rgb(255 255 255 / .7); font-size: 13px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* the client's own list of requests */
.req-h { margin: 28px 0 10px; font: 700 17px/1.2 'Schibsted Grotesk', sans-serif; }
.req-list { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 10px; }
.req-list li { display: grid; gap: 4px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; }
.req-list small { color: var(--ink-3); font-size: 12.5px; }
.req-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.req-no { font: 500 12px ui-monospace, Consolas, monospace; color: var(--ink-3); }
.req-st { padding: 4px 9px; border-radius: 99px; font-size: 12px; font-weight: 700; background: #eef3fa; color: var(--ink-2); }
.req-st.st-open { background: #e6f0ff; color: #0052cc; }
.req-st.st-progress { background: #fff1d9; color: #9a5800; }
.req-st.st-resolved, .req-st.st-closed { background: #e2f5ec; color: var(--ok); }
.req-reply { margin: 6px 0 0; padding: 8px 10px; border-radius: 10px; background: #f3f6fb; font-size: 13.5px; }
.req-reply small { display: block; margin-top: 2px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------- client portal ---------- */
.auth-card.wide { width: min(640px, calc(100vw - 24px)); }
.pt-sum { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 10px; margin: 6px 0 16px; }
.pt-sum > div { display: grid; gap: 2px; padding: 14px 16px; border-radius: 16px; background: #f3f6fb; border: 1px solid var(--line); }
.pt-sum small { font-size: 12.5px; font-weight: 600; color: var(--ink-3); }
.pt-sum b { font: 800 26px/1.1 'Schibsted Grotesk', sans-serif; letter-spacing: -.03em; }
.pt-sum .is-bad { background: #fde7ea; border-color: #f2a9b3; } .pt-sum .is-bad b, .pt-sum .is-bad small { color: var(--bad); }
.pt-sum .is-ok { background: #e2f5ec; border-color: #a7dcc4; } .pt-sum .is-ok b { color: var(--ok); }
.pt-tabs { display: flex; gap: 4px; padding: 4px; margin: 0 0 18px; border-radius: 14px; background: #eef3fa; border: 1px solid var(--line); overflow-x: auto; }
.pt-tabs a { flex: 1; text-align: center; padding: 10px 12px; border-radius: 10px; color: var(--ink-2); font-weight: 700; font-size: 14px; text-decoration: none; white-space: nowrap; transition: background .2s, color .2s; }
.pt-tabs a.on { background: #fff; color: var(--ink); box-shadow: 0 2px 8px -4px rgb(10 22 51 / .3); }
.pt-panel { display: grid; gap: 14px; animation: up .35s ease both; }
.pt-panel[hidden] { display: none; }
.pt-box { padding: 14px 16px; border-radius: 16px; border: 1px dashed #c8d2e2; }
.req-h0 { margin: 0 0 8px; font: 700 15px/1.2 'Schibsted Grotesk', sans-serif; }
.pt-chan { display: flex; align-items: center; gap: 10px; margin: 6px 0 0; font-size: 14px; }
.pt-chan b { min-width: 96px; }
.pt-chan span { flex: 1; font-variant-numeric: tabular-nums; }
.pt-copy, .pt-btn { height: 34px; padding: 0 12px; border-radius: 10px; border: 1px solid #c8d2e2; background: #fff; color: var(--ink); font: 600 13px 'Figtree', sans-serif; cursor: pointer; }
.pt-btn { background: linear-gradient(135deg, #0047d6, #0066ff); color: #fff; border: 0; }
.pt-btn.ghost { background: #fff; color: var(--ink); border: 1px solid #c8d2e2; }
.pt-acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.pt-two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.req-st.st-rejected { background: #fde7ea; color: var(--bad); }
.req-st.st-waiting { background: #eef3fa; }
.pt-doc { width: min(900px, 100vw); height: min(92dvh, 1200px); max-width: 100vw; max-height: 100dvh; padding: 0; border: 0; border-radius: 18px; background: #e3eaf5; }
.pt-doc::backdrop { background: rgb(4 8 18 / .7); }
.pt-doc[open] { display: flex; flex-direction: column; }
.pt-doc-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 14px; background: #fff; }
.pt-doc-top span { display: flex; gap: 6px; }
.pt-paper { flex: 1; overflow: auto; padding: 16px 12px 24px; }
@media (max-width: 520px) {
  .pt-two { grid-template-columns: 1fr; }
  .pt-sum b { font-size: 22px; }
  .auth-card.wide { padding: 24px 18px; border-radius: 22px; }
  .pt-doc { width: 100vw; height: 100dvh; border-radius: 0; }
}
@media print { body:not(.tk-public) .aurora, body:not(.tk-public) .auth, .pt-doc { display: none !important; } }

/* ---------- one ticket, for the client (t.php) ---------- */
.tk-h1 { text-align: left !important; font-size: 24px !important; margin-top: 2px !important; }
.tk-public .auth-kicker, .tk-public .auth-sub { text-align: left; }
.tk-steps { list-style: none; margin: 4px 0 14px; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); position: relative; }
.tk-steps::before { content: ''; position: absolute; left: 12.5%; right: 12.5%; top: 11px; height: 3px; border-radius: 3px; background: #e3e9f3; }
.tk-steps li { position: relative; display: grid; justify-items: center; gap: 7px; text-align: center; font-size: 12px; color: var(--ink-3); }
.tk-steps li span { position: relative; z-index: 1; width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 3px solid #d5dde9; }
.tk-steps li.done span { background: var(--ok); border-color: var(--ok); }
.tk-steps li.done span::after { content: ''; position: absolute; left: 6px; top: 2px; width: 5px; height: 10px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.tk-steps li.now span { border-color: var(--blue); box-shadow: 0 0 0 5px #e6f0ff; animation: ring-n 1.8s infinite; }
.tk-steps li.now b { color: var(--ink); }
.tk-steps li.skip { opacity: .45; }
.tk-steps b { font-weight: 600; }
@keyframes ring-n { 50% { box-shadow: 0 0 0 9px #e6f0ff00; } }
.tk-wait { margin: -4px 0 14px; padding: 10px 12px; border-radius: 12px; background: #fff4e0; color: #8a5200; text-align: left; font-weight: 600; }
.tk-body { margin: 0; color: var(--ink-2); line-height: 1.6; }
.tk-feed { list-style: none; margin: 0 0 8px; padding: 0 0 0 4px; position: relative; display: grid; gap: 14px; }
.tk-feed::before { content: ''; position: absolute; left: 10px; top: 8px; bottom: 8px; width: 2px; background: #e3e9f3; }
.tk-feed li { position: relative; display: grid; grid-template-columns: 14px minmax(0, 1fr); gap: 12px; }
.tk-feed .dot { width: 14px; height: 14px; margin-top: 4px; border-radius: 50%; background: #fff; border: 3px solid var(--blue); position: relative; z-index: 1; }
.tk-feed .k-created .dot { border-color: var(--ok); background: var(--ok); }
.tk-feed .k-comment > div { padding: 10px 12px; border-radius: 4px 14px 14px 14px; background: #f3f6fb; }
.tk-feed p { margin: 4px 0 0; color: var(--ink-2); line-height: 1.55; }
.tk-feed small { display: block; margin-top: 4px; font-size: 12px; color: var(--ink-3); }
.tk-save { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 18px; }
.tk-save a { display: inline-flex; align-items: center; text-decoration: none; }
.muted { color: var(--ink-3); }
@media print {
  .tk-public { background: #fff !important; }
  .tk-public .aurora, .tk-public form, .tk-public .tk-save, .tk-public .auth-foot, .tk-public .auth-hint, .tk-public .tk-reply { display: none !important; }
  .tk-public .auth { display: block; min-height: 0; padding: 0; }
  .tk-public .auth-card { width: 100% !important; box-shadow: none !important; padding: 0 !important; animation: none; }
  .tk-public * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
@media (max-width: 520px) { .tk-steps { font-size: 11px; } .tk-steps li { font-size: 11px; } }

/* ---------- sign-in: the way in for people without an account ---------- */
.auth-alt { display: block; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); text-align: center; color: var(--blue); font-weight: 600; font-size: 14px; text-decoration: none; }
.auth-alt:hover { text-decoration: underline; }
.auth-hint a { color: var(--blue); font-weight: 600; }
.fld > span em { font-style: normal; font-weight: 500; color: var(--ink-3); }
.fld > span:has(em) { display: block; }

/* ---------- support: the public ticket form ---------- */
.sp-form { display: grid; gap: 14px; }
.sp-kinds { margin: 0; padding: 0; border: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sp-kinds legend { padding: 0; margin-bottom: 6px; font-weight: 600; font-size: 13px; color: var(--ink-2); }
.sp-kind { position: relative; display: grid; align-content: start; gap: 2px; padding: 11px 12px; border: 1px solid #d5ddea; border-radius: 14px; background: #fff; cursor: pointer; transition: border-color .15s, background .15s, box-shadow .15s; }
.sp-kind input { position: absolute; opacity: 0; pointer-events: none; }
.sp-kind b { font-size: 14px; line-height: 1.25; }
.sp-kind small { color: var(--ink-3); font-size: 12px; line-height: 1.35; }
.sp-kind:hover { border-color: #aebcd3; }
.sp-kind:has(input:checked) { border-color: var(--blue); background: #eef4ff; box-shadow: 0 0 0 3px rgb(0 102 255 / .12); }
.sp-kind:has(input:checked) b { color: #0047d6; }
.sp-kind:has(input:focus-visible) { outline: 2px solid var(--blue); outline-offset: 2px; }
@media (max-width: 520px) { .sp-kinds { grid-template-columns: 1fr 1fr; } }

/* ---------- t.php right after sending ---------- */
.tk-new { margin: 0 0 16px; padding: 16px; border-radius: 16px; background: linear-gradient(135deg, #e2f5ec, #e6f0ff); border: 1px solid #a7dcc4; animation: up .4s ease both; }
.tk-new b { display: block; font: 800 17px/1.3 'Schibsted Grotesk', sans-serif; color: var(--ok); }
.tk-new p { margin: 4px 0 12px; color: var(--ink-2); font-size: 14px; }
.tk-new-acts { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- portal: the signed-in client's Account tab ---------- */
.pt-me { display: flex; align-items: center; gap: 12px; border-style: solid; }
.pt-me b { display: block; }
.pt-me small { color: var(--ink-3); font-size: 13px; }
.pt-av { display: grid; place-items: center; flex: none; width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg, #00c8ff, #0057e8); color: #fff; font-weight: 800; }
.pt-out { justify-self: center; display: inline-flex; align-items: center; text-decoration: none; margin-top: 4px; }
.tk-new .tk-no { white-space: nowrap; }
