/* ============================================================
   Harjo Works — Authelia-tema (familie-stil: grafitt + isblå)
   Injiseres av sidecar-containeren `authelia-theme` (nginx) som
   <link rel="stylesheet" href="/__hw/theme.css"> i login-portalen.
   Samme origin -> dekkes av Authelias CSP (style-src 'self').
   Stabile selektorer: MUI-klasser + Authelias faste ID-er.
   ============================================================ */

:root {
  --hw-bg: #0b0f14;
  --hw-panel: rgba(18, 23, 30, 0.78);
  --hw-line: rgba(255, 255, 255, 0.09);
  --hw-text: #eef2f6;
  --hw-dim: rgba(238, 242, 246, 0.62);
  --hw-accent: #9cc7e8;
}

html, body { background-color: var(--hw-bg) !important; }

body {
  background-image:
    radial-gradient(1100px 520px at 50% -8%, rgba(156, 199, 232, 0.08), transparent 62%),
    radial-gradient(900px 480px at 85% 108%, rgba(110, 151, 179, 0.06), transparent 60%) !important;
  background-attachment: fixed !important;
  color: var(--hw-text);
}

body, .MuiTypography-root, .MuiButton-root, .MuiInputBase-root,
input, textarea, button, .MuiFormControlLabel-label, .MuiInputLabel-root {
  font-family: Inter, -apple-system, "Helvetica Neue", Arial, sans-serif !important;
}

/* Tom topplinje skjules helt */
header.MuiAppBar-root { display: none !important; }

/* Kortet (glass-panel, som portal/finnvei/psdash) */
.MuiContainer-maxWidthXs {
  background: var(--hw-panel) !important;
  border: 1px solid var(--hw-line) !important;
  border-radius: 20px !important;
  box-shadow: 0 24px 60px -30px rgba(0, 0, 0, 0.65) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 44px 36px !important;
  margin-top: 7vh !important;
}

/* Logoen diskré i aksentfarge */
#UserSvg { width: 56px !important; height: 56px !important; opacity: 0.95; }
#UserSvg path { fill: var(--hw-accent) !important; }

/* Tittel */
.MuiTypography-h5 {
  color: var(--hw-text) !important;
  font-weight: 300 !important;
  letter-spacing: 0.2px !important;
}

/* Skjemafelt */
.MuiOutlinedInput-root { background: rgba(255, 255, 255, 0.035) !important; border-radius: 10px !important; }
.MuiOutlinedInput-notchedOutline { border-color: rgba(255, 255, 255, 0.13) !important; }
.MuiOutlinedInput-root:hover .MuiOutlinedInput-notchedOutline { border-color: rgba(255, 255, 255, 0.22) !important; }
.MuiOutlinedInput-root.Mui-focused .MuiOutlinedInput-notchedOutline {
  border-color: var(--hw-accent) !important;
  border-width: 1px !important;
}
.MuiInputLabel-root { color: var(--hw-dim) !important; }
.MuiInputLabel-root.Mui-focused { color: var(--hw-accent) !important; }
#username-textfield, #password-textfield { color: var(--hw-text) !important; }
input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 40px #12161c inset !important;
  -webkit-text-fill-color: #eef2f6 !important;
}

/* Hovedknappen */
#sign-in-button {
  background: var(--hw-accent) !important;
  color: #0b0f14 !important;
  border-radius: 10px !important;
  text-transform: none !important;
  font-weight: 600 !important;
  letter-spacing: 0.2px !important;
  box-shadow: none !important;
  transition: background-color 0.15s ease, transform 0.12s ease;
}
#sign-in-button:hover { background: #aed3ee !important; }
#sign-in-button:active { transform: translateY(1px); }
#sign-in-button.Mui-disabled {
  background: rgba(156, 199, 232, 0.35) !important;
  color: rgba(11, 15, 20, 0.7) !important;
}

/* Husk meg + etiketter */
#remember-checkbox { color: rgba(255, 255, 255, 0.35) !important; }
.MuiCheckbox-root.Mui-checked { color: var(--hw-accent) !important; }
.MuiFormControlLabel-label { color: var(--hw-dim) !important; font-size: 14px !important; }

/* Lenker + fotnote */
.MuiLink-root { color: var(--hw-accent) !important; text-decoration-color: rgba(156, 199, 232, 0.4) !important; }
.MuiTypography-caption { color: rgba(238, 242, 246, 0.45) !important; }

/* Tastaturfokus */
:focus-visible { outline: 2px solid var(--hw-accent); outline-offset: 2px; border-radius: 6px; }

/* Redusert bevegelse respekteres */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
