@import url("https://fonts.googleapis.com/css2?family=Bebas+Neue&display=swap");

:root {
  --bg: #0a0a0a;
  --panel: #151515;
  --panel-2: #202020;
  --text: #f3f3f3;
  --muted: #b4b4b4;
  --line: #323232;
  --line-soft: rgba(255, 255, 255, .08);
  --line-strong: rgba(255, 255, 255, .14);
  --red: #e11616;
  --red-dark: #a70f0f;
  --green: #24e65a;
  --white: #ffffff;
  --shadow: 0 24px 80px rgba(0, 0, 0, .38);
  --shadow-panel: 0 18px 48px rgba(0, 0, 0, .22);
  --shadow-overlay: 0 24px 80px rgba(0, 0, 0, .38);
  --shadow-hover: 0 18px 46px rgba(0, 0, 0, .28);
  --radius-panel: 8px;
  --radius-media: 16px;
  --radius-pill: 999px;
  font-family: Inter, "Arial", sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px) 0 0 / 80px 80px,
    radial-gradient(circle at 50% -20%, rgba(225,22,22,.18), transparent 40%);
  opacity: .8;
  z-index: -1;
}

img {
  display: block;
  max-width: 100%;
}

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

button,
input,
textarea {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(150px, 190px) minmax(0, 1fr) minmax(180px, 240px);
  align-items: center;
  gap: 18px;
  width: min(1180px, calc(100% - 28px));
  margin: 14px auto 0;
  padding: 10px 14px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-panel);
  background: rgba(10, 10, 10, .92);
  box-shadow: var(--shadow-overlay);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-height: 52px;
  border-radius: var(--radius-panel);
  color: var(--white);
  font-family: "Bebas Neue", Impact, "Arial Black", sans-serif;
  font-size: 2.1rem;
  letter-spacing: 0;
}

.brand img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.text-brand span {
  line-height: 1;
}

.logo-brand {
  justify-self: start;
  width: clamp(132px, 13vw, 176px);
  padding: 0;
  border: 0;
  background: transparent;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-self: center;
  padding: 6px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-panel);
  background: rgba(255, 255, 255, .02);
  color: var(--muted);
  font-size: 1.02rem;
  font-weight: 900;
}

.main-nav a,
.link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 24px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-panel);
  background: rgba(255, 255, 255, .02);
  color: var(--white);
  cursor: pointer;
  font-weight: 900;
  text-transform: uppercase;
  transition: color .16s ease, background .16s ease, border-color .16s ease, transform .16s ease;
}

.main-nav a:hover,
.main-nav a:focus-visible,
.link-button:hover,
.link-button:focus-visible {
  border-color: rgba(225, 22, 22, .36);
  background: rgba(225, 22, 22, .18);
  color: var(--white);
  outline: 0;
  transform: translateY(-1px);
}

.main-nav a.active {
  border-color: rgba(225, 22, 22, .72);
  background: #e11616;
  color: var(--white);
  box-shadow: 0 10px 24px rgba(225, 22, 22, .22);
}

.link-button[data-reset-store] {
  border-color: rgba(255, 255, 255, .1);
  background: rgba(255, 255, 255, .04);
}

.main-nav a:hover,
.link-button:hover {
  color: var(--white);
}

.link-button {
  padding: 0 16px;
}

.header-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-self: end;
  gap: 8px;
}

.auth-session {
  display: flex;
  align-items: center;
  gap: 8px;
}

.auth-guest {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.auth-guest[hidden],
.auth-user[hidden] {
  display: none !important;
}

.auth-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-panel);
  background: rgba(255, 255, 255, .025);
  color: var(--white);
  cursor: pointer;
  font-size: .76rem;
  font-weight: 900;
  text-transform: uppercase;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

.auth-button:hover,
.auth-button:focus-visible {
  border-color: rgba(225, 22, 22, .5);
  background: rgba(225, 22, 22, .16);
  outline: 0;
  transform: translateY(-1px);
}

.auth-button--secondary {
  border-color: rgba(255, 255, 255, .08);
  background: transparent;
}

.auth-button--secondary:hover,
.auth-button--secondary:focus-visible {
  border-color: rgba(255, 255, 255, .2);
  background: rgba(255, 255, 255, .08);
}

.auth-user {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.auth-avatar {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-pill);
  object-fit: cover;
  background: rgba(255, 255, 255, .05);
  border: 1px solid var(--line-soft);
}

.auth-meta {
  display: grid;
  gap: 1px;
}

.auth-meta strong {
  color: var(--white);
  font-size: .9rem;
  line-height: 1.05;
}

.auth-meta span {
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.05;
}

.auth-signout {
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-panel);
  background: rgba(255, 255, 255, .02);
  color: var(--muted);
  cursor: pointer;
  font-size: .72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auth-signout:hover,
.auth-signout:focus-visible {
  color: var(--white);
  border-color: rgba(255, 255, 255, .16);
  background: rgba(255, 255, 255, .05);
  outline: 0;
}

.auth-greeting {
  max-width: 180px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--white);
  font-size: .82rem;
  font-weight: 900;
}

.auth-profile-button {
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: var(--radius-panel);
  background: rgba(255, 255, 255, .02);
  color: var(--white);
  cursor: pointer;
  font-size: .72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auth-profile-button:hover,
.auth-profile-button:focus-visible {
  border-color: rgba(225, 22, 22, .42);
  background: rgba(225, 22, 22, .14);
  outline: 0;
}

.profile-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 24px;
  pointer-events: none;
  opacity: 0;
  transition: opacity .18s ease;
}

.profile-modal.open {
  opacity: 1;
  pointer-events: auto;
}

.profile-modal__backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 0, 0, .78);
  cursor: pointer;
}

.profile-modal__panel {
  position: relative;
  display: grid;
  gap: 18px;
  width: min(760px, 100%);
  max-height: calc(100vh - 48px);
  overflow: auto;
  padding: 26px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-panel);
  background:
    radial-gradient(circle at 85% 15%, rgba(225, 22, 22, .18), transparent 24%),
    linear-gradient(135deg, rgba(255, 255, 255, .03), rgba(255, 255, 255, .01)),
    #101010;
  box-shadow: var(--shadow-overlay);
}

.profile-modal__header {
  display: grid;
  gap: 8px;
}

.profile-modal__header h2 {
  font-size: clamp(2.2rem, 4vw, 4rem);
}

.profile-modal__header p:last-child {
  max-width: 58ch;
  margin: 0;
}

.profile-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
}

.profile-form {
  display: grid;
  gap: 18px;
}

.profile-form__hero {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-panel);
  background: rgba(255, 255, 255, .025);
}

.profile-form__avatar {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-pill);
  object-fit: cover;
  background: #171717;
}

.profile-form__hero-copy {
  display: grid;
  gap: 4px;
}

.profile-form__hero-copy strong {
  font-size: 1rem;
  color: var(--white);
}

.profile-form__hero-copy span {
  color: var(--muted);
  font-size: .88rem;
}

.profile-form__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.profile-form__full {
  grid-column: 1 / -1;
}

.profile-form__readonly input {
  opacity: .82;
}

.profile-form__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.profile-form__status {
  color: var(--muted);
  font-size: .9rem;
  font-weight: 800;
}

.icon-button {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-panel);
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  color: var(--white);
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
}

.cart-slot {
  display: flex;
  justify-content: flex-end;
  width: 100%;
}

.cart-slot .icon-button {
  width: 52px;
  height: 52px;
  border-color: rgba(255, 255, 255, .18);
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.03));
}

.icon-button svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.cart-count {
  position: absolute;
  top: -8px;
  right: -8px;
  display: grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: var(--radius-pill);
  background: var(--red);
  color: var(--white);
  font-size: .72rem;
  font-weight: 900;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: var(--radius-panel);
  cursor: pointer;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.btn.primary {
  background: var(--red);
  color: var(--white);
}

.btn.primary:hover {
  background: var(--red-dark);
}

.btn.ghost {
  border-color: rgba(255, 255, 255, .16);
  background: rgba(255, 255, 255, .04);
  color: var(--white);
}

.btn.danger {
  background: #2a1010;
  border-color: rgba(225, 22, 22, .5);
  color: #ffb8b8;
}

.btn.full {
  width: 100%;
}

.btn.small {
  min-height: 36px;
  padding: 0 12px;
  font-size: .8rem;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--red);
  font-size: .82rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: Impact, "Arial Black", sans-serif;
  letter-spacing: 0;
  line-height: .95;
  text-transform: uppercase;
}

p {
  color: var(--muted);
  line-height: 1.6;
}

.field {
  display: grid;
  gap: 8px;
}

.field span,
.check-field {
  color: var(--muted);
  font-size: .84rem;
  font-weight: 800;
}

.field input,
.field select,
.field textarea,
.admin-search {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  background: #0f0f0f;
  color: var(--text);
  outline: 0;
}

.field input,
.field select,
.admin-search {
  min-height: 44px;
  padding: 0 12px;
}

.field select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(255,255,255,.72) 50%),
    linear-gradient(135deg, rgba(255,255,255,.72) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) calc(50% - 3px),
    calc(100% - 12px) calc(50% - 3px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

.field textarea {
  min-height: 92px;
  padding: 12px;
  resize: vertical;
}

@media (max-width: 760px) {
  .site-header {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px 12px;
    align-items: center;
  }

  .brand {
    width: clamp(124px, 34vw, 170px);
  }

  .main-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    width: 100%;
    justify-self: stretch;
    gap: 8px;
    overflow-x: visible;
    padding: 7px;
  }

  .main-nav a,
  .link-button {
    flex: 1 1 0;
    min-height: 50px;
    padding: 0 14px;
    font-size: .82rem;
  }

  .header-actions {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    align-self: start;
    min-width: 0;
    gap: 6px;
  }

  .auth-session,
  .auth-guest,
  .auth-user {
    width: auto;
    justify-content: flex-end;
    flex-wrap: wrap;
  }

  .auth-guest {
    gap: 6px;
  }

  .auth-button,
  .auth-profile-button,
  .auth-signout {
    min-height: 26px;
    padding: 0 8px;
    font-size: .62rem;
  }

  .auth-button {
    border-color: rgba(255, 255, 255, .08);
    background: rgba(255, 255, 255, .02);
  }

  .auth-button--secondary {
    border-color: rgba(255, 255, 255, .06);
    background: transparent;
    color: var(--muted);
  }

  .auth-greeting {
    max-width: 88px;
    font-size: .68rem;
  }

  .auth-user {
    gap: 6px;
  }

  .cart-slot {
    width: auto;
  }

  .cart-slot .icon-button {
    width: 42px;
    height: 42px;
  }

  .cart-slot .icon-button svg {
    width: 20px;
    height: 20px;
  }

  .profile-form__grid {
    grid-template-columns: 1fr;
  }

  .profile-form__full {
    grid-column: auto;
  }

  .profile-form__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .profile-modal {
    padding: 14px;
  }

  .profile-modal__panel {
    padding: 20px 16px;
  }
}
