/* ============================================================
   Skills page. Loaded after styles.css and reuses its tokens,
   nav, buttons, reveal and split-heading contracts.
   ============================================================ */

body { background: var(--bg-page); }
code { font-family: "JetBrains Mono", ui-monospace, monospace; }

/* the current page holds the nav underline without waiting for script */
.nav-links a[aria-current="page"] { color: var(--ink); }

/* ---------- hero ---------- */
.skills-hero {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 56px; align-items: center;
  padding: 150px var(--gutter) 70px;
  isolation: isolate;
}
/* two soft lights instead of the landing page's shader: same palette, no GPU */
.skills-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(560px 380px at 78% 42%, rgba(67, 217, 208, 0.13), transparent 70%),
    radial-gradient(620px 420px at 18% 30%, rgba(106, 155, 255, 0.12), transparent 70%);
}
.skills-hero h1 {
  font-size: clamp(40px, 5.2vw, 70px); line-height: 1.05;
  font-weight: 800; letter-spacing: -0.035em; margin: 0 0 22px; max-width: 11em;
}
.skills-hero p {
  font-size: 18px; line-height: 1.7; color: var(--muted);
  max-width: 33em; margin: 0 0 32px;
}
.skills-hero p code {
  color: var(--teal); background: rgba(67, 217, 208, 0.09);
  padding: 2px 7px; border-radius: 6px; font-size: .92em;
}
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-cta .btn { padding: 14px 26px; }

/* ---------- console: one skill, run step by step ---------- */
.console {
  position: relative;
  background: linear-gradient(180deg, rgba(14, 20, 38, 0.92), rgba(8, 12, 26, 0.94));
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  overflow: hidden;
  font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 14px;
}
.console-bar {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 18px; border-bottom: 1px solid var(--line-soft);
}
.console-dots { display: flex; gap: 7px; }
.console-dots i { width: 11px; height: 11px; border-radius: 50%; background: rgba(255, 255, 255, 0.14); }
.console-dots i:first-child { background: #ff6b6b; opacity: .75; }
.console-dots i:nth-child(2) { background: #ffc75a; opacity: .75; }
.console-dots i:nth-child(3) { background: #43d9a0; opacity: .75; }
.console-skill { color: var(--muted-3); font-size: 13px; }
.console-body { padding: 22px 22px 24px; min-height: 340px; transition: opacity .35s ease; }
.console-body.is-out { opacity: 0; }
.console-say { display: flex; align-items: center; gap: 10px; color: var(--ink); font-size: 16px; margin-bottom: 20px; }
.console-caret { color: var(--teal); font-weight: 600; }
.console-cursor {
  width: 9px; height: 19px; margin-left: -6px; background: var(--teal);
  border-radius: 2px; opacity: 0;
}
.console.is-typing .console-cursor { opacity: 1; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.console-steps { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 11px; }
.console-steps li {
  position: relative; padding-left: 30px; color: var(--muted-2); line-height: 1.45;
  transition: opacity .35s ease, transform .5s var(--ease-out), color .3s ease;
}
/* the tick: a ring that fills, then a check drawn on top */
.console-steps li::before {
  content: ""; position: absolute; left: 0; top: 2px; width: 18px; height: 18px;
  border-radius: 50%; border: 1.5px solid rgba(255, 255, 255, 0.18);
  transition: background-color .3s ease, border-color .3s ease, transform .4s var(--ease-out);
}
.console-steps li::after {
  content: ""; position: absolute; left: 6px; top: 6px; width: 5px; height: 8px;
  border: solid var(--ink-dark); border-width: 0 2px 2px 0;
  transform: rotate(45deg) scale(0); transition: transform .3s var(--ease-out) .08s;
}
.console-steps li.is-done { color: var(--ink); }
.console-steps li.is-done::before { background: var(--teal); border-color: var(--teal); }
.console-steps li.is-done::after { transform: rotate(45deg) scale(1); }
.console-steps li.is-run { color: var(--ink); }
.console-steps li.is-run::before {
  border-color: var(--teal); border-right-color: transparent;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.console.is-live .console-steps li:not(.is-done):not(.is-run) { opacity: 0; transform: translate3d(0, 6px, 0); }

.console-result {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; border-radius: 12px;
  background: rgba(67, 217, 208, 0.08); border: 1px solid rgba(67, 217, 208, 0.28);
  color: #bff3ef; font-size: 13.5px;
  opacity: 0; transform: translate3d(0, 8px, 0);
  transition: opacity .4s ease, transform .6s var(--ease-out);
}
.console-result::before { content: "✓"; color: var(--teal); font-weight: 700; }
.console-result.is-on { opacity: 1; transform: none; }
.console-progress { height: 2px; background: rgba(255, 255, 255, 0.05); }
.console-progress span {
  display: block; height: 100%; background: var(--grad);
  transform: scaleX(0); transform-origin: 0 50%;
}

/* ---------- catalog ---------- */
.catalog { padding-top: 40px; }
.catalog-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 24px; flex-wrap: wrap; margin-bottom: 30px;
}
.catalog-head h2, .kits h2, .access h2 {
  font-size: clamp(32px, 3.6vw, 44px); font-weight: 800; letter-spacing: -0.025em;
}

.kit-filter {
  position: relative; display: flex; gap: 4px; padding: 5px;
  background: rgba(255, 255, 255, 0.04); border: 1px solid var(--line); border-radius: 100px;
}
.kit-chip {
  position: relative; z-index: 1;
  font: inherit; font-size: 14px; font-weight: 600; color: var(--muted-2);
  background: none; border: 0; border-radius: 100px; cursor: pointer;
  padding: 9px 16px; transition: color .3s ease;
}
.kit-chip .n {
  font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 12px;
  margin-left: 4px; opacity: .6;
}
.kit-chip:hover { color: var(--ink); }
.kit-chip.is-active { color: var(--ink-dark); }
.kit-chip:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
/* without script the active chip paints itself; with it, the pill slides */
.kit-chip.is-active { background: var(--grad); }
.kit-filter.has-pill .kit-chip.is-active { background: none; }
.kit-pill {
  position: absolute; left: 0; top: 5px; bottom: 5px; width: 0;
  border-radius: 100px; background: var(--grad); opacity: 0;
  box-shadow: 0 6px 22px rgba(67, 217, 208, 0.25);
}
.kit-filter.has-pill .kit-pill { opacity: 1; }
.kit-filter.is-ready .kit-pill { transition: transform .55s var(--ease-out), width .55s var(--ease-out); }
/* the label darkens as the pill lands under it, not before */
.kit-filter.is-ready .kit-chip.is-active { transition: color .3s ease .2s; }

.skill-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px;
}

/* ---------- card ---------- */
.skill-card {
  position: relative; display: flex; flex-direction: column;
  padding: 24px 24px 20px; border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--line);
  transition: transform .5s var(--ease-out), border-color .3s ease, box-shadow .4s ease;
}
.skill-card[hidden] { display: none; }
/* while its sheet is open the card has become the sheet */
.skill-card.is-lifted { opacity: 0; transition: opacity .18s ease; }
/* same pointer-aware hairline as the video cards (motion.js cardGlow) */
.skill-card::before {
  content: ""; position: absolute; inset: -1px; z-index: 2; border-radius: inherit;
  padding: 1px; pointer-events: none; opacity: 0;
  background: radial-gradient(320px circle at var(--gx, 50%) var(--gy, 50%),
    var(--teal), var(--blue) 42%, transparent 72%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  transition: opacity .35s ease;
}
/* a soft wash under the cursor, on its own layer */
.skill-card::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(420px circle at var(--gx, 50%) var(--gy, 50%), rgba(106, 155, 255, 0.08), transparent 60%);
  opacity: 0; transition: opacity .35s ease;
}
.skill-grid:hover .skill-card::before { opacity: 1; }
.skill-card:hover::after { opacity: 1; }
.skill-card:hover { transform: translate3d(0, -4px, 0); box-shadow: 0 22px 50px rgba(0, 0, 0, 0.35); }
.skill-card:focus-within { border-color: rgba(67, 217, 208, 0.5); }

.skill-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 18px; }
.skill-kit {
  font-size: 12px; font-weight: 600; letter-spacing: .02em; color: var(--teal);
  text-transform: uppercase;
}
.skill-status {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; color: var(--muted-3);
}
.skill-status::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%; background: #ffc75a;
  box-shadow: 0 0 0 0 rgba(255, 199, 90, 0.5);
}
.is-buyable .skill-status::before { background: var(--teal); }
.js-motion .is-soon .skill-status::before { animation: breathe 2.6s ease-out infinite; }
@keyframes breathe {
  0% { box-shadow: 0 0 0 0 rgba(255, 199, 90, 0.45); }
  70%, 100% { box-shadow: 0 0 0 7px rgba(255, 199, 90, 0); }
}

.skill-name { font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.skill-name code {
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.skill-title { margin: 0 0 12px; font-weight: 600; color: var(--ink); line-height: 1.45; }
.skill-summary { margin: 0 0 18px; color: var(--muted); font-size: 14.5px; line-height: 1.65; flex: 1; }

.skill-triggers { list-style: none; margin: 0 0 20px; padding: 0; display: flex; flex-wrap: wrap; gap: 7px; }
.skill-triggers li {
  font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 12.5px;
  color: #cfe0ff; background: rgba(106, 155, 255, 0.1);
  border: 1px solid rgba(106, 155, 255, 0.2); border-radius: 8px; padding: 4px 9px;
}
.skill-triggers li::before { content: "› "; color: var(--teal); }

.skill-foot {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 16px; border-top: 1px solid var(--line-soft);
  font-size: 13.5px; color: var(--muted-3);
}
.skill-price { font-weight: 700; color: var(--ink); }
.is-soon .skill-price { color: var(--muted-2); font-weight: 600; }
/* "more" affordance shows only once the button works */
.skill-foot::after {
  content: ""; width: 30px; height: 30px; border-radius: 50%; margin-left: 12px; flex: none;
  border: 1px solid var(--line); display: none;
  background:
    linear-gradient(var(--ink), var(--ink)) center / 10px 1.6px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center / 1.6px 10px no-repeat;
  transition: transform .45s var(--ease-out), background-color .3s ease, border-color .3s ease;
}
.skill-card.can-open .skill-foot::after { display: block; }
.skill-card.can-open .skill-price { margin-left: auto; }
.skill-card:hover .skill-foot::after { transform: rotate(90deg); border-color: rgba(67, 217, 208, 0.6); }

/* the whole card is the button */
.skill-open {
  position: absolute; inset: 0; z-index: 3; border-radius: inherit;
  background: none; border: 0; padding: 0; cursor: pointer;
}
.skill-open:focus-visible { outline: 2px solid var(--teal); outline-offset: 4px; }

/* ---------- detail sheet ---------- */
.skill-sheet {
  position: fixed; inset: 0; width: 100%; height: 100%;
  max-width: none; max-height: none; margin: 0; padding: 24px;
  border: 0; background: transparent; color: var(--ink);
  overflow-y: auto; overscroll-behavior: contain;
}
.skill-sheet[open] { display: grid; place-items: center; }
.skill-sheet::backdrop {
  background: rgba(3, 6, 14, 0.66);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.sheet-ghost {
  position: absolute; left: 0; top: 0; pointer-events: none;
  border-radius: var(--radius-lg); transform-origin: 0 0;
  background: linear-gradient(180deg, #121a31, #0b1124);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.55);
}
.sheet-panel {
  position: relative; width: min(880px, 100%);
  padding: 38px 40px 36px; border-radius: var(--radius-lg);
}
/* without the ghost (no script or reduced motion), the panel carries its own surface */
.skill-sheet:not(.has-ghost) .sheet-panel {
  background: linear-gradient(180deg, #121a31, #0b1124);
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.skill-sheet:not(.has-ghost) .sheet-ghost { display: none; }
.sheet-close {
  position: absolute; top: 18px; right: 18px; z-index: 2;
  width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, 0.06); border: 1px solid var(--line);
  color: var(--ink); cursor: pointer;
  transition: transform .45s var(--ease-out), border-color .25s ease;
}
.sheet-close:hover { transform: rotate(90deg); border-color: rgba(67, 217, 208, 0.6); }
.sheet-close:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; }

.sheet-in { transition: opacity .45s ease var(--d, 0ms), transform .7s var(--ease-out) var(--d, 0ms); }
.skill-sheet.is-entering .sheet-in { opacity: 0; transform: translate3d(0, 14px, 0); transition: none; }
.skill-sheet.is-leaving .sheet-in { opacity: 0; transition: opacity .16s ease; }
.skill-sheet.is-leaving .sheet-close { opacity: 0; transition: opacity .16s ease; }
/* the close button arrives with the content, not ahead of the surface */
.skill-sheet.has-ghost .sheet-close {
  transition: opacity .4s ease .3s, transform .6s var(--ease-out) .3s, border-color .25s ease;
}
.skill-sheet.is-entering .sheet-close { opacity: 0; transform: scale(.6) rotate(-90deg); transition: none; }
.skill-sheet.has-ghost .sheet-close:hover { transform: rotate(90deg); transition-delay: 0s; }

.sheet-head { margin-bottom: 14px; padding-right: 50px; }
.sheet-name { font-size: clamp(28px, 3.4vw, 38px); font-weight: 800; letter-spacing: -0.02em; margin: 8px 0 6px; }
.sheet-name code { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.sheet-title { margin: 0; font-size: 18px; font-weight: 600; }
.sheet-summary { color: var(--muted); line-height: 1.7; margin: 0 0 28px; max-width: 42em; }
.sheet-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 34px; }
.sheet-grid h3 {
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--muted-3); margin-bottom: 14px;
}
.sheet-side { display: grid; gap: 24px; align-content: start; }

/* numbered rail: each step a node on one line */
.sheet-steps { list-style: none; margin: 0; padding: 0; counter-reset: s; position: relative; }
.sheet-steps::before {
  content: ""; position: absolute; left: 14px; top: 14px; bottom: 14px; width: 1px;
  background: linear-gradient(var(--blue), var(--teal)); opacity: .35;
  transform-origin: 0 0; transition: transform .9s var(--ease-out) .2s;
}
.skill-sheet.is-entering .sheet-steps::before { transform: scaleY(0); transition: none; }
.sheet-steps li {
  counter-increment: s; position: relative; padding: 4px 0 14px 44px;
  line-height: 1.5; color: var(--ink);
  transition: opacity .4s ease calc(var(--d, 0ms) + var(--k, 0) * 55ms), transform .6s var(--ease-out) calc(var(--d, 0ms) + var(--k, 0) * 55ms);
}
.skill-sheet.is-entering .sheet-steps li { opacity: 0; transform: translate3d(-8px, 0, 0); transition: none; }
.sheet-steps li::before {
  content: counter(s); position: absolute; left: 0; top: 0;
  width: 29px; height: 29px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font: 600 12px "JetBrains Mono", ui-monospace, monospace; color: var(--teal);
  background: #0e1529; border: 1px solid rgba(67, 217, 208, 0.35);
}
.sheet-works { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.sheet-works li {
  font-size: 13.5px; color: var(--muted); padding: 6px 12px;
  border: 1px solid var(--line); border-radius: 100px; background: rgba(255, 255, 255, 0.03);
}
.sheet-buy {
  padding: 20px; border-radius: var(--radius-md);
  background: rgba(106, 155, 255, 0.07); border: 1px solid rgba(106, 155, 255, 0.2);
}
.sheet-price { font-size: 26px; font-weight: 800; margin-bottom: 14px; }
.sheet-buy .btn { width: 100%; padding: 13px 18px; }
.sheet-note { margin: 12px 0 0; font-size: 13px; color: var(--muted-3); line-height: 1.6; }
.sheet-note code { color: var(--muted); }

/* ---------- kits ---------- */
.kits { display: grid; gap: 22px; }
.kit-loop, .kit-pair {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: center;
  padding: 44px; border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--line);
}
.kit-copy p { color: var(--muted); line-height: 1.75; margin: 16px 0 0; max-width: 32em; }

.loop { position: relative; width: 320px; height: 320px; margin: 0 auto; }
.loop-ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.loop-arc { stroke-dasharray: 100; stroke-dashoffset: 0; transition: stroke-dashoffset 1.8s var(--ease-out); }
.js-motion .loop:not(.is-drawn) .loop-arc { stroke-dashoffset: 100; }
.loop-spin { position: absolute; inset: 0; }
.loop.is-running .loop-spin { animation: orbit 9s linear infinite; }
@keyframes orbit { to { transform: rotate(360deg); } }
.loop-dot {
  position: absolute; left: 50%; top: calc(50% - 118px); width: 12px; height: 12px;
  margin: -6px 0 0 -6px; border-radius: 50%; background: var(--teal);
  box-shadow: 0 0 0 5px rgba(67, 217, 208, 0.16), 0 0 22px rgba(67, 217, 208, 0.7);
}
/* nodes sit on the ring at 0°, 120°, 240° */
.loop-node {
  position: absolute; width: 132px; margin: -30px 0 0 -66px; text-align: center;
  padding: 10px 8px; border-radius: 14px;
  background: #0d1428; border: 1px solid var(--line);
  display: grid; gap: 3px;
}
.loop-node code { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.loop-node span { font-size: 12px; color: var(--muted-3); }
.loop-node::before {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none;
  border: 1px solid var(--teal); box-shadow: 0 0 26px rgba(67, 217, 208, 0.35); opacity: 0;
}
.loop-node.n1 { left: 50%; top: calc(50% - 118px); }
.loop-node.n2 { left: calc(50% + 102px); top: calc(50% + 59px); }
.loop-node.n3 { left: calc(50% - 102px); top: calc(50% + 59px); }
/* each node lights as the dot passes it: same 9s clock, phase-shifted */
.loop.is-running .loop-node::before { animation: arrive 9s linear infinite; }
.loop.is-running .loop-node.n2::before { animation-delay: -6s; }
.loop.is-running .loop-node.n3::before { animation-delay: -3s; }
@keyframes arrive {
  0% { opacity: 1; }
  16%, 92% { opacity: 0; }
  100% { opacity: 1; }
}
.loop-core {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  text-align: center; font-size: 13px; color: var(--muted-3); line-height: 1.5;
}

.kit-flow { display: flex; align-items: center; justify-content: center; gap: 0; }
.kit-flow .loop-node { position: relative; margin: 0; left: auto; top: auto; width: 150px; }
.kit-wire { position: relative; width: 90px; height: 2px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.kit-wire::after {
  content: ""; position: absolute; inset: 0; width: 40%;
  background: linear-gradient(90deg, transparent, var(--teal), transparent);
  transform: translate3d(-100%, 0, 0);
}
.kit-pair.is-running .kit-wire::after { animation: pulse-wire 2.4s var(--ease-out) infinite; }
@keyframes pulse-wire { to { transform: translate3d(260%, 0, 0); } }
.kit-pair.is-running .kit-flow .loop-node:last-child::before { animation: arrive-pair 2.4s ease infinite; }
@keyframes arrive-pair { 0%, 45% { opacity: 0; } 62% { opacity: 1; } 100% { opacity: 0; } }

/* ---------- access ---------- */
.access-card {
  text-align: center; padding: 56px 44px; border-radius: var(--radius-lg);
  background:
    radial-gradient(600px 260px at 50% 0%, rgba(106, 155, 255, 0.14), transparent 70%),
    rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
}
.access-card > p { color: var(--muted); line-height: 1.7; max-width: 36em; margin: 16px auto 34px; }
.access-steps {
  list-style: none; counter-reset: a; margin: 0 auto 36px; padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; max-width: 820px;
}
.access-steps li {
  counter-increment: a; text-align: left; padding: 20px; border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--line-soft);
  display: grid; gap: 6px; align-content: start;
}
.access-steps li::before {
  content: "0" counter(a); font: 600 12px "JetBrains Mono", ui-monospace, monospace; color: var(--teal);
}
.access-steps strong { font-size: 17px; }
.access-steps span { color: var(--muted); font-size: 14px; line-height: 1.55; }
.access-steps code { font-size: 12.5px; color: #cfe0ff; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .skill-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .skills-hero { grid-template-columns: minmax(0, 1fr); padding: 112px 22px 48px; gap: 40px; }
  .console-body { min-height: 0; }
  .kit-loop, .kit-pair { grid-template-columns: minmax(0, 1fr); padding: 28px 20px; }
  .sheet-grid { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .sheet-panel { padding: 30px 22px 24px; }
  .skill-sheet { padding: 12px; place-items: start center; }
  .access-card { padding: 40px 20px; }
  .access-steps { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .skill-grid { grid-template-columns: minmax(0, 1fr); }
  .catalog-head { align-items: flex-start; }
  .kit-filter { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
  .kit-chip { white-space: nowrap; padding: 9px 13px; }
  .loop { transform: scale(.86); margin: -20px auto; }
  .kit-wire { width: 40px; }
  .kit-flow .loop-node { width: 128px; }
}

@media (prefers-reduced-motion: reduce) {
  .skill-card, .skill-card::before, .skill-card::after, .skill-foot::after,
  .kit-pill, .sheet-close, .console-steps li, .console-result { transition: none; }
  .skill-card:hover { transform: none; }
  .skill-card:hover .skill-foot::after { transform: none; }
}
