/*
  Eve Kuaför — site stylesheet, part 2: the home page and its scroll-linked motion (see js/home.js).
*/

/* ---------- home: hero ---------- */

.zy-home { color: var(--zy-cream); }
.zy-home .page-body { margin: 0; }

.zy-hero {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-rows: auto 1fr auto auto;
  column-gap: 20px;
  min-height: calc(100vh - 2 * var(--zy-edge));
  min-height: calc(100svh - 2 * var(--zy-edge));
  margin: var(--zy-edge);
  padding: 170px var(--zy-gutter) 96px;
  box-sizing: border-box;
  border-radius: var(--zy-r-frame);
  overflow: hidden;
  background-color: var(--zy-olive);
  isolation: isolate;
}
/* the photograph is an <img> filled from the home picture settings, so an administrator can swap it */
.zy-hero__bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 70% 30%; display: block; }
.zy-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(rgba(22, 22, 5, .62), rgba(40, 38, 10, .5) 45%, rgba(22, 22, 5, .78)); }

.zy-hero__words { display: contents; }
.zy-hero__word {
  font: 300 clamp(64px, 11.500vw, 172px)/.9 var(--zy-serif);
  letter-spacing: -0.035em;
  text-transform: lowercase;
  color: var(--zy-sky);
  white-space: nowrap;
}
.zy-hero__word--1 { grid-column: 2 / 9; grid-row: 1; }
.zy-hero__word--2 { grid-column: 9 / 13; grid-row: 2; align-self: center; justify-self: end; }
.zy-hero__word--3 { grid-column: 4 / 9; grid-row: 3; align-self: end; }

.zy-hero__frame {
  grid-column: 4 / 9; grid-row: 2;
  position: relative; align-self: center;
  display: block; margin: 26px 0;
  aspect-ratio: 16 / 10;
  border-radius: var(--zy-r-picture);
  overflow: hidden;
  color: var(--zy-cream);
}
.zy-hero__frame img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s; }
.zy-hero__frame:hover img { transform: scale(1.03); }
.zy-hero__frame::after { content: ""; position: absolute; inset: 0; background: rgba(22, 22, 5, .28); }
.zy-hero__frame .zy-label { position: absolute; left: 50%; top: 50%; z-index: 1; transform: translate(-50%, -50%); padding: 12px 20px; border: 1px solid currentColor; border-radius: 999px; white-space: nowrap; }

.zy-hero__lead { grid-column: 9 / 13; grid-row: 3; align-self: end; margin: 0; font: 300 clamp(17px, 1.550vw, 22px)/1.300 var(--zy-serif); letter-spacing: -0.02em; color: var(--zy-sky); }
.zy-hero__cta { grid-column: 1 / -1; grid-row: 4; justify-self: center; margin-top: 56px; background: rgba(22, 22, 5, .45); backdrop-filter: blur(6px); }

@media (prefers-reduced-motion: no-preference) {
  .zy-hero__word { animation: zy-rise .9s cubic-bezier(.2, .7, .2, 1) both; }
  .zy-hero__word--2 { animation-delay: .12s; }
  .zy-hero__word--3 { animation-delay: .24s; }
  @keyframes zy-rise { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
}

@media (max-width: 900px) {
  .zy-hero { display: flex; flex-direction: column; gap: 6px; padding: 250px 22px 84px; }
  .zy-hero__bg { object-position: 78% 30%; }
  .zy-hero__word { font-size: clamp(60px, 19vw, 120px); }
  .zy-hero__word--2 { align-self: flex-end; }
  .zy-hero__frame { order: 5; width: 100%; margin: 30px 0 22px; }
  .zy-hero__lead { order: 6; font-size: 19px; }
  .zy-hero__cta { order: 7; align-self: flex-start; margin-top: 26px; }
}

/* ---------- home: statement ---------- */

.zy-statement { padding: clamp(110px, 16vw, 220px) var(--zy-gutter-wide); text-align: center; }
.zy-statement__line { margin: 0 auto; max-width: 22em; font: 300 clamp(24px, 3vw, 42px)/1.150 var(--zy-serif); letter-spacing: -0.025em; color: var(--zy-cream); }
.zy-statement__choice { display: flex; align-items: baseline; justify-content: center; gap: clamp(20px, 6vw, 110px); margin: clamp(50px, 8vw, 110px) 0; font: 300 clamp(60px, 12vw, 180px)/.9 var(--zy-serif); letter-spacing: -0.04em; text-transform: lowercase; color: var(--zy-sky); flex-wrap: wrap; }
.zy-statement__choice em { font: italic 300 clamp(20px, 2.400vw, 34px)/1 var(--zy-serif); letter-spacing: 0; color: rgba(245, 244, 237, .6); }

/* ---------- home: features ---------- */

.zy-features { display: grid; gap: clamp(90px, 13vw, 190px); padding: 0 var(--zy-gutter) clamp(110px, 14vw, 200px); }
.zy-feature { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .82fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); align-items: center; }
.zy-feature h2 { margin: 0; font: 300 clamp(40px, 5.600vw, 88px)/.95 var(--zy-serif); letter-spacing: -0.035em; text-transform: lowercase; color: var(--zy-sky); }
.zy-feature img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--zy-r-picture); display: block; }
.zy-feature p { margin: 0; max-width: 20em; font: 300 clamp(18px, 1.700vw, 24px)/1.300 var(--zy-serif); letter-spacing: -0.02em; color: rgba(245, 244, 237, .82); }
.zy-feature--flip h2 { order: 3; text-align: right; }
.zy-feature--flip p { order: 1; justify-self: end; }
.zy-feature--flip img { order: 2; }
@media (max-width: 900px) {
  .zy-feature { grid-template-columns: 1fr; gap: 26px; }
  .zy-feature--flip h2 { order: 0; text-align: left; }
  .zy-feature--flip p { order: 3; justify-self: start; }
  .zy-feature img { aspect-ratio: 4 / 3; object-position: 50% 25%; }
}

/* ---------- home: the paper section ---------- */

.zy-paper { margin: 0 var(--zy-edge); padding: 1px 0 clamp(60px, 8vw, 110px); border-radius: var(--zy-r-frame); background: var(--zy-paper); color: var(--ink); }
.zy-block { max-width: 1240px; margin: 0 auto; padding: clamp(80px, 10vw, 150px) 4vw 0; text-align: left; }
.zy-block > .zy-label { margin-bottom: 22px; color: var(--zy-olive); }
.zy-display { margin: 0 0 clamp(36px, 5vw, 70px); max-width: 16em; font: 300 clamp(36px, 5.200vw, 76px)/.98 var(--zy-serif); letter-spacing: -0.035em; text-transform: lowercase; color: var(--ink); text-align: left; border: 0; padding: 0; }

.zy-cats { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.zy-cat { display: grid; grid-template-columns: minmax(0, 1.200fr) minmax(0, 1fr) auto; gap: 28px; align-items: center; padding: 30px 14px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; transition: background-color .2s, padding .25s; }
.zy-cat:hover { padding-left: 30px; background: var(--mist); color: var(--ink); }
.zy-cat__name { font: 300 clamp(28px, 3.600vw, 50px)/1 var(--zy-serif); letter-spacing: -0.03em; text-transform: lowercase; }
.zy-cat__text { color: var(--muted); font-size: 16px; }
.zy-cat__text p { margin: 0; }
.zy-cat__go { font: 500 11px/1 var(--zy-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--zy-olive); white-space: nowrap; }
@media (max-width: 760px) { .zy-cat { grid-template-columns: 1fr; gap: 10px; padding: 24px 6px; } .zy-cat:hover { padding-left: 14px; } }

.zy-steps { counter-reset: zy-step; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 34px; margin: 0; padding: 0; list-style: none; }
.zy-steps li { counter-increment: zy-step; padding-top: 22px; border-top: 1px solid var(--zy-olive); }
.zy-steps li::before { content: counter(zy-step); display: block; margin-bottom: 26px; font: 300 64px/.9 var(--zy-serif); letter-spacing: -0.04em; color: var(--zy-olive); }
.zy-steps h3 { margin: 0 0 10px; font: 400 23px/1.150 var(--zy-serif); letter-spacing: -0.02em; }
.zy-steps p { margin: 0; color: var(--muted); font-size: 16px; }
@media (max-width: 900px) { .zy-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .zy-steps { grid-template-columns: 1fr; } }

.zy-plate { margin: clamp(80px, 10vw, 150px) var(--zy-gutter) 0; }
.zy-plate img { display: block; width: 100%; height: min(78vh, 760px); object-fit: cover; object-position: 50% 22%; border-radius: var(--zy-r-picture); }

.zy-audience { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 48px; margin: 0 0 46px; padding: 0; list-style: none; }
.zy-audience h3 { margin: 0 0 8px; font: 400 24px/1.150 var(--zy-serif); letter-spacing: -0.02em; }
.zy-audience p { margin: 0; color: var(--muted); font-size: 16px; }
@media (max-width: 900px) { .zy-audience { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .zy-audience { grid-template-columns: 1fr; gap: 26px; } }


/* ---------- home: closing ---------- */

.zy-closing { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(40px, 6vw, 100px); padding: clamp(100px, 13vw, 190px) var(--zy-gutter-wide); text-align: left; }
.zy-closing .zy-label { margin-bottom: 22px; color: rgba(245, 244, 237, .6); }
.zy-closing h2 { margin: 0 0 22px; font: 300 clamp(32px, 4.200vw, 60px)/1 var(--zy-serif); letter-spacing: -0.035em; text-transform: lowercase; color: var(--zy-sky); }
.zy-closing p:not(.zy-label) { margin: 0 0 34px; max-width: 26em; font: 300 19px/1.400 var(--zy-serif); color: rgba(245, 244, 237, .8); }
@media (max-width: 800px) { .zy-closing { grid-template-columns: 1fr; } }


/* ---------- dock ---------- */

.zy-dock { position: fixed; left: 50%; bottom: 18px; z-index: 60; display: flex; transform: translateX(-50%); padding: 0 6px; border: 1px solid var(--zy-rule); border-radius: 999px; background: rgba(22, 22, 5, .82); backdrop-filter: blur(10px); white-space: nowrap; }
.zy-dock a { padding: 15px 18px; color: var(--zy-cream); font: 500 10.500px/1 var(--zy-sans); letter-spacing: .14em; text-transform: uppercase; text-decoration: none; }
.zy-dock a + a { position: relative; }
.zy-dock a + a::before { content: ""; position: absolute; left: 0; top: 30%; height: 40%; border-left: 1px solid var(--zy-rule); }
.zy-dock a:hover { color: var(--zy-sky); }
@media print { .zy-dock { display: none; } }

/* ---------- scroll-linked motion (only when js/home.js has started; see that file) ---------- */

.zy-motion .zy-hero { --zy-p: 0; }
.zy-motion .zy-hero::before { opacity: calc(1 + var(--zy-p) * .6); background: linear-gradient(rgba(22, 22, 5, calc(.62 + var(--zy-p) * .38)), rgba(40, 38, 10, calc(.5 + var(--zy-p) * .5)) 45%, rgba(22, 22, 5, calc(.78 + var(--zy-p) * .22))); }
.zy-motion .zy-hero__word--1 { translate: calc(var(--zy-p) * -9vw) calc(var(--zy-p) * -60px); }
.zy-motion .zy-hero__word--2 { translate: calc(var(--zy-p) * 9vw) calc(var(--zy-p) * -20px); }
.zy-motion .zy-hero__word--3 { translate: calc(var(--zy-p) * -5vw) calc(var(--zy-p) * 40px); }
.zy-motion .zy-hero__frame { scale: calc(1 + var(--zy-p) * .45); z-index: 2; }
.zy-motion .zy-hero__lead, .zy-motion .zy-hero__cta { opacity: calc(1 - var(--zy-p) * 2.200); }

.zy-word { transition: opacity .25s linear; }

.zy-motion .zy-statement { --zy-p: 0; height: 320vh; padding-top: 0; padding-bottom: 0; }
.zy-motion .zy-statement__pin { position: sticky; top: 0; height: 100vh; height: 100svh; display: grid; place-items: center; overflow: hidden; }
.zy-motion .zy-statement__pin > * { grid-area: 1 / 1; margin: 0 auto; transition: opacity .5s, transform .7s cubic-bezier(.2, .7, .2, 1); }
.zy-motion .zy-statement__choice { opacity: 0; }
.zy-motion .zy-statement__choice span:first-child { translate: calc((1 - min(1, max(0, (var(--zy-p) - .3) * 5))) * -18vw) 0; }
.zy-motion .zy-statement__choice span:last-child { translate: calc((1 - min(1, max(0, (var(--zy-p) - .3) * 5))) * 18vw) 0; }
.zy-motion .zy-statement__line--after { opacity: 0; transform: translateY(40px); }
.zy-motion .zy-statement.is-choice .zy-statement__line--before { opacity: 0; transform: translateY(-40px); }
.zy-motion .zy-statement.is-choice .zy-statement__choice { opacity: 1; }
.zy-motion .zy-statement.is-after .zy-statement__choice { opacity: 0; transform: scale(.9); }
.zy-motion .zy-statement.is-after .zy-statement__line--after { opacity: 1; transform: none; }

.zy-motion [data-zy-reveal] { opacity: 0; transform: translateY(46px); transition: opacity .9s, transform 1.100s cubic-bezier(.2, .7, .2, 1); }
.zy-motion [data-zy-reveal].is-in { opacity: 1; transform: none; }
.zy-motion .zy-feature[data-zy-reveal] { opacity: 1; transform: none; }
.zy-motion .zy-feature[data-zy-reveal] h2 { opacity: 0; transform: translateY(60px); transition: opacity .9s, transform 1.100s cubic-bezier(.2, .7, .2, 1); }
.zy-motion .zy-feature[data-zy-reveal] img { clip-path: inset(22% 16% 22% 16% round var(--zy-r-picture)); transform: scale(1.120); transition: clip-path 1.300s cubic-bezier(.2, .7, .2, 1), transform 1.600s cubic-bezier(.2, .7, .2, 1); }
.zy-motion .zy-feature.is-in h2 { opacity: 1; transform: none; }
.zy-motion .zy-feature.is-in img { clip-path: inset(0 round var(--zy-r-picture)); transform: none; }
.zy-motion .zy-plate { --zy-d: 0; overflow: hidden; border-radius: var(--zy-r-picture); }
.zy-motion .zy-plate img { scale: 1.160; translate: 0 calc(var(--zy-d) * -8%); border-radius: 0; }

/* ---------- fit: the hero always ends inside the first screen ---------- */

@media (min-width: 901px) {
  .zy-hero { height: calc(100vh - 2 * var(--zy-edge)); height: calc(100svh - 2 * var(--zy-edge)); min-height: 600px; padding: 138px var(--zy-gutter) 84px; grid-template-rows: auto minmax(0, 1fr) auto; }
  .zy-hero__word { font-size: min(11.500vw, 20vh); }
  .zy-hero__frame { justify-self: center; height: 100%; max-height: 100%; width: auto; max-width: 100%; margin: 14px 0; }
}