@font-face {
  font-family: "Crimson Text";
  src: url("../assets/fonts/Crimson_Text/CrimsonText-Regular.ttf")
    format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Crimson Text";
  src: url("../assets/fonts/Crimson_Text/CrimsonText-SemiBold.ttf")
    format("truetype");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}

:root {
  color-scheme: dark;
  font-family: "Crimson Text", Georgia, serif;
  color: #e9e6df;
  background: #050605;
  --color-gold: #e0c998;
  --color-new: #fa7f99;
  --color-online: #35d957;
  --gold-icon-filter: brightness(0) saturate(100%) invert(88%) sepia(17%)
    saturate(612%) hue-rotate(354deg) brightness(94%) contrast(88%);
  --color-gold-subtle: color-mix(in srgb, var(--color-gold) 25%, transparent);
  --site-header-height: 92px;
  --content-gutter: 15px;
  --content-max-width: 1265px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
}

button,
input,
select {
  font: inherit;
}

button,
a,
input {
  -webkit-tap-highlight-color: transparent;
}

button,
a {
  touch-action: manipulation;
}

button {
  cursor: pointer;
}

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

button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 1px solid #00000000;
}

[hidden] {
  display: none !important;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  max-height: 100dvh;
  overflow-y: auto;
  background: rgb(5 6 5 / 25%);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.site-header__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px 40px;
  grid-template-rows: var(--site-header-height);
  align-items: center;
  column-gap: 2px;
  width: calc(100% - 2 * var(--content-gutter));
  max-width: var(--content-max-width);
  min-height: var(--site-header-height);
  margin-inline: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  width: fit-content;
}

.brand__logo {
  display: block;
  flex-shrink: 0;
  width: clamp(110px, calc(54vw - 45.43px), 165px);
}

.brand__logo img {
  display: block;
  width: 100%;
  height: auto;
}

.brand__tagline {
  padding-top: 0;
  color: #d5d2cd;
  font-size: clamp(7px, 2.3vw, 9px);
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  white-space: nowrap;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #f6edda;
  transition:
    background-color 160ms ease,
    opacity 160ms ease;
}

.icon-button img,
.header-search__submit img {
  display: block;
  filter: brightness(0) saturate(100%) invert(94%) sepia(15%) saturate(345%)
    hue-rotate(347deg) brightness(101%) contrast(93%);
}

.search-toggle {
  grid-column: 2;
  grid-row: 1;
}

.menu-toggle {
  position: relative;
  grid-column: 3;
  grid-row: 1;
}

.menu-toggle__lines {
  display: grid;
  gap: 5px;
  width: 22px;
}

.menu-toggle__lines span {
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  box-shadow: 0 1px 1px color-mix(in srgb, var(--color-gold) 40%, transparent);
  transition:
    transform 160ms ease,
    opacity 160ms ease;
}

.menu-toggle[aria-expanded="true"] .menu-toggle__lines span:first-child {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle__lines span:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] .menu-toggle__lines span:last-child {
  transform: translateY(-7px) rotate(-45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle__notification {
  display: none;
}

.menu-toggle__notification {
  position: absolute;
  top: 9px;
  right: 7px;
  width: 10px;
  height: 10px;
  border: 1.5px solid var(--color-gold);
  border-radius: 50%;
  background: #d93648;
}

.header-search {
  display: none;
  grid-column: 1 / -1;
  align-items: center;
  min-width: 0;
  height: 38px;
  margin-bottom: 16px;
  border: 1px solid rgb(230 227 218 / 24%);
  border-radius: 6px;
  background: rgb(5 6 5 / 26%);
  transition: border-color 160ms ease;
}

.header-search:focus-within {
  border-color: var(--color-gold);
}

.site-header.is-search-open .header-search {
  display: flex;
}

.header-search input {
  width: 100%;
  min-width: 0;
  height: 100%;
  padding: 0 11px;
  border: 0;
  border-radius: inherit;
  background: transparent;
  color: #e9e6df;
  font-size: 14px;
}

.header-search input::placeholder {
  color: #93928d;
  opacity: 1;
}

.header-search__submit {
  display: grid;
  flex-shrink: 0;
  place-items: center;
  width: 34px;
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: inherit;
  background: transparent;
  transition:
    background-color 160ms ease,
    opacity 160ms ease;
}

.header-favorites {
  display: none;
}

.header-menu {
  display: none;
  grid-column: 1 / -1;
  padding-block: 8px 20px;
  border-top: 1px solid var(--color-gold-subtle);
}

.site-header.is-menu-open .header-menu {
  display: block;
  animation: header-reveal 160ms ease;
}

.header-nav {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}

.header-nav__link {
  display: flex;
  align-items: center;
  min-height: 44px;
  width: fit-content;
  font-size: 17px;
  font-weight: 600;
  transition:
    color 160ms ease,
    opacity 160ms ease;
}

.header-nav__link[aria-current="page"] {
  color: var(--color-gold);
}

.header-account {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-top: 12px;
  color: var(--color-gold);
  font-size: 16px;
  font-weight: 600;
}

.header-account a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  transition:
    color 160ms ease,
    background-color 160ms ease,
    opacity 160ms ease;
}

.header-account__register {
  padding-inline: 16px;
  border: 1px solid var(--color-gold);
  border-radius: 6px;
  box-shadow:
    0 0 2px color-mix(in srgb, var(--color-gold) 36%, transparent),
    inset 0 0 2px color-mix(in srgb, var(--color-gold) 20%, transparent);
}

@media (hover: hover) {
  .icon-button:hover,
  .header-search__submit:hover,
  .header-account__register:hover {
    background: color-mix(in srgb, var(--color-gold) 10%, transparent);
  }

  .header-nav__link:hover,
  .header-account__login:hover {
    color: var(--color-gold);
  }

  .brand:hover {
    opacity: 0.9;
  }
}

.site-header a:active,
.site-header button:active {
  opacity: 0.65;
}

@media (min-width: 900px) {
  :root {
    --content-gutter: 56px;
  }

  .site-header {
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
  }
}

@media (min-width: 1100px) {
  :root {
    --site-header-height: 72px;
  }

  .site-header__inner {
    grid-template-columns:
      220px minmax(0, 1fr) clamp(170px, calc(20vw - 50px), 216px)
      28px 124px;
    column-gap: clamp(12px, calc(3vw - 21px), 24px);
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
    gap: 12px;
  }

  .brand__logo {
    width: 126px;
  }

  .brand__tagline {
    padding-top: 0;
    font-size: 8px;
    line-height: 1.5;
    letter-spacing: 0.23em;
  }

  .search-toggle,
  .menu-toggle {
    display: none;
  }

  .header-search {
    display: flex;
    grid-column: 3;
    grid-row: 1;
    height: 34px;
    margin: 0;
  }

  .header-search input {
    font-size: 11px;
  }

  .header-search__submit img {
    width: 15px;
    height: 15px;
  }

  .header-favorites {
    display: inline-flex;
    grid-column: 4;
    grid-row: 1;
    width: 28px;
  }

  .header-favorites img {
    filter: none;
    opacity: 0.85;
  }

  .header-menu,
  .site-header.is-menu-open .header-menu {
    display: contents;
  }

  .header-nav {
    grid-column: 2;
    grid-row: 1;
    flex-direction: row;
    align-items: center;
    gap: clamp(24px, 2.2vw, 34px);
    margin-left: 16px;
    white-space: nowrap;
  }

  .header-nav__link {
    min-height: 40px;
    padding-top: 0;
    border-bottom: 2px solid transparent;
    font-size: 14px;
    line-height: 1;
  }

  .header-nav__link[aria-current="page"] {
    border-bottom-color: var(--color-gold);
  }

  .header-account {
    grid-column: 5;
    grid-row: 1;
    justify-content: space-between;
    gap: 12px;
    margin: 0;
    font-size: 13px;
  }

  .header-account a {
    min-height: 34px;
  }

  .header-account__register {
    padding-inline: 16px;
  }
}

@media (min-width: 1180px) {
  .header-nav {
    margin-left: 47px;
  }
}

@keyframes header-reveal {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-header *,
  .site-header *::before,
  .site-header *::after {
    animation: none !important;
    transition: none !important;
  }
}
