/* STW Markets — vanilla replacement for Framer's live runtime bundle.
   Handles: mobile nav open state, FAQ accordion, calculator result panel, form feedback notes. */

html.stw-menu-open,
body.stw-menu-open {
  overflow: hidden;
}

/* Wide brand banner inserted above the "Create Account" step section */
.stw-create-account-banner {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 24px;
  margin: 0 0 32px;
}

/* "Trusted by" logo ticker — Framer's continuous auto-scroll marquee had
   no CSS driving it at all, purely the removed JS runtime. Reproduced
   here as a plain looping CSS animation over a doubled item list. */
.stw-ticker-wrapper {
  overflow: hidden;
}
.stw-ticker-track {
  display: flex;
  animation: stw-ticker-scroll 22s linear infinite;
}
.stw-ticker-wrapper:hover .stw-ticker-track {
  animation-play-state: paused;
}
@keyframes stw-ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .stw-ticker-track {
    animation: none;
  }
}

/* Mobile menu hamburger -> X feedback */
[data-framer-name="Mobile Menu Icon"] [data-framer-name="Line"] {
  transition: transform 0.2s ease;
}
header.stw-menu-open-icon [data-framer-name="Mobile Menu Icon"] [data-framer-name="Line"]:first-child {
  transform: translateY(4px) rotate(45deg);
}
header.stw-menu-open-icon [data-framer-name="Mobile Menu Icon"] [data-framer-name="Line"]:last-child {
  transform: translateY(-4px) rotate(-45deg);
}
[data-framer-name="Mobile Menu Icon"] {
  cursor: pointer;
}

/* Desktop nav dropdowns (Trading / Markets / Help / Tools) — rebuilt from
   scratch, the static export only shipped the resting "Closed" state. */
.stw-nav-panel {
  display: none;
  position: fixed;
  min-width: 220px;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
  padding: 8px;
  z-index: 9999;
  cursor: default;
  box-sizing: border-box;
}
.stw-nav-panel.stw-nav-open {
  display: block;
}
.stw-nav-panel-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.stw-nav-panel-list li + li {
  margin-top: 2px;
}
.stw-nav-panel-list a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #0b1220;
  text-decoration: none;
  white-space: nowrap;
}
.stw-nav-panel-list a:hover {
  background: rgb(224, 239, 236);
}

/* Mobile nav overlay — the static export never rendered the open-menu
   markup at all (only logo + hamburger), so this is built fresh. */
.stw-mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  background: #ffffff;
  overflow-y: auto;
  padding: 96px 24px 32px;
  box-sizing: border-box;
}
.stw-mobile-overlay.stw-open {
  display: block;
}
.stw-mobile-overlay-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stw-mobile-link,
.stw-mobile-group-trigger {
  display: block;
  width: 100%;
  text-align: left;
  padding: 16px 4px;
  border: none;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  background: none;
  font-size: 18px;
  font-weight: 500;
  color: #0b1220;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
}
.stw-mobile-group-trigger {
  position: relative;
}
.stw-mobile-group-trigger::after {
  content: '+';
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: #00473e;
  transition: transform 0.2s ease;
}
.stw-mobile-group-open .stw-mobile-group-trigger::after {
  transform: translateY(-50%) rotate(45deg);
}
.stw-mobile-group-panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
.stw-mobile-group-open .stw-mobile-group-panel {
  max-height: 400px;
}
.stw-mobile-group-panel .stw-nav-panel-list {
  padding: 8px 0 12px 12px;
}
.stw-mobile-group-panel .stw-nav-panel-list a {
  padding: 10px 4px;
  font-size: 16px;
  font-weight: 400;
}
.stw-mobile-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 24px;
}
.stw-mobile-btn {
  display: block;
  text-align: center;
  padding: 14px;
  border-radius: 100px;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  box-sizing: border-box;
}
.stw-mobile-btn-outline {
  border: 1.5px solid #00473e;
  color: #00473e;
}
.stw-mobile-btn-solid {
  border: 1.5px solid #00473e;
  background: #00473e;
  color: #ffffff;
}

/* FAQ accordion (help-center.html) */
.stw-faq-row {
  cursor: pointer;
}
.stw-faq-answer {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  margin-top: 0;
  transition: max-height 0.3s ease, opacity 0.25s ease, margin-top 0.3s ease;
}
.stw-faq-row.stw-faq-open .stw-faq-answer {
  max-height: 320px;
  opacity: 1;
  margin-top: 12px;
}
.stw-faq-answer p {
  margin: 0 0 8px;
  font-size: 15px;
  line-height: 1.5;
  color: #333;
}
.stw-faq-answer-link {
  display: inline-block;
  color: #00473e;
  font-weight: 600;
  text-decoration: underline;
}
.stw-faq-row.stw-faq-open [data-framer-name="+"] {
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

/* Second FAQ accordion pattern — the native Framer "+" icon widget used on
   trading-accounts.html, all markets/* and trading-platforms/* pages,
   about-us.html, contact-us.html, index.html, lot-size-calculator.html */
.stw-faq2-card.stw-faq-open .stw-faq2-answer {
  max-height: 320px;
  opacity: 1;
  margin-top: 12px;
  padding: 0 24px 18px;
}
.stw-faq2-trigger svg {
  transition: transform 0.2s ease;
}
.stw-faq2-card.stw-faq-open .stw-faq2-trigger svg {
  transform: rotate(45deg);
}
[data-framer-name="+"] {
  transition: transform 0.2s ease;
}

/* Lot size calculator result panel (lot-size-calculator.html) */
.stw-calc-result {
  margin-top: 20px;
  padding: 18px;
  border: 1.5px solid #d0e8e0;
  border-radius: 12px;
  background: #f4faf8;
  box-sizing: border-box;
}
.stw-calc-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 0;
  font-size: 15px;
  color: #1a1a1a;
}
.stw-calc-row strong {
  color: #00473e;
}
.stw-calc-error {
  color: #b3261e;
  margin: 0;
  font-size: 14px;
}
.stw-calc-note {
  font-size: 13px;
  color: #8a6d00;
  margin: 10px 0 0;
}
.stw-calc-disclaimer {
  font-size: 12px;
  color: #777;
  margin: 10px 0 0;
}

/* Form submit feedback (newsletter + contact forms) */
.stw-form-note {
  margin-top: 10px;
  font-size: 13px;
  color: #00473e;
  font-weight: 500;
}
