/* Lexora Store — premium floating glass header (2026) */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:root {
  --lex-blue: #4f6bff;
  --lex-violet: #6c63ff;
  --lex-white: #ffffff;
  --lex-surface: #f5f7ff;
  --lex-muted: #94a3b8;
  --lex-ink: #1b1d28;
  --lex-glass-bg: rgba(255, 255, 255, 0.78);
  --lex-glass-bg-scrolled: rgba(255, 255, 255, 0.94);
  --lex-glass-border: rgba(255, 255, 255, 0.65);
  --lex-glass-border-scrolled: rgba(27, 29, 40, 0.1);
  --lex-glass-shadow: 0 8px 32px rgba(15, 23, 42, 0.08);
  --lex-glass-shadow-scrolled: 0 4px 16px rgba(15, 23, 42, 0.06), 0 14px 44px rgba(31, 38, 135, 0.12);
  --lex-glass-blur: 20px;
  --lex-nav-muted: #64748b;
  --lex-nav-muted-scrolled: #475569;
  --lex-radius: 24px;
  --lex-header-top: clamp(0.65rem, 2vw, 1rem);
  --header-offset: 5.5rem;
  --site-max: 1320px;
  --site-gutter: clamp(1rem, 4vw, 2.5rem);
  --site-pad: clamp(0.5rem, 1.2vw, 0.85rem);
  --header-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html.dark {
  --lex-glass-bg: rgba(27, 29, 40, 0.72);
  --lex-glass-border: rgba(255, 255, 255, 0.1);
  --lex-glass-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.site-shell,
.lex-header__shell {
  width: min(var(--site-max), calc(100% - 2 * var(--site-gutter)));
  max-width: var(--site-max);
  margin-inline: auto;
  padding-inline: max(var(--site-pad), env(safe-area-inset-left, 0px))
    max(var(--site-pad), env(safe-area-inset-right, 0px));
  box-sizing: border-box;
}

body.has-simple-header {
  padding-top: var(--header-offset, 5.5rem);
}

.has-simple-header.home-page .home-main {
  padding-top: 0;
}

/* —— Floating header shell —— */
.lex-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding: var(--lex-header-top) 0 0;
  pointer-events: none;
  transform: translateY(0);
  opacity: 1;
  transition:
    padding 0.4s var(--header-ease),
    transform 0.48s var(--header-ease),
    opacity 0.35s var(--header-ease);
  will-change: transform, opacity;
}

.lex-header__shell {
  pointer-events: auto;
}

.lex-header--scrolled {
  padding-top: calc(var(--lex-header-top) * 0.5);
}

.lex-header--hidden {
  transform: translateY(calc(-100% - 0.35rem));
  opacity: 0;
  pointer-events: none;
}

/* —— Glass pill container —— */
.lex-glass {
  position: relative;
  display: flex;
  align-items: center;
  gap: clamp(0.5rem, 1.5vw, 1.25rem);
  min-height: 3.25rem;
  padding: 0.4rem clamp(0.65rem, 1.8vw, 1.1rem);
  border-radius: var(--lex-radius);
  background: var(--lex-glass-bg);
  -webkit-backdrop-filter: blur(var(--lex-glass-blur)) saturate(1.35);
  backdrop-filter: blur(var(--lex-glass-blur)) saturate(1.35);
  border: 1px solid var(--lex-glass-border);
  box-shadow: var(--lex-glass-shadow);
  isolation: isolate;
  transition:
    background 0.45s var(--header-ease),
    box-shadow 0.45s var(--header-ease),
    border-color 0.45s var(--header-ease),
    transform 0.5s var(--header-ease);
  animation: lex-header-float 6s ease-in-out infinite;
}

.lex-header--scrolled .lex-glass {
  min-height: 3rem;
  padding-block: 0.32rem;
  background: var(--lex-glass-bg-scrolled);
  border-color: var(--lex-glass-border-scrolled);
  box-shadow: var(--lex-glass-shadow-scrolled);
  -webkit-backdrop-filter: blur(14px) saturate(1.15);
  backdrop-filter: blur(14px) saturate(1.15);
  animation: none;
}

html:not(.dark) .lex-header--scrolled .lex-glass::before {
  opacity: 1;
}

html.dark .lex-header--scrolled .lex-glass {
  background: rgba(27, 29, 40, 0.92);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
}

.lex-header--settled.lex-header--scrolled:not(.lex-header--hidden) .lex-glass {
  animation: lex-header-settle 0.55s var(--header-ease) both;
}

@keyframes lex-header-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px);
  }
}

@keyframes lex-header-settle {
  0% {
    transform: translateY(-2px) scale(0.992);
    box-shadow: var(--lex-glass-shadow);
  }
  55% {
    transform: translateY(0) scale(1.004);
    box-shadow: var(--lex-glass-shadow-scrolled);
  }
  100% {
    transform: translateY(0) scale(1);
    box-shadow: var(--lex-glass-shadow-scrolled);
  }
}

/* Subtle surface lift behind glass in light mode when scrolled */
html:not(.dark) .lex-glass::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.55) 0%, rgba(248, 250, 252, 0.2) 100%);
  opacity: 0;
  pointer-events: none;
  z-index: -1;
  transition: opacity 0.4s var(--header-ease);
}

.lex-glass--desktop {
  display: none;
}

.lex-glass--mobile {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.35rem;
}

@media (min-width: 1024px) {
  :root {
    --header-offset: 5.75rem;
  }

  .lex-glass--desktop {
    display: flex;
    flex-wrap: nowrap;
    width: 100%;
    min-width: 0;
  }

  .lex-glass--mobile {
    display: none;
  }
}

/* —— Brand —— */
.lex-header__brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
  flex-shrink: 0;
  min-width: 0;
  transition: opacity 0.25s var(--header-ease);
}

.lex-header__brand:hover {
  opacity: 0.88;
}

.lex-header__brand-mark {
  position: relative;
  width: 2rem;
  height: 2rem;
  flex-shrink: 0;
}

@media (min-width: 1024px) {
  .lex-header__brand-mark {
    width: 2.15rem;
    height: 2.15rem;
  }
}

.lex-header__logo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: auto;
  transition: opacity 0.35s ease;
}

.lex-header__logo--light {
  opacity: 1;
}

.lex-header__logo--dark {
  opacity: 0;
}

html.dark .lex-header__logo--light {
  opacity: 0;
}

html.dark .lex-header__logo--dark {
  opacity: 1;
}

.lex-header__brand-name {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--lex-ink);
  white-space: nowrap;
  transition: color 0.3s ease;
}

html.dark .lex-header__brand-name {
  color: var(--lex-white);
}

@media (min-width: 1280px) {
  .lex-header__brand-name {
    font-size: 0.875rem;
  }
}

/* —— Search pill —— */
.lex-header__search {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0.2rem 0.2rem 0.2rem 0.65rem;
  background: rgba(245, 247, 255, 0.85);
  border: 1px solid rgba(160, 167, 194, 0.18);
  border-radius: 999px;
  transition:
    border-color 0.3s var(--header-ease),
    box-shadow 0.3s var(--header-ease),
    background 0.3s var(--header-ease);
}

html.dark .lex-header__search {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.1);
}

.lex-header__search:focus-within {
  border-color: rgba(79, 107, 255, 0.45);
  box-shadow: 0 0 0 3px rgba(79, 107, 255, 0.12);
  background: var(--lex-white);
}

html.dark .lex-header__search:focus-within {
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 0 3px rgba(79, 107, 255, 0.2);
}

/* Font Awesome solid glyphs (full set; regular subset is too limited) */
.lex-glass .fas,
.lex-glass .fa-solid,
.lex-search-expand .fas,
.lex-mobile-menu .fas {
  font-family: "Font Awesome 7 Free", "Font Awesome 5 Free";
  font-weight: 900;
  font-style: normal;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
}

.lex-header__search-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--lex-muted);
  font-size: 0.8rem;
}

.lex-header__search-icon .fas {
  font-size: 0.85rem;
  opacity: 0.75;
}

.lex-header__search-input {
  flex: 1;
  min-width: 0;
  width: 0;
  border: none;
  background: transparent;
  padding: 0.45rem 0.25rem;
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--lex-ink);
  outline: none;
}

html.dark .lex-header__search-input {
  color: var(--lex-white);
}

.lex-header__search-input::placeholder {
  color: var(--lex-muted);
  font-weight: 300;
}

.lex-header__search-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 1.85rem;
  height: 1.85rem;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--lex-blue), var(--lex-violet));
  color: var(--lex-white);
  font-size: 0.65rem;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(79, 107, 255, 0.35);
  transition:
    transform 0.25s var(--header-ease),
    box-shadow 0.25s var(--header-ease),
    filter 0.25s var(--header-ease);
}

.lex-header__search-btn:hover {
  transform: scale(1.06);
  box-shadow: 0 6px 20px rgba(79, 107, 255, 0.45);
  filter: brightness(1.05);
}

.lex-header__search-btn:active {
  transform: scale(0.98);
}

.lex-header__search-btn .fas {
  color: var(--lex-white);
  font-size: 0.65rem;
}

.lex-header__search--expanded {
  padding: 0.35rem 0.35rem 0.35rem 0.85rem;
  background: rgba(255, 255, 255, 0.82);
  border-color: rgba(79, 107, 255, 0.2);
  box-shadow: 0 4px 24px rgba(79, 107, 255, 0.08);
}

html.dark .lex-header__search--expanded {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.14);
}

.lex-header__search--expanded .lex-header__search-input {
  padding: 0.65rem 0.5rem;
  font-size: 0.9375rem;
}

.lex-header__search--expanded .lex-header__search-btn {
  width: 2.15rem;
  height: 2.15rem;
  font-size: 0.72rem;
}

.lex-header__search-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  margin-left: 0.15rem;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--lex-muted);
  font-size: 0.85rem;
  cursor: pointer;
  transition:
    color 0.25s var(--header-ease),
    background 0.25s var(--header-ease);
}

.lex-header__search-close:hover {
  color: var(--lex-ink);
  background: rgba(160, 167, 194, 0.15);
}

html.dark .lex-header__search-close:hover {
  color: var(--lex-white);
  background: rgba(255, 255, 255, 0.1);
}

.lex-header__search-trigger[aria-expanded="true"] {
  color: var(--lex-blue);
  background: rgba(79, 107, 255, 0.12);
}

/* —— Expandable search panel (mobile + desktop) —— */
.lex-search-expand {
  width: 100%;
  margin-top: 0.45rem;
  box-sizing: border-box;
  pointer-events: none;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transform: translateY(-6px);
  transition:
    max-height 0.5s var(--header-ease),
    opacity 0.35s var(--header-ease),
    transform 0.4s var(--header-ease),
    margin 0.35s var(--header-ease);
}

.lex-search-expand.open {
  pointer-events: auto;
  max-height: min(78vh, 580px);
  opacity: 1;
  transform: translateY(0);
  overflow: visible;
}

.lex-search-expand__panel {
  padding: 0.45rem;
  border-radius: 20px;
  background: var(--lex-glass-bg);
  -webkit-backdrop-filter: blur(var(--lex-glass-blur)) saturate(1.35);
  backdrop-filter: blur(var(--lex-glass-blur)) saturate(1.35);
  border: 1px solid var(--lex-glass-border);
  box-shadow: var(--lex-glass-shadow);
}

/* —— Live search results —— */
.lex-search-results {
  margin-top: 0.5rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(160, 167, 194, 0.12);
}

html.dark .lex-search-results {
  border-top-color: rgba(255, 255, 255, 0.08);
}

.lex-search-results__hint,
.lex-search-results__empty {
  padding: 0.65rem 0.5rem 0.45rem;
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--lex-muted);
  text-align: center;
}

.lex-search-results__hint .fa-spin {
  margin-right: 0.35rem;
  color: var(--lex-blue);
}

.lex-search-results__empty strong {
  color: var(--lex-ink);
  font-weight: 500;
}

html.dark .lex-search-results__empty strong {
  color: var(--lex-white);
}

.lex-search-results__link {
  display: inline-block;
  margin-top: 0.35rem;
  color: var(--lex-blue);
  text-decoration: none;
  font-weight: 500;
}

.lex-search-results__track {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  max-height: min(48vh, 340px);
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0.15rem 0.1rem 0.25rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(79, 107, 255, 0.35) transparent;
}

@media (min-width: 640px) {
  .lex-search-results__track {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem;
    max-height: min(52vh, 360px);
  }
}

@media (min-width: 1024px) {
  .lex-search-results__track {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.lex-search-hit {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.5rem 0.55rem;
  border-radius: 14px;
  text-decoration: none;
  color: inherit;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(160, 167, 194, 0.12);
  transition:
    transform 0.22s var(--header-ease),
    box-shadow 0.22s var(--header-ease),
    border-color 0.22s var(--header-ease),
    background 0.22s var(--header-ease);
}

html.dark .lex-search-hit {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
}

.lex-search-hit:hover,
.lex-search-hit:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(79, 107, 255, 0.35);
  box-shadow: 0 8px 24px rgba(79, 107, 255, 0.12);
  background: rgba(255, 255, 255, 0.92);
  outline: none;
}

html.dark .lex-search-hit:hover,
html.dark .lex-search-hit:focus-visible {
  background: rgba(255, 255, 255, 0.1);
}

.lex-search-hit__media {
  flex-shrink: 0;
  width: 4rem;
  height: 4rem;
  border-radius: 12px;
  overflow: hidden;
  background: var(--lex-surface);
  display: flex;
  align-items: center;
  justify-content: center;
}

.lex-search-hit__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: auto;
}

.lex-search-hit__media img.is-fallback {
  object-fit: contain;
  padding: 0.35rem;
  opacity: 0.65;
}

.lex-search-hit__body {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.lex-search-hit__name {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--lex-ink);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

html.dark .lex-search-hit__name {
  color: var(--lex-white);
}

.lex-search-hit__meta {
  font-size: 0.6875rem;
  font-weight: 400;
  color: var(--lex-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lex-search-hit__price-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.1rem;
}

.lex-search-hit__price {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--lex-blue);
}

.lex-search-hit__old {
  font-size: 0.6875rem;
  color: var(--lex-muted);
  text-decoration: line-through;
}

.lex-search-hit__stock {
  font-size: 0.625rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #e85d6a;
  padding: 0.1rem 0.35rem;
  border-radius: 999px;
  background: rgba(232, 93, 106, 0.1);
}

.lex-search-results__footer {
  padding: 0.5rem 0.15rem 0.15rem;
  border-top: 1px solid rgba(160, 167, 194, 0.1);
  margin-top: 0.25rem;
}

html.dark .lex-search-results__footer {
  border-top-color: rgba(255, 255, 255, 0.06);
}

.lex-search-results__all {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  padding: 0.55rem 0.75rem;
  border-radius: 12px;
  font-size: 0.8125rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--lex-white);
  background: linear-gradient(135deg, var(--lex-blue), var(--lex-violet));
  box-shadow: 0 4px 16px rgba(79, 107, 255, 0.28);
  transition:
    transform 0.22s var(--header-ease),
    box-shadow 0.22s var(--header-ease);
}

.lex-search-results__all:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(79, 107, 255, 0.38);
}

.lex-search-results.is-loading .lex-search-results__track {
  display: none;
}

.lex-header--search-open .lex-header__nav {
  opacity: 0;
  visibility: hidden;
  flex: 0 0 0;
  width: 0;
  min-width: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  pointer-events: none;
  transition:
    opacity 0.3s var(--header-ease),
    visibility 0.3s var(--header-ease);
}

.lex-header--search-open .lex-header__mobile-actions > :not(.lex-header__search-trigger) {
  opacity: 0;
  visibility: hidden;
  width: 0;
  min-width: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  pointer-events: none;
}

.lex-header--search-open .lex-header__mobile-actions .lex-header__search-trigger {
  margin-left: auto;
}

/* —— Navigation —— */
.lex-header__nav {
  display: none;
  align-items: center;
  justify-content: center;
  gap: clamp(0.15rem, 0.8vw, 0.5rem);
  flex: 1 1 auto;
  min-width: 0;
  margin-inline: 0.15rem;
}

@media (min-width: 1024px) {
  .lex-header__nav {
    display: flex;
    flex: 1 1 auto;
    justify-content: flex-start;
    padding-left: clamp(0.35rem, 1.2vw, 1rem);
    margin-inline: 0;
  }

  .lex-header__actions {
    margin-left: auto;
  }
}

.lex-header__nav-link {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  padding: 0.35rem clamp(0.45rem, 0.9vw, 0.65rem);
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--lex-nav-muted, var(--lex-muted));
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.28s var(--header-ease);
}

html:not(.dark) .lex-header--scrolled .lex-header__nav-link {
  color: var(--lex-nav-muted-scrolled);
}

html:not(.dark) .lex-header--scrolled .lex-header__nav-link:hover {
  color: var(--lex-ink);
}

html:not(.dark) .lex-header--scrolled .lex-header__icon {
  color: var(--lex-nav-muted-scrolled);
}

html:not(.dark) .lex-header--scrolled .lex-header__icon:hover {
  color: var(--lex-blue);
}

.lex-header__nav-link span {
  line-height: 1.2;
}

.lex-header__nav-link::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0.1rem;
  width: 4px;
  height: 4px;
  margin-left: -2px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--lex-blue), var(--lex-violet));
  opacity: 0;
  transform: scale(0);
  transition:
    opacity 0.28s var(--header-ease),
    transform 0.28s var(--header-ease);
}

.lex-header__nav-link:hover {
  color: var(--lex-ink);
}

html.dark .lex-header__nav-link:hover {
  color: var(--lex-white);
}

.lex-header__nav-link.is-active {
  color: var(--lex-blue);
  font-weight: 500;
}

.lex-header__nav-link.is-active::after {
  opacity: 1;
  transform: scale(1);
}

html.dark .lex-header__nav-link.is-active {
  color: #8b9bff;
}

/* —— Actions & icons —— */
.lex-header__actions,
.lex-header__mobile-actions {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  flex-shrink: 0;
}

@media (min-width: 1024px) {
  .lex-header__actions {
    gap: 0.25rem;
  }
}

.lex-header__mobile-actions {
  gap: 0.1rem;
  margin-left: auto;
  flex-shrink: 0;
}

.lex-header__icon {
  position: relative;
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--lex-muted);
  text-decoration: none;
  font-size: 0.9rem;
  cursor: pointer;
  transition:
    color 0.28s var(--header-ease),
    background 0.28s var(--header-ease),
    transform 0.28s var(--header-ease);
}

.lex-header__icon:hover {
  color: var(--lex-blue);
  background: rgba(79, 107, 255, 0.08);
  transform: translateY(-1px);
}

html.dark .lex-header__icon:hover {
  color: #9aa8ff;
  background: rgba(79, 107, 255, 0.15);
}

.lex-header__theme-icon.fa-sun {
  color: #c4a035;
}

.lex-header__theme-icon.fa-moon {
  color: #9aa8ff;
}

.lex-header__cart-badge {
  position: absolute;
  top: 0.15rem;
  right: 0.1rem;
  min-width: 0.875rem;
  height: 0.875rem;
  padding: 0 0.15rem;
  font-size: 0.5rem;
  font-weight: 600;
  line-height: 1;
  background: linear-gradient(135deg, var(--lex-blue), var(--lex-violet));
  color: var(--lex-white);
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(79, 107, 255, 0.4);
}

.lex-header__cart-badge:empty,
.lex-header__cart-badge[data-count="0"] {
  /* keep zero visible per design */
}

.lex-header__sign-up {
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0.4rem 0.95rem;
  margin-left: 0.15rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--lex-white);
  background: linear-gradient(135deg, var(--lex-blue), var(--lex-violet));
  box-shadow: 0 4px 18px rgba(79, 107, 255, 0.32);
  white-space: nowrap;
  transition:
    transform 0.28s var(--header-ease),
    box-shadow 0.28s var(--header-ease),
    filter 0.28s var(--header-ease);
}

.lex-header__sign-up:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 28px rgba(79, 107, 255, 0.42);
  filter: brightness(1.04);
}

@media (min-width: 1024px) {
  .lex-header__sign-up {
    display: inline-flex;
  }
}

.lex-header__sign-up--mobile {
  display: inline-flex;
  padding: 0.35rem 0.7rem;
  font-size: 0.6875rem;
  margin-left: 0.1rem;
}

.lex-header__menu-btn {
  display: inline-flex;
}

@media (min-width: 1024px) {
  .lex-header__menu-btn {
    display: none;
  }
}

/* —— Mobile menu drawer —— */
.lex-mobile-menu {
  position: fixed;
  top: var(--header-offset, 5.5rem);
  left: var(--site-gutter);
  right: var(--site-gutter);
  z-index: 48;
  max-width: min(var(--site-max), calc(100% - 2 * var(--site-gutter)));
  margin-inline: auto;
  padding: 1rem 1.15rem 1.25rem;
  border-radius: 20px;
  background: var(--lex-glass-bg);
  -webkit-backdrop-filter: blur(var(--lex-glass-blur)) saturate(1.35);
  backdrop-filter: blur(var(--lex-glass-blur)) saturate(1.35);
  border: 1px solid var(--lex-glass-border);
  box-shadow: var(--lex-glass-shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px) scale(0.98);
  transition:
    opacity 0.35s var(--header-ease),
    transform 0.35s var(--header-ease),
    visibility 0.35s;
  pointer-events: none;
}

.lex-mobile-menu.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

@media (min-width: 1024px) {
  .lex-mobile-menu {
    display: none;
  }
}

.lex-mobile-menu__nav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.lex-mobile-menu__link {
  position: relative;
  display: block;
  padding: 0.75rem 0.85rem;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--lex-ink);
  text-decoration: none;
  border-radius: 12px;
  transition:
    color 0.25s var(--header-ease),
    background 0.25s var(--header-ease);
}

.lex-mobile-menu__link:hover {
  color: var(--lex-ink);
  background: rgba(79, 107, 255, 0.06);
}

html.dark .lex-mobile-menu__link:hover {
  color: var(--lex-white);
  background: rgba(79, 107, 255, 0.12);
}

.lex-mobile-menu__link.is-active {
  color: var(--lex-blue);
  font-weight: 600;
  background: rgba(79, 107, 255, 0.1);
}

html.dark .lex-mobile-menu__link {
  color: rgba(245, 247, 255, 0.92);
}

html.dark .lex-mobile-menu__link.is-active {
  color: #9aa8ff;
}

.lex-mobile-menu__footer {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(160, 167, 194, 0.15);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

html.dark .lex-mobile-menu__footer {
  border-top-color: rgba(255, 255, 255, 0.08);
}

.lex-header__mobile-theme {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.7rem 1rem;
  border: 1px solid rgba(160, 167, 194, 0.2);
  border-radius: 14px;
  background: rgba(245, 247, 255, 0.6);
  color: var(--lex-ink);
  font-size: 0.8125rem;
  font-weight: 400;
  cursor: pointer;
  transition: background 0.25s var(--header-ease);
}

.lex-header__mobile-theme:hover {
  background: rgba(79, 107, 255, 0.08);
}

html.dark .lex-header__mobile-theme {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
  color: var(--lex-white);
}

.lex-mobile-menu__auth {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.lex-mobile-menu__sign-in {
  display: block;
  padding: 0.7rem;
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--lex-muted);
  text-decoration: none;
  border-radius: 12px;
  transition: color 0.25s var(--header-ease);
}

.lex-mobile-menu__sign-in:hover {
  color: var(--lex-ink);
}

html.dark .lex-mobile-menu__sign-in:hover {
  color: var(--lex-white);
}

.lex-mobile-menu__cta {
  display: flex !important;
  justify-content: center;
  width: 100%;
  margin-left: 0;
  padding: 0.75rem;
  font-size: 0.875rem;
}

.lex-mobile-menu__sign-out {
  display: block;
  text-align: center;
  font-size: 0.8125rem;
  font-weight: 500;
  color: #e85d6a;
  text-decoration: none;
  padding: 0.5rem;
}

body.lex-menu-open {
  overflow: hidden;
}

@media (max-width: 1023px) {
  :root {
    --header-offset: 4.25rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lex-glass {
    animation: none;
  }

  .lex-header--settled.lex-header--scrolled .lex-glass {
    animation: none;
  }

  .lex-header--hidden {
    transform: none;
    opacity: 1;
  }

  .lex-header,
  .lex-header__icon,
  .lex-header__search-btn,
  .lex-header__sign-up,
  .lex-glass,
  .lex-search-expand,
  .lex-mobile-menu {
    transition-duration: 0.01ms;
  }
}
