/* [ PWNED ] Cyber Security Club — terminal-minimal theme */
:root {
  --bg: #0a0e0a;
  --bg-soft: #0f150f;
  --bg-card: #0d130d;
  --border: #1d2b1d;
  --green: #00ff41;
  --green-dim: #39d353;
  --red: #ff2d55;
  --text: #c9d1c9;
  --text-dim: #6a7a6a;
  --mono: ui-monospace, "JetBrains Mono", "Fira Code", "Cascadia Code",
          Consolas, "Liberation Mono", monospace;
}

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

html { color-scheme: dark; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--mono);
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* subtle CRT scanlines */
.scanlines {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  background: repeating-linear-gradient(
    to bottom,
    rgba(0, 255, 65, 0.015) 0px,
    rgba(0, 255, 65, 0.015) 1px,
    transparent 1px,
    transparent 3px
  );
}

a { color: var(--green-dim); text-decoration: none; }
a:hover { color: var(--green); text-decoration: underline; }
.dim { color: var(--text-dim); }
.t-green { color: var(--green); }
.t-red { color: var(--red); }
.t-dim { color: var(--text-dim); }

/* ---------- top bar ---------- */
.topbar {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding: 0.8rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg-soft);
  position: sticky;
  top: 0;
  z-index: 10;
}
.brand {
  color: var(--green);
  font-weight: 700;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}
.brand-logo {
  height: 26px;
  width: auto;
  display: block;
  filter: drop-shadow(0 0 6px rgba(0, 255, 65, 0.35));
}
.brand:hover { text-decoration: none; text-shadow: 0 0 8px rgba(0,255,65,.6); }
.nav { display: flex; gap: 0.2rem; flex-wrap: wrap; }
.nav a {
  padding: 0.3rem 0.7rem;
  color: var(--text-dim);
  border: 1px solid transparent;
  border-radius: 3px;
}
.nav a:hover { color: var(--green); text-decoration: none; }
.nav a.active {
  color: var(--green);
  border-color: var(--border);
  background: rgba(0, 255, 65, 0.05);
}
.nav a.pwned-link { color: var(--red); }
.nav a.pwned-link.active { border-color: #3a1220; background: rgba(255,45,85,.06); }
.topbar-right { margin-left: auto; display: flex; gap: 0.5rem; }

/* ---------- layout ---------- */
.container {
  width: 100%;
  max-width: 1060px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
  flex: 1;
}
.footer {
  border-top: 1px solid var(--border);
  padding: 1rem 1.5rem;
  font-size: 0.8rem;
  color: var(--text-dim);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ---------- hero / glitch title ---------- */
.hero { padding: 2.5rem 0 1.8rem; }
.hero h1 {
  font-size: clamp(1.8rem, 5vw, 3rem);
  color: var(--green);
  letter-spacing: 0.08em;
  text-shadow: 0 0 12px rgba(0, 255, 65, 0.35);
}
.hero-sub { color: var(--text-dim); margin-top: 0.4rem; }

.glitch { position: relative; }
.glitch::before, .glitch::after {
  content: attr(data-text);
  position: absolute;
  left: 0; top: 0;
  width: 100%;
  opacity: 0.55;
  clip-path: inset(0 0 0 0);
}
.glitch::before { color: var(--red); transform: translateX(-2px); clip-path: inset(0 0 55% 0); }
.glitch::after { color: #2bd9ff; transform: translateX(2px); clip-path: inset(60% 0 0 0); }

/* ---------- cards & markdown ---------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.4rem 1.6rem;
  margin-bottom: 1.4rem;
}
.card-title {
  font-size: 0.85rem;
  color: var(--text-dim);
  font-weight: 400;
  margin-bottom: 1rem;
  letter-spacing: 0.05em;
}
.card-title::before { content: ""; }
.md h1, .md h2, .md h3, .md h4 {
  color: var(--green);
  margin: 1.2em 0 0.5em;
  line-height: 1.3;
}
.md h1:first-child, .md h2:first-child, .md h3:first-child { margin-top: 0; }
.md h1 { font-size: 1.5rem; }
.md h2 { font-size: 1.25rem; }
.md h3 { font-size: 1.05rem; }
.md p { margin: 0.7em 0; }
.md ul, .md ol { margin: 0.7em 0 0.7em 1.4em; }
.md li { margin: 0.25em 0; }
.md blockquote {
  border-left: 3px solid var(--green-dim);
  padding: 0.4em 1em;
  margin: 0.9em 0;
  color: var(--text-dim);
  background: rgba(0, 255, 65, 0.04);
}
.md code {
  background: #101b10;
  border: 1px solid var(--border);
  padding: 0.1em 0.4em;
  border-radius: 3px;
  color: var(--green);
  font-size: 0.9em;
}
.md pre {
  background: #101b10;
  border: 1px solid var(--border);
  padding: 0.9em 1.1em;
  border-radius: 4px;
  overflow-x: auto;
  margin: 0.9em 0;
}
.md pre code { border: none; background: none; padding: 0; }
.md img { max-width: 100%; border-radius: 4px; }
.md table { border-collapse: collapse; margin: 0.9em 0; }
.md th, .md td { border: 1px solid var(--border); padding: 0.4em 0.8em; }
.md th { color: var(--green); }


/* ---------- gallery ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}
.gallery-vertical { grid-template-columns: 1fr; }
.gallery-item {
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-soft);
}
.gallery-item img {
  display: block;
  width: 100%;
  height: 170px;
  object-fit: cover;
}
.gallery-vertical .gallery-item img { height: auto; max-height: 320px; object-fit: contain; }
.gallery-item figcaption {
  font-size: 0.72rem;
  color: var(--text-dim);
  padding: 0.35rem 0.6rem;
  border-top: 1px solid var(--border);
}


/* ---------- members ---------- */
.member-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.2rem;
}
.member-card {
  display: flex;
  gap: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.1rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.member-card:hover {
  border-color: var(--green-dim);
  box-shadow: 0 0 14px rgba(0, 255, 65, 0.08);
}
.member-photo {
  width: 86px;
  height: 86px;
  border-radius: 6px;
  object-fit: cover;
  border: 1px solid var(--border);
  flex-shrink: 0;
}
.member-photo-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 700;
  color: var(--green);
  background: #101b10;
}
.member-name { color: var(--green); font-size: 1rem; }
.member-role { color: var(--text-dim); font-size: 0.8rem; margin: 0.1rem 0 0.4rem; }
.member-bio { font-size: 0.85rem; }
.member-bio p { margin: 0.2em 0; }


/* ---------- achievements ---------- */
.score-layout {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 1.4rem;
  align-items: start;
}
@media (max-width: 800px) { .score-layout { grid-template-columns: 1fr; } }
.table-wrap { overflow-x: auto; }
.score-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.score-table th, .score-table td {
  text-align: left;
  padding: 0.55rem 0.7rem;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.score-table td.event-name { white-space: normal; min-width: 160px; color: var(--green); }
.score-table th { color: var(--text-dim); font-weight: 400; border-bottom: 1px solid var(--green-dim); }
.rank-1 { background: rgba(0, 255, 65, 0.07); }
.rank-2 { background: rgba(43, 217, 255, 0.05); }
.rank-3 { background: rgba(255, 200, 0, 0.05); }
.rank-badge { color: var(--green); }


/* ---------- PWNED terminal ---------- */
.pwned-wrap { max-width: 780px; margin: 2.5rem auto 0; }
.terminal {
  background: #050805;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 0 40px rgba(0, 255, 65, 0.07);
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 0.9rem;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
}
.dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.dot.red { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #27c93f; }
.terminal-title { margin-left: 0.6rem; font-size: 0.75rem; color: var(--text-dim); }
.terminal-body { padding: 1.1rem 1.3rem; font-size: 0.92rem; overflow-x: auto; }
.terminal-body p { margin: 0.35rem 0; }
.prompt { color: var(--green-dim); font-weight: 700; }
.cursor { animation: blink 1s steps(1) infinite; }
.blink { animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.pwned-note { margin-top: 1.2rem; font-size: 0.8rem; color: var(--text-dim); text-align: center; }


/* ---------- forms / admin ---------- */
.flashes { margin-bottom: 1rem; }
.flash {
  border: 1px solid var(--green-dim);
  color: var(--green);
  background: rgba(0, 255, 65, 0.06);
  border-radius: 4px;
  padding: 0.5rem 0.9rem;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
}
label { display: block; color: var(--text-dim); font-size: 0.82rem; margin: 0.9rem 0 0.3rem; }
input[type="text"], input[type="password"], input[type="date"], input[type="number"],
input[type="url"], textarea, select {
  width: 100%;
  background: #0a100a;
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--mono);
  font-size: 0.9rem;
  padding: 0.55rem 0.7rem;
  border-radius: 4px;
}
textarea { min-height: 220px; resize: vertical; line-height: 1.55; }
input:focus, textarea:focus {
  outline: none;
  border-color: var(--green-dim);
  box-shadow: 0 0 0 2px rgba(0, 255, 65, 0.08);
}


.btn {
  display: inline-block;
  border: 1px solid var(--green-dim);
  color: var(--green);
  background: rgba(0, 255, 65, 0.07);
  font-family: var(--mono);
  font-size: 0.88rem;
  padding: 0.5rem 1.1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
}
.btn:hover {
  background: rgba(0, 255, 65, 0.15);
  box-shadow: 0 0 10px rgba(0, 255, 65, 0.15);
  text-decoration: none;
}
.btn-danger { border-color: #5c1a2c; color: var(--red); background: rgba(255,45,85,.06); }
.btn-danger:hover { background: rgba(255,45,85,.14); box-shadow: 0 0 10px rgba(255,45,85,.15); }
.btn-ghost { border-color: var(--border); color: var(--text-dim); background: transparent; }
.btn-small { font-size: 0.75rem; padding: 0.3rem 0.7rem; }
.inline-form { display: inline; }
.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.2rem;
}
.admin-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.2rem 1.4rem;
}
.admin-card h3 { color: var(--green); font-size: 0.95rem; margin-bottom: 0.4rem; }
.admin-card p { font-size: 0.8rem; color: var(--text-dim); margin-bottom: 0.9rem; }
.banner {
  border: 1px solid var(--red);
  color: var(--red);
  background: rgba(255, 45, 85, 0.07);
  border-radius: 4px;
  padding: 0.7rem 1rem;
  margin-bottom: 1.4rem;
  font-size: 0.85rem;
}
.img-thumb { max-width: 120px; max-height: 80px; border-radius: 4px; border: 1px solid var(--border); display: block; }
.row { display: flex; gap: 1rem; flex-wrap: wrap; align-items: flex-end; }
.row > * { flex: 1 1 140px; }
.row > .btn, .row > .inline-form { flex: 0 0 auto; }
.mt { margin-top: 1rem; }
hr.sep { border: none; border-top: 1px dashed var(--border); margin: 1.6rem 0; }






