/* The agent pages (src/layouts/Agent.astro): problem first, and mostly pictures rather than paragraphs.
   Same vocabulary as shell.css: Clash Display headings, Figtree text, #E4E9F5 hairlines, periwinkle
   #536ee5 for the agent's side. No hover scale or grow anywhere; hover is color, border or shadow. */

/* ---- the hero sits close to the demo, so the demo starts high on a laptop screen ---- */
.ag-hero .la-h1 { max-width: 920px; }
.ag-page .la-hero-sec > .w-container { padding-bottom: 36px !important; }
.ag-page .la-hero-sec + .ld-solo > .container { padding-top: 12px !important; }
.ag-page .ag-sec > .w-container { padding-top: 56px !important; padding-bottom: 56px !important; }
.ag-page .ag-sec.is-tight > .w-container { padding-top: 8px !important; }
.ag-sec .section-wrapper { gap: 40px; }
.ag-sec .la-h2 { font-size: 40px; }

/* ---- what it takes off your plate ---- */
.ag-handles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.ag-handle { display: flex; flex-direction: column; gap: 10px; padding: 24px 22px 26px; border: 1px solid #E4E9F5; border-radius: 20px; background: #fff; text-align: left; }
.ag-handle-ic { width: 52px; height: 52px; margin-bottom: 8px; border-radius: 15px; display: inline-flex; align-items: center; justify-content: center; background: #EEF1FD; color: #536ee5; }
.ag-handle-ic svg { width: 28px; height: 28px; }
.ag-handle-t { margin: 0; font-family: var(--brand-font-heading); font-size: 19px; line-height: 1.2; font-weight: 600; color: #232323; text-align: left; }
.ag-handle-p { margin: 0; font-size: 15px; line-height: 1.55; color: #585858; }

/* ---- what it reads, the agent, and what you get; then what it never does ---- */
.ag-wire { display: grid; grid-template-columns: minmax(0, 1fr) minmax(250px, 330px) minmax(0, 1fr); align-items: center; row-gap: 12px; }
/* the two labels sit in a row of their own over the columns, so they line up; in one column each sits on its own list */
.ag-wire > .is-top { align-self: end; }
.ag-wire-h.is-inline { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.ag-wire-col { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.ag-wire-h { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: .08em !important; text-transform: uppercase; color: #536ee5; text-align: left; }
.ag-nodes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.ag-node { display: flex; align-items: center; gap: 14px; padding: 14px 18px 14px 14px; border: 1px solid #E4E9F5; border-radius: 16px; background: #fff; box-shadow: 0 12px 26px -22px rgba(35, 42, 80, .4); text-align: left; }
.ag-node-ic { width: 44px; height: 44px; flex: none; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: #F1F3FA; color: #4B5563; }
.ag-node-ic svg { width: 24px; height: 24px; }
.ag-node.is-out { border-color: #C9D3F7; }
.ag-node.is-out .ag-node-ic { background: #EEF1FD; color: #536ee5; }
.ag-node-t { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ag-node-t b { font-size: 16px; font-weight: 600; line-height: 1.3; color: #232323; }
.ag-node-t small { font-size: 13.5px; line-height: 1.35; color: #6B7280; }
.ag-wire-mid { display: flex; align-items: center; min-width: 0; }
/* the dotted wire, with one dot carrying the work across */
.ag-flow { position: relative; flex: 1; min-width: 28px; height: 2px; background: repeating-linear-gradient(90deg, #BCC6E6 0 6px, transparent 6px 12px); }
.ag-flow i { position: absolute; top: 50%; left: 0; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: #536ee5; box-shadow: 0 0 0 4px rgba(83, 110, 229, .16); animation: agFlow 2.4s cubic-bezier(.45, 0, .55, 1) infinite; }
.ag-core + .ag-flow i { animation-delay: 1.2s; }
@keyframes agFlow { 0% { left: 0; opacity: 0; } 15%, 85% { opacity: 1; } 100% { left: calc(100% - 8px); opacity: 0; } }
.ag-core { flex: none; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px 22px 18px; border: 1.5px solid #536ee5; border-radius: 22px; background: linear-gradient(180deg, #fff, #F5F7FF); box-shadow: 0 26px 50px -30px rgba(83, 110, 229, .7); text-align: center; }
.ag-core-face { width: 76px; height: 76px; margin-bottom: 8px; border-radius: 50%; overflow: hidden; background: #fff; box-shadow: 0 0 0 3px #fff, 0 0 0 5px #536ee5; }
.ag-core-face img { width: 100%; height: 100%; max-width: none; object-fit: cover; display: block; }
.ag-core b { font-family: var(--brand-font-heading); font-size: 18px; font-weight: 600; line-height: 1.2; color: #232323; }
.ag-core small { font-size: 13px; font-weight: 600; color: #1B44C8; }

.ag-rules { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 16px; }
.ag-never { display: flex; flex-direction: column; justify-content: center; padding: 20px 22px 22px; border: 1px solid #F3DCCF; border-radius: 18px; background: #FFFAF7; text-align: left; }
.ag-never .ag-wire-h { margin-bottom: 12px; color: #C2410C; }
.ag-never ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.ag-never li { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px 6px 7px; border: 1px solid #F3DCCF; border-radius: 999px; background: #fff; font-size: 14.5px; font-weight: 600; line-height: 1.35; color: #7C2D12; }
.ag-x { width: 22px; height: 22px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #FDE8DD; color: #C2410C; }
.ag-x svg { width: 12px; height: 12px; }
.ag-facts { list-style: none; margin: 0; padding: 20px 22px; border: 1px solid #E4E9F5; border-radius: 18px; background: #fff; display: flex; flex-direction: column; justify-content: center; gap: 12px; text-align: left; }
.ag-facts li { display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 500; line-height: 1.4; color: #2c3444; }
.ag-facts li span { width: 32px; height: 32px; flex: none; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: #E7F6EC; color: #15803D; }
.ag-facts svg { width: 18px; height: 18px; }
.ag-note { margin: 0; padding: 14px 18px; border: 1px solid #E4E9F5; border-radius: 14px; background: #fff; font-size: 14px; line-height: 1.55; color: #4B5563; text-align: left; }

/* ---- who owns what (Tool Builder) ---- */
.ag-owns { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.ag-own { display: flex; flex-direction: column; gap: 4px; padding: 24px; border: 1px solid #E4E9F5; border-radius: 20px; background: #fff; text-align: left; }
.ag-own-ic { width: 44px; height: 44px; margin-bottom: 12px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; background: #EEF1FD; color: #536ee5; }
.ag-own-ic svg { width: 24px; height: 24px; }
.ag-own-k { font-size: 15px; color: #585858; }
.ag-own-v { font-family: var(--brand-font-heading); font-size: 34px; line-height: 1.1; font-weight: 600; color: #232323; }

/* ---- when it isn't sure: the reasons, and one question the way it arrives ---- */
.ag-ask { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.ag-ask-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; text-align: left; }
.ag-ask-copy .la-h2, .ag-ask-copy .la-sub { text-align: left !important; }
.ag-ask.is-solo { grid-template-columns: minmax(0, 760px); justify-content: center; }
.ag-ask.is-solo .ag-ask-copy { align-items: center; }
.ag-ask.is-solo .ag-ask-copy .la-h2, .ag-ask.is-solo .ag-ask-copy .la-sub { text-align: center !important; }
.ag-cases { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.ag-cases li { display: flex; align-items: center; gap: 12px; font-size: 16px; font-weight: 500; line-height: 1.4; color: #2c3444; }
.ag-cases li span { width: 32px; height: 32px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #FEF3E2; color: #B45309; }
.ag-cases svg { width: 17px; height: 17px; }
.ag-ex { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.ag-ex-card { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 14px; padding: 22px; border: 1.5px solid #536ee5; border-radius: 20px; background: linear-gradient(135deg, #F7F8FF, #EEF1FD); box-shadow: 0 30px 60px -36px rgba(83, 110, 229, .7); text-align: left; transition: background-color .3s ease, border-color .3s ease, box-shadow .3s ease; }
.ag-ex-mark { width: 44px; height: 44px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #FEF3E2; color: #B45309; }
.ag-ex-mark svg { width: 22px; height: 22px; }
.ag-ex-copy { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.ag-ex-copy b { font-family: var(--brand-font-heading); font-size: 17px; font-weight: 600; color: #232323; }
.ag-ex-copy span { font-size: 15px; line-height: 1.5; color: #374151; }
.ag-ex-btns { width: 100%; padding-left: 58px; display: flex; flex-wrap: wrap; gap: 8px; }
.ag-ex-go { display: inline-flex; align-items: center; min-height: 44px; margin: 0; padding: 0 20px; border: 0; border-radius: 12px; background: #536ee5; color: #fff; font: 700 15px/1 var(--brand-font-body); cursor: pointer; box-shadow: 0 12px 24px -14px rgba(27, 68, 200, .9); transition: background-color .2s ease; }
.ag-ex-go:hover { background: #1B44C8; }
.ag-ex-alt { min-height: 44px; margin: 0; padding: 0 16px; border: 1px solid #C9D1EA; border-radius: 12px; background: #fff; color: #374151; font: 600 14px/1 var(--brand-font-body); cursor: pointer; transition: border-color .2s ease, color .2s ease; }
.ag-ex-alt:hover { border-color: #536ee5; color: #1B44C8; }
.ag-ex-go:focus-visible, .ag-ex-alt:focus-visible { outline: 2px solid #536ee5; outline-offset: 3px; }
.ag-ex-done { display: none; width: 100%; margin: 0; padding-left: 58px; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; line-height: 1.4; color: #15803D; }
.ag-ex-check { width: 30px; height: 30px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #E7F6EC; color: #15803D; }
.ag-ex-check svg { width: 16px; height: 16px; }
.ag-ex-card.is-done { border-color: #BFE3CB; background: #F3FBF6; box-shadow: none; }
.ag-ex-card.is-done .ag-ex-btns { display: none; }
.ag-ex-card.is-done .ag-ex-done { display: flex; animation: agDone .45s cubic-bezier(.22, .61, .36, 1) both; }
@keyframes agDone { from { opacity: 0; transform: translate3d(0, 6px, 0); } }
.ag-ex-by { display: flex; align-items: center; gap: 8px; margin: 0; padding-left: 4px; font-size: 13.5px; color: #6B7280; text-align: left; }
.ag-ex-face { width: 28px; height: 28px; flex: none; border-radius: 50%; overflow: hidden; background: #F5F7FE; }
.ag-ex-face img { width: 100%; height: 100%; max-width: none; object-fit: cover; display: block; }

/* ---- rather do it yourself ---- */
.ag-diy { display: flex; align-items: center; gap: 16px; width: 100%; max-width: 880px; margin: 0 auto; padding: 18px 22px 18px 18px; border: 1px solid #E4E9F5; border-radius: 18px; background: #fff; color: #232323; text-decoration: none; text-align: left; transition: border-color .2s ease, box-shadow .2s ease; }
.ag-diy:hover { border-color: #536ee5; box-shadow: 0 20px 40px -32px rgba(83, 110, 229, .6); }
.ag-diy:focus-visible { outline: 2px solid #536ee5; outline-offset: 2px; }
.ag-diy-ic { width: 46px; height: 46px; flex: none; border-radius: 13px; display: inline-flex; align-items: center; justify-content: center; background: #F1F3FA; color: #4B5563; }
.ag-diy-ic svg { width: 24px; height: 24px; }
.ag-diy-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ag-diy-t b { font-size: 16px; font-weight: 600; color: #232323; }
.ag-diy-t > span { font-size: 14.5px; line-height: 1.5; color: #585858; }
.ag-diy-t u { color: #1B44C8; text-decoration-color: rgba(83, 110, 229, .4); text-underline-offset: 3px; }
.ag-chev { width: 7px; height: 14px; flex: none; display: inline-flex; color: #9CA3AF; transition: color .2s ease; }
.ag-diy:hover .ag-chev { color: #536ee5; }

/* ---- the offer ---- */
.ag-offer { gap: 20px; }
.ag-steps { list-style: none; width: 100%; max-width: 940px; margin: 12px 0 8px; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.ag-steps li { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 20px 20px 22px; border: 1px solid rgba(255, 255, 255, .1); border-radius: 18px; background: rgba(255, 255, 255, .05); text-align: left; }
.ag-step-n { width: 30px; height: 30px; margin-bottom: 6px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #536ee5; color: #fff; font-size: 14px; font-weight: 700; }
.ag-steps b { font-family: var(--brand-font-heading); font-size: 18px; font-weight: 600; line-height: 1.25; color: #fff; }
.ag-steps li > span:last-child { font-size: 14.5px; line-height: 1.5; color: #cbd5e1; }

/* ---- the other agents, by the work they take off a plate ---- */
.ag-more-sec > .w-container { padding-top: 0 !important; }
.ag-more { width: 100%; text-align: center; }
.ag-more-h { margin: 0 0 16px; font-size: 15px; font-weight: 600; color: #6B7280; }
.ag-more-list { max-width: 980px; margin: 0 auto; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.ag-more-a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 4px 16px 4px 4px; border: 1px solid #D5DBEA; border-radius: 999px; background: #fff; color: #232323; font-size: 14.5px; font-weight: 600; line-height: 1.3; text-decoration: none; transition: border-color .2s ease, color .2s ease; }
.ag-more-a:hover { border-color: #536ee5; color: #1B44C8; }
.ag-more-a:focus-visible { outline: 2px solid #536ee5; outline-offset: 2px; }
.ag-more-ic { width: 34px; height: 34px; flex: none; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; background: #EEF1FD; color: #536ee5; }
.ag-more-ic svg { width: 19px; height: 19px; }
.ag-more-a .ag-chev { display: none; }

@media (max-width: 991px) {
  .ag-handles, .ag-owns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ag-sec .la-h2 { font-size: 34px; }
  /* the wire runs top to bottom */
  .ag-wire { grid-template-columns: minmax(0, 1fr); width: 100%; max-width: 520px; margin: 0 auto; row-gap: 0; }
  .ag-wire > .is-top { display: none; }
  .ag-wire-h.is-inline { position: static !important; width: auto; height: auto; margin: 0; overflow: visible; clip: auto; white-space: normal; }
  .ag-wire-mid { flex-direction: column; }
  .ag-flow { flex: none; width: 2px; height: 40px; min-width: 0; background: repeating-linear-gradient(180deg, #BCC6E6 0 6px, transparent 6px 12px); }
  .ag-flow i { top: 0; left: 50%; margin: 0 0 0 -4px; animation-name: agFlowDown; }
  @keyframes agFlowDown { 0% { top: 0; opacity: 0; } 15%, 85% { opacity: 1; } 100% { top: calc(100% - 8px); opacity: 0; } }
  .ag-core { width: 100%; max-width: 300px; }
  .ag-rules { grid-template-columns: minmax(0, 1fr); max-width: 520px; width: 100%; margin: 0 auto; }
  .ag-note { max-width: 520px; width: 100%; margin: 0 auto; }
  .ag-ask { grid-template-columns: minmax(0, 1fr); gap: 32px; max-width: 620px; margin: 0 auto; }
  .ag-steps { grid-template-columns: minmax(0, 1fr); max-width: 520px; }
}
@media (max-width: 767px) {
  .ag-page .ag-sec > .w-container { padding-top: 40px !important; padding-bottom: 40px !important; }
  .ag-page .la-hero-sec > .w-container { padding-bottom: 24px !important; }
  .ag-sec .la-h2 { font-size: 28px; }
  .ag-sec .section-wrapper { gap: 28px; }
  /* each thing it handles on one row: icon beside the words, so four of them stay short */
  .ag-handles { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .ag-handle { display: grid; grid-template-columns: 44px minmax(0, 1fr); column-gap: 14px; row-gap: 4px; padding: 16px; border-radius: 16px; }
  .ag-handle-ic { grid-row: span 2; width: 44px; height: 44px; margin: 0; border-radius: 12px; }
  .ag-handle-ic svg { width: 24px; height: 24px; }
  .ag-handle-t { font-size: 17px; }
  .ag-handle-p { font-size: 14.5px; }
  .ag-own { padding: 18px; }
  .ag-own-v { font-size: 26px; }
  .ag-ex-card { padding: 18px; }
  .ag-ex-btns, .ag-ex-done { padding-left: 0; }
  .ag-ex-btns > * { flex: 1; justify-content: center; }
  .ag-diy { align-items: flex-start; padding: 16px; }
  .ag-diy .ag-chev { display: none; }
  .ag-more-list { flex-direction: column; align-items: stretch; }
  .ag-more-a { border-radius: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .ag-flow i { display: none; }
  .ag-ex-card.is-done .ag-ex-done { animation: none; }
}
