:root {
  --bg: #0a0a0a;
  --bg2: #111111;
  --bg3: #181818;
  --accent: #c8f135;
  --accent2: #35f1c8;
  --accent3: #f135c8;
  --text: #e8e8e0;
  --muted: #555550;
  --border: #222220;
  --card: #131313;
}

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 15px;
  line-height: 1.6;
  overflow-x: hidden;
}

/* ── NOISE OVERLAY ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
}

/* ── NAV ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10,10,10,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}

.nav-logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 22px;
  letter-spacing: 0.1em;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-logo span {
  color: var(--text);
}

.nav-logo .bracket {
  color: var(--muted);
  font-family: 'Space Mono', monospace;
  font-size: 16px;
}

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

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  font-family: 'Space Mono', monospace;
  transition: color 0.2s;
  letter-spacing: 0.05em;
}

.nav-links a:hover { color: var(--accent); }

.nav-badge {
  background: var(--accent);
  color: #0a0a0a;
  font-size: 11px;
  font-weight: 700;
  font-family: 'Space Mono', monospace;
  padding: 4px 10px;
  border-radius: 2px;
  letter-spacing: 0.05em;
}

/* ── HERO ── */
.hero {
  position: relative;
  padding: 7rem 2rem 5rem;
  max-width: 1200px;
  margin: 0 auto;
  z-index: 1;
}

.hero-eyebrow {
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 12px;
}

.hero-eyebrow::after {
  content: '';
  display: block;
  width: 48px;
  height: 1px;
  background: var(--accent);
  opacity: 0.5;
}

.hero h1 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(60px, 10vw, 110px);
  line-height: 0.92;
  letter-spacing: 0.02em;
  color: var(--text);
  margin-bottom: 0.4em;
  min-height: 2.76em;
}

.hero h1 em {
  color: var(--accent);
  font-style: normal;
  display: inline-block;
  min-width: 3ch;
}

.hero-sub {
  font-size: 16px;
  color: var(--muted);
  max-width: 480px;
  margin-bottom: 3rem;
  font-weight: 300;
  line-height: 1.8;
}

.hero-stats {
  display: flex;
  gap: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.stat-num {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 40px;
  color: var(--accent);
  line-height: 1;
}

.stat-label {
  font-size: 12px;
  color: var(--muted);
  font-family: 'Space Mono', monospace;
  letter-spacing: 0.05em;
}

/* ── GRID DECORATION ── */
.hero-grid {
  position: absolute;
  right: 0;
  top: 0;
  width: 480px;
  height: 100%;
  overflow: hidden;
  opacity: 0.06;
  pointer-events: none;
}

.hero-grid svg { width: 100%; height: 100%; }

/* ── SEARCH + FILTER ── */
.toolbar {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.search-wrap {
  position: relative;
}

.search-wrap input {
  width: 100%;
  background: var(--bg3);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: 'Space Mono', monospace;
  font-size: 14px;
  padding: 14px 20px 14px 48px;
  border-radius: 4px;
  outline: none;
  transition: border-color 0.2s;
}

.search-wrap input:focus { border-color: var(--accent); }
.search-wrap input::placeholder { color: var(--muted); }

.search-icon {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  font-family: 'Space Mono', monospace;
  font-size: 13px;
}

.filter-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.filter-label {
  font-size: 11px;
  font-family: 'Space Mono', monospace;
  color: var(--muted);
  letter-spacing: 0.1em;
  margin-right: 4px;
}

.filter-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--muted);
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  padding: 6px 14px;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.15s;
  letter-spacing: 0.05em;
}

.filter-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #0a0a0a;
  font-weight: 700;
}

/* ── PROJECT GRID ── */
.projects-section {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem 6rem;
}

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

.section-title {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.count-badge {
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  color: var(--muted);
}

.count-badge strong {
  color: var(--accent);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}

/* ── PROJECT CARD ── */
.card {
  background: var(--card);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: background 0.15s;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent-color, var(--accent));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.card:hover { background: var(--bg3); }
.card:hover::before { transform: scaleX(1); }

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.lang-tag {
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border-radius: 2px;
  font-weight: 700;
  text-transform: uppercase;
}

.card-num {
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  color: var(--muted);
}

.card h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  font-family: 'Noto Sans KR', sans-serif;
}

.card-desc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.7;
  font-weight: 300;
  flex: 1;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.student-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 700;
  font-family: 'Space Mono', monospace;
  flex-shrink: 0;
}

.student-name {
  font-size: 13px;
  color: var(--muted);
  font-weight: 400;
}

.card-links {
  display: flex;
  gap: 10px;
}

.card-link {
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  text-decoration: none;
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: 2px;
  transition: all 0.15s;
  letter-spacing: 0.05em;
}

.card-link:hover {
  color: var(--text);
  border-color: var(--muted);
}

/* ── TAGS ── */
.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  font-size: 10px;
  color: var(--muted);
  font-family: 'Space Mono', monospace;
  padding: 3px 8px;
  border: 1px solid var(--border);
  border-radius: 2px;
  letter-spacing: 0.05em;
}

/* ── FEATURED CARD ── */
.card.featured {
  grid-column: span 2;
  background: linear-gradient(135deg, #131313 0%, #181310 100%);
  border-left: 3px solid var(--accent);
}

.featured-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Space Mono', monospace;
  font-size: 10px;
  color: var(--accent);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.featured-badge::before {
  content: '★';
  font-size: 10px;
}

/* ── FOOTER ── */
footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-left {
  font-family: 'Space Mono', monospace;
  font-size: 11px;
  color: var(--muted);
}

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

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

#grid .card {
  animation: fadeUp 0.35s ease forwards;
}

#grid .card:nth-child(1) { animation-delay: 0.00s; }
#grid .card:nth-child(2) { animation-delay: 0.05s; }
#grid .card:nth-child(3) { animation-delay: 0.10s; }
#grid .card:nth-child(4) { animation-delay: 0.15s; }
#grid .card:nth-child(5) { animation-delay: 0.20s; }
#grid .card:nth-child(n+6) { animation-delay: 0.25s; }

/* ── TYPEWRITER ── */
.typewriter {
  border-right: 2px solid var(--accent);
  animation: blink 0.8s step-end infinite;
  padding-right: 2px;
}

@keyframes blink {
  50% { border-color: transparent; }
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--muted); border-radius: 0; }

/* ── HIDDEN ── */
.card.hidden { display: none; }

/* ── LOADING ── */
.loading-msg {
  font-family: 'Space Mono', monospace;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  padding: 4rem 2rem;
  letter-spacing: 0.1em;
}

.loading-msg::after {
  content: '';
  animation: dots 1.4s steps(3) infinite;
}

@keyframes dots {
  0%   { content: ''; }
  33%  { content: '.'; }
  66%  { content: '..'; }
  100% { content: '...'; }
}

@media (max-width: 768px) {
  .hero h1 { font-size: 58px; }
  .hero-stats { gap: 2rem; }
  .card.featured { grid-column: span 1; }
  .nav-links { display: none; }
  .projects-grid { grid-template-columns: 1fr; }
}
