/* ==========================================================================
   Vent Martine — global stylesheet
   Minimal, black on white. One display font drives every piece of text.
   ========================================================================== */

/* Pacaembu swap point ------------------------------------------------------
   When you have the licensed Pacaembu files, drop them in assets/fonts/ and
   uncomment the two blocks below. They take priority over the Raleway /
   Bodoni Moda SC stand-ins automatically — no other file needs to change.

@font-face {
  font-family: 'Pacaembu';
  src: url('../fonts/Pacaembu-Bold.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: 'Pacaembu';
  src: url('../fonts/Pacaembu-Regular.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
--------------------------------------------------------------------------- */

:root {
  --font-display: 'Pacaembu', 'Raleway', sans-serif;
  --font-body: 'Pacaembu', 'Bodoni Moda SC', Georgia, 'Times New Roman', serif;

  --color-bg: #ffffff;
  --color-fg: #000000;
  --color-muted: #767676; /* 4.54:1 on white — passes WCAG AA */
  --color-line: #e2e2e2;

  --header-height: 64px;
  --drawer-width: min(340px, 82vw);
  --page-pad: 24px;
  --maxw: 1400px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-fg);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
.u-display {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

h1 {
  font-size: 1.35rem;
  margin: 0;
}

h2 {
  font-size: 1.05rem;
  margin: 0 0 12px;
}

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

main a:not(.vm-card):not(.vm-btn):not(.vm-footer a) {
  text-decoration: underline;
  text-underline-offset: 2px;
}

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

img {
  height: auto;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

/* Visible keyboard focus everywhere — required for the a11y score. */
:focus-visible {
  outline: 2px solid var(--color-fg);
  outline-offset: 3px;
}

.u-visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.u-skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--color-fg);
  color: var(--color-bg);
  padding: 12px 18px;
  font-size: 0.8rem;
}

.u-skip-link:focus {
  left: 0;
}

/* ------------------------------- Header -------------------------------- */

.vm-header {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--header-height);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding: 0 var(--page-pad);
  z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(140%) blur(6px);
}

.vm-header__menu {
  display: flex;
  flex-direction: column;
  justify-content: center;
  justify-self: start;
  gap: 5px;
  width: 30px;
  height: 30px;
  padding: 0;
}

.vm-header__menu span {
  display: block;
  height: 2px;
  width: 22px;
  background: var(--color-fg);
}

.vm-header__logo {
  grid-column: 2;
  justify-self: center;
}

.vm-header__logo img {
  height: 34px;
  width: auto;
}

/* ----------------------------- Nav drawer ------------------------------ */

.vm-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 45;
}

.vm-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--drawer-width);
  background: var(--color-bg);
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.65, 0, 0.35, 1);
  z-index: 50;
  padding: 20px 26px 40px;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

body.vm-nav-open .vm-drawer {
  transform: translateX(0);
}

body.vm-nav-open .vm-drawer-overlay {
  opacity: 1;
  visibility: visible;
}

.vm-drawer__close {
  align-self: flex-end;
  font-size: 1.6rem;
  line-height: 1;
  width: 34px;
  height: 34px;
  margin-bottom: 26px;
}

.vm-drawer__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.vm-drawer__list a {
  font-family: var(--font-display);
  font-weight: 100;
  font-size: 1.5525rem; /* 1.15rem base, +35% */
}

.vm-drawer__list a:hover,
.vm-drawer__list a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.vm-drawer__list a[aria-current='page'] {
  text-decoration: underline;
  text-underline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .vm-drawer,
  .vm-drawer-overlay {
    transition: none;
  }
}

/* ------------------------------- Layout -------------------------------- */

.vm-main {
  padding-top: var(--header-height);
  min-height: 60vh;
}

.vm-section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 40px var(--page-pad) 72px;
  scroll-margin-top: var(--header-height);
}

/* Homepage intro copy sits directly above the shop grid with no gap
   between them — they read as one continuous section while scrolling. */
#intro {
  padding-bottom: 0;
}

#shop {
  padding-top: 0;
}

.vm-eyebrow {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 0 0 20px;
}

.vm-prose {
  max-width: 62ch;
}

.vm-prose h2 {
  margin-top: 34px;
}

.vm-prose p,
.vm-prose li {
  font-size: 0.95rem;
}

/* --------------------------- Homepage videos --------------------------- */

.vm-reel {
  display: block;
}

.vm-reel__item {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 1; /* wide letterboxed display; crop, don't resize, the source video */
  min-height: 160px; /* floor so very narrow screens still show a usable strip */
  background: #f2f2f0;
  overflow: hidden;
}

.vm-reel__item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center; /* crop symmetrically top/bottom, never shift off the horizontal centerline */
}

/* Museum clip (3rd of 5) — shifted up slightly so less headroom is cropped
   off the top of the frame. Applies to the poster still too, since a
   video's poster uses the same object-fit/object-position as the video. */
.vm-reel__item:nth-child(3) video {
  object-position: center 35%;
}

/* ----------------------------- Product grid ---------------------------- */

.vm-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 40px 24px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.vm-card {
  display: block;
}

.vm-card img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: #f2f2f0;
}

.vm-card__media {
  position: relative;
  display: block;
}

.vm-card__hover {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  /* Opaque backdrop so the reduced-opacity image below actually reads as
     "faded" instead of blending invisibly into the identical photo
     underneath it. */
  background: var(--color-bg);
}

.vm-card:hover .vm-card__hover,
.vm-card:focus-visible .vm-card__hover {
  opacity: 1;
}

.vm-card__hover img {
  position: absolute;
  inset: 0;
  opacity: 0.5;
}

.vm-card__hover-label {
  position: absolute;
  inset: 0 0 50% 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  text-align: center;
  color: #000;
  font-family: var(--font-display); /* Raleway, same family as body text */
  font-weight: 100;
  font-size: clamp(2rem, 7vw, 3.5rem);
  letter-spacing: 0.05em;
}

@media (prefers-reduced-motion: reduce) {
  .vm-card__hover {
    transition: none;
  }
}

.vm-card__meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-top: 12px;
}

.vm-card__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.82rem;
  display: block;
}

.vm-card__color {
  font-size: 0.78rem;
  color: var(--color-muted);
  display: block;
  margin-top: 2px;
}

.vm-card__price {
  font-size: 0.82rem;
  white-space: nowrap;
}

/* -------------------------------- Gallery -------------------------------- */

.vm-gallery {
  columns: 3 320px;
  column-gap: 24px;
}

.vm-gallery__item {
  position: relative;
  display: block;
  overflow: hidden;
  background: #f2f2f0;
  margin: 0 0 24px;
  break-inside: avoid;
}

.vm-gallery__item img {
  width: 100%;
  display: block;
  object-fit: cover;
}

.vm-gallery__item:nth-child(3n+1) img {
  aspect-ratio: 4 / 3;
}

.vm-gallery__item:nth-child(3n+2) img {
  aspect-ratio: 1 / 1;
}

.vm-gallery__item:nth-child(3n) img {
  aspect-ratio: 5 / 4;
}

.vm-gallery__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 22px 14px 12px;
  color: #fff;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0));
}

/* ---------------------------- Product detail --------------------------- */

.vm-product {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 48px;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 32px var(--page-pad) 80px;
}

.vm-product__gallery {
  position: relative;
}

.vm-product__gallery img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: #f2f2f0;
}

.vm-product__views {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.vm-product__views button {
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 8px 16px;
  border: 1px solid var(--color-fg);
  background: var(--color-bg);
}

.vm-product__views button[aria-pressed='true'] {
  background: var(--color-fg);
  color: var(--color-bg);
}

.vm-product__color {
  font-size: 0.9rem;
  color: var(--color-muted);
  margin: 8px 0 0;
}

.vm-product__specs {
  margin: 22px 0 0;
  padding-left: 18px;
  font-size: 0.88rem;
  line-height: 1.75;
}

.vm-product__specs li {
  margin-bottom: 2px;
}

.vm-product__price {
  font-size: 0.95rem;
  margin: 26px 0 0;
}

.vm-btn {
  display: inline-block;
  margin-top: 20px;
  border: 1px solid var(--color-fg);
  background: var(--color-bg);
  padding: 14px 30px;
  font-size: 0.78rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.vm-btn:hover {
  background: var(--color-fg);
  color: var(--color-bg);
}

.vm-note {
  font-size: 0.78rem;
  color: var(--color-muted);
  margin-top: 14px;
}

/* ------------------------------ Collections ---------------------------- */

.vm-drop {
  display: block;
  max-width: 620px;
}

.vm-drop img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: #f2f2f0;
}

.vm-drop__meta {
  margin-top: 12px;
}

.vm-drop__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
}

.vm-drop__detail {
  font-size: 0.8rem;
  color: var(--color-muted);
}

/* -------------------------------- Forms -------------------------------- */

.vm-form {
  max-width: 520px;
  margin-top: 26px;
}

.vm-field {
  margin-bottom: 20px;
}

.vm-field label {
  display: block;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 7px;
}

.vm-field input,
.vm-field select,
.vm-field textarea {
  width: 100%;
  font: inherit;
  font-size: 0.92rem;
  color: var(--color-fg);
  background: var(--color-bg);
  border: 1px solid var(--color-fg);
  border-radius: 0;
  padding: 11px 12px;
  -webkit-appearance: none;
  appearance: none;
}

.vm-field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23000' fill='none' stroke-width='1.4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 34px;
}

.vm-field textarea {
  min-height: 150px;
  resize: vertical;
}

.vm-field__hint {
  font-size: 0.76rem;
  color: var(--color-muted);
  margin-top: 5px;
}

/* Honeypot — hidden from humans, still reachable by naive bots. */
.vm-hp {
  position: absolute !important;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.vm-form__status {
  margin-top: 16px;
  font-size: 0.86rem;
}

.vm-form__status[data-state='error'] {
  color: #a32d2d;
}

/* -------------------------------- Footer -------------------------------- */

.vm-footer {
  border-top: 1px solid var(--color-line);
  padding: 44px var(--page-pad) 40px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.vm-footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 32px;
}

.vm-footer h2 {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 0 0 14px;
}

.vm-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.vm-footer a {
  font-size: 0.85rem;
}

.vm-footer a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.vm-social {
  display: flex;
  gap: 14px;
  align-items: center;
}

.vm-social a {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-line);
}

.vm-social a:hover {
  border-color: var(--color-fg);
}

.vm-social svg {
  width: 17px;
  height: 17px;
  fill: currentColor;
}

.vm-footer__base {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  justify-content: space-between;
  align-items: center;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--color-line);
  font-size: 0.75rem;
  color: var(--color-muted);
}

/* ------------------------------ Responsive ------------------------------ */

@media (max-width: 880px) {
  .vm-product {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .vm-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 28px 16px;
  }

  .vm-gallery {
    columns: 2 220px;
    column-gap: 16px;
  }

  .vm-gallery__item {
    margin-bottom: 16px;
  }
}

@media (max-width: 520px) {
  :root {
    --page-pad: 18px;
  }

  .vm-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .vm-gallery {
    columns: 1;
  }
}
