.ai-hero{
  position:relative;
  padding-top:clamp(54px,7vw,92px);
  padding-bottom:clamp(62px,8vw,108px);
  overflow-x:clip;
  border-bottom:1px solid var(--color-border);
  background:var(--color-bg);
}
.ai-hero::before{
  content:"";
  position:absolute;
  inset:0;
  background-image:radial-gradient(var(--color-grid) 1px,transparent 1.4px);
  background-size:22px 22px;
  opacity:.24;
  pointer-events:none;
}
.ai-hero-grid{
  position:relative;
  display:grid;
  grid-template-columns:minmax(0,.92fr) minmax(460px,1.08fr);
  gap:clamp(38px,6vw,84px);
  align-items:center;
}
.ai-hero-copy{
  min-width:0;
}
.ai-hero-copy .eyebrow{
  margin-top:24px;
}
.ai-hero-copy h1{
  margin-top:14px;
  font-size:clamp(52px,5vw,70px);
}
.ai-hero-lead{
  max-width:660px;
  margin-top:24px;
  color:var(--color-muted);
  font-size:17px;
}
.ai-hero-actions{
  display:flex;
  flex-wrap:wrap;
  gap:14px;
  margin-top:30px;
}
.ai-fact-row{
  display:flex;
  flex-wrap:wrap;
  gap:9px;
  margin-top:26px;
}
.ai-fact-row span{
  display:inline-flex;
  min-height:32px;
  align-items:center;
  max-width:100%;
  padding:5px 12px;
  overflow:hidden;
  border:1px solid var(--color-border);
  border-radius:var(--radius-pill);
  background:var(--color-bg);
  color:var(--color-muted);
  font-size:12px;
  font-weight:700;
}

.ai-route-panel{
  position:relative;
  min-width:0;
  min-height:460px;
  overflow:hidden;
  box-shadow:var(--shadow-card);
}
.ai-route-panel::before{
  content:"";
  position:absolute;
  inset:0;
  background-image:
    linear-gradient(var(--color-grid) 1px,transparent 1px),
    linear-gradient(90deg,var(--color-grid) 1px,transparent 1px);
  background-size:32px 32px;
  opacity:.35;
  pointer-events:none;
}
.ai-panel-head{
  position:relative;
  z-index:2;
  display:flex;
  justify-content:space-between;
  gap:18px;
  padding:22px 26px;
  border-bottom:1px solid var(--color-border);
  color:var(--color-muted);
  font-family:var(--font-mono);
  font-size:10px;
  font-weight:700;
  letter-spacing:.1em;
}
.ai-route-svg{
  position:absolute;
  inset:56px 0 0;
  width:100%;
  height:390px;
}
.ai-route-path,
.ai-route-stem{
  fill:none;
  stroke:var(--color-teal);
  stroke-width:2.2;
  stroke-linecap:round;
}
.ai-route-path-soft{
  stroke:var(--color-teal-soft);
  stroke-width:1.6;
  stroke-dasharray:5 9;
}
.ai-route-stem{
  stroke:var(--color-border);
  stroke-width:1.5;
}
.ai-route-halo{
  fill:var(--color-teal-soft);
  opacity:.28;
}
.ai-route-node{
  fill:var(--color-text);
  stroke:var(--color-bg);
  stroke-width:4;
}
.ai-route-origin,
.ai-route-core,
.ai-route-target{
  position:absolute;
  z-index:3;
  display:grid;
  gap:2px;
  min-width:92px;
  padding:10px 13px;
  border:1px solid var(--color-border);
  border-radius:var(--radius-sm);
  background:var(--color-bg);
  box-shadow:var(--shadow-chip);
}
.ai-route-origin{
  left:7%;
  top:47%;
}
.ai-route-core{
  left:50%;
  top:47%;
  transform:translateX(-50%);
}
.ai-route-target{
  right:6%;
  top:47%;
}
.ai-route-origin small,
.ai-route-core small,
.ai-route-target small{
  color:var(--color-muted);
  font-family:var(--font-mono);
  font-size:9px;
  letter-spacing:.12em;
}
.ai-route-origin strong,
.ai-route-core strong,
.ai-route-target strong{
  font-size:13px;
}
.ai-panel-chip{
  position:absolute;
  z-index:3;
  padding:9px 13px;
  border:1px solid var(--color-border);
  border-radius:var(--radius-pill);
  background:var(--color-bg);
  color:var(--color-teal);
  box-shadow:var(--shadow-chip);
  font-size:12px;
  font-weight:750;
}
.ai-panel-chip-top{
  top:92px;
  right:28px;
}
.ai-panel-chip-bottom{
  right:28px;
  bottom:24px;
}

.ai-article{
  padding-top:48px;
}
.ai-section{
  display:grid;
  grid-template-columns:180px minmax(0,1fr);
  gap:clamp(28px,5vw,72px);
  padding-top:clamp(64px,8vw,108px);
  padding-bottom:clamp(64px,8vw,108px);
  border-bottom:1px solid var(--color-border);
}
.ai-section:last-child{
  border-bottom:0;
}
.ai-section-index{
  padding-top:10px;
  color:var(--color-teal);
  font-family:var(--font-mono);
  font-size:11px;
  font-weight:800;
  letter-spacing:.13em;
}
.ai-section-body{
  min-width:0;
  max-width:900px;
}
.ai-section-body > h2:first-child{
  margin-top:0;
}
.ai-section-body h2{
  max-width:760px;
}
.ai-section-body h3{
  font-size:22px;
}
.ai-section-body p{
  color:var(--color-muted);
}
.ai-section-body a:not(.btn){
  color:var(--color-accent-dark);
  font-weight:750;
  text-decoration:underline;
  text-underline-offset:3px;
}

.ai-principles{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:14px;
  margin-top:34px;
}
.ai-principles > div{
  min-width:0;
  padding:22px;
  border:1px solid var(--color-border);
  border-radius:var(--radius-md);
  background:var(--color-panel);
}
.ai-principles strong{
  display:block;
  color:var(--color-text);
}
.ai-principles p{
  margin-top:8px;
  font-size:14px;
}

.ai-tool-ledger{
  margin-top:34px;
  border-top:1px solid var(--color-border);
}
.ai-tool-entry{
  display:grid;
  grid-template-columns:170px minmax(0,1fr);
  gap:30px;
  padding-top:30px;
  padding-bottom:30px;
  border-bottom:1px solid var(--color-border);
  transition:transform var(--transition-fast),background-color var(--transition-fast),box-shadow var(--transition-fast);
}
.ai-tool-entry:hover{
  transform:translateY(-2px);
  background:var(--color-bg);
  box-shadow:var(--shadow-chip);
}
.ai-tool-name{
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  gap:5px;
}
.ai-tool-name span{
  color:var(--color-teal);
  font-family:var(--font-mono);
  font-size:10px;
  font-weight:800;
  letter-spacing:.13em;
}
.ai-tool-name strong{
  color:var(--color-text);
  font-size:19px;
}
.ai-tool-entry h3{
  margin:0;
}
.ai-tool-entry p{
  margin-top:10px;
}
.ai-comparison-table{
  min-width:820px;
}
.ai-section-body .callout{
  margin-top:26px;
}

.ai-workflow{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:16px;
  margin-top:30px;
  margin-bottom:30px;
}
.ai-workflow-item{
  min-width:0;
  padding:26px;
  border:1px solid var(--color-border);
  border-radius:var(--radius-lg);
  background:var(--color-panel);
}
.ai-workflow-item h3{
  font-size:20px;
}
.ai-workflow-item p{
  margin-top:10px;
}
.ai-failure-list{
  margin-top:30px;
}
.ai-section .promo-block{
  max-width:none;
}
.ai-section-body .promo-block p{
  color:var(--color-panel-strong);
}

@media (max-width:1040px){
  .ai-hero-grid{
    grid-template-columns:1fr;
  }
  .ai-hero-copy{
    max-width:800px;
  }
  .ai-route-panel{
    min-height:430px;
  }
  .ai-section{
    grid-template-columns:130px minmax(0,1fr);
  }
}

@media (max-width:768px){
  .ai-hero{
    padding-top:42px;
  }
  .ai-hero-copy h1{
    font-size:clamp(34px,10vw,40px);
  }
  .ai-hero-lead{
    font-size:16px;
  }
  .ai-hero-actions{
    width:100%;
    flex-direction:column;
  }
  .ai-route-panel{
    min-height:360px;
  }
  .ai-panel-head{
    padding:18px;
  }
  .ai-route-svg{
    inset:38px -70px 0;
    width:calc(100% + 140px);
    height:330px;
  }
  .ai-route-origin,
  .ai-route-core,
  .ai-route-target{
    min-width:78px;
    padding:8px 10px;
  }
  .ai-route-origin{
    left:4%;
  }
  .ai-route-target{
    right:4%;
  }
  .ai-panel-chip-top{
    top:76px;
    right:14px;
  }
  .ai-panel-chip-bottom{
    right:14px;
    bottom:14px;
  }
  .ai-article{
    padding-top:34px;
  }
  .ai-section{
    grid-template-columns:1fr;
    gap:18px;
  }
  .ai-section-index{
    padding-top:0;
  }
  .ai-principles{
    grid-template-columns:1fr;
  }
  .ai-tool-entry{
    grid-template-columns:1fr;
    gap:14px;
  }
}

@media (max-width:640px){
  .ai-fact-row{
    display:grid;
    grid-template-columns:1fr 1fr;
  }
  .ai-fact-row span{
    justify-content:center;
    text-align:center;
  }
  .ai-route-panel{
    min-height:340px;
  }
  .ai-panel-head span:last-child{
    display:none;
  }
  .ai-route-svg{
    inset:38px -120px 0;
    width:calc(100% + 240px);
  }
  .ai-route-origin,
  .ai-route-target{
    top:46%;
  }
  .ai-route-core{
    top:46%;
  }
  .ai-route-origin strong,
  .ai-route-core strong,
  .ai-route-target strong{
    font-size:11px;
  }
  .ai-panel-chip{
    max-width:72%;
    overflow:hidden;
    white-space:nowrap;
    text-overflow:ellipsis;
  }
  .ai-workflow{
    grid-template-columns:1fr;
  }
  .ai-workflow-item{
    padding:22px 18px;
  }
}

@media (max-width:390px){
  .ai-fact-row{
    grid-template-columns:1fr;
  }
  .ai-route-origin{
    left:3%;
  }
  .ai-route-target{
    right:3%;
  }
  .ai-route-origin,
  .ai-route-core,
  .ai-route-target{
    min-width:70px;
    padding:7px 8px;
  }
}