:root {
  --antagonist-black: #050304;
  --antagonist-panel: rgba(18, 7, 10, 0.94);
  --antagonist-panel-raised: rgba(31, 9, 14, 0.82);
  --antagonist-red: #e33b47;
  --antagonist-red-bright: #ff6670;
  --antagonist-text: #f6eeee;
  --antagonist-muted: #cdbdc0;
  --antagonist-line: rgba(255, 86, 98, 0.42);
}

* {
  box-sizing: border-box;
}

.antagonist-page {
  --global-nav-background: #080305;
  --global-footer-background: #180509;
  --global-footer-color: #f8e9eb;
  min-width: 320px;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
  overflow-x: hidden;
  color: var(--antagonist-text);
  background:
    linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    radial-gradient(
      circle at 68% 22%,
      rgba(179, 18, 35, 0.24),
      transparent 40rem
    ),
    var(--antagonist-black);
  background-size:
    34px 34px,
    34px 34px,
    auto,
    auto;
  font-family: Georgia, "Times New Roman", serif;
}

.antagonist-page .navbar {
  border-bottom: 1px solid var(--antagonist-line);
  background: rgba(8, 3, 5, 0.97);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.38);
}

.antagonist-page .nav-links a {
  color: #f3e8ea;
}

.antagonist-page .nav-links a:hover,
.antagonist-page .nav-links a:focus-visible,
.antagonist-page .nav-links a.active {
  color: var(--antagonist-red-bright);
}

.antagonist-page .site-footer {
  border-top: 1px solid var(--antagonist-line);
  color: var(--global-footer-color);
  background: linear-gradient(90deg, #0c0305, #24070d 50%, #0c0305);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.36);
}

.antagonist-interface {
  width: min(100% - (2 * var(--global-page-gutter)), 1320px);
  min-height: calc(100vh - var(--global-header-height));
  min-height: calc(100svh - var(--global-header-height));
  margin-inline: auto;
  padding-block: calc(var(--global-header-height) + clamp(1.5rem, 4vw, 3rem))
    clamp(2rem, 5vw, 4rem);
}

.interface-loading,
.interface-error {
  margin: 20vh auto;
  color: var(--antagonist-red-bright);
  font:
    600 0.8rem/1.6 Georgia,
    "Times New Roman",
    serif;
  letter-spacing: 0.14em;
  text-align: center;
  text-transform: uppercase;
}

.antagonist-shell {
  position: relative;
  border: 1px solid var(--antagonist-line);
  background: linear-gradient(
    145deg,
    rgba(22, 8, 12, 0.97),
    rgba(3, 2, 3, 0.99)
  );
  box-shadow:
    0 35px 90px rgba(0, 0, 0, 0.65),
    inset 0 0 70px rgba(141, 12, 23, 0.05);
  overflow: hidden;
}

.antagonist-shell::before,
.status-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    transparent 0 3px,
    rgba(255, 255, 255, 0.014) 3px 4px
  );
}

.profile-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(280px, 0.94fr) minmax(280px, 1.06fr);
  min-height: clamp(650px, 62vw, 780px);
}

.profile-copy {
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(2.25rem, 5vw, 4.75rem);
  background: linear-gradient(
    90deg,
    #080406 0 78%,
    rgba(8, 4, 6, 0.68) 90%,
    transparent
  );
}

.eyebrow,
.status-kicker,
.anomaly-label {
  margin: 0 0 1rem;
  color: var(--antagonist-red-bright);
  font:
    700 clamp(0.7rem, 1vw, 0.82rem)/1.4 Georgia,
    "Times New Roman",
    serif;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.eyebrow::before,
.status-kicker::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 0.6rem;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 12px currentColor;
}

.profile-title {
  max-width: 11ch;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.65rem, 5vw, 5.15rem);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}

.profile-title-line,
.profile-title-accent {
  display: block;
}

.profile-title-accent {
  color: var(--antagonist-red-bright);
  text-shadow: 0 0 24px rgba(227, 59, 71, 0.24);
}

.profile-quote {
  display: grid;
  max-width: 40ch;
  gap: 0.2rem;
  margin: clamp(1.5rem, 3vw, 2.4rem) 0 0;
  color: #e1d5d7;
  font-family: Georgia, serif;
  font-size: clamp(0.96rem, 1.2vw, 1.12rem);
  line-height: 1.48;
}

.profile-quote > span {
  display: block;
}

.profile-quote .quote-alert {
  margin-top: 0.7rem;
  color: #ff7a83;
  font-weight: 700;
}

.profile-quote .quote-alert + .quote-alert {
  margin-top: 0;
}

.profile-button {
  display: inline-flex;
  width: fit-content;
  margin-top: 2rem;
  padding: 0.85rem 1.5rem;
  min-height: 46px;
  align-items: center;
  border: 1px solid var(--antagonist-red-bright);
  color: #fff;
  background: linear-gradient(
    135deg,
    rgba(227, 59, 71, 0.24),
    rgba(83, 12, 22, 0.24)
  );
  font:
    700 0.75rem/1 Georgia,
    "Times New Roman",
    serif;
  letter-spacing: 0.13em;
  text-decoration: none;
  text-transform: uppercase;
  transition:
    background 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

.profile-button:hover,
.profile-button:focus-visible {
  background: rgba(213, 42, 55, 0.2);
  box-shadow: 0 0 26px rgba(255, 70, 83, 0.32);
  transform: translateY(-2px);
}

.profile-visual {
  position: relative;
  min-height: 100%;
  overflow: hidden;
  background: #090406 url("../../assets/antagonists/img_1.png") center 18% /
    cover no-repeat;
}

.profile-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, #050405 0, transparent 32%),
    linear-gradient(0deg, rgba(0, 0, 0, 0.72), transparent 45%);
}

.profile-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
  filter: saturate(0.86) contrast(1.12) brightness(0.78);
}

.status-panel {
  position: relative;
  display: grid;
  grid-template-columns: 0.9fr 1.2fr 0.82fr;
  gap: clamp(1.25rem, 3vw, 3rem);
  padding: clamp(1.5rem, 4vw, 3.5rem);
  border-top: 1px solid var(--antagonist-line);
  background: linear-gradient(
    135deg,
    var(--antagonist-panel),
    rgba(8, 4, 6, 0.97)
  );
}

.status-alert,
.status-metrics,
.anomaly-card {
  position: relative;
  z-index: 1;
}

.alert-row {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.alert-row > div {
  min-width: 0;
}

.alert-icon {
  display: grid;
  flex: 0 0 88px;
  width: 88px;
  height: 88px;
  place-items: center;
  border: 1px solid var(--antagonist-red);
  border-radius: 50%;
  color: var(--antagonist-red-bright);
  box-shadow:
    0 0 28px rgba(213, 42, 55, 0.2),
    inset 0 0 22px rgba(213, 42, 55, 0.1);
  font:
    400 2.4rem/1 Georgia,
    serif;
}

.alert-title {
  margin: 0;
  color: var(--antagonist-red-bright);
  font:
    500 clamp(1.35rem, 2.6vw, 2.2rem)/1.1 Georgia,
    "Times New Roman",
    serif;
  text-transform: uppercase;
}

.alert-copy {
  margin: 0.6rem 0 0;
  color: #e1d7d9;
  overflow-wrap: anywhere;
}

.metric-list {
  display: grid;
  gap: 1rem;
  margin: 0.3rem 0 0;
  padding: 0;
  list-style: none;
}

.metric {
  display: grid;
  grid-template-columns: minmax(110px, 0.8fr) 1fr auto;
  align-items: center;
  gap: 0.75rem;
  color: var(--antagonist-muted);
  font:
    600 0.72rem/1.3 Georgia,
    "Times New Roman",
    serif;
  text-transform: uppercase;
}

.metric-track {
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  overflow: hidden;
}

.metric-fill {
  display: block;
  height: 100%;
  background: var(--antagonist-red-bright);
  box-shadow: 0 0 9px rgba(255, 70, 83, 0.72);
}

.metric-fill-32 {
  width: 32%;
}
.metric-fill-41 {
  width: 41%;
}
.metric-fill-58 {
  width: 58%;
}
.metric-fill-64 {
  width: 64%;
}
.metric-fill-100 {
  width: 100%;
}

.metric-value {
  min-width: 3.5ch;
  color: #e7dfe0;
  text-align: right;
}

.metric[data-error="true"] .metric-value {
  color: var(--antagonist-red-bright);
}

.anomaly-card {
  align-self: stretch;
  padding: 1.4rem;
  border: 1px solid var(--antagonist-line);
  background: var(--antagonist-panel-raised);
  box-shadow: inset 0 0 28px rgba(227, 59, 71, 0.06);
}

.anomaly-signal {
  position: relative;
  height: 70px;
  margin-block: 1.25rem;
  overflow: hidden;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(213, 42, 55, 0.15),
    transparent
  );
}

.anomaly-signal::before {
  content: "";
  position: absolute;
  top: 50%;
  width: 100%;
  height: 1px;
  background: var(--antagonist-red);
  box-shadow:
    22px -10px 0 var(--antagonist-red),
    60px 9px 0 var(--antagonist-red),
    92px -16px 0 var(--antagonist-red);
}

.anomaly-copy {
  margin: 0;
  color: #ddd0d2;
  font-size: 0.9rem;
  line-height: 1.55;
}

.intruder-search {
  position: relative;
  display: grid;
  grid-template-columns: minmax(290px, 0.72fr) minmax(440px, 1.28fr);
  border-top: 1px solid var(--antagonist-line);
  background: linear-gradient(
    135deg,
    rgba(17, 7, 9, 0.98),
    rgba(3, 3, 4, 0.98)
  );
  overflow: hidden;
}

.intruder-copy {
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(2rem, 5vw, 4.5rem);
  background: linear-gradient(
    90deg,
    #090406 0 80%,
    rgba(9, 4, 6, 0.68) 91%,
    transparent
  );
}

.intruder-title {
  max-width: 9ch;
  margin: 0;
  font:
    400 clamp(2.5rem, 5vw, 4.9rem)/1 Georgia,
    "Times New Roman",
    serif;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}

.intruder-title span {
  display: block;
  color: var(--antagonist-red-bright);
}

.intruder-title::after {
  content: "";
  display: block;
  width: min(180px, 55%);
  height: 1px;
  margin-top: 1.35rem;
  background: linear-gradient(90deg, var(--antagonist-red), transparent);
  box-shadow: 0 0 8px rgba(213, 42, 55, 0.5);
}

.intruder-narrative {
  max-width: 44ch;
  margin-top: 1.6rem;
  color: #dfd2d4;
  line-height: 1.45;
}

.intruder-narrative p {
  margin-top: 0;
  margin-bottom: 0.35rem;
  line-height: 1.45;
}

.intruder-narrative ul {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
  padding-left: 1.2rem;
}

.intruder-narrative li {
  margin-bottom: 0.25rem;
  line-height: 1.45;
}

.intruder-narrative li::marker {
  color: var(--antagonist-red-bright);
}

.intruder-narrative .intruder-vow {
  margin-top: 0.85rem;
  margin-bottom: 0;
  color: var(--antagonist-red-bright);
  font-weight: 600;
}

.intruder-visual {
  position: relative;
  min-height: 590px;
  overflow: hidden;
  background: #090406 url("../../assets/antagonists/img_2.jpeg") center / cover
    no-repeat;
}

.intruder-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, #070405 0, transparent 31%),
    linear-gradient(0deg, #060405 0, transparent 30%);
  pointer-events: none;
}

.intruder-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: saturate(0.9) contrast(1.1) brightness(0.8);
}

.intel-grid {
  z-index: 2;
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--antagonist-line);
  list-style: none;
}

.intel-card {
  display: grid;
  grid-template-columns: 52px 1fr;
  min-width: 0;
  align-items: start;
  gap: 0.9rem;
  padding: clamp(1.1rem, 2.5vw, 1.8rem);
  border-right: 1px solid var(--antagonist-line);
  background: rgba(5, 3, 4, 0.9);
}

.intel-card:last-child {
  border-right: 0;
}

.intel-symbol {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid var(--antagonist-red);
  color: var(--antagonist-red-bright);
  font-size: 1.55rem;
  box-shadow: inset 0 0 18px rgba(213, 42, 55, 0.1);
}

.intel-card h3 {
  margin: 0 0 0.4rem;
  color: #eee7e8;
  font-size: 0.77rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.intel-card p {
  margin: 0;
  color: var(--antagonist-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

@media (max-width: 940px) {
  .profile-hero {
    grid-template-columns: 1fr;
  }

  .profile-copy {
    min-height: 460px;
    background: linear-gradient(
      0deg,
      #080406 0,
      rgba(8, 4, 6, 0.96) 74%,
      rgba(8, 4, 6, 0.5)
    );
  }

  .profile-visual {
    grid-row: 1;
    height: min(72vw, 620px);
  }

  .profile-visual::after {
    background: linear-gradient(0deg, #050405, transparent 38%);
  }

  .profile-visual img {
    object-position: center 14%;
  }

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

  .status-alert {
    grid-column: 1 / -1;
  }

  .intruder-search {
    grid-template-columns: 1fr;
  }

  .intruder-visual {
    grid-row: 1;
    min-height: 0;
    height: min(66vw, 560px);
  }

  .intruder-visual::after {
    background: linear-gradient(0deg, #070405 0, transparent 38%);
  }

  .intel-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .intel-card:nth-child(even) {
    border-right: 0;
  }
}

@media (max-width: 620px) {
  .antagonist-interface {
    width: 100%;
    padding-top: var(--global-header-height);
  }

  .antagonist-shell {
    border-inline: 0;
  }

  .profile-copy {
    min-height: auto;
    padding: 2rem 1.25rem 2.5rem;
  }

  .profile-visual {
    height: min(112vw, 520px);
    min-height: 390px;
  }

  .profile-title {
    max-width: 100%;
    font-size: clamp(2.15rem, 10.5vw, 3.5rem);
    letter-spacing: 0.01em;
  }

  .profile-visual img {
    object-position: center 26%;
    filter: saturate(1) contrast(1.08) brightness(0.9);
  }

  .profile-visual::after {
    background: linear-gradient(
      0deg,
      #080406 0,
      rgba(8, 4, 6, 0.18) 32%,
      transparent 62%
    );
  }

  .status-panel {
    grid-template-columns: 1fr;
    padding: 1.5rem 1.25rem 2rem;
  }

  .status-alert {
    grid-column: auto;
  }

  .alert-row {
    align-items: flex-start;
  }

  .alert-icon {
    flex-basis: 66px;
    width: 66px;
    height: 66px;
    font-size: 1.8rem;
  }

  .metric {
    grid-template-columns: minmax(96px, 0.9fr) minmax(70px, 1fr) auto;
    gap: 0.55rem;
  }

  .intruder-copy {
    padding: 2rem 1.25rem 2.5rem;
  }

  .intruder-visual {
    height: 72vw;
    min-height: 280px;
  }

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

  .intel-card {
    border-right: 0;
    border-bottom: 1px solid var(--antagonist-line);
  }

  .intel-card:last-child {
    border-bottom: 0;
  }
}

@keyframes threat-pulse {
  0%, 100% {
    opacity: 1;
    filter: drop-shadow(0 0 6px rgba(255, 102, 112, 0.6));
  }
  50% {
    opacity: 0.65;
    filter: drop-shadow(0 0 2px rgba(255, 102, 112, 0.2));
  }
}

.alert-icon,
.anomaly-signal {
  animation: threat-pulse 3.2s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .profile-button,
  .alert-icon,
  .anomaly-signal {
    transition: none;
    animation: none;
  }
}
