/* ============================================
   PHANTOM WING — Core Stylesheet
   Stealth / tactical aesthetic
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@300;400;500;600;700&family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* Surfaces */
  --bg-0: #050608;
  --bg-1: #0c0e12;
  --bg-2: #14171c;
  --bg-3: #1c2028;
  --bg-4: #262b35;

  /* Text */
  --text-0: #e8eaed;
  --text-1: #9aa0a6;
  --text-2: #5f6368;
  --text-3: #3c4148;

  /* Accent */
  --accent: #c41e3a;
  --accent-bright: #e63950;
  --accent-dim: #7a1424;
  --accent-glow: rgba(196, 30, 58, 0.35);

  /* Status */
  --ok: #10b981;
  --warn: #d97706;
  --info: #3b82f6;
  --classified: #ff4444;

  /* Layout */
  --border: 1px solid var(--bg-3);
  --border-strong: 1px solid var(--bg-4);
  --radius: 2px;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.6);

  /* Type */
  --font-display: 'Rajdhani', 'Segoe UI', sans-serif;
  --font-body: 'Inter', 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Consolas', monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* ============================================
   Custom scrollbars — match the dark/red aesthetic
   ============================================ */

/* Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--accent-dim) var(--bg-1);
}

/* WebKit (Chrome, Edge, Safari) */
*::-webkit-scrollbar           { width: 10px; height: 10px; }
*::-webkit-scrollbar-track     { background: var(--bg-1); border-left: 1px solid var(--bg-3); }
*::-webkit-scrollbar-thumb     {
  background: var(--bg-3);
  border: 2px solid var(--bg-1);
  border-radius: 0;
  transition: background .15s;
}
*::-webkit-scrollbar-thumb:hover  { background: var(--accent-dim); }
*::-webkit-scrollbar-thumb:active { background: var(--accent); }
*::-webkit-scrollbar-corner    { background: var(--bg-1); }

/* Hide the document-level scrollbar entirely. Internal scrollable
   containers (chat feeds, member lists, forum lists) keep their
   styled scrollbars; only the html / body / iframe page-level
   gutter — the one that reserves 10px on the right edge of every
   page — is suppressed. Scroll still works via wheel / keyboard / touch. */
html::-webkit-scrollbar,
body::-webkit-scrollbar { display: none !important; width: 0 !important; }
html, body { scrollbar-width: none !important; }

html, body {
  height: 100%;
  background: var(--bg-0);
  color: var(--text-0);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body {
  background:
    radial-gradient(ellipse at top, rgba(196, 30, 58, 0.04), transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(58, 138, 138, 0.03), transparent 60%),
    var(--bg-0);
  min-height: 100vh;
}

/* Scanline texture overlay (subtle) */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    rgba(255, 255, 255, 0.012) 0,
    rgba(255, 255, 255, 0.012) 1px,
    transparent 1px,
    transparent 3px
  );
  z-index: 1;
  mix-blend-mode: overlay;
}

/* Headings */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

h1 { font-size: 2.4rem; line-height: 1.1; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.2rem; }
h4 { font-size: 1rem; letter-spacing: 0.08em; }

a { color: var(--accent-bright); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ============================================
   PUBLIC LANDING PAGE
   ============================================ */

.landing {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  position: relative;
  z-index: 2;
}

.landing-nav {
  padding: 1.5rem 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.landing-mark {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.4em;
  font-size: 0.85rem;
  color: var(--text-1);
}

.landing-mark::before {
  content: '◢';
  color: var(--accent);
  margin-right: 0.6rem;
}

.landing-access {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-2);
  border: 1px solid var(--bg-3);
  padding: 0.5rem 1rem;
  transition: all 0.2s;
}

.landing-access:hover {
  color: var(--accent-bright);
  border-color: var(--accent-dim);
  text-decoration: none;
  background: rgba(196, 30, 58, 0.04);
}

.landing-hero {
  display: grid;
  place-items: center;
  text-align: center;
  padding: 2rem;
}

.landing-sigil {
  font-family: var(--font-display);
  font-size: clamp(3rem, 12vw, 8rem);
  font-weight: 300;
  letter-spacing: 0.6em;
  /* `letter-spacing` adds 0.6em of trailing space after every glyph,
     including the last one.  Without compensation, when the block is
     centered by the parent grid the visible glyphs end up ~0.3em left
     of true centre because the trailing space takes up the right side
     of the block.  Matching padding-left rebalances it so the visible
     P·W appears centred. */
  padding-left: 0.6em;
  line-height: 1;
  color: var(--text-0);
  text-shadow: 0 0 40px rgba(196, 30, 58, 0.15);
  margin-bottom: 1.5rem;
  position: relative;
}

.landing-sigil::after {
  content: '';
  position: absolute;
  bottom: -1rem;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.landing-quote {
  margin-top: 3rem;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 300;
  font-size: 1.1rem;
  letter-spacing: 0.05em;
  color: var(--text-1);
  /* Force the line to stay on a single row regardless of the parent's
     available width.  The previous `max-width: 560px` was triggering
     a wrap because the full quote (with both guillemets) renders wider
     than 560px at this font-size. */
  white-space: nowrap;
}

.landing-quote-mark {
  color: var(--accent);
  font-size: 1.3rem;
  margin: 0 0.4rem;
}

.landing-classified {
  margin-top: 4rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.4em;
  color: var(--text-2);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: center;
}

.redacted {
  display: inline-block;
  background: var(--text-0);
  color: var(--text-0);
  user-select: none;
  padding: 0 0.3em;
}

.landing-footer {
  padding: 2rem 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-3);
}

/* ============================================
   LOGIN
   ============================================ */

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
  position: relative;
  z-index: 2;
}

.auth-card {
  background: var(--bg-1);
  border: var(--border);
  padding: 3rem 2.5rem;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow);
  position: relative;
}

.auth-card::before,
.auth-card::after {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  border: 1px solid var(--accent);
}
.auth-card::before { top: -1px; left: -1px; border-right: none; border-bottom: none; }
.auth-card::after { bottom: -1px; right: -1px; border-left: none; border-top: none; }

.auth-card h2 {
  font-size: 1.4rem;
  letter-spacing: 0.2em;
  margin-bottom: 0.4rem;
}

.auth-sub {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text-2);
  margin-bottom: 2rem;
}

.field {
  margin-bottom: 1.25rem;
}

.field label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-1);
  margin-bottom: 0.4rem;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  background: var(--bg-0);
  border: 1px solid var(--bg-3);
  color: var(--text-0);
  padding: 0.7rem 0.85rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: var(--accent-dim);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.btn {
  display: inline-block;
  background: var(--accent);
  color: white;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-size: 0.85rem;
  padding: 0.75rem 1.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
}
.btn:hover { background: var(--accent-bright); text-decoration: none; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-block { width: 100%; }
.btn-ghost {
  background: transparent;
  color: var(--text-1);
  border: 1px solid var(--bg-3);
}
.btn-ghost:hover { color: var(--text-0); border-color: var(--bg-4); background: var(--bg-2); }
.btn-danger { background: var(--accent-dim); }
.btn-danger:hover { background: var(--accent); }
.btn-sm { padding: 0.4rem 0.8rem; font-size: 0.7rem; }

.auth-msg {
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--classified);
  min-height: 1rem;
}

.auth-hint {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px dashed var(--bg-3);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  color: var(--text-2);
  line-height: 1.7;
}

.auth-hint code {
  color: var(--text-1);
  background: var(--bg-2);
  padding: 0.1rem 0.4rem;
}

.auth-back {
  display: block;
  text-align: center;
  margin-top: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-2);
}
