/* The guide and the homepage share the same advisor control. */
.bar .eo-nav-cta {
  --eo-ink: var(--ink);
  --eo-action: var(--olive);
  --eo-celery: var(--celery);
  --eo-paper: var(--chalk);
  --eo-face: var(--sans);
}

.eo-button {
  --engaged: 0;
  --action-ease: cubic-bezier(.22, .78, .22, 1);
  --surface-height: 44px;
  --face: var(--eo-paper);
  --action-ink: var(--eo-ink);
  --reveal: var(--eo-celery);
  display: inline-flex;
  flex: none;
  align-items: center;
  box-sizing: border-box;
  white-space: nowrap;
  text-decoration: none;
  touch-action: manipulation;
  min-height: 44px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  font: 620 15px/1.15 var(--eo-face);
}
@media (hover: hover) and (pointer: fine) {
  .eo-button:hover { --engaged: 1; }
}
.eo-button:focus-visible, .eo-button:active { --engaged: 1; }
.eo-study-action {
  --surface-height: 48px;
  --face: var(--eo-action);
  --action-ink: var(--eo-paper);
}
.eo-action-surface, .eo-action-reveal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  box-sizing: border-box;
}
.eo-action-surface {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: var(--surface-height);
  padding: 4px 8px 4px 13px;
  border: 1px solid var(--eo-action);
  border-radius: 6px;
  color: var(--action-ink);
  background: var(--face);
}
.eo-study-action .eo-action-surface { gap: 12px; padding-inline: 16px 9px; }
.eo-action-copy, .eo-action-label, .eo-action-detail { display: inline-grid; align-items: center; }
.eo-action-copy { align-self: stretch; justify-items: start; }
.eo-action-label, .eo-action-detail { grid-area: 1 / 1; line-height: 1.18; }
.eo-action-detail { font: 500 12px/1.15 var(--eo-face); opacity: 0; }

/* Each side of the diagonal fold carries the matching lettering. */
.eo-action-reveal {
  --travel: calc(var(--engaged) * 120%);
  position: absolute;
  z-index: 1;
  inset: 0;
  gap: inherit;
  padding: inherit;
  background: var(--reveal);
  color: var(--eo-ink);
  pointer-events: none;
  clip-path: polygon(-16% 0, calc(var(--travel) - 1%) 0, calc(var(--travel) - 15%) 100%, -16% 100%);
  transition: clip-path .62s cubic-bezier(.55, .04, .18, 1);
}
.from-end .eo-action-reveal {
  clip-path: polygon(calc(115% - var(--travel)) 0, 116% 0, 116% 100%, calc(101% - var(--travel)) 100%);
}
.eo-action-reveal .eo-action-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 2px;
}
.eo-action-reveal .eo-action-label {
  transform: translateY(calc((1 - var(--engaged)) * 7px));
  transition: transform .42s var(--action-ease) calc(var(--engaged) * 105ms);
}
.eo-action-reveal .eo-action-detail {
  opacity: var(--engaged);
  transform: translateY(calc((1 - var(--engaged)) * 3px));
  transition: opacity .34s, transform .42s var(--action-ease);
  transition-delay: calc(var(--engaged) * 155ms);
}
.eo-button:active .eo-action-surface::after {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 1px;
  border: 1px solid var(--eo-action);
  border-radius: 4px;
  opacity: .5;
  pointer-events: none;
}

.eo-conversation {
  position: relative;
  display: grid;
  flex: none;
  place-items: center;
  width: 23px;
  height: 21px;
  color: var(--eo-action);
}
.eo-conversation::before, .eo-message {
  box-sizing: border-box;
  border: 1px solid currentColor;
  border-radius: 4px;
  transition: transform .48s var(--action-ease);
}
.eo-conversation::before {
  content: "";
  position: absolute;
  width: 15px;
  height: 11px;
  background: var(--eo-celery);
  transform: translate(calc(1px + var(--engaged) * 2px), calc(1px + var(--engaged) * 2px));
}
.eo-message {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5px;
  width: 17px;
  height: 13px;
  background: var(--eo-paper);
  transform: translate(calc(-1px - var(--engaged) * 1px), -1px);
}
.eo-message::after {
  content: "";
  position: absolute;
  left: 3px;
  bottom: -3px;
  width: 4px;
  height: 4px;
  background: inherit;
  border: solid currentColor;
  border-width: 0 0 1px 1px;
  transform: skewY(-33deg);
}
.eo-message i {
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: currentColor;
  opacity: calc(.36 + var(--engaged) * .64);
  transition: opacity .32s ease calc(var(--engaged) * var(--dot-delay, 40ms));
}
.eo-message i:nth-child(2) { --dot-delay: 125ms; }
.eo-message i:nth-child(3) { --dot-delay: 210ms; }

.eo-flight {
  --tile-size: 28px;
  position: relative;
  isolation: isolate;
  display: grid;
  flex: none;
  align-self: center;
  place-items: center;
  width: var(--tile-size);
  height: var(--tile-size);
  overflow: hidden;
  border-radius: 3px;
}
.eo-flight::before {
  --fold: calc(6px - var(--engaged) * 4px);
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: var(--eo-celery);
  clip-path: polygon(0 0, calc(100% - var(--fold)) 0, 100% var(--fold), 100% 100%, 0 100%);
  transition: clip-path .5s var(--action-ease);
}
.eo-plane {
  position: relative;
  grid-area: 1 / 1;
  width: 16px;
  height: 16px;
  transform: translate(calc(var(--engaged) * 24px), calc(var(--engaged) * -20px));
  transition: transform .56s var(--action-ease);
}
.eo-plane + .eo-plane {
  transform: translate(calc((var(--engaged) - 1) * 24px), calc((1 - var(--engaged)) * 20px));
  transition-delay: calc(var(--engaged) * 65ms);
}
.eo-plane::before, .eo-plane::after { content: ""; position: absolute; inset: 0; }
.eo-plane::before { background: var(--eo-action); clip-path: polygon(2% 43%, 95% 6%, 66% 94%, 46% 63%, 32% 78%, 30% 56%); }
.eo-plane::after { background: var(--eo-ink); clip-path: polygon(30% 56%, 95% 6%, 46% 63%, 32% 78%); }
.eo-action-reveal .eo-flight::before { background: var(--eo-action); }
.eo-action-reveal .eo-plane::before { background: var(--eo-paper); }
.eo-action-reveal .eo-plane::after { background: var(--eo-celery); }

/* Compact navigation and touch layouts retain their single-line compass control. */
@media (max-width: 1100px), (hover: none), (pointer: coarse) {
  .eo-text-action {
    --face: rgba(250, 250, 236, .54);
    --action-ink: var(--eo-action);
    font: 570 15px/1.25 var(--eo-face);
  }
  .eo-text-action .eo-action-surface {
    padding-inline: 12px;
    border-color: rgba(70, 84, 56, .32);
    transition: background-color .38s var(--action-ease), border-color .38s var(--action-ease);
  }
  .eo-text-action .eo-action-label { line-height: inherit; }
  .eo-text-action .eo-action-reveal, .eo-text-action .eo-action-detail,
  .eo-text-action:active .eo-action-surface::after { display: none; }
  .eo-text-action:is(:focus-visible, :active) .eo-action-surface { background: var(--eo-celery); border-color: var(--eo-action); }
}
@media (max-width: 1100px) and (hover: hover) and (pointer: fine) {
  .eo-text-action:hover .eo-action-surface { background: var(--eo-celery); border-color: var(--eo-action); }
}
.eo-compass {
  display: grid;
  flex: none;
  place-items: center;
  box-sizing: border-box;
  width: 22px;
  height: 22px;
  border: 1px solid var(--eo-action);
  border-radius: 50%;
  background: var(--eo-paper);
}
.eo-compass::before, .eo-compass::after { content: ""; grid-area: 1 / 1; }
.eo-compass::before {
  width: 8px;
  height: 15px;
  background: linear-gradient(var(--eo-action) 50%, var(--eo-accent) 50%);
  clip-path: polygon(50% 0, 91% 50%, 50% 100%, 9% 50%);
  transform: rotate(calc(25deg + var(--engaged) * 38deg));
  transition: transform .58s cubic-bezier(.24, 1.16, .33, 1);
}
.eo-compass::after {
  z-index: 1;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: var(--eo-paper);
}

@media (max-width: 900px) {
  .eo-study-action { font-size: 14px; }
  .eo-study-action .eo-action-surface { gap: 7px; padding-inline-start: 11px; }
  .eo-text-action { font-size: 14px; }
  .eo-text-action .eo-action-surface { gap: 5px; padding-inline: 7px; }
  .eo-compass { width: 20px; height: 20px; }
}
@media (max-width: 720px) {
  .eo-nav-cta { font-size: 14px; }
  .eo-nav-cta .eo-action-surface { gap: 5px; padding-inline: 9px 5px; }
  .eo-study-action { --surface-height: 46px; }
  .eo-study-action .eo-action-surface { padding-inline-end: 8px; }
}
@media (max-width: 400px) {
  .eo-study-action .eo-action-surface { gap: 5px; padding-inline-start: 8px; }
  .eo-actions a { letter-spacing: -.01em; }
  .eo-text-action .eo-action-surface { padding-inline: 4px; gap: 4px; }
  .eo-compass { width: 18px; height: 18px; }
}
@media (max-width: 385px) {
  .eo-nav-cta .eo-conversation { display: none; }
  .eo-nav-cta .eo-action-surface { padding-inline: 10px; }
}
@media (max-width: 360px) {
  .eo-nav-cta .eo-action-surface { padding-inline: 6px; }
  .bar { padding-inline: 10px; gap: 3px; }
  .bar .menubtn { min-width: 44px; padding-inline: 5px; }
}
@media (pointer: coarse) {
  .eo-button:active .eo-action-reveal { transition-duration: .12s; }
}
@media (prefers-reduced-motion: reduce) {
  .eo-button *, .eo-button *::before, .eo-button *::after { transition: none !important; }
}
@media (forced-colors: active) {
  .eo-plane::before, .eo-plane::after, .eo-message i, .eo-compass::before { background: LinkText; forced-color-adjust: none; }
}

/* The anchors keep their final hit areas while their printed faces arrive. */
@media (min-width: 1101px) and (prefers-reduced-motion: no-preference) {
  .eo-reading-copy .eo-study-action > .eo-action-surface {
    animation: eo-ticket-arrive .72s var(--eo-ease-out) .26s backwards;
  }
  .eo-reading-copy .eo-text-action > .eo-action-surface {
    animation: eo-action-develop .65s ease-out .36s backwards;
  }
  .eo-reading-copy .eo-text-action .eo-compass {
    animation: eo-compass-orient .9s var(--eo-ease-out) .36s backwards;
  }

  /* Scroll dismissal belongs to the parent cue. Only the flag stack and the
     arrow inside its circular window move during this entrance. */
  .eo-student-cover .eo-scroll-link {
    animation: eo-action-develop .58s ease-out .32s backwards;
  }
  .eo-student-cover .eo-dock-flags .eo-flag + .eo-flag {
    --eo-flag-start: -12px;
    animation: eo-dock-unstack .74s var(--eo-ease-out) .36s backwards;
  }
  .eo-student-cover .eo-dock-flags .eo-flag:nth-child(3) { --eo-flag-start: -24px; }
  .eo-student-cover .eo-dock-descent {
    animation: eo-descent-arrive .72s var(--eo-ease-out) .43s backwards;
  }

  .eo-student-cover .eo-slider-tools:not([hidden]) {
    animation: eo-action-develop .55s ease-out .29s backwards;
  }
  .eo-student-cover .eo-slider-arrow {
    animation: eo-pager-unfold .68s var(--eo-ease-out) .38s backwards;
  }
  .eo-student-cover .eo-slide-meter {
    transform-origin: center;
    animation: eo-pager-rule .76s var(--eo-ease-out) .33s backwards;
  }

  .eo-type-pending .eo-student-cover :is(.eo-action-surface, .eo-compass, .eo-scroll-link,
    .eo-dock-flags .eo-flag, .eo-dock-descent, .eo-slider-tools, .eo-slider-arrow, .eo-slide-meter) {
    animation-play-state: paused;
  }
  .eo-reading-copy .eo-button:focus-visible :is(.eo-action-surface, .eo-compass),
  .eo-student-cover .eo-scroll-link:focus-visible,
  .eo-student-cover .eo-scroll-link:focus-visible :is(.eo-flag, .eo-dock-descent),
  .eo-student-cover .eo-slider-tools:focus-within,
  .eo-student-cover .eo-slider-tools:focus-within :is(.eo-slider-arrow, .eo-slide-meter) {
    animation-duration: 1ms;
    animation-delay: 0s;
  }
}
/* Keep the rounded surface's clip static as the hero re-enters the viewport.
   The inner fold owns the hover reveal. */
@keyframes eo-ticket-arrive {
  from { opacity: 0; transform: translateX(-6px); }
  to { opacity: 1; transform: none; }
}
@keyframes eo-action-develop { from { opacity: 0; } to { opacity: 1; } }
@keyframes eo-compass-orient { from { transform: rotate(-55deg); } to { transform: rotate(0deg); } }
@keyframes eo-dock-unstack { from { translate: var(--eo-flag-start) 0; } to { translate: 0 0; } }
@keyframes eo-descent-arrive { from { clip-path: inset(0 0 100% round 50%); } to { clip-path: inset(0 round 50%); } }
@keyframes eo-pager-unfold {
  from { opacity: 0; translate: calc(var(--direction) * -7px) 0; }
  to { opacity: 1; translate: 0 0; }
}
@keyframes eo-pager-rule { from { transform: scaleX(.12); } to { transform: scaleX(1); } }
