@font-face {
  font-family: "DM Serif Display";
  src: url("_assets/_fonts/DMSerifDisplay-Regular.ttf") format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Bodoni Moda";
  src: url("_assets/_fonts/BodoniModa-Variable.ttf") format("truetype");
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
}

@font-face {
  font-family: "Cormorant Garamond";
  src: url("_assets/_fonts/CormorantGaramond-Variable.ttf") format("truetype");
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
}

@font-face {
  font-family: "Barlow Semi Condensed";
  src: url("_assets/_fonts/BarlowSemiCondensed-Regular.ttf") format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Barlow Semi Condensed";
  src: url("_assets/_fonts/BarlowSemiCondensed-Medium.ttf") format("truetype");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  color: #111;
  background: #fff;
  font-family: "Barlow Semi Condensed", Arial, sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }

html { min-width: 320px; }

body { margin: 0; }

.business-card {
  width: min(100% - clamp(2.5rem, 8vw, 8rem), 72rem);
  min-height: 100svh;
  margin-inline: auto;
  padding-block: clamp(1.25rem, 3vh, 2.5rem);
  display: grid;
  justify-items: center;
  align-content: safe center;
  gap: clamp(1.1rem, 2.25vh, 1.75rem);
}

@media (min-height: 48rem) {
  .business-card { transform: translateY(-1rem); }
}

.masthead {
  grid-row: 1;
  margin-bottom: clamp(.4rem, 1.15vh, .75rem);
  text-align: center;
}

.landscape-text { display: contents; }

h1 {
  margin: 0;
  font-family: "Cormorant Garamond", "DM Serif Display", Georgia, serif;
  font-size: clamp(2.7rem, 4.1vw, 4.35rem);
  font-weight: 600;
  line-height: .84;
  letter-spacing: -.018em;
  text-transform: uppercase;
}

.masthead p {
  margin: clamp(.55rem, 1vw, .85rem) 0 0;
  font-size: clamp(1.45rem, 2.1vw, 2.2rem);
  font-weight: 500;
  letter-spacing: -.04em;
}

/* Main portrait: the artwork remains a square, like a printed image. */
.artwork {
  grid-row: 2;
  width: min(100%, clamp(18rem, 40vw, 34rem));
  height: auto;
  aspect-ratio: 1;
  margin: 0;
  overflow: hidden;
  background: #f2f0ec;
  position: relative;
}

.artwork img,
.artwork video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.artwork video { position: absolute; inset: 0; }

.contact {
  grid-row: 3;
  width: min(100%, 32rem);
  margin: clamp(1.1rem, 2.25vh, 1.75rem) 0 0;
  padding: 0;
  text-align: center;
  font-size: clamp(1.05rem, 1.45vw, 1.35rem);
  font-style: normal;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.03em;
}

.contact p { margin: 0; }
.contact p + p { margin-top: .18rem; }
.contact .instagram { margin-top: clamp(.85rem, 1.5vw, 1.35rem); }
.contact .legal {
  margin-top: clamp(1.1rem, 1.8vw, 1.5rem);
  font-size: .72em;
  opacity: .65;
}

.legal a:hover,
.legal a:focus-visible { text-decoration: underline; }

a {
  color: inherit;
  overflow-wrap: anywhere;
  text-decoration: none;
}

a:visited { color: inherit; }
a:hover { color: #b50400; } /* #8a351d | #b50400 | */
a:focus-visible { outline: 2px solid #8a351d; outline-offset: 4px; }

/* Legal dialogs */
dialog {
  width: min(calc(100% - 2.5rem), 34rem);
  max-height: 85svh;
  padding: 2rem;
  overflow-y: auto;
  color: #111;
  border: 0;
  border-radius: 16px;
  background: #fff;
  font: inherit;
  line-height: 1.55;
  box-shadow: 0 1.25rem 4rem rgb(0 0 0 / .12);
  opacity: 0;
  transform: scale(.98);
  transition: opacity 180ms ease, transform 180ms ease;
}

dialog[open] {
  opacity: 1;
  transform: scale(1);
}

@starting-style {
  dialog[open] {
    opacity: 0;
    transform: scale(.98);
  }
}

dialog::backdrop {
  background: rgb(255 255 255 / .62);
  backdrop-filter: blur(2px);
  transition: background 180ms ease, backdrop-filter 180ms ease;
}

dialog h2 {
  margin: 0 2.5rem 1.75rem 0;
  font-family: "Barlow Semi Condensed", Arial, sans-serif;;
  font-size: clamp(2.15rem, 6vw, 2.75rem);
  font-weight: 600;
  line-height: .95;
  letter-spacing: -.02em;
}

dialog h3 { margin: 2rem 0 .5rem; font-size: 1.1em; font-weight: 700; }
dialog section:first-of-type h3 { margin-top: 0; }
dialog p { max-width: 42ch; margin: .65rem 0 0; }
dialog address { font-style: normal; }

.dialog-close {
  position: absolute;
  top: 0.1rem;
  right: 0.1rem;
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  color: inherit;
  border: 0;
  background: none;
  font: inherit;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  place-items: center;
}

.dialog-close:hover { background: rgb(0 0 0 / 0); }
.dialog-close:active { transform: scale(1.2); }
.dialog-close:focus-visible { outline: none; }

@media (max-width: 42rem) {
  dialog { padding: 1.5rem; }
  dialog h2 {
    margin-bottom: 1.5rem;
    font-family: "Barlow Semi Condensed", Arial, sans-serif;
    font-weight: 600;
  }
  dialog h3 { margin-top: 1.75rem; }
  .dialog-close { font-family: "Barlow Semi Condensed", Arial, sans-serif; font-weight: 400; }
  .contact .legal { margin-top: 1.5rem; font-size: 0.9em; opacity: .55; }
}

@media (prefers-reduced-motion: reduce) {
  dialog,
  dialog::backdrop,
  .dialog-close { transition: none; }
}

@media (prefers-reduced-motion: reduce) {
  .artwork video { display: none; }
}

/* Phone portrait: keep the artwork square and the type comfortably legible. */
@media (max-width: 42rem) and (orientation: portrait) {
  .business-card {
    width: min(100% - 2.5rem, 30rem);
    gap: clamp(1rem, 2.4svh, 1.35rem);
  }

  @media (min-height: 40rem) {
    .business-card { transform: translateY(-.6rem); }
  }

  h1 { font-size: clamp(2.35rem, 10vw, 3.3rem); }
  .masthead p { font-size: clamp(1.35rem, 5.8vw, 1.7rem); }
  .artwork { width: min(100%, 20rem, 42svh); }

  .contact { font-size: clamp(1.05rem, 4.4vw, 1.25rem); }
}

/* Phone landscape: use the still image alongside compact contact details. */
@media (max-width: 58rem) and (max-height: 34rem) and (orientation: landscape) {
  .business-card {
    width: min(100% - 2rem, 60rem);
    min-height: 100svh;
    grid-template-columns: minmax(0, min(44vw, calc(100svh - 2.5rem))) minmax(0, 1fr);
    grid-template-rows: auto;
    column-gap: clamp(1.25rem, 3vw, 2.5rem);
    row-gap: .65rem;
    align-content: center;
    align-items: start;
    justify-items: start;
    padding-block: 1rem;
    transform: none;
  }

  .landscape-text {
    display: flex;
    grid-column: 2;
    grid-row: 1 / span 2;
    width: 100%;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: clamp(1.15rem, 4svh, 1.9rem);
    align-self: stretch;
  }

  .masthead { padding: 0; margin: 0; text-align: center; }
  h1 { font-size: clamp(2.1rem, 4.7vw, 3.25rem); }
  .masthead p { margin-top: .25rem; }
  .artwork { grid-column: 1; grid-row: 1 / span 2; width: 100%; height: auto; aspect-ratio: 1; max-height: calc(100svh - 2.5rem); align-self: center; }
  .contact { width: 100%; padding: 0; margin: 0; text-align: center; font-size: clamp(.9rem, 1.85vw, 1.05rem); }
  .contact .instagram { margin-top: .9rem; }
  .contact .legal { margin-top: .8rem; }
}
