/* Tokens follow alrevion.com (apps/web/main/site/src/styles/global.css). */
:root {
  --bg: #050607;
  --card: #0d0f12;
  --line: #1c1f24;
  --line-2: #30353d;
  --text: #f5f5f5;
  --body: #c9cdd3;
  --muted: #b1b6be;
  --dim: #858b95;
  --lime: #c6f432;
  --teal: #2fb0b0;
  --blue: #3b6ff0;
  --nav: #d6d9de;
  --plate: rgba(27, 27, 27, .4);
  --popover: rgba(22, 24, 28, .92);
  --hover-bg: rgba(255, 255, 255, .07);
  --font: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --wrap: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --radius: 16px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 112px; }
body { font: 400 16px/1.6 var(--font); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--lime); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--lime); color: #0b0c0e; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -9999px; top: 12px; z-index: 100; background: var(--text); color: var(--bg); padding: 10px 16px; border-radius: 10px; }
.skip:focus { left: 12px; }
.ulink { text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; transition: text-decoration-color .2s; }
.ulink:hover { text-decoration-color: var(--text); }

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  min-height: 48px; padding: 0 22px; border-radius: 999px;
  border: 1px solid var(--text); color: var(--text);
  font-size: 15px; font-weight: 500; white-space: nowrap;
  transition: background .2s, color .2s, border-color .2s;
}
.btn:hover { background: var(--text); color: var(--bg); }
.btn--solid { background: var(--lime); border-color: var(--lime); color: #0b0c0e; }
.btn--solid:hover { background: #d8ff5c; border-color: #d8ff5c; color: #0b0c0e; }
.btn--ghost { border-color: var(--line-2); }

/* —— Header: same as alrevion.com — transparent over the top, glass capsule once scrolled —— */
.hdr { position: fixed; top: 0; inset-inline: 0; z-index: 50; padding-top: 16px; pointer-events: none; }
.hdr__row {
  position: relative; pointer-events: auto;
  max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter);
  display: flex; align-items: center; gap: 24px; height: 84px;
}
.hdr__row::before {
  content: ""; position: absolute; z-index: -1; inset-block: 0;
  inset-inline: max(6px, calc(var(--gutter) - 20px));
  border-radius: 32px; background-color: var(--plate); box-shadow: 0 0 1px 1px var(--plate);
  opacity: 0; transition: opacity .2s ease-out;
}
.hdr.is-scrolled .hdr__row::before { opacity: 1; backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.hdr__logo { font-weight: 500; letter-spacing: .14em; font-size: 17px; white-space: nowrap; }
.hdr__nav { display: flex; gap: 36px; margin-inline: auto; font-size: 17px; color: var(--nav); }
.hdr__nav a { transition: color .2s; white-space: nowrap; }
.hdr__nav a:hover { color: #fff; }
.hdr__end { display: flex; align-items: center; gap: 10px; }
.hdr__cta { min-height: 56px; padding: 0 30px; font-size: 17px; font-weight: 400; border-color: rgba(255, 255, 255, .9); }

/* Language switcher — same pattern as alrevion.com */
.lang { position: relative; }
.lang summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 6px; color: var(--nav); font: 400 14px/1 var(--mono); padding: 10px; border-radius: 999px; }
.lang summary::-webkit-details-marker { display: none; }
.lang summary:hover, .lang[open] > summary { color: #fff; }
.lang__list {
  position: absolute; inset-inline-end: 0; top: calc(100% + 14px); list-style: none; padding: 6px; min-width: 180px;
  background: var(--popover); backdrop-filter: blur(28px) saturate(180%); -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, .1); border-radius: 20px; box-shadow: 0 18px 50px rgba(0, 0, 0, .5);
}
.lang__list a { display: flex; align-items: center; gap: 10px; padding: 9px 12px 9px 8px; border-radius: 12px; font-size: 15px; color: var(--muted); white-space: nowrap; }
.lang__list a:hover, .lang__list a[aria-current] { background: var(--hover-bg); color: var(--text); }
.flag { width: 20px; height: 20px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 1px rgba(255, 255, 255, .12); }

@media (max-width: 1100px) { .hdr__nav { gap: 24px; font-size: 16px; } .hdr__cta { min-height: 48px; padding: 0 22px; font-size: 15px; } }
@media (max-width: 960px) {
  .hdr__nav { display: none; }
  .hdr__end { margin-inline-start: auto; }
  .hdr { padding-top: 10px; }
  .hdr__row { height: 64px; }
  .hdr__row::before { border-radius: 24px; }
  html { scroll-padding-top: 88px; }
}
@media (max-width: 520px) { .hdr__row { gap: 8px; } .hdr__logo { font-size: 13px; letter-spacing: .08em; } .hdr__cta { display: none; } }

/* —— Hero: fan of light lines like alrevion.com (src/components/Hero.astro) —— */
.hero { position: relative; overflow: hidden; contain: paint; min-height: min(92vh, 860px); min-height: min(92svh, 860px); display: flex; align-items: center; }
.hero > .wrap { width: 100%; padding-block: 160px 96px; }
.hero__glow { position: absolute; top: -20%; height: 110%; right: -15%; width: 70%; background: radial-gradient(closest-side, rgba(0, 158, 137, .35), rgba(59, 111, 240, .12) 55%, transparent 75%); pointer-events: none; }
.hero__wave { position: absolute; inset: 0; width: 100%; height: 100%; fill: none; -webkit-mask-image: linear-gradient(#000 65%, transparent); mask-image: linear-gradient(#000 65%, transparent); stroke-width: .9; pointer-events: none; will-change: transform; animation: sway 10s ease-in-out infinite alternate; }
@keyframes sway { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-18px, 10px, 0); } }
.hero .wrap { position: relative; }
.hero__inner { max-width: 760px; }
.eyebrow { font-size: 15px; color: var(--dim); margin-bottom: 20px; }
.name { font-size: clamp(44px, 7.4vw, 92px); font-weight: 500; line-height: .98; letter-spacing: -.035em; }
.name span { display: block; }
.role { display: flex; align-items: center; min-height: 1.25em; margin: 14px 0 28px; font-size: clamp(26px, 3.6vw, 44px); font-weight: 500; letter-spacing: -.03em; line-height: 1.2; white-space: nowrap; }
.role__word { background: linear-gradient(90deg, var(--lime), #5fd4a0 60%, var(--teal)); -webkit-background-clip: text; background-clip: text; color: transparent; padding-block: .06em; }
.role__caret { width: .07em; height: .9em; margin-left: .08em; background: var(--lime); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.lead { max-width: 60ch; font-size: clamp(17px, 1.5vw, 19px); color: var(--body); margin-bottom: 32px; }
.name + .lead { margin-top: 28px; }
.lead a { color: var(--text); }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.contacts { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 28px; font-size: 15px; color: var(--muted); }
.contacts a, .contacts span { display: inline-flex; align-items: center; min-height: 32px; transition: color .2s; }
.contacts a:hover { color: var(--text); }
@media (max-width: 1000px) { .hero__wave { opacity: .45; } }
@media (max-width: 700px) { .hero > .wrap { padding-block: 128px 64px; } }

.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); }
@media (min-width: 800px) { .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stat { display: flex; flex-direction: column-reverse; justify-content: flex-end; padding: 28px 24px 28px 0; }
.stat + .stat { padding-left: 24px; border-left: 1px solid var(--line); }
@media (max-width: 799px) { .stat:nth-child(3) { padding-left: 0; border-left: 0; } .stat:nth-child(n+3) { border-top: 1px solid var(--line); } }
.stat dd { font-size: clamp(36px, 4.6vw, 52px); font-weight: 500; line-height: 1; letter-spacing: -.04em; font-variant-numeric: tabular-nums; margin-bottom: 10px; }
.stat dt { font-size: 14px; line-height: 1.4; color: var(--dim); }

/* —— Sections: title pinned on the left while the right column scrolls —— */
.sec { padding-top: clamp(72px, 10vw, 128px); }
.sec__grid { display: grid; gap: 28px; }
.sec__grid > * { min-width: 0; }
@media (max-width: 520px) { .rec th, .rec td { padding-right: 8px; } .rec td { font-size: 15px; } .rec thead th { font-size: 12px; white-space: normal; vertical-align: bottom; } .panel { padding: 20px; } }
@media (min-width: 1000px) {
  .sec__grid { grid-template-columns: 260px minmax(0, 1fr); gap: 48px; }
  .sec__head { position: sticky; top: 124px; align-self: start; }
}
.sec__head h2 { font-size: clamp(26px, 2.6vw, 32px); font-weight: 500; letter-spacing: -.025em; line-height: 1.15; }
.sec__head p { margin-top: 10px; color: var(--dim); font-size: 15px; max-width: 28ch; }

.entry { display: grid; gap: 8px 32px; padding-bottom: 40px; }
.entry + .entry { padding-top: 40px; border-top: 1px solid var(--line); }
.entry:last-child { padding-bottom: 0; }
@media (min-width: 720px) { .entry { grid-template-columns: 140px minmax(0, 1fr); } }
.entry__meta { font-size: 14px; line-height: 1.6; color: var(--dim); }
.entry__meta b { display: block; color: var(--text); font: 500 14px/1.6 var(--mono); }
.entry__title { font-size: 21px; font-weight: 500; letter-spacing: -.015em; line-height: 1.3; }
.entry__org { margin-top: 4px; font-size: 15px; color: var(--dim); }

.list { list-style: none; margin-top: 18px; display: grid; gap: 12px; }
.list li { position: relative; padding-left: 20px; color: var(--body); font-size: 16px; }
.list li::before { content: ""; position: absolute; left: 0; top: .8em; width: 8px; height: 1px; background: var(--dim); }
.list strong { color: var(--text); font-weight: 500; }
.facts { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 14px; font-size: 15px; color: var(--muted); }
.facts b { color: var(--text); font-weight: 500; }
.note { margin-top: 12px; font-size: 13px; line-height: 1.5; color: var(--dim); max-width: 80ch; }

/* —— Panels (A Generator, method) —— */
.panel { padding: clamp(24px, 4vw, 40px); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.panel + .panel { margin-top: 16px; }
.panel__top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 16px; }
.panel h3 { font-size: clamp(24px, 2.8vw, 32px); font-weight: 500; letter-spacing: -.03em; }
.panel__top a { font-size: 15px; color: var(--muted); }
.panel__top a:hover { color: var(--text); }
.panel > p { margin-top: 12px; color: var(--body); max-width: 68ch; }
.rec { width: 100%; margin-top: 28px; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.rec caption { text-align: left; font-size: 15px; font-weight: 500; padding-bottom: 12px; }
.rec th, .rec td { padding: 12px 12px 12px 0; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
.rec th:first-child, .rec td:first-child { text-align: left; }
.rec thead th { font-size: 13px; font-weight: 400; color: var(--dim); }
.rec td { font-size: 16px; color: var(--body); }
.rec td:first-child { font-family: var(--mono); font-size: 14px; color: var(--text); }
.rec .ours { color: var(--text); font-weight: 500; }
.rec .gain { color: var(--lime); }
.scroll-x { overflow-x: auto; }
.kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 24px; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }
@media (min-width: 760px) { .kv { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.kv div { display: flex; flex-direction: column-reverse; justify-content: flex-end; }
.kv dd { font-size: 28px; font-weight: 500; letter-spacing: -.03em; line-height: 1.1; }
.kv dt { margin-top: 6px; font-size: 14px; color: var(--dim); }

/* Method tracks */
.track { margin-top: 28px; }
.track__head { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; margin-bottom: 12px; }
.track__head h4 { font-size: 17px; font-weight: 500; }
.track__head span { font-size: 13px; color: var(--dim); }
.steps { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; counter-reset: s; }
.steps li { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 14px; color: var(--body); }
.steps li b { font: 500 12px/1 var(--mono); color: var(--dim); }
.steps--start li b { color: var(--lime); }
.steps--corp li b { color: #6ccfcf; }
.gate { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 24px; font-size: 14px; color: var(--muted); }
.gate b { color: var(--text); font-weight: 500; }

/* —— Products —— */
.cards { display: grid; gap: 16px; }
@media (min-width: 640px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.card { display: flex; flex-direction: column; gap: 8px; padding: 24px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .2s, transform .3s var(--ease); }
a.card:hover { border-color: var(--line-2); transform: translateY(-2px); }
.card__top { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; color: var(--dim); }
.card h3 { font-size: 20px; font-weight: 500; letter-spacing: -.015em; }
.card p { color: var(--body); font-size: 15px; }
.card__url { margin-top: auto; padding-top: 8px; font-size: 14px; color: var(--muted); }
.status--prod { color: #6ee7b7; }

/* —— Skills —— */
.rows { display: grid; }
.row { display: grid; gap: 6px 32px; padding: 18px 0; border-top: 1px solid var(--line); }
.row:first-child { border-top: 0; padding-top: 0; }
@media (min-width: 720px) { .row { grid-template-columns: 200px minmax(0, 1fr); align-items: baseline; } }
.row h3 { font-size: 15px; font-weight: 500; }
.row p { color: var(--body); font-size: 16px; }

.contact { padding: clamp(96px, 12vw, 152px) 0 40px; }
.contact h2 { font-size: clamp(32px, 4.6vw, 52px); font-weight: 500; letter-spacing: -.035em; line-height: 1.1; margin-bottom: 16px; }
.contact p { color: var(--body); max-width: 56ch; margin-bottom: 28px; }
.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 72px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 14px; color: var(--dim); }

/* —— Motion —— */
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.hero .eyebrow, .hero .name span, .hero .role, .hero .lead, .hero .cta, .hero .contacts, .stats { animation: rise .8s var(--ease) both; }
.hero .name span:nth-child(2) { animation-delay: .08s; }
.hero .role { animation-delay: .14s; }
.hero .lead { animation-delay: .2s; }
.hero .cta { animation-delay: .26s; }
.hero .contacts { animation-delay: .32s; }
.stats { animation-delay: .36s; }
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ================================================================
   PRINT — one Letter page, light
   ================================================================ */
.resume-print { display: none; }
.rp-doc {
  --rp-accent: #3f6212; --rp-text: #16181a; --rp-muted: #4b5049; --rp-light: #6b7068;
  font-family: "Onest", "Segoe UI", Arial, sans-serif; font-size: 8.2pt; line-height: 1.31; color: var(--rp-text);
}
.rp-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; }
.rp-name { font-size: 21pt; font-weight: 600; letter-spacing: -.03em; line-height: 1; margin: 0 0 .22em; }
.rp-tagline { font-size: 8pt; font-weight: 500; color: var(--rp-muted); }
.rp-contacts { text-align: right; font-size: 7.6pt; color: var(--rp-muted); line-height: 1.45; }
.rp-profile { margin: .45em 0 0; font-size: 8.2pt; line-height: 1.38; }
.rp-divider { border: none; border-top: .75pt solid #dfe1dc; margin: .38em 0 .28em; }
.rp-section-title { font-size: 6.8pt; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--rp-accent); margin: 0 0 .18em; }
.rp-entry-row { display: flex; justify-content: space-between; align-items: baseline; gap: .75rem; margin: .2em 0 .02em; }
.rp-entry-title { font-weight: 600; font-size: 8.7pt; line-height: 1.22; }
.rp-entry-date { font-size: 7.4pt; font-weight: 500; color: var(--rp-muted); white-space: nowrap; flex-shrink: 0; }
.rp-sub { font-size: 7.6pt; color: var(--rp-light); margin: 0 0 .06em; }
.rp-list { margin: .05em 0 .15em; padding: 0 0 0 .95em; list-style: none; }
.rp-list li { position: relative; margin: .07em 0; font-size: 7.9pt; line-height: 1.34; }
.rp-list li::before { content: "–"; position: absolute; left: -.95em; color: var(--rp-light); }
.rp-list strong { font-weight: 600; }
.rp-skill-row { display: grid; grid-template-columns: 1.05in 1fr; gap: 0 .4rem; margin: .06em 0; font-size: 7.9pt; align-items: baseline; }
.rp-skill-label { font-size: 7.4pt; font-weight: 600; color: var(--rp-muted); }
.rp-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.rp-link { color: inherit; text-decoration: none; }

@media print {
  @page { size: letter; margin: .42in .55in; }
  body { background: #fff !important; color: #16181a; }
  .hdr, main, .skip { display: none !important; }
  .resume-print { display: block !important; }
  .rp-entry, .rp-block { break-inside: avoid; }
}
