:root {
  --page-background: #0b1017;
  --page-background-soft: #111923;
  --panel-background: rgba(18, 27, 38, 0.88);
  --panel-background-hover: rgba(25, 37, 51, 0.96);

  --border-color: rgba(255, 255, 255, 0.11);
  --border-color-strong: rgba(255, 255, 255, 0.18);

  --text-primary: #f7f9fb;
  --text-secondary: #aab5c2;
  --text-muted: #7f8b98;

  --accent: #db8b32;
  --accent-hover: #eba04a;
  --accent-soft: rgba(219, 139, 50, 0.14);

  --success: #56c58b;

  --shadow-large: 0 30px 80px rgba(0, 0, 0, 0.34);
  --shadow-small: 0 12px 30px rgba(0, 0, 0, 0.18);

  --radius-large: 26px;
  --radius-medium: 17px;
  --radius-small: 11px;

  --content-width: 1280px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--page-background);
}

body {
  min-height: 100vh;
  margin: 0;

  color: var(--text-primary);
  background:
    radial-gradient(
      circle at 75% 10%,
      rgba(219, 139, 50, 0.10),
      transparent 30%
    ),
    radial-gradient(
      circle at 15% 85%,
      rgba(54, 94, 132, 0.16),
      transparent 35%
    ),
    linear-gradient(
      145deg,
      var(--page-background) 0%,
      var(--page-background-soft) 100%
    );

  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;

  line-height: 1.5;
}

a {
  color: inherit;
}

.portal-page {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.portal-header {
  display: flex;
  width: min(calc(100% - 48px), var(--content-width));
  margin: 0 auto;
  padding: 30px 0;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.portal-brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;

  color: var(--text-primary);
  text-decoration: none;
}

.portal-brand-mark {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;

  border: 1px solid rgba(219, 139, 50, 0.50);
  border-radius: 14px;

  color: #121212;
  background: var(--accent);

  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.04em;

  box-shadow:
    0 10px 26px rgba(219, 139, 50, 0.20),
    inset 0 1px 0 rgba(255, 255, 255, 0.30);
}

.portal-brand-text {
  display: flex;
  flex-direction: column;
}

.portal-brand-text strong {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.portal-brand-text span {
  color: var(--text-secondary);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.portal-header-status {
  display: inline-flex;
  padding: 9px 13px;
  align-items: center;
  gap: 9px;

  border: 1px solid var(--border-color);
  border-radius: 999px;

  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.035);

  font-size: 13px;
}

.status-indicator {
  width: 8px;
  height: 8px;

  border-radius: 50%;
  background: var(--success);

  box-shadow: 0 0 0 4px rgba(86, 197, 139, 0.12);
}

.portal-main {
  display: flex;
  flex: 1;
  align-items: center;
}

.portal-hero {
  display: grid;
  width: min(calc(100% - 48px), var(--content-width));
  margin: 0 auto;
  padding: 64px 0 88px;
  grid-template-columns: minmax(0, 0.9fr) minmax(480px, 1.1fr);
  gap: 72px;
  align-items: center;
}

.portal-hero-content {
  max-width: 610px;
}

.portal-eyebrow {
  margin: 0 0 18px;

  color: var(--accent);

  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.portal-hero h1 {
  margin: 0;

  font-size: clamp(48px, 6vw, 82px);
  font-weight: 760;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.portal-introduction {
  max-width: 580px;
  margin: 28px 0 0;

  color: var(--text-secondary);

  font-size: 18px;
  line-height: 1.75;
}

.portal-actions {
  display: flex;
  margin-top: 36px;
  flex-wrap: wrap;
  gap: 13px;
}

.button {
  display: inline-flex;
  min-height: 48px;
  padding: 0 20px;
  align-items: center;
  justify-content: center;

  border: 1px solid transparent;
  border-radius: var(--radius-small);

  font-size: 15px;
  font-weight: 700;
  text-decoration: none;

  transition:
    background-color 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: #17130e;
  background: var(--accent);
  box-shadow: 0 14px 30px rgba(219, 139, 50, 0.20);
}

.button-primary:hover {
  background: var(--accent-hover);
}

.button-secondary {
  border-color: var(--border-color-strong);

  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.035);
}

.button-secondary:hover {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.07);
}

.portal-access-note {
  margin: 18px 0 0;

  color: var(--text-muted);

  font-size: 13px;
}

.portal-system-panel {
  overflow: hidden;

  border: 1px solid var(--border-color);
  border-radius: var(--radius-large);

  background:
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.055),
      rgba(255, 255, 255, 0.018)
    ),
    var(--panel-background);

  box-shadow: var(--shadow-large);
  backdrop-filter: blur(18px);
}

.system-panel-header {
  display: flex;
  padding: 21px 23px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;

  border-bottom: 1px solid var(--border-color);

  color: var(--text-primary);

  font-size: 14px;
  font-weight: 700;
}

.system-panel-label {
  color: var(--text-muted);

  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
}

.division-grid {
  display: grid;
  padding: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.division-card {
  display: flex;
  min-height: 170px;
  padding: 20px;
  flex-direction: column;
  gap: 25px;

  border: 1px solid var(--border-color);
  border-radius: var(--radius-medium);

  background: rgba(255, 255, 255, 0.025);

  transition:
    border-color 160ms ease,
    background-color 160ms ease,
    transform 160ms ease;
}

.division-card:hover {
  border-color: rgba(219, 139, 50, 0.28);
  background: var(--panel-background-hover);
  transform: translateY(-3px);
}

.division-code {
  display: inline-flex;
  width: fit-content;
  min-height: 30px;
  padding: 0 10px;
  align-items: center;

  border: 1px solid rgba(219, 139, 50, 0.20);
  border-radius: 8px;

  color: var(--accent);
  background: var(--accent-soft);

  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.division-card h2 {
  margin: 0;

  font-size: 16px;
  font-weight: 700;
}

.division-card p {
  margin: 8px 0 0;

  color: var(--text-secondary);

  font-size: 13px;
  line-height: 1.65;
}

.portal-footer {
  display: flex;
  width: min(calc(100% - 48px), var(--content-width));
  margin: 0 auto;
  padding: 24px 0 30px;
  justify-content: space-between;
  gap: 20px;

  border-top: 1px solid var(--border-color);

  color: var(--text-muted);

  font-size: 12px;
}

.portal-footer p {
  margin: 0;
}

@media (max-width: 1000px) {
  .portal-hero {
    padding-top: 44px;
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .portal-hero-content {
    max-width: 720px;
  }
}

@media (max-width: 680px) {
  .portal-header,
  .portal-hero,
  .portal-footer {
    width: min(calc(100% - 32px), var(--content-width));
  }

  .portal-header {
    padding-top: 20px;
  }

  .portal-header-status {
    display: none;
  }

  .portal-hero {
    padding: 40px 0 60px;
  }

  .portal-hero h1 {
    font-size: clamp(44px, 15vw, 66px);
  }

  .portal-introduction {
    font-size: 16px;
  }

  .portal-actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

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

  .division-card {
    min-height: auto;
  }

  .portal-footer {
    flex-direction: column;
  }
}

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