/* Image Origami hero CSS: six-slide origami hero + final paper-fold exit */
:root {
  --io-paper: #f8f0e5;
  --io-paper-light: #fffaf1;
  --io-paper-mid: #eadfce;
  --io-ink: #201a17;
  --io-muted: #74665c;
  --io-wine: #7b1438;
  --io-wine-dark: #4b0b21;
  --io-gold: #b88443;
  --io-line: rgba(92, 70, 46, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--io-paper);
  color: var(--io-ink);
  font-family: "Lato", Arial, Helvetica, sans-serif;
  overflow-x: hidden;
}

.io-hero-journey {
  position: relative;
  height: 760dvh;
  background: #fff8ee;
  perspective: 1800px;
  perspective-origin: 50% 0;
}

.io-hero {
  position: sticky;
  top: 0;
  z-index: 30;
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
  background: var(--io-paper);
  isolation: isolate;
  transform-origin: top center;
  transform-style: preserve-3d;
  will-change: transform, clip-path, opacity;
  --io-fold-shadow: 0;
}

.io-hero.io-is-exiting {
  box-shadow: 0 28px 80px rgba(44, 30, 20, .24);
  background: #f8f0e5;
}

.io-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 82;
  pointer-events: none;
  opacity: var(--io-fold-shadow);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .14), rgba(32, 22, 15, .20)),
    linear-gradient(90deg, rgba(255, 255, 255, .16), rgba(0, 0, 0, .08));
}

.io-paper-field {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 54vw;
  z-index: 3;
  pointer-events: none;
  background:
    radial-gradient(circle at 12% 18%, rgba(255, 255, 255, .62) 0 1px, transparent 1px),
    #fbf4e9;
  background-size: 24px 24px, auto;
  -webkit-mask-image: linear-gradient(
    90deg,
    #000 0%,
    #000 63%,
    rgba(0, 0, 0, .72) 76%,
    rgba(0, 0, 0, .28) 90%,
    transparent 100%
  );
  mask-image: linear-gradient(
    90deg,
    #000 0%,
    #000 63%,
    rgba(0, 0, 0, .72) 76%,
    rgba(0, 0, 0, .28) 90%,
    transparent 100%
  );
}

.io-image-stack {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 32vw;
  z-index: 1;
  overflow: hidden;
  background: #e4d5c4;
}

.io-image-stack::before,
.io-image-stack::after {
  content: none;
  display: none;
}

.io-image {
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: 0;
  transform: translateX(46px) scale(1.075);
  clip-path: inset(0 0 0 100%);
  transition:
    opacity 820ms cubic-bezier(.22, 1, .36, 1),
    transform 1600ms cubic-bezier(.22, 1, .36, 1),
    clip-path 920ms cubic-bezier(.22, 1, .36, 1);
  background-size: cover;
  background-position: 100% center;
  background-repeat: no-repeat;
  will-change: opacity, transform, clip-path;
}

.io-image.active {
  z-index: 3;
  opacity: 1;
  transform: translateX(0) scale(1.018);
  clip-path: inset(0 0 0 0);
}

.io-image.leaving {
  z-index: 2;
  opacity: 0;
  transform: translateX(-32px) scale(1.035);
  clip-path: inset(0 100% 0 0);
}

.io-hero.reverse .io-image {
  transform: translateX(-46px) scale(1.075);
  clip-path: inset(0 100% 0 0);
}

.io-hero.reverse .io-image.active {
  transform: translateX(0) scale(1.018);
  clip-path: inset(0 0 0 0);
}

.io-hero.reverse .io-image.leaving {
  transform: translateX(32px) scale(1.035);
  clip-path: inset(0 0 0 100%);
}

.io-image::before,
.io-image::after {
  content: none;
  display: none;
}

.io-image-1 {
  background-image: url("../images/image1.jpg");
}

.io-image-2 {
  background-image: url("../images/image2.jpg");
}

.io-image-3 {
  background-image: url("../images/image3.jpg");
}

.io-image-4 {
  background-image: url("../images/image4.jpg");
}

.io-image-5 {
  background-image: url("../images/image5.jpg");
}

.io-image-6 {
  background-image: url("../images/image6.jpg");
}

.io-fold-stage {
  position: absolute;
  top: -8dvh;
  bottom: 92px;
  left: clamp(300px, 30vw, 440px);
  width: min(540px, 38vw);
  z-index: 10;
  pointer-events: none;
  overflow: visible;
  transform-origin: 50% 50%;
  transition: transform 760ms cubic-bezier(.22, 1, .36, 1);
}

.io-fold-stage::before,
.io-fold-stage::after {
  content: none;
  display: none;
}

.io-hero.transitioning .io-fold-stage {
  transform: translateX(-7px);
}

.io-fold-svg {
  position: absolute;
  inset: -18% -72% -18% -62%;
  width: 214%;
  height: 136%;
  overflow: visible;
  shape-rendering: geometricPrecision;
  transform-origin: 50% 50%;
  transform: rotate(90deg) scale(1.05);
}

.io-morph-wall,
.io-base-piece {
  display: none;
  opacity: 0;
  visibility: hidden;
  filter: none;
}

.io-piece {
  opacity: .96;
  filter:
    drop-shadow(0 28px 36px rgba(43, 29, 18, .18))
    drop-shadow(0 5px 12px rgba(43, 29, 18, .08));
}

.io-piece-a,
.io-piece-d,
.io-piece-g {
  opacity: .98;
}

.io-piece-b,
.io-piece-e,
.io-piece-i {
  opacity: .9;
}

.io-piece-j {
  opacity: .82;
}

.io-morph-creases,
.io-crease,
.io-crease.soft {
  display: none;
  opacity: 0;
  visibility: hidden;
  stroke: transparent;
  stroke-width: 0;
}

.io-logo {
  position: absolute;
  z-index: 32;
  top: 36px;
  left: 4.2vw;
  display: flex;
  align-items: center;
  gap: 13px;
  white-space: nowrap;
}

.io-logo-mark {
  width: 34px;
  height: 42px;
  position: relative;
  flex: 0 0 auto;
}

.io-logo-mark::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 2px;
  width: 20px;
  height: 32px;
  border: 1.3px solid var(--io-gold);
  transform: rotate(45deg) skew(4deg, 8deg);
  background: rgba(255, 250, 241, .36);
}

.io-logo-mark::after {
  content: "";
  position: absolute;
  left: 14px;
  top: 13px;
  width: 10px;
  height: 10px;
  border: 1px solid var(--io-gold);
  transform: rotate(45deg);
  opacity: .76;
}

.io-logo-text {
  display: flex;
  align-items: baseline;
  gap: 12px;
  white-space: nowrap;
}

.io-logo-title {
  font-family: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  font-size: 24px;
  font-weight: 500;
  letter-spacing: .035em;
  line-height: 1;
}

.io-logo-sub {
  font-size: 8px;
  letter-spacing: .38em;
  color: var(--io-wine);
  text-transform: uppercase;
  line-height: 1;
}

.io-copy {
  position: absolute;
  z-index: 32;
  left: 8.2vw;
  top: 28dvh;
  width: min(650px, 49vw);
  transition:
    opacity 420ms cubic-bezier(.22, 1, .36, 1),
    transform 480ms cubic-bezier(.22, 1, .36, 1),
    filter 480ms cubic-bezier(.22, 1, .36, 1);
}

.io-copy.switching {
  opacity: 0;
  transform: translateY(16px);
  filter: blur(3px);
}

.io-title {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  font-weight: 500;
  font-size: clamp(44px, 5.25vw, 78px);
  line-height: .91;
  letter-spacing: -.045em;
}

.io-title span {
  color: var(--io-wine);
}

.io-mini-line {
  width: 58px;
  height: 2px;
  background: var(--io-gold);
  margin: 28px 0 24px;
}

.io-note {
  max-width: 405px;
  margin: 0;
  text-transform: uppercase;
  font-size: 11px;
  line-height: 1.85;
  letter-spacing: .24em;
  color: #4f423a;
  font-weight: 700;
}

.io-scroll-cue {
  position: absolute;
  z-index: 32;
  left: 8.2vw;
  bottom: 17.5dvh;
  color: var(--io-muted);
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: .24em;
  transition: opacity .35s ease;
}

.io-scroll-cue::after {
  content: "";
  display: block;
  width: 1px;
  height: 32px;
  margin: 12px 0 0 10px;
  background: var(--io-gold);
}

.io-tabs {
  position: absolute;
  z-index: 46;
  left: 0;
  right: 0;
  bottom: 0;
  height: clamp(74px, 10.5dvh, 92px);
  padding: 0 10px 10px;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  align-items: end;
  gap: 0;
  overflow: visible;
  transform-origin: bottom center;
  transform-style: preserve-3d;
  will-change: transform, opacity, height, padding;
  backface-visibility: hidden;
  background: linear-gradient(
    180deg,
    rgba(248, 240, 229, 0) 0%,
    rgba(248, 240, 229, .72) 42%,
    rgba(248, 240, 229, .96) 100%
  );
}

.io-hero.io-is-exiting .io-tabs {
  pointer-events: none;
}

.io-tab {
  appearance: none;
  border-radius: 0;
  font-family: "Lato", Arial, Helvetica, sans-serif;
  text-align: left;
  position: relative;
  height: clamp(58px, 8.2dvh, 72px);
  padding: 0 clamp(14px, 1.35vw, 22px);
  border: 1px solid rgba(90, 70, 48, .13);
  border-right: 0;
  background: linear-gradient(145deg, #f5f2ec 0%, #e7e1d8 100%);
  color: var(--io-ink);
  cursor: pointer;
  overflow: hidden;
  clip-path: polygon(0 0, calc(100% - 24px) 0, 100% 24px, 100% 100%, 0 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .78),
    0 -8px 22px rgba(40, 28, 18, .055);
  transform: translateY(0);
  display: flex;
  align-items: center;
  transition:
    transform .34s ease,
    background .34s ease,
    box-shadow .34s ease,
    border-color .34s ease;
}

.io-tab:last-child {
  border-right: 1px solid rgba(90, 70, 48, .13);
}

.io-tab::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .74), rgba(255, 255, 255, 0) 42%),
    linear-gradient(45deg, rgba(126, 93, 58, .06), rgba(255, 255, 255, 0) 68%);
  pointer-events: none;
}

.io-tab::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 28px;
  height: 28px;
  z-index: 2;
  background: linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(177, 154, 126, .24));
  clip-path: polygon(0 0, 100% 0, 100% 100%);
  border-left: 1px solid rgba(96, 76, 50, .12);
  border-bottom: 1px solid rgba(96, 76, 50, .10);
}

.io-tab-label {
  display: none;
}

.io-tab-name {
  position: relative;
  z-index: 3;
  display: block;
  font-family: "Lato", Arial, Helvetica, sans-serif;
  font-size: clamp(11.5px, .82vw, 13.5px);
  line-height: 1.22;
  font-weight: 400;
  letter-spacing: .01em;
  color: #302923;
}

.io-tab:not(.active):hover {
  background: linear-gradient(145deg, #fff8ec 0%, #ead9c4 100%);
  border-color: rgba(184, 132, 67, .45);
  transform: translateY(-4px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .9),
    0 -14px 30px rgba(120, 82, 42, .14);
}

.io-tab:not(.active):hover .io-tab-name {
  color: var(--io-wine);
}

.io-tab:not(.active):hover::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .85), rgba(255, 255, 255, 0) 42%),
    linear-gradient(45deg, rgba(184, 132, 67, .18), rgba(255, 255, 255, 0) 68%);
}

.io-tab:not(.active):hover::after {
  background: linear-gradient(135deg, #fff7e8 0%, #d9b77e 100%);
  border-left-color: rgba(184, 132, 67, .35);
  border-bottom-color: rgba(184, 132, 67, .28);
}

.io-tab.active {
  background: linear-gradient(145deg, #8a173f 0%, #5a0b28 100%);
  border-color: rgba(92, 10, 42, .55);
  color: #fff8ee;
  transform: translateY(-5px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .18),
    0 -18px 38px rgba(85, 13, 38, .24);
}

.io-tab.active::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, 0) 46%),
    linear-gradient(45deg, rgba(255, 220, 170, .12), rgba(255, 255, 255, 0) 66%);
}

.io-tab.active::after {
  background: linear-gradient(135deg, rgba(255, 236, 200, .88), rgba(120, 22, 58, .18));
  border-left-color: rgba(255, 236, 200, .22);
  border-bottom-color: rgba(255, 236, 200, .18);
}

.io-tab.active .io-tab-name {
  color: #fff8ee;
}

.io-tab.active:hover {
  background: linear-gradient(145deg, #9b1b4a 0%, #661031 100%);
  transform: translateY(-6px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .22),
    0 -20px 42px rgba(85, 13, 38, .30);
}

.io-tab.active:hover .io-tab-name {
  color: #fff3dc;
}

.io-sticky-menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 80;
  height: 68px;
  padding: 0 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(31, 26, 23, .94);
  color: #fff8ed;
  transform: translateY(-100%);
  opacity: 0;
  transition: transform 520ms ease, opacity 520ms ease;
  backdrop-filter: blur(16px);
}

.io-sticky-menu.revealed {
  transform: translateY(0);
  opacity: 1;
}

.io-menu-logo {
  font-family: "Lato", Arial, Helvetica, sans-serif;
  font-size: 18px;
  letter-spacing: .08em;
  white-space: nowrap;
}

.io-sticky-menu nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.io-sticky-menu a {
  color: #fff4e8;
  text-decoration: none;
  text-transform: uppercase;
  font-family: "Lato", Arial, Helvetica, sans-serif;
  font-size: 10px;
  letter-spacing: .17em;
  white-space: nowrap;
}

.io-sticky-menu .io-book-link {
  background: var(--io-gold);
  color: #fff;
  padding: 13px 18px;
  border-radius: 999px;
}

@media (max-width: 1180px) {
  .io-image-stack {
    left: 34vw;
  }

  .io-fold-stage {
    left: 29vw;
    width: 40vw;
  }

  .io-copy {
    width: min(590px, 51vw);
  }

  .io-title {
    font-size: clamp(42px, 5vw, 68px);
  }
}

@media (min-width: 981px) and (max-height: 740px) {
  .io-copy {
    top: 25dvh;
  }

  .io-title {
    font-size: clamp(40px, 4.85vw, 64px);
  }

  .io-mini-line {
    margin: 22px 0 20px;
  }

  .io-note {
    font-size: 10.5px;
    line-height: 1.75;
  }

  .io-scroll-cue {
    display: none;
  }
}

@media (max-width: 980px) {
  .io-hero-journey {
    height: auto;
    background: var(--io-paper);
    perspective: none;
  }

  .io-hero {
    position: relative;
    height: auto;
    min-height: 100dvh;
  }

  .io-paper-field {
    position: absolute;
    inset: 0;
    width: auto;
    background: #fbf4e9;
    -webkit-mask-image: none;
    mask-image: none;
  }

  .io-logo {
    top: 28px;
    left: 24px;
  }

  .io-logo-title {
    font-size: 20px;
  }

  .io-logo-sub {
    font-size: 7px;
    letter-spacing: .28em;
  }

  .io-copy {
    left: 26px;
    top: 148px;
    width: calc(100% - 52px);
  }

  .io-title {
    font-size: 42px;
    max-width: 470px;
  }

  .io-scroll-cue {
    display: none;
  }

  .io-image-stack {
    position: relative;
    left: auto;
    width: 100%;
    height: 420px;
    margin-top: 410px;
    z-index: 1;
  }

  .io-fold-stage {
    top: 235px;
    left: -8vw;
    bottom: auto;
    width: 92vw;
    height: 520px;
    opacity: .82;
  }

  .io-fold-svg {
    inset: -14% -64% -18% -64%;
    width: 220%;
    height: 132%;
    transform: rotate(90deg) scale(.92);
  }

  .io-tabs {
    position: relative;
    height: auto;
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 16px 20px 28px;
    background: #f8f0e5;
  }

  .io-tab {
    height: auto;
    min-height: 96px;
    border-right: 1px solid rgba(90, 70, 48, .13);
    transform: none;
  }

  .io-tab.active,
  .io-tab:hover,
  .io-tab.active:hover {
    transform: none;
  }

  .io-tab-name {
    font-size: 13.5px;
  }

  .io-sticky-menu {
    position: sticky;
    transform: translateY(0);
    opacity: 1;
    height: auto;
    min-height: 68px;
    padding: 16px 20px;
    overflow-x: auto;
    gap: 20px;
  }

  .io-sticky-menu nav {
    gap: 18px;
  }
}

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

  .io-image,
  .io-copy,
  .io-tab,
  .io-tabs,
  .io-fold-stage,
  .io-sticky-menu {
    transition: none;
  }
}


/* Slide 5 only: larger classic origami crane, shifted left to preserve the portrait */
@media (min-width: 981px) {
  .io-hero[data-io-slide="4"] .io-fold-stage {
    left: clamp(220px, 23vw, 340px);
    width: min(620px, 42vw);
  }

  .io-hero[data-io-slide="4"] .io-fold-svg {
    transform: rotate(90deg) scale(1.08);
  }
}


/* Slide 6 only: compact origami butterfly flying diagonally upward */
@media (min-width: 981px) {
  .io-hero[data-io-slide="5"] .io-fold-stage {
    left: clamp(190px, 20vw, 300px);
    top: -2dvh;
    width: min(520px, 35vw);
  }

  .io-hero[data-io-slide="5"] .io-fold-svg {
    transform: rotate(48deg) scale(.92);
    transform-origin: 50% 52%;
  }
}
/* =========================================================
   WORDPRESS PRIMARY MENU + DROPDOWNS
   ========================================================= */

.io-main-navigation {
  height: 100%;
  display: flex;
  align-items: center;
}

.io-main-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 30px;
}

.io-main-menu > li {
  position: relative;
  margin: 0;
  padding: 0;
}

.io-main-menu > li > a {
  display: flex;
  align-items: center;
  height: 68px;
  color: #fff4e8;
  text-decoration: none;
  text-transform: uppercase;
  font-family: "Lato", Arial, Helvetica, sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .17em;
  white-space: nowrap;
}

.io-main-menu > li > a:hover,
.io-main-menu > li.current-menu-item > a,
.io-main-menu > li.current-menu-ancestor > a {
  color: #d9a85f;
}

.io-main-menu .menu-item-has-children > a::after {
  content: "";
  width: 6px;
  height: 6px;
  margin-left: 8px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition: transform .25s ease;
}

.io-main-menu .menu-item-has-children:hover > a::after {
  transform: rotate(225deg) translate(-1px, -1px);
}

.io-main-menu .sub-menu {
  position: absolute;
  top: calc(100% - 1px);
  left: -20px;
  z-index: 100;
  width: 280px;
  margin: 0;
  padding: 12px 0;
  list-style: none;
  background: rgba(31, 26, 23, .98);
  border-top: 2px solid #b88443;
  box-shadow: 0 20px 45px rgba(0, 0, 0, .24);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition:
    opacity .25s ease,
    visibility .25s ease,
    transform .25s ease;
}

.io-main-menu li:hover > .sub-menu,
.io-main-menu li:focus-within > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.io-main-menu .sub-menu li {
  position: relative;
  margin: 0;
  padding: 0;
}

.io-main-menu .sub-menu a {
  display: block;
  padding: 12px 20px;
  color: #f8efe6;
  text-decoration: none;
  font-family: "Lato", Arial, Helvetica, sans-serif;
  font-size: 12px;
  line-height: 1.4;
  letter-spacing: .03em;
  text-transform: none;
  border-left: 2px solid transparent;
  transition:
    color .22s ease,
    background .22s ease,
    border-color .22s ease,
    padding-left .22s ease;
}

.io-main-menu .sub-menu a:hover,
.io-main-menu .sub-menu .current-menu-item > a {
  color: #fff;
  background: rgba(184, 132, 67, .16);
  border-left-color: #b88443;
  padding-left: 25px;
}

/* Book Consultation top-level item */
.io-main-menu > li:last-child > a {
  height: auto;
  padding: 13px 18px;
  border-radius: 999px;
  background: #b88443;
  color: #fff;
}

.io-main-menu > li:last-child > a:hover {
  background: #9d7038;
  color: #fff;
}
