
* { margin: 0; padding: 0; box-sizing: border-box; }
    :root { --bg: #FFFFF8; --text: #111111; --border: rgba(17, 17, 17, 0.15); --muted: rgba(0,0,0,0.4); }
    body.dark { --bg: #111111; --text: #FFFFF8; --border: rgba(255, 255, 248, 0.15); --muted: rgba(255,255,255,0.4); }
    body { font-family: -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif; background: var(--bg); color: var(--text); line-height: 1.4; letter-spacing: -0.02em; transition: background 0.2s, color 0.2s; }
    a { color: inherit; text-decoration: none; }

    .topbar { border-bottom: 1px solid var(--border); padding: 20px 40px; display: flex; justify-content: space-between; align-items: center; }
    .topbar-left { display: flex; align-items: center; gap: 24px; }
    .topbar-left a { font-size: 14px; opacity: 0.5; }
    .topbar-left a:hover { opacity: 1; }
    .topbar-left a.active { opacity: 1; }
    .topbar-title { font-size: 14px; }
    .topbar-right button { background: none; border: 1px solid var(--border); color: var(--text); padding: 6px 12px; font-family: inherit; font-size: 13px; cursor: pointer; }

    .content { max-width: 1100px; margin: 0 auto; padding: 40px; }
    .page-label { font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; opacity: 0.4; margin-bottom: 12px; }
    .page-title { font-size: 36px; font-weight: 400; letter-spacing: -0.03em; line-height: 1.1; margin-bottom: 16px; }
    .page-desc { font-size: 14px; opacity: 0.5; margin-bottom: 40px; }

    /* Metro legend */
    .metro-legend { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
    .metro-btn { padding: 8px 16px; border: 1px solid var(--border); background: transparent; color: var(--text); font-family: inherit; font-size: 13px; cursor: pointer; display: flex; align-items: center; gap: 6px; opacity: 0.5; transition: opacity 0.15s; }
    .metro-btn:hover, .metro-btn.active { opacity: 1; }
    .metro-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }

    /* Line detail */
    .line-detail { border: 1px solid var(--border); padding: 24px; margin-bottom: 40px; display: none; }
    .line-detail.visible { display: block; }
    .line-detail-title { font-size: 16px; margin-bottom: 16px; }
    .line-stations { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
    .station { padding: 8px 16px; border: 1px solid var(--border); font-size: 13px; cursor: pointer; transition: opacity 0.15s; }
    .station:hover { opacity: 0.5; }
    .station-arrow { opacity: 0.3; font-size: 16px; }

    /* Phase grid */
    .phase-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 1px; border: 1px solid var(--border); margin-bottom: 40px; }
    .phase-node { padding: 20px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); cursor: pointer; transition: opacity 0.15s; }
    .phase-node:hover { opacity: 0.6; }
    .phase-id { font-size: 24px; margin-bottom: 4px; }
    .phase-name { font-size: 11px; opacity: 0.5; line-height: 1.3; }
    .phase-xp { font-size: 11px; opacity: 0.3; margin-top: 8px; }
    .phase-dots { margin-top: 8px; display: flex; gap: 3px; }
    .phase-progress { height: 2px; background: rgba(128,128,128,0.2); margin-top: 8px; }
    .phase-progress .fill { height: 100%; background: var(--text); }

    /* Detail panel */
    .detail-panel { border: 1px solid var(--border); padding: 24px; margin-bottom: 40px; display: none; }
    .detail-panel.visible { display: block; }
    .detail-title { font-size: 18px; margin-bottom: 8px; }
    .detail-question { font-size: 13px; opacity: 0.5; font-style: italic; margin-bottom: 16px; }
    .detail-meta { font-size: 12px; opacity: 0.4; margin-bottom: 16px; }
    .detail-comp { padding: 8px 0; border-bottom: 1px solid rgba(128,128,128,0.15); font-size: 13px; }
    .detail-comp:last-child { border-bottom: none; }
    .detail-notion { padding-left: 16px; font-size: 12px; opacity: 0.6; padding-top: 4px; }
    .detail-sub { padding-left: 32px; font-size: 11px; opacity: 0.4; }

    /* Prereq flow */
    .prereq-section { border: 1px solid var(--border); padding: 24px; margin-bottom: 40px; }
    .prereq-title { font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.4; margin-bottom: 16px; }
    .prereq-flow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; }
    .prereq-node { padding: 6px 12px; border: 1px solid var(--border); }
    .prereq-arrow { opacity: 0.3; }

    /* Metro map canvas */
    .metro-map-section { border: 1px solid var(--border); padding: 24px; margin-bottom: 40px; }
    .metro-map-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
    .metro-map-title { font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.4; }
    .metro-map-hint { font-size: 12px; opacity: 0.3; }
    .metro-map-scroll { overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; }
    .metro-map-wrap { position: relative; }
    #metroMapCanvas { display: block; }
    .metro-map-tooltip { position: absolute; background: var(--bg); border: 1px solid var(--border); padding: 10px 14px; font-size: 12px; pointer-events: none; display: none; z-index: 10; max-width: 260px; line-height: 1.4; }
    .metro-map-tooltip .mtt-id { opacity: 0.4; font-size: 11px; }
    .metro-map-tooltip .mtt-name { margin-top: 2px; }
    .metro-map-tooltip .mtt-lines { opacity: 0.5; font-size: 11px; margin-top: 4px; }

    /* Constellation */
    .constellation-section { border: 1px solid var(--border); padding: 24px; }
    .constellation-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
    .constellation-title { font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.4; }
    .constellation-hint { font-size: 12px; opacity: 0.3; }
    .constellation-wrap { position: relative; border-radius: 8px; overflow: hidden; }
    #constellationCanvas { display: block; width: 100%; cursor: default; }
    .constellation-tooltip { position: absolute; background: rgba(10,10,30,0.92); border: 1px solid rgba(255,255,255,0.2); color: #fff; padding: 10px 14px; font-size: 12px; pointer-events: none; display: none; z-index: 10; max-width: 280px; line-height: 1.4; border-radius: 4px; backdrop-filter: blur(6px); }
    .constellation-tooltip .tt-id { opacity: 0.5; font-size: 11px; }
    .constellation-tooltip .tt-name { margin-top: 2px; font-weight: 500; }
    .constellation-tooltip .tt-phase { opacity: 0.6; font-size: 11px; margin-top: 4px; }
    .constellation-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 12px; font-size: 11px; opacity: 0.5; }
    .constellation-legend span { display: flex; align-items: center; gap: 4px; }

    @media (max-width: 600px) {
      .content { padding: 20px; }
      .phase-grid { grid-template-columns: repeat(2, 1fr); }
      .page-title { font-size: 28px; }
    }
      /* Nav */
    .logo{font-size:18px;font-weight:500;display:flex;align-items:center;gap:12px;color:var(--text);text-decoration:none}
    @media(max-width:768px){.nav-center{display:none}}
