/* Sea-glass clay: the Aero CLI page's claymorphic recipe with a teal, mint, ivory and deep-green palette. */
:root {
  color-scheme: light;
  --canvas: #e4efeb;
  --ink: #0d1a18;
  --muted: #46605a;
  --accent: #0f8f7c;
  --accent-deep: #0b6f61;
  --surface: #f1f7f4;
  --shadow: 12px 14px 28px #9cb8b070, -9px -9px 24px #ffffffb0, inset 2px 2px 3px #ffffffd9, inset -3px -3px 6px #a9c4bc40;
  font-family: ui-rounded, "SF Pro Rounded", "Avenir Next", system-ui, sans-serif;
  background: var(--canvas);
  color: var(--ink);
  font-synthesis: none;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 2rem; }
body { margin: 0; }
main { max-width: 1120px; margin: auto; padding: 28px 32px 40px; }
a { color: var(--accent-deep); text-underline-offset: 4px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible { outline: 3px solid var(--accent); outline-offset: 5px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 8px 0; }
.wordmark { color: var(--ink); font: 700 20px ui-monospace, "SFMono-Regular", monospace; text-decoration: none; }
nav { display: flex; align-items: center; gap: 24px; }
nav a { min-height: 44px; display: inline-flex; align-items: center; font-size: 15px; }
.hero { display: grid; grid-template-columns: 1.05fr 1fr; gap: 24px; align-items: center; padding: 48px 0 32px; }
h1 { font-size: clamp(44px, 6vw, 76px); line-height: 1.04; letter-spacing: -0.055em; margin: 0 0 24px; font-weight: 750; }
h2 { font-size: 30px; line-height: 1.25; letter-spacing: -0.035em; margin: 0 0 24px; }
h3 { font-size: 20px; letter-spacing: -0.025em; margin: 0 0 12px; }
p, li { font-size: 16px; line-height: 1.75; color: var(--muted); }
p { margin: 0 0 16px; }
p:last-child { margin-bottom: 0; }
.intro { font-size: 20px; line-height: 1.6; max-width: 480px; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 28px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 12px 24px; border-radius: 19px; background: var(--surface); box-shadow: var(--shadow); text-decoration: none; font-weight: 650; transition: transform 160ms ease; }
.button.primary { color: #fff; background: var(--accent); box-shadow: 7px 8px 17px #2a8a7850, inset 2px 2px 4px #5cc4b1, inset -3px -3px 5px #0a5c50; }
.button:hover { transform: translateY(-2px); text-decoration: none; }
.button:active { transform: translateY(1px); }
.scene-figure { margin: 0; min-width: 0; }
.scene-view { width: 100%; aspect-ratio: 1; position: relative; }
.scene-view img { display: block; width: 100%; height: auto; }
.warning { background: #f5c7c8; border-radius: 24px; box-shadow: 8px 10px 22px #be8e9850, inset 2px 2px 3px #ffe6e7, inset -3px -3px 5px #ce959b66; padding: 22px 28px; margin: 8px 0 64px; }
.warning strong { display: block; color: #842e38; margin-bottom: 4px; }
.warning p, .warning a { color: #75333c; }
.features { margin-bottom: 64px; }
.clay { padding: 28px; background: var(--surface); border-radius: 28px; box-shadow: var(--shadow); }
ul { padding-left: 19px; margin: 0; }
li + li { margin-top: 6px; }
.note { font-size: 15px; margin-top: 24px; }
code { font: 0.9em ui-monospace, "SFMono-Regular", Consolas, monospace; background: #d3e6df; border-radius: 6px; padding: 2px 5px; overflow-wrap: anywhere; color: var(--ink); }
.notices { padding: 36px; margin-bottom: 32px; }
.notices section + section { margin-top: 32px; padding-top: 28px; border-top: 1px solid #c6d9d2; }
.notices h2 { font-size: 23px; margin-bottom: 16px; }
footer { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding: 8px 4px; }
footer a { display: inline-flex; min-height: 44px; align-items: center; font-size: 15px; }
::selection { background: #a9dfd2; }

/* Bento grid */
.grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 20px; align-items: stretch; }
.bento { grid-column: span 2; position: relative; overflow: hidden; padding: 28px; display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.bento.discover, .bento.wallets { grid-column: span 4; display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 32px; }
.bento.discover .tile-copy, .bento.wallets .tile-copy { grid-column: 1; grid-row: 1; }
.bento.discover .tile-visual, .bento.wallets .tile-visual { grid-column: 2; }
.bento.agents { grid-column: span 6; display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 40px; }
.features article.discover { background: #d7ece5; }
.features article.reads { background: #e3eef7; }
.features article.execution { background: #f5f3e6; }
.features article.wallets { background: #c9e4dc; }
.features article.bridge { background: #dfe9f5; }
.features article.policy { background: #f2ece0; }
.features article.monitor { background: #dcefe9; }
.features article.agents { background: #0d1a18; color: #f0f8f5; }
.agents p { color: #c9dcd6; }
.agents code { color: #f0f8f5; background: none; }
.tile-copy > p { font-size: 16px; line-height: 1.55; }
.bento h3 { font-size: 25px; line-height: 1.15; margin-bottom: 12px; }
.tile-visual { min-height: 110px; display: flex; justify-content: center; align-items: center; }
.tile-visual svg { width: 100%; max-width: 240px; height: 100px; overflow: visible; }
.tile-visual svg path { fill: none; stroke: var(--accent); stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; }

/* Tile diagrams */
.schema-diagram { width: 100%; max-width: 300px; padding: 20px 22px; border-radius: 18px; background: #0d1a18; box-shadow: inset 2px 2px 8px #050c0b; display: grid; gap: 14px; }
.schema-diagram code { background: none; color: #f0f8f5; font-size: 16px; padding: 0; }
.schema-diagram code span { color: #5cc4b1; }
.schema-rows { display: grid; gap: 8px; }
.schema-rows i { display: block; height: 9px; width: var(--w); border-radius: 5px; background: #2f5a52; }
.schema-rows i:first-child { background: #5cc4b1; }
.blocks-diagram rect { fill: #a9cfe6; stroke: #4a86b0; stroke-width: 2; }
.blocks-diagram .link { stroke: #4a86b0 !important; stroke-width: 4; }
.pipeline { display: flex; align-items: center; flex-wrap: wrap; justify-content: center; gap: 6px; font: 600 12px ui-monospace, monospace; color: #4f4c3e; }
.pipeline span { padding: 8px 11px; border-radius: 11px; background: #ebe6d2; box-shadow: inset 2px 2px 3px #fffdf3, inset -2px -2px 3px #c9c2a566; }
.pipeline .hot { background: var(--accent); color: #fff; box-shadow: inset 2px 2px 3px #5cc4b1, inset -2px -2px 3px #0a5c50; }
.pipeline b { font-weight: 400; color: #8b8670; }
.wallet-chips { display: grid; gap: 10px; width: 100%; max-width: 280px; }
.wallet-chips span { padding: 12px 16px; border-radius: 14px; background: #f5f3e6; font: 13px ui-monospace, monospace; color: #2f4f47; box-shadow: 5px 6px 12px #4f7f7326, inset 2px 2px 3px #fff; transform: rotate(-3deg); }
.wallet-chips span:nth-child(2) { transform: rotate(2deg) translateX(14px); }
.wallet-chips span:nth-child(3) { transform: rotate(-1deg) translateX(-6px); }
.swap-diagram { display: flex; align-items: center; width: 100%; gap: 6px; }
.swap-diagram svg { width: 70px; flex: 1; }
.token { display: grid; place-items: center; width: 78px; height: 78px; flex: 0 0 78px; border-radius: 50%; font: 700 12px ui-monospace, monospace; text-align: center; box-shadow: 5px 7px 12px #3d5f7325, inset 3px 3px 4px #ffffffb0, inset -3px -4px 5px #5e86a835; }
.token-a { background: #9fc3ec; color: #1d3f66; }
.token-b { background: #f5f3e6; color: #535044; }
.budget { display: grid; gap: 6px; width: 100%; max-width: 260px; font: 12px ui-monospace, monospace; color: #6b5f45; }
.budget span + .bar { margin-bottom: 8px; }
.bar { height: 16px; border-radius: 8px; background: #e2d9c2; box-shadow: inset 2px 2px 3px #c9be9f66; overflow: hidden; }
.bar i { display: block; height: 100%; width: 72%; border-radius: 8px; background: var(--accent); }
.bar .reserved { width: 38%; background: #c9a35e; }
.chart-diagram .baseline { stroke: #9dc6b9; stroke-width: 2; }
.chart-diagram .chart-line { stroke: var(--accent); }
.chart-diagram .pulse { fill: var(--accent); }
.command-diagram { display: flex; align-items: center; gap: 12px; background: #142622; padding: 24px; border-radius: 16px; width: 100%; box-shadow: inset 2px 2px 8px #050c0b; }
.command-diagram code { font-size: 20px; padding: 0; }
.command-diagram code span { color: #5cc4b1; }
.command-diagram b { font-weight: 400; }
.command-cursor { width: 9px; height: 22px; background: #5cc4b1; }

/* Capability popups */
.capability-trigger { position: absolute; inset: 0; width: 100%; height: 100%; cursor: pointer; border: 0; padding: 0; border-radius: inherit; background: transparent; color: inherit; }
.capability-trigger:focus-visible, .popup-close:focus-visible { outline: 3px solid currentColor; outline-offset: 3px; border-radius: 5px; }
.capability-trigger:focus-visible { outline-offset: -4px; border-radius: inherit; }
.capability-popup { position: fixed; inset: auto; margin: 0; width: min(380px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow: auto; overscroll-behavior: contain; padding: 40px 26px 26px; border: 1px solid #bcd8cf; border-radius: 22px; background: var(--surface); color: var(--ink); box-shadow: 0 14px 42px #1f4a4235, inset 2px 2px 3px #ffffff; }
.capability-popup:popover-open { animation: popup-arrive 160ms cubic-bezier(.2,.8,.2,1); }
.capability-popup li, .agents .capability-popup li { font-size: 15px; line-height: 1.6; color: var(--muted); }
.capability-popup .note, .agents .capability-popup .note { font-size: 14px; margin-top: 16px; color: var(--muted); }
.capability-popup code, .agents .capability-popup code { color: var(--ink); background: #d3e6df; }
.popup-close { position: absolute; top: 0; right: 4px; width: 44px; height: 44px; border: 0; background: transparent; color: var(--muted); font-size: 24px; cursor: pointer; }
@keyframes popup-arrive { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }

/* JSON flow */
.demo { display: grid; grid-template-columns: 0.75fr 1.25fr; align-items: start; gap: 48px; margin: 0 0 64px; }
.demo-copy { padding-top: 24px; }
.terminal { min-width: 0; padding: 26px 28px; background: #0d1a18; color: #e6f2ee; overflow: auto; box-shadow: 12px 14px 28px #6e8f8670, -9px -9px 24px #ffffff90, inset 2px 2px 3px #2a4640, inset -3px -3px 6px #050c0b; }
.terminal pre { margin: 0; font: 14px/1.7 ui-monospace, "SFMono-Regular", Consolas, monospace; white-space: pre-wrap; overflow-wrap: anywhere; }
.terminal code { font: inherit; background: none; color: inherit; padding: 0; }
.terminal .prompt { color: #5cc4b1; }
.terminal .dim { color: #8fb3aa; }

/* Motion */
@media (prefers-reduced-motion: no-preference) {
  .bento.arriving { animation: tile-arrive 480ms cubic-bezier(.2,.8,.2,1) backwards; }
  .bento.arriving .tile-visual { animation: diagram-arrive 600ms cubic-bezier(.2,.8,.2,1) both; }
  .bento.arriving .chart-line { stroke-dasharray: 300; animation: chart-draw 900ms ease-out both; }
  .bento.arriving .schema-rows i { transform-origin: left; animation: weights-settle 700ms cubic-bezier(.2,.8,.2,1) both; }
  .bento.arriving .bar i { transform-origin: left; animation: weights-settle 800ms ease-out both; }
  .bento.arriving .blocks-diagram rect { animation: block-drop 520ms cubic-bezier(.2,.8,.2,1) both; }
  .bento.arriving .blocks-diagram rect:nth-of-type(2) { animation-delay: 90ms; }
  .bento.arriving .blocks-diagram rect:nth-of-type(3) { animation-delay: 180ms; }
  .chart-diagram .pulse { animation: pulse 2.2s ease-out infinite; transform-origin: 228px 14px; }
  .command-cursor { animation: blink 1.1s steps(2, end) infinite; }
  @media (hover: hover) {
    .bento { transition: transform 240ms cubic-bezier(.2,.8,.2,1); }
    .bento:hover { transform: translateY(-4px); }
    .bento .token, .bento .wallet-chips span, .pipeline .hot { transition: transform 240ms ease-out; }
    .bridge:hover .token-a { transform: translateX(5px) rotate(-7deg); }
    .bridge:hover .token-b { transform: translateX(-5px) rotate(7deg); }
    .wallets:hover .wallet-chips span { transform: none; }
    .execution:hover .pipeline .hot { transform: translateY(-3px); }
  }
}
@keyframes tile-arrive { from { opacity: 0; transform: translateY(22px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes diagram-arrive { from { transform: translateY(8px); } to { transform: none; } }
@keyframes chart-draw { from { stroke-dashoffset: 300; } to { stroke-dashoffset: 0; } }
@keyframes weights-settle { from { transform: scaleX(.3); } to { transform: scaleX(1); } }
@keyframes block-drop { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
@keyframes pulse { 0% { opacity: .9; transform: scale(1); } 70%, 100% { opacity: 0; transform: scale(3); } }
@keyframes blink { to { opacity: 0; } }

/* Layout breakpoints */
@media (max-width: 1000px) {
  .bento { padding: 24px; }
  .bento.discover, .bento.wallets { display: flex; gap: 22px; }
  .bento h3 { font-size: 23px; }
  .swap-diagram { max-width: 280px; }
}
@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
  .bento, .bento.discover, .bento.wallets { grid-column: span 1; }
  .bento.agents { grid-column: span 2; display: flex; gap: 22px; }
  .bento { padding: 22px; }
  .token { width: 60px; height: 60px; flex-basis: 60px; font-size: 10px; }
}
@media (max-width: 760px) {
  main { padding: 20px 24px 28px; }
  .hero { grid-template-columns: 1fr; gap: 0; padding-top: 40px; }
  .hero .intro { max-width: 540px; }
  .scene-figure { max-width: 440px; width: 100%; margin: 12px auto 0; }
  .demo { grid-template-columns: 1fr; gap: 24px; }
  .warning { margin-bottom: 48px; }
  .clay, .notices { padding: 24px; }
  .terminal { padding: 22px; }
  .terminal pre { font-size: 13px; }
  nav { gap: 16px; }
  h2 { font-size: 27px; }
}
@media (max-width: 540px) {
  .grid { grid-template-columns: minmax(0, 1fr); }
  .bento, .bento.discover, .bento.wallets, .bento.agents { grid-column: 1; }
  .bento { gap: 18px; padding: 26px; }
  .tile-visual { min-height: 100px; }
  .bento h3 { font-size: 25px; }
  .command-diagram code { font-size: 17px; }
}
@media (max-width: 380px) {
  main { padding-left: 16px; padding-right: 16px; }
  nav { gap: 12px; }
  .topbar { gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button { transition: none; }
  .capability-popup:popover-open { animation: none; }
}
