@import url("./motion.css");
@import url("https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&family=Playfair+Display:wght@600;700&display=swap");

:root {
  --hf-crimson: #8b0000;
  --hf-crimson-dark: #6b0f1a;
  --hf-metallic-accent: #111111;
  --hf-metallic-highlight: #767676;
  --hf-metallic-readable: #1a1a1a;
  --hf-metallic-glow: rgba(17, 17, 17, .2);
  --hf-frame-shadow:
    0 18px 42px rgba(26, 26, 26, .16),
    0 5px 14px rgba(26, 26, 26, .09);
  --hf-gold: var(--hf-metallic-accent);
  --hf-ivory: #fefefe;
  --hf-surface: #fafafa;
  --hf-muted-surface: #f5f5f5;
  --hf-border: #e5e5e5;
  --hf-card: #ffffff;
  --hf-soft-surface: #f7f4f0;
  --hf-dark-panel: #171717;
  --hf-dark-panel-raised: #202020;
  --hf-onyx: #1a1a1a;
  --hf-charcoal: #4a4a4a;
  --hf-muted: #737373;
  --content: 1180px;
  --hf-duration: var(--hf-motion-base);
  --hf-ease: var(--hf-ease-out);
  --hf-metallic-live-duration: 14s;
  --hf-metallic-shimmer-duration: 22s;
  --hf-metallic-live-ease: cubic-bezier(0.42, 0, 0.58, 1);
  --hf-blood-red: #6c0a16;
  --hf-cta-pill-bg: rgba(108, 10, 22, 0.75);
  --hf-cta-pill-text: #f5f5f3;
  --hf-cta-metallic-strong: #1a1a1a;
  --hf-quicksilver-gradient: linear-gradient(
    105deg,
    #242424 0%,
    #363636 14%,
    #4a4a4a 28%,
    #626262 42%,
    #858585 47%,
    #b0b0b0 49.5%,
    #6c0a16 50%,
    #b0b0b0 50.5%,
    #858585 53%,
    #626262 58%,
    #4a4a4a 72%,
    #363636 86%,
    #242424 100%
  );
  --hf-cta-text-gradient: var(--hf-quicksilver-gradient);
}

html { color-scheme: light; }
html[data-theme="dark"] {
  color-scheme: dark;
  --hf-crimson: #cf4f59;
  --hf-crimson-dark: #b83f49;
  --hf-ivory: #181818;
  --hf-surface: #101010;
  --hf-muted-surface: #202020;
  --hf-border: #363636;
  --hf-card: #1b1b1b;
  --hf-soft-surface: #22201e;
  --hf-dark-panel: #090909;
  --hf-dark-panel-raised: #161616;
  --hf-onyx: #f3f0eb;
  --hf-charcoal: #cbc7c0;
  --hf-muted: #aaa59d;
  --hf-metallic-accent: #050505;
  --hf-metallic-highlight: #d5d5d5;
  --hf-metallic-readable: #e7e7e7;
  --hf-metallic-glow: rgba(231, 231, 231, .3);
  --hf-frame-shadow:
    0 20px 48px rgba(0, 0, 0, .52),
    0 6px 16px rgba(0, 0, 0, .34),
    0 0 24px rgba(231, 231, 231, .045);
  --hf-cta-metallic-strong: #d0d0d0;
  --hf-cta-text-gradient: linear-gradient(
    105deg,
    #6a7280 0%,
    #8a92a0 18%,
    #c4cad6 38%,
    #eef1f6 48%,
    #ffffff 50%,
    #eef1f6 52%,
    #b8c0cc 62%,
    #8890a0 82%,
    #6a7280 100%
  );
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--hf-surface);
  color: var(--hf-onyx);
  font-family: "DM Sans", sans-serif;
  line-height: 1.65;
  transition:
    background var(--hf-duration) var(--hf-ease),
    color var(--hf-duration) var(--hf-ease);
}
a { color: var(--hf-crimson); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--hf-crimson);
  outline-offset: 3px;
}
.skip-link {
  position: fixed; top: 10px; left: 10px; z-index: 10;
  transform: translateY(-150%);
  background: var(--hf-ivory); padding: 10px 14px; border: 2px solid var(--hf-crimson);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  width: min(var(--content), calc(100% - 40px));
  margin: 0 auto;
  min-height: 112px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--hf-border);
}
.wordmark { color: var(--hf-onyx); font-size: 13px; font-weight: 700; letter-spacing: .15em; text-decoration: none; }
.wordmark-product { display: inline-flex; align-items: center; }
.site-logo { display: block; width: auto; height: 99px; max-width: min(405px, 55vw); }
nav { display: flex; align-items: center; gap: 24px; }
nav a {
  position: relative;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  color: var(--hf-charcoal);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  text-decoration: none;
  transition: color var(--hf-duration) var(--hf-ease);
}
nav a:hover, nav a[aria-current="page"] { color: var(--hf-crimson); }
.theme-toggle {
  width: 44px;
  height: 44px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 44px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--hf-charcoal);
  cursor: pointer;
  transition:
    color var(--hf-motion-slow) var(--hf-ease),
    background var(--hf-motion-slow) var(--hf-ease),
    transform var(--hf-motion-emphasis) var(--hf-ease-soft);
}
.theme-toggle:hover {
  color: var(--hf-crimson);
  transform: rotate(20deg);
}
.theme-toggle-icon {
  position: relative;
  width: 14px;
  height: 14px;
  display: inline-block;
}
.theme-toggle-icon svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transition:
    opacity var(--hf-motion-emphasis) var(--hf-ease),
    transform var(--hf-motion-emphasis) var(--hf-ease-soft);
}
.theme-toggle-sun { opacity: 0; transform: rotate(-90deg) scale(.6); }
.theme-toggle-moon { opacity: 1; transform: rotate(0) scale(1); }
html[data-theme="dark"] .theme-toggle-sun { opacity: 1; transform: rotate(0) scale(1); }
html[data-theme="dark"] .theme-toggle-moon { opacity: 0; transform: rotate(90deg) scale(.6); }

main, footer { width: min(var(--content), calc(100% - 40px)); margin-inline: auto; }
.hero {
  margin-top: 52px;
  padding: clamp(32px, 6vw, 76px);
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(220px, .5fr);
  align-items: start;
  gap: 48px;
  background: var(--hf-ivory);
}
.deco-frame {
  position: relative;
  border: 3px solid var(--hf-crimson);
  box-shadow:
    var(--hf-frame-shadow),
    inset 0 0 0 12px var(--hf-ivory),
    inset 0 0 0 13px var(--hf-border);
}
.deco-frame::before {
  content: "";
  position: absolute;
  inset: -3px;
  z-index: 1;
  padding: 3px;
  pointer-events: none;
  background: linear-gradient(
    115deg,
    var(--hf-crimson) 0%,
    var(--hf-crimson) 15%,
    var(--hf-metallic-accent) 25%,
    var(--hf-metallic-highlight) 29%,
    var(--hf-metallic-accent) 33%,
    var(--hf-crimson) 46%,
    var(--hf-crimson) 62%,
    var(--hf-metallic-accent) 72%,
    var(--hf-metallic-highlight) 76%,
    var(--hf-metallic-accent) 80%,
    var(--hf-crimson) 92%,
    var(--hf-crimson) 100%
  );
  background-size: 260% 260%;
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  mask-composite: exclude;
  filter: drop-shadow(0 1px 3px var(--hf-metallic-glow));
  animation:
    metallic-shimmer-flow var(--hf-metallic-shimmer-duration) ease-in-out infinite alternate,
    metallic-drift-bar var(--hf-metallic-live-duration) ease-in-out infinite alternate;
  animation-delay: 0s, -5.8s;
}
.hero-mark { align-self: start; margin-top: 24px; }
.hero-mark img { width: min(100%, 300px); height: auto; display: block; margin: auto; }
.eyebrow, .section-label, .stack {
  font-family: "JetBrains Mono", monospace; font-size: 11px; font-weight: 500; letter-spacing: .13em;
  color: var(--hf-crimson);
}
h1, h2, h3 { font-family: "Playfair Display", Georgia, serif; line-height: 1.14; margin: 0; }
h1 { font-size: clamp(34px, 4.8vw, 59px); max-width: 920px; }
h2 { font-size: clamp(32px, 4vw, 50px); }
h3 { font-size: 23px; }

.hero-metallic-title {
  color: var(--hf-onyx);
}

.hero-metallic-title .reveal-field {
  display: block;
  overflow: hidden;
  padding-bottom: 0.08em;
}

.hero-metallic-title .reveal-field-inner {
  display: block;
}

@supports ((background-clip: text) or (-webkit-background-clip: text)) {
  .hero-metallic-title .reveal-field-inner {
    background:
      linear-gradient(
        105deg,
        #080808 0%,
        #292929 28%,
        #0c0c0c 42%,
        #747474 50%,
        #111111 58%,
        #343434 78%,
        #080808 100%
      );
    background-size: 220% 100%;
    background-position: 0 0;
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: hero-metallic-sheen 2.4s var(--hf-ease-out) calc(500ms + var(--reveal-delay, 0ms)) 1 both;
  }

  html[data-theme="dark"] .hero-metallic-title .reveal-field-inner {
    background-image:
      linear-gradient(
        105deg,
        #d4d4d4 0%,
        #f4f4f4 32%,
        #9f9f9f 45%,
        #ffffff 50%,
        #bdbdbd 58%,
        #f0f0f0 100%
      );
  }
}

@supports ((background-clip: text) or (-webkit-background-clip: text)) {
  .hero-metallic-title {
    background: none;
    color: var(--hf-onyx);
    -webkit-text-fill-color: unset;
  }
}

@supports not ((background-clip: text) or (-webkit-background-clip: text)) {
  .hero-metallic-title .reveal-field-inner {
    color: var(--hf-onyx);
  }
}

@keyframes hero-metallic-sheen {
  from { background-position: 0 0; }
  to { background-position: 100% 0; }
}

.lede, .section-intro { color: var(--hf-charcoal); font-size: clamp(17px, 2vw, 20px); max-width: 800px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.button {
  min-height: 48px; padding: 12px 20px; border-radius: 8px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 600; text-decoration: none;
  transition:
    background var(--hf-duration) var(--hf-ease),
    color var(--hf-duration) var(--hf-ease),
    border-color var(--hf-duration) var(--hf-ease),
    box-shadow var(--hf-duration) var(--hf-ease),
    transform var(--hf-duration) var(--hf-ease);
}
.button:hover { transform: translateY(-1px); }
.button-primary { background: var(--hf-crimson); border: 2px solid var(--hf-crimson); color: white; }
.button-primary:hover { background: var(--hf-crimson-dark); box-shadow: 0 5px 16px rgba(139, 0, 0, .16); }
.button-secondary { background: var(--hf-ivory); border: 2px solid var(--hf-crimson); color: var(--hf-crimson); }
.button.is-disabled { cursor: not-allowed; opacity: .55; transform: none; }
.demo-link span {
  transition: transform var(--hf-duration) var(--hf-ease);
}
.demo-link:hover span { transform: translate(1px, -1px); }
.demo-status, .fine-print { color: var(--hf-muted); font-size: 13px; }
.deco-divider { height: 86px; display: grid; place-items: center; }
.deco-divider::before { content: ""; width: 100%; height: 1px; background: var(--hf-border); }
.deco-divider span {
  position: absolute;
  width: 12px;
  height: 12px;
  background: linear-gradient(
    135deg,
    var(--hf-metallic-accent) 0%,
    var(--hf-metallic-highlight) 25%,
    var(--hf-metallic-accent) 50%,
    var(--hf-metallic-accent) 50%,
    var(--hf-metallic-highlight) 75%,
    var(--hf-metallic-accent) 100%
  );
  background-size: 200% 200%;
  box-shadow: 0 2px 7px var(--hf-metallic-glow);
  transform: rotate(45deg);
  animation:
    metallic-shimmer-diamond var(--hf-metallic-shimmer-duration) ease-in-out infinite alternate,
    metallic-drift-diamond var(--hf-metallic-live-duration) ease-in-out infinite alternate;
  animation-delay: 0s, -11.4s;
}

.section { padding: clamp(58px, 8vw, 100px) clamp(0px, 3vw, 38px); }
.split { display: grid; grid-template-columns: .8fr 1.2fr; column-gap: 80px; row-gap: 40px; }
.prose { color: var(--hf-charcoal); font-size: 18px; }
.problem-infographic {
  grid-column: 1 / -1;
  margin-top: 4px;
  padding: clamp(22px, 4vw, 38px);
  display: grid;
  gap: 12px;
  border: 1px solid var(--hf-border);
  border-radius: 14px;
  background: var(--hf-ivory);
}
.problem-map-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
}
.problem-map-card {
  min-height: 78px;
  padding: 15px 18px;
  display: grid;
  align-content: center;
  gap: 4px;
  border-left: 3px solid var(--hf-border);
  background: var(--hf-muted-surface);
}
.problem-map-card span,
.feature-taxonomy span,
.safety-boundary article > span {
  color: var(--hf-muted);
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  letter-spacing: .12em;
}
.problem-map-card b { font-size: 14px; font-weight: 600; }
.problem-map-response { border-left-color: var(--hf-crimson); background: var(--hf-card); }
.problem-map-response span { color: var(--hf-crimson); }
.problem-map-arrow {
  color: var(--hf-metallic-readable);
  font-family: "JetBrains Mono", monospace;
  text-align: center;
}
.surface { background: var(--hf-ivory); border: 1px solid var(--hf-border); padding-inline: clamp(24px, 6vw, 72px); }
.feature-taxonomy {
  margin-top: 38px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--hf-border);
  border-radius: 12px;
  overflow: hidden;
}
.feature-taxonomy div {
  min-height: 96px;
  padding: 18px 20px;
  display: grid;
  align-content: center;
  gap: 2px;
  background: var(--hf-muted-surface);
  border-top: 3px solid var(--hf-border);
}
.feature-taxonomy div + div { border-left: 1px solid var(--hf-border); }
.feature-taxonomy b { font-family: "Playfair Display", Georgia, serif; font-size: 18px; }
.feature-taxonomy small { color: var(--hf-muted); }
.feature-taxonomy [data-band="daily"] { border-top-color: var(--hf-crimson); }
.feature-taxonomy [data-band="safety"] { border-top-color: var(--hf-charcoal); }
.feature-taxonomy [data-band="intelligence"] {
  border-top-color: var(--hf-metallic-accent);
  animation: metallic-edge-live var(--hf-metallic-live-duration) ease-in-out infinite alternate;
  animation-delay: -3.6s;
}
.feature-grid { margin-top: 44px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature-grid article {
  min-height: 210px;
  padding: 26px;
  border: 1px solid var(--hf-border);
  border-top: 3px solid var(--hf-border);
  border-radius: 12px;
  background: var(--hf-card);
  transition:
    border-color var(--hf-duration) var(--hf-ease),
    box-shadow var(--hf-duration) var(--hf-ease),
    background var(--hf-duration) var(--hf-ease);
}
.feature-grid article[data-band="daily"] { border-top-color: var(--hf-crimson); }
.feature-grid article[data-band="safety"] { border-top-color: var(--hf-charcoal); }
.feature-grid article[data-band="intelligence"] {
  border-top-color: var(--hf-metallic-accent);
  animation: metallic-edge-live var(--hf-metallic-live-duration) ease-in-out infinite alternate;
}

.feature-grid article[data-band="intelligence"]:nth-child(3) { animation-delay: -2.1s; }
.feature-grid article[data-band="intelligence"]:nth-child(6) { animation-delay: -7.9s; }
.feature-grid article[data-band="intelligence"]:nth-child(8) { animation-delay: -12.3s; }
.feature-grid article > span { color: var(--hf-crimson); font-family: "JetBrains Mono", monospace; font-size: 10px; letter-spacing: .12em; }
.feature-grid p { color: var(--hf-charcoal); margin-bottom: 0; }

.live-demo { display: grid; grid-template-columns: 1.4fr .6fr; gap: 40px; align-items: center; border-bottom: 1px solid var(--hf-border); }
.architecture {
  margin-top: 42px;
  padding: clamp(24px, 4vw, 44px) clamp(16px, 3vw, 28px) clamp(28px, 5vw, 44px);
  background: var(--hf-dark-panel);
  border-radius: 14px;
  color: white;
  overflow-x: visible;
}
.architecture-flow {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: clamp(6px, 1vw, 12px);
}
.flow-item { flex: 0 0 auto; }
.flow-arrow {
  flex: 0 0 auto;
  color: var(--hf-metallic-readable);
  font-family: "JetBrains Mono", monospace;
  font-size: 14px;
  line-height: 1;
}
.flow-arrow::before { content: "→"; }
.node {
  display: block;
  border: 1px solid #4a4a4a;
  border-radius: 8px;
  padding: 14px clamp(9px, 1.2vw, 16px);
  font-family: "JetBrains Mono", monospace;
  font-size: clamp(10px, 1.6vw, 11px);
  text-align: center;
  white-space: nowrap;
}
.node-accent {
  border-color: var(--hf-metallic-accent);
  color: #e5e5e5;
  box-shadow: 0 0 0 1px var(--hf-metallic-highlight);
  animation: metallic-drift-node var(--hf-metallic-live-duration) ease-in-out infinite alternate;
}

.architecture-flow .node-accent:first-of-type { animation-delay: -4.2s; }
.architecture-flow .node-accent:last-of-type { animation-delay: -10.7s; }
.architecture-state {
  width: 72%;
  max-width: 100%;
  margin: 28px auto 0;
  padding: 12px 18px;
  border-top: 2px solid var(--hf-crimson);
  font-family: "JetBrains Mono", monospace;
  color: #d4d4d4;
  font-size: 10px;
  text-align: center;
}
.architecture-state span {
  display: block;
  margin-bottom: 4px;
  color: var(--hf-metallic-readable);
  letter-spacing: .12em;
}
.architecture-state b {
  font-weight: 400;
}
.architecture-layers {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.architecture-layers div {
  padding: 13px 16px;
  border: 1px solid #3f3f3f;
  border-radius: 8px;
  background: var(--hf-dark-panel-raised);
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  line-height: 1.6;
  text-align: center;
}
.architecture-layers span {
  display: block;
  color: var(--hf-metallic-readable);
  letter-spacing: .12em;
}
.architecture-layers b {
  color: #c8c8c8;
  font-weight: 400;
}
.stack { margin-top: 18px; color: var(--hf-muted); }
.trust-grid { display: grid; grid-template-columns: .65fr 1.35fr; gap: clamp(36px, 7vw, 80px); }
.safety-boundary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.safety-boundary article {
  padding: 24px;
  border: 1px solid var(--hf-border);
  border-top: 3px solid var(--hf-charcoal);
  border-radius: 12px;
  background: var(--hf-ivory);
}
.safety-boundary article:first-child { border-top-color: var(--hf-crimson); }
.safety-boundary article:first-child > span { color: var(--hf-crimson); }
.safety-boundary .safety-limit > span { color: var(--hf-charcoal); }
.safety-boundary h3 { margin-top: 10px; font-size: 21px; }
.safety-boundary ul { margin: 18px 0 0; padding-left: 20px; color: var(--hf-charcoal); }
.safety-boundary li { margin-bottom: 12px; padding-left: 4px; }
.safety-boundary li::marker { color: var(--hf-crimson); }
.engineering-grid { margin-top: 40px; border-top: 1px solid var(--hf-border); }
.engineering-grid div {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 20px;
  padding: 20px 12px;
  border-bottom: 1px solid var(--hf-border);
  transition: background var(--hf-duration) var(--hf-ease);
}
.engineering-grid strong { color: var(--hf-crimson); font-family: "JetBrains Mono", monospace; font-size: 12px; }
.demo-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  margin-top: 40px;
}
.demo-shot {
  overflow: hidden;
  border: 1px solid var(--hf-border);
  border-radius: 12px;
  background: var(--hf-ivory);
  transition:
    border-color var(--hf-duration) var(--hf-ease),
    box-shadow var(--hf-duration) var(--hf-ease);
}
.demo-shot-featured { grid-column: 1 / -1; }
.demo-video,
.demo-screenshot {
  display: block;
  width: 100%;
  height: auto;
  vertical-align: top;
  background: var(--hf-card);
}
.demo-video { background: #000; }
.demo-screenshot { border-top: 1px solid var(--hf-border); }
.demo-window { background: var(--hf-soft-surface); }
.demo-window-bar {
  min-height: 38px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--hf-dark-panel);
  color: #d4d4d4;
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  letter-spacing: .1em;
}
.demo-window-bar i { width: 7px; height: 7px; border-radius: 50%; background: #555; }
.demo-window-bar i:first-child { background: var(--hf-crimson); }
.demo-window-bar span { margin-left: 7px; }
.chat-preview {
  min-height: 310px;
  padding: 24px;
  display: grid;
  grid-template-columns: minmax(150px, .32fr) minmax(0, 1fr);
  gap: 22px;
}
.preview-sidebar {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-right: 1px solid var(--hf-border);
  color: var(--hf-charcoal);
  font-size: 12px;
}
.preview-sidebar strong { color: var(--hf-crimson); }
.preview-chat { display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.preview-bubble { max-width: 72%; margin: 0; padding: 13px 16px; border-radius: 12px; font-size: 13px; }
.preview-bubble-user { align-self: flex-end; background: var(--hf-crimson); color: white; }
.preview-bubble-assistant { background: var(--hf-card); border: 1px solid var(--hf-border); }
.preview-prompts { display: flex; flex-wrap: wrap; gap: 8px; }
.preview-prompts span { padding: 7px 10px; border: 1px solid #d7c89a; border-radius: 99px; background: var(--hf-card); font-size: 10px; }
.routine-preview { min-height: 210px; padding: 24px; display: grid; align-content: center; gap: 12px; }
.routine-preview div {
  padding: 14px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3px 12px;
  align-items: center;
  background: var(--hf-card);
  border: 1px solid var(--hf-border);
  border-radius: 9px;
}
.routine-preview small { color: var(--hf-muted); }
.routine-preview button { grid-column: 2; grid-row: 1 / 3; padding: 8px 10px; border: 1px solid var(--hf-crimson); border-radius: 7px; background: var(--hf-card); color: var(--hf-crimson); }
.appointment-preview { min-height: 210px; padding: 32px; display: flex; align-items: center; justify-content: center; gap: 20px; }
.appointment-preview time { padding: 12px 16px; border: 2px solid var(--hf-crimson); color: var(--hf-crimson); font: 700 24px/1 "Playfair Display", serif; text-align: center; }
.appointment-preview time small { font: 500 9px/1 "JetBrains Mono", monospace; letter-spacing: .12em; }
.appointment-preview div { display: grid; gap: 6px; }
.appointment-preview span, .appointment-preview p { margin: 0; color: var(--hf-muted); font-size: 12px; }
.demo-caption {
  padding: 24px;
  border-top: 2px solid transparent;
  transition: border-color var(--hf-duration) var(--hf-ease);
}
.demo-caption > span {
  color: var(--hf-metallic-readable);
  font-family: "JetBrains Mono", monospace;
  font-size: 10px;
  letter-spacing: .12em;
}
.demo-caption h3 { margin-top: 8px; }
.demo-caption p { margin-bottom: 0; color: var(--hf-charcoal); }
.role-fit { border-top: 3px solid var(--hf-crimson); }
.role-fit h2 { max-width: 900px; }
.role-fit p { max-width: 780px; color: var(--hf-charcoal); font-size: 18px; }
.role-fit p a { text-decoration: none; }

.cta-pill {
  --cta-pill-width: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  margin-top: 8px;
  padding: 14px 22px;
  border-radius: 28px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--hf-cta-pill-text);
  text-decoration: none;
  font-family: "DM Sans", sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transition:
    color var(--hf-duration) var(--hf-ease),
    border-color var(--hf-duration) var(--hf-ease),
    box-shadow var(--hf-duration) var(--hf-ease),
    transform var(--hf-duration) var(--hf-ease);
  box-shadow: none;
}

.cta-pill::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: var(--cta-pill-width);
  height: 100%;
  border-radius: 28px;
  background:
    linear-gradient(
      90deg,
      transparent 0%,
      rgba(255, 255, 255, 0.04) 25%,
      rgba(255, 255, 255, 0.1) 50%,
      rgba(255, 255, 255, 0.04) 75%,
      transparent 100%
    ),
    var(--hf-cta-pill-bg);
  background-size: 200% 100%, 100% 100%;
  background-repeat: no-repeat;
  animation: cta-pill-shimmer 3.2s ease-in-out infinite;
  box-shadow: none;
  transition: width 0.3s ease, background 0.3s ease;
  pointer-events: none;
  z-index: 0;
}

.cta-pill:hover {
  color: #fff;
  border-color: transparent;
  box-shadow: none;
}

.cta-pill:hover::before {
  width: 100%;
  background:
    linear-gradient(
      90deg,
      transparent 0%,
      rgba(255, 255, 255, 0.04) 25%,
      rgba(255, 255, 255, 0.1) 50%,
      rgba(255, 255, 255, 0.04) 75%,
      transparent 100%
    ),
    var(--hf-blood-red);
  background-size: 200% 100%, 100% 100%;
  background-repeat: no-repeat;
  box-shadow: none;
  animation: cta-pill-shimmer-fast 1.4s ease-in-out infinite;
}

.cta-pill:focus-visible {
  outline: 2px solid var(--hf-blood-red);
  outline-offset: 3px;
}

.cta-pill:active { transform: scale(0.96); }

@supports ((background-clip: text) or (-webkit-background-clip: text)) {
  .cta-pill-text {
    display: inline-block;
    position: relative;
    z-index: 2;
    -webkit-font-smoothing: antialiased;
    background-image: var(--hf-cta-text-gradient);
    background-size: 280% 100%;
    background-repeat: no-repeat;
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: cta-quicksilver 3.8s ease-in-out infinite;
    transition: color 0.25s ease, -webkit-text-fill-color 0.25s ease;
  }

  .cta-pill:hover .cta-pill-text {
    animation: none;
    background: none;
    background-image: none;
    -webkit-background-clip: border-box;
    background-clip: border-box;
    -webkit-text-fill-color: #fff;
    color: #fff;
  }
}

@supports not ((background-clip: text) or (-webkit-background-clip: text)) {
  .cta-pill-text {
    position: relative;
    z-index: 2;
    color: var(--hf-cta-metallic-strong);
  }

  .cta-pill:hover .cta-pill-text {
    color: #fff;
  }
}

.cta-pill-icon {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  transform: translateX(-5px);
  transition: transform 0.3s ease;
}

.cta-pill-icon-base,
.cta-pill-icon-shimmer {
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cta-pill-icon-base {
  stroke: currentColor;
  transition: opacity 0.25s ease;
}

.cta-pill-icon-shimmer {
  stroke: url(#roleFitCtaArrowQuicksilver);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.cta-pill:hover .cta-pill-icon { transform: translateX(0); }
.cta-pill:hover .cta-pill-icon-base { opacity: 0; }
.cta-pill:hover .cta-pill-icon-shimmer { opacity: 1; }

html[data-theme="light"] .cta-pill:hover .cta-pill-icon-shimmer {
  filter: brightness(0.55) contrast(1.15);
}

@keyframes cta-pill-shimmer {
  0% { background-position: -100% 0, 0 0; }
  50%, 100% { background-position: 200% 0, 0 0; }
}

@keyframes cta-pill-shimmer-fast {
  0% { background-position: -100% 0, 0 0; }
  100% { background-position: 200% 0, 0 0; }
}

@keyframes cta-quicksilver {
  0% { background-position: 100% 50%; }
  50% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}

@media (prefers-reduced-motion: reduce) {
  .cta-pill::before,
  .cta-pill-text { animation: none !important; }

  .cta-pill::before,
  .cta-pill-icon { transition: none !important; }

  @supports ((background-clip: text) or (-webkit-background-clip: text)) {
    .cta-pill-text {
      background-position: 50% 50%;
      -webkit-text-fill-color: var(--hf-cta-metallic-strong);
      color: var(--hf-cta-metallic-strong);
    }
  }

  .cta-pill:hover::before { width: 100%; animation: none !important; }
  .cta-pill:hover .cta-pill-icon { transform: translateX(0); }
  .cta-pill:hover .cta-pill-icon-base {
    opacity: 1;
    stroke: var(--hf-cta-metallic-strong);
  }
  .cta-pill:hover .cta-pill-icon-shimmer { opacity: 0; }
  .cta-pill:hover .cta-pill-text {
    -webkit-text-fill-color: #fff;
    color: #fff;
  }
}
footer { padding: 40px 0 64px; border-top: 1px solid var(--hf-border); color: var(--hf-charcoal); text-align: center; }
footer a { text-decoration: none; }
footer p { margin: 8px 0; }

@keyframes metallic-shimmer-flow {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

@keyframes metallic-shimmer-diamond {
  0%, 100% { background-position: 0% 0%; }
  50% { background-position: 100% 100%; }
}

@keyframes metallic-drift-bar {
  0%, 100% {
    transform: translate(0, 0);
    box-shadow: 0 1px 8px -4px color-mix(in srgb, var(--hf-metallic-glow) 40%, transparent);
  }
  18% {
    transform: translate(0.24px, -0.11px);
    box-shadow: 0 2px 10px -3px color-mix(in srgb, var(--hf-metallic-glow) 62%, transparent);
  }
  42% {
    transform: translate(-0.2px, 0.14px);
    box-shadow: 0 3px 12px -3px var(--hf-metallic-glow);
  }
  68% {
    transform: translate(0.28px, 0.05px);
    box-shadow: 0 2px 11px -3px color-mix(in srgb, var(--hf-metallic-glow) 55%, transparent);
  }
}

@keyframes metallic-drift-diamond {
  0%, 100% {
    transform: rotate(45deg) translate(0, 0);
    box-shadow: 0 2px 7px color-mix(in srgb, var(--hf-metallic-glow) 40%, transparent);
  }
  20% {
    transform: rotate(45deg) translate(-0.2px, 0.13px);
    box-shadow: 0 3px 10px -2px color-mix(in srgb, var(--hf-metallic-glow) 58%, transparent);
  }
  46% {
    transform: rotate(45deg) translate(0.26px, -0.08px);
    box-shadow: 0 4px 12px -2px var(--hf-metallic-glow);
  }
  72% {
    transform: rotate(45deg) translate(-0.14px, -0.12px);
    box-shadow: 0 2px 9px -3px color-mix(in srgb, var(--hf-metallic-glow) 52%, transparent);
  }
}

@keyframes metallic-edge-live {
  0%, 100% {
    border-top-color: var(--hf-metallic-accent);
    box-shadow: 0 0 0 0 transparent;
  }
  38% {
    border-top-color: color-mix(in srgb, var(--hf-metallic-accent) 52%, var(--hf-metallic-highlight));
    box-shadow: 0 4px 13px -11px color-mix(in srgb, var(--hf-metallic-glow) 48%, transparent);
  }
  62% {
    border-top-color: var(--hf-metallic-highlight);
    box-shadow: 0 6px 16px -10px var(--hf-metallic-glow);
  }
}

@keyframes metallic-drift-node {
  0%, 100% {
    transform: translate(0, 0);
    box-shadow:
      0 0 0 1px var(--hf-metallic-highlight),
      0 0 0 0 transparent;
  }
  21% {
    transform: translate(0.24px, -0.11px);
    box-shadow:
      0 0 0 1px var(--hf-metallic-highlight),
      0 3px 12px -5px color-mix(in srgb, var(--hf-metallic-glow) 52%, transparent);
  }
  47% {
    transform: translate(-0.18px, 0.15px);
    box-shadow:
      0 0 0 1px var(--hf-metallic-highlight),
      0 5px 15px -4px var(--hf-metallic-glow);
  }
  73% {
    transform: translate(0.16px, -0.07px);
    box-shadow:
      0 0 0 1px var(--hf-metallic-highlight),
      0 3px 11px -5px color-mix(in srgb, var(--hf-metallic-glow) 58%, transparent);
  }
}

.motion-ready [data-reveal-style] {
  transition:
    opacity var(--hf-motion-slow) var(--hf-ease-out),
    transform var(--hf-motion-slow) var(--hf-ease-out),
    clip-path var(--hf-motion-slow) var(--hf-ease-out),
    filter var(--hf-motion-slow) var(--hf-ease-out);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: transform, opacity;
}

.motion-ready [data-reveal-style="cascade"] {
  opacity: 0;
  transform: translateY(calc(var(--hf-rise-md) * -1.4));
  clip-path: inset(0 0 100% 0);
}

.motion-ready [data-reveal-style="ledger"] {
  opacity: 0;
  transform: translateX(calc(var(--hf-rise-md) * -2.2));
  clip-path: inset(0 100% 0 0);
}

.motion-ready [data-reveal-style="bloom"] {
  opacity: 0;
  transform: scale(0.965);
  filter: blur(4px);
  clip-path: none;
}

.motion-ready [data-reveal-style="settle"] {
  opacity: 0;
  transform: translateY(calc(var(--hf-rise-md) * 1.35));
  clip-path: none;
}

.motion-ready [data-reveal].is-visible[data-reveal-style],
.motion-ready [data-reveal-stagger].is-visible > *:not([data-reveal-lines])[data-reveal-style],
.motion-ready [data-reveal-stagger].is-visible .reveal-field-inner[data-reveal-style],
.motion-ready [data-reveal-group].is-visible > [data-reveal-style] {
  opacity: 1;
  transform: none;
  clip-path: inset(0 0 0 0);
  filter: none;
}

.motion-ready .hero-mark[data-reveal] { transition-delay: calc(var(--hf-stagger-step) * 5); }

.reveal-field {
  display: block;
  overflow: hidden;
}

.reveal-field-inner {
  display: block;
}

.motion-ready [data-reveal-group] > [data-reveal-style] {
  transition-delay: var(--reveal-delay, 0ms);
}

@media (hover: hover) and (pointer: fine) {
  .demo-shot:hover {
    border-color: rgba(139, 0, 0, .35);
    box-shadow: 0 10px 28px rgba(26, 26, 26, .07);
  }
  .demo-shot:hover .demo-caption {
    border-top-color: var(--hf-metallic-accent);
    box-shadow: 0 -3px 9px -6px var(--hf-metallic-glow);
  }
  .feature-grid article:hover {
    border-right-color: rgba(139, 0, 0, .3);
    border-bottom-color: rgba(139, 0, 0, .3);
    border-left-color: rgba(139, 0, 0, .3);
    background: var(--hf-ivory);
    box-shadow: 0 8px 22px rgba(26, 26, 26, .055);
  }
  .engineering-grid div:hover { background: var(--hf-muted-surface); }
}

@media (max-width: 980px) {
  .architecture-flow {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .flow-arrow { align-self: center; }
  .flow-arrow::before { content: "↓"; }
  .node {
    width: 100%;
    white-space: normal;
    font-size: 11px;
  }
  .architecture-state { margin-top: 22px; }
  .architecture-layers { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
  .site-header { align-items: flex-start; flex-direction: column; padding: 18px 0; gap: 12px; }
  nav { width: 100%; flex-wrap: wrap; gap: 8px 16px; }
  nav a { display: inline-flex; min-height: 32px; align-items: center; }
  main, footer { width: min(var(--content), calc(100% - 28px)); }
  .hero {
    margin-top: 28px;
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 26px 22px 30px;
  }
  .deco-frame {
    box-shadow:
      var(--hf-frame-shadow),
      inset 0 0 0 7px var(--hf-ivory),
      inset 0 0 0 8px var(--hf-border);
  }
  .hero-mark { order: -1; margin-top: 0; }
  .hero-mark img { width: 161px; }
  .eyebrow { font-size: 9px; line-height: 1.6; }
  h1 { font-size: clamp(27px, 8vw, 34px); }
  .lede, .section-intro { font-size: 16px; }
  .hero-actions { margin-top: 22px; }
  .hero-actions .button { width: 100%; }
  .split, .live-demo, .trust-grid { grid-template-columns: 1fr; gap: 24px; }
  .problem-map-row { grid-template-columns: 1fr; gap: 8px; }
  .problem-map-arrow { transform: rotate(90deg); }
  .feature-taxonomy { grid-template-columns: 1fr; }
  .feature-taxonomy div + div { border-left: 0; border-top-width: 3px; }
  .feature-grid, .demo-gallery { grid-template-columns: 1fr; }
  .demo-shot-featured { grid-column: auto; }
  .feature-grid article { min-height: auto; }
  .chat-preview { min-height: 280px; grid-template-columns: 1fr; padding: 16px; }
  .preview-sidebar { display: none; }
  .preview-bubble { max-width: 88%; }
  .routine-preview, .appointment-preview { min-height: 190px; padding: 18px; }
  .safety-boundary { grid-template-columns: 1fr; }
  .engineering-grid div { grid-template-columns: 1fr; gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    transition-delay: 0ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
  .button:hover,
  .theme-toggle:hover,
  .demo-link:hover span,
  .problem-map-arrow,
  [data-reveal],
  [data-reveal-group] > *,
  [data-reveal-stagger] > *,
  [data-reveal-stagger] .reveal-field-inner,
  [data-reveal-style],
  .deco-frame::before,
  .deco-divider span,
  .hero-metallic-title,
  .hero-metallic-title .reveal-field-inner,
  .node-accent,
  .feature-taxonomy [data-band="intelligence"],
  .feature-grid article[data-band="intelligence"] {
    opacity: 1 !important;
    transform: none !important;
    clip-path: none !important;
    filter: none !important;
    text-shadow: none !important;
    box-shadow: none !important;
    animation: none !important;
  }

  .deco-divider span {
    transform: rotate(45deg) !important;
  }
}
