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

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

:focus:not(:focus-visible) {
  outline: none;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

html,
body,
#app,
.site-shell,
.site-main,
.home-page {
  background: transparent;
}

body {
  background:
    radial-gradient(circle at top left, rgba(141, 47, 76, 0.035), transparent 24%),
    radial-gradient(circle at top right, rgba(61, 122, 103, 0.028), transparent 22%),
    linear-gradient(180deg, #fffefd 0%, var(--bg) 38%, #f7f4ee 100%);
  color: var(--text);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
  text-rendering: optimizeLegibility;
}

body.menu-open {
  overflow: hidden;
}

body.app-modal-open {
  overflow: hidden;
  padding-right: var(--scrollbar-width, 0px);
}

body.gallery-lightbox-open {
  position: fixed;
  inset: 0;
  overflow: hidden;
  overscroll-behavior: none;
  touch-action: none;
}

body.checkout-redirect-open {
  position: fixed;
  inset: 0;
  overflow: hidden;
  overscroll-behavior: none;
  touch-action: none;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
}

#app {
  min-height: 100vh;
}

@media (max-width: 767.98px) {
  input,
  select,
  textarea {
    font-size: 16px;
  }
}

.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;
}

.hidden {
  display: none !important;
}

/* ─── Toast ─────────────────────────────────────────── */
.app-toast {
  position: fixed;
  top: 24px;
  right: 24px;
  transform: translateY(-12px);
  background: #1a1a1a;
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 10px 20px;
  border-radius: 100px;
  max-width: min(420px, calc(100vw - 32px));
  white-space: normal;
  overflow-wrap: anywhere;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 9999;
  text-align: left;
}

.app-toast.app-toast--success {
  background: #1a6b3a;
}

.app-toast.app-toast--error {
  background: #b91c1c;
}

.app-toast.app-toast--visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 767.98px) {
  .app-toast {
    top: 16px;
    right: 16px;
    left: auto;
    width: fit-content;
    max-width: min(320px, calc(100vw - 32px));
    padding: 10px 14px;
    border-radius: 18px;
    font-size: 0.82rem;
  }
}

.app-cart-action {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-height: 56px;
  padding: 0.8rem 0.9rem 0.8rem 1rem;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(71, 48, 38, 0.1);
  box-shadow: 0 16px 30px rgba(69, 43, 34, 0.1);
  transform: translateY(16px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 9998;
}

.app-cart-action--visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.app-cart-action__copy {
  max-width: 240px;
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.35;
}

.app-cart-action__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 0.95rem;
  border-radius: 999px;
  background: var(--brand);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 800;
  white-space: nowrap;
}

.cookie-notice {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9991;
  display: flex;
  justify-content: stretch;
  opacity: 0;
  transform: translateY(18px);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

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

.cookie-notice__content {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.9rem;
  padding: 0.82rem clamp(16px, 3.2vw, 32px) calc(0.82rem + env(safe-area-inset-bottom));
  border-radius: 0;
  background: rgba(255, 252, 247, 0.96);
  border-top: 1px solid rgba(95, 70, 54, 0.12);
  box-shadow: 0 -10px 24px rgba(57, 39, 31, 0.08);
  backdrop-filter: blur(14px);
}

.cookie-notice__copy {
  display: grid;
  gap: 0.2rem;
  min-width: 0;
  flex: 1 1 auto;
}

.cookie-notice__eyebrow {
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(98, 72, 58, 0.7);
}

.cookie-notice__message {
  margin: 0;
  color: rgba(71, 50, 39, 0.86);
  font-size: 0.88rem;
  line-height: 1.45;
}

.cookie-notice__inline-link {
  display: inline-flex;
  width: fit-content;
  color: rgba(91, 61, 45, 0.8);
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.16em;
}

.cookie-notice__actions {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}

.cookie-notice__button,
.cookie-notice__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 0.9rem;
  border-radius: 999px;
  border: 0;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
  white-space: nowrap;
}

.cookie-notice__button {
  background: #4f382e;
  color: #fffaf4;
}

.cookie-notice__button--secondary {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(95, 70, 54, 0.16);
  color: rgba(71, 50, 39, 0.88);
}

.cookie-notice__button--ghost {
  background: transparent;
  border: 1px dashed rgba(95, 70, 54, 0.22);
  color: rgba(71, 50, 39, 0.78);
}

.cookie-notice__button:hover {
  transform: translateY(-1px);
}

.cookie-preferences {
  position: fixed;
  inset: 0;
  z-index: 9992;
  display: grid;
  place-items: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

.cookie-preferences.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.cookie-preferences__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(43, 30, 24, 0.34);
  border: 0;
}

.cookie-preferences__panel {
  position: relative;
  width: min(620px, 100%);
  display: grid;
  gap: 1rem;
  padding: 1.2rem;
  border-radius: 26px;
  background: #fffdf9;
  border: 1px solid rgba(95, 70, 54, 0.12);
  box-shadow: 0 28px 60px rgba(42, 30, 24, 0.18);
}

.cookie-preferences__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.cookie-preferences__eyebrow {
  display: inline-flex;
  margin-bottom: 0.24rem;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(98, 72, 58, 0.72);
}

.cookie-preferences__title {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.24;
  color: #33241d;
}

.cookie-preferences__close {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  border: 1px solid rgba(95, 70, 54, 0.14);
  background: rgba(252, 248, 242, 0.92);
  color: rgba(71, 50, 39, 0.86);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
}

.cookie-preferences__intro {
  margin: 0;
  color: rgba(71, 50, 39, 0.76);
  font-size: 0.92rem;
  line-height: 1.6;
}

.cookie-preferences__list {
  display: grid;
  gap: 0.75rem;
}

.cookie-preferences__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 0.95rem;
  border-radius: 18px;
  border: 1px solid rgba(95, 70, 54, 0.1);
  background: rgba(255, 250, 244, 0.72);
}

.cookie-preferences__item-copy {
  display: grid;
  gap: 0.28rem;
}

.cookie-preferences__item-copy strong {
  color: #342621;
  font-size: 0.95rem;
}

.cookie-preferences__item-copy span,
.cookie-preferences__state {
  color: rgba(71, 50, 39, 0.72);
  font-size: 0.84rem;
  line-height: 1.55;
}

.cookie-preferences__state--locked {
  font-weight: 700;
}

.cookie-preferences__toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cookie-preferences__toggle input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.cookie-preferences__toggle-ui {
  width: 3rem;
  height: 1.75rem;
  border-radius: 999px;
  background: rgba(95, 70, 54, 0.18);
  box-shadow: inset 0 0 0 1px rgba(95, 70, 54, 0.08);
  transition: background-color 0.18s ease;
}

.cookie-preferences__toggle-ui::after {
  content: "";
  position: absolute;
  top: 0.2rem;
  left: 0.2rem;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 4px 12px rgba(67, 48, 38, 0.18);
  transition: transform 0.18s ease;
}

.cookie-preferences__toggle input:checked + .cookie-preferences__toggle-ui {
  background: #6f4b3c;
}

.cookie-preferences__toggle input:checked + .cookie-preferences__toggle-ui::after {
  transform: translateX(1.25rem);
}

.cookie-preferences__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.7rem;
}

@media (max-width: 767.98px) {
  .cookie-notice {
    left: 0;
    right: 0;
    bottom: 0;
  }

  .cookie-notice__content {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
    padding: 0.6rem 0.72rem calc(0.6rem + env(safe-area-inset-bottom));
    border-radius: 0;
    box-shadow: 0 -8px 18px rgba(57, 39, 31, 0.07);
  }

  .cookie-notice__eyebrow {
    display: none;
  }

  .cookie-notice__message {
    font-size: 0.77rem;
    line-height: 1.34;
  }

  .cookie-notice__inline-link {
    font-size: 0.71rem;
    font-weight: 700;
  }

  .cookie-notice__actions {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.36rem;
  }

  .cookie-notice__button {
    min-width: 0;
    min-height: 34px;
    padding: 0 0.52rem;
    font-size: 0.73rem;
    letter-spacing: -0.01em;
  }

  .cookie-preferences {
    padding: 14px;
    align-items: end;
  }

  .cookie-preferences__panel {
    width: 100%;
    gap: 0.9rem;
    padding: 1rem 0.95rem;
    border-radius: 22px;
  }

  .cookie-preferences__item {
    align-items: flex-start;
  }

  .cookie-preferences__actions {
    flex-wrap: wrap;
    justify-content: stretch;
  }

  .cookie-preferences__actions .cookie-notice__button {
    flex: 1 1 calc(50% - 0.35rem);
  }
}

@media (max-width: 767.98px) {
  .app-cart-action {
    right: 12px;
    left: 12px;
    bottom: calc(max(12px, env(safe-area-inset-bottom)) + 2px);
    gap: 0.7rem;
    min-height: 0;
    padding: 0.72rem 0.76rem 0.72rem 0.84rem;
    border-radius: 16px;
    align-items: center;
  }

  .app-cart-action__copy {
    min-width: 0;
    max-width: none;
    flex: 1 1 auto;
    font-size: 0.84rem;
    line-height: 1.32;
  }

  .app-cart-action__button {
    flex: 0 0 auto;
    min-height: 38px;
    padding: 0 0.82rem;
    font-size: 0.82rem;
    border-radius: 999px;
  }
}

.app-modal-gate {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 10010;
}

.app-modal-gate--visible {
  opacity: 1;
  pointer-events: auto;
}

.app-modal-gate__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26, 18, 14, 0.46);
  backdrop-filter: blur(4px);
}

.app-modal-gate__dialog {
  position: relative;
  width: min(100%, 440px);
  display: grid;
  gap: 0.9rem;
  padding: 1.35rem;
  border: 1px solid rgba(71, 48, 38, 0.12);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 26px 60px rgba(43, 28, 21, 0.16);
}

.app-modal-gate__close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: rgba(141, 47, 76, 0.08);
  color: var(--brand-deep);
  font-size: 1rem;
  font-weight: 700;
}

.app-modal-gate__eyebrow {
  color: var(--text-soft);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.app-modal-gate__title {
  margin: 0;
  padding-right: 2.5rem;
  font-size: 1.6rem;
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.app-modal-gate__copy {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.6;
}

.app-modal-gate__actions {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.25rem;
}

.app-modal-gate__action {
  width: 100%;
}

/* ── Gallery Lightbox ─────────────────────────────── */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 10020;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

.gallery-lightbox--visible {
  opacity: 1;
  pointer-events: auto;
}

.gallery-lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 6, 4, 0.88);
  backdrop-filter: blur(6px);
}

.gallery-lightbox__image {
  position: relative;
  z-index: 1;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.5);
}

.gallery-lightbox__close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  cursor: pointer;
  transition: background 0.15s;
}

.gallery-lightbox__close:hover {
  background: rgba(255, 255, 255, 0.22);
}

.gallery-lightbox__close svg {
  width: 20px;
  height: 20px;
}

.gallery-lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  cursor: pointer;
  transition: background 0.15s;
}

.gallery-lightbox__nav:hover {
  background: rgba(255, 255, 255, 0.24);
}

.gallery-lightbox__nav svg {
  width: 22px;
  height: 22px;
}

.gallery-lightbox__prev { left: 1.25rem; }
.gallery-lightbox__next { right: 1.25rem; }

.gallery-lightbox__image {
  cursor: grab;
}

.gallery-lightbox__image:active {
  cursor: grabbing;
}

@media (hover: none) and (max-width: 767px) {
  .gallery-lightbox__nav {
    width: 22px;
    height: 80px;
    border-radius: 0 6px 6px 0;
    background: rgba(255, 255, 255, 0.1);
    border: none;
  }

  .gallery-lightbox__nav svg {
    width: 14px;
    height: 14px;
  }

  .gallery-lightbox__prev {
    left: 0;
    border-radius: 0 6px 6px 0;
  }

  .gallery-lightbox__next {
    right: 0;
    border-radius: 6px 0 0 6px;
  }

  .gallery-lightbox__nav:hover {
    background: rgba(255, 255, 255, 0.1);
  }
}
