/* T.RICKS Menu + Slider — study replica ("Cólneot")
   Palette:
     #d9d5d1 light gray/beige — page base
     #3d2817 dark brown       — primary ink, dark menu panel
     #d4a569 golden tan       — primary accent (underlines, cursor, DRAG, selection)
     #b5a89a medium taupe     — muted secondary (menu numbers)
     #6b8a96 muted blue-gray  — cool meta label (detail process tag) */

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

::selection { background: #d4a569; color: #3d2817; text-shadow: none; }

html { height: 100%; }

body {
  margin: 0;
  background-color: #d9d5d1;
  font-family: 'Fahkwang', sans-serif;
  color: #3d2817;
  font-size: 1vw;
  line-height: 1.6;
  font-weight: 700;
}

@media only screen and (min-width: 2000px) {
  body { font-size: 20px; }
}

body.overflow-hidden { overflow: hidden; }

a { color: inherit; text-decoration: none; display: inline-block; max-width: 100%; }

h1 {
  margin: 0;
  font-size: 4.11em;
  line-height: 0.96;
  font-weight: 700;
  font-style: italic;
  letter-spacing: -0.05em;
  text-transform: lowercase;
}

p { margin: 0; }

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

/* ---------- shell ---------- */

.overflow {
  position: relative;
  overflow: hidden;
  width: 100%;
}

.container {
  width: 100%;
  max-width: 2000px;
  margin-right: auto;
  margin-left: auto;
  padding: 4.06em;
}

/* ---------- nav ---------- */

.section.is--nav {
  position: absolute;
  left: 0; top: 0; right: 0;
  z-index: 900;
}

.container.is--nav {
  position: relative;
  z-index: 2;
  display: flex;
  padding-top: 1.65em;
  padding-bottom: 1.65em;
  justify-content: space-between;
  align-items: center;
  color: #3d2817;
  transition: color 500ms ease-out;
}

.nav__logo {
  font-family: 'Fahkwang', sans-serif;
  font-weight: 700;
  font-size: 1.28em;
  letter-spacing: -0.01em;
  line-height: 1;
}

.trigger {
  display: flex;
  padding: 1em 0.8em;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  border: 0.15em solid currentColor;
  border-radius: 0.7em;
  transition: border-color 500ms cubic-bezier(0.39, 0.575, 0.565, 1) 200ms;
}

.trigger__line {
  width: 3em;
  height: 0.2em;
  margin-top: 0.3em;
  margin-bottom: 0.3em;
  background-color: #3d2817;
  transition: transform 500ms cubic-bezier(0.39, 0.575, 0.565, 1), background-color 500ms cubic-bezier(0.39, 0.575, 0.565, 1);
}

/* closing: colors/lines revert with a 200ms delay (matches original) */
.container.is--nav,
.trigger__line { transition-delay: 200ms; }

/* menu-open state (toggled on nav) */
.section.is--nav.menu-open .container.is--nav,
.section.is--nav.menu-open .trigger,
.section.is--nav.menu-open .trigger__line { transition-delay: 0ms; }

.section.is--nav.menu-open .container.is--nav { color: #d9d5d1; }
.section.is--nav.menu-open .trigger__line { background-color: #d9d5d1; }
.section.is--nav.menu-open .trigger__line.is--1 { transform: translateY(0.4em) rotate(45deg); }
.section.is--nav.menu-open .trigger__line.is--2 { transform: translateY(-0.4em) rotate(-45deg); }

/* ---------- menu ---------- */

.menu {
  position: absolute;
  left: 0; top: 0; right: 0;
  z-index: 1;
  display: none;
}

.background {
  position: absolute;
  left: 0; top: 0; right: 0;
  z-index: 1;
  display: flex;
  width: 100%;
  height: 101%;
  flex-direction: column;
  align-items: stretch;
  transform: translateY(-100%);
}

.background__fill {
  width: 100%;
  height: 100%;
  flex-shrink: 0;
  background-color: #3d2817;
}

.background__lottie {
  width: 100%;
  margin-top: -1%;
  flex-shrink: 0;
}

.background__lottie svg { display: block; }

.container.is--menu {
  position: relative;
  z-index: 2;
  display: flex;
  height: 100vh;
  justify-content: flex-start;
  align-items: center;
  color: #d9d5d1;
  opacity: 0;
}

.menu__contain {
  display: flex;
  width: 100%;
  justify-content: space-between;
  align-items: stretch;
}

.menu__left {
  position: relative;
  display: flex;
  padding-left: 4.06em;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
}

.nav-link {
  display: flex;
  overflow: hidden;
  margin-top: 0.7em;
  margin-bottom: 0.7em;
  justify-content: flex-start;
  align-items: center;
}

.nav-link:hover { font-style: italic; font-weight: 700; }
.nav-link.is--1 { margin-left: 12.4em; }
.nav-link.is--3 { margin-left: 6.2em; }

.nav-link__text {
  font-size: 7.03em;
  line-height: 1.2;
  letter-spacing: -0.05em;
}

.nav-link__num {
  margin-top: 0.7em;
  margin-left: 0.3em;
  font-size: 1.25em;
  line-height: 1;
  font-style: normal;
  letter-spacing: -0.04em;
  color: #b5a89a;
}

.nav-link__contain {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  opacity: 0;
}

.nav-link__line {
  width: 0em;
  height: 0.2em;
  background-color: #d4a569;
  transition: width 500ms cubic-bezier(0.165, 0.84, 0.44, 1);
}

.nav-link:hover .nav-link__line { width: 5em; }

.nav-link__img {
  position: absolute;
  left: auto; top: 0; right: 0;
  z-index: -2;
  width: 46em;
  height: 30em;
  margin-right: -35em;
  object-fit: contain;
  filter: hue-rotate(150deg) saturate(0.55);
  visibility: hidden;
  opacity: 0;
  transform: scale(0.7);
  transition: opacity 500ms cubic-bezier(0.165, 0.84, 0.44, 1), transform 500ms cubic-bezier(0.165, 0.84, 0.44, 1), visibility 0s linear 500ms;
}

.nav-link:hover .nav-link__img {
  visibility: visible;
  opacity: 1;
  transform: scale(1);
  transition-delay: 0s;
}

.menu__right {
  display: flex;
  padding-top: 1em;
  padding-right: 10.99em;
  padding-bottom: 1.7em;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
}

.menu__icon {
  width: 3.02em;
  transform: scale(0);
}

.sublinks {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
}

.sublink {
  overflow: hidden;
  margin-top: 1.5em;
}

.sublink__contain { opacity: 0; }

.sublink__text {
  font-size: 1.77em;
  line-height: 1.2;
  letter-spacing: -0.04em;
}

.sublink__line {
  width: 100%;
  height: 0.2em;
  background-color: #d4a569;
  transform: translateX(-101%);
}

.sublink.is--hover .sublink__line {
  transform: translateX(0%);
  transition: transform 500ms cubic-bezier(0.165, 0.84, 0.44, 1);
}

.sublink.is--out .sublink__line {
  transform: translateX(101%);
  transition: transform 500ms cubic-bezier(0.165, 0.84, 0.44, 1);
}

/* ---------- hero ---------- */

.section.is--hero {
  position: relative;
  z-index: 3;
}

.container.is--hero {
  padding-top: 11.26em;
  padding-bottom: 0em;
}

.hero__wrap {
  width: 49%;
  margin-right: auto;
  margin-left: auto;
  text-align: center;
}

.hero__p {
  margin-top: 1em;
  font-family: 'Poppins', sans-serif;
  font-weight: 400;
}

/* ---------- slider ---------- */

.section.is--slider {
  position: relative;
  z-index: 2;
  margin-bottom: 5em;
}

.container.is--slider {
  padding-top: 0em;
  padding-bottom: 0em;
}

.slider__wave {
  position: absolute;
  left: 0; top: 0; right: 0;
  z-index: 2;
  margin-top: -0.6vw;
  pointer-events: none;
}

.slider__wave svg { display: block; width: 100%; height: auto; }
.slider__wave svg path { pointer-events: auto; }

.slider__wave.is--bottom {
  top: auto;
  bottom: 0;
  margin-top: 0;
  margin-bottom: -0.6vw;
  transform: rotate(-180deg);
}

.splide__track { overflow: visible !important; }

.splide__list {
  display: flex;
  justify-content: flex-start;
  align-items: stretch;
}

.splide__slide {
  width: 33.333333333333336%;
  height: 40vw;
  min-height: 41.88em;
  padding-right: 0.52em;
  padding-left: 0.52em;
  flex: 0 0 auto;
}

.splide__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms cubic-bezier(0.165, 0.84, 0.44, 1);
  cursor: pointer;
}

/* hover zoom */
.splide__slide { overflow: hidden; }
.splide__slide:hover .splide__img { transform: scale(1.06); }

/* fashion-sketch slides: show the full drawing on a white croquis card */
.splide__img.is--sketch {
  object-fit: contain;
  background-color: #ffffff;
  padding: 2em;
}

.splide *:focus { outline: none; }

.splide__arrow.splide__arrow--next,
.splide__arrow.splide__arrow--prev,
.splide__pagination { display: none; }

/* ---------- controls ---------- */

.controls {
  position: absolute;
  left: 0; right: 0;
  top: auto; bottom: 0;
  z-index: 4;
  display: flex;
  width: 13em;
  margin-right: auto;
  margin-left: auto;
  justify-content: center;
  align-items: center;
}

.control {
  position: relative;
  display: flex;
  overflow: hidden;
  width: 3.33em;
  height: 3.33em;
  margin-right: 0.5em;
  margin-left: 0.5em;
  justify-content: center;
  align-items: center;
  border: 2px solid #3d2817;
  border-radius: 0.9em;
  transition: transform 200ms ease, background-color 200ms cubic-bezier(0.165, 0.84, 0.44, 1), color 500ms cubic-bezier(0.165, 0.84, 0.44, 1) 100ms;
  color: #3d2817;
  background-color: transparent;
  -webkit-mask-image: -webkit-radial-gradient(white, black);
}

.control:hover {
  color: #d4a569;
  background-color: #3d2817;
  transition: transform 200ms ease, color 500ms cubic-bezier(0.165, 0.84, 0.44, 1), background-color 200ms cubic-bezier(0.165, 0.84, 0.44, 1) 400ms;
}

.control:active { transform: scale(0.9); }

.control__fill {
  position: absolute;
  left: auto; top: 0; right: 0; bottom: auto;
  z-index: 1;
  width: 100%;
  height: 100%;
  margin-top: -100%;
  margin-right: -100%;
  border-radius: 0.9em;
  background-color: #3d2817;
  transform: translate(0%, 0%);
  transition: transform 500ms cubic-bezier(0.165, 0.84, 0.44, 1) 100ms;
}

.control:hover .control__fill {
  transform: translate(-100%, 100%);
  transition: transform 500ms cubic-bezier(0.165, 0.84, 0.44, 1);
}

.control__arrow {
  position: relative;
  z-index: 2;
  display: block;
  width: 1.5em;
  height: 1.3em;
}

.control__arrow svg { display: block; width: 100%; height: 100%; }

.control__arrow.is--flipped { transform: rotate(-180deg); }

/* ---------- cursor ---------- */

.cursor {
  position: fixed;
  left: 0; top: 0; right: 0; bottom: 0;
  z-index: 1000;
  display: flex;
  width: 100%;
  height: 100vh;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 200ms ease;
  pointer-events: none;
}

body:hover .cursor { opacity: 1; }

.cursor.hide-cursor { display: none; }

.cursor__dot1 {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #3d2817;
  transition: opacity 350ms ease, background-color 350ms ease, height 350ms ease, width 350ms ease;
}

.cursor__dot1.is--larger {
  width: 6em;
  height: 6em;
  background-color: #d4a569;
}

.cursor__dot1.opacity-0 { opacity: 0; }

.cursor__dot2 {
  position: absolute;
  display: flex;
  overflow: hidden;
  width: 52px;
  height: 52px;
  justify-content: center;
  align-items: center;
  border: 2px solid #3d2817;
  border-radius: 50%;
  transition: border-color 350ms ease, height 350ms ease, width 350ms ease, background-color 350ms ease, color 350ms ease;
  color: transparent;
}

.cursor__dot2.is--larger {
  width: 6em;
  height: 6em;
  background-color: #3d2817;
  color: #d4a569;
}

.cursor__dot2.light-ring {
  width: 6em;
  height: 6em;
  border-color: #d4a569;
}

.cursor__text {
  font-family: 'Poppins', sans-serif;
  font-weight: 400;
  font-size: 0.9em;
  letter-spacing: 0.28em;
  text-indent: 0.28em; /* offset trailing letter-spacing so it stays optically centred */
  text-transform: uppercase;
}

/* ---------- intro / landing ---------- */

.intro {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
}

.intro.is--gone { display: none; }

.intro__bg {
  position: absolute;
  inset: 0;
  background-color: #d9d5d1;
  transition: opacity 600ms ease;
}

.intro.is--hiding .intro__bg { opacity: 0; }

.intro__logo {
  position: relative;
  z-index: 2;
  font-family: 'Fahkwang', sans-serif;
  font-weight: 700;
  font-size: 7em;
  line-height: 1;
  letter-spacing: -0.01em;
  color: #3d2817;
  cursor: pointer;
  transform-origin: 0 0;
  /* entrance from-state (fade + rise) */
  opacity: 0;
  transform: translateY(0.5em);
  transition: opacity 3200ms cubic-bezier(0.16, 1, 0.3, 1),
              transform 3600ms cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform, opacity;
}

.intro.is--in .intro__logo {
  opacity: 1;
  transform: translateY(0);
}

/* the flight to the nav position (inline transform is set from JS) */
.intro__logo.is--flying {
  transition: transform 900ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* "click to continue" hint — fades in after the wordmark settles, then pulses */
.intro__hint {
  position: absolute;
  left: 0; right: 0;
  bottom: 3.5em;
  z-index: 2;
  text-align: center;
  font-family: 'Poppins', sans-serif;
  font-weight: 400;
  font-size: 0.82em;
  letter-spacing: 0.38em;
  text-indent: 0.38em;
  text-transform: uppercase;
  color: #b5a89a;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1200ms ease 2600ms;
}

.intro.is--in .intro__hint {
  opacity: 1;
  animation: introHintPulse 2400ms ease-in-out 3800ms infinite;
}

@keyframes introHintPulse {
  0%   { opacity: 1; }
  50%  { opacity: 0.4; }
  100% { opacity: 1; }
}

/* when dismissing, drop the hint quickly so it doesn't linger during the flight */
.intro.is--hiding .intro__hint {
  opacity: 0;
  animation: none;
  transition: opacity 250ms ease;
}

@media screen and (max-width: 767px) {
  .intro__hint { font-size: 2.6vw; bottom: 4em; }
}

/* homepage starts hidden behind the intro, then zooms in when dismissed */
.overflow.intro-hidden { opacity: 0; }

@keyframes pageZoomIn {
  from { opacity: 0; transform: scale(1.04); }
  to   { opacity: 1; transform: scale(1); }
}

.overflow.intro-reveal {
  animation: pageZoomIn 720ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@media screen and (max-width: 767px) {
  .intro__logo { font-size: 12vw; }
}

/* ---------- drawing-process detail page ---------- */

/* while the detail overlay is up (and fading out), the hamburger sits
   directly behind its close button — disable it so clicks can't leak through */
body.detail-open .trigger { pointer-events: none; }

.detail {
  position: fixed;
  left: 0; top: 0; right: 0; bottom: 0;
  z-index: 950;
  background-color: transparent; /* body cream shows through as the page zooms out */
  opacity: 0;
  visibility: hidden;
  transition: opacity 250ms ease, visibility 0s linear 250ms;
}

.detail.is--open {
  opacity: 1;
  visibility: visible;
  transition: opacity 250ms ease;
}

/* the page (nav + hero + slider) zooms out and fades as the detail opens */
.overflow {
  transform-origin: 50% 42%;
  transition: transform 720ms cubic-bezier(0.16, 1, 0.3, 1), opacity 550ms ease;
}

.overflow.page-zoomed {
  transform: scale(0.92);
  opacity: 0;
  pointer-events: none;
}

/* FLIP ghost: the clicked image, flown from its slide into the detail panel */
.flip-ghost {
  position: fixed;
  z-index: 960;
  margin: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background-color: #ffffff;
  padding: 2.5em;
  pointer-events: none;
  will-change: top, left, width, height;
}

.flip-ghost img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.flip-ghost.is--morphing {
  transition: top 720ms cubic-bezier(0.16, 1, 0.3, 1),
              left 720ms cubic-bezier(0.16, 1, 0.3, 1),
              width 720ms cubic-bezier(0.16, 1, 0.3, 1),
              height 720ms cubic-bezier(0.16, 1, 0.3, 1);
}

.detail__inner {
  display: flex;
  width: 100%;
  height: 100%;
  max-width: 2000px;
  margin: 0 auto;
  padding: 4.06em;
  gap: 4em;
  align-items: center;
}

/* the real image panel; stays hidden until the flying ghost hands off to it */
.detail__media {
  flex: 0 0 52%;
  height: 100%;
  background-color: #ffffff;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2.5em;
  opacity: 0;
  transition: opacity 160ms ease;
}

.detail.is--revealed .detail__media { opacity: 1; }

.detail__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.detail__info {
  flex: 1 1 auto;
  max-width: 34em;
}

/* info items pop up in sequence, once the image is settling */
.detail__tag,
.detail__title,
.detail__text {
  opacity: 0;
  transform: translateY(1.7em);
  transition: opacity 600ms ease, transform 720ms cubic-bezier(0.16, 1, 0.3, 1);
}

.detail.is--revealed .detail__tag,
.detail.is--revealed .detail__title,
.detail.is--revealed .detail__text {
  opacity: 1;
  transform: translateY(0);
}

.detail.is--revealed .detail__tag   { transition-delay: 90ms; }
.detail.is--revealed .detail__title { transition-delay: 200ms; }
.detail.is--revealed .detail__text  { transition-delay: 320ms; }

.detail__tag {
  font-family: 'Poppins', sans-serif;
  font-weight: 400;
  font-size: 0.85em;
  letter-spacing: 0.35em;
  padding-bottom: 0.6em;
  border-bottom: 0.22em solid #d4a569;
  display: inline-block;
  color: #6b8a96;
}

.detail__title {
  margin: 0.9em 0 0.5em;
  font-size: 2.6em;
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.03em;
  text-transform: uppercase;
}

.detail__text {
  font-family: 'Poppins', sans-serif;
  font-weight: 300;
  font-size: 1.06em;
  line-height: 1.9;
}

.detail__close {
  position: absolute;
  top: 1.65em;
  right: 4.06em;
  z-index: 2;
  display: flex;
  width: 3.2em;
  height: 3.2em;
  justify-content: center;
  align-items: center;
  border: 0.15em solid #3d2817;
  border-radius: 0.7em;
  color: #3d2817;
  transition: background-color 250ms ease, color 250ms ease;
}

.detail__close svg { width: 1.1em; height: 1.1em; }

.detail__close:hover {
  background-color: #3d2817;
  color: #d4a569;
}

@media screen and (max-width: 767px) {
  .detail { overflow-y: auto; }
  .detail__inner {
    flex-direction: column;
    align-items: stretch;
    height: auto;
    min-height: 100%;
    gap: 3em;
    padding-top: 12em;
  }
  .detail__media { flex: 0 0 auto; height: 55vh; }
  .detail__close { right: 4.9em; }
}

/* ---------- responsive ---------- */

@media screen and (max-width: 991px) {
  .container {
    padding-right: 3em;
    padding-left: 3em;
  }

  .hero__p { font-size: 12px; }

  .overflow { min-height: 100vh; }

  .cursor { display: none; }

  .menu { height: 100vh; }

  .background__lottie {
    position: relative;
    z-index: 2;
    flex: 0 0 auto;
  }

  .background__fill {
    position: relative;
    z-index: 1;
  }
}

@media screen and (max-width: 767px) {
  h1 { font-size: 7em; }

  .container {
    padding-right: 4.9em;
    padding-left: 4.9em;
  }

  .container.is--hero {
    padding-top: 136px;
    padding-bottom: 3.4em;
  }

  .container.is--nav {
    padding-top: 22px;
    padding-bottom: 22px;
  }

  .section.is--slider { margin-bottom: 9.9em; }

  .hero__wrap { width: 90%; }

  .controls {
    margin-bottom: -3em;
    font-size: 2em;
  }

  .nav__logo { font-size: 10px; }
  .trigger { font-size: 8px; }

  .splide__slide {
    width: 100%;
    min-height: 89em;
    padding-right: 0.92em;
    padding-left: 0.92em;
  }

  .menu__icon { font-size: 10px; }
  .sublink { font-size: 7px; }
  .sublink__line { display: none; }
}

@media screen and (max-width: 479px) {
  h1 { font-size: 8em; }

  .hero__wrap { width: 100%; }

  .controls {
    margin-bottom: -47px;
    font-size: 10px;
  }

  .menu__left {
    padding-left: 0em;
    font-size: 2em;
  }

  .menu__contain { display: block; }

  .menu__right {
    padding-top: 5.3em;
    padding-right: 0em;
    padding-bottom: 0em;
    align-items: center;
    font-size: 5px;
    text-align: center;
  }

  .menu__icon { font-size: 2em; }

  .sublinks {
    padding-top: 1.3em;
    align-items: center;
    text-align: center;
  }

  .sublink { font-size: 2em; }
}
