/* ═══════════════════════════════════════════
   FRACTURED INTERFACE – SHARED STYLES
   Ghost in the Gutter · Cyberpunk LARP
   ═══════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Share+Tech+Mono&family=Orbitron:wght@400;700;900&family=Exo+2:ital,wght@0,300;0,400;0,600;1,300&display=swap');

:root {
  --neon-cyan: #00f5ff;
  --neon-yellow: #f5e642;
  --neon-red: #ff2d55;
  --neon-orange: #ff6b35;
  --neon-green: #00ff88;
  --dark-bg: #040608;
  --panel-bg: #080d12;
  --panel-border: #0a1a24;
  --mid-gray: #1a2535;
  --text-primary: #c8d8e8;
  --text-dim: #8aa4b6;
  --text-bright: #e8f4ff;
  --scanline-opacity: 0.03;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--dark-bg);
  color: var(--text-primary);
  font-family: 'Exo 2', sans-serif;
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0,245,255,var(--scanline-opacity)) 2px, rgba(0,245,255,var(--scanline-opacity)) 4px);
  pointer-events: none;
  z-index: 1000;
}

/* GLITCH SCAN LINE – global */
.glitch-line {
  position: fixed;
  height: 1px;
  left: 0; right: 0;
  background: linear-gradient(90deg, transparent, var(--neon-cyan), transparent);
  opacity: 0;
  animation: glitch-scan 5s infinite;
  pointer-events: none;
  z-index: 999;
}

@keyframes glitch-scan {
  0%, 85%, 100% { opacity: 0; top: -10px; }
  87% { opacity: 0.6; top: 15%; }
  89% { opacity: 0.3; top: 35%; }
  91% { opacity: 0.7; top: 55%; }
  93% { opacity: 0.4; top: 72%; }
  95% { opacity: 0.8; top: 85%; }
  97% { opacity: 0; top: 110%; }
}

a { color: var(--neon-cyan); }

/* ─── NAVIGATION ─── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  background: rgba(4,6,8,0.92);
  border-bottom: 1px solid var(--neon-cyan);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 max(2rem, calc((100vw - 1340px) / 2));
  height: 56px;
}

.nav-logo {
  font-family: 'Orbitron', monospace;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--neon-cyan);
  letter-spacing: 0.15em;
  text-decoration: none;
  text-transform: uppercase;
}
.nav-logo span { color: var(--neon-yellow); }

.nav-links { display: flex; gap: 2rem; list-style: none; }

.nav-links a {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  color: var(--text-dim);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: color 0.2s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 1px;
  background: var(--neon-cyan);
  transition: width 0.2s;
}
.nav-links a:hover { color: var(--neon-cyan); }
.nav-links a:hover::after { width: 100%; }
.nav-links a.active { color: var(--neon-cyan); }
.nav-links a.active::after { width: 100%; }

.nav-cta {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  color: var(--dark-bg) !important;
  background: var(--neon-cyan);
  padding: 0.3rem 0.9rem;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: background 0.2s;
  clip-path: polygon(6px 0%, 100% 0%, calc(100% - 6px) 100%, 0% 100%);
}
.nav-cta:hover { background: var(--neon-yellow) !important; }
.nav-cta::after { display: none !important; }

/* Mobile hamburger */
.nav-hamburger {
  display: none;
  background: none;
  border: none;
  color: var(--neon-cyan);
  font-size: 1.3rem;
  cursor: pointer;
  font-family: 'Share Tech Mono', monospace;
}

/* ─── PAGE HEADER (subpages) ─── */
.page-header {
  padding: 8rem max(3rem, calc((100vw - 1340px) / 2)) 3rem;
  border-bottom: 1px solid var(--panel-border);
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 80% at 80% 20%, rgba(0,245,255,0.04) 0%, transparent 70%),
    radial-gradient(ellipse 40% 50% at 10% 80%, rgba(255,45,85,0.03) 0%, transparent 60%);
  pointer-events: none;
}

.page-header .section-tag { margin-bottom: 1rem; }

.page-title {
  font-family: 'Orbitron', monospace;
  font-size: clamp(1.8rem, 5vw, 3.5rem);
  font-weight: 900;
  text-transform: uppercase;
  color: var(--text-bright);
  line-height: 1;
  margin-bottom: 1rem;
  position: relative;
}

.page-subtitle {
  font-size: 1rem;
  color: var(--text-dim);
  max-width: 640px;
  line-height: 1.7;
  position: relative;
}

/* ─── SECTION UTILS ─── */
.section-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 3rem;
}

.section-tag {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  color: var(--neon-cyan);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  white-space: nowrap;
}

.section-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--neon-cyan), transparent);
  opacity: 0.3;
}

.content-section {
  padding: 5rem 3rem;
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
}

.content-section.alt-bg {
  background: var(--panel-bg);
  border-top: 1px solid var(--panel-border);
  border-bottom: 1px solid var(--panel-border);
  max-width: none;
}

.content-section.alt-bg > * {
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
}

.content-max {
  max-width: 900px;
}

/* ─── TERMINAL BOX ─── */
.terminal-box {
  background: rgba(0,0,0,0.6);
  border: 1px solid rgba(0,245,255,0.2);
  padding: 2rem;
  position: relative;
  font-family: 'Share Tech Mono', monospace;
  margin-bottom: 2rem;
}
.terminal-box::before {
  content: '● ● ●';
  position: absolute;
  top: 0.7rem; left: 1rem;
  font-size: 0.5rem;
  color: var(--neon-cyan);
  letter-spacing: 0.3em;
}
.terminal-body { margin-top: 1.5rem; }
.terminal-line { font-size: 0.82rem; line-height: 2; color: var(--text-primary); }
.terminal-line .prompt { color: var(--neon-cyan); }
.terminal-line .value { color: var(--neon-yellow); }
.terminal-line .comment { color: var(--text-dim); }
.terminal-line .red { color: var(--neon-red); }
.terminal-divider { height: 1px; background: rgba(0,245,255,0.15); margin: 1rem 0; }

/* ─── ACCORDION / COLLAPSIBLE ─── */
.accordion { max-width: 900px; }

.accordion-item {
  border-bottom: 1px solid var(--panel-border);
}

.accordion-trigger {
  width: 100%;
  background: none;
  border: none;
  color: var(--text-bright);
  font-family: 'Orbitron', monospace;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: left;
  padding: 1.5rem 0;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: color 0.2s;
}

.accordion-trigger:hover { color: var(--neon-cyan); }

.accordion-trigger .arrow {
  font-family: 'Share Tech Mono', monospace;
  color: var(--neon-cyan);
  font-size: 0.9rem;
  transition: transform 0.3s;
}

.accordion-trigger.open .arrow { transform: rotate(90deg); }

.accordion-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

.accordion-inner {
  padding: 0 0 2rem;
  font-size: 0.92rem;
  line-height: 1.8;
  color: var(--text-primary);
}

.accordion-inner p {
  margin-bottom: 1rem;
}

.accordion-inner strong { color: var(--text-bright); font-weight: 600; }

.accordion-inner .rule-note {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.75rem;
  color: var(--neon-yellow);
  border-left: 2px solid var(--neon-yellow);
  padding-left: 1rem;
  margin: 1rem 0;
}

/* ─── FACTION CARDS ─── */
.faction-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5px;
  background: rgba(0,245,255,0.08);
  border: 1px solid rgba(0,245,255,0.08);
  max-width: 1100px;
}

.faction-card {
  background: var(--dark-bg);
  padding: 2.5rem 2rem;
  transition: background 0.3s;
  position: relative;
}

.faction-card:hover { background: rgba(0,245,255,0.03); }

.faction-tag {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.6rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin-bottom: 0.8rem;
}
.faction-tag.street { color: var(--neon-yellow); }
.faction-tag.corpo { color: var(--neon-red); }
.faction-tag.neutral { color: var(--neon-cyan); }
.faction-tag.gang { color: var(--neon-orange); }

.faction-name {
  font-family: 'Orbitron', monospace;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-bright);
  margin-bottom: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.faction-desc {
  font-size: 0.88rem;
  color: var(--text-dim);
  line-height: 1.7;
  margin-bottom: 1rem;
}

.faction-roles {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.7rem;
  color: var(--text-primary);
  border-top: 1px solid var(--panel-border);
  padding-top: 0.8rem;
}

.faction-roles span { color: var(--neon-cyan); }

.faction-card.full-width {
  grid-column: 1 / -1;
}

/* ─── GALLERY ─── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
  max-width: 1100px;
}

.gallery-item {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/10;
  background: var(--panel-bg);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.7) saturate(0.8);
  transition: filter 0.3s, transform 0.3s;
}

.gallery-item:hover img {
  filter: brightness(0.9) saturate(1);
  transform: scale(1.03);
}

.gallery-caption {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: linear-gradient(transparent, rgba(4,6,8,0.9));
  padding: 2rem 1rem 0.8rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  color: var(--text-dim);
  letter-spacing: 0.1em;
  opacity: 0;
  transition: opacity 0.3s;
}

.gallery-item:hover .gallery-caption { opacity: 1; }

/* ─── TIMELINE ─── */
.timeline { max-width: 900px; position: relative; padding-left: 2rem; }
.timeline::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(180deg, var(--neon-cyan), transparent);
}

.timeline-item {
  padding: 0 0 2.5rem;
  position: relative;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -2rem;
  top: 0.5rem;
  width: 7px; height: 7px;
  background: var(--neon-cyan);
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(0,245,255,0.5);
}

.timeline-day {
  font-family: 'Orbitron', monospace;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--neon-yellow);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.timeline-events {
  font-size: 0.9rem;
  color: var(--text-primary);
  line-height: 1.8;
}

.timeline-events .time {
  font-family: 'Share Tech Mono', monospace;
  color: var(--neon-cyan);
  font-size: 0.8rem;
}

/* ─── BUTTONS ─── */
.btn-primary {
  font-family: 'Orbitron', monospace;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--dark-bg);
  background: var(--neon-cyan);
  border: none;
  padding: 0.9rem 2rem;
  text-decoration: none;
  cursor: pointer;
  clip-path: polygon(10px 0%, 100% 0%, calc(100% - 10px) 100%, 0% 100%);
  transition: background 0.2s, box-shadow 0.2s;
  box-shadow: 0 0 20px rgba(0,245,255,0.3);
  display: inline-block;
}
.btn-primary:hover { background: var(--neon-yellow); box-shadow: 0 0 30px rgba(245,230,66,0.4); }

.btn-secondary {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  background: transparent;
  border: 1px solid var(--neon-cyan);
  padding: 0.9rem 2rem;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s;
  display: inline-block;
}
.btn-secondary:hover { background: rgba(0,245,255,0.08); }

/* ─── INFO CARDS ─── */
.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5px;
  background: rgba(0,245,255,0.08);
  border: 1px solid rgba(0,245,255,0.08);
  max-width: 1100px;
}

.info-card {
  background: var(--dark-bg);
  padding: 2rem;
}

.info-card-title {
  font-family: 'Orbitron', monospace;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--neon-cyan);
  margin-bottom: 1rem;
}

.info-card p {
  font-size: 0.88rem;
  color: var(--text-primary);
  line-height: 1.8;
}

.info-card p strong { color: var(--text-bright); font-weight: 600; }

/* ─── SOCIALS BAR ─── */
.socials-bar {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  margin: 1.5rem 0;
}

.social-link {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  color: var(--text-dim);
  text-decoration: none;
  letter-spacing: 0.1em;
  transition: color 0.2s;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.social-link:hover { color: var(--neon-cyan); }
.social-link .dot {
  width: 6px; height: 6px;
  background: var(--neon-cyan);
  border-radius: 50;
}

/* ─── FOOTER ─── */
footer {
  background: var(--panel-bg);
  border-top: 1px solid var(--neon-cyan);
  padding: 3rem max(3rem, calc((100vw - 1340px) / 2));
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
}

.footer-brand { display: flex; flex-direction: column; gap: 1rem; }
.footer-logo {
  font-family: 'Orbitron', monospace;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--neon-cyan);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
}
.footer-logo span { color: var(--neon-yellow); }

.footer-tagline {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.72rem;
  color: var(--text-dim);
  line-height: 1.7;
}

.footer-socials { margin-top: 0.5rem; }

.footer-contact {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  color: var(--text-dim);
  line-height: 2;
  margin-top: 1rem;
}

.footer-col h4 {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  color: var(--neon-cyan);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
}

.footer-links { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.footer-links a {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.7rem;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
  letter-spacing: 0.05em;
}
.footer-links a:hover { color: var(--neon-cyan); }

.footer-bottom {
  border-top: 1px solid var(--panel-border);
  padding: 1.5rem max(3rem, calc((100vw - 1340px) / 2));
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-copyright {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.6rem;
  color: var(--text-dim);
  letter-spacing: 0.1em;
}

.footer-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.6rem;
  color: var(--text-dim);
}

.status-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #00ff88;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(0,255,136,0.4); }
  50% { opacity: 0.8; box-shadow: 0 0 0 4px rgba(0,255,136,0); }
}

/* ─── TABLET ─── */
@media (max-width: 1024px) {
  .faction-grid { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: 1fr; }
  footer { grid-template-columns: 1fr 1fr; }
  .gallery-grid { grid-template-columns: 1fr 1fr; }
}

/* ─── MOBILE ─── */
@media (max-width: 768px) {
  nav { padding: 0 1rem; }
  .nav-links { display: none; }
  .nav-hamburger { display: block; }

  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 56px; left: 0; right: 0;
    background: rgba(4,6,8,0.97);
    padding: 1.5rem;
    gap: 1rem;
    border-bottom: 1px solid var(--neon-cyan);
    z-index: 500;
  }

  .page-header { padding: 7rem 1.5rem 2rem; }
  .content-section { padding: 3rem 1.5rem; }
  .faction-grid { grid-template-columns: 1fr; }
  .info-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr; }
  .timeline { padding-left: 1.5rem; }
  footer { grid-template-columns: 1fr; padding: 2rem 1.5rem; }
  .footer-bottom { flex-direction: column; gap: 0.8rem; padding: 1.5rem; }

  /* Fix 2-col grids that appear inline on subpages */
  [style*="grid-template-columns: 1fr 1fr"] ,
  [style*="grid-template-columns:1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }
}
