/*
  WhisperDecks public site root formatting.
  This file is the canonical source for shared site identity: tokens, navigation,
  wordmark, and top-level CTA buttons. Page-specific sections can keep their own
  layouts, but they must not redefine the rules below.
*/

:root {
  color-scheme: dark;
  --wd-site-blue-900: #050f1f;
  --wd-site-blue-850: #071833;
  --wd-site-blue-800: #0a2344;
  --wd-site-panel: #092033;
  --wd-site-text: #f7fbff;
  --wd-site-soft: #d7e9ed;
  --wd-site-muted: #b8cbd3;
  --wd-site-green: #24d296;
  --wd-site-green-soft: #8be8c1;
  --wd-site-orange: #ff7a1f;
  --wd-site-orange-soft: #ffd0a8;
  --wd-site-line: rgba(139, 232, 193, .18);
  --wd-site-font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 122, 31, .78) rgba(5, 15, 31, .92);
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
  width: 12px;
}

html::-webkit-scrollbar-track,
body::-webkit-scrollbar-track {
  background: linear-gradient(180deg, rgba(5, 15, 31, .96), rgba(7, 24, 51, .96));
  border-left: 1px solid rgba(139, 232, 193, .1);
}

html::-webkit-scrollbar-thumb,
body::-webkit-scrollbar-thumb {
  border: 3px solid rgba(5, 15, 31, .96);
  border-radius: 999px;
  background: linear-gradient(180deg, var(--wd-site-orange), var(--wd-site-green-soft));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12), 0 0 18px rgba(255, 122, 31, .2);
}

html::-webkit-scrollbar-thumb:hover,
body::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--wd-site-orange-soft), var(--wd-site-orange) 45%, var(--wd-site-green-soft));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18), 0 0 24px rgba(255, 122, 31, .28);
}

html::-webkit-scrollbar-corner,
body::-webkit-scrollbar-corner {
  background: var(--wd-site-blue-900);
}

.nav,
.nav * {
  box-sizing: border-box;
  font-family: var(--wd-site-font);
  letter-spacing: 0;
}

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  min-height: 62px;
  padding: 0 34px;
  border: 0;
  background: rgba(5, 15, 31, .88);
  color: var(--wd-site-text);
  backdrop-filter: blur(16px);
  box-shadow: 0 18px 34px rgba(0, 0, 0, .16);
}

.nav a {
  color: inherit;
  text-decoration: none;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  width: max-content;
  color: var(--wd-site-text);
}

.platformLogo {
  position: relative;
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  animation: header-logo-spin 5.8s cubic-bezier(.2, .72, .16, 1) .35s both, header-logo-breathe 7s ease-in-out 6.2s infinite;
}

.platformLogo span {
  position: absolute;
  width: 13px;
  height: 13px;
  border: 1px solid rgba(255, 255, 255, .46);
  border-radius: 4px;
  background: linear-gradient(145deg, rgba(43, 196, 140, .96), rgba(6, 184, 135, .78));
  box-shadow: 0 8px 18px rgba(0, 0, 0, .28), 0 0 20px rgba(43, 196, 140, .28);
}

.logoNorth {
  left: 9px;
  top: 0;
  animation: header-square-north 5.8s cubic-bezier(.2, .72, .16, 1) .35s both, header-square-north-loop 7s ease-in-out 6.2s infinite;
}

.logoEast {
  right: 0;
  top: 9px;
  animation: header-square-east 5.8s cubic-bezier(.2, .72, .16, 1) .5s both, header-square-east-loop 7s ease-in-out 6.2s infinite;
}

.logoSouth {
  left: 9px;
  bottom: 0;
  animation: header-square-south 5.8s cubic-bezier(.2, .72, .16, 1) .65s both, header-square-south-loop 7s ease-in-out 6.2s infinite;
}

.logoWest {
  left: 0;
  top: 9px;
  animation: header-square-west 5.8s cubic-bezier(.2, .72, .16, 1) .8s both, header-square-west-loop 7s ease-in-out 6.2s infinite;
}

.brandWordmark {
  position: relative;
  overflow: visible;
  color: #f8fbff;
  font-family: var(--wd-site-font);
  font-size: 18px;
  font-weight: 850;
  line-height: 1.16;
  letter-spacing: 0;
  text-shadow: 0 0 16px rgba(255, 255, 255, .12);
  isolation: isolate;
}

.brandWordmark span,
.brandWordmark em {
  position: relative;
  z-index: 1;
  color: transparent;
  background-size: 260% 100%;
  background-clip: text;
  -webkit-background-clip: text;
  animation: header-text-shimmer 5.8s ease-in-out 1.2s infinite;
}

.brandWordmark span {
  background-image: linear-gradient(110deg, #f8fbff 0%, #f8fbff 34%, #bfffe9 46%, #ffffff 52%, #f8fbff 66%, #f8fbff 100%);
}

.brandWordmark em {
  background-image: linear-gradient(110deg, var(--wd-site-orange) 0%, var(--wd-site-orange) 34%, var(--wd-site-orange-soft) 47%, #ffffff 52%, #ff8d3d 66%, var(--wd-site-orange) 100%);
  font-style: normal;
  text-shadow: 0 0 15px rgba(255, 122, 31, .24);
}

.navLinks {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 26px;
  color: var(--wd-site-soft);
  font-family: var(--wd-site-font);
  font-size: 14px;
  font-weight: 400;
}

.navLinks a {
  position: relative;
  padding: 8px 0;
  color: inherit;
  text-decoration: none;
  transition: color .18s ease;
}

.navLinks a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 2px;
  border-radius: 999px;
  background: var(--wd-site-orange);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .18s ease;
}

.navLinks a:hover,
.navLinks a[aria-current="page"] {
  color: var(--wd-site-text);
}

.navLinks a:hover::after,
.navLinks a[aria-current="page"]::after {
  transform: scaleX(1);
}

.navButtons {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.nav .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 8px;
  padding: 0 17px;
  background: transparent;
  color: var(--wd-site-text);
  font-family: var(--wd-site-font);
  font-size: 14px;
  font-weight: 750;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}

.nav .button.primary {
  border-color: var(--wd-site-orange);
  background: var(--wd-site-orange);
  color: #041014;
  box-shadow: 0 14px 30px rgba(255, 122, 31, .22);
}

.nav .button.login {
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--wd-site-soft);
  box-shadow: none;
  padding-inline: 10px;
}

.nav .button:hover,
.nav .button:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(139, 232, 193, .62);
  background: rgba(139, 232, 193, .12);
  box-shadow: 0 16px 34px rgba(0, 0, 0, .22);
}

.nav .button.login:hover,
.nav .button.login:focus-visible {
  border: 0;
  outline: 0;
  background: rgba(139, 232, 193, .08);
  color: var(--wd-site-text);
  box-shadow: none;
}

.nav .button.primary:hover,
.nav .button.primary:focus-visible,
.nav .button.is-pressed {
  border-color: var(--wd-site-green-soft);
  background: var(--wd-site-green-soft);
  color: #031018;
  box-shadow: 0 20px 38px rgba(139, 232, 193, .26), 0 0 0 4px rgba(139, 232, 193, .08);
}

.languageSwitch {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.languageButton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 38px;
  border: 0;
  border-radius: 8px;
  padding: 0 12px;
  background:
    linear-gradient(180deg, rgba(9, 32, 51, .88), rgba(5, 15, 31, .78));
  color: var(--wd-site-green-soft);
  font-family: var(--wd-site-font);
  font-size: 13px;
  font-weight: 850;
  line-height: 1;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .025);
  transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}

.languageButton:hover,
.languageButton:focus-visible,
.languageSwitch.is-open .languageButton {
  transform: translateY(-2px);
  background:
    linear-gradient(135deg, rgba(255, 122, 31, .18), rgba(36, 210, 150, .14)),
    rgba(5, 15, 31, .86);
  color: var(--wd-site-text);
  box-shadow: 0 16px 34px rgba(0, 0, 0, .24), 0 0 0 4px rgba(255, 122, 31, .08);
}

.languageMenu {
  position: absolute;
  top: calc(100% + 9px);
  right: 0;
  z-index: 30;
  display: grid;
  min-width: 152px;
  border: 1px solid rgba(139, 232, 193, .24);
  border-radius: 10px;
  padding: 6px;
  background: rgba(5, 15, 31, .96);
  box-shadow: 0 22px 50px rgba(0, 0, 0, .36), 0 0 28px rgba(36, 210, 150, .08);
  backdrop-filter: blur(18px);
}

.languageMenu[hidden] {
  display: none;
}

.languageOption {
  display: grid;
  grid-template-columns: 34px 1fr;
  align-items: center;
  gap: 8px;
  width: 100%;
  border: 0;
  border-radius: 7px;
  padding: 9px 10px;
  background: transparent;
  color: var(--wd-site-soft);
  font-family: var(--wd-site-font);
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}

.languageOption strong {
  color: var(--wd-site-green-soft);
  font-size: 12px;
  font-weight: 900;
}

.languageOption:hover,
.languageOption.is-active {
  background: linear-gradient(90deg, rgba(255, 122, 31, .16), rgba(36, 210, 150, .1));
  color: var(--wd-site-text);
}

.floatingTry {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 80;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 48px;
  border-radius: 10px;
  padding: 0 18px;
  background: linear-gradient(135deg, var(--wd-site-orange), #ff8f3b);
  color: #041014;
  font-family: var(--wd-site-font);
  font-size: 14px;
  font-weight: 850;
  line-height: 1;
  text-decoration: none;
  box-shadow: 0 18px 42px rgba(255, 122, 31, .28), 0 0 0 1px rgba(255, 255, 255, .08) inset;
  opacity: 0;
  pointer-events: none;
  transform: translateY(14px);
  transition: opacity .22s ease, transform .22s ease, background .2s ease, box-shadow .2s ease;
}

.floatingTry.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.floatingTry:hover,
.floatingTry:focus-visible {
  background: linear-gradient(135deg, var(--wd-site-green-soft), var(--wd-site-orange));
  box-shadow: 0 22px 46px rgba(36, 210, 150, .22), 0 0 0 4px rgba(255, 122, 31, .1);
  transform: translateY(-2px);
}

.footerLinks {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: flex-end;
}

.footerLinks a {
  color: inherit;
  text-decoration: none;
  transition: color .18s ease;
}

.footerLinks a:hover,
.footerLinks a:focus-visible {
  color: var(--wd-site-orange);
}

.wd-subtle-reveal main {
  animation: wd-page-reveal .42s cubic-bezier(.2, .8, .2, 1) .04s both;
}

.wd-subtle-reveal main > section,
.wd-subtle-reveal main > footer,
.wd-subtle-reveal .loginShell {
  animation: wd-content-reveal .48s cubic-bezier(.2, .8, .2, 1) both;
}

.wd-subtle-reveal main > section:nth-of-type(1),
.wd-subtle-reveal .loginShell {
  animation-delay: .06s;
}

.wd-subtle-reveal main > section:nth-of-type(2) {
  animation-delay: .12s;
}

.wd-subtle-reveal main > section:nth-of-type(3) {
  animation-delay: .18s;
}

.wd-subtle-reveal main > section:nth-of-type(4),
.wd-subtle-reveal main > footer {
  animation-delay: .22s;
}

@keyframes wd-page-reveal {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes wd-content-reveal {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .wd-subtle-reveal main,
  .wd-subtle-reveal main > section,
  .wd-subtle-reveal main > footer,
  .wd-subtle-reveal .loginShell {
    animation: none !important;
  }
}

@media (max-width: 1060px) {
  .nav {
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    justify-items: stretch;
    align-items: center;
    padding: 18px 22px;
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
  }

  .navButtons {
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
    justify-content: flex-end;
    flex-direction: row;
    flex-wrap: nowrap;
  }

  .navLinks {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: center;
    gap: clamp(16px, 3vw, 24px);
    width: 100%;
  }
}

@media (max-width: 720px) {
  .nav {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 13px;
    padding: 14px;
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
    max-width: 100%;
  }

  .brandWordmark {
    font-size: 17px;
  }

  .navLinks {
    grid-column: 1 / -1;
    grid-row: 2;
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    width: 100%;
    gap: clamp(10px, 3.4vw, 18px);
    font-size: 13px;
  }

  .navButtons {
    grid-column: 2;
    grid-row: 1;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-self: end;
    justify-content: flex-end;
    width: auto;
    max-width: 220px;
    gap: 8px;
  }

  .nav > .navButtons,
  .topbar > .actions {
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center;
  }

  .nav .button.demo-open {
    grid-column: auto;
  }

  .nav .button {
    width: auto;
    min-height: 39px;
    padding: 0 10px;
    font-size: 13px;
    line-height: 1.05;
    text-align: center;
  }

  .nav .button.login {
    flex: 0 0 auto;
    padding-inline: 6px;
    white-space: nowrap;
  }

  .languageSwitch {
    flex: 0 0 auto;
  }

  .languageButton {
    min-width: 42px;
    min-height: 39px;
    padding: 0 10px;
  }

  .languageMenu {
    right: 0;
    min-width: 142px;
  }

  .floatingTry {
    right: 14px;
    left: 14px;
    bottom: 14px;
    width: auto;
    min-height: 46px;
  }
}

@media (max-width: 380px) {
  .navLinks {
    font-size: 12px;
    gap: 8px;
  }

  .nav .button {
    font-size: 12px;
    padding: 0 8px;
  }

  .nav .button.login {
    padding-inline: 4px;
  }

  .navButtons {
    gap: 6px;
  }

  .languageButton {
    min-width: 40px;
    padding: 0 8px;
  }
}
