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

html {
  scroll-behavior: smooth;
  font-size: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  img[data-elizfan-img] {
    opacity: 1;
    transition: none;
  }

  .hero-slide img,
  .collection-card .card-visual img,
  .product-card .thumb img,
  .product-card,
  .filter-btn,
  .hero-arrow,
  .home-rail-arrow,
  .pdp-arrow {
    transition: none;
  }

  @media (hover: hover) {
    .hero-slide:hover img {
      transform: none;
    }

    .collection-card:hover .card-visual img,
    .collection-card:focus-within .card-visual img {
      transform: none;
    }

    .product-card:hover {
      transform: none;
    }
  }

  .product-card:focus-visible {
    transform: none;
  }
}

body {
  margin: 0;
  background: var(--bg, #f7f6f4);
  color: var(--fg, #391f27);
  font-family: var(--font, "Times New Roman", Times, serif);
  font-size: var(--text-base, 1.2rem);
  line-height: 1.65;
  font-weight: var(--weight, 300);
}

/* Body copy: centered paragraphs */
p {
  font-size: var(--text-base);
  text-align: center;
  overflow-wrap: break-word;
  word-break: normal;
  text-wrap: pretty;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: var(--weight, 300);
  text-align: center;
  text-wrap: balance;
}

h1 {
  font-size: var(--text-hero);
  line-height: 1.15;
}

h2 {
  font-size: var(--text-2xl);
  line-height: 1.18;
}

h3 {
  font-size: var(--text-xl);
  line-height: 1.2;
}

h4 {
  font-size: var(--text-lg);
  line-height: 1.22;
}

h5 {
  font-size: var(--text-lede);
  line-height: 1.24;
}

h6 {
  font-size: var(--text-base);
  line-height: 1.25;
}

b,
strong {
  font-weight: var(--weight, 300);
}

button,
input,
select,
textarea {
  font-family: inherit;
  font-weight: var(--weight, 300);
}

a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--border, var(--line));
  transition: opacity 0.2s var(--ease), border-color 0.2s var(--ease);
}

a:hover {
  opacity: 1;
  border-bottom-color: var(--accent);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
  z-index: 400;
  padding: 0.85rem 1.35rem;
  background: var(--fg);
  color: var(--bg);
  font-family: var(--font-sans);
  font-size: var(--text-ui);
  font-weight: var(--weight, 300);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: none;
}

.skip-link:focus {
  position: fixed;
  left: 1rem;
  top: 1rem;
  width: auto;
  height: auto;
  overflow: visible;
  outline: 3px solid var(--bg);
  outline-offset: 2px;
  box-shadow: var(--shadow-card);
}

button:focus-visible,
.filter-btn:focus-visible,
.hero-arrow:focus-visible,
.home-rail-arrow:focus-visible,
.pdp-arrow:focus-visible,
.hero-dot:focus-visible,
.home-rail .hero-dot:focus-visible,
.menu-toggle:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 3px;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
  border-radius: 0;
}

img[data-elizfan-img] {
  opacity: 0;
  transition: opacity 0.35s ease;
}

img[data-elizfan-img].is-loaded {
  opacity: 1;
}

/* PLP thumbs: opacity governed by default/worn stack, not page-load fade */
.product-card .thumb img[data-elizfan-img] {
  transition: opacity var(--product-thumb-fade) var(--product-thumb-ease);
}

.product-card .thumb img.default[data-elizfan-img],
.product-card .thumb img.default[data-elizfan-img].is-loaded {
  opacity: 1;
}

.product-card .thumb img.worn[data-elizfan-img] {
  opacity: 0;
}

picture {
  border-radius: 0;
}
