/* ===================== CSS VARIABLES ===================== */
:root {
  --bg: #f0f4f8;
  --bg2: #e2e8f0;
  --surface: #ffffff;
  --card-bg: #ffffff;
  --text: #0f1923;
  --text2: #4a5568;
  --accent: #00e5ff;
  --accent2: #ff6b35;
  --accent3: #39ff14;
  --border: rgba(0,229,255,0.25);
  --shadow: 0 4px 32px rgba(0,0,0,0.08);
  --nav-bg: rgba(240,244,248,0.92);
  --glow: 0 0 20px rgba(0,229,255,0.35);
  --chat-bubble-user: #00e5ff;
  --chat-bubble-user-text: #0f1923;
  --chat-bubble-ai: #e2e8f0;
  --chat-bubble-ai-text: #0f1923;
  --transition: 0.35s cubic-bezier(0.4,0,0.2,1);
}

    /* ── Wrapper ── */
    #network-status {
      position: relative;
      background: var(--bg, #0a0f0a);
      padding: 100px 40px;
      overflow: hidden;
    }

    /* scanline overlay */
    #network-status::before {
      content: '';
      position: absolute;
      inset: 0;
      background: repeating-linear-gradient(0deg,
          transparent,
          transparent 2px,
          rgba(0, 255, 65, 0.012) 2px,
          rgba(0, 255, 65, 0.012) 4px);
      pointer-events: none;
      z-index: 0;
    }

    /* grid BG */
    #network-status::after {
      content: '';
      position: absolute;
      inset: 0;
      background-image:
        linear-gradient(rgba(0, 255, 65, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 65, 0.03) 1px, transparent 1px);
      background-size: 44px 44px;
      pointer-events: none;
      z-index: 0;
    }

    /* glow orbs */
    .ns-orb {
      position: absolute;
      border-radius: 50%;
      filter: blur(110px);
      pointer-events: none;
      z-index: 0;
      animation: ns-orb-float 9s ease-in-out infinite;
    }

    .ns-orb-1 {
      width: 480px;
      height: 480px;
      background: var(--accent, #00ff41);
      opacity: .07;
      top: -160px;
      left: -120px;
    }

    .ns-orb-2 {
      width: 360px;
      height: 360px;
      background: #00e5ff;
      opacity: .06;
      bottom: -100px;
      right: -80px;
      animation-direction: reverse;
      animation-duration: 11s;
    }

    @keyframes ns-orb-float {

      0%,
      100% {
        transform: translate(0, 0)
      }

      50% {
        transform: translate(18px, -18px)
      }
    }

    .ns-wrap {
      position: relative;
      z-index: 1;
      max-width: 1200px;
      margin: 0 auto;
    }

    /* ── Header ── */
    .ns-live-label {
      display: inline-flex;
      align-items: center;
      gap: 9px;
      font-family: 'Share Tech Mono', monospace;
      font-size: 11px;
      letter-spacing: 4px;
      text-transform: uppercase;
      color: var(--accent, #00ff41);
      margin-bottom: 14px;
    }

    .ns-live-dot {
      width: 8px;
      height: 8px;
      border-radius: 50%;
      background: var(--accent, #00ff41);
      box-shadow: 0 0 8px var(--accent, #00ff41), 0 0 18px var(--accent, #00ff41);
      animation: ns-blink 1.6s ease-in-out infinite;
    }

    @keyframes ns-blink {

      0%,
      100% {
        opacity: 1;
        transform: scale(1)
      }

      50% {
        opacity: .4;
        transform: scale(.7)
      }
    }

    .ns-title {
      font-family: 'Orbitron', monospace;
      font-size: clamp(2rem, 5vw, 3.5rem);
      font-weight: 900;
      color: var(--text, #e0ffe8);
      line-height: 1;
      margin-bottom: 10px;
      letter-spacing: -1px;
    }

    .ns-title .accent {
      color: var(--accent, #00ff41);
      text-shadow: 0 0 28px rgba(0, 255, 65, .55);
    }

    .ns-subtitle {
      font-family: 'Share Tech Mono', monospace;
      font-size: 12px;
      color: rgba(0, 255, 65, .45);
      margin-bottom: 50px;
      letter-spacing: 1px;
    }

    .ns-subtitle em {
      color: #00e5ff;
      font-style: normal;
    }

    /* ── Uptime Bar ── */
    .ns-uptime-bar {
      display: flex;
      align-items: center;
      gap: 18px;
      padding: 16px 22px;
      background: rgba(0, 255, 65, .04);
      border: 1px solid rgba(0, 255, 65, .18);
      border-left: 3px solid var(--accent, #00ff41);
      border-radius: 4px;
      margin-bottom: 40px;
    }

    .ns-uptime-label {
      font-family: 'Share Tech Mono', monospace;
      font-size: 10px;
      letter-spacing: 3px;
      text-transform: uppercase;
      color: rgba(0, 255, 65, .45);
      white-space: nowrap;
    }

    .ns-uptime-track {
      flex: 1;
      height: 5px;
      background: rgba(0, 255, 65, .1);
      border-radius: 3px;
      overflow: hidden;
    }

    .ns-uptime-fill {
      height: 100%;
      width: 99.97%;
      background: linear-gradient(90deg, #00ff41, #00e5ff);
      border-radius: 3px;
      box-shadow: 0 0 10px rgba(0, 255, 65, .5);
      animation: ns-uptime-pulse 3s ease-in-out infinite;
    }

    @keyframes ns-uptime-pulse {

      0%,
      100% {
        box-shadow: 0 0 10px rgba(0, 255, 65, .5)
      }

      50% {
        box-shadow: 0 0 20px rgba(0, 229, 255, .8)
      }
    }

    .ns-uptime-val {
      font-family: 'Orbitron', monospace;
      font-size: 14px;
      font-weight: 700;
      color: var(--accent, #00ff41);
      white-space: nowrap;
    }

    /* ── Grid layouts ── */
    .ns-grid-2 {
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 14px;
      margin-bottom: 14px;
    }

    .ns-grid-4 {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 14px;
      margin-bottom: 14px;
    }

    .ns-grid-2b {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 14px;
      margin-bottom: 14px;
    }

    /* ── Base Card ── */
    .ns-card {
      position: relative;
      background: var(--card-bg, #0d1f0d);
      border: 1px solid rgba(0, 255, 65, .18);
      border-radius: 6px;
      padding: 26px;
      overflow: hidden;
      transition: border-color .3s, transform .3s, background .3s;
      cursor: default;
    }

    .ns-card::before {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(135deg, rgba(0, 255, 65, .03) 0%, transparent 60%);
      pointer-events: none;
    }

    .ns-card:hover {
      border-color: rgba(0, 255, 65, .5);
      background: rgba(0, 255, 65, .06);
      transform: translateY(-2px);
    }

    .ns-card-glow {
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      height: 1px;
      background: linear-gradient(90deg, transparent, var(--accent, #00ff41), transparent);
      opacity: 0;
      transition: opacity .3s;
    }

    .ns-card:hover .ns-card-glow {
      opacity: 1;
    }

    /* ── Card content atoms ── */
    .ns-clabel {
      font-family: 'Share Tech Mono', monospace;
      font-size: 10px;
      letter-spacing: 3px;
      text-transform: uppercase;
      color: rgba(0, 255, 65, .4);
      margin-bottom: 10px;
      display: flex;
      align-items: center;
      gap: 6px;
    }

    .ns-clabel::before {
      content: '//';
      color: rgba(0, 255, 65, .18);
    }

    .ns-cval {
      font-family: 'Orbitron', monospace;
      font-weight: 700;
      font-size: 1.9rem;
      line-height: 1;
      margin-bottom: 8px;
    }

    .ns-cval.sm {
      font-size: 1.4rem;
    }

    .ns-cval.g {
      color: var(--accent, #00ff41);
      text-shadow: 0 0 18px rgba(0, 255, 65, .4);
    }

    .ns-cval.c {
      color: #00e5ff;
      text-shadow: 0 0 18px rgba(0, 229, 255, .4);
    }

    .ns-cval.a {
      color: #ffa500;
      text-shadow: 0 0 18px rgba(255, 165, 0, .4);
    }

    .ns-cval.r {
      color: #ff073a;
      text-shadow: 0 0 18px rgba(255, 7, 58, .4);
    }

    .ns-cval.w {
      color: var(--text, #e0ffe8);
    }

    .ns-badge {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      font-family: 'Share Tech Mono', monospace;
      font-size: 10px;
      padding: 4px 10px;
      border-radius: 2px;
      margin-top: 8px;
    }

    .ns-badge.ok {
      background: rgba(0, 255, 65, .1);
      color: var(--accent, #00ff41);
      border: 1px solid rgba(0, 255, 65, .22);
    }

    .ns-badge.warn {
      background: rgba(255, 165, 0, .1);
      color: #ffa500;
      border: 1px solid rgba(255, 165, 0, .22);
    }

    .ns-badge.err {
      background: rgba(255, 7, 58, .1);
      color: #ff073a;
      border: 1px solid rgba(255, 7, 58, .22);
    }

    .ns-badge-dot {
      width: 5px;
      height: 5px;
      border-radius: 50%;
      background: currentColor;
      animation: ns-blink 1.5s ease-in-out infinite;
    }

    .ns-meta {
      font-family: 'Share Tech Mono', monospace;
      font-size: 11px;
      color: rgba(0, 255, 65, .4);
      margin-top: 7px;
    }

    .ns-meta span {
      color: var(--accent, #00ff41);
    }

    .ns-meta span.c {
      color: #00e5ff;
    }

    /* ── Graph ── */
    .ns-graph-head {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      margin-bottom: 16px;
    }

    .ns-graph-meta {
      font-family: 'Share Tech Mono', monospace;
      font-size: 10px;
      color: rgba(0, 255, 65, .4);
      text-align: right;
      line-height: 1.7;
    }

    .ns-graph-meta span.g {
      color: var(--accent, #00ff41);
    }

    .ns-graph-meta span.c {
      color: #00e5ff;
    }

    .ns-graph-area {
      position: relative;
      height: 88px;
      display: flex;
      align-items: flex-end;
      gap: 3px;
      overflow: hidden;
    }

    .ns-bar {
      flex: 1;
      border-radius: 2px 2px 0 0;
      background: linear-gradient(to top, var(--accent, #00ff41), rgba(0, 229, 255, .6));
      box-shadow: 0 0 5px rgba(0, 255, 65, .3);
      animation: ns-bar-grow .8s ease-out both;
      transition: opacity .3s;
      min-width: 0;
    }

    .ns-bar:hover {
      opacity: .65;
    }

    @keyframes ns-bar-grow {
      from {
        transform: scaleY(0);
        transform-origin: bottom
      }

      to {
        transform: scaleY(1);
        transform-origin: bottom
      }
    }

    .ns-baseline {
      position: absolute;
      bottom: 0;
      left: 0;
      right: 0;
      height: 1px;
      background: rgba(0, 255, 65, .12);
    }

    .ns-graph-ticks {
      display: flex;
      justify-content: space-between;
      margin-top: 6px;
      font-family: 'Share Tech Mono', monospace;
      font-size: 9px;
      color: rgba(0, 255, 65, .3);
      letter-spacing: 1px;
    }

    /* ── Resource meters ── */
    .ns-res-grid {
      display: flex;
      gap: 24px;
      margin-top: 12px;
    }

    .ns-res-item {
      flex: 1;
    }

    .ns-res-label {
      font-family: 'Share Tech Mono', monospace;
      font-size: 10px;
      letter-spacing: 2px;
      color: rgba(0, 255, 65, .4);
      margin-bottom: 7px;
      text-transform: uppercase;
    }

    .ns-res-track {
      height: 4px;
      border-radius: 2px;
      overflow: hidden;
      margin-top: 8px;
    }

    .ns-res-fill {
      height: 100%;
      border-radius: 2px;
      transition: width 1.2s ease;
    }

    .ns-res-fill.g {
      background: linear-gradient(90deg, var(--accent, #00ff41), #00e5ff);
      box-shadow: 0 0 8px rgba(0, 255, 65, .45);
    }

    .ns-res-fill.a {
      background: linear-gradient(90deg, #ffa500, #ff073a);
      box-shadow: 0 0 8px rgba(255, 165, 0, .4);
    }

    .ns-res-fill.c {
      background: #00e5ff;
      box-shadow: 0 0 8px rgba(0, 229, 255, .4);
    }

    .ns-res-bg-g {
      background: rgba(0, 255, 65, .1);
    }

    .ns-res-bg-a {
      background: rgba(255, 165, 0, .1);
    }

    .ns-res-bg-c {
      background: rgba(0, 229, 255, .1);
    }

    /* ── Node list ── */
    .ns-node-list {
      display: flex;
      flex-direction: column;
      gap: 11px;
      margin-top: 12px;
    }

    .ns-node-row {
      display: flex;
      align-items: center;
      gap: 10px;
      font-family: 'Share Tech Mono', monospace;
      font-size: 11px;
    }

    .ns-node-dot {
      width: 7px;
      height: 7px;
      border-radius: 50%;
      flex-shrink: 0;
    }

    .ns-node-dot.on {
      background: var(--accent, #00ff41);
      box-shadow: 0 0 7px var(--accent, #00ff41);
      animation: ns-blink 2s ease-in-out infinite;
    }

    .ns-node-dot.sb {
      background: #00e5ff;
      box-shadow: 0 0 7px #00e5ff;
    }

    .ns-node-dot.of {
      background: #ff073a;
      box-shadow: 0 0 7px #ff073a;
    }

    .ns-node-name {
      flex: 1;
      color: rgba(224, 255, 232, .65);
    }

    .ns-node-name.of-text {
      color: rgba(255, 7, 58, .5);
    }

    .ns-node-ping {
      color: var(--accent, #00ff41);
      margin-left: auto;
      padding-right: 10px;
    }

    .ns-node-ping.sb {
      color: #00e5ff;
    }

    .ns-node-ping.of {
      color: #ff073a;
    }

    .ns-node-bwrap {
      width: 72px;
      height: 3px;
      background: rgba(0, 255, 65, .1);
      border-radius: 2px;
      overflow: hidden;
    }

    .ns-node-bfill {
      height: 100%;
      border-radius: 2px;
    }

    .ns-node-bfill.g {
      background: var(--accent, #00ff41);
    }

    .ns-node-bfill.c {
      background: #00e5ff;
    }

    .ns-node-bfill.r {
      background: #ff073a;
    }

    /* ── Activity Log ── */
    .ns-log-list {
      display: flex;
      flex-direction: column;
      gap: 7px;
      margin-top: 12px;
      max-height: 155px;
      overflow: hidden;
    }

    .ns-log-item {
      display: flex;
      gap: 10px;
      font-family: 'Share Tech Mono', monospace;
      font-size: 10.5px;
      line-height: 1.4;
      padding: 5px 10px;
      background: rgba(0, 255, 65, .03);
      border-left: 2px solid;
      border-radius: 0 2px 2px 0;
      animation: ns-slide-in .4s ease-out both;
    }

    @keyframes ns-slide-in {
      from {
        opacity: 0;
        transform: translateX(-8px)
      }

      to {
        opacity: 1;
        transform: translateX(0)
      }
    }

    .ns-log-item.ok {
      border-color: var(--accent, #00ff41);
    }

    .ns-log-item.info {
      border-color: #00e5ff;
    }

    .ns-log-item.warn {
      border-color: #ffa500;
    }

    .ns-log-item.err {
      border-color: #ff073a;
    }

    .ns-log-time {
      color: rgba(0, 255, 65, .35);
      white-space: nowrap;
    }

    .ns-log-type {
      font-weight: 700;
      white-space: nowrap;
    }

    .ns-log-item.ok .ns-log-type {
      color: var(--accent, #00ff41);
    }

    .ns-log-item.info .ns-log-type {
      color: #00e5ff;
    }

    .ns-log-item.warn .ns-log-type {
      color: #ffa500;
    }

    .ns-log-item.err .ns-log-type {
      color: #ff073a;
    }

    .ns-log-msg {
      color: rgba(224, 255, 232, .55);
    }

    /* ── Ticker ── */
    .ns-ticker {
      display: flex;
      align-items: center;
      gap: 16px;
      padding: 12px 20px;
      background: rgba(0, 255, 65, .04);
      border: 1px solid rgba(0, 255, 65, .15);
      border-radius: 4px;
      overflow: hidden;
      margin-top: 24px;
    }

    .ns-ticker-lbl {
      font-family: 'Share Tech Mono', monospace;
      font-size: 10px;
      letter-spacing: 3px;
      color: var(--accent, #00ff41);
      text-transform: uppercase;
      white-space: nowrap;
      border-right: 1px solid rgba(0, 255, 65, .18);
      padding-right: 16px;
    }

    .ns-ticker-track {
      flex: 1;
      overflow: hidden;
      position: relative;
    }

    .ns-ticker-inner {
      display: flex;
      gap: 56px;
      white-space: nowrap;
      animation: ns-ticker 28s linear infinite;
      font-family: 'Share Tech Mono', monospace;
      font-size: 11px;
      color: rgba(0, 255, 65, .65);
    }

    @keyframes ns-ticker {
      0% {
        transform: translateX(0)
      }

      100% {
        transform: translateX(-50%)
      }
    }

    .ns-t-key {
      color: rgba(0, 255, 65, .35);
    }

    .ns-t-sep {
      color: rgba(0, 255, 65, .18);
    }

    .ns-t-val {
      color: var(--accent, #00ff41);
      font-weight: 700;
    }

    .ns-t-item {
      display: inline-flex;
      align-items: center;
      gap: 7px;
    }

    /* ── Responsive ── */
    @media (max-width:900px) {
      .ns-grid-2 {
        grid-template-columns: 1fr;
      }

      .ns-grid-4 {
        grid-template-columns: repeat(2, 1fr);
      }

      .ns-grid-2b {
        grid-template-columns: 1fr;
      }
    }

    @media (max-width:540px) {
      #network-status {
        padding: 60px 18px;
      }

      .ns-grid-4 {
        grid-template-columns: 1fr 1fr;
      }

      .ns-cval {
        font-size: 1.5rem;
      }

      .ns-cval.sm {
        font-size: 1.2rem;
      }

      .ns-title {
        font-size: 1.8rem;
      }

      .ns-res-grid {
        flex-direction: column;
        gap: 16px;
      }
    }
  
[data-theme="dark"] {
  --bg: #080d14;
  --bg2: #0d1520;
  --surface: #101820;
  --card-bg: #121c28;
  --text: #e8f4f8;
  --text2: #7fa8c0;
  --border: rgba(0,229,255,0.18);
  --shadow: 0 4px 32px rgba(0,229,255,0.07);
  --nav-bg: rgba(8,13,20,0.95);
  --chat-bubble-ai: #1a2535;
  --chat-bubble-ai-text: #e8f4f8;
}

/* ===================== RESET & BASE ===================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Rajdhani', sans-serif;
  background: var(--bg);
  color: var(--text);
  transition: background var(--transition), color var(--transition);
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }

/* ===================== NOTIFICATION ===================== */
#notif-container {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.notif-item {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  padding: 14px 18px;
  border-radius: 10px;
  min-width: 280px;
  max-width: 320px;
  box-shadow: var(--shadow), var(--glow);
  pointer-events: all;
  animation: slideInNotif 0.4s ease forwards;
  position: relative;
  overflow: hidden;
}
.notif-item::before {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  height: 3px;
  background: var(--accent);
  animation: notifTimer 5s linear forwards;
}
.notif-item.exit { animation: slideOutNotif 0.35s ease forwards; }
.notif-title { font-family: 'Orbitron', monospace; font-size: 11px; color: var(--accent); font-weight: 700; letter-spacing: 1px; margin-bottom: 4px; }
.notif-body { font-size: 14px; color: var(--text); }
.notif-close { position: absolute; top: 8px; right: 10px; cursor: pointer; color: var(--text2); font-size: 14px; }
@keyframes slideInNotif { from { transform: translateX(120%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes slideOutNotif { to { transform: translateX(120%); opacity: 0; } }
@keyframes notifTimer { from { width: 100%; } to { width: 0%; } }

/* Notification Panel */
.notif-panel {
  position: fixed;
  top: 70px;
  right: 20px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  width: 300px;
  z-index: 9000;
  box-shadow: var(--shadow);
  animation: fadeIn 0.3s ease;
}
.notif-panel.hidden { display: none; }
.notif-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  font-family: 'Orbitron', monospace;
  font-size: 12px;
  color: var(--accent);
}
.notif-panel-header button { background: none; border: none; cursor: pointer; color: var(--text2); font-size: 16px; }
.notif-panel-body { padding: 14px 18px; display: flex; flex-direction: column; gap: 14px; }
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-size: 14px;
  color: var(--text);
}
.toggle-row input[type="checkbox"] { display: none; }
.slider {
  width: 44px; height: 24px;
  background: var(--bg2);
  border-radius: 12px;
  position: relative;
  transition: background 0.3s;
  flex-shrink: 0;
}
.slider::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 18px; height: 18px;
  background: var(--text2);
  border-radius: 50%;
  transition: 0.3s;
}
.toggle-row input:checked ~ .slider { background: var(--accent); }
.toggle-row input:checked ~ .slider::after { transform: translateX(20px); background: var(--bg); }
.notif-sound-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
}
.notif-sound-row select {
  background: var(--bg2);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 13px;
}
.notif-badge {
  position: absolute;
  top: -4px; right: -4px;
  background: var(--accent2);
  color: #fff;
  font-size: 9px;
  width: 16px; height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Orbitron', monospace;
  font-weight: 700;
}

/* ===================== NAVBAR ===================== */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 64px;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  z-index: 1000;
  transition: background var(--transition), box-shadow var(--transition);
}
#navbar.scrolled { box-shadow: 0 4px 30px rgba(0,229,255,0.12); }
.nav-logo { display: flex; align-items: center; gap: 12px; cursor: pointer; }
.logo-text { font-family: 'Orbitron', monospace; font-size: 18px; font-weight: 900; letter-spacing: 2px; color: var(--text); }
.accent { color: var(--accent); }
.nav-links { display: flex; gap: 28px; list-style: none; }
.nav-links a {
  font-family: 'Rajdhani', sans-serif;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--text2);
  text-transform: uppercase;
  transition: color 0.2s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width 0.3s;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a:hover::after { width: 100%; }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.notif-btn {
  background: none;
  border: none;
  cursor: pointer;
  position: relative;
  font-size: 18px;
  padding: 4px;
}
.theme-toggle {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  padding: 6px 10px;
  font-size: 16px;
  transition: all 0.2s;
  color: var(--text);
}
.theme-toggle:hover { border-color: var(--accent); box-shadow: var(--glow); }
.btn-nav {
  background: transparent;
  border: 1.5px solid var(--accent);
  color: var(--accent);
  padding: 7px 20px;
  border-radius: 8px;
  font-family: 'Orbitron', monospace;
  font-size: 12px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 700;
}
.btn-nav:hover { background: var(--accent); color: var(--bg); box-shadow: var(--glow); }

/* ===================== HERO ===================== */
.hero {
  min-height: 100vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 0 40px;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
#matrix-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.15;
}
[data-theme="light"] #matrix-canvas { opacity: 0.06; }
.hero-grid {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 60px 60px;
  opacity: 0.5;
}
.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 860px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(0,229,255,0.1);
  border: 1px solid var(--accent);
  border-radius: 100px;
  padding: 6px 18px;
  font-family: 'Share Tech Mono', monospace;
  font-size: 12px;
  color: var(--accent);
  letter-spacing: 2px;
  margin-bottom: 24px;
}
.pulse-dot {
  width: 8px; height: 8px;
  background: var(--accent3);
  border-radius: 50%;
  animation: pulse 1.5s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.5); opacity: 0.6; } }
.hero-title {
  font-family: 'Orbitron', monospace;
  font-size: clamp(48px, 8vw, 96px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -2px;
  margin-bottom: 24px;
}
.title-line { display: block; }
.accent-glow { color: var(--accent); text-shadow: 0 0 40px rgba(0,229,255,0.5); }
.hero-sub {
  font-size: clamp(16px, 2vw, 20px);
  color: var(--text2);
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.6;
  font-weight: 400;
}
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.stat-box {
  text-align: center;
  padding: 16px 28px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  min-width: 120px;
  transition: all 0.3s;
}
.stat-box:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: var(--glow); }
.stat-num {
  display: block;
  font-family: 'Orbitron', monospace;
  font-size: 28px;
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
}
.stat-label { font-size: 13px; color: var(--text2); font-weight: 600; letter-spacing: 1px; margin-top: 4px; display: block; }
.hero-cta { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: var(--bg);
  padding: 14px 32px;
  border-radius: 10px;
  font-family: 'Orbitron', monospace;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  border: none;
  position: relative;
  overflow: hidden;
  transition: all 0.25s;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--glow); }
.btn-primary::before {
  content: '';
  position: absolute;
  top: -50%; left: -60%;
  width: 40%; height: 200%;
  background: rgba(255,255,255,0.3);
  transform: skewX(-20deg);
  animation: shimmer 3s infinite;
}
@keyframes shimmer { 0% { left: -60%; } 100% { left: 160%; } }

.btn-secondary {
  background: transparent;
  color: var(--text);
  padding: 14px 32px;
  border-radius: 10px;
  font-family: 'Orbitron', monospace;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  cursor: pointer;
  border: 1.5px solid var(--border);
  transition: all 0.25s;
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }

.hero-scroll-hint {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text2);
  font-size: 12px;
  letter-spacing: 2px;
  font-family: 'Share Tech Mono', monospace;
}
.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, transparent, var(--accent));
  animation: scrollHint 1.5s ease-in-out infinite;
}
@keyframes scrollHint { 0%,100% { opacity: 0; transform: scaleY(0); transform-origin: top; } 50% { opacity: 1; transform: scaleY(1); } }

/* Animate in */
.animate-in { opacity: 0; transform: translateY(30px); animation: animIn 0.7s ease forwards; }
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.3s; }
.delay-3 { animation-delay: 0.5s; }
.delay-4 { animation-delay: 0.7s; }
.delay-5 { animation-delay: 0.9s; }
@keyframes animIn { to { opacity: 1; transform: translateY(0); } }

/* ===================== SECTIONS ===================== */
.section {
  padding: 100px 60px;
  max-width: 1200px;
  margin: 0 auto;
}
.section-label {
  font-family: 'Share Tech Mono', monospace;
  font-size: 12px;
  color: var(--accent);
  letter-spacing: 4px;
  margin-bottom: 16px;
  opacity: 0.8;
}
.section-title {
  font-family: 'Orbitron', monospace;
  font-size: clamp(28px, 4vw, 46px);
  font-weight: 900;
  margin-bottom: 60px;
  line-height: 1.2;
}

/* ===================== ABOUT ===================== */
.about-section { max-width: 1200px; margin: 0 auto; }
.about-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 80px; align-items: center; }
.about-visual { display: flex; flex-direction: column; align-items: center; gap: 28px; }
.cyber-mask {
  position: relative;
  width: 200px; height: 220px;
}
.cyber-mask svg { width: 100%; height: 100%; filter: drop-shadow(0 0 20px rgba(0,229,255,0.3)); }
.rotating-ring {
  position: absolute;
  inset: -20px;
  border: 2px dashed rgba(0,229,255,0.3);
  border-radius: 50%;
  animation: spin 8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.about-tags { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.tag {
  background: rgba(0,229,255,0.1);
  border: 1px solid var(--border);
  color: var(--accent);
  padding: 5px 12px;
  border-radius: 20px;
  font-family: 'Share Tech Mono', monospace;
  font-size: 11px;
  letter-spacing: 1px;
  transition: all 0.2s;
}
.tag:hover { background: rgba(0,229,255,0.2); transform: scale(1.05); }
.about-text h2 {
  font-family: 'Orbitron', monospace;
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 900;
  margin-bottom: 20px;
  line-height: 1.2;
}
.about-text p { color: var(--text2); line-height: 1.8; margin-bottom: 16px; font-size: 16px; font-weight: 400; }
.about-values { display: flex; flex-direction: column; gap: 20px; margin-top: 28px; }
.value-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: all 0.25s;
}
.value-item:hover { border-color: var(--accent); transform: translateX(4px); }
.value-icon { font-size: 24px; flex-shrink: 0; }
.value-item strong { display: block; font-family: 'Rajdhani', sans-serif; font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.value-item p { font-size: 14px; color: var(--text2); margin: 0; }

/* ===================== FEATURES ===================== */
.features-section { padding: 100px 60px; max-width: 1200px; margin: 0 auto; }
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.feature-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  position: relative;
  overflow: hidden;
  transition: all 0.35s;
  opacity: 0;
  transform: translateY(40px);
}
.feature-card.visible { opacity: 1; transform: translateY(0); transition: opacity 0.5s ease, transform 0.5s ease; }
.feature-card:hover {
  border-color: var(--accent);
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(0,229,255,0.12);
}
.feature-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}
.feature-card:hover::before { opacity: 1; }
.feature-icon { font-size: 36px; margin-bottom: 16px; }
.feature-card h3 { font-family: 'Orbitron', monospace; font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 12px; letter-spacing: 0.5px; }
.feature-card p { color: var(--text2); font-size: 15px; line-height: 1.6; font-weight: 400; }
.feature-tag {
  position: absolute;
  top: 16px; right: 16px;
  background: var(--accent);
  color: var(--bg);
  font-family: 'Orbitron', monospace;
  font-size: 9px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  letter-spacing: 1px;
}
.live-tag { background: var(--accent2); animation: blinkTag 1.5s ease-in-out infinite; }
@keyframes blinkTag { 0%,100% { opacity: 1; } 50% { opacity: 0.5; } }

/* ===================== MEMBERS ===================== */
.members-section { max-width: 1200px; margin: 0 auto; overflow: hidden; }
.members-ticker {
  width: 100%;
  overflow: hidden;
  padding: 24px 0;
  mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
  margin-bottom: 48px;
}
.ticker-track {
  display: flex;
  gap: 16px;
  animation: ticker 30s linear infinite;
  width: max-content;
}
@keyframes ticker { to { transform: translateX(-50%); } }
.ticker-card {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 10px 20px;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 600;
  transition: border-color 0.2s;
}
.ticker-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 900;
  color: var(--bg);
  flex-shrink: 0;
}
.members-cta { text-align: center; }
.members-cta p { font-size: 18px; color: var(--text2); margin-bottom: 28px; font-weight: 400; }
.members-cta strong { color: var(--text); }
.member-levels { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.level-badge {
  padding: 8px 20px;
  border-radius: 50px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 14px;
  font-weight: 700;
  background: var(--card-bg);
  border: 1px solid var(--border);
  transition: all 0.2s;
  cursor: pointer;
}
.level-badge:hover { border-color: var(--accent); color: var(--accent); }

/* ===================== CHAT ===================== */
.chat-section { max-width: 1200px; margin: 0 auto; }
.chat-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.chat-box {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 520px;
}
.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--bg2);
}
.chat-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Orbitron', monospace;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}
.online-dot {
  width: 10px; height: 10px;
  background: var(--accent3);
  border-radius: 50%;
  animation: pulse 1.5s ease-in-out infinite;
}
.online-count { font-family: 'Share Tech Mono', monospace; font-size: 12px; color: var(--accent3); }
.ai-avatar {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, var(--accent), #0066ff);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Orbitron', monospace;
  font-size: 11px;
  font-weight: 900;
  color: var(--bg);
  flex-shrink: 0;
}
.ai-status { display: block; font-family: 'Share Tech Mono', monospace; font-size: 10px; color: var(--accent); letter-spacing: 1px; }
.clear-btn { background: none; border: 1px solid var(--border); color: var(--text2); padding: 4px 12px; border-radius: 6px; font-size: 12px; cursor: pointer; transition: all 0.2s; }
.clear-btn:hover { border-color: var(--accent2); color: var(--accent2); }
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.msg { display: flex; flex-direction: column; max-width: 80%; animation: msgIn 0.3s ease; }
@keyframes msgIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.msg.user-msg { align-self: flex-end; align-items: flex-end; }
.msg.ai-msg, .msg.comm-msg { align-self: flex-start; align-items: flex-start; }
.msg-bubble {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.5;
  font-weight: 400;
  max-width: 100%;
  word-break: break-word;
}
.user-msg .msg-bubble { background: var(--accent); color: var(--bg); border-radius: 12px 12px 4px 12px; }
.ai-msg .msg-bubble, .comm-msg .msg-bubble { background: var(--chat-bubble-ai); color: var(--chat-bubble-ai-text); border-radius: 12px 12px 12px 4px; }
.msg-name { font-family: 'Orbitron', monospace; font-size: 10px; color: var(--accent); margin-bottom: 4px; letter-spacing: 1px; }
.msg-time { font-size: 11px; color: var(--text2); margin-top: 4px; font-family: 'Share Tech Mono', monospace; }
.typing-bubble .msg-bubble { display: flex; gap: 5px; align-items: center; padding: 12px 16px; }
.typing-dot { width: 7px; height: 7px; background: var(--text2); border-radius: 50%; animation: typingAnim 1.2s ease-in-out infinite; }
.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingAnim { 0%,60%,100% { transform: translateY(0); opacity: 0.4; } 30% { transform: translateY(-6px); opacity: 1; } }
.ai-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 16px;
  border-top: 1px solid var(--border);
}
.ai-suggestions button {
  background: rgba(0,229,255,0.08);
  border: 1px solid var(--border);
  color: var(--text2);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.ai-suggestions button:hover { border-color: var(--accent); color: var(--accent); background: rgba(0,229,255,0.15); }
.chat-input-row {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
}
.chat-input-row input {
  flex: 1;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 14px;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
}
.chat-input-row input:focus { border-color: var(--accent); }
.chat-input-row button {
  background: var(--accent);
  border: none;
  border-radius: 8px;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--bg);
  transition: all 0.2s;
  flex-shrink: 0;
}
.chat-input-row button:hover { transform: scale(1.05); box-shadow: var(--glow); }
.chat-input-row button:disabled { opacity: 0.5; cursor: not-allowed; }

/* ===================== JOIN SECTION ===================== */
.join-section {
  position: relative;
  text-align: center;
  padding: 120px 60px;
  overflow: hidden;
}
.join-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 50%, rgba(0,229,255,0.08) 0%, transparent 70%);
  pointer-events: none;
}
.join-content { position: relative; z-index: 1; max-width: 800px; margin: 0 auto; }
.join-content h2 { font-family: 'Orbitron', monospace; font-size: clamp(28px, 4vw, 44px); font-weight: 900; margin-bottom: 20px; line-height: 1.2; }
.join-content p { color: var(--text2); font-size: 18px; margin-bottom: 48px; font-weight: 400; }
.join-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}
.step { text-align: center; }
.step-num {
  font-family: 'Orbitron', monospace;
  font-size: 32px;
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 8px;
}
.step-text strong { display: block; font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.step-text span { font-size: 13px; color: var(--text2); font-weight: 400; }
.step-arrow { font-size: 24px; color: var(--border); font-weight: 300; }
.btn-large { padding: 18px 48px; font-size: 16px; border-radius: 12px; }
.btn-glow {
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.1);
  border-radius: inherit;
  animation: glowPulse 2s ease-in-out infinite;
}
@keyframes glowPulse { 0%,100% { opacity: 0; transform: scale(1); } 50% { opacity: 1; transform: scale(1.02); } }
.join-note { margin-top: 20px; font-size: 14px; color: var(--text2); font-weight: 600; letter-spacing: 1px; }

/* ===================== FOOTER ===================== */
.footer {
  background: var(--bg2);
  border-top: 1px solid var(--border);
  padding: 60px 60px 30px;
}
.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 48px;
  margin-bottom: 40px;
}
.footer-brand .logo-text { font-family: 'Orbitron', monospace; font-size: 20px; font-weight: 900; margin-bottom: 16px; }
.footer-brand p { color: var(--text2); font-size: 14px; line-height: 1.7; font-weight: 400; margin-bottom: 20px; }
.social-links a {
  display: inline-block;
  background: var(--card-bg);
  border: 1px solid var(--border);
  padding: 8px 20px;
  border-radius: 8px;
  font-size: 13px;
  font-family: 'Orbitron', monospace;
  letter-spacing: 1px;
  color: var(--accent);
  transition: all 0.2s;
}
.social-links a:hover { border-color: var(--accent); box-shadow: var(--glow); }
.footer-links h4 { font-family: 'Orbitron', monospace; font-size: 12px; color: var(--accent); letter-spacing: 2px; margin-bottom: 16px; }
.footer-links ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-links li a { font-size: 14px; color: var(--text2); transition: color 0.2s; font-weight: 400; }
.footer-links li a:hover { color: var(--accent); }
.footer-stats h4 { font-family: 'Orbitron', monospace; font-size: 12px; color: var(--accent); letter-spacing: 2px; margin-bottom: 16px; }
.status-item { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text2); margin-bottom: 10px; font-weight: 400; }
.dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.dot.green { background: var(--accent3); box-shadow: 0 0 6px var(--accent3); }
.dot.yellow { background: #ffcc00; box-shadow: 0 0 6px #ffcc00; }
.member-counter {
  margin-top: 16px;
  padding: 12px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-align: center;
}
.member-counter span:first-child { display: block; font-family: 'Orbitron', monospace; font-size: 22px; font-weight: 900; color: var(--accent); }
.member-counter span:last-child { font-size: 12px; color: var(--text2); font-family: 'Share Tech Mono', monospace; }
.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text2);
  font-family: 'Share Tech Mono', monospace;
}

/* ===================== FAB ===================== */
.fab-chat {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 58px;
  height: 58px;
  background: var(--accent);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg);
  box-shadow: 0 4px 24px rgba(0,229,255,0.4);
  transition: all 0.3s;
  z-index: 500;
}
.fab-chat:hover { transform: scale(1.1) translateY(-2px); box-shadow: 0 8px 32px rgba(0,229,255,0.6); }
.fab-badge {
  position: absolute;
  top: -2px; right: -2px;
  background: var(--accent2);
  color: #fff;
  font-size: 10px;
  width: 18px; height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Orbitron', monospace;
  font-weight: 700;
  animation: pulse 1.5s ease-in-out infinite;
}

/* ===================== UTILITIES ===================== */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ===================== HAT TYPES SECTION ===================== */
.hat-types-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 100px 60px;
  position: relative;
}

.hat-types-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,255,65,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,65,0.02) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
}

.section-subtitle {
  font-size: clamp(14px, 2vw, 18px);
  color: var(--text2);
  text-align: center;
  margin-top: -40px;
  margin-bottom: 60px;
  font-weight: 400;
}

/* Hat Grid */
.hat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-bottom: 80px;
  position: relative;
}

/* Hat Card Base */
.hat-card {
  position: relative;
  background: var(--card-bg);
  border: 1.5px solid var(--border);
  border-radius: 16px;
  padding: 32px 28px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0;
  transform: translateY(30px);
}

.hat-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.hat-glow {
  position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.4s;
}

.hat-card:hover::before {
  opacity: 1;
}

.hat-card:hover {
  transform: translateY(-8px) scale(1.01);
  border-color: var(--accent);
  box-shadow: 0 20px 60px rgba(0,229,255,0.15);
}

/* Hat Header */
.hat-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.hat-icon {
  font-size: 48px;
  line-height: 1;
  filter: drop-shadow(0 0 12px rgba(0,229,255,0.4));
  transition: transform 0.3s;
}

.hat-card:hover .hat-icon {
  transform: scale(1.1) rotate(5deg);
}

.hat-label {
  font-family: 'Share Tech Mono', monospace;
  font-size: 10px;
  letter-spacing: 3px;
  color: rgba(0,255,65,0.5);
  border: 1px solid rgba(0,255,65,0.2);
  padding: 4px 10px;
  border-radius: 4px;
}

.hat-title {
  font-family: 'Orbitron', monospace;
  font-size: 26px;
  font-weight: 900;
  color: var(--text);
  margin-bottom: 14px;
  letter-spacing: 1px;
}

.hat-accent {
  color: var(--accent);
  text-shadow: 0 0 20px rgba(0,229,255,0.6);
}

.hat-desc {
  font-size: 15px;
  color: var(--text2);
  line-height: 1.7;
  margin-bottom: 20px;
  font-weight: 400;
}

/* Hat Traits / List */
.hat-traits {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
}

.hat-traits li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Share Tech Mono', monospace;
  font-size: 12px;
  color: var(--text2);
  line-height: 1.5;
}

.trait-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 6px currentColor;
}

.trait-dot.safe { background: #39ff14; color: #39ff14; }
.trait-dot.warn { background: #ffa500; color: #ffa500; }
.trait-dot.bad  { background: #ff073a; color: #ff073a; }

/* Hat Badge */
.hat-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Orbitron', monospace;
  font-size: 10px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 6px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.hat-badge.success {
  background: rgba(57, 255, 20, 0.1);
  color: #39ff14;
  border: 1px solid rgba(57, 255, 20, 0.3);
  box-shadow: 0 0 14px rgba(57, 255, 20, 0.25);
}

.hat-badge.warning {
  background: rgba(255, 165, 0, 0.1);
  color: #ffa500;
  border: 1px solid rgba(255, 165, 0, 0.3);
  box-shadow: 0 0 14px rgba(255, 165, 0, 0.25);
}

.hat-badge.danger {
  background: rgba(255, 7, 58, 0.1);
  color: #ff073a;
  border: 1px solid rgba(255, 7, 58, 0.3);
  box-shadow: 0 0 14px rgba(255, 7, 58, 0.25);
}

/* Specific Card Colors */
.black-hat:hover {
  border-color: #ff073a;
  box-shadow: 0 20px 60px rgba(255, 7, 58, 0.2);
}

.gray-hat:hover {
  border-color: #ffa500;
  box-shadow: 0 20px 60px rgba(255, 165, 0, 0.2);
}

.white-hat:hover {
  border-color: #39ff14;
  box-shadow: 0 20px 60px rgba(57, 255, 20, 0.2);
}

/* Comparison Table */
.hat-comparison {
  margin-top: 60px;
  margin-bottom: 80px;
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

.comparison-title {
  font-family: 'Orbitron', monospace;
  font-size: 20px;
  color: var(--accent);
  text-align: center;
  margin-bottom: 32px;
  letter-spacing: 2px;
}

.comparison-table {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
}

.comparison-row {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  border-bottom: 1px solid var(--border);
}

.comparison-row:last-child {
  border-bottom: none;
}

.comparison-row.header {
  background: rgba(0,229,255,0.05);
}

.comparison-row.header span {
  font-family: 'Orbitron', monospace;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 1px;
  padding: 16px 20px;
}

.comparison-row:not(.header) span {
  padding: 14px 20px;
  font-size: 14px;
  color: var(--text2);
  display: flex;
  align-items: center;
  font-weight: 400;
}

.comparison-row span:first-child {
  font-family: 'Share Tech Mono', monospace;
  font-weight: 700;
  color: var(--text);
  letter-spacing: 1px;
  border-right: 1px solid var(--border);
}

.bad-cell { color: #ff073a !important; }
.warn-cell { color: #ffa500 !important; }
.good-cell { color: #39ff14 !important; }

/* CTA Section */
.hat-cta {
  text-align: center;
  padding: 48px 32px;
  background: linear-gradient(135deg, rgba(0,229,255,0.05), rgba(57,255,20,0.05));
  border: 1px solid var(--border);
  border-radius: 16px;
  position: relative;
  overflow: hidden;
}

.hat-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0,255,65,0.03) 2px,
    rgba(0,255,65,0.03) 4px
  );
  pointer-events: none;
}

.hat-cta p {
  font-size: 18px;
  color: var(--text2);
  margin-bottom: 28px;
  font-weight: 400;
}

.hat-cta strong { color: var(--text); }

/* Responsive */
@media (max-width: 960px) {
  .hat-grid { grid-template-columns: 1fr; }
  .comparison-row { grid-template-columns: 1fr 1fr; }
  .comparison-row span:first-child {
    grid-column: 1 / -1;
    border-bottom: 1px solid var(--border);
    border-right: none;
    padding-bottom: 8px;
    margin-bottom: 8px;
  }
  .comparison-row.header span:first-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
  }
}

@media (max-width: 600px) {
  .hat-types-section { padding: 80px 24px; }
  .hat-card { padding: 24px 20px; }
  .hat-title { font-size: 22px; }
  .comparison-row { grid-template-columns: 1fr; }
  .comparison-row span:first-child {
    border: none;
    padding-bottom: 0;
    margin-bottom: 4px;
  }
  .comparison-row.header span { font-size: 11px; padding: 12px 16px; }
  .comparison-row:not(.header) span { padding: 12px 16px; }
}

/* Animation Delays for Stagger */
.hat-card[data-hat="black"] { transition-delay: 0.1s; }
.hat-card[data-hat="gray"]  { transition-delay: 0.2s; }
.hat-card[data-hat="white"] { transition-delay: 0.3s; }

@media (max-width: 960px) {
  #navbar { padding: 0 20px; }
  .nav-links { display: none; }
  .section { padding: 80px 24px; }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .features-grid { grid-template-columns: 1fr 1fr; }
  .chat-layout { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .join-section { padding: 80px 24px; }
  .hero { padding: 0 20px; }
}
@media (max-width: 600px) {
  .features-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-stats { gap: 12px; }
  .stat-box { padding: 12px 16px; min-width: 90px; }
  .join-steps { flex-direction: column; }
  .step-arrow { transform: rotate(90deg); }
  .footer { padding: 40px 20px 20px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}
