.portal-guide-help {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 2.55rem;
  padding: 0.55rem 0.9rem;
  border: 1.5px solid rgba(36, 70, 60, 0.25);
  border-radius: 999px;
  background: #f8edc8;
  color: #1e342e;
  font: 800 0.88rem/1 "Nunito", sans-serif;
  cursor: pointer;
}

.portal-guide-help::before {
  content: "?";
  display: grid;
  width: 1.35rem;
  height: 1.35rem;
  place-items: center;
  border-radius: 50%;
  background: #24463c;
  color: #fff;
  font-size: 0.82rem;
}

.portal-guide-help:hover,
.portal-guide-help:focus-visible {
  border-color: #24463c;
  outline: 3px solid rgba(228, 195, 108, 0.35);
  outline-offset: 2px;
}

.portal-guide-root {
  position: fixed;
  inset: 0;
  z-index: 100000;
  pointer-events: none;
  font-family: "DM Sans", sans-serif;
}

.portal-guide-root[hidden] {
  display: none !important;
}

.portal-guide-root [hidden] {
  display: none !important;
}

.portal-guide-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 4;
  background: rgba(14, 32, 27, 0.76);
  pointer-events: auto;
}

.portal-guide-menu {
  position: fixed;
  top: 50%;
  left: 50%;
  z-index: 5;
  width: min(920px, calc(100vw - 32px));
  max-height: min(820px, calc(100vh - 32px));
  padding: clamp(1.1rem, 2.5vw, 1.8rem);
  overflow-y: auto;
  box-sizing: border-box;
  transform: translate(-50%, -50%);
  border: 2px solid #24463c;
  border-radius: 26px;
  background: #f8f8f1;
  color: #1e342e;
  box-shadow: 10px 12px 0 #e4c36c, 0 28px 70px rgba(4, 18, 13, 0.4);
  pointer-events: auto;
}

.portal-guide-menu-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.portal-guide-menu-heading span {
  color: #2f7d67;
  font: 900 0.75rem/1 "Nunito", sans-serif;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.portal-guide-menu-heading h2 {
  margin: 0.35rem 0 0.4rem;
  font: 900 clamp(1.55rem, 4vw, 2.35rem)/1.05 "Nunito", sans-serif;
}

.portal-guide-menu-heading p {
  max-width: 620px;
  margin: 0;
  color: #5c6964;
  line-height: 1.5;
}

.portal-guide-menu-close {
  display: grid;
  flex: 0 0 auto;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  place-items: center;
  border: 1.5px solid #24463c;
  border-radius: 50%;
  background: #fff;
  color: #24463c;
  font: 900 1.4rem/1 "Nunito", sans-serif;
  cursor: pointer;
  touch-action: manipulation;
}

.portal-guide-topic-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.portal-guide-topic-list button {
  display: grid;
  min-height: 132px;
  padding: 1rem;
  text-align: left;
  border: 1.5px solid #c8d5ce;
  border-radius: 18px;
  background: #fff;
  color: #1e342e;
  cursor: pointer;
  touch-action: manipulation;
}

.portal-guide-topic-list button:hover,
.portal-guide-topic-list button:focus-visible {
  border-color: #2f7d67;
  outline: 3px solid rgba(228, 195, 108, 0.4);
  outline-offset: 2px;
  transform: translateY(-2px);
}

.portal-guide-topic-list span {
  align-self: start;
  font: 900 1.05rem/1.15 "Nunito", sans-serif;
}

.portal-guide-topic-list small {
  align-self: start;
  margin-top: 0.35rem;
  color: #61706a;
  font-size: 0.8rem;
  line-height: 1.4;
}

.portal-guide-topic-list b {
  align-self: end;
  margin-top: 0.6rem;
  color: #2f7d67;
  font: 800 0.76rem/1 "Nunito", sans-serif;
}

.portal-guide-menu-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.65rem;
  margin-top: 1rem;
}

.portal-guide-menu-actions button {
  min-height: 2.75rem;
  padding: 0.65rem 1rem;
  border: 1.5px solid #24463c;
  border-radius: 999px;
  background: #fff;
  color: #24463c;
  font: 900 0.88rem/1 "Nunito", sans-serif;
  cursor: pointer;
  touch-action: manipulation;
}

.portal-guide-menu-actions .portal-guide-all {
  background: #24463c;
  color: #fff;
}

.portal-guide-mask,
.portal-guide-spotlight,
.portal-guide-card {
  position: fixed;
}

.portal-guide-mask {
  z-index: 1;
  background: rgba(14, 32, 27, 0.72);
  pointer-events: auto;
}

.portal-guide-spotlight {
  z-index: 2;
  border: 4px solid #e4c36c;
  border-radius: 18px;
  box-shadow:
    0 0 0 5px rgba(255, 255, 255, 0.92),
    0 14px 38px rgba(4, 18, 13, 0.35);
  pointer-events: auto;
  transition: inset 180ms ease, width 180ms ease, height 180ms ease;
}

.portal-guide-card {
  z-index: 3;
  width: min(390px, calc(100vw - 24px));
  max-height: calc(100vh - 36px);
  padding: 1.25rem;
  overflow-y: auto;
  box-sizing: border-box;
  border: 2px solid #24463c;
  border-radius: 22px;
  background: #fff;
  color: #1e342e;
  box-shadow: 9px 10px 0 #e4c36c, 0 22px 55px rgba(4, 18, 13, 0.28);
  pointer-events: auto;
}

.portal-guide-kicker {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 1rem;
  margin-bottom: 0.55rem;
  color: #2f7d67;
  font: 800 0.72rem/1 "Nunito", sans-serif;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.portal-guide-progress {
  margin-left: auto;
  color: #6d7974;
  letter-spacing: 0;
  white-space: nowrap;
}

.portal-guide-step-close {
  display: grid;
  width: 2.75rem;
  height: 2.75rem;
  flex: 0 0 2.75rem;
  place-items: center;
  padding: 0;
  border: 2px solid #24463c;
  border-radius: 50%;
  background: #fff;
  color: #24463c;
  font: 900 1.4rem/1 "Nunito", sans-serif;
  cursor: pointer;
  touch-action: manipulation;
}

.portal-guide-step-close:hover,
.portal-guide-step-close:focus-visible {
  outline: 3px solid rgba(228, 195, 108, 0.42);
  outline-offset: 2px;
  background: #f8f3df;
}

.portal-guide-card h2 {
  margin: 0 0 0.55rem;
  color: #1e342e;
  font: 900 clamp(1.35rem, 2.8vw, 1.72rem)/1.08 "Nunito", sans-serif;
}

.portal-guide-card p {
  margin: 0;
  color: #56645f;
  font-size: 0.94rem;
  line-height: 1.55;
}

.portal-guide-visual {
  display: grid;
  gap: 0.45rem;
  margin-top: 0.85rem;
  padding: 0.75rem;
  border: 1.5px solid #d6dfda;
  border-radius: 14px;
  background: #f8f8f1;
}

.portal-guide-visual-label {
  color: #2f7d67;
  font: 900 0.68rem/1 "Nunito", sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portal-guide-visual-actions {
  display: grid;
  gap: 0.45rem;
}

.portal-guide-visual-action {
  display: grid;
  grid-template-columns: 2.25rem minmax(0, 1fr);
  gap: 0.65rem;
  align-items: center;
  min-height: 3.4rem;
  padding: 0.55rem 0.65rem;
  border: 1.5px solid #24463c;
  border-radius: 11px;
  background: #24463c;
  color: #fff;
}

.portal-guide-visual-action > span {
  display: grid;
  width: 2.15rem;
  height: 2.15rem;
  place-items: center;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.16);
  font: 900 0.72rem/1 "Nunito", sans-serif;
}

.portal-guide-visual-action > div {
  display: grid;
  gap: 0.16rem;
}

.portal-guide-visual-action strong {
  font: 900 0.84rem/1.18 "Nunito", sans-serif;
}

.portal-guide-visual-action small {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.72rem;
  line-height: 1.3;
}

.portal-guide-visual-action.is-secondary {
  border-color: #aebfb6;
  background: #fff;
  color: #24463c;
}

.portal-guide-visual-action.is-secondary > span {
  background: #eef3f0;
}

.portal-guide-visual-action.is-secondary small {
  color: #61706a;
}

.portal-guide-visual-action.is-success {
  border-color: #2f7d67;
  background: #2f7d67;
}

.portal-guide-tip {
  display: block;
  margin-top: 0.75rem;
  padding: 0.7rem 0.8rem;
  border-left: 4px solid #e4c36c;
  border-radius: 8px;
  background: #f8f8f1;
  color: #31443d;
  font-size: 0.82rem;
  line-height: 1.45;
}

.portal-guide-target-note {
  display: block;
  margin-top: 0.75rem;
  padding: 0.65rem 0.75rem;
  border-radius: 9px;
  background: #fff3cf;
  color: #594816;
  font-size: 0.78rem;
  line-height: 1.4;
}

.portal-guide-actions {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.55rem;
  align-items: center;
  margin-top: 1.05rem;
}

.portal-guide-actions button {
  min-height: 2.45rem;
  padding: 0.55rem 0.8rem;
  border: 1.5px solid #24463c;
  border-radius: 999px;
  background: #fff;
  color: #24463c;
  font: 800 0.84rem/1 "Nunito", sans-serif;
  cursor: pointer;
  touch-action: manipulation;
}

.portal-guide-actions button:hover,
.portal-guide-actions button:focus-visible {
  outline: 3px solid rgba(228, 195, 108, 0.42);
  outline-offset: 2px;
}

.portal-guide-actions .portal-guide-choose {
  border-color: transparent;
  color: #6d7974;
}

.portal-guide-actions .portal-guide-next {
  background: #24463c;
  color: #fff;
}

.portal-guide-actions button[hidden] {
  visibility: hidden;
}

@media (max-width: 1100px) {
  .portal-guide-help {
    min-height: 2.35rem;
    padding: 0.45rem 0.65rem;
    font-size: 0;
  }

  .portal-guide-help::before {
    font-size: 0.82rem;
  }

  .portal-guide-menu {
    width: min(720px, calc(100vw - 24px));
    max-height: calc(100vh - 24px - env(safe-area-inset-bottom));
    padding: 1rem;
    border-radius: 20px;
    box-shadow: 5px 6px 0 #e4c36c, 0 20px 48px rgba(4, 18, 13, 0.36);
  }

  .portal-guide-topic-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portal-guide-topic-list button {
    min-height: 112px;
  }

  .portal-guide-card {
    width: calc(100vw - 24px);
    max-height: min(54vh, 520px);
    padding: 1rem;
    overflow-y: auto;
    box-sizing: border-box;
    border-radius: 18px;
    box-shadow: 5px 6px 0 #e4c36c, 0 18px 42px rgba(4, 18, 13, 0.28);
  }

  .portal-guide-kicker {
    position: sticky;
    top: -1rem;
    z-index: 1;
    padding: 0.45rem 0;
    background: #fff;
  }

  .portal-guide-card h2 {
    font-size: 1.35rem;
  }

  .portal-guide-card p {
    font-size: 0.88rem;
  }

  .portal-guide-spotlight {
    border-width: 3px;
    border-radius: 14px;
  }
}

@media (max-width: 620px) {
  .portal-guide-menu-heading h2 {
    font-size: 1.45rem;
  }

  .portal-guide-topic-list {
    grid-template-columns: 1fr;
  }

  .portal-guide-topic-list button {
    min-height: 94px;
  }

  .portal-guide-menu-actions {
    position: sticky;
    bottom: -1rem;
    padding: 0.85rem 0 0.2rem;
    background: linear-gradient(transparent, #f8f8f1 24%);
  }

  .portal-guide-card {
    max-height: 58vh;
  }

  .portal-guide-actions {
    grid-template-columns: auto auto;
  }

  .portal-guide-actions .portal-guide-choose {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

@media (prefers-reduced-motion: reduce) {
  .portal-guide-spotlight {
    transition: none;
  }
}
