:root {
  --bg: #0c1118;
  --bg-elevated: #141b26;
  --surface: #1a2332;
  --surface-2: #243044;
  --card: #1e2838;
  --border: rgba(226, 232, 240, 0.1);
  --border-strong: rgba(226, 232, 240, 0.18);
  --text: #e8edf4;
  --muted: #9aa8bc;
  --red: #ef3e42;
  --red-soft: #ff6b6b;
  --red-deep: #c1292d;
  --blue: #3b82f6;
  --white: #ffffff;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
  --radius: 16px;
  --nav-h: 84px;
  --max: 1120px;
  --font-display: "Orbitron", sans-serif;
  --font-body: "Inter", "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea {
  font: inherit;
  color: inherit;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.2;
  letter-spacing: 0.02em;
  margin: 0 0 0.75rem;
}

p {
  margin: 0 0 1rem;
}

p:last-child {
  margin-bottom: 0;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 1rem;
  z-index: 2000;
  background: var(--red);
  color: var(--white);
  padding: 0.5rem 0.9rem;
  border-radius: 8px;
}

.skip-link:focus {
  left: 1rem;
}

.container {
  width: min(var(--max), calc(100% - 2.5rem));
  margin-inline: auto;
}

.nav-shell {
  width: min(1280px, calc(100% - 2rem));
  margin-inline: auto;
}

.logic-red {
  color: var(--red-soft);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(12, 17, 24, 0.78);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

.site-header.is-scrolled {
  background: rgba(12, 17, 24, 0.94);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.28);
}

.nav-inner {
  min-height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.brand img {
  height: 42px;
  width: auto;
}

.brand-tagline {
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  color: var(--muted);
  text-shadow: 0 0 10px rgba(59, 130, 246, 0.35);
}

.nav-toggle {
  display: none;
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border-radius: 10px;
  cursor: pointer;
}

.nav-toggle:focus-visible,
.nav-links a:focus-visible,
.has-sub > button:focus-visible,
.cta:focus-visible {
  outline: 2px solid var(--red-soft);
  outline-offset: 3px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-links a,
.has-sub > button {
  background: none;
  border: 0;
  color: var(--text);
  cursor: pointer;
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  font-size: 0.92rem;
  transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover,
.has-sub > button:hover,
.nav-links a.is-active {
  color: var(--red-soft);
  background: rgba(239, 62, 66, 0.08);
}

.has-sub {
  position: relative;
}

.sub-menu {
  position: absolute;
  top: calc(100% + 0.4rem);
  left: 0;
  min-width: 200px;
  padding: 0.45rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.has-sub:hover .sub-menu,
.has-sub:focus-within .sub-menu,
.has-sub.is-open .sub-menu {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.sub-menu a {
  display: block;
  border-radius: 8px;
  padding: 0.65rem 0.8rem;
}

.nav-portal {
  margin-left: 0.4rem;
  border: 1px solid rgba(239, 62, 66, 0.45) !important;
  color: var(--red-soft) !important;
}

.nav-portal:hover,
.nav-portal.is-active {
  background: var(--red) !important;
  color: var(--white) !important;
  border-color: var(--red) !important;
}

/* Hero */
.hero {
  position: relative;
  min-height: 86vh;
  display: grid;
  place-items: center;
  text-align: center;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  isolation: isolate;
}

.hero-page {
  min-height: 52vh;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(12, 17, 24, 0.42) 0%, rgba(12, 17, 24, 0.82) 100%),
    radial-gradient(ellipse at center, transparent 20%, rgba(12, 17, 24, 0.5) 100%);
  z-index: -1;
}

.hero-home {
  background-image: url("../images/home-slide-1.png");
}

.hero-about {
  background-image: url("../images/hkj.jpg");
}

.hero-government {
  background-image: url("../images/government");
}

.hero-technology {
  background-image: url("../images/Technology.jpg");
}

.hero-contact {
  background-image: url("../images/contact");
}

.hero-portal {
  background: radial-gradient(circle at top, #1a1020 0%, #05070a 70%);
  min-height: 48vh;
}

.hero-copy {
  width: min(820px, calc(100% - 2.5rem));
  padding: 4.5rem 0.5rem 3.5rem;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--red-soft);
  margin-bottom: 1rem;
  text-shadow: 0 0 16px rgba(255, 107, 107, 0.35);
}

.hero h1 {
  font-size: clamp(1.45rem, 4.6vw, 3.1rem);
  margin-bottom: 1rem;
  text-shadow: 0 0 18px rgba(59, 130, 246, 0.35);
  overflow-wrap: break-word;
}

.hero p.lede {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: #d5deea;
  margin-bottom: 1.8rem;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}

/* Buttons */
.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.85rem 1.4rem;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.cta-primary {
  background: linear-gradient(180deg, var(--red-soft), var(--red));
  color: var(--white);
  box-shadow: 0 8px 24px rgba(239, 62, 66, 0.32);
}

.cta-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(239, 62, 66, 0.45);
}

.cta-ghost {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-strong);
  color: var(--text);
}

.cta-ghost:hover {
  transform: translateY(-2px);
  border-color: var(--red-soft);
}

/* Sections */
.section {
  padding: 5rem 0;
}

.section-muted {
  background:
    linear-gradient(rgba(12, 17, 24, 0.82), rgba(12, 17, 24, 0.88)),
    url("../images/AdobeStock_173122779.jpeg") center / cover no-repeat;
}

.section-head {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 2.8rem;
}

.section-head h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
}

.section-head p {
  color: var(--muted);
}

.section-head p + p {
  margin-top: 0.85rem;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.15rem;
}

.detail-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.4rem 1.35rem 1.5rem;
}

.detail-card h3 {
  font-size: 1rem;
  color: var(--red-soft);
  margin-bottom: 0.5rem;
}

.detail-card p {
  color: var(--muted);
  font-size: 0.95rem;
}

.focus-list.described {
  gap: 0.9rem;
}

.focus-list.described li {
  padding-left: 1.25rem;
}

.focus-list.described strong {
  display: block;
  color: var(--text);
  font-family: var(--font-display);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  margin-bottom: 0.2rem;
}

/* Cards */
.card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.4rem;
}

.service-card {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  min-height: 100%;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.service-card:hover {
  transform: translateY(-8px);
  border-color: rgba(239, 62, 66, 0.45);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(239, 62, 66, 0.15);
}

.service-card img {
  width: 100%;
  height: 210px;
  object-fit: cover;
}

.service-card .card-body {
  padding: 1.3rem 1.35rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  flex: 1;
}

.service-card h3 {
  font-size: 1.15rem;
  margin: 0;
}

.service-card p {
  color: var(--muted);
  font-size: 0.95rem;
}

.card-link {
  margin-top: auto;
  color: var(--red-soft);
  font-weight: 600;
  font-size: 0.92rem;
}

.pill-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.pill {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.3rem 1.2rem;
}

.pill h3 {
  font-size: 0.95rem;
  color: var(--red-soft);
  margin-bottom: 0.4rem;
}

.pill p {
  color: var(--muted);
  font-size: 0.92rem;
}

.split {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 3rem;
  align-items: center;
}

.split img {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  object-fit: cover;
  min-height: 320px;
  max-height: 460px;
}

.split-copy h2 {
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
}

.split-copy p {
  color: #c9d4e3;
}

.focus-list {
  list-style: none;
  padding: 0;
  margin: 1.2rem 0 0;
  display: grid;
  gap: 0.55rem;
}

.focus-list li {
  position: relative;
  padding-left: 1.2rem;
  color: var(--muted);
}

.focus-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 10px rgba(239, 62, 66, 0.7);
}

.cta-band {
  padding: 3.5rem 0;
  text-align: center;
  background: linear-gradient(90deg, rgba(239, 62, 66, 0.12), rgba(59, 130, 246, 0.1));
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.cta-band h2 {
  margin-bottom: 0.6rem;
}

.cta-band p {
  color: var(--muted);
  margin-bottom: 1.4rem;
}

/* Forms */
.contact-layout {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 2rem;
  align-items: start;
}

.glass {
  background: rgba(20, 27, 38, 0.7);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow);
}

.contact-meta h3,
.glass h3 {
  font-size: 1.05rem;
  margin-bottom: 0.8rem;
}

.contact-meta p,
.contact-meta a {
  color: var(--muted);
}

.contact-meta a:hover {
  color: var(--red-soft);
}

.field {
  margin-bottom: 1rem;
}

.field label {
  display: block;
  font-size: 0.82rem;
  margin-bottom: 0.35rem;
  color: var(--muted);
}

.field input,
.field textarea {
  width: 100%;
  background: rgba(8, 12, 18, 0.55);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.8rem 0.9rem;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--red-soft);
  box-shadow: 0 0 0 3px rgba(239, 62, 66, 0.18);
}

.form-note,
.form-error,
.form-success {
  font-size: 0.9rem;
  margin-top: 0.8rem;
}

.form-error {
  color: var(--red-soft);
}

.form-success {
  color: #7dd3a8;
}

.is-hidden {
  display: none !important;
}

.resource-links {
  display: grid;
  gap: 0.7rem;
  margin-top: 1.2rem;
}

/* Footer */
.site-footer {
  background: #0d131c;
  border-top: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(239, 62, 66, 0.28);
  padding: 2.8rem 0 1.5rem;
  text-align: center;
}

.footer-grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.15rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.footer-brand img {
  height: 38px;
  width: auto;
  margin: 0 auto 0.55rem;
}

.footer-brand p,
.copyright {
  color: var(--muted);
  font-size: 0.88rem;
  margin: 0;
}

.footer-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.15rem 0;
  row-gap: 0.35rem;
}

.footer-nav a {
  color: var(--text);
  font-size: 0.9rem;
  padding: 0.2rem 0.85rem;
}

.footer-nav a + a {
  border-left: 1px solid var(--border-strong);
}

.footer-nav a:hover {
  color: var(--red-soft);
}

.socials {
  display: flex;
  justify-content: center;
  gap: 0.7rem;
}

.socials a {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--muted);
}

.socials a:hover {
  border-color: var(--red-soft);
  color: var(--red-soft);
}

.socials svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.copyright {
  width: 100%;
  margin-top: 0.6rem;
  padding-top: 1.15rem;
  border-top: 1px solid var(--border);
}

/* Back to top */
#back-to-top {
  position: fixed;
  right: 1.1rem;
  bottom: 1.1rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 0;
  background: var(--blue);
  color: var(--white);
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 50;
}

#back-to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
}

#back-to-top:hover {
  transform: translateY(-2px);
}

/* Portal */
#matrix {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.page-portal .site-header,
.page-portal .site-footer,
.page-portal main {
  position: relative;
  z-index: 1;
}

.page-portal {
  background: transparent;
}

.page-portal .hero-portal {
  background: radial-gradient(circle at top, rgba(26, 16, 32, 0.72) 0%, rgba(5, 7, 10, 0.55) 70%);
}

.login-wrap {
  max-width: 460px;
  margin: 0 auto;
}

#employee-login {
  min-height: 70vh;
  padding-top: 1.5rem;
  padding-bottom: 6rem;
}

#loading-screen {
  position: fixed;
  inset: 0;
  background: #000;
  display: none;
  place-items: center;
  z-index: 2000;
}

#loading-screen.is-on {
  display: grid;
}

#loading-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.access-toast {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2100;
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 4vw, 2.4rem);
  color: var(--red);
  background: #fff;
  padding: 1rem 1.4rem;
  border: 2px solid var(--red);
  border-radius: 12px;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.shake {
  animation: shake 0.3s ease;
}

@media (max-width: 900px) {
  .card-grid,
  .pill-grid,
  .detail-grid,
  .split,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .split img {
    min-height: 240px;
    max-height: 320px;
  }
}

@media (max-width: 768px) {
  :root {
    --nav-h: 72px;
  }

  .nav-toggle {
    display: grid;
    place-items: center;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.2rem;
    padding: 0.8rem 1.1rem 1.1rem;
    background: #101722;
    border-bottom: 1px solid var(--border);
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-portal {
    margin-left: 0;
    text-align: center;
  }

  .sub-menu {
    position: static;
    opacity: 1;
    pointer-events: none;
    transform: none;
    display: none;
    box-shadow: none;
    background: rgba(0, 0, 0, 0.25);
    margin: 0.2rem 0 0.4rem;
  }

  .has-sub.is-open .sub-menu {
    display: block;
    pointer-events: auto;
  }

  .hero,
  .hero-page,
  .section-muted {
    background-attachment: scroll;
  }

  .hero {
    min-height: 72vh;
  }

  .section {
    padding: 3.4rem 0;
  }

  .brand-tagline {
    display: none;
  }

  .footer-nav {
    gap: 0.35rem 0.9rem;
  }

  .footer-nav a {
    padding: 0.2rem 0.15rem;
  }

  .footer-nav a + a {
    border-left: 0;
  }

  .site-footer {
    padding-bottom: 4.25rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}
