.ai-editorial .intro {
  display: grid;
  gap: 1.25rem;
  padding: clamp(1.6rem, 3.2vw, 3rem) 0 clamp(1.25rem, 2.5vw, 2rem);
}
.ai-editorial h1, .ai-editorial h2, .ai-editorial p, .ai-editorial figure { margin: 0; }
.ai-editorial .intro h1 { font-size: clamp(2.25rem, 4.4vw, 4.1rem); font-weight: 400; letter-spacing: -.055em; line-height: 1.02; }
.ai-editorial .intro h1 span { font-family: Georgia, 'Times New Roman', serif; font-style: italic; letter-spacing: -.048em; }
.ai-editorial .instructions { display: none; color: var(--muted); font-size: 1rem; line-height: 1.45; max-width: 32rem; }
:root.with-comparisons .ai-editorial .instructions { display: block; }
.ai-editorial .gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(2rem, 4vw, 3.5rem) clamp(1.15rem, 2.5vw, 2rem); }
.ai-editorial .comparison { min-width: 0; --split: 50%; }
.ai-editorial .comparison h2 { font-size: 1.0625rem; font-weight: 400; line-height: 1.3; letter-spacing: -.015em; padding: .75rem 0; border-top: 1px solid var(--line); }
.ai-editorial .frame { position: relative; isolation: isolate; }
.ai-editorial .layer { position: relative; }
.ai-editorial .layer img { width: 100%; aspect-ratio: 4 / 5; height: auto; display: block; object-fit: cover; object-position: center; }
.ai-editorial .layer figcaption {
  position: absolute; top: .75rem; z-index: 1;
  font-size: .875rem; line-height: 1; color: #fff;
  background: rgba(18, 19, 17, .78); padding: .4rem .6rem; border-radius: 2px;
}
.ai-editorial .original figcaption { left: .75rem; }
.ai-editorial .enhanced figcaption { right: .75rem; }
.ai-editorial .range, .ai-editorial .divider, .ai-editorial .modes { display: none; }
.ai-editorial .is-ready .frame { aspect-ratio: 4 / 5; overflow: hidden; }
.ai-editorial .is-ready .layer { position: absolute; inset: 0; }
.ai-editorial .is-ready .layer img { width: 100%; height: 100%; }
.ai-editorial .is-ready .original { z-index: 1; clip-path: inset(0 calc(100% - var(--split)) 0 0); }
.ai-editorial .is-ready .enhanced { clip-path: inset(0 0 0 var(--split)); }
.ai-editorial .is-ready .range {
  display: block; appearance: none; -webkit-appearance: none;
  position: absolute; z-index: 3; inset: 0; width: 100%; height: 100%;
  margin: 0; border: 0; border-radius: 0; opacity: 0;
  cursor: ew-resize; touch-action: pan-y;
}
.ai-editorial .range::-webkit-slider-runnable-track { width: 100%; height: 100%; background: transparent; }
.ai-editorial .range::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 2px; height: 100%; background: transparent; }
.ai-editorial .range::-moz-range-track { height: 100%; background: transparent; border: 0; }
.ai-editorial .range::-moz-range-thumb { width: 2px; height: 100%; background: transparent; border: 0; }
.ai-editorial .is-ready .divider {
  display: block; position: absolute; top: 0; bottom: 0; left: var(--split);
  z-index: 2; width: 2px; transform: translateX(-50%);
  background: #fff; box-shadow: 0 0 4px #0008; pointer-events: none;
}
.ai-editorial .grip {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  display: flex; align-items: center; justify-content: center; gap: .33rem;
  height: 2.5rem; width: 2.5rem; border: 1px solid #fffd; border-radius: 50%;
  background: #161714c9; color: #fff;
}
.ai-editorial .grip::before, .ai-editorial .grip::after { content: ''; width: .4rem; height: .4rem; border: solid currentColor; border-width: 0 1.5px 1.5px 0; }
.ai-editorial .grip::before { transform: rotate(135deg); }
.ai-editorial .grip::after { transform: rotate(-45deg); }
.ai-editorial .comparison[data-endpoint] .divider { visibility: hidden; }
.ai-editorial .frame:has(.range:focus-visible) { outline: 2px solid var(--accent); outline-offset: 3px; }
.ai-editorial .is-ready .modes { display: flex; gap: .3rem; padding-top: .55rem; }
.ai-editorial .modes button {
  background: transparent; color: var(--muted); border: 1px solid transparent; border-radius: 2px;
  min-height: 2.75rem; padding: .45rem .8rem; font-size: .875rem; cursor: pointer;
}
.ai-editorial .modes button[aria-pressed="true"] { border-color: #70726a; background: #272824; color: var(--fg); }
.ai-editorial .modes button:hover { color: var(--fg); }
@media (max-width: 44rem) {
  .ai-editorial .gallery { grid-template-columns: 1fr; }
}
@media (max-width: 25rem) {
  .ai-editorial .modes button { padding-inline: .7rem; }
}

.ai-editorial {
  width: min(100%, 76rem);
  margin-inline: auto;
  padding-inline: var(--pad);
  padding-bottom: clamp(3rem, 7vw, 6rem);
}
.ai-editorial .intro-copy {
  max-width: 42rem;
  display: grid;
  gap: .75rem;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
}
.ai-editorial .modes button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.ai-editorial .gallery { scroll-margin-top: calc(var(--site-header-height) + 1rem); }
