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

:root {
  --bg: #05070f;
  --surface: #090e1a;
  --surface2: #0e1525;
  --cyan: #00d4ff;
  --cyan-glow: rgba(0, 212, 255, 0.1);
  --cyan-border: rgba(0, 212, 255, 0.22);
  --text: #c8dff0;
  --text-muted: #3d5a70;
  --text-dim: #1a2e40;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 212, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 212, 255, 0.025) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
  z-index: 0;
}

.page {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
  padding: 3.5rem 2rem 5rem;
}

header {
  text-align: center;
  margin-bottom: 3.5rem;
  padding-bottom: 2rem;
  position: relative;
}

header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--text-dim) 20%, var(--cyan) 50%, var(--text-dim) 80%, transparent);
}

.site-title {
  font-family: 'Orbitron', monospace;
  font-size: 2rem;
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: 0.5em;
  text-transform: uppercase;
  text-shadow: 0 0 30px rgba(0, 212, 255, 0.35), 0 0 60px rgba(0, 212, 255, 0.1);
  padding-right: 0.5em;
}

.site-subtitle {
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  margin-top: 0.6rem;
  font-family: 'Orbitron', monospace;
}

.section-label {
  font-size: 0.6rem;
  font-family: 'Orbitron', monospace;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.section-label::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--cyan);
  clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
  flex-shrink: 0;
  opacity: 0.7;
}

.section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--text-dim), transparent);
}

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

.tile {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--text-dim);
  border-radius: 3px;
  padding: 1.5rem 1.25rem 1.25rem;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  overflow: hidden;
  transition: border-color 0.25s, background 0.25s;
  --mx: 50%;
  --my: 50%;
}

.tile-corner {
  position: absolute;
  width: 10px;
  height: 10px;
  transition: width 0.25s, height 0.25s, border-color 0.25s;
}

.tile-corner-tl { top: 0; left: 0; border-top: 1px solid var(--cyan-border); border-left: 1px solid var(--cyan-border); }
.tile-corner-br { bottom: 0; right: 0; border-bottom: 1px solid var(--cyan-border); border-right: 1px solid var(--cyan-border); }

.tile-glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle 160px at var(--mx) var(--my), rgba(0, 212, 255, 0.09), transparent 70%);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}

.tile:hover .tile-glow { opacity: 1; }

.tile:hover {
  border-color: var(--cyan-border);
  background: var(--surface2);
}

.tile:hover .tile-corner-tl,
.tile:hover .tile-corner-br {
  width: 18px;
  height: 18px;
  border-color: var(--cyan);
}

.tile-icon {
  font-size: 1.8rem;
  color: var(--cyan);
  opacity: 0.7;
  transition: opacity 0.25s, text-shadow 0.25s;
  position: relative;
  z-index: 1;
  line-height: 1;
}

.tile:hover .tile-icon {
  opacity: 1;
  text-shadow: 0 0 12px rgba(0, 212, 255, 0.5);
}

.tile-name {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text);
  position: relative;
  z-index: 1;
  margin-top: 0.25rem;
}

.tile-desc {
  font-size: 0.7rem;
  color: var(--text-muted);
  line-height: 1.4;
  position: relative;
  z-index: 1;
}

.collapsible-trigger {
  display: flex;
  align-items: center;
  gap: 1rem;
  cursor: pointer;
  user-select: none;
  margin-bottom: 0;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  padding: 0;
  color: inherit;
}

.collapsible-trigger .section-label {
  margin-bottom: 0;
  flex: 1;
  pointer-events: none;
}

.collapse-toggle {
  font-size: 0.6rem;
  font-family: 'Orbitron', monospace;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  transition: color 0.2s;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

.collapsible-trigger:hover .collapse-toggle { color: var(--cyan); }

.collapse-toggle i {
  transition: transform 0.35s;
  font-size: 1rem;
}

.collapsible-trigger[aria-expanded="true"] .collapse-toggle i {
  transform: rotate(180deg);
}

.collapsible-body {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), margin-top 0.3s;
  margin-top: 0;
}

.collapsible-body.open {
  max-height: 500px;
  margin-top: 1rem;
}

footer {
  text-align: center;
  font-size: 0.58rem;
  color: var(--text-dim);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  font-family: 'Orbitron', monospace;
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--text-dim);
}

@media (max-width: 600px) {
  .site-title { font-size: 1.3rem; letter-spacing: 0.3em; }
  .page { padding: 2rem 1rem 3rem; }
}

@media (prefers-reduced-motion: reduce) {
  .tile-glow, .tile-corner, .collapse-toggle i, .tile-icon { transition: none; }
  .collapsible-body { transition: none; }
}