  :root {
    --bg: #0a0a0f;
    --surface: #12121a;
    --card: #1a1a26;
    --border: #2a2a3a;
    --accent: #7c3aed;
    --accent2: #06b6d4;
    --accent3: #f59e0b;
    --green: #10b981;
    --red: #ef4444;
    --text: #e2e8f0;
    --muted: #64748b;
    --tag-bg: #1e1b4b;
  }

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

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

  /* Grid background */
  body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
      linear-gradient(rgba(124,58,237,0.04) 1px, transparent 1px),
      linear-gradient(90deg, rgba(124,58,237,0.04) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
    z-index: 0;
  }

  .container { max-width: 960px; margin: 0 auto; padding: 0 20px; position: relative; z-index: 1; }

  /* HEADER */
  header {
    padding: 40px 20px 20px;
    text-align: center;
    position: relative;
    z-index: 1;
  }

  .badge {
    display: inline-block;
    background: var(--tag-bg);
    border: 1px solid var(--accent);
    color: #a78bfa;
    font-family: 'Space Mono', monospace;
    font-size: 11px;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 16px;
    letter-spacing: 2px;
    text-transform: uppercase;
  }

  h1 {
    font-size: clamp(2rem, 6vw, 3.5rem);
    font-weight: 800;
    line-height: 1.1;
    background: linear-gradient(135deg, #a78bfa 0%, #06b6d4 50%, #f59e0b 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 12px;
  }

  .subtitle {
    color: var(--muted);
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    margin-bottom: 32px;
  }

  /* PROGRESS BAR */
  .progress-section {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px 24px;
    margin-bottom: 28px;
    display: flex;
    gap: 24px;
    align-items: center;
    flex-wrap: wrap;
  }

  .stat { text-align: center; min-width: 70px; }
  .stat-num {
    font-size: 1.8rem;
    font-weight: 800;
    font-family: 'Space Mono', monospace;
  }
  .stat-num.purple { color: #a78bfa; }
  .stat-num.cyan { color: var(--accent2); }
  .stat-num.gold { color: var(--accent3); }
  .stat-label { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }

  .progress-bar-wrap { flex: 1; min-width: 200px; }
  .progress-bar-label { font-size: 12px; color: var(--muted); margin-bottom: 6px; display: flex; justify-content: space-between; }
  .progress-bar {
    height: 8px;
    background: var(--border);
    border-radius: 10px;
    overflow: hidden;
  }
  .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent), var(--accent2));
    border-radius: 10px;
    transition: width 0.5s ease;
  }

  /* FILTER TABS */
  .filter-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    flex-wrap: wrap;
  }

  .tab-btn {
    padding: 8px 18px;
    border-radius: 30px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--muted);
    font-family: 'Syne', sans-serif;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    letter-spacing: 0.5px;
  }
  .tab-btn:hover { border-color: var(--accent); color: #a78bfa; }
  .tab-btn.active { background: var(--accent); border-color: var(--accent); color: white; }
  .tab-btn.beginner.active { background: var(--green); border-color: var(--green); }
  .tab-btn.intermediate.active { background: var(--accent3); border-color: var(--accent3); color: #0a0a0f; }
  .tab-btn.advanced.active { background: var(--red); border-color: var(--red); }

  /* QUESTION CARDS */
  .questions-grid { display: flex; flex-direction: column; gap: 16px; margin-bottom: 40px; }

  .q-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    transition: border-color 0.2s, transform 0.2s;
    cursor: pointer;
  }
  .q-card:hover { border-color: var(--accent); transform: translateX(4px); }
  .q-card.solved { border-color: var(--green); opacity: 0.7; }

  .q-header {
    padding: 18px 22px;
    display: flex;
    align-items: center;
    gap: 14px;
  }

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

  .q-badge {
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    white-space: nowrap;
  }
  .badge-beginner { background: rgba(16,185,129,0.15); color: var(--green); border: 1px solid rgba(16,185,129,0.3); }
  .badge-intermediate { background: rgba(245,158,11,0.15); color: var(--accent3); border: 1px solid rgba(245,158,11,0.3); }
  .badge-advanced { background: rgba(239,68,68,0.15); color: var(--red); border: 1px solid rgba(239,68,68,0.3); }

  .q-topic {
    font-size: 10px;
    color: var(--muted);
    padding: 3px 10px;
    border-radius: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    white-space: nowrap;
  }

  .q-title {
    flex: 1;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    line-height: 1.4;
  }

  .q-expand-icon {
    color: var(--muted);
    font-size: 18px;
    transition: transform 0.3s;
    flex-shrink: 0;
  }
  .q-card.open .q-expand-icon { transform: rotate(180deg); }
  .solved-check { color: var(--green); font-size: 18px; }

  .q-body {
    display: none;
    border-top: 1px solid var(--border);
    padding: 0;
  }
  .q-card.open .q-body { display: block; }

  .q-description {
    padding: 18px 22px;
    font-size: 14px;
    color: #94a3b8;
    line-height: 1.7;
    font-family: 'Space Mono', monospace;
    border-bottom: 1px solid var(--border);
  }

  .q-description code {
    background: rgba(124,58,237,0.15);
    color: #a78bfa;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 13px;
  }

  /* Code answer area */
  .answer-area { padding: 18px 22px; }
  .answer-label { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: 1.5px; margin-bottom: 10px; font-family: 'Space Mono', monospace; }

  .code-editor {
    width: 100%;
    min-height: 100px;
    background: #0d0d14;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: #a78bfa;
    font-family: 'Space Mono', monospace;
    font-size: 13px;
    padding: 14px;
    resize: vertical;
    outline: none;
    transition: border-color 0.2s;
    line-height: 1.6;
  }
  .code-editor:focus { border-color: var(--accent); }
  .code-editor::placeholder { color: #3d3d5c; }

  .answer-actions { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }

  .btn {
    padding: 9px 20px;
    border-radius: 8px;
    border: none;
    font-family: 'Syne', sans-serif;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    letter-spacing: 0.5px;
  }
  .btn-primary { background: var(--accent); color: white; }
  .btn-primary:hover { background: #6d28d9; transform: translateY(-1px); }
  .btn-hint { background: var(--surface); color: var(--accent3); border: 1px solid rgba(245,158,11,0.3); }
  .btn-hint:hover { background: rgba(245,158,11,0.1); }
  .btn-solution { background: var(--surface); color: var(--accent2); border: 1px solid rgba(6,182,212,0.3); }
  .btn-solution:hover { background: rgba(6,182,212,0.1); }
  .btn-mark { background: var(--surface); color: var(--green); border: 1px solid rgba(16,185,129,0.3); }
  .btn-mark:hover { background: rgba(16,185,129,0.1); }

  .hint-box, .solution-box {
    margin-top: 14px;
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 13px;
    line-height: 1.7;
    display: none;
  }
  .hint-box { background: rgba(245,158,11,0.08); border: 1px solid rgba(245,158,11,0.2); color: #fcd34d; font-family: 'Space Mono', monospace; }
  .solution-box { background: rgba(6,182,212,0.08); border: 1px solid rgba(6,182,212,0.2); color: #67e8f9; font-family: 'Space Mono', monospace; white-space: pre-wrap; }
  .hint-box.visible, .solution-box.visible { display: block; animation: fadeIn 0.3s ease; }

  @keyframes fadeIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }

  /* ROADMAP section */
  .section-title {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .section-title::before {
    content: '';
    width: 4px;
    height: 24px;
    background: linear-gradient(var(--accent), var(--accent2));
    border-radius: 4px;
    display: block;
  }

  .roadmap { display: flex; flex-direction: column; gap: 0; margin-bottom: 40px; }

  .roadmap-phase {
    display: flex;
    gap: 20px;
    padding: 20px 0;
    position: relative;
  }
  .roadmap-phase:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 19px;
    top: 50px;
    bottom: 0;
    width: 2px;
    background: var(--border);
  }

  .phase-dot {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 14px;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
  }
  .phase-dot.p1 { background: rgba(16,185,129,0.2); border: 2px solid var(--green); color: var(--green); }
  .phase-dot.p2 { background: rgba(245,158,11,0.2); border: 2px solid var(--accent3); color: var(--accent3); }
  .phase-dot.p3 { background: rgba(124,58,237,0.2); border: 2px solid var(--accent); color: #a78bfa; }
  .phase-dot.p4 { background: rgba(239,68,68,0.2); border: 2px solid var(--red); color: var(--red); }

  .phase-content { flex: 1; }
  .phase-title { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
  .phase-desc { font-size: 13px; color: var(--muted); line-height: 1.6; }
  .phase-topics { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
  .phase-tag {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 6px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--muted);
  }

  /* Tip cards */
  .tips-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; margin-bottom: 40px; }
  .tip-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 18px;
  }
  .tip-icon { font-size: 24px; margin-bottom: 10px; }
  .tip-title { font-size: 14px; font-weight: 700; margin-bottom: 6px; }
  .tip-text { font-size: 12px; color: var(--muted); line-height: 1.7; font-family: 'Space Mono', monospace; }

  footer { text-align: center; padding: 30px; color: var(--muted); font-size: 12px; font-family: 'Space Mono', monospace; }

  .hidden { display: none !important; }

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