/* ============================================================
       DESIGN TOKENS — EDITH DARK PALETTE
    ============================================================ */
    :root {
      /* Backgrounds */
      --bg:          #0A0A0F;
      --bg-surface:  #12121A;
      --bg-elevated: #1A1A26;
      --bg-hover:    #22223A;
      --border:      rgba(255,255,255,0.07);
      --border-accent: rgba(108,63,255,0.3);

      /* Text — all tokens pass WCAG 2.2 AA (4.5:1) on --bg.
         For purple text use --purple-glow (5.3:1), never --purple (3.6:1 — borders/large UI only). */
      --text:        #F0EDE8;
      --text-muted:  #8A8A9A;
      --text-dim:    #8288A2;

      /* Accents */
      --purple:      #6C3FFF;
      --purple-glow: #8B6AFF;
      --purple-dim:  rgba(108,63,255,0.15);
      --teal:        #00B4D8;
      --teal-dim:    rgba(0,180,216,0.12);

      /* Status */
      --green:       #4ADE80;
      --amber:       #FBBF24;
      --red:         #F87171;

      /* Typography */
      --font:        'Inter', system-ui, sans-serif;
      --mono:        'JetBrains Mono', monospace;

      /* Spacing */
      --section-pad: 4rem 0;
      --container:   1200px;

      /* Transitions */
      --ease:        cubic-bezier(0.4, 0, 0.2, 1);
      --fast:        150ms;
      --mid:         300ms;
      --slow:        500ms;
    }

    /* ============================================================
       RESET & BASE
    ============================================================ */
    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
    html { scroll-behavior: smooth; overflow-x: hidden; }

    body {
      font-family: var(--font);
      background: var(--bg);
      color: var(--text);
      line-height: 1.7;
      font-size: 1rem;
      overflow-x: hidden;
      max-width: 100%;
    }

    h1,h2,h3,h4,h5 { line-height: 1.2; font-weight: 700; color: var(--text); }
    a { color: inherit; text-decoration: none; }
    ul { list-style: none; }
    img { max-width: 100%; display: block; }

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

    /* ============================================================
       PARTICLES CANVAS
    ============================================================ */
    #particles { position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: 0.5; }
    /* Content always stacks above the constellation canvas, on every page —
       without this, pages whose <main> is unpositioned get dots drawn over text */
    main { position: relative; z-index: 1; }

    /* ============================================================
       LAYOUT
    ============================================================ */
    .container {
      max-width: var(--container);
      margin: 0 auto;
      padding: 0 2rem;
    }

    .section {
      padding: var(--section-pad);
      position: relative;
      z-index: 1;
    }

    .section-label {
      display: inline-flex;
      align-items: center;
      gap: 0.5rem;
      font-size: 0.75rem;
      font-weight: 600;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      color: var(--purple);
      margin-bottom: 1rem;
    }
    .section-label::before {
      content: '';
      width: 1.5rem;
      height: 1px;
      background: var(--purple);
    }

    .section-title,
    .section-heading {
      font-size: clamp(1.75rem, 4vw, 2.5rem);
      font-weight: 800;
      margin-bottom: 0.75rem;
      background: linear-gradient(135deg, var(--text) 60%, var(--text-muted));
      -webkit-background-clip: text;
      -webkit-text-fill-color: transparent;
      background-clip: text;
    }

    .section-sub {
      color: var(--text-muted);
      font-size: 1.05rem;
      max-width: 560px;
      margin-bottom: 3.5rem;
    }

    /* ============================================================
       FLOATING NAV
    ============================================================ */
    .nav-wrap {
      position: fixed;
      top: 1.25rem;
      left: 50%;
      transform: translateX(-50%);
      z-index: 1000;
      width: calc(100% - 4rem);
      max-width: 820px;
    }

    .nav {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 0.75rem 1.5rem;
      background: rgba(10, 10, 15, 0.75);
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      border: 1px solid var(--border);
      border-radius: 999px;
      transition: background var(--mid) var(--ease), border-color var(--mid) var(--ease);
    }

    .nav.scrolled {
      background: rgba(10, 10, 15, 0.92);
      border-color: rgba(108,63,255,0.2);
    }

    .nav-left {
      display: flex;
      align-items: center;
      gap: 0.75rem;
    }

    .nav-location {
      display: flex;
      align-items: center;
      gap: 0.35rem;
      padding: 0.25rem 0.7rem;
      background: var(--purple-dim);
      border: 1px solid var(--border-accent);
      border-radius: 999px;
      font-size: 0.7rem;
      font-weight: 500;
      color: var(--purple-glow);
      white-space: nowrap;
    }
    .nav-location i { font-size: 0.6rem; }

    .nav-logo {
      font-size: 1rem;
      font-weight: 700;
      font-family: var(--mono);
      color: var(--text);
      letter-spacing: -0.02em;
    }
    .nav-logo span { color: var(--purple); }

    .nav-links {
      display: flex;
      align-items: center;
      gap: 0.25rem;
    }

    .nav-links a {
      padding: 0.4rem 0.875rem;
      border-radius: 999px;
      font-size: 0.875rem;
      font-weight: 500;
      color: var(--text-muted);
      transition: color var(--fast), background var(--fast);
    }
    .nav-links a:hover, .nav-links a.active {
      color: var(--text);
      background: var(--bg-elevated);
    }

    .nav-cta {
      padding: 0.45rem 1.1rem;
      background: var(--purple);
      color: var(--text) !important;
      border-radius: 999px;
      font-size: 0.875rem;
      font-weight: 600;
      transition: background var(--fast) !important;
    }
    .nav-cta:hover { background: var(--purple-glow) !important; }

    /* ============================================================
       HERO
    ============================================================ */
    .hero {
      min-height: 100vh;
      display: flex;
      align-items: center;
      padding: 8rem 0 3rem;
      position: relative;
      overflow: hidden;
    }

    /* Glow orbs */
    .hero::before {
      content: '';
      position: absolute;
      top: 10%;
      left: -5%;
      width: 600px;
      height: 600px;
      background: radial-gradient(circle, rgba(108,63,255,0.18) 0%, transparent 70%);
      pointer-events: none;
    }
    .hero::after {
      content: '';
      position: absolute;
      bottom: 5%;
      right: -5%;
      width: 500px;
      height: 500px;
      background: radial-gradient(circle, rgba(0,180,216,0.1) 0%, transparent 70%);
      pointer-events: none;
    }

    .hero-inner,
    .hero-grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 4rem;
      align-items: center;
    }

    .hero-badge {
      display: inline-flex;
      align-items: center;
      gap: 0.5rem;
      padding: 0.4rem 0.875rem;
      background: var(--purple-dim);
      border: 1px solid var(--border-accent);
      border-radius: 999px;
      font-size: 0.8rem;
      font-weight: 500;
      color: var(--purple-glow);
      margin-bottom: 1.5rem;
    }
    .hero-badge i { font-size: 0.7rem; }

    .hero-title {
      font-size: clamp(2.5rem, 6vw, 4rem);
      font-weight: 900;
      line-height: 1.1;
      margin-bottom: 1.25rem;
      letter-spacing: -0.02em;
    }

    .hero-title .name {
      display: block;
      background: linear-gradient(135deg, var(--text) 30%, var(--purple-glow) 100%);
      -webkit-background-clip: text;
      -webkit-text-fill-color: transparent;
      background-clip: text;
    }

    .hero-role {
      font-size: clamp(1rem, 2.5vw, 1.2rem);
      font-weight: 500;
      color: var(--text-muted);
      margin-bottom: 1.5rem;
    }
    .hero-role .pill {
      display: inline-block;
      padding: 0.2rem 0.65rem;
      background: var(--teal-dim);
      border: 1px solid rgba(0,180,216,0.25);
      border-radius: 999px;
      color: var(--teal);
      font-size: 0.85rem;
      font-weight: 600;
      margin-left: 0.25rem;
    }

    .hero-desc {
      color: var(--text-muted);
      font-size: 1.05rem;
      line-height: 1.75;
      margin-bottom: 2.5rem;
      max-width: 480px;
    }

    .hero-stats {
      display: flex;
      gap: 2rem;
      margin-bottom: 2.5rem;
    }
    .hero-stat { text-align: center; }
    .hero-stat-num,
    .stat-num {
      display: block;
      font-size: 1.75rem;
      font-weight: 800;
      color: var(--text);
      font-family: var(--mono);
    }
    .hero-stat-label,
    .stat-lbl {
      font-size: 0.75rem;
      color: var(--text-muted);
      text-transform: uppercase;
      letter-spacing: 0.08em;
    }

    .hero-actions {
      display: flex;
      gap: 1rem;
      flex-wrap: wrap;
    }

    .btn {
      display: inline-flex;
      align-items: center;
      gap: 0.5rem;
      padding: 0.75rem 1.5rem;
      border-radius: 999px;
      font-size: 0.9rem;
      font-weight: 600;
      border: none;
      cursor: pointer;
      transition: all var(--mid) var(--ease);
      white-space: nowrap;
    }
    .btn-primary {
      background: var(--purple);
      color: var(--text);
    }
    .btn-primary:hover {
      background: var(--purple-glow);
      transform: translateY(-1px);
      box-shadow: 0 8px 30px rgba(108,63,255,0.4);
    }
    .btn-outline,
    .btn-ghost {
      background: transparent;
      color: var(--text);
      border: 1px solid var(--border);
    }
    .btn-outline:hover,
    .btn-ghost:hover {
      background: var(--bg-elevated);
      border-color: var(--border-accent);
      transform: translateY(-1px);
    }

    .hero-socials {
      display: flex;
      gap: 1rem;
      margin-top: 2rem;
    }
    .hero-social-link {
      width: 2.25rem;
      height: 2.25rem;
      display: flex;
      align-items: center;
      justify-content: center;
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: 50%;
      color: var(--text-muted);
      font-size: 0.875rem;
      transition: all var(--fast);
    }
    .hero-social-link:hover {
      color: var(--text);
      border-color: var(--purple);
      background: var(--purple-dim);
    }

    /* Hero right — profile card */
    .hero-visual {
      display: flex;
      justify-content: center;
      align-items: center;
      position: relative;
    }

    .profile-card {
      position: relative;
      width: 280px;
      height: 280px;
    }

    /* HTML uses .profile-ring as the outer container */
    .profile-ring {
      position: relative;
      width: 280px;
      height: 280px;
    }

    @keyframes spin { to { transform: rotate(360deg); } }

    .profile-img-wrap {
      width: 100%;
      height: 100%;
      border-radius: 50%;
      overflow: hidden;
      border: 2px solid var(--border-accent);
      background: var(--bg-surface);
      display: flex;
      align-items: center;
      justify-content: center;
      box-shadow: 0 0 0 4px rgba(108,63,255,0.15), 0 0 40px rgba(108,63,255,0.2);
    }
    .profile-img-wrap img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      object-position: center center;
      display: block;
      flex-shrink: 0;
    }

    /* ── Orbiting stars ── */
    /* ── Two dotted orbital rings ── */
    .spin-ring { position: absolute; border-radius: 50%; pointer-events: none; }

    /* Ring 1 — purple, clockwise */
    .spin-ring-1 {
      inset: -14px;
      border: 1.5px dashed rgba(108,63,255,0.45);
      animation: spin 18s linear infinite;
    }
    /* Ring 2 — teal, counter-clockwise */
    .spin-ring-2 {
      inset: -28px;
      border: 1.5px dashed rgba(0,180,216,0.35);
      animation: spin 26s linear infinite reverse;
    }

    /* ── Orbiting stars — ride exactly on their ring ── */
    .orbit-star {
      position: absolute;
      border-radius: 50%;
      pointer-events: none;
    }

    /* Star 1 — purple glow, clockwise, same inset as ring 1 */
    .orbit-star-1 {
      inset: -14px;
      animation: orbit-cw 7s linear infinite;
    }
    .orbit-star-1::before {
      content: '';
      position: absolute;
      width: 11px;
      height: 11px;
      top: -5.5px;
      left: 50%;
      transform: translateX(-50%);
      border-radius: 50%;
      background: #fff;
      box-shadow:
        0 0 4px 1px #fff,
        0 0 10px 3px var(--purple),
        0 0 22px 6px rgba(108,63,255,0.55),
        0 0 40px 10px rgba(108,63,255,0.2);
    }

    /* Star 2 — teal glow, counter-clockwise, same inset as ring 2 */
    .orbit-star-2 {
      inset: -28px;
      animation: orbit-ccw 11s linear infinite;
    }
    .orbit-star-2::before {
      content: '';
      position: absolute;
      width: 9px;
      height: 9px;
      top: -4.5px;
      left: 50%;
      transform: translateX(-50%);
      border-radius: 50%;
      background: #fff;
      box-shadow:
        0 0 4px 1px #fff,
        0 0 10px 3px var(--teal),
        0 0 20px 6px rgba(0,180,216,0.55),
        0 0 36px 10px rgba(0,180,216,0.2);
    }

    @keyframes orbit-cw  { from { transform: rotate(0deg); }   to { transform: rotate(360deg); } }
    @keyframes orbit-ccw { from { transform: rotate(0deg); }   to { transform: rotate(-360deg); } }

    .profile-placeholder {
      width: 100%;
      height: 100%;
      background: linear-gradient(135deg, var(--bg-elevated) 0%, var(--bg-surface) 100%);
      display: none; /* hidden by default; shown via onerror */
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: 0.5rem;
    }
    .profile-placeholder i {
      font-size: 4rem;
      color: var(--purple);
      opacity: 0.6;
    }
    .profile-placeholder span {
      font-size: 0.7rem;
      color: var(--text-dim);
      font-family: var(--mono);
    }

    /* Floating tags around profile */
    .float-tag {
      position: absolute;
      padding: 0.4rem 0.75rem;
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: 999px;
      font-size: 0.75rem;
      font-weight: 600;
      color: var(--text);
      white-space: nowrap;
      animation: float 4s ease-in-out infinite;
    }
    .float-tag.t1, .float-tag.tag-tr { top: 5%; right: -15%; animation-delay: 0s; border-color: rgba(108,63,255,0.3); color: var(--purple-glow); }
    .float-tag.t2, .float-tag.tag-br { bottom: 15%; right: -20%; animation-delay: 1s; border-color: rgba(0,180,216,0.3); color: var(--teal); }
    .float-tag.t3, .float-tag.tag-tl { top: 30%; left: -25%; animation-delay: 2s; }
    .float-tag.t4, .float-tag.tag-bl { bottom: 5%; left: -10%; animation-delay: 0.5s; border-color: rgba(74,222,128,0.3); color: var(--green); }

    @keyframes float {
      0%, 100% { transform: translateY(0); }
      50% { transform: translateY(-8px); }
    }

    /* ============================================================
       ABOUT
    ============================================================ */
    .about-grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 4rem;
      align-items: start;
    }

    .about-text p {
      color: var(--text-muted);
      margin-bottom: 1.25rem;
      font-size: 1.025rem;
      line-height: 1.8;
    }

    .about-text p strong { color: var(--text); }

    .about-cards {
      display: flex;
      flex-direction: column;
      gap: 1rem;
    }

    .about-card {
      display: flex;
      align-items: center;
      gap: 1rem;
      padding: 1.25rem 1.5rem;
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: 0.875rem;
      transition: border-color var(--mid), transform var(--mid);
    }
    .about-card:hover {
      border-color: var(--border-accent);
      transform: translateX(4px);
    }
    .about-card-icon {
      width: 2.5rem;
      height: 2.5rem;
      border-radius: 0.625rem;
      background: var(--purple-dim);
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--purple-glow);
      font-size: 1rem;
      flex-shrink: 0;
    }
    .about-card h4 { font-size: 0.875rem; font-weight: 600; margin-bottom: 0.2rem; }
    .about-card p { font-size: 0.85rem; color: var(--text-muted); margin: 0; }

    /* ============================================================
       PROJECTS
    ============================================================ */
    .projects-tabs {
      display: flex;
      gap: 0.5rem;
      margin-bottom: 2.5rem;
      flex-wrap: wrap;
    }
    .projects-tab {
      padding: 0.45rem 1rem;
      border-radius: 999px;
      font-size: 0.8rem;
      font-weight: 600;
      color: var(--text-muted);
      background: var(--bg-surface);
      border: 1px solid var(--border);
      cursor: pointer;
      transition: all var(--fast);
    }
    .projects-tab.active, .projects-tab:hover {
      color: var(--text);
      border-color: var(--purple);
      background: var(--purple-dim);
    }

    .projects-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
      gap: 1.25rem;
    }

    .project-card {
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: 1rem;
      padding: 1.75rem;
      transition: all var(--mid) var(--ease);
      display: flex;
      flex-direction: column;
      position: relative;
      overflow: hidden;
    }

    .project-card::before {
      content: '';
      position: absolute;
      top: 0; left: 0; right: 0;
      height: 1px;
      background: linear-gradient(90deg, transparent, var(--purple), transparent);
      opacity: 0;
      transition: opacity var(--mid);
    }

    .project-card:hover {
      border-color: var(--border-accent);
      transform: translateY(-4px);
      box-shadow: 0 20px 60px rgba(108,63,255,0.12);
    }
    .project-card:hover::before { opacity: 1; }

    .project-card-header {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      margin-bottom: 1rem;
    }

    .project-icon {
      width: 2.75rem;
      height: 2.75rem;
      border-radius: 0.75rem;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 1.2rem;
      flex-shrink: 0;
    }
    .project-icon.ml   { background: rgba(108,63,255,0.15); color: var(--purple-glow); }
    .project-icon.ai   { background: rgba(0,180,216,0.12);  color: var(--teal); }
    .project-icon.agri { background: rgba(74,222,128,0.12); color: var(--green); }
    .project-icon.web  { background: rgba(251,191,36,0.12); color: var(--amber); }

    .project-badge {
      padding: 0.25rem 0.625rem;
      border-radius: 999px;
      font-size: 0.7rem;
      font-weight: 700;
      letter-spacing: 0.04em;
      text-transform: uppercase;
    }
    .badge-live  { background: rgba(74,222,128,0.12); color: var(--green); border: 1px solid rgba(74,222,128,0.25); }
    .badge-kaggle { background: rgba(0,180,216,0.1); color: var(--teal); border: 1px solid rgba(0,180,216,0.2); }
    .badge-active { background: rgba(251,191,36,0.1); color: var(--amber); border: 1px solid rgba(251,191,36,0.2); }
    .badge-zaio  { background: var(--purple-dim); color: var(--purple-glow); border: 1px solid var(--border-accent); }

    .project-title {
      font-size: 1.05rem;
      font-weight: 700;
      margin-bottom: 0.6rem;
      color: var(--text);
    }

    .project-desc {
      font-size: 0.875rem;
      color: var(--text-muted);
      line-height: 1.7;
      margin-bottom: 1.25rem;
      flex: 1;
    }

    .project-metric {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      padding: 0.3rem 0.625rem;
      background: var(--bg-elevated);
      border-radius: 0.375rem;
      font-size: 0.75rem;
      font-weight: 600;
      color: var(--text-muted);
      margin-bottom: 1rem;
      font-family: var(--mono);
    }
    .project-metric i { color: var(--purple); font-size: 0.65rem; }

    .project-tags {
      display: flex;
      flex-wrap: wrap;
      gap: 0.4rem;
      margin-bottom: 1.25rem;
    }
    .tag {
      padding: 0.2rem 0.55rem;
      background: var(--bg-elevated);
      border-radius: 0.375rem;
      font-size: 0.7rem;
      font-weight: 600;
      color: var(--text-muted);
      border: 1px solid var(--border);
      font-family: var(--mono);
    }

    .project-links {
      display: flex;
      gap: 0.75rem;
      margin-top: auto;
    }
    .project-link {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      font-size: 0.8rem;
      font-weight: 600;
      color: var(--text-muted);
      transition: color var(--fast);
    }
    .project-link:hover { color: var(--purple-glow); }
    .project-link i { font-size: 0.75rem; }

    /* ============================================================
       SKILLS
    ============================================================ */
    .skills-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
      gap: 1.25rem;
    }

    .skills-card,
    .skill-card {
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: 1rem;
      padding: 1.5rem;
      transition: border-color var(--mid);
    }
    .skills-card:hover,
    .skill-card:hover { border-color: var(--border-accent); }

    /* Header used by the live skills markup: icon + label on one line */
    .skill-card-header {
      display: flex;
      align-items: center;
      gap: 0.6rem;
      font-size: 0.875rem;
      font-weight: 700;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      color: var(--text-muted);
      margin-bottom: 1.25rem;
    }
    .skill-card-header i { color: var(--purple-glow); }

    .skills-card-header {
      display: flex;
      align-items: center;
      gap: 0.75rem;
      margin-bottom: 1.25rem;
    }
    .skills-card-icon {
      width: 2.25rem;
      height: 2.25rem;
      border-radius: 0.625rem;
      background: var(--purple-dim);
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--purple-glow);
      font-size: 0.875rem;
    }
    .skills-card-title {
      font-size: 0.875rem;
      font-weight: 700;
      letter-spacing: 0.04em;
      text-transform: uppercase;
      color: var(--text-muted);
    }

    /* Skill bars */
    .skill-bar-item { margin-bottom: 1rem; }
    .skill-bar-item:last-child { margin-bottom: 0; }
    .skill-bar-top {
      display: flex;
      justify-content: space-between;
      align-items: center;
      margin-bottom: 0.4rem;
    }
    .skill-bar-name { font-size: 0.875rem; font-weight: 500; color: var(--text); }
    .skill-bar-level { font-size: 0.75rem; color: var(--text-dim); font-family: var(--mono); }
    .skill-bar-track {
      height: 4px;
      background: var(--bg-elevated);
      border-radius: 2px;
      overflow: hidden;
    }
    .skill-bar-fill {
      height: 100%;
      border-radius: 2px;
      background: linear-gradient(90deg, var(--purple), var(--teal));
      transform: scaleX(0);
      transform-origin: left;
      transition: transform 1s var(--ease) 0.2s;
    }
    .skill-bar-fill.animated { transform: scaleX(1); }

    /* Skill chips */
    .skill-chips {
      display: flex;
      flex-wrap: wrap;
      gap: 0.5rem;
    }
    .skill-chip {
      padding: 0.3rem 0.7rem;
      background: var(--bg-elevated);
      border: 1px solid var(--border);
      border-radius: 999px;
      font-size: 0.775rem;
      font-weight: 500;
      color: var(--text-muted);
      transition: all var(--fast);
      font-family: var(--mono);
    }
    .skill-chip:hover {
      color: var(--text);
      border-color: var(--purple);
      background: var(--purple-dim);
    }

    /* ============================================================
       WEBDEV / BUILDER TEASER
    ============================================================ */
    .webdev-banner {
      background: linear-gradient(135deg, var(--bg-surface) 0%, rgba(108,63,255,0.06) 100%);
      border: 1px solid var(--border-accent);
      border-radius: 1.25rem;
      padding: 3rem;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 2rem;
      flex-wrap: wrap;
      position: relative;
      overflow: hidden;
    }
    .webdev-banner::after {
      content: '';
      position: absolute;
      right: -5%;
      top: -30%;
      width: 400px;
      height: 400px;
      background: radial-gradient(circle, rgba(108,63,255,0.08) 0%, transparent 70%);
      pointer-events: none;
    }

    .webdev-content { flex: 1; min-width: min(260px, 100%); }
    .webdev-content h3 {
      font-size: 1.5rem;
      font-weight: 800;
      margin-bottom: 0.75rem;
    }
    .webdev-content p {
      color: var(--text-muted);
      font-size: 0.95rem;
      line-height: 1.75;
      max-width: 480px;
    }

    .webdev-features {
      display: flex;
      flex-wrap: wrap;
      gap: 0.5rem;
      margin-top: 1.25rem;
    }
    .webdev-feature {
      display: flex;
      align-items: center;
      gap: 0.4rem;
      font-size: 0.8rem;
      color: var(--text-muted);
    }
    .webdev-feature i { color: var(--green); font-size: 0.65rem; }

    /* ============================================================
       CONTACT
    ============================================================ */
    .contact-grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 3rem;
      align-items: start;
    }

    .contact-info h3 {
      font-size: 1.75rem;
      font-weight: 800;
      margin-bottom: 1rem;
    }
    .contact-info p {
      color: var(--text-muted);
      margin-bottom: 2rem;
      line-height: 1.75;
    }

    .contact-items {
      display: flex;
      flex-direction: column;
      gap: 1rem;
    }
    .contact-item {
      display: flex;
      align-items: center;
      gap: 1rem;
      padding: 1rem 1.25rem;
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: 0.75rem;
      transition: border-color var(--mid);
    }
    .contact-item:hover { border-color: var(--border-accent); }
    .contact-item-icon {
      width: 2.25rem;
      height: 2.25rem;
      border-radius: 0.625rem;
      background: var(--purple-dim);
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--purple-glow);
      font-size: 0.875rem;
      flex-shrink: 0;
    }
    .contact-item-text { font-size: 0.875rem; }
    .contact-item-label { font-weight: 600; color: var(--text); display: block; margin-bottom: 0.15rem; }
    .contact-item-val { color: var(--text-muted); font-family: var(--mono); font-size: 0.8rem; }

    /* Form */
    .contact-form {
      display: flex;
      flex-direction: column;
      gap: 1rem;
    }
    .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
    .form-group { display: flex; flex-direction: column; gap: 0.4rem; }
    .form-group label { font-size: 0.8rem; font-weight: 600; color: var(--text-muted); }
    .form-group input,
    .form-group textarea,
    .form-group select {
      background: var(--bg-surface);
      border: 1px solid var(--border);
      border-radius: 0.625rem;
      padding: 0.75rem 1rem;
      color: var(--text);
      font-family: var(--font);
      font-size: 0.875rem;
      transition: border-color var(--fast);
      outline: none;
      resize: vertical;
    }
    .form-group input:focus,
    .form-group textarea:focus,
    .form-group select:focus {
      border-color: var(--purple);
    }
    .form-group textarea { min-height: 110px; }
    .form-group select option { background: var(--bg-surface); }

    /* ============================================================
       FOOTER
    ============================================================ */
    footer {
      border-top: 1px solid var(--border);
      padding: 2.5rem 0;
      margin-top: 2rem;
    }
    .footer-inner {
      display: flex;
      align-items: center;
      justify-content: space-between;
      flex-wrap: wrap;
      gap: 1rem;
    }
    .footer-logo {
      font-family: var(--mono);
      font-weight: 700;
      font-size: 0.9rem;
    }
    .footer-logo span { color: var(--purple); }
    footer p { font-size: 0.8rem; color: var(--text-dim); }
    .footer-links {
      display: flex;
      gap: 1.5rem;
    }
    .footer-links a {
      font-size: 0.8rem;
      color: var(--text-muted);
      transition: color var(--fast);
    }
    .footer-links a:hover { color: var(--purple-glow); }

    /* ============================================================
       SCROLL REVEAL
    ============================================================ */
    .reveal {
      opacity: 0;
      transform: translateY(24px);
      transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
    }
    .reveal.revealed {
      opacity: 1;
      transform: translateY(0);
    }
    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }

    /* ============================================================
       RESPONSIVE
    ============================================================ */
    @media (max-width: 768px) {
      .hero-inner,
      .hero-grid,
      .about-grid,
      .contact-grid { grid-template-columns: 1fr; }
      .form-row { grid-template-columns: 1fr; }
      .nav-links { display: none; }
      .nav-wrap { width: calc(100% - 2rem); }
      .projects-grid { grid-template-columns: 1fr; }
      .skills-grid { grid-template-columns: 1fr; }

      /* Mobile profile picture — centered, with compact floating tags */
      .hero-visual { display: flex; justify-content: center; margin: 1.5rem 0 0.75rem; order: -1; }
      .hero-grid { display: flex; flex-direction: column; }
      .hero-text { order: 1; }
      .profile-ring { width: 170px; height: 170px; }
      .profile-card { width: 170px; height: 170px; }

      /* Floating tags — desktop feature, compact mobile placement */
      .hero-visual .float-tag {
        display: inline-flex;
        font-size: 0.65rem;
        padding: 0.28rem 0.6rem;
      }
      .float-tag.t3, .float-tag.tag-tl { top: 10%;    left: -26%;  }
      .float-tag.t1, .float-tag.tag-tr { top: -6%;    right: -22%; }
      .float-tag.t4, .float-tag.tag-bl { bottom: 0%;  left: -18%;  }
      .float-tag.t2, .float-tag.tag-br { bottom: 16%; right: -26%; }
    }

    /* ── Hamburger button (mobile only) ── */
    .nav-hamburger {
      display: none;
      flex-direction: column;
      justify-content: center;
      gap: 5px;
      width: 36px;
      height: 36px;
      background: transparent;
      border: none;
      cursor: pointer;
      padding: 4px;
    }
    .nav-hamburger span {
      display: block;
      height: 2px;
      width: 100%;
      background: var(--text-muted);
      border-radius: 2px;
      transition: all 0.25s var(--ease);
    }
    .nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .nav-hamburger.open span:nth-child(2) { opacity: 0; }
    .nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    @media (max-width: 768px) {
      .nav-hamburger { display: flex; }
    }

    /* ── Mobile nav dropdown ── */
    .mobile-menu {
      position: fixed;
      top: 4.5rem;
      left: 1rem;
      right: 1rem;
      background: rgba(10, 10, 15, 0.97);
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      border: 1px solid var(--border);
      border-radius: 16px;
      z-index: 1001;
      padding: 0.5rem 0;
      flex-direction: column;
      opacity: 0;
      transform: translateY(-8px);
      pointer-events: none;
      transition: opacity 0.2s var(--ease), transform 0.2s var(--ease);
      display: flex;
    }
    .mobile-menu.open { opacity: 1; transform: translateY(0); pointer-events: auto; }
    .mobile-menu a {
      display: block;
      margin: 0.3rem 0.9rem;
      padding: 0.8rem 1.4rem;
      font-size: 1rem;
      font-weight: 500;
      color: var(--text-muted);
      text-decoration: none;
      border-radius: 999px;
      transition: color 0.2s, background 0.2s;
    }
    .mobile-menu a:first-child { margin-top: 0.6rem; }
    .mobile-menu a:hover { color: var(--text); background: rgba(255,255,255,0.03); }

    /* Active-section indicator — mobile parity with the desktop nav's glowing pill + teal dot */
    .mobile-menu a.active {
      color: #fff;
      background: var(--purple-dim);
    }
    .mobile-menu a.active:not(.nav-cta)::after {
      content: '';
      display: inline-block;
      width: 5px;
      height: 5px;
      margin-left: 0.6rem;
      border-radius: 50%;
      background: var(--teal);
      box-shadow: 0 0 8px var(--teal);
      vertical-align: middle;
    }
    /* Where supported, the dot orbits the active row — same motion as desktop */
    @supports (offset-path: border-box) {
      .mobile-menu a { position: relative; }
      .mobile-menu a.active:not(.nav-cta)::after {
        position: absolute;
        margin-left: 0;
        offset-path: border-box;
        offset-distance: 0%;
        animation: orbit-pill 3.2s linear infinite;
      }
    }

    /* Contact CTA — proper inset pill, not a full-width slab */
    .mobile-menu a.nav-cta {
      margin: 0.6rem 1.25rem 0.85rem;
      padding: 0.7rem 1rem;
      border-radius: 999px;
      background: var(--purple);
      color: var(--text) !important;
      text-align: center;
      font-weight: 600;
      border-bottom: none;
    }
    .mobile-menu a.nav-cta:hover,
    .mobile-menu a.nav-cta.active { background: var(--purple-glow); }

    /* The dropdown belongs to mobile only — never leak into desktop widths
       (it kept its open state when rotating / resizing past the breakpoint) */
    @media (min-width: 769px) {
      .mobile-menu { display: none !important; }
    }

    /* ============================================================
       DIVIDER
    ============================================================ */
    .divider {
      height: 1px;
      background: linear-gradient(90deg, transparent, var(--border), transparent);
      margin: 0;
    }
/* ── CMS SUPPLEMENT ── */
.section-sub { color: var(--text-muted); margin-bottom: 2.5rem; font-size: 1.05rem; }
.btn-text { color: var(--text-muted); text-decoration: none; font-size: 0.95rem; display: inline-flex; align-items: center; gap: 6px; transition: color .2s; margin-top: 1rem; }
.btn-text:hover { color: var(--text); }
.about-cta { margin-top: 1.25rem; }
.about-cta i { font-size: 0.8em; transition: transform var(--fast) var(--ease); }
.about-cta:hover i { transform: translateX(3px); }
.btn-full { width: 100%; justify-content: center; }

/* Hero extras */
.hero-location { display: inline-flex; align-items: center; gap: 6px; color: var(--text-muted); font-size: 0.85rem; background: var(--bg-elevated); padding: 6px 14px; border-radius: 999px; margin-bottom: 1.2rem; border: 1px solid rgba(255,255,255,.07); }
.hero-name { font-size: clamp(2.8rem,7vw,5.5rem); font-weight: 900; line-height: 1.05; margin-bottom: 1rem; }
.hero-name span { color: var(--purple); }
.hero-roles { display: flex; align-items: center; gap: 10px; margin-bottom: 1.2rem; flex-wrap: wrap; }
.role-plain { font-size: 1.1rem; color: var(--text-muted); font-weight: 500; }
.role-pill { background: rgba(108,63,255,.18); color: var(--purple-glow); border: 1px solid rgba(108,63,255,.35); padding: 4px 14px; border-radius: 999px; font-size: 0.95rem; font-weight: 600; }
.hero-bio { color: var(--text-muted); line-height: 1.75; font-size: 1rem; max-width: 500px; margin-bottom: 1.8rem; }
.social-icon { width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--bg-elevated); color: var(--text-muted); border: 1px solid rgba(255,255,255,.08); transition: all .2s; font-size: 0.95rem; }
.social-icon:hover { color: var(--purple-glow); border-color: var(--purple); background: var(--purple-dim); }
/* spin-ring styles moved to hero section above */
@keyframes spin { to { transform: rotate(360deg); } }

/* About layout */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.about-cards { padding-top: 3.5rem; }
@media (max-width: 768px) { .about-grid { grid-template-columns: 1fr; } }
.about-text p { color: var(--text-muted); line-height: 1.8; margin-bottom: 1rem; }
.about-cards { display: flex; flex-direction: column; gap: 1rem; }
.info-card { display: flex; align-items: center; gap: 1rem; background: var(--bg-surface); border: 1px solid rgba(255,255,255,.06); border-radius: 12px; padding: 1rem 1.25rem; }
.info-icon { width: 38px; height: 38px; min-width: 38px; background: var(--purple-dim); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: var(--purple-glow); font-size: 1rem; }
.info-card strong { display: block; font-size: 0.85rem; font-weight: 600; color: var(--text); margin-bottom: 2px; }
.info-card span, .info-card a { font-size: 0.82rem; color: var(--text-muted); text-decoration: none; }

/* Filter tabs */
.filter-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 2rem; }
.filter-btn { padding: 7px 18px; border-radius: 999px; border: 1px solid rgba(255,255,255,.1); background: transparent; color: var(--text-muted); font-size: 0.88rem; cursor: pointer; transition: all .2s; font-family: var(--font); }
.filter-btn.active, .filter-btn:hover { background: var(--purple-dim); color: var(--purple-glow); border-color: var(--purple); }
.filter-show { border-color: rgba(108,63,255,.3) !important; transform: translateY(-4px); box-shadow: 0 20px 60px rgba(108,63,255,0.12); transition: border-color .25s, transform .25s, box-shadow .25s; }
.filter-show::before { opacity: 1 !important; }

/* Project cards */
.projects-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 1.25rem; }
.project-card { background: var(--bg-surface); border: 1px solid rgba(255,255,255,.06); border-radius: 16px; padding: 1.5rem; display: flex; flex-direction: column; gap: 0.75rem; transition: border-color .25s, transform .25s; }
.project-card:hover { border-color: rgba(108,63,255,.3); transform: translateY(-4px); }
.project-header { display: flex; align-items: center; justify-content: space-between; }
.project-icon { width: 42px; height: 42px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; }
.icon-ai { background: rgba(108,63,255,.18); color: var(--purple-glow); }
.icon-ml { background: rgba(0,180,216,.14); color: var(--teal); }
.icon-web { background: rgba(74,222,128,.12); color: var(--green); }
.badge { font-size: 0.72rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; letter-spacing: .05em; }
.badge-ai { background: rgba(108,63,255,.18); color: var(--purple-glow); border: 1px solid rgba(108,63,255,.25); }
.badge-ml { background: rgba(0,180,216,.14); color: var(--teal); border: 1px solid rgba(0,180,216,.2); }
.badge-web { background: rgba(74,222,128,.12); color: var(--green); border: 1px solid rgba(74,222,128,.2); }
.project-tech-row { font-family: var(--mono); font-size: 0.78rem; color: var(--text-dim); display: flex; align-items: center; gap: 8px; }
.tech-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot-ai { background: var(--purple); }
.dot-ml { background: var(--teal); }
.dot-web { background: var(--green); }
.project-links { display: flex; gap: 10px; margin-top: auto; }
.project-link { display: inline-flex; align-items: center; gap: 6px; font-size: 0.82rem; color: var(--text-muted); text-decoration: none; transition: color .2s; }
.project-link:hover { color: var(--purple-glow); }

/* Skills grid extras */
.skill-bar-row { display: flex; justify-content: space-between; align-items: center; font-size: 0.88rem; color: var(--text-muted); margin-bottom: 6px; }
.skill-pct { font-family: var(--mono); font-size: 0.78rem; color: var(--text-dim); transition: color 0.4s; }

.skill-bar-track {
  width: 100%;
  height: 5px;
  background: rgba(255,255,255,.05);
  border-radius: 99px;
  margin-bottom: 14px;
  overflow: hidden;
  position: relative;
}

/* Bar starts at 0; transitions to var(--w) once .animated is added */
.skill-bar-fill {
  height: 100%;
  width: 0;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--purple) 0%, var(--purple-glow) 50%, var(--teal) 100%);
  background-size: 200% 100%;
  position: relative;
  overflow: hidden;
  transition: none;
  box-shadow: none;
}

/* Shimmer overlay inside the bar */
.skill-bar-fill::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(255,255,255,0.55) 45%,
    rgba(255,255,255,0.85) 50%,
    rgba(255,255,255,0.55) 55%,
    transparent 100%
  );
  transform: translateX(-200%);
  border-radius: inherit;
}

/* When triggered: animate width to target, glow, shimmer sweeps through */
.skill-bar-fill.animated {
  width: var(--w, 0%);
  transition: width 2s cubic-bezier(0.4, 0, 0.15, 1), box-shadow 0.4s ease 1s;
  box-shadow: 0 0 8px rgba(108,63,255,0.9), 0 0 18px rgba(108,63,255,0.5), 0 0 32px rgba(0,180,216,0.3);
  animation: bar-bg-shift 2.2s ease forwards;
}
.skill-bar-fill.animated::before {
  animation: bar-shimmer 2s ease 0.2s forwards;
}
.skill-bar-fill.animated + .skill-bar-fill + .skill-pct,
.skill-pct.lit { color: var(--teal); }

@keyframes bar-shimmer {
  0%   { transform: translateX(-200%); }
  100% { transform: translateX(300%); }
}
@keyframes bar-bg-shift {
  0%   { background-position: 100% 0; filter: brightness(1.6); }
  60%  { filter: brightness(1.3); }
  100% { background-position: 0% 0;   filter: brightness(1); }
}

/* Chip entrance animation */
.chip.chip-visible {
  animation: chip-pop 0.45s cubic-bezier(0.34,1.56,0.64,1) both;
}
@keyframes chip-pop {
  from { opacity: 0; transform: scale(0.7) translateY(6px); }
  to   { opacity: 1; transform: scale(1)   translateY(0); }
}
.chip-wrap { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.chip { padding: 5px 12px; border-radius: 999px; background: var(--bg-elevated); border: 1px solid rgba(255,255,255,.08); font-size: 0.8rem; color: var(--text-muted); font-family: var(--mono); }
.chip-ai { background: var(--purple-dim); color: var(--purple-glow); border-color: rgba(108,63,255,.25); }

/* Web Dev Banner */
.webdev-banner { background: linear-gradient(135deg, rgba(108,63,255,.08), rgba(0,180,216,.06)); border-top: 1px solid rgba(255,255,255,.05); border-bottom: 1px solid rgba(255,255,255,.05); padding: 5rem 0; }
.webdev-inner { max-width: 760px; }
.webdev-copy h2 { font-size: 2.2rem; font-weight: 800; margin-bottom: 0.75rem; }
.webdev-copy p { color: var(--text-muted); line-height: 1.75; margin-bottom: 1.5rem; }
.webdev-features { list-style: none; display: flex; flex-direction: column; gap: 8px; margin-bottom: 2rem; }
.webdev-features li { display: flex; align-items: center; gap: 10px; font-size: 0.92rem; color: var(--text-muted); }
.webdev-features li i { color: var(--green); font-size: 0.85rem; }
.webdev-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: stretch; }
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-cards { display: flex; flex-direction: column; gap: 0.75rem; }
.contact-card-item { display: flex; align-items: center; gap: 1rem; background: var(--bg-surface); border: 1px solid rgba(255,255,255,.06); border-radius: 12px; padding: 1rem 1.25rem; }
.contact-card-icon { width: 38px; height: 38px; min-width: 38px; background: var(--purple-dim); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: var(--purple-glow); font-size: 1rem; }
.contact-card-item strong { display: block; font-size: 0.83rem; font-weight: 600; color: var(--text); margin-bottom: 2px; }
.contact-card-item span, .contact-card-item a { font-size: 0.82rem; color: var(--text-muted); text-decoration: none; font-family: var(--mono); word-break: break-all; }
.contact-card-item a:hover { color: var(--purple-glow); }
.contact-form { margin-top: -1.5rem; display: flex; flex-direction: column; }
.contact-form .form-group:has(textarea) { flex: 1; display: flex; flex-direction: column; }
.contact-form .form-group:has(textarea) textarea { flex: 1; min-height: 80px; }
@media (max-width: 768px) { .contact-form { margin-top: 0; } }
.contact-left { display: flex; flex-direction: column; }
.contact-cards { flex: 1; display: flex; flex-direction: column; }
.contact-cards .contact-card-item { flex: 1; }
.contact-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 768px) { .contact-form .form-row { grid-template-columns: 1fr; } }
.contact-form .form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 1rem; }
.contact-form label { font-size: 0.82rem; color: var(--text-muted); font-weight: 500; }
.contact-form input, .contact-form textarea, .contact-form select { width: 100%; background: var(--bg-elevated); border: 1px solid rgba(255,255,255,.08); border-radius: 10px; padding: 12px 14px; color: var(--text); font-size: 0.92rem; font-family: var(--font); outline: none; transition: border-color .2s; resize: none; }
.contact-form input:focus, .contact-form textarea:focus, .contact-form select:focus { border-color: var(--purple); }
.contact-form select option { background: var(--bg-elevated); color: var(--text); }

/* Footer */
.footer { border-top: 1px solid rgba(255,255,255,.06); padding: 2.5rem 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1.5rem; }
.footer-brand .nav-logo { display: block; margin-bottom: 4px; }
.footer-brand p { font-size: 0.8rem; color: var(--text-dim); }
.footer-nav { display: flex; gap: 1.5rem; }
.footer-nav a { font-size: 0.85rem; color: var(--text-muted); text-decoration: none; transition: color .2s; }
.footer-nav a:hover { color: var(--text); }
.footer-copy { font-size: 0.8rem; color: var(--text-dim); }

/* ============================================================
   PRELOADER — BLACK PANTHER EDITION
============================================================ */
#preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #020205;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: opacity 0.7s cubic-bezier(0.4,0,0.2,1), visibility 0.7s;
}
#preloader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.5s cubic-bezier(0.4,0,0.2,1), visibility 0s 0.5s;
}

/* ── Hexagonal vibranium grid background ── */
.pre-hex-bg {
  position: absolute;
  inset: -20%;
  background-image:
    repeating-linear-gradient(
      60deg,
      transparent,
      transparent 28px,
      rgba(108,63,255,0.06) 28px,
      rgba(108,63,255,0.06) 29px
    ),
    repeating-linear-gradient(
      120deg,
      transparent,
      transparent 28px,
      rgba(108,63,255,0.06) 28px,
      rgba(108,63,255,0.06) 29px
    ),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 28px,
      rgba(108,63,255,0.04) 28px,
      rgba(108,63,255,0.04) 29px
    );
  animation: pre-hex-drift 12s linear infinite;
  opacity: 0;
  animation: pre-hex-in 1s 0.3s forwards, pre-hex-drift 12s 0.3s linear infinite;
}
@keyframes pre-hex-in  { to { opacity: 1; } }
@keyframes pre-hex-drift {
  0%   { transform: translate(0, 0); }
  100% { transform: translate(30px, 30px); }
}

/* Central glow orb */
#preloader::before {
  content: '';
  position: absolute;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(108,63,255,0.22) 0%, rgba(0,180,216,0.08) 40%, transparent 70%);
  border-radius: 50%;
  animation: pre-orb-pulse 2.5s ease-in-out infinite;
}
@keyframes pre-orb-pulse {
  0%, 100% { transform: scale(1);   opacity: 0.8; }
  50%       { transform: scale(1.15); opacity: 1;   }
}

/* ── Claw slashes ── */
.pre-claws {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.pre-claw {
  position: absolute;
  top: 0; bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, transparent 0%, rgba(108,63,255,0.7) 40%, rgba(0,180,216,0.5) 60%, transparent 100%);
  transform-origin: center;
  opacity: 0;
}
.pre-claw-1 { left: calc(50% - 36px); transform: rotate(-8deg); animation: pre-claw-slash 0.4s 0.2s cubic-bezier(0.2,0,0,1) forwards; }
.pre-claw-2 { left: 50%;              transform: rotate(-5deg); animation: pre-claw-slash 0.4s 0.35s cubic-bezier(0.2,0,0,1) forwards; }
.pre-claw-3 { left: calc(50% + 36px); transform: rotate(-2deg); animation: pre-claw-slash 0.4s 0.5s cubic-bezier(0.2,0,0,1) forwards; }
@keyframes pre-claw-slash {
  0%   { opacity: 0; clip-path: inset(0 0 100% 0); }
  30%  { opacity: 1; }
  100% { opacity: 0.15; clip-path: inset(0 0 0% 0); }
}

/* ── Corner geometry (Wakanda-style angular brackets) ── */
.pre-corner {
  position: absolute;
  width: 56px;
  height: 56px;
  opacity: 0;
  animation: pre-corner-in 0.5s 0.6s forwards;
}
.pre-corner-tl { top: 2rem; left: 2rem; border-top: 2px solid rgba(108,63,255,0.6); border-left: 2px solid rgba(108,63,255,0.6); }
.pre-corner-br { bottom: 2rem; right: 2rem; border-bottom: 2px solid rgba(0,180,216,0.5); border-right: 2px solid rgba(0,180,216,0.5); }
@keyframes pre-corner-in {
  from { opacity: 0; transform: scale(0.7); }
  to   { opacity: 1; transform: scale(1); }
}

/* ── Main body ── */
.pre-body {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  text-align: center;
}

/* Logo */
.pre-logo {
  font-family: var(--font);
  font-size: 5rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -4px;
  color: #fff;
  opacity: 0;
  animation: pre-logo-drop 0.6s 0.25s cubic-bezier(0.2,0,0,1.2) forwards;
  text-shadow: 0 0 40px rgba(108,63,255,0.6), 0 0 80px rgba(108,63,255,0.3);
}
.pre-logo span { color: var(--purple); }
@keyframes pre-logo-drop {
  from { opacity: 0; transform: translateY(-24px) scale(0.9); }
  to   { opacity: 1; transform: translateY(0)     scale(1); }
}

/* Name */
.pre-name {
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.35em;
  color: rgba(255,255,255,0.35);
  text-transform: uppercase;
  opacity: 0;
  animation: pre-fade-up 0.5s 0.7s forwards;
}

/* Role cycling */
.pre-role-wrap {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--mono);
  font-size: 1rem;
  font-weight: 600;
  opacity: 0;
  animation: pre-fade-up 0.5s 0.9s forwards;
  min-height: 1.4em;
}
.pre-role-prefix { color: var(--purple); }
.pre-role {
  color: var(--teal);
  border-right: 2px solid var(--teal);
  padding-right: 3px;
  animation: pre-cursor-blink 0.8s step-end infinite;
}
@keyframes pre-cursor-blink {
  0%, 100% { border-color: var(--teal); }
  50%       { border-color: transparent; }
}

/* ── Vibranium energy bar ── */
.pre-energy-track {
  width: 260px;
  height: 4px;
  background: rgba(255,255,255,0.07);
  border-radius: 99px;
  overflow: visible;
  position: relative;
  margin-top: 0.4rem;
  opacity: 0;
  animation: pre-fade-up 0.5s 1s forwards;
}
.pre-energy-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--purple), #a855f7, var(--teal));
  border-radius: 99px;
  animation: pre-charge 3.2s 1.1s cubic-bezier(0.4,0,0.2,1) forwards;
  position: relative;
  box-shadow: 0 0 12px rgba(108,63,255,0.8), 0 0 24px rgba(0,180,216,0.4);
}
.pre-energy-spark {
  position: absolute;
  right: -1px;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 0 10px #fff, 0 0 20px var(--purple), 0 0 40px var(--teal);
  animation: pre-spark-pulse 0.4s ease-in-out infinite;
}
@keyframes pre-charge {
  0%   { width: 0%; }
  20%  { width: 25%; }
  50%  { width: 60%; }
  75%  { width: 82%; }
  100% { width: 100%; }
}
@keyframes pre-spark-pulse {
  0%, 100% { transform: translateY(-50%) scale(1);   opacity: 1; }
  50%       { transform: translateY(-50%) scale(1.6); opacity: 0.7; }
}

/* ── Tech stack pills ── */
.pre-tech-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 380px;
  margin-top: 0.3rem;
}
.pre-tech {
  padding: 0.25rem 0.65rem;
  border: 1px solid rgba(108,63,255,0.3);
  border-radius: 999px;
  font-size: 0.68rem;
  font-family: var(--mono);
  color: rgba(255,255,255,0.5);
  opacity: 0;
  transform: translateY(8px);
  background: rgba(108,63,255,0.07);
}
.pre-tech:nth-child(1) { animation: pre-pill-in 0.4s 1.3s forwards; }
.pre-tech:nth-child(2) { animation: pre-pill-in 0.4s 1.5s forwards; }
.pre-tech:nth-child(3) { animation: pre-pill-in 0.4s 1.7s forwards; }
.pre-tech:nth-child(4) { animation: pre-pill-in 0.4s 1.9s forwards; }
.pre-tech:nth-child(5) { animation: pre-pill-in 0.4s 2.1s forwards; }
@keyframes pre-pill-in {
  to { opacity: 1; transform: translateY(0); }
}

/* ── Status text ── */
.pre-status {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.25em;
  color: rgba(108,63,255,0.6);
  margin-top: 0.5rem;
  opacity: 0;
  animation: pre-fade-up 0.5s 2.2s forwards;
}

/* Shared fade-up */
@keyframes pre-fade-up {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Private repo indicator */
.project-link.private-repo {
  cursor: default;
  opacity: 0.55;
  font-size: 0.8rem;
  gap: 6px;
}
.project-link.private-repo:hover {
  color: inherit;
  opacity: 0.55;
}

/* ============================================================
   PHASE 1 FOUNDATIONS — view transitions & motion guardrails
============================================================ */

/* Cross-document view transitions: MPA pages crossfade like an app.
   Browsers without support silently fall back to instant navigation. */
@view-transition { navigation: auto; }

@media (prefers-reduced-motion: no-preference) {
  ::view-transition-old(root) { animation: vt-leave 200ms var(--ease) both; }
  ::view-transition-new(root) { animation: vt-enter 280ms var(--ease) both; }
}
@keyframes vt-leave { to   { opacity: 0; transform: translateY(6px); } }
@keyframes vt-enter { from { opacity: 0; transform: translateY(-6px); } }

/* Reduced motion: kill all decorative animation, keep content instantly visible */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  ::view-transition-old(root), ::view-transition-new(root) { animation: none !important; }
}

/* ============================================================
   PHASE 2 — HUD KIT (corner brackets · conic glow · grid · reactor)
============================================================ */

/* HUD motion rules: large layers (reactor, grid) animate via
   transform/opacity only. The @property gradient rotation below is
   permitted ONLY on button-sized elements — its per-frame style
   recalc is cheap when the painted region is tiny. Do not use it
   on anything bigger than a control. */
@property --hud-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}
@keyframes hud-rotate { to { --hud-angle: 360deg; } }

/* ── Ambient background grid — Tron floor, radially faded ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(108,63,255,0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(108,63,255,0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 95% 75% at 50% 0%, #000 0%, transparent 78%);
  mask-image: radial-gradient(ellipse 95% 75% at 50% 0%, #000 0%, transparent 78%);
}

/* ── HUD corner brackets — sit just outside cards, reveal on hover ── */
.project-card { position: relative; }
.project-card::after {
  content: '';
  position: absolute;
  inset: -7px;
  pointer-events: none;
  --bk: var(--teal);
  --bl: 16px;   /* bracket arm length */
  --bw: 1.5px;  /* bracket stroke */
  background-image:
    linear-gradient(var(--bk), var(--bk)), linear-gradient(var(--bk), var(--bk)),
    linear-gradient(var(--bk), var(--bk)), linear-gradient(var(--bk), var(--bk)),
    linear-gradient(var(--bk), var(--bk)), linear-gradient(var(--bk), var(--bk)),
    linear-gradient(var(--bk), var(--bk)), linear-gradient(var(--bk), var(--bk));
  background-repeat: no-repeat;
  background-size:
    var(--bl) var(--bw), var(--bw) var(--bl),
    var(--bl) var(--bw), var(--bw) var(--bl),
    var(--bl) var(--bw), var(--bw) var(--bl),
    var(--bl) var(--bw), var(--bw) var(--bl);
  background-position:
    top left, top left,
    top right, top right,
    bottom left, bottom left,
    bottom right, bottom right;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity var(--mid) var(--ease), transform var(--mid) var(--ease);
}
.project-card:hover::after,
.project-card:focus-within::after {
  opacity: 0.85;
  transform: scale(1);
}

/* ── Rotating conic border glow — for the primary CTA ── */
.hud-glow {
  position: relative;
  isolation: isolate;
}
.hud-glow::before {
  content: '';
  position: absolute;
  inset: -2px;
  z-index: -1;
  border-radius: inherit;
  background: conic-gradient(
    from var(--hud-angle),
    transparent 0%,
    var(--purple-glow) 10%,
    var(--teal) 20%,
    transparent 30%
  );
  animation: hud-rotate 2.4s linear infinite;
  filter: blur(4px);
  opacity: 0.85;
}

/* ── Arc reactor — sweep + tick ring around the profile ── */
.profile-ring::before {
  content: '';
  position: absolute;
  inset: -46px;
  border-radius: 50%;
  pointer-events: none;
  background: conic-gradient(from 0deg, rgba(0,180,216,0.30), transparent 20%);
  -webkit-mask: radial-gradient(closest-side, transparent 80%, #000 81%, #000 97%, transparent 98%);
  mask: radial-gradient(closest-side, transparent 80%, #000 81%, #000 97%, transparent 98%);
  animation: spin 3.6s linear infinite;
}
.profile-ring::after {
  content: '';
  position: absolute;
  inset: -38px;
  border-radius: 50%;
  pointer-events: none;
  background: repeating-conic-gradient(
    rgba(139,106,255,0.35) 0deg 1.4deg,
    transparent 1.4deg 12deg
  );
  -webkit-mask: radial-gradient(closest-side, transparent 88%, #000 89%, #000 96%, transparent 97%);
  mask: radial-gradient(closest-side, transparent 88%, #000 89%, #000 96%, transparent 97%);
}
@media (max-width: 768px) {
  .profile-ring::before { inset: -22px; }
  .profile-ring::after  { inset: -17px; }
}

/* ── Themed focus ring — HUD teal, visible and on-brand ── */
:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
}

/* ============================================================
   PHASE 3 — NEBULA · BENTO · SPOTLIGHT · GAUGES
============================================================ */

/* ── Nebula — drifting gas clouds behind the hero name ── */
.nebula {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.hero > .container { position: relative; z-index: 1; }
.neb {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  will-change: transform;
}
.neb-1 {
  width: 560px; height: 560px; left: -8%; top: 4%;
  background: radial-gradient(circle, rgba(108,63,255,0.45), transparent 65%);
  animation: neb-a 11s ease-in-out infinite alternate;
}
.neb-2 {
  width: 460px; height: 460px; left: 16%; top: 32%;
  background: radial-gradient(circle, rgba(0,180,216,0.30), transparent 65%);
  animation: neb-b 14s ease-in-out infinite alternate;
}
.neb-3 {
  width: 380px; height: 380px; left: 0%; top: 46%;
  background: radial-gradient(circle, rgba(190,80,255,0.34), transparent 65%);
  animation: neb-c 17s ease-in-out infinite alternate;
}
@keyframes neb-a { from { transform: none; opacity: 0.55; } to { transform: translate(120px, 60px)  scale(1.22); opacity: 1; } }
@keyframes neb-b { from { transform: none; opacity: 1; }    to { transform: translate(-90px, -60px) scale(0.82); opacity: 0.5; } }
@keyframes neb-c { from { transform: none; opacity: 0.6; }  to { transform: translate(70px, -90px)  scale(1.18); opacity: 1; } }

/* ── Project grid: three equal columns on desktop ── */
@media (min-width: 900px) {
  .projects-grid { grid-template-columns: repeat(3, 1fr); }
}
.featured-media {
  margin: -1.5rem -1.5rem 0.5rem;
  border-radius: 16px 16px 0 0;
  overflow: hidden;
  aspect-ratio: 2.6 / 1;
  border-bottom: 1px solid var(--border);
}
.featured-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform var(--slow) var(--ease);
}
.project-card.featured:hover .featured-media img { transform: scale(1.03); }

/* ── Cursor-tracked card spotlight (replaces the old cursor trail) ── */
.project-card {
  --mx: -400px;
  --my: -400px;
  background-image: radial-gradient(
    340px circle at var(--mx) var(--my),
    rgba(139,106,255,0.10),
    transparent 65%
  );
}

/* ── System diagnostics gauges ── */
@property --shown {
  syntax: '<number>';
  initial-value: 0;
  inherits: true;
}
.gauge-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(86px, 1fr));
  gap: 1.1rem 0.5rem;
  margin-top: 0.85rem;
}
.gauge {
  text-align: center;
  --shown: 0;
  transition: --shown 1.2s var(--ease);
}
.gauge.animated { --shown: var(--pct); }
.gauge-ring {
  width: 72px;
  height: 72px;
  margin: 0 auto;
  border-radius: 50%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: conic-gradient(var(--teal) calc(var(--shown) * 1%), var(--bg-elevated) 0);
}
.gauge-ring::before {
  content: '';
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  background: var(--bg-surface);
}
.gauge-val {
  position: relative;
  font-family: var(--mono);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
}
.gauge-val small { font-size: 0.65em; color: var(--text-muted); }
.gauge-name {
  margin-top: 0.5rem;
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.3;
}

/* ============================================================
   PHASE 4 — TERMINAL VOICE · NAV HOVER · MOTION
============================================================ */

/* ── Hero terminal line ── */
.hero-terminal {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--teal);
  margin: 0.35rem 0 1.1rem;
  min-height: 1.3em;
}
.term-prompt { color: var(--purple-glow); }
/* Mobile: long log lines wrap to two rows — reserve the space so the
   typewriter doesn't shove the layout up and down on every message */
@media (max-width: 768px) {
  .hero-terminal { font-size: 0.75rem; min-height: 2.8em; }
}
/* Narrow desktop/tablet: the hero column is slim enough that long
   messages still wrap — keep two lines reserved there too */
@media (min-width: 769px) and (max-width: 1024px) {
  .hero-terminal { min-height: 2.7em; }
}
.term-caret {
  display: inline-block;
  width: 0.55em;
  height: 1.05em;
  margin-left: 2px;
  vertical-align: text-bottom;
  background: var(--teal);
  animation: caret-blink 1.1s steps(2, start) infinite;
}
@keyframes caret-blink { to { visibility: hidden; } }

/* ── Nav hover — glow pill + teal indicator dot ── */
.nav-links a:not(.nav-cta) {
  position: relative;
  transition: color var(--fast), background var(--fast), text-shadow var(--mid) var(--ease);
}
.nav-links a:not(.nav-cta)::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 3px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 8px var(--teal);
  transform: translateX(-50%) scale(0);
  transition: transform var(--mid) var(--ease);
}
.nav-links a:not(.nav-cta):hover {
  color: #fff;
  background: var(--purple-dim);
  text-shadow: 0 0 14px rgba(139,106,255,0.9);
}
.nav-links a:not(.nav-cta):hover::after,
.nav-links a:not(.nav-cta).active::after {
  transform: translateX(-50%) scale(1);
}
.nav-links a:not(.nav-cta).active {
  color: #fff;
  background: var(--purple-dim);
}

/* ── Card media — image banner on any card that has artwork ──
     Two motion layers: a slow CSS Ken Burns drift runs ambiently
     (composited off the main thread), and script.js adds a
     pointer-tracked 3D tilt on the container while hovering. */
.card-media {
  margin: -1.5rem -1.5rem 0.5rem;
  border-radius: 16px 16px 0 0;
  overflow: hidden;
  aspect-ratio: 2.6 / 1;
  border-bottom: 1px solid var(--border);
  transform-style: preserve-3d;
  transition: transform 0.35s var(--ease);
}
.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  animation: media-drift 26s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes media-drift {
  0%   { transform: scale(1.06) translate(-1.2%, 0.8%); }
  50%  { transform: scale(1.14) translate(1.2%, -1%); }
  100% { transform: scale(1.06) translate(-0.6%, -1.2%); }
}
/* Stagger the drift so neighbouring cards breathe out of sync */
.project-card:nth-child(3n)   .card-media img { animation-delay: -9s; }
.project-card:nth-child(3n+2) .card-media img { animation-delay: -18s; }
/* Living-light overlay (card-art.js) sits on top of the painted banner */
.card-media, .featured-media { position: relative; }
.card-art-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* ── Nav hover, amplified ── */
.nav-links a:not(.nav-cta) {
  border: 1px solid transparent;
  transition: color var(--fast), background var(--fast), border-color var(--fast),
              box-shadow var(--mid) var(--ease), text-shadow var(--mid) var(--ease),
              transform var(--fast) var(--ease);
}
.nav-links a:not(.nav-cta):hover {
  color: #fff;
  background: var(--purple-dim);
  border-color: rgba(139,106,255,0.45);
  box-shadow: 0 0 18px rgba(108,63,255,0.35), inset 0 0 10px rgba(108,63,255,0.12);
  text-shadow: 0 0 14px rgba(139,106,255,0.95);
  transform: translateY(-1px);
}

/* ============================================================
   REFINEMENTS — role pill · nav speed · orbit dot · featured
   layout · gauge glow
============================================================ */

/* Role pill stays legible over the nebula */
.hero-roles .role-pill {
  position: relative;
  z-index: 1;
  background: rgba(10,10,15,0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--purple-glow);
  border: 1px solid rgba(139,106,255,0.55);
}

/* Nav: snappier response */
.nav-links a:not(.nav-cta) {
  transition: color 90ms, background 90ms, border-color 90ms,
              box-shadow 140ms var(--ease), text-shadow 140ms var(--ease),
              transform 90ms var(--ease);
}
.nav-links a:not(.nav-cta)::after {
  transition: transform 150ms var(--ease);
}

/* Active nav item: the teal dot orbits the pill */
@supports (offset-path: border-box) {
  .nav-links a:not(.nav-cta).active::after {
    left: auto;
    bottom: auto;
    transform: none;
    offset-path: border-box;
    offset-distance: 0%;
    animation: orbit-pill 3.2s linear infinite;
  }
}
@keyframes orbit-pill { to { offset-distance: 100%; } }

/* (featured magazine layout removed — all cards share equal space) */

/* Gauges: teal glow, breathing once armed */
.gauge-ring { transition: box-shadow 0.6s var(--ease); }
.gauge.animated .gauge-ring {
  animation: gauge-glow 2.6s ease-in-out 1.3s infinite alternate;
}
@keyframes gauge-glow {
  from { box-shadow: 0 0 10px rgba(0,180,216,0.22); }
  to   { box-shadow: 0 0 22px rgba(0,180,216,0.55); }
}

/* Filtering now actually filters — non-matching cards hide */
.project-card.filter-hide { display: none !important; }

/* Contact CTA joins the orbit club when its section is active */
.nav-cta { position: relative; }
.nav-cta::after {
  content: '';
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 9px var(--teal);
  opacity: 0;
}
@supports (offset-path: border-box) {
  .nav-cta.active::after {
    opacity: 1;
    offset-path: border-box;
    animation: orbit-pill 3.2s linear infinite;
  }
}

/* ── Back-to-top — fixed bottom-left on every long page.
     Left side on purpose: the template wizard's mood board owns
     the bottom-right corner, so the two can never collide. ── */
.back-to-top {
  position: fixed;
  bottom: 24px;
  left: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 1px solid var(--border-accent);
  color: var(--purple-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  z-index: 900;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease),
              box-shadow 0.25s var(--ease), border-color 0.25s var(--ease),
              color 0.25s var(--ease);
}
.back-to-top.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.back-to-top:hover {
  border-color: var(--purple);
  color: #fff;
  box-shadow: 0 0 18px rgba(108,63,255,0.4);
}
@media (max-width: 640px) {
  .back-to-top { bottom: 12px; left: 12px; width: 40px; height: 40px; font-size: 0.9rem; }
}

/* ── Card link buttons — proper buttons, proper hover ── */
.project-link {
  padding: 0.45rem 0.9rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-weight: 500;
  transition: color var(--fast), background var(--fast), border-color var(--fast),
              box-shadow var(--fast) var(--ease), transform var(--fast) var(--ease);
}
.project-link:hover {
  color: #fff;
  background: var(--purple-dim);
  border-color: rgba(139,106,255,0.5);
  box-shadow: 0 0 14px rgba(108,63,255,0.3);
  transform: translateY(-2px);
}
/* Private repos stay inert — a label, not a button */
.project-link.private-repo,
.project-link.private-repo:hover {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  transform: none;
  color: var(--text-dim);
}
