/* ================================================================
   VIV ALBERTINE — V2
   ================================================================ */

/* ------------------------------
   VARIABLES
   ------------------------------ */
:root {
  --space-section: 40px;

  --space-grid: 40px;
  --font-body: "avenir-lt-pro", sans-serif;

  /* Avenir LT Pro: 65 Medium / 85 Heavy */
  --fw-medium: 500;
  --fw-heavy: 800;

  --colour-background-start: #ffb994;
  --colour-background-end: #ffd8bd;
  /* 0 = original gradient; 1 = white */
  --background-lightening: 0.15;
  --colour-news-background: rgba(255, 255, 255, 0.25);
  --colour-rule: rgba(0, 0, 0, 0.20);
  --colour-section-title: rgba(0, 0, 0, 0.70);
  --colour-text: #1a1a1a;
  --colour-accent: #993c31;

  --content-width: 1040px;
  --grid-gap: var(--space-grid);
  --section-gap: clamp(3.5rem, 6vw, 5.5rem);
  --copy-size: 1.1875rem;
  --copy-leading: 1.5789;
}

/* ------------------------------
   RESET / BASE
   ------------------------------ */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body,
h1,
h2,
h3,
p,
figure {
  margin: 0;
}

body {
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--colour-text);
  background:
    linear-gradient(rgba(255, 255, 255, var(--background-lightening)), rgba(255, 255, 255, var(--background-lightening))),
    linear-gradient(135deg, var(--colour-background-start) 0%, var(--colour-background-end) 100%);
  background-attachment: fixed;
  font-size: var(--copy-size);
  line-height: var(--copy-leading);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
  width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

a {
  color: inherit;
  text-decoration: none;
  font-weight: var(--fw-heavy);
}

a:hover {
  text-decoration: none;
}

a[href^="mailto:"],
.accent-copy,
.accent-copy a {
  color: var(--colour-accent);
}

.contact-company {
  font-weight: var(--fw-heavy);
}

.contact-grid a {
  position: relative;
  color: var(--colour-accent);
}

.contact-grid a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.08em;
  width: 100%;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.contact-grid a:hover::after,
.contact-grid a:focus-visible::after {
  transform: scaleX(1);
}

.page-width {
  width: min(var(--content-width), calc(100% - 64px));
  margin-inline: auto;
}

.accent-copy {
  color: var(--colour-accent);
}

/* ------------------------------
   RULED TITLES
   ------------------------------ */
.ruled-title {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.ruled-title .rule {
  flex: 1 1 auto;
  height: 1px;
  background: var(--colour-rule);
}

.ruled-title h2,
.ruled-title h1 {
  flex: 0 0 auto;
  color: var(--colour-section-title);
  font-weight: var(--fw-medium);
  line-height: 1.15;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.ruled-title h2 {
  font-size: 2rem;
}

/* ------------------------------
   HEADER / HERO
   ------------------------------ */
.site-header {
    padding-top: 32px;
}

.site-kicker {
  text-align: center;
  font-size: 0.8125rem;
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--colour-accent);
  font-weight: var(--fw-heavy);
}

.hero {
    padding-block: var(--space-section);
}

.ruled-title--hero h1 {
  color: var(--colour-section-title);
  font-size: 3.5rem;
  font-weight: var(--fw-medium);
  letter-spacing: 0.13em;
  line-height: 1;
}

.portrait {
  width: calc((100% - var(--grid-gap)) / 2);
  margin: var(--space-section) auto 0;
  position: relative;
}

.portrait img {
  aspect-ratio: 0.803 / 1;
  object-fit: cover;
}

.portrait figcaption {
  position: absolute;
  right: 0.35rem;
  bottom: 0.3rem;
  font-size: 0.80rem;
  line-height: 1;
  color: #fff;
}

.bio {
    max-width: 680px;
    margin: 24px auto 0;
    text-align: center;
    font-size: 1.25rem;
    line-height: 1.6;
    font-weight: var(--fw-medium);
}

.bio p:nth-child(n + 2) {
  font-size: 1.15rem;
}

.bio em {
  font-weight: var(--fw-medium);
  font-style: italic;
}

/* Latest News */
.latest-news {
  display: flex;
  align-items: center;
  padding-block: var(--space-section);
  background: var(--colour-news-background);
}

.latest-news-inner {
  width: 100%;
}

.latest-news .accent-copy {
  margin-top: var(--space-section);
  color: var(--colour-accent);
  font-weight: var(--fw-heavy);
  font-size: 1.25rem;
  line-height: 1.45;
  text-align: center;
  position: relative;
  top: -12px;
}

/* ------------------------------
   SECTIONS
   ------------------------------ */
.content-section {
    padding-top: var(--space-section);
}

.content-section > .page-width {
    padding-bottom: 0;
    border-bottom: 0;
}

.content-section .ruled-title {
    margin-bottom: var(--space-section);
}

/* ------------------------------
   MEDIA GRIDS / CARDS
   ------------------------------ */
.media-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--grid-gap);
}

.media-card {
  min-width: 0;
}

/* Books keep the full portrait cover ratio. Music artwork stays square. */
.media-card > img {
  display: block;
  width: 100%;
}

.media-grid--music .media-card > img,
.media-grid--slits .media-card > img {
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.media-grid--books .media-card > img {
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
}

.media-card__copy {
    padding-top: 16px;
}

.media-card__copy h3 {
    margin: 0;
    font-size: 1.25rem;
    line-height: 1.364;
    font-weight: var(--fw-heavy);
}

.media-card__copy h3 span {
  font-weight: var(--fw-medium);
  font-style: normal;
}

.media-card__copy p {
  margin-top: 0.22rem;
  font-size: 1.15rem;
  line-height: 1.5;
  font-weight: var(--fw-medium);
}

 .media-card--featured {
  grid-column: 1 / -1;
  width: calc((100% - var(--grid-gap)) / 2);
  justify-self: center;
}

.media-grid--slits {
    margin-top: var(--space-grid);
}

/* ------------------------------
   CONTACT
   ------------------------------ */
.contact-section .page-width {
    padding-bottom: 1.8rem;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 2rem;
}

.contact-grid h3 {
  margin-bottom: 0.45rem;
  font-size: 1.25rem;
  line-height: 1.36;
  font-weight: var(--fw-heavy);
}

.contact-grid p {
  font-size: 1.15rem;
  line-height: 1.5;
  font-weight: var(--fw-medium);
}

.contact-grid .contact-note {
  font-size: 0.8rem;
  line-height: 1.2;
}

.contact-spacer {
  margin-top: 0.8rem;
}

/* ------------------------------
   FOOTER
   ------------------------------ */
.site-footer {
  padding-block: var(--space-section);
  text-align: center;

  border-top: 1px solid var(--colour-rule);
}

.site-footer p {
  font-size: 0.8rem;
  line-height: 1.2;
}










/* ------------------------------
   CONTACT — COMPACT DESKTOP
   ------------------------------ */
@media (max-width: 1050px) {
  .contact-grid {
    display: block;
    column-count: 2;
    column-gap: 2rem;
  }

  .contact-grid > div {
    break-inside: avoid;
    margin-bottom: 1.5rem;
  }

  .contact-grid > div:nth-child(3) {
    break-before: column;
  }

  .contact-grid h3 {
    margin-bottom: 0.2rem;
  }
}

/* ------------------------------
   TABLET
   ------------------------------ */
@media (max-width: 800px) {
  :root {
    --grid-gap: 28px;
  }

  .page-width {
    width: min(680px, calc(100% - var(--space-grid)));
  }

  .portrait {
    width: min(330px, 65vw);
  }

}

/* ------------------------------
   MOBILE
   ------------------------------ */
@media (max-width: 560px) {
  body {
    background-attachment: scroll;
  }

  .page-width {
    width: calc(100% - 40px);
    max-width: none;
  }

  .site-header {
    padding-top: 1rem;
  }

  .site-kicker {
    font-size: 0.75rem;
    line-height: 1.2;
    letter-spacing: 0.02em;
  }

  .hero {
    padding-block: 1.5rem 2rem;
  }

  .ruled-title {
    gap: 0.5rem;
  }

  .ruled-title h2 {
    font-size: 1.625rem;
    line-height: 1.2;
  }

  .ruled-title--hero h1 {
    font-size: clamp(2.05rem, 10vw, 2.5rem);
    line-height: 1;
    letter-spacing: 0.08em;
  }

  .portrait {
    width: 100%;
    max-width: none;
    margin-top: 1.5rem;
  }

  .bio {
    max-width: none;
    margin-top: 1.5rem;
    font-size: 1.125rem;
    line-height: 1.5;
  }

  .bio p:nth-child(n + 2) {
    font-size: 1rem;
  }

  /* Keep the heading-to-news-copy relationship visible on mobile.
     The -12px optical lift is applied to the copy only. */
  .latest-news {
    padding-block: 20px;
  }

  .latest-news .accent-copy {
    margin-top: 30px;
    font-size: 1.1875rem;
    line-height: 1.45;
    font-weight: var(--fw-heavy);
    text-align: center;
    top: -14px;
  }

  /* Half the desktop section rhythm on mobile. */
  .content-section {
    padding-top: 20px;
  }

  .content-section .ruled-title {
    margin-bottom: 20px;
  }

  .content-section > .page-width {
    padding-bottom: 20px;
  }

  .media-grid,
  .media-grid--slits {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .media-card--featured {
    grid-column: auto;
    width: 100%;
  }

  .media-grid--slits {
    margin-top: 30px;
  }

  .media-card__copy {
    padding-top: 16px;
  }

  .media-card__copy h3 {
    font-size: 1.125rem;
    line-height: 1.45;
  }

  .media-card__copy p {
    margin-top: 0.4rem;
    font-size: 1rem;
    line-height: 1.5;
  }

  .media-card__copy .card-link {
    font-size: 1rem;
    font-weight: var(--fw-heavy);
  }

  .contact-grid {
    display: grid;
    column-count: auto;
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .contact-grid > div:nth-child(n) {
    break-before: auto;
    margin-bottom: 0;
  }

  .contact-grid h3 {
    font-size: 1.25rem;
    line-height: 1.35;
  }

  .contact-grid p {
    font-size: 1rem;
    line-height: 1.5;
  }

  .contact-grid .contact-company {
    font-size: 1.0625rem;
  }

  .site-footer {
    padding-block: 24px;
  }
}

/* ------------------------------
   SCROLL REVEAL
   ------------------------------ */
.js .scroll-reveal {
  opacity: 0.3;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.js .scroll-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.js .typing-word {
  display: inline-block;
  white-space: nowrap;
}

.js .typing-character {
  opacity: 0;
}

.js .latest-news.is-visible .typing-character {
  animation: type-character 1ms step-end forwards;
  animation-delay: var(--character-delay);
}

@keyframes type-character {
  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .js .scroll-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .js .typing-character {
    opacity: 1;
    animation: none;
  }
}

/* Card links in media cards: heavy accent links with expanding underline. */
.media-card__copy .card-link {
  position: relative;
  color: var(--colour-accent);
  font-weight: var(--fw-heavy);
  text-decoration: none;
}

.media-card__copy .card-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.08em;
  width: 100%;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.media-card__copy .card-link:hover::after,
.media-card__copy .card-link:focus-visible::after {
  transform: scaleX(1);
}
