/* Portfolio styles: plum-to-cream palette, glass cards and serif accents. */

:root {
  /* Palette */
  --plum-900: #190019;
  --plum-800: #2b124c;
  --plum-700: #522b5b;
  --plum-600: #854f6c;
  --rose-300: #dfb6b2;
  --cream-100: #fbe4d8;

  /* Roles */
  --bg: var(--plum-900);
  --text: var(--cream-100);
  --text-muted: rgba(251, 228, 216, 0.68);
  --text-soft: rgba(251, 228, 216, 0.5);
  --accent: var(--rose-300);
  --glass: rgba(43, 18, 76, 0.34);
  --glass-strong: rgba(43, 18, 76, 0.55);
  --glass-border: rgba(223, 182, 178, 0.16);
  --glow: rgba(223, 182, 178, 0.35);
  --shadow: 0 24px 60px -24px rgba(8, 0, 10, 0.85);

  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --container: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-height: 76px;
  --radius: 18px;
  --radius-small: 12px;
  --ease: cubic-bezier(0.645, 0.045, 0.355, 1);
}

/* ---------- base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
}

body {
  margin: 0;
  background:
    radial-gradient(900px 600px at 78% -5%, rgba(133, 79, 108, 0.35), transparent 70%),
    radial-gradient(700px 500px at 5% 30%, rgba(43, 18, 76, 0.7), transparent 70%),
    radial-gradient(800px 600px at 95% 70%, rgba(82, 43, 91, 0.35), transparent 70%),
    var(--bg);
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

::selection {
  background: var(--plum-600);
  color: var(--cream-100);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.25s var(--ease);
}

a:hover {
  color: var(--accent);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

img {
  max-width: 100%;
}

.icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--plum-900);
}

.skip-link:focus {
  top: 16px;
}

/* ---------- typography ---------- */

.eyebrow {
  margin-bottom: 14px;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.eyebrow-bracket::before,
.eyebrow-bracket::after {
  content: "|";
  margin: 0 8px;
  opacity: 0.6;
}

.eyebrow-bracket::before {
  margin-left: 0;
}

.display {
  color: var(--text);
  font-weight: 300;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.display em {
  color: var(--accent);
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
}

.section-title {
  max-width: 720px;
  margin-bottom: 40px;
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
}

.panel-title {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
}

.subheading {
  margin: 70px 0 24px;
  color: var(--text);
  font-size: 1.15rem;
  font-weight: 400;
}

.prose p + p {
  margin-top: 18px;
}

.bullet-list li {
  position: relative;
  padding-left: 16px;
}

.bullet-list li::before {
  content: "";
  position: absolute;
  top: 0.68em;
  left: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.bullet-list li + li {
  margin-top: 6px;
}

/* ---------- buttons & links ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 22px;
  border: 1px solid transparent;
  border-radius: 10px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background-color 0.25s var(--ease), color 0.25s var(--ease);
}

.button .icon {
  width: 17px;
  height: 17px;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: linear-gradient(135deg, var(--rose-300), var(--cream-100));
  color: var(--plum-900);
  box-shadow: 0 10px 30px -10px var(--glow);
}

.button-primary:hover {
  color: var(--plum-900);
  box-shadow: 0 14px 36px -10px rgba(223, 182, 178, 0.6);
}

.button-ghost {
  border-color: rgba(223, 182, 178, 0.4);
  background: rgba(43, 18, 76, 0.25);
  color: var(--text);
}

.button-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.button-small {
  padding: 10px 16px;
  font-size: 0.72rem;
}

.pill-button {
  padding: 9px 18px;
  border: 1px solid rgba(223, 182, 178, 0.5);
  border-radius: 999px;
  background: rgba(82, 43, 91, 0.25);
  color: var(--text);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  box-shadow: 0 0 24px -6px var(--glow);
}

.pill-button:hover {
  background: rgba(223, 182, 178, 0.15);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
}

.icon-button {
  display: inline-grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  color: var(--text);
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease), transform 0.25s var(--ease);
}

.icon-button:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

.icon-button .icon {
  width: 18px;
  height: 18px;
}

/* ---------- glass surfaces ---------- */

.glass-card,
.glass-panel {
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(82, 43, 91, 0.28), rgba(43, 18, 76, 0.22));
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.glass-card {
  padding: 22px;
}

.glass-panel {
  padding: clamp(24px, 4vw, 40px);
}

.card-label {
  margin-bottom: 6px;
  color: var(--accent);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.card-value {
  color: var(--text);
  font-size: 1.4rem;
  font-weight: 300;
}

.card-body {
  color: var(--text-muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.icon-ring {
  display: inline-grid;
  width: 46px;
  height: 46px;
  place-items: center;
  margin-bottom: 16px;
  border: 1px solid rgba(223, 182, 178, 0.4);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(223, 182, 178, 0.18), transparent 70%);
  color: var(--accent);
  box-shadow: 0 0 22px -6px var(--glow);
}

.icon-ring-large {
  width: 62px;
  height: 62px;
}

/* ---------- header ---------- */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
  padding: 0 max(var(--gutter), calc((100vw - var(--container)) / 2));
  transition: transform 0.3s var(--ease), background-color 0.3s var(--ease), height 0.3s var(--ease);
}

.site-header.is-scrolled {
  height: 64px;
  background: rgba(25, 0, 25, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 10px 30px -20px rgba(0, 0, 0, 0.8);
}

.site-header.is-hidden {
  transform: translateY(-100%);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid var(--accent);
  border-radius: 12px;
  color: var(--accent);
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-style: italic;
  box-shadow: 0 0 20px -6px var(--glow), inset 0 0 12px -6px var(--glow);
}

.brand-text {
  display: grid;
  line-height: 1.2;
}

.brand-name {
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
}

.brand-aka {
  margin-left: 4px;
  color: var(--accent);
  font-family: var(--font-serif);
  font-size: 0.92rem;
  font-style: italic;
  letter-spacing: 0.02em;
  text-transform: none;
}

.brand-role {
  color: var(--text-soft);
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.header-panel {
  display: flex;
  align-items: center;
  gap: 28px;
}

.header-panel nav {
  display: flex;
  gap: 30px;
}

.header-panel nav a {
  position: relative;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.header-panel nav a::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: 50%;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0;
  transform: translateX(-50%);
  transition: opacity 0.25s var(--ease);
}

.header-panel nav a.is-current,
.header-panel nav a:hover {
  color: var(--text);
}

.header-panel nav a.is-current::after {
  opacity: 1;
}

.language-switch {
  display: inline-flex;
  overflow: hidden;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
}

.language-option {
  padding: 6px 11px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font: inherit;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  cursor: pointer;
}

.language-option[aria-pressed="true"] {
  background: rgba(223, 182, 178, 0.18);
  color: var(--text);
}

.menu-toggle {
  display: none;
  position: relative;
  z-index: 45;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  position: absolute;
  left: 8px;
  right: 8px;
  height: 1.5px;
  border-radius: 2px;
  background: var(--text);
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
}

.menu-toggle span:nth-child(1) { top: 13px; }
.menu-toggle span:nth-child(2) { top: 19.5px; }
.menu-toggle span:nth-child(3) { top: 26px; }

.menu-open .menu-toggle span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.menu-open .menu-toggle span:nth-child(2) { opacity: 0; }
.menu-open .menu-toggle span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ---------- layout ---------- */

main {
  padding: 0 var(--gutter);
}

.section {
  max-width: var(--container);
  margin: 0 auto;
  padding: clamp(60px, 9vw, 110px) 0;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 40px;
}

.section-head .section-title {
  margin-bottom: 0;
}

/* ---------- reveal on scroll ---------- */

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------- hero ---------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(24px, 4vw, 60px);
  align-items: center;
  max-width: var(--container);
  min-height: 100vh;
  min-height: 100svh;
  margin: 0 auto;
  padding: calc(var(--header-height) + 30px) 0 60px;
}

.hero-title {
  margin-bottom: 24px;
  font-size: clamp(2.3rem, 5vw, 3.6rem);
}

.hero-title em {
  display: block;
}

.hero-intro {
  max-width: 500px;
  margin-bottom: 34px;
  font-size: 1rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 40px;
}

.status-line {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.8rem;
  line-height: 1.5;
}

.status-line strong {
  display: block;
  color: var(--text);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.status-dot {
  position: relative;
  flex-shrink: 0;
  width: 14px;
  height: 14px;
  margin-top: 2px;
  border: 1px solid var(--accent);
  border-radius: 50%;
}

.status-dot::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse {
  50% {
    opacity: 0.35;
  }
}

.hero-visual {
  position: relative;
  aspect-ratio: 1 / 1.02;
  width: 100%;
  max-width: 560px;
  margin-left: auto;
}

.moon {
  position: absolute;
  top: 6%;
  left: 12%;
  width: 76%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #f3c9cf 0%, var(--rose-300) 25%, var(--plum-600) 62%, var(--plum-700) 100%);
  box-shadow: 0 0 90px 10px rgba(223, 182, 178, 0.35), 0 0 200px 40px rgba(133, 79, 108, 0.3);
}

.orbit {
  position: absolute;
  top: 1%;
  left: 7%;
  width: 86%;
  aspect-ratio: 1;
  border: 1px solid rgba(223, 182, 178, 0.18);
  border-radius: 50%;
}

.portrait {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 82%;
  height: auto;
  transform: translateX(-46%);
  filter: drop-shadow(0 20px 40px rgba(25, 0, 25, 0.6));
}

.float-card {
  position: absolute;
  z-index: 2;
  padding: 16px 18px;
  animation: float 7s ease-in-out infinite;
}

.card-experience {
  bottom: 18%;
  left: -6%;
  width: 150px;
}

.card-craft {
  top: 8%;
  right: -4%;
  width: 160px;
  animation-delay: -2s;
}

.card-craft .heart {
  width: 14px;
  height: 14px;
  margin-top: 8px;
  color: var(--accent);
}

.card-focus {
  right: -6%;
  bottom: 10%;
  width: 180px;
  animation-delay: -4s;
}

.card-focus .bullet-list {
  font-size: 0.8rem;
  line-height: 1.4;
}

.card-focus .bullet-list li + li {
  margin-top: 4px;
}

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

/* ---------- work: case cards ---------- */

.case-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.case-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  background: linear-gradient(170deg, rgba(82, 43, 91, 0.32), rgba(25, 0, 25, 0.6));
  box-shadow: var(--shadow);
  transition: transform 0.35s var(--ease), border-color 0.35s var(--ease);
}

.case-card:hover {
  border-color: rgba(223, 182, 178, 0.4);
  transform: translateY(-6px);
}

.case-visual {
  position: relative;
  height: 190px;
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 20%, rgba(223, 182, 178, 0.25), transparent 55%),
    linear-gradient(160deg, var(--plum-700), var(--plum-800));
}

.case-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 18px 20px 20px;
}

.case-index {
  color: var(--text-soft);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
}

.case-title {
  margin-top: 4px;
  color: var(--text);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.case-subtitle {
  margin-bottom: 12px;
  color: var(--accent);
  font-size: 0.85rem;
}

.case-description {
  flex: 1;
  margin-bottom: 18px;
  font-size: 0.86rem;
  line-height: 1.55;
}

.case-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag-list li {
  padding: 3px 9px;
  border: 1px solid var(--glass-border);
  border-radius: 6px;
  color: var(--text-muted);
  font-size: 0.66rem;
  letter-spacing: 0.04em;
}

.tag-list-plain li {
  padding: 0;
  border: 0;
  color: var(--text-soft);
}

.case-links {
  display: flex;
  flex-shrink: 0;
  gap: 8px;
}

.round-arrow {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid rgba(223, 182, 178, 0.5);
  border-radius: 50%;
  color: var(--accent);
  transition: background-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.round-arrow:hover {
  background: rgba(223, 182, 178, 0.15);
  transform: translateX(3px);
}

.round-arrow .icon {
  width: 18px;
  height: 18px;
}

.case-private {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 6px;
  color: var(--text-soft);
  font-size: 0.7rem;
}

.case-private .icon {
  width: 14px;
  height: 14px;
}

/* Handheld illustration: device, screen rows and a scan beam. */
.visual-handheld span:nth-child(1) {
  position: absolute;
  top: 12%;
  left: 38%;
  width: 24%;
  height: 84%;
  border: 2px solid var(--rose-300);
  border-radius: 16px;
  background: var(--plum-900);
}

.visual-handheld span:nth-child(2) {
  position: absolute;
  top: 20%;
  left: 41%;
  width: 18%;
  height: 40%;
  border-radius: 6px;
  background: var(--plum-800);
}

.visual-handheld span:nth-child(n + 3):nth-child(-n + 5) {
  position: absolute;
  left: 43%;
  width: 14%;
  height: 6%;
  border-radius: 3px;
  background: rgba(223, 182, 178, 0.25);
}

.visual-handheld span:nth-child(3) { top: 25%; }
.visual-handheld span:nth-child(4) { top: 35%; width: 10%; }
.visual-handheld span:nth-child(5) { top: 45%; width: 12%; }

.visual-handheld span:nth-child(6) {
  position: absolute;
  top: 36%;
  left: 16%;
  width: 68%;
  height: 2px;
  background: var(--cream-100);
  box-shadow: 0 0 16px 4px rgba(251, 228, 216, 0.6);
  animation: scan 3s ease-in-out infinite;
}

@keyframes scan {
  50% {
    transform: translateY(70px);
  }
}

/* Receipt illustration: paper strip with printed lines. */
.visual-receipt span:nth-child(1) {
  position: absolute;
  top: 10%;
  left: 36%;
  width: 28%;
  height: 82%;
  background: var(--cream-100);
  clip-path: polygon(0 0, 100% 0, 100% 94%, 90% 100%, 80% 94%, 70% 100%, 60% 94%, 50% 100%, 40% 94%, 30% 100%, 20% 94%, 10% 100%, 0 94%);
}

.visual-receipt span:nth-child(n + 2) {
  position: absolute;
  left: 40.5%;
  height: 4%;
  border-radius: 2px;
  background: rgba(82, 43, 91, 0.45);
}

.visual-receipt span:nth-child(2) { top: 18%; width: 19%; background: var(--plum-700); }
.visual-receipt span:nth-child(3) { top: 30%; width: 13%; }
.visual-receipt span:nth-child(4) { top: 38%; width: 17%; }
.visual-receipt span:nth-child(5) { top: 46%; width: 10%; }
.visual-receipt span:nth-child(6) { top: 60%; width: 19%; background: var(--plum-700); }
.visual-receipt span:nth-child(7) { top: 70%; width: 19%; height: 9%; background: repeating-linear-gradient(90deg, var(--plum-800) 0 2px, transparent 2px 4px, var(--plum-800) 4px 5px, transparent 5px 8px); }

/* Chart illustration: bars rising from a baseline. */
.visual-chart span {
  position: absolute;
  bottom: 18%;
  width: 7%;
  border-radius: 4px 4px 0 0;
  background: linear-gradient(180deg, var(--cream-100), var(--plum-600));
}

.visual-chart span:nth-child(1) { left: 20%; height: 28%; }
.visual-chart span:nth-child(2) { left: 30%; height: 46%; }
.visual-chart span:nth-child(3) { left: 40%; height: 36%; }
.visual-chart span:nth-child(4) { left: 50%; height: 56%; }
.visual-chart span:nth-child(5) { left: 60%; height: 42%; }
.visual-chart span:nth-child(6) { left: 70%; height: 64%; }

.visual-chart span:nth-child(7) {
  left: 16%;
  width: 68%;
  height: 1px;
  background: var(--rose-300);
}

/* Tasks illustration: a phone with a task list in PaceTasks' sage palette. */
.visual-tasks span:nth-child(1) {
  position: absolute;
  top: 10%;
  left: 37%;
  width: 26%;
  height: 86%;
  border: 2px solid var(--cream-100);
  border-radius: 18px;
  background: #e7efe1;
}

.visual-tasks span:nth-child(n + 2):nth-child(-n + 6) {
  position: absolute;
  left: 40%;
  width: 20%;
  height: 9%;
  border-radius: 6px;
  background: #f6f8f1;
  box-shadow: inset 3px 0 0 #4e8552;
}

.visual-tasks span:nth-child(2) { top: 20%; background: #4e8552; box-shadow: none; }
.visual-tasks span:nth-child(3) { top: 32%; }
.visual-tasks span:nth-child(4) { top: 44%; }
.visual-tasks span:nth-child(5) { top: 56%; }
.visual-tasks span:nth-child(6) { top: 68%; opacity: 0.55; }

.visual-tasks span:nth-child(7) {
  position: absolute;
  bottom: 9%;
  left: 44%;
  width: 12%;
  height: 4%;
  border-radius: 999px;
  background: #4e8552;
}

/* ---------- work: smaller project cards ---------- */

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

.mini-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-small);
  background: var(--glass);
  font-size: 0.84rem;
  line-height: 1.55;
}

.mini-card p {
  flex: 1;
}

.mini-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.mini-card-top .icon-button {
  width: 34px;
  height: 34px;
}

.folder-icon {
  width: 30px;
  height: 30px;
  color: var(--accent);
}

.muted-icon {
  width: 16px;
  height: 16px;
  margin-right: 9px;
  color: var(--text-soft);
}

.mini-card-title {
  color: var(--text);
  font-size: 0.98rem;
  font-weight: 500;
}

/* ---------- services panel ---------- */

.services-panel {
  display: grid;
  grid-template-columns: minmax(200px, 0.9fr) minmax(0, 2.6fr) minmax(170px, 0.8fr);
  gap: clamp(24px, 3vw, 40px);
  align-items: start;
}

.services-intro {
  position: relative;
  min-height: 100%;
}

.planet {
  position: relative;
  width: 110px;
  aspect-ratio: 1;
  margin-top: 30px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--cream-100), var(--plum-600) 55%, var(--plum-800));
  box-shadow: 0 0 50px -4px var(--glow);
}

.planet::after {
  content: "";
  position: absolute;
  top: 42%;
  left: -30%;
  width: 160%;
  height: 22%;
  border: 1px solid rgba(223, 182, 178, 0.5);
  border-radius: 50%;
  transform: rotate(-14deg);
}

.services-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.service h3 {
  margin-bottom: 8px;
  color: var(--text);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.service p {
  font-size: 0.84rem;
  line-height: 1.55;
}

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

.tool {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 4px;
  border-radius: 10px;
  text-align: center;
  cursor: help;
}

.tool-mark {
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.tool:hover .tool-mark,
.tool:focus-visible .tool-mark {
  box-shadow: 0 0 18px -4px var(--glow);
  transform: translateY(-2px);
}

/* One-sentence popup above a tool tile; --shift keeps it inside the screen. */
.tool-tip {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  z-index: 5;
  display: none;
  width: max-content;
  max-width: 200px;
  padding: 8px 11px;
  border: 1px solid rgba(223, 182, 178, 0.35);
  border-radius: 10px;
  background: rgba(25, 0, 25, 0.95);
  box-shadow: var(--shadow);
  color: var(--text);
  font-size: 0.72rem;
  line-height: 1.4;
  text-align: left;
  transform: translateX(calc(-50% + var(--shift, 0px)));
  pointer-events: none;
}

.tool-tip strong {
  display: block;
  margin-bottom: 2px;
  color: var(--accent);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.tool:hover .tool-tip,
.tool:focus-visible .tool-tip {
  display: block;
  animation: rise-in 0.2s var(--ease);
}

.tool-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--tint) 60%, transparent);
  border-radius: 10px;
  background: color-mix(in srgb, var(--tint) 22%, var(--plum-900));
  color: var(--cream-100);
  font-size: 0.85rem;
  font-weight: 600;
}

.tool-name {
  color: var(--text-soft);
  font-size: 0.6rem;
}

/* ---------- about ---------- */

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(260px, 0.8fr);
  gap: clamp(30px, 5vw, 70px);
  align-items: start;
}

.facts {
  display: grid;
  gap: 6px;
  padding: 26px;
}

.facts-text {
  margin-bottom: 14px;
  font-size: 0.88rem;
}

.facts-list {
  display: grid;
  gap: 10px;
  margin-bottom: 20px;
  font-size: 0.84rem;
  line-height: 1.45;
}

.facts-list li {
  display: grid;
}

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

.facts .button {
  justify-self: start;
}

/* ---------- experience ---------- */

.experience {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: clamp(20px, 4vw, 44px);
  min-height: 340px;
}

.tab-list {
  --active-index: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  border-left: 1px solid var(--glass-border);
}

.tab-list [role="tab"] {
  height: 46px;
  padding: 0 22px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font: inherit;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.25s var(--ease), background-color 0.25s var(--ease);
}

.tab-list [role="tab"]:hover,
.tab-list [role="tab"][aria-selected="true"] {
  background: rgba(223, 182, 178, 0.08);
  color: var(--text);
}

.tab-highlight {
  position: absolute;
  top: 0;
  left: -1px;
  width: 2px;
  height: 46px;
  background: var(--accent);
  box-shadow: 0 0 12px var(--glow);
  transform: translateY(calc(var(--active-index) * 46px));
  transition: transform 0.3s var(--ease);
}

.job-title {
  margin-bottom: 4px;
  color: var(--text);
  font-size: 1.2rem;
  font-weight: 400;
}

.job-title em {
  color: var(--accent);
  font-family: var(--font-serif);
}

.job-meta {
  margin-bottom: 18px;
  color: var(--text-soft);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

.job-bullets {
  font-size: 0.9rem;
}

.job-bullets li + li {
  margin-top: 10px;
}

/* ---------- process ---------- */

.process {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 40px;
  align-items: center;
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 18px;
}

.process-step {
  position: relative;
}

/* Glowing connector between step icons. */
.process-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 31px;
  left: 74px;
  right: -14px;
  height: 1px;
  background: linear-gradient(90deg, var(--rose-300), rgba(223, 182, 178, 0.15));
  box-shadow: 0 0 8px var(--glow);
}

.process-title {
  margin-bottom: 6px;
  color: var(--text);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.process-index {
  margin-right: 8px;
  color: var(--accent);
  font-family: var(--font-serif);
  font-size: 1rem;
  font-style: italic;
  letter-spacing: 0;
}

.process-body {
  font-size: 0.82rem;
  line-height: 1.5;
}

.arch-art {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 0 40px rgba(223, 182, 178, 0.25));
}

/* ---------- beyond code ---------- */

.beyond-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.beyond-card h3 {
  margin-bottom: 8px;
  color: var(--text);
  font-size: 1rem;
  font-weight: 500;
}

.beyond-card p {
  font-size: 0.88rem;
}

/* ---------- contact ---------- */

.contact-panel {
  position: relative;
  display: grid;
  grid-template-columns: 200px minmax(0, 1.1fr) minmax(0, 1fr);
  gap: clamp(24px, 3vw, 44px);
  align-items: center;
  padding-left: clamp(24px, 5vw, 64px);
}

.contact-side {
  position: absolute;
  top: 50%;
  left: 14px;
  color: var(--text-soft);
  font-size: 0.6rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  transform: translateY(-50%) rotate(180deg);
  writing-mode: vertical-rl;
}

.contact-art {
  width: 100%;
  height: auto;
}

.contact-body {
  margin: 16px 0 22px;
  font-size: 0.92rem;
}

.contact-list {
  display: grid;
  gap: 12px;
  font-size: 0.9rem;
}

.contact-list a,
.contact-list span {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.contact-list .icon {
  width: 18px;
  height: 18px;
  color: var(--accent);
}

.contact-form {
  display: grid;
  gap: 12px;
}

.field input,
.field textarea {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  background: rgba(25, 0, 25, 0.45);
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
  resize: vertical;
  transition: border-color 0.25s var(--ease);
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--text-soft);
}

.field input:focus,
.field textarea:focus {
  border-color: var(--accent);
  outline: none;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ---------- footer ---------- */

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 30px;
  max-width: var(--container);
  margin: 0 auto;
  padding: 50px var(--gutter) 30px;
  border-top: 1px solid var(--glass-border);
  font-size: 0.82rem;
}

.footer-brand p {
  max-width: 260px;
  margin-top: 14px;
  color: var(--text-soft);
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, max-content);
  gap: 8px 40px;
}

.social-list {
  display: flex;
  gap: 10px;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  grid-column: 1 / -1;
  justify-content: space-between;
  gap: 10px 24px;
  padding-top: 22px;
  border-top: 1px solid var(--glass-border);
  color: var(--text-soft);
  font-size: 0.72rem;
}

/* ---------- play: Bruno's walk (coding puzzle) ---------- */

.walk-game:focus {
  outline: none;
}

.walk-game:focus-visible {
  outline: 2px solid rgba(223, 182, 178, 0.55);
  outline-offset: 4px;
}

.walk-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
}

.walk-eyebrow {
  color: var(--accent);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.walk-levels {
  display: flex;
  gap: 6px;
}

.walk-level {
  width: 28px;
  height: 28px;
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  background: none;
  color: var(--text-muted);
  font: inherit;
  font-size: 0.74rem;
  cursor: pointer;
}

.walk-level[aria-current="step"] {
  border-color: var(--accent);
  color: var(--text);
}

.walk-level.is-solved {
  border-color: rgba(125, 216, 125, 0.6);
  background: rgba(125, 216, 125, 0.18);
  color: #c8f0c8;
}

.walk-hint {
  margin: 12px 0 16px;
  color: var(--text-muted);
  font-size: 0.86rem;
}

.walk-body {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 20px;
}

/* The park: a grid of tiles; treats and Bruno sit on top, placed through --x and --y. */
.walk-board {
  --tile: 50px;
  position: relative;
  display: grid;
  grid-template-columns: repeat(var(--columns), var(--tile));
  grid-auto-rows: var(--tile);
  overflow: hidden;
  border: 2px solid rgba(223, 182, 178, 0.4);
  border-radius: 12px;
  background: rgba(82, 43, 91, 0.3);
}

.walk-tile {
  position: relative;
  display: grid;
  place-items: center;
  border: 1px solid rgba(223, 182, 178, 0.06);
}

/* A puddle: an uneven blue blob with a little glint of light. */
.walk-tile.is-puddle::before {
  content: "";
  width: 78%;
  height: 58%;
  border-radius: 46% 54% 50% 50% / 55% 45% 55% 45%;
  background:
    radial-gradient(circle at 32% 34%, rgba(255, 255, 255, 0.75) 0 6%, transparent 7%),
    linear-gradient(160deg, rgba(160, 196, 238, 0.9), rgba(96, 128, 190, 0.85));
  box-shadow: inset 0 -2px 4px rgba(25, 0, 25, 0.35);
}

.walk-tile.is-splashed::before {
  animation: walk-splash 0.5s var(--ease);
}

.walk-paw {
  position: absolute;
  width: 44%;
  height: 44%;
  color: rgba(223, 182, 178, 0.45);
  transform: rotate(var(--angle));
}

.walk-treat,
.walk-bruno {
  position: absolute;
  top: 0;
  left: 0;
  width: var(--tile);
  height: var(--tile);
  transform: translate(calc(var(--x) * var(--tile)), calc(var(--y) * var(--tile)));
}

.walk-treat {
  display: grid;
  place-items: center;
  color: var(--cream-100);
  transition: opacity 0.25s var(--ease), scale 0.25s var(--ease);
}

.walk-treat .icon {
  width: 62%;
  height: 62%;
  rotate: -30deg;
  filter: drop-shadow(0 2px 4px rgba(8, 0, 10, 0.6));
}

.walk-treat.is-eaten {
  opacity: 0;
  scale: 0.3;
}

.walk-bruno {
  z-index: 1;
  transition: transform 0.32s var(--ease);
}

.walk-bruno img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 4px 5px rgba(8, 0, 10, 0.55));
  transition: transform 0.2s var(--ease);
}

.walk-bruno.is-flipped img {
  transform: scaleX(-1);
}

/* A small arrow at Bruno's paws shows which way walk() will go. */
.walk-heading {
  position: absolute;
  inset: 0;
  transform: rotate(var(--angle));
  transition: transform 0.25s var(--ease);
}

.walk-heading::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -3px;
  border-top: 6px solid transparent;
  border-bottom: 6px solid transparent;
  border-left: 8px solid var(--accent);
  transform: translateY(-50%);
}

.walk-bruno.is-resetting,
.walk-bruno.is-resetting img,
.walk-bruno.is-resetting .walk-heading {
  transition: none;
}

.walk-heart {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 2;
  width: 18px;
  height: 18px;
  color: #e07a8a;
  transform: translate(calc((var(--x) + 0.5) * var(--tile) - 9px), calc(var(--y) * var(--tile)));
  animation: walk-heart 0.8s var(--ease) forwards;
}

/* The code panel takes the park's height and scrolls once a program gets longer. */
.walk-code-panel {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 8px;
  min-width: 0;
  contain: size;
}

.walk-code {
  position: relative;
  padding: 12px 8px;
  overflow-y: auto;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-small);
  background: rgba(25, 0, 25, 0.65);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.75;
}

.walk-code-row {
  display: flex;
  gap: 12px;
  padding: 0 8px;
  border-radius: 6px;
  white-space: pre;
  transition: background-color 0.15s var(--ease);
}

.walk-line-no {
  flex: none;
  width: 2ch;
  color: var(--text-soft);
  text-align: right;
}

.walk-line-code {
  padding-left: calc(var(--depth) * 2ch);
}

.walk-code-row.is-running {
  background: rgba(223, 182, 178, 0.18);
}

.walk-code-row.is-error {
  background: rgba(224, 122, 138, 0.25);
}

.walk-code-row.is-passed .walk-line-no {
  color: #7dd87d;
}

.tok-kw {
  color: #c9a0dc;
}

.tok-fn {
  color: var(--accent);
}

.tok-num {
  color: #f0b27a;
}

.tok-comment {
  color: var(--text-soft);
  font-style: italic;
}

.walk-count {
  padding: 0 4px;
  border: 1px dashed rgba(240, 178, 122, 0.6);
  border-radius: 4px;
  background: rgba(240, 178, 122, 0.12);
  color: #f0b27a;
  font: inherit;
  cursor: pointer;
}

.walk-caret {
  display: inline-block;
  width: 2px;
  height: 1.1em;
  background: var(--accent);
  vertical-align: middle;
  animation: walk-blink 1s steps(1) infinite;
}

.walk-game.is-running .walk-caret {
  visibility: hidden;
}

.walk-lines {
  color: var(--text-soft);
  font-size: 0.74rem;
  text-align: right;
}

.walk-lines.is-full {
  color: #f0b27a;
}

.walk-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
}

.walk-command {
  padding: 8px 12px;
  border: 1px solid rgba(223, 182, 178, 0.35);
  border-radius: 8px;
  background: rgba(43, 18, 76, 0.55);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}

.walk-command:hover:not(:disabled) {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.walk-command:disabled,
.walk-actions .button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.walk-actions {
  display: flex;
  gap: 8px;
  margin-left: auto;
}

.walk-status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  min-height: 1.6em;
  margin-top: 14px;
  font-size: 0.88rem;
}

.walk-status.is-error {
  color: #f3a1ae;
}

.walk-status.is-success {
  color: #a6e8a6;
}

.walk-keys {
  margin-top: 8px;
  color: var(--text-soft);
  font-size: 0.72rem;
}

@keyframes walk-splash {
  50% {
    transform: scale(1.18);
  }
}

@keyframes walk-heart {
  to {
    opacity: 0;
    translate: 0 -26px;
  }
}

@keyframes walk-blink {
  50% {
    opacity: 0;
  }
}

/* Touch screens have no keyboard shortcuts to show. */
@media (hover: none) {
  .walk-keys {
    display: none;
  }
}

/* Phones: the park above the code, bigger buttons. */
@media (max-width: 680px) {
  .walk-body {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .walk-board {
    --tile: 42px;
  }

  .walk-code-panel {
    width: 100%;
    contain: none;
  }

  .walk-code {
    min-height: 130px;
    max-height: 180px;
  }

  .walk-actions {
    width: 100%;
    margin-left: 0;
  }

  .walk-actions .button {
    flex: 1;
  }
}

/* ---------- PaceTasks case study ---------- */

.pt-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: clamp(40px, 6vw, 80px);
  align-items: center;
  max-width: var(--container);
  min-height: 100vh;
  min-height: 100svh;
  margin: 0 auto;
  padding: calc(var(--header-height) + 40px) 0 80px;
}

.back-link {
  display: inline-block;
  margin-bottom: 26px;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.pt-name {
  margin-bottom: 14px;
  font-size: clamp(2.8rem, 7vw, 4.4rem);
}

.pt-tagline {
  margin-bottom: 16px;
  color: var(--accent);
  font-family: var(--font-serif);
  font-size: clamp(1.2rem, 2.6vw, 1.6rem);
  font-style: italic;
}

.pt-intro {
  max-width: 540px;
  margin-bottom: 28px;
}

.pt-facts {
  display: grid;
  gap: 14px;
  margin: 0 0 32px;
}

.pt-facts dd {
  margin: 2px 0 0;
  color: var(--text);
}

.pt-stack {
  margin-top: 6px;
}

.pt-features {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.pt-feature h3,
.pt-layer h3 {
  margin: 8px 0;
  color: var(--text);
  font-size: 1.02rem;
  font-weight: 500;
}

.pt-feature p {
  font-size: 0.9rem;
}

.pt-layers {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 36px;
  counter-reset: layer;
}

.pt-layer {
  position: relative;
  counter-increment: layer;
}

.pt-layer::before {
  content: "0" counter(layer);
  color: var(--accent);
  font-family: var(--font-serif);
  font-style: italic;
}

/* Arrow between layers shows the direction of data flow. */
.pt-layer:not(:last-child)::after {
  content: "→";
  position: absolute;
  top: 50%;
  right: -28px;
  color: var(--accent);
  font-size: 1.2rem;
  transform: translateY(-50%);
}

.pt-layer p {
  margin-bottom: 14px;
  font-size: 0.88rem;
}

.pt-layer ul {
  display: grid;
  gap: 6px;
}

.pt-layer ul li {
  padding: 6px 10px;
  border-radius: 8px;
  background: rgba(25, 0, 25, 0.45);
  color: var(--text-muted);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 0.74rem;
}

.pt-decisions li + li {
  margin-top: 12px;
}

.pt-footer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 40px;
}

/* Phone mockup in the PaceTasks "Film" theme (sage/cream with forest green). */
.phone {
  --pt-bg: #e7efe1;
  --pt-bg-end: #d7e4d0;
  --pt-surface: #f6f8f1;
  --pt-border: #dce5d5;
  --pt-text: #26332a;
  --pt-text-muted: #7c8779;
  --pt-green: #4e8552;
  --pt-green-light: #9fc89d;
  width: min(100%, 300px);
  margin: 0 auto;
  padding: 12px;
  border-radius: 42px;
  background: #140014;
  box-shadow: 0 0 80px -10px var(--glow), 0 0 0 1px var(--glass-border);
}

.pt-screen {
  display: flex;
  flex-direction: column;
  min-height: 560px;
  padding: 34px 16px 14px;
  border-radius: 32px;
  background: linear-gradient(180deg, var(--pt-bg), var(--pt-bg-end));
  color: var(--pt-text);
  font-family: var(--font-sans);
}

.pt-eyebrow {
  color: var(--pt-text-muted);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.pt-title {
  margin: 2px 0 14px;
  font-size: 1.7rem;
  font-weight: 800;
}

.pt-quickadd {
  margin-bottom: 14px;
  padding: 11px 14px;
  border: 1px solid var(--pt-border);
  border-radius: 14px;
  background: var(--pt-surface);
  color: var(--pt-text-muted);
  font-size: 0.8rem;
}

.pt-tasks {
  display: grid;
  gap: 8px;
}

.pt-task {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--pt-surface);
}

.pt-check {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border: 2px solid var(--pt-green);
  border-radius: 50%;
}

.pt-task.is-done .pt-check {
  background: var(--pt-green);
  box-shadow: inset 0 0 0 3px var(--pt-surface);
}

.pt-task.is-done .pt-task-title {
  color: var(--pt-text-muted);
  text-decoration: line-through;
}

.pt-task-text {
  display: grid;
  flex: 1;
  min-width: 0;
}

.pt-task-title {
  overflow: hidden;
  font-size: 0.82rem;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pt-task-meta {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--pt-text-muted);
  font-size: 0.66rem;
}

.pt-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.cat-work { background: #5c6fbf; }
.cat-personal { background: #8b6bb5; }
.cat-shopping { background: #d98a3d; }
.cat-home { background: #4e8552; }
.cat-health { background: #d9678a; }

.pt-badge,
.pt-timer {
  flex-shrink: 0;
  padding: 3px 7px;
  border-radius: 999px;
  font-size: 0.6rem;
  font-weight: 700;
}

.pt-badge {
  background: var(--pt-green);
  color: var(--pt-surface);
  letter-spacing: 0.06em;
}

.pt-timer {
  background: var(--pt-green-light);
  color: var(--pt-text);
}

.pt-tabbar {
  display: flex;
  justify-content: space-between;
  gap: 4px;
  margin-top: auto;
  padding: 5px;
  border-radius: 999px;
  background: var(--pt-surface);
  font-size: 0.68rem;
  font-weight: 600;
}

.pt-tabbar span {
  flex: 1;
  padding: 7px 0;
  border-radius: 999px;
  color: var(--pt-text-muted);
  text-align: center;
}

.pt-tabbar .is-active {
  background: var(--pt-green);
  color: var(--pt-surface);
}

/* ---------- simulations: shared ---------- */

.button:disabled {
  opacity: 0.5;
  cursor: progress;
  transform: none;
}

.demo-head {
  margin-bottom: 16px;
}

.demo-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 500;
}

/* A small glowing sparkle marks every interactive demo. */
.demo-badge {
  display: inline-grid;
  width: 26px;
  height: 26px;
  place-items: center;
  border: 1px solid rgba(223, 182, 178, 0.4);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(223, 182, 178, 0.22), transparent 70%);
  color: var(--accent);
  box-shadow: 0 0 14px -4px var(--glow);
  animation: twinkle 3s ease-in-out infinite;
}

.demo-badge .icon {
  width: 14px;
  height: 14px;
}

@keyframes twinkle {
  50% {
    transform: rotate(12deg) scale(1.08);
    box-shadow: 0 0 20px -2px var(--glow);
  }
}

.demo-body {
  margin-top: 6px;
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.5;
}

.demo-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  margin-top: 16px;
}

.demo-status {
  color: var(--text);
  font-size: 0.8rem;
}

.demo-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  cursor: pointer;
}

.demo-check input {
  accent-color: var(--rose-300);
}

/* ---------- simulations: hero feed ---------- */

/* Lets the one-line feed shrink instead of widening the hero column on small screens. */
.hero-copy {
  min-width: 0;
}

.hero-ticker {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 500px;
  margin-top: 18px;
  padding: 8px 14px;
  overflow: hidden;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  background: rgba(25, 0, 25, 0.45);
  font-size: 0.72rem;
}

.hero-ticker-label {
  flex-shrink: 0;
  color: var(--accent);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero-ticker-line {
  overflow: hidden;
  color: var(--text);
  font-family: var(--font-mono);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-ticker-line.is-entering {
  animation: rise-in 0.5s var(--ease);
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
}

/* ---------- simulations: live demo ---------- */

.lab-lede,
.play-lede {
  max-width: 760px;
  margin: -16px 0 32px;
  font-size: 0.95rem;
}

.lab {
  display: grid;
  gap: 26px;
}

.lab-pipeline {
  display: flex;
  align-items: center;
}

.lab-node {
  flex: 1 1 0;
  min-width: 0;
  padding: 16px 10px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-small);
  background: rgba(25, 0, 25, 0.35);
  text-align: center;
}

.lab-node .icon-ring {
  margin-bottom: 10px;
}

.lab-node-title {
  color: var(--text);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.lab-node-sub {
  color: var(--text-soft);
  font-family: var(--font-mono);
  font-size: 0.66rem;
}

.lab-node-stat {
  margin-top: 8px;
  color: var(--accent);
  font-size: 0.74rem;
}

.lab-node.is-active {
  animation: node-glow 0.9s var(--ease);
}

.lab-node.is-offline {
  border-style: dashed;
  border-color: rgba(217, 138, 61, 0.6);
}

.lab-node.is-offline .lab-node-stat {
  color: #f0b27a;
}

@keyframes node-glow {
  30% {
    border-color: var(--accent);
    box-shadow: 0 0 30px -4px var(--glow);
    transform: translateY(-3px);
  }
}

.lab-wire {
  position: relative;
  flex: 0 0 clamp(18px, 3vw, 44px);
  height: 1px;
  background: linear-gradient(90deg, var(--rose-300), rgba(223, 182, 178, 0.2));
}

.lab-packet {
  position: absolute;
  top: 50%;
  left: 0;
  width: 10px;
  height: 10px;
  margin-top: -5px;
  border-radius: 50%;
  background: var(--cream-100);
  box-shadow: 0 0 12px 3px var(--glow);
  opacity: 0;
}

.lab-wire.is-flowing .lab-packet {
  animation: packet-x 0.52s var(--ease);
}

@keyframes packet-x {
  from {
    left: 0;
    opacity: 1;
  }
  to {
    left: calc(100% - 10px);
    opacity: 1;
  }
}

@keyframes packet-y {
  from {
    top: 0;
    opacity: 1;
  }
  to {
    top: calc(100% - 10px);
    opacity: 1;
  }
}

.lab-panels {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.8fr) minmax(0, 1.3fr);
  gap: 18px;
}

.lab-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-small);
  background: rgba(25, 0, 25, 0.35);
}

.lab-empty {
  color: var(--text-soft);
  font-size: 0.8rem;
}

.lab-cart {
  flex: 1;
  min-height: 150px;
  max-height: 190px;
  overflow-y: auto;
  font-size: 0.84rem;
}

.lab-cart li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 6px 0;
  border-bottom: 1px dashed var(--glass-border);
}

.lab-cart li.lab-empty {
  border: 0;
}

.lab-total {
  display: flex;
  justify-content: space-between;
  margin: 10px 0 14px;
  color: var(--text);
}

.lab-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.lab-network[aria-pressed="false"] {
  border-color: #d98a3d;
  color: #f0b27a;
}

.lab-paper {
  flex: 1;
  min-height: 230px;
  max-height: 300px;
  padding: 16px 14px 24px;
  overflow-y: auto;
  background: var(--cream-100);
  color: var(--plum-900);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  line-height: 1.6;
  clip-path: polygon(0 0, 100% 0, 100% 97%, 90% 100%, 80% 97%, 70% 100%, 60% 97%, 50% 100%, 40% 97%, 30% 100%, 20% 97%, 10% 100%, 0 97%);
}

.lab-paper .lab-empty {
  color: var(--plum-700);
}

.lab-paper > p:last-child {
  animation: rise-in 0.25s var(--ease);
}

.receipt-shop {
  font-weight: 700;
  text-align: center;
}

.receipt-meta {
  color: var(--plum-700);
  text-align: center;
}

.receipt-line {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.receipt-total {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px dashed var(--plum-700);
  font-weight: 700;
}

.receipt-barcode {
  height: 26px;
  margin: 10px 0 4px;
  background: repeating-linear-gradient(90deg, var(--plum-900) 0 2px, transparent 2px 4px, var(--plum-900) 4px 5px, transparent 5px 8px);
}

.lab-log {
  flex: 1;
  min-height: 230px;
  max-height: 300px;
  padding: 12px;
  overflow-y: auto;
  border-radius: 10px;
  background: rgba(8, 0, 10, 0.55);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.55;
}

.lab-log li {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr);
  gap: 8px;
}

.lab-log li + li {
  margin-top: 4px;
}

.lab-log li:last-child {
  animation: rise-in 0.3s var(--ease);
}

.lab-log time {
  color: var(--text-soft);
}

.lab-log-source {
  font-weight: 600;
}

.source-handheld { color: #9fc89d; }
.source-room { color: #f0b27a; }
.source-rabbitmq { color: #ff9f80; }
.source-service { color: #b9a5e6; }
.source-sql { color: #8fb3e0; }
.source-printer { color: var(--cream-100); }

.lab-note {
  color: var(--text-soft);
  font-size: 0.72rem;
}

/* ---------- simulations: project card demos ---------- */

.case-visual[role="button"] {
  cursor: pointer;
}

.case-visual[role="button"]:focus-visible {
  outline-offset: -4px;
}

.visual-readout {
  position: absolute;
  bottom: 10px;
  left: 12px;
  display: grid;
  max-width: calc(100% - 24px);
  padding: 5px 10px;
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  background: rgba(25, 0, 25, 0.82);
  color: var(--cream-100);
  font-size: 0.72rem;
  line-height: 1.35;
}

.visual-readout:empty {
  display: none;
}

.visual-readout small {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.62rem;
}

.visual-handheld.is-scanning span:nth-child(2) {
  animation: screen-flash 0.6s var(--ease);
}

@keyframes screen-flash {
  30% {
    background: var(--plum-600);
  }
}

.visual-receipt.is-printing span:nth-child(1) {
  animation: paper-feed 0.7s var(--ease);
}

.visual-receipt.is-printing span:nth-child(n + 2) {
  transform-origin: left;
  animation: line-print 0.4s var(--ease) both;
}

.visual-receipt.is-printing span:nth-child(3) { animation-delay: 0.1s; }
.visual-receipt.is-printing span:nth-child(4) { animation-delay: 0.2s; }
.visual-receipt.is-printing span:nth-child(5) { animation-delay: 0.3s; }
.visual-receipt.is-printing span:nth-child(6) { animation-delay: 0.45s; }
.visual-receipt.is-printing span:nth-child(7) { animation-delay: 0.6s; }

@keyframes paper-feed {
  from {
    transform: translateY(-40%);
  }
}

@keyframes line-print {
  from {
    transform: scaleX(0);
  }
}

.visual-chart span:nth-child(-n + 6) {
  transition: height 0.6s var(--ease);
}

.case-visual.visual-tasks span.is-checked:nth-child(n + 3) {
  background: #9fc89d;
  opacity: 1;
  transition: background-color 0.3s var(--ease);
}

/* ---------- simulations: skill map ---------- */

.skill-map {
  display: grid;
  grid-column: 1 / -1;
  gap: 18px;
  padding-top: 28px;
  border-top: 1px solid var(--glass-border);
}

.skill-map-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 20px;
}

.skill-map-head .eyebrow {
  margin: 0;
}

.skill-map-hint {
  font-size: 0.84rem;
}

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

.skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.skill-chip {
  padding: 5px 10px;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 0.74rem;
  cursor: pointer;
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease), background-color 0.25s var(--ease);
}

.skill-chip:hover {
  border-color: var(--accent);
  color: var(--text);
}

.skill-chip[aria-pressed="true"] {
  border-color: var(--accent);
  background: rgba(223, 182, 178, 0.16);
  color: var(--text);
  box-shadow: 0 0 16px -4px var(--glow);
}

.skill-usage {
  padding: 16px 18px;
  border-radius: var(--radius-small);
  background: rgba(25, 0, 25, 0.35);
}

.skill-usage-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-target {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid rgba(223, 182, 178, 0.4);
  border-radius: 10px;
  background: rgba(43, 18, 76, 0.35);
  color: var(--text);
  font: inherit;
  font-size: 0.8rem;
  cursor: pointer;
  transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}

.skill-target:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.skill-target .icon {
  width: 15px;
  height: 15px;
  color: var(--accent);
}

.case-card.is-matched,
.mini-card.is-matched {
  border-color: rgba(223, 182, 178, 0.55);
  box-shadow: var(--shadow), 0 0 30px -10px var(--glow);
}

.tab-list [role="tab"].is-matched::after {
  content: "•";
  margin-left: 8px;
  color: var(--accent);
}

.is-flash {
  animation: flash 1.2s var(--ease);
}

@keyframes flash {
  30% {
    box-shadow: 0 0 0 2px var(--accent), 0 0 40px var(--glow);
  }
}

/* ---------- simulations: experience demos ---------- */

.job-demo {
  margin-top: 26px;
  padding: 20px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-small);
  background: rgba(25, 0, 25, 0.35);
}

.device-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.device {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  background: rgba(43, 18, 76, 0.3);
  transition: border-color 0.3s var(--ease);
}

.device-name {
  color: var(--text-soft);
  font-size: 0.66rem;
  letter-spacing: 0.06em;
}

.device-version {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 500;
}

.device.is-running {
  border-color: #d98a3d;
}

.device.is-running .device-version {
  color: #f0b27a;
}

.device.is-current {
  border-color: rgba(159, 200, 157, 0.55);
}

.device.is-current .device-version {
  color: #9fc89d;
}

.demo-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.demo-steps li {
  padding: 10px 8px;
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  color: var(--text-soft);
  font-size: 0.74rem;
  text-align: center;
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease), background-color 0.3s var(--ease);
}

.demo-steps li[data-state="active"] {
  border-color: var(--accent);
  color: var(--text);
  box-shadow: 0 0 20px -6px var(--glow);
}

.demo-steps li[data-state="done"] {
  border-color: rgba(159, 200, 157, 0.55);
  background: rgba(159, 200, 157, 0.1);
  color: #c9e3c7;
}

.demo-steps li[data-state="error"] {
  border-color: #e07a8a;
  background: rgba(224, 122, 138, 0.14);
  color: #f2b3bd;
}

.demo-credit {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.demo-ranges {
  display: grid;
  gap: 18px;
}

.demo-range {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 12px;
  font-size: 0.8rem;
}

.demo-range input {
  grid-column: 1 / -1;
  grid-row: 2;
  width: 100%;
  accent-color: var(--rose-300);
}

.demo-range output {
  color: var(--text);
  font-weight: 500;
}

.demo-result {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 10px;
  background: rgba(43, 18, 76, 0.35);
}

.demo-result .card-label:not(:first-child) {
  margin-top: 10px;
}

.demo-result strong {
  color: var(--text);
  font-weight: 500;
}

.demo-meter {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(223, 182, 178, 0.15);
}

.demo-meter-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #9fc89d, #d98a3d, #e07a8a);
  transition: width 0.3s var(--ease);
}

.demo-result .demo-big {
  font-size: 1.4rem;
  font-weight: 300;
}

.demo-verdict {
  justify-self: start;
  margin-top: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
}

.demo-verdict[data-state="approved"] { background: rgba(159, 200, 157, 0.18); color: #c9e3c7; }
.demo-verdict[data-state="review"] { background: rgba(217, 138, 61, 0.2); color: #f0b27a; }
.demo-verdict[data-state="declined"] { background: rgba(224, 122, 138, 0.2); color: #f2b3bd; }

.test-lanes {
  display: grid;
  gap: 12px;
}

.test-lane {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr) 60px;
  gap: 12px;
  align-items: center;
  font-size: 0.78rem;
}

.test-dots {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 4px;
}

.test-dots li {
  height: 12px;
  border-radius: 3px;
  background: rgba(223, 182, 178, 0.15);
  transition: background-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.test-dots li.is-passed {
  background: #9fc89d;
  box-shadow: 0 0 8px -2px #9fc89d;
}

.test-clock {
  color: var(--text);
  font-family: var(--font-mono);
  font-weight: 500;
  text-align: right;
}

/* ---------- simulations: process run ---------- */

.process-run {
  display: grid;
  gap: 14px;
  margin-top: 30px;
}

.process-run-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
}

.process-run-head .demo-body {
  margin: 0;
}

.process-log {
  display: grid;
  gap: 8px;
  font-size: 0.84rem;
}

.process-log li {
  padding: 10px 14px;
  border-left: 2px solid var(--accent);
  border-radius: 0 10px 10px 0;
  background: rgba(25, 0, 25, 0.35);
  animation: rise-in 0.4s var(--ease);
}

.process-log strong {
  margin-right: 8px;
  color: var(--text);
  font-weight: 600;
}

.process-step .icon-ring {
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.process-step.is-active .icon-ring {
  background: rgba(223, 182, 178, 0.3);
  color: var(--cream-100);
  box-shadow: 0 0 34px -2px var(--glow);
  transform: scale(1.12);
}

.process-step.is-done .icon-ring {
  border-color: #9fc89d;
  color: #9fc89d;
}

/* ---------- simulations: beyond code ---------- */

.beyond-demo {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--glass-border);
}

.beyond-demo .demo-actions {
  margin-top: 12px;
}

.climb-wall {
  position: relative;
  height: 120px;
  overflow: hidden;
  border-radius: 10px;
  background: linear-gradient(160deg, rgba(82, 43, 91, 0.5), rgba(25, 0, 25, 0.6));
}

.climb-hold {
  position: absolute;
  width: 14px;
  height: 12px;
  margin: -6px 0 0 -7px;
  border-radius: 45% 55% 50% 40%;
  background: var(--rose-300);
}

.climb-climber {
  position: absolute;
  z-index: 1;
  width: 14px;
  height: 14px;
  margin: -7px 0 0 -7px;
  border-radius: 50%;
  background: var(--cream-100);
  box-shadow: 0 0 14px 2px var(--glow);
  transition: left 0.4s var(--ease), top 0.4s var(--ease), background-color 0.3s var(--ease);
}

.climb-climber.is-falling {
  background: #e07a8a;
  transition-timing-function: cubic-bezier(0.55, 0, 1, 0.45);
}

.climb-climber.is-topped {
  background: #9fc89d;
  box-shadow: 0 0 18px 4px rgba(159, 200, 157, 0.6);
}

.stitch-rows {
  display: grid;
  align-content: end;
  gap: 6px;
  min-height: 120px;
}

.stitch-rows li {
  display: flex;
  gap: 4px;
}

.stitch-rows span {
  width: 12px;
  height: 12px;
  border: 2px solid var(--rose-300);
  border-radius: 50%;
}

.stitch-rows li:last-child span {
  animation: rise-in 0.3s var(--ease) both;
}

.stitch-rows li.is-bug span {
  border-color: #e07a8a;
}

.stitch-rows li.is-bug span:last-child {
  background: #e07a8a;
}

/* ---------- simulations: PaceTasks phone ---------- */

.pt-phone-wrap {
  display: grid;
  justify-items: center;
  gap: 14px;
}

.pt-mockup-hint {
  color: var(--text-soft);
  font-size: 0.78rem;
  text-align: center;
}

input.pt-quickadd {
  width: 100%;
  color: var(--pt-text);
  font: inherit;
  font-size: 0.8rem;
  outline: none;
}

input.pt-quickadd::placeholder {
  color: var(--pt-text-muted);
}

input.pt-quickadd:focus {
  border-color: var(--pt-green);
}

.pt-tasks {
  max-height: 340px;
  overflow-y: auto;
}

button.pt-task {
  width: 100%;
  border: 0;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: transform 0.2s var(--ease);
}

button.pt-task:hover {
  transform: translateX(2px);
}

button.pt-task:focus-visible {
  outline-color: var(--pt-green);
}

/* ---------- personal: portrait releases ---------- */

.hero-photo {
  position: absolute;
  inset: 0;
}

/* A slightly smaller portrait keeps the floating cards on its edges, away from the face. */
.portrait-stack .portrait {
  width: 74%;
}

.portrait-stack {
  position: absolute;
  inset: 0;
  cursor: pointer;
}

.portrait-stack .portrait {
  opacity: 0;
  transition: opacity 0.6s var(--ease);
}

.portrait-stack .portrait.is-current {
  opacity: 1;
}

.card-release {
  width: 176px;
}

/* Hold the floating card still while someone reads or clicks it. */
.card-release:hover {
  animation-play-state: paused;
}

.release-version {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 1.05rem;
  font-weight: 500;
}

.release-note {
  min-height: 3em;
  margin: 2px 0 10px;
}

.release-next {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent);
  font: inherit;
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
}

.release-next .icon {
  width: 14px;
  height: 14px;
  transition: transform 0.25s var(--ease);
}

.release-next:hover .icon {
  transform: translateX(3px);
}

/* ---------- personal: beyond code photos ---------- */

.beyond-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.beyond-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Bruno's card is twice as wide: photo on the left, story and treats on the right. */
.beyond-card-wide {
  display: grid;
  grid-column: span 2;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 24px;
}

.beyond-body {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.beyond-body .beyond-demo {
  margin-top: auto;
}

.beyond-body p + .beyond-demo {
  margin-top: 18px;
}

.icon-ring-photo {
  overflow: hidden;
  padding: 0;
}

.icon-ring-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.beyond-facts {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
}

.beyond-facts div {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 12px;
  font-size: 0.84rem;
}

.beyond-facts dt {
  color: var(--accent);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  line-height: 2;
  text-transform: uppercase;
}

.beyond-facts dd {
  margin: 0;
  color: var(--text);
}

.photo-stack {
  position: relative;
  display: flex;
  flex-direction: column;
  margin: -22px -22px 18px;
  cursor: pointer;
}

.photo-frame {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--plum-800);
}

.beyond-card-wide .photo-stack {
  margin: -22px 0 -22px -22px;
}

.beyond-card-wide .photo-frame {
  flex: 1;
  aspect-ratio: auto;
  min-height: 320px;
}

.photo-stack img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.04);
  transition: opacity 0.7s var(--ease), transform 1.2s var(--ease);
}

.photo-stack img.is-current {
  opacity: 1;
  transform: none;
}

.photo-caption {
  min-height: 3.4em;
  padding: 10px 14px;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(25, 0, 25, 0.55);
  color: var(--cream-100);
  font-family: var(--font-serif);
  font-size: 0.86rem;
  font-style: italic;
  line-height: 1.4;
}

.photo-stack:focus-visible {
  outline-offset: -4px;
}

.heart-pop {
  position: absolute;
  bottom: 30%;
  left: 50%;
  color: #e07a8a;
  animation: heart-pop 1.1s var(--ease) forwards;
  pointer-events: none;
}

.heart-pop .icon {
  width: 34px;
  height: 34px;
  fill: currentColor;
}

@keyframes heart-pop {
  0% {
    opacity: 0;
    transform: translate(-50%, 10px) scale(0.6);
  }
  25% {
    opacity: 1;
    transform: translate(-50%, -10px) scale(1.15);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -80px) scale(1);
  }
}

.oven {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(223, 182, 178, 0.15);
}

.oven-fill {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #f0b27a, #d98a3d, #e07a8a);
  box-shadow: 0 0 12px rgba(217, 138, 61, 0.6);
  transition: width 0.15s linear;
}

/* ---------- motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .float-card,
  .status-dot::after,
  .visual-handheld span:nth-child(6),
  .hero-ticker-line.is-entering,
  .lab-node.is-active,
  .lab-wire.is-flowing .lab-packet,
  .lab-paper > p:last-child,
  .lab-log li:last-child,
  .visual-handheld.is-scanning span,
  .visual-receipt.is-printing span,
  .is-flash,
  .process-log li,
  .stitch-rows li:last-child span,
  .demo-badge,
  .tool:hover .tool-tip,
  .heart-pop,
  .walk-caret {
    animation: none;
  }

  .climb-climber,
  .visual-chart span,
  .demo-meter-fill,
  .portrait-stack .portrait,
  .photo-stack img {
    transition: none;
  }
}

/* ---------- responsive ---------- */

@media (max-width: 1100px) {
  .menu-toggle {
    display: block;
  }

  .header-panel {
    position: fixed;
    inset: 0 0 0 auto;
    z-index: 42;
    flex-direction: column;
    justify-content: center;
    gap: 34px;
    width: min(78vw, 380px);
    padding: 40px 24px;
    background: rgba(25, 0, 25, 0.96);
    box-shadow: -20px 0 40px -20px rgba(0, 0, 0, 0.8);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.3s var(--ease), visibility 0.3s var(--ease);
  }

  .menu-open .header-panel {
    transform: none;
    visibility: visible;
  }

  .menu-open main,
  .menu-open .site-footer {
    filter: blur(4px);
  }

  .header-panel nav {
    flex-direction: column;
    align-items: center;
    gap: 24px;
  }

  .header-panel nav a {
    font-size: 0.85rem;
  }

  .services-panel {
    grid-template-columns: 1fr;
  }

  .services-intro {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
  }

  .planet {
    flex-shrink: 0;
    width: 80px;
    margin: 0 20px 0 0;
  }

  .services-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tool-grid {
    grid-template-columns: repeat(9, minmax(0, 1fr));
  }

  .process {
    grid-template-columns: 1fr;
  }

  .arch-art {
    display: none;
  }
}

@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding-bottom: 20px;
  }

  .hero-visual {
    max-width: 440px;
    margin: 10px auto 0;
  }

  .card-experience {
    left: 0;
  }

  .card-craft {
    right: 0;
  }

  .card-focus {
    right: 0;
  }

  .about-grid,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .contact-panel {
    padding-left: clamp(24px, 4vw, 40px);
  }

  .contact-art,
  .contact-side {
    display: none;
  }

  .process-steps {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .process-step {
    display: grid;
    grid-template-columns: 62px 1fr;
    column-gap: 18px;
    padding-bottom: 26px;
  }

  .process-step .icon-ring {
    grid-row: 1 / span 2;
    margin: 0;
  }

  /* Vertical connector on narrow screens. */
  .process-step:not(:last-child)::after {
    top: 66px;
    bottom: 0;
    left: 31px;
    right: auto;
    width: 1px;
    height: auto;
    background: linear-gradient(180deg, var(--rose-300), rgba(223, 182, 178, 0.15));
  }

  .site-footer {
    grid-template-columns: 1fr;
  }

  .pt-hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .pt-layers {
    grid-template-columns: 1fr;
    gap: 34px;
  }

  .pt-layer:not(:last-child)::after {
    content: "↓";
    top: auto;
    right: auto;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
  }
}

@media (max-width: 600px) {
  .section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-actions .button {
    flex: 1 1 100%;
  }

  .float-card {
    padding: 12px 14px;
  }

  .card-experience {
    width: 128px;
  }

  .card-craft {
    width: 130px;
  }

  .card-focus {
    display: none;
  }

  .services-intro {
    display: block;
  }

  .planet {
    display: none;
  }

  .services-list {
    grid-template-columns: 1fr;
  }

  .tool-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .experience {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .tab-list {
    flex-direction: row;
    overflow-x: auto;
    border-bottom: 1px solid var(--glass-border);
    border-left: 0;
  }

  .tab-list [role="tab"] {
    padding: 0 14px;
  }

  .tab-highlight {
    display: none;
  }

  .tab-list [role="tab"][aria-selected="true"] {
    box-shadow: inset 0 -2px 0 var(--accent);
  }

  .form-actions .button {
    flex: 1 1 100%;
  }
}

/* ---------- simulations: responsive ---------- */

@media (max-width: 1100px) {
  .lab-panels {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lab-panels > :last-child {
    grid-column: 1 / -1;
  }

  .skill-groups {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  /* The pipeline turns vertical: each node becomes a row, packets travel downwards. */
  .lab-pipeline {
    flex-direction: column;
    align-items: stretch;
  }

  .lab-node {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) auto;
    column-gap: 14px;
    align-items: center;
    text-align: left;
  }

  .lab-node .icon-ring {
    grid-row: 1 / span 2;
    margin: 0;
  }

  .lab-node-title { grid-column: 2; grid-row: 1; }
  .lab-node-sub { grid-column: 2; grid-row: 2; }

  .lab-node-stat {
    grid-column: 3;
    grid-row: 1 / span 2;
    margin: 0;
  }

  .lab-wire {
    flex: 0 0 22px;
    width: 1px;
    height: auto;
    margin-left: 40px;
    background: linear-gradient(180deg, var(--rose-300), rgba(223, 182, 178, 0.2));
  }

  .lab-packet {
    top: 0;
    left: 50%;
    margin: 0 0 0 -5px;
  }

  .lab-wire.is-flowing .lab-packet {
    animation-name: packet-y;
  }

  .demo-credit {
    grid-template-columns: 1fr;
  }

  .skill-groups {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .lab-panels,
  .skill-groups,
  .demo-steps {
    grid-template-columns: 1fr;
  }

  .device-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .test-lane {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .test-dots {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .hero-ticker {
    border-radius: var(--radius-small);
  }
}

/* ---------- personal: responsive ---------- */

@media (max-width: 860px) {
  .beyond-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .beyond-card-wide {
    display: flex;
  }

  .beyond-card-wide .photo-stack {
    margin: -22px -22px 18px;
  }

  .beyond-card-wide .photo-frame {
    aspect-ratio: 4 / 3;
    min-height: 0;
  }
}

@media (max-width: 600px) {
  .beyond-grid {
    grid-template-columns: 1fr;
  }

  .beyond-card-wide {
    grid-column: auto;
  }

  .release-note {
    font-size: 0.74rem;
  }
}

/* ---------- personal: hero cards below the photo on small screens ---------- */

@media (max-width: 1100px) {
  .hero-visual {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    aspect-ratio: auto;
  }

  .hero-photo {
    position: relative;
    grid-column: 1 / -1;
    aspect-ratio: 1 / 1.02;
  }

  .portrait-stack .portrait {
    width: 82%;
  }

  .hero-visual .float-card {
    position: static;
    width: auto;
    animation: none;
  }

  .hero-visual .card-focus {
    display: block;
    grid-column: 1 / -1;
  }

  .card-focus .bullet-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 16px;
  }

  .card-focus .bullet-list li + li {
    margin-top: 0;
  }
}
