:root {
    --bg: #080D19;
    --surface: #111B2E;
    --surface-2: #18263D;
    --ink: #EEF3FF;
    --ink-muted: #A6B5CF;
    --line: #273752;
    --line-strong: #435979;
    --accent: #A0B5FF;
    --accent-soft: #1C2D50;
    --cyan: #82DCE6;
    --pass: #74DDA8;
    --pass-soft: #15352B;
    --fail: #FF9999;
    --fail-soft: #3A1C22;
    --pending: #435979;
    --shadow: rgba(0, 0, 0, .38);
    --glow: rgba(91, 128, 255, .12);
    color-scheme: dark;
  }

  * { box-sizing: border-box; }
  html { scroll-behavior: smooth; }
  body {
    position: relative;
    isolation: isolate;
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: 'Geist', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
  }
  body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
      radial-gradient(ellipse at 85% 8%, rgba(69, 103, 221, .18), transparent 55%),
      radial-gradient(ellipse at 6% 65%, rgba(40, 111, 134, .09), transparent 50%);
  }
  body::after {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 800px;
    z-index: -1;
    pointer-events: none;
    opacity: .18;
    background-image: linear-gradient(rgba(125, 156, 217, .2) 1px, transparent 1px), linear-gradient(90deg, rgba(125, 156, 217, .2) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: linear-gradient(to bottom, black, transparent);
  }
  p { margin: 0; }
  h1, h2, h3 { margin: 0; text-wrap: balance; letter-spacing: -.02em; }
  a { color: var(--accent); }
  .mono { font-family: 'Geist Mono', ui-monospace, 'Cascadia Mono', monospace; }
  :focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
  main:focus { outline: none; }

  .skip {
    position: absolute; left: 16px; top: -60px; z-index: 50;
    background: var(--accent); color: var(--surface);
    font-size: .88rem; font-weight: 500;
    padding: 10px 14px; border-radius: 6px; text-decoration: none;
    transition: top .15s ease;
  }
  .skip:focus { top: calc(12px + env(safe-area-inset-top, 0px)); }

  /* shell */
  .shell {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 80px;
    max-width: 1160px;
    margin: 0 auto;
    padding-inline: 32px;
  }

  /* rail */
  .rail {
    position: sticky;
    top: env(safe-area-inset-top, 0px);
    height: 100dvh;
    padding-block: 72px 36px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    overflow-y: auto;
    scrollbar-width: none;
  }
  .rail::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
  }
  .rail-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .rail h1 { font-size: 2.2rem; font-weight: 600; line-height: 1.15; letter-spacing: -.045em; }
  .rail h1 .ph { color: var(--ink-muted); font-weight: 500; }
  .rail .role { font-size: 1.05rem; font-weight: 500; margin-top: 10px; }
  .rail .pitch { color: var(--ink-muted); margin-top: 12px; font-size: .95rem; max-width: 34ch; }
  .ctas { display: flex; gap: 10px; flex-wrap: wrap; }
  .btn {
    font-size: .88rem; font-weight: 500;
    padding: 10px 16px; border-radius: 8px;
    text-decoration: none;
    display: inline-flex; align-items: center; gap: 8px;
    transition: background .2s ease, border-color .2s ease, transform .2s ease, box-shadow .2s ease;
  }
  .btn.primary { background: linear-gradient(135deg, #C1D0FF, #9EBAFF); color: #101A34; box-shadow: 0 4px 20px var(--glow), inset 0 1px 0 rgba(255, 255, 255, .3); }
  .btn.primary:hover { transform: translateY(-2px); box-shadow: 0 6px 28px rgba(91, 128, 255, .24); }
  .btn.ghost { border: 1px solid var(--line-strong); color: var(--ink); background: rgba(17, 27, 46, .5); }
  .btn.ghost:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

  .rail nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
  .rail nav a {
    display: flex; align-items: center; gap: 14px;
    padding: 7px 0;
    color: var(--ink-muted);
    text-decoration: none;
    font-size: .9rem; font-weight: 500;
    transition: color .15s ease;
  }
  .rail nav a::before {
    content: ""; height: 1.5px; width: 22px; background: var(--line-strong); transition: width .25s ease, background .25s ease, box-shadow .25s ease;
  }
  .rail nav a:hover, .rail nav a.is-active { color: var(--ink); }
  .rail nav a.is-active::before { width: 56px; background: var(--accent); box-shadow: 0 0 10px rgba(160, 181, 255, .45); }
  @media (prefers-reduced-motion: reduce) { .rail nav a.is-active::before { transition: none; } }

  .contacts { margin-top: auto; display: grid; gap: 6px; font-size: .85rem; }
  .contacts .mono { color: var(--ink-muted); }
  .menu-btn {
    display: none;
    font: inherit; font-size: .88rem; font-weight: 500;
    background: transparent; color: var(--ink);
    border: 1px solid var(--line-strong); border-radius: 8px;
    padding: 7px 12px; cursor: pointer;
  }
  .m-only { display: none; }

  /* main */
  main { padding-block: 72px 80px; min-width: 0; counter-reset: section; }
  main section { padding-block: 56px; border-top: 1px solid var(--line); scroll-margin-top: 24px; counter-increment: section; }
  main section:first-of-type { border-top: none; padding-top: 0; }
  main h2 { font-size: 1.55rem; font-weight: 600; margin-bottom: 12px; }
  main section > h2:not(.hero-title) { display: flex; align-items: center; gap: 14px; }
  main section > h2:not(.hero-title)::before {
    content: counter(section, decimal-leading-zero);
    flex: none;
    padding: 4px 8px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--accent-soft);
    color: var(--accent);
    font: 500 .72rem/1.5 'Geist Mono', ui-monospace, monospace;
    letter-spacing: .02em;
  }
  .eyebrow { margin-bottom: 12px; font: 500 .72rem/1.5 'Geist Mono', ui-monospace, monospace; letter-spacing: .09em; text-transform: uppercase; color: var(--cyan); }
  main .hero-title { font-size: clamp(1.75rem, 2.55vw, 2.55rem); font-weight: 600; line-height: 1.18; letter-spacing: -.045em; margin-bottom: 28px; }
  .hero-title span { color: var(--accent); }
  .lead { color: var(--ink-muted); max-width: 60ch; margin-bottom: 28px; }

  .proto-note {
    font-size: .82rem; color: var(--ink-muted);
    border: 1px dashed var(--line-strong); border-radius: 8px;
    padding: 10px 14px; margin-bottom: 28px;
  }
  .proto-note b { color: var(--ink); font-weight: 600; }

  /* terminal */
  .term {
    background: linear-gradient(145deg, #14223A, #0E182A 72%);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 24px 64px -28px var(--shadow), 0 0 40px -16px var(--glow), inset 0 1px 0 rgba(192, 212, 255, .08);
    overflow: hidden;
  }
  .term-bar {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    padding: 11px 16px;
    border-bottom: 1px solid var(--line);
    background: linear-gradient(90deg, #1B2A45, #15223A);
    font-family: 'Geist Mono', ui-monospace, monospace; font-size: .78rem; color: var(--ink-muted);
  }
  .term-bar .dots { display: flex; gap: 6px; }
  .term-bar .dots span { width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); display: block; }
  .term-bar .dots span:first-child { background: #7990BC; }
  .term-bar .dots span:nth-child(2) { background: #7699D6; }
  .term-bar .dots span:last-child { background: var(--pass); box-shadow: 0 0 10px rgba(116, 221, 168, .2); }
  .term-bar .repo { margin-left: auto; color: var(--accent); text-decoration: none; }
  .term-bar .repo:hover { text-decoration: underline; }
  .term-body {
    min-height: 274px;
    padding: 18px 20px 20px;
    font-family: 'Geist Mono', ui-monospace, monospace;
    font-size: .84rem;
    line-height: 1.9;
  }
  .term-body .ln { white-space: pre-wrap; word-break: break-word; }
  .term-body .prompt { color: var(--accent); font-weight: 600; }
  .term-body .ok { color: var(--pass); }
  .term-body .muted { color: var(--ink-muted); }
  .term-body .sum { color: var(--ink); font-weight: 600; margin-top: 6px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
  .term-body .overview-marker { color: var(--accent); }
  .repo-controls { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px 16px; padding: 10px 20px; border-top: 1px solid var(--line); background: rgba(18, 34, 59, .35); }
  .repo-controls[hidden] { display: none; }
  .repo-preview { font: 400 .72rem/1.5 'Geist Mono', ui-monospace, monospace; color: var(--ink-muted); }
  .repo-pager { display: flex; align-items: center; gap: 10px; }
  .repo-arrow { display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; flex: none; border: 1px solid var(--line-strong); border-radius: 8px; color: var(--accent); background: var(--surface); cursor: pointer; transition: background .2s ease, border-color .2s ease, box-shadow .2s ease; }
  .repo-arrow:hover { background: var(--accent-soft); border-color: var(--accent); box-shadow: 0 0 14px var(--glow); }
  .repo-arrow:active { background: var(--surface-2); }
  .repo-index { min-width: 7ch; color: var(--ink-muted); text-align: center; font: 500 .75rem/1.5 'Geist Mono', ui-monospace, monospace; font-variant-numeric: tabular-nums; }
  .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
  .status-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--pass); box-shadow: 0 0 12px rgba(116, 221, 168, .35); flex: none; }
  .cursor { display: inline-block; width: .55em; height: 1.05em; background: var(--accent); vertical-align: -3px; }
  .term-body.has-typewriter .ln { animation: none !important; }
  .term-body .is-type-pending { visibility: hidden; }
  .cursor.is-writing { position: relative; width: 0; background: transparent; animation: none; }
  .cursor.is-writing::after { content: ""; position: absolute; top: 0; left: .1em; width: .55em; height: 100%; background: var(--accent); box-shadow: 0 0 10px var(--glow); }

  .summary {
    display: grid; grid-template-columns: repeat(4, 1fr);
    border-top: 1px solid var(--line);
    background: rgba(18, 34, 59, .55);
  }
  .summary > div { padding: 18px 20px; }
  .summary > div + div { border-left: 1px solid var(--line); }
  .stat .num { font-family: 'Geist Mono', monospace; font-variant-numeric: tabular-nums; font-size: 1.45rem; font-weight: 600; letter-spacing: -.02em; color: var(--accent); margin-bottom: 5px; }
  .stat .cap { font-size: .8rem; color: var(--ink-muted); line-height: 1.35; }

  @keyframes blink { 0%, 55% { opacity: 1; } 56%, 100% { opacity: 0; } }
  .cursor { animation: blink 1.05s step-end infinite; }
  @media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .term-body .ln, .cursor { animation: none; }
  }

  /* skills */
  .skills { margin: 0; border: 1px solid var(--line); border-radius: 12px; padding: 2px 20px; background: linear-gradient(135deg, rgba(22, 36, 60, .8), rgba(13, 23, 40, .8)); box-shadow: inset 0 1px 0 rgba(192, 212, 255, .04); }
  .skill-row {
    display: grid; grid-template-columns: minmax(160px, .8fr) minmax(0, 1.5fr); gap: 24px;
    padding: 16px 0; border-bottom: 1px solid var(--line);
    align-items: baseline;
  }
  .skill-row dt { font-weight: 600; font-size: .95rem; }
  .skill-row dt span { display: block; font-weight: 400; font-size: .82rem; color: var(--ink-muted); margin-top: 2px; }
  .skill-row dd { min-width: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
  .tag {
    font-family: 'Geist Mono', monospace; font-size: .78rem;
    padding: 3px 9px; border-radius: 6px;
    background: rgba(21, 35, 57, .85); border: 1px solid var(--line); color: #C5D3EB;
    transition: border-color .15s ease, color .15s ease;
  }
  .skill-row:hover .tag { border-color: var(--accent); color: var(--accent); }

  /* cases */
  .case {
    background: linear-gradient(145deg, #15243E, #101B2F 60%, #0E192B);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 30px 30px 28px;
    box-shadow: 0 16px 48px -28px var(--shadow), inset 0 1px 0 rgba(192, 212, 255, .07);
    transition: border-color .2s ease, box-shadow .2s ease;
  }
  .case + .case { margin-top: 20px; }
  .case:hover { border-color: var(--line-strong); box-shadow: 0 20px 52px -24px var(--shadow), 0 0 28px -14px var(--glow); }
  .case-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
  .case h3 { font-size: 1.15rem; font-weight: 600; }
  .case-meta { display: flex; gap: 6px; flex-wrap: wrap; }
  .star { display: grid; gap: 12px; margin-bottom: 22px; }
  .star-row { display: grid; grid-template-columns: 96px 1fr; gap: 16px; }
  .star-row b { font-size: .82rem; font-weight: 600; color: var(--ink-muted); }
  .star-row p { font-size: .93rem; }
  .impact { display: grid; gap: 16px; padding-top: 18px; border-top: 1px solid var(--line); }
  .impact-title { font-size: .82rem; font-weight: 600; color: var(--ink-muted); margin-bottom: 6px; }
  .bar-row { display: grid; grid-template-columns: 56px 1fr 72px; gap: 12px; align-items: center; font-size: .82rem; }
  .bar-row .bl { color: var(--ink-muted); }
  .bar-row .bv { font-family: 'Geist Mono', monospace; font-variant-numeric: tabular-nums; font-weight: 600; text-align: right; }
  .track { height: 8px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
  .fill { display: block; height: 100%; border-radius: 4px; }
  .fill.before { background: var(--line-strong); }
  .fill.after { background: linear-gradient(90deg, #49B58D, var(--pass)); }
  .bar-row .bv.before { color: var(--ink-muted); }
  .bar-row .bv.after { color: var(--pass); }

  /* projects & experience */
  .rows { border-top: 1px solid var(--line); }
  .row-item { display: grid; grid-template-columns: 220px 1fr; gap: 24px; padding: 18px 0; border-bottom: 1px solid var(--line); }
  .row-item .k { font-family: 'Geist Mono', monospace; font-size: .8rem; color: var(--ink-muted); padding-top: 3px; }
  .row-item h3 { font-size: 1rem; font-weight: 600; margin-bottom: 4px; }
  .row-item .place { font-size: .88rem; color: var(--ink-muted); margin-bottom: 6px; }
  .row-item p, .row-item li { font-size: .92rem; color: var(--ink-muted); }
  .row-item ul { margin: 0; padding-left: 1.1em; display: grid; gap: 3px; }

  .skills > .skill-row:last-child, .rows > .row-item:last-child { border-bottom: none; }

  /* contact */
  .contact h2 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); margin-bottom: 10px; }
  .contact .lead { margin-bottom: 22px; }
  .contact-list { display: flex; flex-wrap: wrap; gap: 10px 26px; font-family: 'Geist Mono', monospace; font-size: .88rem; }
  .contact-list a { text-decoration: none; border-bottom: 1px solid var(--line-strong); }
  .contact-list a:hover { border-color: var(--accent); }
  .contact-list span { color: var(--ink-muted); }

  footer.page { font-size: .8rem; color: var(--ink-muted); padding-top: 28px; border-top: 1px solid var(--line); }

  /* responsive */
  @media (max-width: 960px) {
    .shell { display: block; padding-inline: 20px; }
    .rail {
      height: auto; overflow: visible;
      padding-block: calc(12px + env(safe-area-inset-top, 0px)) 12px;
      margin-inline: -20px; padding-inline: 20px;
      gap: 0;
      background: color-mix(in srgb, var(--bg) 88%, transparent);
      backdrop-filter: blur(10px);
      border-bottom: 1px solid var(--line);
      z-index: 20;
    }
    .rail h1 { font-size: 1.05rem; }
    .rail .role, .rail .pitch, .rail .ctas, .contacts, .rail .d-only { display: none; }
    .menu-btn { display: inline-flex; }
    .rail nav { display: none; padding-top: 8px; }
    .rail.open nav { display: block; }
    .rail nav a { padding: 11px 0; border-top: 1px solid var(--line); font-size: .95rem; }
    .rail nav a::before { display: none; }
    .rail nav a.is-active { color: var(--accent); }
    .m-only { display: block; }
    main { padding-top: 36px; }
    main section { scroll-margin-top: 80px; }
    .m-intro { margin-bottom: 32px; }
    .m-intro .role { font-size: 1.15rem; font-weight: 600; }
    .m-intro .pitch { color: var(--ink-muted); margin: 10px 0 18px; }
    main .hero-title { font-size: clamp(1.6rem, 4.5vw, 2.55rem); }
  }
  @media (max-width: 640px) {
    .term-body { font-size: .78rem; padding: 16px; min-height: 350px; }
    .repo-controls { padding-inline: 16px; }
    .repo-preview { font-size: .66rem; }
    .repo-pager { gap: 6px; }
    .term-body .leader { display: none; }
    .summary { grid-template-columns: 1fr 1fr; }
    .summary > div + div { border-left: none; }
    .summary > div { border-top: 1px solid var(--line); }
    .summary > div:nth-child(-n+2) { border-top: none; }
    .summary > div:nth-child(even) { border-left: 1px solid var(--line); }
    .skill-row, .row-item { grid-template-columns: 1fr; gap: 8px; }
    .star-row { grid-template-columns: 1fr; gap: 2px; }
    .case { padding: 20px 18px; }
  }

  /* idioma */
  .tools { display: flex; align-items: center; gap: 8px; }
  .lang { display: inline-flex; border: 1px solid var(--line-strong); border-radius: 8px; padding: 2px; }
  .lang button {
    font-family: 'Geist Mono', ui-monospace, monospace; font-size: .75rem; font-weight: 600;
    background: transparent; color: var(--ink-muted);
    border: 0; border-radius: 6px; padding: 5px 9px; cursor: pointer;
    transition: background .15s ease, color .15s ease;
  }
  .lang button:hover { color: var(--ink); }
  .lang button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
  @media (min-width: 961px) {
    .rail-top { flex-direction: column-reverse; align-items: flex-start; gap: 22px; }
  }
  .skill-row dt .t { display: inline; font-weight: 600; font-size: .95rem; color: var(--ink); margin: 0; }

  .rail .loc { font-size: .85rem; color: var(--ink-muted); margin-top: 10px; }
  .case-org { font-size: .85rem; color: var(--ink-muted); margin-top: 4px; }
  .num .unit { font-size: .95rem; font-weight: 500; color: var(--ink-muted); }
  .shift { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; font-size: .85rem; }
  .shift .from, .shift .to { padding: 6px 11px; border-radius: 6px; font-weight: 500; }
  .shift .from { background: var(--surface-2); color: var(--ink); }
  .shift .to { background: var(--pass-soft); color: var(--pass); }
  .shift .arrow { color: var(--ink-muted); }
  .facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
  .facts > div { background: var(--surface); padding: 12px 14px; display: grid; gap: 2px; }
  .facts .fv { font-family: 'Geist Mono', monospace; font-variant-numeric: tabular-nums; font-size: 1.15rem; font-weight: 600; color: var(--accent); }
  .facts .fl { font-size: .8rem; color: var(--ink-muted); line-height: 1.35; }
  @media (max-width: 640px) { .facts { grid-template-columns: 1fr; } }
  a.proj { color: var(--ink); text-decoration: none; background-image: linear-gradient(var(--accent), var(--accent)); background-size: 0 1.5px; background-position: 0 100%; background-repeat: no-repeat; transition: background-size .2s ease, color .15s ease; }
  a.proj:hover { color: var(--accent); background-size: 100% 1.5px; }
  .row-item .k { overflow-wrap: anywhere; }
  @media (max-width: 960px) { .rail .loc { display: none; } }

  /* layout resilience, hierarchy and progressive motion */
  html { scroll-padding-top: 24px; }
  .shell, main, main section, .term, .summary, .rows, .skills { min-width: 0; }
  .value-prop { margin-top: 14px; max-width: 32ch; color: var(--accent); font: 600 .82rem/1.45 'Geist Mono', ui-monospace, monospace; }
  .summary { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .summary > div, .stat, .stat .num, .stat .cap { min-width: 0; }
  .stat .num, .stat .cap { overflow-wrap: anywhere; }
  .term-bar > span:not(.dots) { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

  .case { position: relative; overflow: hidden; }
  .case-label { margin-bottom: 12px; color: var(--ink-muted); font: 500 .68rem/1.5 'Geist Mono', ui-monospace, monospace; letter-spacing: .09em; text-transform: uppercase; }
  .case-result { display: grid; gap: 5px; margin-bottom: 24px; position: relative; z-index: 1; }
  .result-number { color: var(--accent); font-family: 'Geist Mono', ui-monospace, monospace; font-size: clamp(2.6rem, 5vw, 4rem); font-weight: 600; letter-spacing: -.06em; line-height: 1.05; text-wrap: balance; }
  .result-number small { font-size: .36em; font-weight: 500; color: var(--cyan); letter-spacing: -.02em; }
  .result-caption { font-size: .95rem; font-weight: 500; color: var(--ink-muted); }
  .case-result-text .result-number { font-size: clamp(1.55rem, 3vw, 2.4rem); max-width: 24ch; letter-spacing: -.035em; }
  .case::after { content: ""; position: absolute; width: 300px; height: 240px; right: -110px; top: -100px; background: radial-gradient(ellipse, rgba(91, 128, 255, .14), transparent 70%); pointer-events: none; }
  .case-head { padding-top: 18px; border-top: 1px solid var(--line); }

  #projetos .rows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; border-top: 0; }
  #projetos .row-item { min-width: 0; grid-template-columns: 1fr; align-content: start; gap: 16px; padding: 22px; border: 1px solid var(--line); border-radius: 12px; background: linear-gradient(150deg, #14233B, #0F1A2D); box-shadow: inset 0 1px 0 rgba(192, 212, 255, .05); transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
  #projetos .row-item:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 18px 38px -28px var(--shadow), 0 0 24px -14px var(--glow); }
  #projetos .row-item .k { width: fit-content; padding: 3px 8px; border: 1px solid var(--line); border-radius: 6px; color: var(--accent); }
  #projetos .row-item h3 { font-size: 1.05rem; overflow-wrap: anywhere; }

  #experiencia .rows { position: relative; border-top: 0; padding-left: 24px; }
  #experiencia .rows::before { content: ""; position: absolute; top: 7px; bottom: 8px; left: 4px; width: 1px; background: linear-gradient(var(--accent), var(--line), transparent); }
  #experiencia .row-item { position: relative; }
  #experiencia .row-item::before { content: ""; position: absolute; left: -24px; top: 24px; width: 9px; height: 9px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); transform: translateX(-1px); box-shadow: 0 0 10px var(--glow); }
  #experiencia .row-item:first-child::before { background: var(--accent); }
  #experiencia .place { color: var(--accent); }
  #contato { border: 1px solid var(--line-strong); border-radius: 16px; padding: 30px; margin-block: 28px 36px; background: radial-gradient(ellipse at 100% 0%, rgba(91, 128, 255, .13), transparent 70%), var(--surface); box-shadow: 0 18px 44px -28px var(--shadow); }
  .contact-list a { overflow-wrap: anywhere; }

  .term-body .ln { animation: none; }
  html.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .55s cubic-bezier(.22, 1, .36, 1); }
  html.js .reveal.is-visible { opacity: 1; transform: none; }
  .fill { transform-origin: left; }
  html.js .impact:not(.is-visible) .fill { transform: scaleX(0); }
  html.js .impact.is-visible .fill { transform: scaleX(1); transition: transform .8s cubic-bezier(.22, 1, .36, 1); }
  html.js .impact.is-visible .fill.after { transition-delay: .16s; }

  @media (max-width: 960px) {
    .rail .value-prop { display: none; }
    .m-intro .value-prop { display: block; margin: -8px 0 18px; }
    .rail-top { min-width: 0; }
    .rail-top > h1 { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .tools { flex: none; }
  }
  @media (max-width: 640px) {
    .shell { max-width: 100%; }
    .term { width: 100%; }
    .term-bar { flex-wrap: nowrap; padding-inline: 12px; }
    .term-bar .repo { font-size: 0; flex: none; }
    .term-bar .repo::after { content: "↗"; font-size: .9rem; }
    .summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .summary > div { padding: 15px 14px; }
    .stat .num { font-size: 1.22rem; }
    .stat .cap { font-size: .75rem; }
    #projetos .rows { grid-template-columns: 1fr; }
    #experiencia .rows { padding-left: 18px; }
    #experiencia .row-item::before { left: -18px; }
    .skills { padding-inline: 16px; }
    .term-body .ln { overflow-wrap: anywhere; }
    #contato { padding: 22px 18px; }
    .row-item { min-width: 0; }
  }
  @media (prefers-reduced-motion: reduce) {
    .btn, .tag, .case, .lang button, .repo-arrow, .rail nav a::before, #projetos .row-item, html.js .reveal, .fill { transition: none !important; transform: none !important; }
    html.js .reveal { opacity: 1; }
    html.js .term .ln { opacity: 1; transform: none; animation: none !important; }
  }
