:root {
  --tl-blue: #00498c;
  --tl-blue-dark: #07305e;
  --tl-orange: #f58200;
  --ink: #132033;
  --muted: #68768a;
  --line: rgba(7, 48, 94, 0.12);
  --surface: #ffffff;
  --background: #f5f7fa;
  --shadow: 0 10px 26px rgba(7, 48, 94, 0.09);
  --shadow-hover: 0 14px 34px rgba(7, 48, 94, 0.13);
  --radius: 20px;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  min-height: 100vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  background:
    linear-gradient(180deg, #ffffff 0, var(--background) 190px),
    var(--background);
  font-family: "Segoe UI", Roboto, Arial, sans-serif;
}

img,
svg {
  display: block;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: 14px;
  z-index: 20;
  transform: translateY(-140%);
  border-radius: 999px;
  background: var(--tl-blue-dark);
  color: #fff;
  padding: 12px 16px;
  font-weight: 800;
  text-decoration: none;
}

.skip-link:focus-visible {
  transform: translateY(0);
}

.topbar {
  flex: 0 0 auto;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
}

.topbar-inner {
  width: min(1080px, calc(100% - 36px));
  min-height: 76px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  border-radius: 14px;
  text-decoration: none;
  outline-offset: 7px;
}

.brand img {
  width: clamp(205px, 27vw, 270px);
  height: auto;
}

.topbar-label {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  border: 1px solid rgba(0, 73, 140, 0.14);
  border-radius: 999px;
  background: #fff;
  color: var(--tl-blue-dark);
  padding: 0 16px;
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.portal-shell {
  width: min(1080px, calc(100% - 36px));
  margin: 0 auto;
  padding: clamp(22px, 3.2vw, 38px) 0 22px;
}

.intro {
  max-width: 720px;
  margin-bottom: clamp(18px, 2.8vw, 28px);
}

.eyebrow,
.card-kicker {
  color: var(--tl-orange);
  font-size: 0.74rem;
  line-height: 1.2;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.intro h1 {
  margin: 8px 0 6px;
  color: var(--tl-blue-dark);
  font-size: clamp(2rem, 4.2vw, 3.1rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.intro p {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.8vw, 1.12rem);
  line-height: 1.45;
}

.status-panel {
  position: relative;
  overflow: hidden;
  margin: clamp(14px, 2vw, 20px) 0 0;
  border: 1px solid rgba(0, 73, 140, 0.12);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: none;
  padding: 12px 14px;
}

.status-panel[hidden] {
  display: none;
}

.status-panel::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: #94a3b8;
}

.status-panel--good::before {
  background: #16a34a;
}

.status-panel--ok::before {
  background: #f59e0b;
}

.status-panel--bad::before {
  background: #dc2626;
}

.status-main {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.status-dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: #94a3b8;
  box-shadow: 0 0 0 4px rgba(148, 163, 184, 0.12);
}

.status-panel--good .status-dot {
  background: #16a34a;
  box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.12);
}

.status-panel--ok .status-dot {
  background: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.status-panel--bad .status-dot {
  background: #dc2626;
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.12);
}

.status-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.status-copy h2 {
  margin: 0;
  color: var(--tl-blue-dark);
  font-size: clamp(1.02rem, 1.7vw, 1.18rem);
  line-height: 1.08;
  letter-spacing: 0;
}

.status-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.35;
}

.status-systems {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.status-item {
  min-width: 0;
  display: grid;
  gap: 3px;
  border: 1px solid rgba(0, 73, 140, 0.10);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.70);
  padding: 8px 10px;
}

.status-item strong {
  min-width: 0;
  overflow: hidden;
  color: var(--tl-blue-dark);
  font-size: 0.88rem;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.status-item span {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.status-item--good {
  border-color: rgba(22, 163, 74, 0.22);
}

.status-item--ok {
  border-color: rgba(245, 158, 11, 0.26);
}

.status-item--bad {
  border-color: rgba(220, 38, 38, 0.24);
}

.status-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(14px, 2vw, 20px);
}

.app-card {
  position: relative;
  min-height: clamp(150px, 18vw, 178px);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-rows: 1fr auto;
  column-gap: 18px;
  row-gap: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: clamp(18px, 2.5vw, 24px);
  text-decoration: none;
  outline-offset: 7px;
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(245, 130, 0, 0.16);
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.app-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: var(--tl-blue);
}

.app-card--accent::before {
  background: linear-gradient(90deg, var(--tl-orange) 0 34%, var(--tl-blue) 34% 100%);
}

.icon-badge {
  width: clamp(62px, 8vw, 74px);
  height: clamp(62px, 8vw, 74px);
  display: grid;
  place-items: center;
  align-self: start;
  border-radius: 18px;
  background: #f8fafc;
  border: 1px solid rgba(0, 73, 140, 0.10);
}

.icon-badge img {
  width: clamp(40px, 5vw, 48px);
  height: clamp(40px, 5vw, 48px);
}

.card-copy {
  min-width: 0;
  align-self: start;
  display: grid;
  gap: 6px;
}

.card-copy strong {
  color: var(--tl-blue-dark);
  font-size: clamp(1.28rem, 2.6vw, 1.75rem);
  line-height: 1.08;
  letter-spacing: -0.025em;
}

.card-url {
  min-width: 0;
  color: var(--muted);
  font-size: clamp(0.84rem, 1.6vw, 0.94rem);
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.open-pill {
  grid-column: 2;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  border-radius: 999px;
  background: rgba(0, 73, 140, 0.08);
  color: var(--tl-blue-dark);
  padding: 0 14px;
  font-size: 0.9rem;
  font-weight: 850;
}

.open-pill img {
  opacity: 0.72;
}

.page-footer {
  width: min(1080px, calc(100% - 36px));
  margin: auto auto 0;
  padding: 12px 0 22px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 650;
}

.brand:focus-visible,
.app-card:focus-visible,
.skip-link:focus-visible {
  outline: 4px solid rgba(245, 130, 0, 0.42);
}

@media (hover: hover) and (pointer: fine) {
  .app-card:hover {
    transform: translateY(-3px);
    border-color: rgba(245, 130, 0, 0.48);
    box-shadow: var(--shadow-hover);
  }

  .app-card:hover .open-pill {
    background: var(--tl-blue-dark);
    color: #fff;
  }

  .app-card:hover .open-pill img {
    filter: brightness(0) invert(1);
    opacity: 1;
  }
}

@media (max-width: 700px) {
  .topbar-inner,
  .portal-shell,
  .page-footer {
    width: min(100% - 28px, 1080px);
  }

  .topbar-inner {
    min-height: 70px;
  }

  .brand img {
    width: 205px;
  }

  .topbar-label {
    display: none;
  }

  .intro h1 {
    font-size: clamp(1.85rem, 8vw, 2.5rem);
  }

  .status-main {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .status-systems {
    grid-template-columns: 1fr;
  }

  .app-grid {
    grid-template-columns: 1fr;
  }

  .app-card {
    min-height: 142px;
  }
}

@media (orientation: landscape) and (max-height: 760px) and (min-width: 760px) {
  .topbar-inner {
    min-height: 66px;
  }

  .brand img {
    width: 220px;
  }

  .portal-shell {
    padding-top: 18px;
  }

  .intro {
    margin-bottom: 16px;
  }

  .intro h1 {
    font-size: clamp(1.85rem, 3.7vw, 2.55rem);
  }

  .intro p {
    font-size: 1rem;
  }

  .app-card {
    min-height: 134px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Compact display-only PRTG status: Systeemstatus + Pitstop/Incadea smileys. */
.status-panel {
  --status-good: #178a47;
  --status-ok: #a96b00;
  --status-bad: #c42b2b;
  --status-idle: #8794a6;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px 14px;
  margin: 12px 0 0;
  padding: 8px 10px;
  border: 1px solid rgba(7, 48, 94, 0.10);
  border-left: 4px solid var(--status-idle);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: none;
  overflow: visible;
}

.status-panel::before {
  display: none;
}

.status-panel[hidden] {
  display: none;
}

.status-panel--good {
  border-left-color: var(--status-good);
}

.status-panel--ok {
  border-left-color: var(--status-ok);
}

.status-panel--bad {
  border-left-color: var(--status-bad);
}

.status-copy {
  min-width: 190px;
  display: block;
}

.status-copy h2 {
  margin: 0;
  color: var(--tl-blue-dark);
  font-size: 1rem;
  line-height: 1.1;
  letter-spacing: 0;
}

.status-copy p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 650;
  line-height: 1.2;
}

.status-systems {
  display: flex !important;
  grid-template-columns: none !important;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
}

.status-item {
  min-width: auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid rgba(7, 48, 94, 0.10);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  padding: 5px 9px 5px 5px;
}

.status-item strong {
  min-width: 0;
  overflow: visible;
  color: var(--tl-blue-dark);
  font-size: 0.95rem;
  line-height: 1.1;
  letter-spacing: 0;
  text-overflow: clip;
  white-space: nowrap;
}

.status-label {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.status-speed {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  line-height: 1.05;
  white-space: nowrap;
}

.status-item--good {
  border-color: rgba(23, 138, 71, 0.24);
}

.status-item--ok {
  border-color: rgba(169, 107, 0, 0.26);
}

.status-item--bad {
  border-color: rgba(196, 43, 43, 0.24);
}

.status-face {
  --face-main: var(--status-good);
  position: relative;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--face-main);
}

.status-item--ok .status-face {
  --face-main: var(--status-ok);
}

.status-item--bad .status-face {
  --face-main: var(--status-bad);
}

.status-face-eye {
  position: absolute;
  top: 30%;
  width: 3px;
  height: 5px;
  border-radius: 999px;
  background: #172218;
}

.status-face-eye-left {
  left: 31%;
}

.status-face-eye-right {
  right: 31%;
}

.status-face-mouth {
  position: absolute;
  left: 50%;
  bottom: 25%;
  width: 46%;
  height: 24%;
  transform: translateX(-50%);
  border-bottom: 3px solid #172218;
  border-radius: 0 0 999px 999px;
}

.status-item--ok .status-face-mouth {
  bottom: 37%;
  height: 0;
  border-radius: 999px;
}

.status-item--bad .status-face-mouth {
  bottom: 20%;
  border-bottom: 0;
  border-top: 3px solid #172218;
  border-radius: 999px 999px 0 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

@media (max-width: 700px) {
  .status-panel {
    align-items: flex-start;
    flex-direction: column;
  }

  .status-systems {
    justify-content: flex-start;
  }
}
