@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Manrope:wght@600;700;800&display=swap");

:root {
  color-scheme: dark;
  --wm-bg: #0b1020;
  --wm-surface: #12192b;
  --wm-surface-2: #182238;
  --wm-border: #293550;
  --wm-text: #f8fafc;
  --wm-muted: #a8b3c7;
  --wm-primary: #4f7cff;
  --wm-primary-strong: #3d68df;
  --wm-green: #35c985;
  --wm-amber: #f5b942;
  --wm-cyan: #2bb7cc;
  --wm-danger: #ef6a78;
  --wm-radius: 8px;
  --wm-shadow: 0 18px 48px rgba(0, 0, 0, 0.24);
}

[data-theme="light"] {
  color-scheme: light;
  --wm-bg: #f4f7fb;
  --wm-surface: #ffffff;
  --wm-surface-2: #eef3f9;
  --wm-border: #d7dfeb;
  --wm-text: #101827;
  --wm-muted: #59677b;
  --wm-primary: #315fd2;
  --wm-primary-strong: #244cad;
  --wm-shadow: 0 16px 40px rgba(30, 50, 80, 0.1);
}

* {
  box-sizing: border-box;
  letter-spacing: 0;
}

html {
  scroll-behavior: smooth;
}

body.wm-shell {
  margin: 0;
  min-height: 100vh;
  background: var(--wm-bg);
  color: var(--wm-text);
  font-family: "Inter", sans-serif;
  line-height: 1.6;
}

body.wm-shell::before,
body.wm-shell::after {
  display: none !important;
}

.wm-shell a {
  color: inherit;
}

.wm-skip {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 10000;
  padding: 9px 12px;
  border-radius: var(--wm-radius);
  background: var(--wm-text);
  color: var(--wm-bg);
  transform: translateY(-150%);
}

.wm-skip:focus {
  transform: translateY(0);
}

.wm-topbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--wm-border);
  background: color-mix(in srgb, var(--wm-bg) 92%, transparent);
  backdrop-filter: blur(16px);
}

.wm-topbar-inner,
.wm-container {
  width: min(1600px, calc(100% - clamp(32px, 6vw, 120px)));
  margin: 0 auto;
}

.wm-topbar-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.wm-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  text-decoration: none;
}

.wm-brand-mark {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: var(--wm-radius);
  background: var(--wm-primary);
  color: #fff;
  font: 800 17px/1 "Manrope", sans-serif;
}

.wm-brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}

.wm-brand-copy {
  min-width: 0;
}

.wm-brand-copy strong,
.wm-brand-copy span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wm-brand-copy strong {
  font: 800 15px/1.2 "Manrope", sans-serif;
}

.wm-brand-copy span {
  margin-top: 2px;
  color: var(--wm-muted);
  font-size: 11px;
}

.wm-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.wm-icon-button,
.wm-button {
  border: 1px solid var(--wm-border);
  border-radius: var(--wm-radius);
  background: var(--wm-surface);
  color: var(--wm-text);
  cursor: pointer;
  font: 700 13px/1 "Inter", sans-serif;
  text-decoration: none;
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}

.wm-icon-button {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
}

.wm-icon-button svg {
  width: 19px;
  height: 19px;
}

.wm-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 15px;
}

.wm-button-primary {
  border-color: var(--wm-primary);
  background: var(--wm-primary);
  color: #fff;
}

.wm-button:hover,
.wm-icon-button:hover {
  border-color: var(--wm-primary);
  transform: translateY(-1px);
}

.wm-button:active,
.wm-icon-button:active {
  transform: translateY(0) scale(0.98);
  opacity: 0.95;
}

.wm-button-primary:hover {
  background: var(--wm-primary-strong);
}

.wm-button svg {
  width: 17px;
  height: 17px;
}

.wm-main {
  padding: 46px 0 64px;
}

.wm-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
  gap: clamp(36px, 5vw, 82px);
  align-items: end;
  padding-bottom: 34px;
  border-bottom: 1px solid var(--wm-border);
}

.wm-eyebrow {
  margin: 0 0 12px;
  color: var(--wm-primary);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.wm-hero h1,
.wm-state h1 {
  margin: 0;
  max-width: 760px;
  font: 800 clamp(30px, 5vw, 54px)/1.08 "Manrope", sans-serif;
}

.wm-hero p,
.wm-state p {
  margin: 16px 0 0;
  max-width: 700px;
  color: var(--wm-muted);
  font-size: 16px;
}

.wm-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.wm-summary-item {
  min-height: 86px;
  padding: 15px;
  border: 1px solid var(--wm-border);
  border-radius: var(--wm-radius);
  background: var(--wm-surface);
}

.wm-summary-item strong,
.wm-summary-item span {
  display: block;
}

.wm-summary-item strong {
  font: 800 22px/1.15 "Manrope", sans-serif;
}

.wm-summary-item span {
  margin-top: 7px;
  color: var(--wm-muted);
  font-size: 12px;
}

.wm-section {
  padding-top: 34px;
}

.wm-section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 17px;
}

.wm-section-heading h2 {
  margin: 0;
  font: 800 22px/1.2 "Manrope", sans-serif;
}

.wm-section-heading p {
  margin: 5px 0 0;
  color: var(--wm-muted);
  font-size: 13px;
}

.wm-app-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 1.25vw, 22px);
}

.wm-app-card {
  position: relative;
  min-height: 245px;
  display: flex;
  flex-direction: column;
  padding: 20px;
  overflow: hidden;
  border: 1px solid var(--wm-border);
  border-radius: var(--wm-radius);
  background: var(--wm-surface);
  text-decoration: none;
  box-shadow: 0 0 0 transparent;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.wm-app-card:hover {
  border-color: var(--wm-primary);
  box-shadow: var(--wm-shadow);
  transform: translateY(-3px);
}

.wm-app-card[aria-disabled="true"] {
  cursor: default;
}

.wm-app-card[aria-disabled="true"]:hover {
  border-color: var(--wm-border);
  box-shadow: none;
  transform: none;
}

.wm-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.wm-app-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: var(--wm-radius);
  background: var(--wm-surface-2);
  color: var(--card-accent, var(--wm-primary));
}

.wm-app-icon svg {
  width: 23px;
  height: 23px;
}

.wm-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border: 1px solid var(--wm-border);
  border-radius: 999px;
  color: var(--wm-muted);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.wm-status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.wm-status-live {
  color: var(--wm-green);
}

.wm-status-soon {
  color: var(--wm-amber);
}

.wm-app-card h3 {
  margin: 23px 0 8px;
  font: 800 18px/1.25 "Manrope", sans-serif;
}

.wm-app-card p {
  margin: 0;
  color: var(--wm-muted);
  font-size: 13px;
  line-height: 1.65;
}

.wm-card-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 20px;
  color: var(--card-accent, var(--wm-primary));
  font-size: 13px;
  font-weight: 800;
}

.wm-card-action svg {
  width: 18px;
  height: 18px;
}

.wm-footer {
  padding: 24px 0;
  border-top: 1px solid var(--wm-border);
  color: var(--wm-muted);
  font-size: 12px;
}

.wm-footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.wm-state-page {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.wm-state-main {
  flex: 1;
  display: grid;
  place-items: center;
  padding: 48px 0;
}

.wm-state {
  width: min(720px, 100%);
}

.wm-state-icon {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  margin-bottom: 24px;
  border-radius: var(--wm-radius);
  background: var(--wm-surface-2);
  color: var(--state-accent, var(--wm-primary));
}

.wm-state-icon svg {
  width: 28px;
  height: 28px;
}

.wm-state-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.wm-bottom-nav {
  display: none;
}

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--wm-primary) 55%, transparent);
  outline-offset: 3px;
}

@media (max-width: 850px) {
  .wm-hero {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .wm-app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .wm-topbar-inner,
  .wm-container {
    width: min(100% - 24px, 1160px);
  }

  .wm-topbar-inner {
    min-height: 60px;
  }

  .wm-brand-copy span,
  .wm-home-label {
    display: none;
  }

  .wm-main {
    padding-top: 30px;
  }

  .wm-hero {
    gap: 27px;
  }

  .wm-hero h1,
  .wm-state h1 {
    font-size: 32px;
  }

  .wm-app-grid {
    grid-template-columns: 1fr;
  }

  .wm-app-card {
    min-height: 205px;
  }

  .wm-footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (min-width: 1400px) {
  .wm-main {
    padding-top: 58px;
  }

  .wm-hero {
    grid-template-columns: minmax(0, 1.5fr) minmax(360px, .5fr);
    padding-bottom: 44px;
  }

  .wm-hero h1 {
    max-width: 940px;
    font-size: clamp(46px, 3.4vw, 64px);
  }

  .wm-hero p {
    max-width: 820px;
    font-size: 17px;
  }

  .wm-summary-item {
    min-height: 102px;
    padding: 20px;
  }

  .wm-summary-item strong {
    font-size: 28px;
  }

  .wm-section {
    padding-top: 42px;
  }

  .wm-app-card {
    min-height: 260px;
    padding: 24px;
  }
}

@media (min-width: 601px) and (max-width: 1100px) {
  .wm-topbar-inner,
  .wm-container {
    width: min(100% - clamp(32px, 6vw, 64px), 1040px);
  }

  .wm-main {
    padding: 38px 0 54px;
  }

  .wm-hero {
    grid-template-columns: 1fr;
    gap: 26px;
    align-items: start;
  }

  .wm-hero h1 {
    font-size: clamp(38px, 6vw, 52px);
  }

  .wm-summary {
    grid-template-columns: repeat(2, minmax(0, 220px));
  }

  .wm-app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  body.wm-shell {
    padding-bottom: calc(84px + env(safe-area-inset-bottom)) !important;
  }

  .wm-topbar {
    background: color-mix(in srgb, var(--wm-bg) 97%, transparent);
  }

  /* Hide topbar actions on mobile - moved to bottom nav */
  .wm-topbar .wm-actions {
    display: none;
  }

  .wm-topbar-inner,
  .wm-container {
    width: calc(100% - 32px);
  }

  .wm-main {
    padding: 24px 0 40px;
  }

  .wm-hero {
    gap: 20px;
    padding-bottom: 24px;
  }

  .wm-hero h1,
  .wm-state h1 {
    font-size: clamp(28px, 8.5vw, 36px);
    line-height: 1.1;
  }

  .wm-hero p,
  .wm-state p {
    margin-top: 10px;
    font-size: 13.5px;
    line-height: 1.55;
  }

  .wm-summary {
    gap: 8px;
  }

  .wm-summary-item {
    min-height: 72px;
    padding: 12px;
  }

  .wm-summary-item strong {
    font-size: 18px;
  }

  .wm-section {
    padding-top: 24px;
  }

  .wm-section-heading {
    margin-bottom: 12px;
  }

  .wm-section-heading h2 {
    font-size: 18px;
  }

  .wm-app-grid {
    gap: 12px;
    grid-template-columns: 1fr;
  }

  /* Standard Single-Action Card: List Item on Mobile */
  .wm-app-card {
    min-height: auto;
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr) 22px;
    grid-template-rows: auto auto;
    gap: 4px 12px;
    padding: 16px;
    position: relative;
  }

  .wm-card-head {
    grid-column: 1;
    grid-row: 1 / 3;
    align-items: center;
    justify-content: center;
    margin: 0;
  }

  .wm-app-icon {
    width: 46px;
    height: 46px;
  }

  /* Absolute position trigger & status badge on mobile for clean overlap prevention */
  .wm-status {
    position: absolute !important;
    top: 16px !important;
    right: 16px !important;
    padding: 4px 7px !important;
    font-size: 8px !important;
    z-index: 90 !important;
    margin: 0 !important;
  }

  .wm-info-trigger {
    position: absolute !important;
    top: 15px !important;
    right: 84px !important;
    width: 26px !important;
    height: 26px !important;
    display: grid !important;
    place-items: center !important;
    border-radius: 50% !important;
    z-index: 100 !important;
    margin: 0 !important;
  }

  .wm-app-card h3 {
    grid-column: 2;
    grid-row: 1;
    align-self: end;
    margin: 0;
    padding-right: 112px; /* Ensure title clears trigger and badge */
    font-size: 15px;
    font-weight: 700;
  }

  .wm-app-card p {
    grid-column: 2;
    grid-row: 2;
    display: -webkit-box;
    overflow: hidden;
    font-size: 11.5px;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    padding-right: 10px;
  }

  .wm-card-action {
    grid-column: 3;
    grid-row: 1 / 3;
    align-self: center;
    padding: 0;
    font-size: 0;
  }

  .wm-card-action svg {
    width: 20px;
    height: 20px;
  }

  /* Mobile-Native Action Card: Vertical Layout on Mobile */
  .wm-app-card.wm-card-has-actions {
    display: flex;
    flex-direction: column;
    min-height: auto;
    padding: 16px;
    gap: 0;
  }

  .wm-app-card.wm-card-has-actions .wm-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 12px;
  }

  .wm-app-card.wm-card-has-actions h3 {
    margin: 0 0 6px;
    padding-right: 0;
    font-size: 16px;
  }

  .wm-app-card.wm-card-has-actions p {
    display: block;
    margin-bottom: 16px;
    font-size: 12px;
    line-height: 1.5;
    -webkit-line-clamp: none;
    padding-right: 0;
  }

  .wm-app-card.wm-card-has-actions .wm-card-actions-group {
    display: flex;
    flex-direction: column !important;
    gap: 8px !important;
    width: 100% !important;
    margin-top: auto !important;
    padding-top: 0 !important;
  }

  .wm-app-card.wm-card-has-actions .wm-card-btn {
    width: 100% !important;
    flex: none !important;
    min-height: 44px !important;
    font-size: 13px !important;
    justify-content: center !important;
    align-items: center !important;
  }

  /* Bottom Sheet Modal Style on Mobile */
  .wm-modal {
    align-items: flex-end !important;
  }

  .wm-modal-content {
    width: 100% !important;
    max-height: 85vh !important;
    border-radius: 20px 20px 0 0 !important;
    border-bottom: none !important;
    transform: translateY(100%) scale(1) !important;
    padding: 24px 20px calc(24px + env(safe-area-inset-bottom)) !important;
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.28) !important;
    transition: transform 0.3s cubic-bezier(0.1, 0.76, 0.55, 0.94) !important;
  }

  .wm-modal.active .wm-modal-content {
    transform: translateY(0) scale(1) !important;
  }
  
  /* Modal drag handle bar indicator */
  .wm-modal-content::before {
    content: "";
    display: block;
    width: 44px;
    height: 5px;
    background: var(--wm-border);
    border-radius: 99px;
    margin: -12px auto 20px;
    opacity: 0.7;
  }

  /* Mobile Bottom Navigation Bar */
  .wm-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 64px;
    background: color-mix(in srgb, var(--wm-surface) 94%, transparent);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--wm-border);
    z-index: 1900;
    justify-content: space-around;
    align-items: center;
    padding-bottom: env(safe-area-inset-bottom);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.2);
  }
  
  .wm-bottom-nav-item {
    background: none;
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    color: var(--wm-muted);
    cursor: pointer;
    text-decoration: none;
    flex: 1;
    height: 100%;
    padding: 6px 0;
    font-size: 10.5px;
    font-weight: 700;
    transition: color 0.2s ease;
  }
  
  .wm-bottom-nav-item svg {
    width: 21px;
    height: 21px;
  }
  
  .wm-bottom-nav-item:hover,
  .wm-bottom-nav-item:focus,
  .wm-bottom-nav-item.active {
    color: var(--wm-primary);
  }

  .wm-bottom-nav-item:active {
    transform: scale(0.95);
    opacity: 0.85;
  }

  .wm-footer {
    padding-bottom: calc(24px + env(safe-area-inset-bottom));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Shared identity layer for the feature-rich legacy CBT landing page. */
body.cbt-landing {
  --primary: var(--wm-primary);
  --primary-dark: var(--wm-primary-strong);
  --bg-primary: var(--wm-bg);
  --bg-secondary: var(--wm-surface);
  --bg-card: var(--wm-surface);
  --text-primary: var(--wm-text);
  --text-secondary: var(--wm-muted);
  --border-color: var(--wm-border);
  font-family: "Inter", sans-serif;
}

body.cbt-landing h1,
body.cbt-landing h2,
body.cbt-landing h3,
body.cbt-landing h4 {
  font-family: "Manrope", sans-serif;
  letter-spacing: 0;
}

body.cbt-landing .modal-card,
body.cbt-landing .feature-card,
body.cbt-landing .login-card,
body.cbt-landing .testimonial-card {
  border-radius: var(--wm-radius);
}
