/* ==========================================================================
   MRGRAY // PRIVATE SECURITY INFRASTRUCTURE
   Public Landing Page Stylesheet (main.css)
   Aesthetic: Mr. Robot x fsociety x "Hello, Friend" Underground Terminal
   Palette: Void Black, Bone Off-White, Restrained Dark Crimson
   ========================================================================== */

:root {
  --bg-void: #050608;
  --bg-dark: #080a0f;
  --bg-surface: #0e1118;
  --bg-card: rgba(13, 16, 23, 0.7);
  
  --border-subtle: #1c2230;
  --border-active: #2f384c;
  --border-crimson: rgba(197, 34, 31, 0.4);

  --accent-crimson: #c5221f;
  --accent-crimson-bright: #e52925;
  --accent-crimson-dark: #7a1412;
  --accent-crimson-glow: rgba(197, 34, 31, 0.28);

  --text-white: #f2f0eb;
  --text-bone: #dedad2;
  --text-muted: #6f798a;
  --text-dim: #434c5c;

  --font-mono: "Courier New", Courier, ui-monospace, "SF Mono", "Cascadia Code", "JetBrains Mono", monospace;
  --font-display: "Courier New", Courier, monospace;

  --max-width: 1180px;
}

/* Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  background-color: var(--bg-void);
  color: var(--text-bone);
  font-family: var(--font-mono);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
}

body {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  background: var(--bg-void) url("../images/terminal-grid.svg") repeat;
  background-size: 48px 48px;
  display: flex;
  flex-direction: column;
}

/* ==========================================================================
   CRT Scanlines, VHS Distortion & Noise Overlays
   ========================================================================== */

.crt-scanlines {
  position: fixed;
  inset: 0;
  background: linear-gradient(
    rgba(18, 16, 16, 0) 50%, 
    rgba(0, 0, 0, 0.38) 50%
  );
  background-size: 100% 3px;
  z-index: 999;
  pointer-events: none;
  opacity: 0.75;
}

.crt-vignette {
  position: fixed;
  inset: 0;
  background: radial-gradient(
    circle at 50% 50%,
    rgba(0, 0, 0, 0) 50%,
    rgba(5, 6, 8, 0.75) 80%,
    rgba(2, 2, 3, 0.98) 100%
  );
  z-index: 998;
  pointer-events: none;
}

/* Subtle VHS Tracking Bar Artifact */
.vhs-tracking-bar {
  position: fixed;
  left: 0;
  right: 0;
  height: 6px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 0 10px rgba(197, 34, 31, 0.2);
  z-index: 997;
  pointer-events: none;
  opacity: 0.6;
  animation: vhsScroll 18s linear infinite;
}

@keyframes vhsScroll {
  0% { top: -20px; }
  100% { top: 105vh; }
}

/* CRT Ambient Flicker */
.ambient-flicker {
  animation: crtFlicker 12s infinite;
}

@keyframes crtFlicker {
  0%, 100% { opacity: 0.99; }
  2% { opacity: 0.93; }
  4% { opacity: 0.99; }
  28% { opacity: 0.99; }
  29% { opacity: 0.91; filter: drop-shadow(1px 0 0 rgba(197, 34, 31, 0.4)); }
  30% { opacity: 0.99; filter: none; }
  72% { opacity: 0.99; }
  73% { opacity: 0.95; }
  74% { opacity: 0.99; }
}

/* ==========================================================================
   Page Layout Shell
   ========================================================================== */

.page-wrapper {
  position: relative;
  z-index: 10;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* ==========================================================================
   Site Header
   ========================================================================== */

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.25rem;
  margin-bottom: 3.5rem;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-cursor-block {
  display: inline-block;
  width: 11px;
  height: 18px;
  background-color: var(--accent-crimson);
  box-shadow: 0 0 10px var(--accent-crimson-glow);
}

.brand-id {
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--text-white);
  text-transform: uppercase;
}

.header-status {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0.65rem;
  background-color: rgba(14, 17, 24, 0.8);
  border: 1px solid var(--border-subtle);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--accent-crimson);
  box-shadow: 0 0 8px var(--accent-crimson-glow);
  animation: pulseDot 2.8s ease-in-out infinite;
}

@keyframes pulseDot {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; transform: scale(1.15); }
}

/* ==========================================================================
   Hero Section: fsociety / "Hello Friend" Split Composition
   ========================================================================== */

.hero-section {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 3rem;
  align-items: center;
  margin-bottom: 5rem;
}

/* Hero Typography (Left Column) */
.hero-content {
  display: flex;
  flex-direction: column;
}

.hero-lead-salutation {
  font-size: 0.82rem;
  color: var(--accent-crimson);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-lead-salutation::before {
  content: ">";
  color: var(--text-white);
  font-weight: bold;
}

.hero-greeting {
  font-size: clamp(2.5rem, 5.5vw, 4.4rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.05;
  color: var(--text-white);
  margin-bottom: 0.8rem;
  text-transform: uppercase;
  text-shadow: 0 0 20px rgba(0, 0, 0, 0.8);
}

.hero-subbrand {
  font-size: clamp(1.2rem, 2.5vw, 1.8rem);
  font-weight: 700;
  color: var(--accent-crimson);
  letter-spacing: 0.12em;
  margin-bottom: 1.75rem;
  text-transform: uppercase;
  text-shadow: 0 0 14px var(--accent-crimson-glow);
}

.hero-manifesto {
  font-size: 1rem;
  color: var(--text-bone);
  line-height: 1.8;
  max-width: 560px;
  margin-bottom: 2rem;
}

.typewriter-cursor {
  display: inline-block;
  width: 10px;
  height: 1.15em;
  background-color: var(--accent-crimson);
  vertical-align: -2px;
  margin-left: 5px;
  animation: blinkCursor 1s steps(2, start) infinite;
}

@keyframes blinkCursor {
  0%, 100% { opacity: 0; }
  50% { opacity: 1; }
}

/* Hero Telemetry Terminal Card */
.hero-telemetry-box {
  background: rgba(11, 14, 20, 0.85);
  border: 1px solid var(--border-subtle);
  border-left: 2px solid var(--accent-crimson);
  padding: 1.25rem 1.5rem;
  max-width: 500px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.telemetry-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
  padding: 0.35rem 0;
  border-bottom: 1px dashed rgba(28, 34, 48, 0.7);
}

.telemetry-row:last-child {
  border-bottom: none;
}

.telemetry-label {
  color: var(--text-muted);
  letter-spacing: 0.12em;
}

.telemetry-value {
  color: var(--text-white);
  font-weight: 600;
  letter-spacing: 0.08em;
}

.telemetry-value.accent {
  color: var(--accent-crimson);
}

/* ==========================================================================
   Hero Visual Frame: Surveillance Mask Display (Right Column)
   ========================================================================== */

.hero-visual-frame {
  position: relative;
  background: #020304;
  border: 1px solid var(--border-subtle);
  padding: 0.5rem;
  box-shadow: 0 0 35px rgba(0, 0, 0, 0.9), inset 0 0 20px rgba(0, 0, 0, 0.8);
}

.hero-visual-frame::before {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  width: 14px;
  height: 14px;
  border-top: 2px solid var(--accent-crimson);
  border-left: 2px solid var(--accent-crimson);
  z-index: 2;
}

.hero-visual-frame::after {
  content: "";
  position: absolute;
  bottom: -2px;
  right: -2px;
  width: 14px;
  height: 14px;
  border-bottom: 2px solid var(--accent-crimson);
  border-right: 2px solid var(--accent-crimson);
  z-index: 2;
}

.visual-viewport {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: #000000;
}

.hero-mask-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  filter: contrast(1.15) brightness(0.95);
  transition: transform 0.6s ease, filter 0.6s ease;
}

.hero-visual-frame:hover .hero-mask-img {
  filter: contrast(1.22) brightness(1);
  transform: scale(1.02);
}

/* Surveillance OSD (On-Screen Display) Overlay */
.surveillance-osd {
  position: absolute;
  inset: 0;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1rem;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--text-white);
  z-index: 3;
}

.osd-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.osd-rec {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #ff3b30;
  font-weight: 700;
}

.rec-blinker {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #ff3b30;
  animation: blinkRec 1.2s infinite;
}

@keyframes blinkRec {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.15; }
}

.osd-timestamp {
  font-family: var(--font-mono);
  color: #dedad2;
  text-shadow: 0 0 6px rgba(0, 0, 0, 0.9);
}

.osd-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.68rem;
  color: var(--text-muted);
}

.osd-target {
  color: var(--text-bone);
}

/* ==========================================================================
   Dispatches / Principles Grid
   ========================================================================== */

.ambient-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.75rem;
  margin-bottom: 5rem;
}

.ambient-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 1.75rem;
  position: relative;
  transition: all 0.25s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.ambient-card:hover {
  border-color: var(--border-crimson);
  background-color: rgba(18, 22, 32, 0.85);
  transform: translateY(-2px);
}

.card-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.15em;
  margin-bottom: 1.25rem;
  border-bottom: 1px solid rgba(28, 34, 48, 0.6);
  padding-bottom: 0.6rem;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-white);
  margin-bottom: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.card-body {
  font-size: 0.84rem;
  color: var(--text-bone);
  line-height: 1.7;
}

/* ==========================================================================
   Transmission Notice Panel
   ========================================================================== */

.statement-panel {
  border: 1px solid var(--border-subtle);
  background: rgba(10, 13, 18, 0.75);
  padding: 2rem;
  margin-bottom: 4rem;
  position: relative;
}

.statement-panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 50px;
  height: 2px;
  background-color: var(--accent-crimson);
}

.statement-title {
  font-size: 0.76rem;
  letter-spacing: 0.22em;
  color: var(--accent-crimson);
  text-transform: uppercase;
  margin-bottom: 0.85rem;
}

.statement-quote {
  font-size: 1.15rem;
  color: var(--text-white);
  line-height: 1.6;
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.statement-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  max-width: 800px;
  line-height: 1.7;
}

/* ==========================================================================
   Site Footer
   ========================================================================== */

.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding-top: 1.75rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.footer-copy {
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-copy span {
  color: var(--accent-crimson);
}

.footer-compliance {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.compliance-tag {
  color: var(--accent-crimson-dark);
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 900px) {
  .hero-section {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .hero-visual-frame {
    max-width: 440px;
    margin: 0 auto;
    width: 100%;
  }

  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 2.5rem;
  }

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

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}
