/* Hushwell: a one-serum skin care shop. Deep bottle green, peach, cream, one amber drop. Calm and editorial on purpose. */
:root { --green: #173A2C; --deep: #0F2A1F; --peach: #F3C9A6; --cream: #FBF4EC; --amber: #C8862E; --sage: #DCE3D5;
  --serif: "Instrument Serif", Georgia, serif; --sans: Geist, system-ui, sans-serif; --gut: clamp(20px, 5vw, 72px); --out: cubic-bezier(.16, 1, .3, 1); }
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--cream); color: var(--green); font: 400 17px/1.6 var(--sans); overflow-x: clip; }
h1, h2, h3, p, dl, dd, ul, ol, figure { margin: 0; padding: 0; }
h1, h2 { font-family: var(--serif); font-weight: 400; letter-spacing: -.015em; line-height: .96; text-wrap: balance; }
h2 { font-size: clamp(44px, 5.6vw, 88px); }
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2.5px solid var(--green); outline-offset: 3px; border-radius: 4px; }
.eyebrow { margin-bottom: 18px; font-size: 13px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; color: var(--amber); }

.preview { padding: 7px var(--gut); background: var(--green); color: var(--cream); font-size: 13px; text-align: center; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 54px; padding: 0 30px; border: 0; border-radius: 99px; background: var(--green); color: var(--cream);
  font-size: 16px; font-weight: 500; text-decoration: none; transition: transform .35s var(--out), background .25s; }
.btn:hover { transform: translateY(-2px); background: var(--deep); }
.btn:disabled { opacity: .4; cursor: not-allowed; transform: none; }

/* ---- Nav ---- */
.nav { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: clamp(16px, 3vw, 40px); height: 68px; padding: 0 var(--gut); background: rgb(251 244 236 / .88);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: 0 1px 0 rgb(23 58 44 / .1); }
.nav__logo { font: 400 32px/1 var(--serif); letter-spacing: -.02em; text-decoration: none; }
.nav nav { display: flex; gap: clamp(16px, 2.4vw, 34px); margin-left: auto; font-size: 15px; }
.nav nav a { text-decoration: none; } .nav nav a:hover { text-decoration: underline; text-underline-offset: 5px; }
.nav__cart { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 8px 0 16px; border: 1px solid rgb(23 58 44 / .3); border-radius: 99px; background: transparent; font-size: 15px; }
.nav__cart i { display: grid; place-items: center; min-width: 26px; height: 26px; border-radius: 99px; background: var(--peach); font-style: normal; font-size: 13px; font-weight: 600; }

/* ---- Hero: a tall photograph bleeding off three edges, and a headline that crosses onto it ---- */
.hero { position: relative; display: grid; align-items: center; min-height: calc(100svh - 96px); overflow: clip; background: var(--cream); }
.hero__pic { position: absolute; top: 0; right: 0; bottom: 0; width: 56%; overflow: clip; background: #EBD3B3; }
.hero__pic img { width: 100%; height: 112%; object-fit: cover; object-position: 50% 82%; will-change: transform; }
.hero__copy { position: relative; z-index: 2; padding: clamp(36px, 7vh, 80px) var(--gut); max-width: 100%; }
.hero h1 { font-size: clamp(64px, 9.6vw, 168px); line-height: .86; letter-spacing: -.025em; }
.hero h1 span { display: block; }
.hero h1 span + span { font-style: italic; padding-left: .5em; }
.hero__sub { max-width: 24ch; margin-top: 30px; font-size: clamp(19px, 1.6vw, 24px); }
.hero__acts { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin-top: 34px; }
.hero__price { font-size: 15px; opacity: .8; }
.hero__cue { position: absolute; z-index: 2; right: var(--gut); bottom: 26px; display: flex; align-items: center; gap: 12px; color: var(--cream); font-size: 12.5px; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; text-shadow: 0 1px 12px rgb(23 58 44 / .45); }
.hero__cue::after { content: ""; width: 1px; height: 44px; background: currentColor; transform-origin: top; animation: cue 2.4s ease-in-out infinite; }
@keyframes cue { 0% { scale: 1 0; } 50% { scale: 1 1; } 100% { scale: 1 1; opacity: 0; } }
.js .hero h1 span { animation: rise 1.2s var(--out) both; } .js .hero h1 span + span { animation-delay: .12s; }
.js .hero .eyebrow, .js .hero__sub, .js .hero__acts { animation: rise 1.1s var(--out) .32s both; }
.js .hero__pic { animation: reveal 1.5s var(--out) both; } .js .hero__pic img { animation: settle 2.2s var(--out) both; }
@keyframes rise { from { opacity: 0; translate: 0 .35em; } }
@keyframes reveal { from { clip-path: inset(0 0 0 100%); } to { clip-path: inset(0); } }
@keyframes settle { from { scale: 1.12; } }

/* ---- The routine: eleven products become one. The photographs fall away, the last one fills the screen ---- */
.routine { height: 320vh; background: var(--peach); }
.routine__pin { position: sticky; top: 68px; height: calc(100svh - 68px); display: grid; grid-template-rows: auto 1fr auto; gap: clamp(12px, 2.4vh, 24px); padding: clamp(18px, 3.4vh, 34px) var(--gut) clamp(18px, 3.4vh, 34px); overflow: clip; }
.routine h2 { position: relative; z-index: 4; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 .3em; font-size: clamp(46px, 6.4vw, 104px); }
.routine__who { font-style: italic; }
.routine__n b { font-weight: 400; font-variant-numeric: tabular-nums; display: inline-block; min-width: 1.1ch; text-align: right; }
.mosaic { position: relative; display: grid; gap: clamp(8px, 1vw, 14px); min-height: 0;
  grid-template-columns: 1fr 1fr 1.35fr 1fr 1fr; grid-template-rows: repeat(3, minmax(0, 1fr));
  grid-template-areas: "a b s d e" "c c s f f" "g h s i j"; }
.tile { width: 100%; height: 100%; min-height: 0; object-fit: cover; border-radius: 6px; will-change: transform, opacity; }
.cell { grid-area: s; }
.finale { position: absolute; z-index: 3; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: 50% 50%; will-change: clip-path; clip-path: inset(var(--ct, 0) var(--cr, 0) var(--cb, 0) var(--cl, 0) round var(--cx, 6px)); }
.routine__foot { position: relative; z-index: 4; min-height: 2.6em; display: flex; align-items: end; }
.routine__end { font: italic 400 clamp(26px, 2.8vw, 44px)/1.15 var(--serif); opacity: 0; translate: 0 12px; transition: opacity .5s, translate .6s var(--out); }
.routine__end.is-on { opacity: 1; translate: 0 0; }

/* ---- What is in it ---- */
.inside { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(32px, 6vw, 110px); align-items: stretch; padding-right: var(--gut); }
.inside__pic { position: relative; min-height: 70vh; overflow: clip; }
.inside__pic img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 60% 40%; }
.inside__in { align-self: center; padding: clamp(80px, 12vh, 140px) 0; }
.inside dl { margin-top: 38px; }
.inside dl div { display: grid; grid-template-columns: 1.2fr 1fr; gap: 16px; padding: 18px 0; border-top: 1px solid rgb(23 58 44 / .16); }
.inside dl div:last-child { border-bottom: 1px solid rgb(23 58 44 / .16); }
.inside dt { display: flex; align-items: baseline; gap: 18px; font: 400 clamp(30px, 3vw, 44px)/1.1 var(--serif); }
.inside dt i { font: 500 13px/1 var(--sans); letter-spacing: .1em; color: var(--amber); }
.inside dd { align-self: center; font-size: 18px; }
.inside__note { margin-top: 26px; font-size: 18px; opacity: .8; }

/* ---- How to use it ---- */
.use { position: relative; display: grid; align-items: center; min-height: 92vh; padding: clamp(80px, 12vh, 140px) var(--gut); overflow: clip; background: #E9DDCC; }
.use__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 60% 50%; }
.use__in { position: relative; width: min(500px, 100%); padding: clamp(30px, 4vw, 56px); background: rgb(251 244 236 / .94); }
.use ol { margin-top: 26px; list-style: none; counter-reset: step; }
.use li { counter-increment: step; display: grid; grid-template-columns: 52px 1fr; padding: 16px 0; border-top: 1px solid rgb(23 58 44 / .14); font-size: 18px; }
.use li::before { content: counter(step); font: italic 400 38px/1 var(--serif); color: var(--amber); }
.use li b { font-weight: 600; }

/* ---- Left out ---- */
.out { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); background: var(--green); color: var(--cream); }
.out__in { align-self: center; padding: clamp(80px, 12vh, 140px) var(--gut); }
.out ul { display: flex; flex-wrap: wrap; gap: 4px 34px; margin: 36px 0 0; list-style: none; }
.out li { font: 400 clamp(36px, 4.4vw, 70px)/1.15 var(--serif); text-decoration: line-through; text-decoration-thickness: 2px; text-decoration-color: var(--peach); color: rgb(251 244 236 / .62); }
.out p { margin-top: 36px; font: italic 400 clamp(24px, 2.2vw, 32px)/1.3 var(--serif); color: var(--peach); }
.out__pic { position: relative; min-height: 60vh; overflow: clip; }
.out__pic img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 60%; }

/* ---- The shop ---- */
.shop { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(32px, 6vw, 100px); align-items: center; padding: clamp(80px, 12vh, 140px) var(--gut); }
.gallery { display: grid; grid-template-columns: 1fr 92px; gap: 14px; align-items: start; }
.gallery__main { aspect-ratio: 5 / 4; overflow: clip; background: #D9CDBE; }
.gallery__main img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; transition: opacity .3s; }
.gallery__thumbs { display: grid; gap: 12px; order: 2; }
.gallery__thumbs button { padding: 0; border: 2px solid transparent; background: none; overflow: clip; aspect-ratio: 1; opacity: .6; transition: opacity .25s, border-color .25s; }
.gallery__thumbs button.is-on, .gallery__thumbs button:hover { opacity: 1; }
.gallery__thumbs button.is-on { border-color: var(--green); }
.gallery__thumbs img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; }
.shop__size { margin-top: 10px; font-size: 18px; opacity: .8; }
.shop__price { margin-top: 22px; font: 400 72px/1 var(--serif); }
.shop__buy { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 26px; }
.qty { display: inline-flex; align-items: center; height: 54px; border: 1px solid rgb(23 58 44 / .3); border-radius: 99px; }
.qty button { width: 48px; height: 100%; border: 0; background: none; font-size: 22px; }
.qty output { min-width: 2ch; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
.shop__note { margin-top: 18px; font-size: 15.5px; opacity: .8; }
.shop__facts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; list-style: none; }
.shop__facts li { padding: 7px 14px; border: 1px solid rgb(23 58 44 / .22); border-radius: 99px; font-size: 14px; }

/* ---- Questions ---- */
.ask { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(24px, 6vw, 110px); padding: 0 var(--gut) clamp(80px, 12vh, 140px); }
.ask details { border-top: 1px solid rgb(23 58 44 / .16); }
.ask details:last-child { border-bottom: 1px solid rgb(23 58 44 / .16); }
.ask summary { display: flex; justify-content: space-between; gap: 20px; padding: 22px 0; cursor: pointer; font: 400 clamp(24px, 2.2vw, 30px)/1.2 var(--serif); list-style: none; }
.ask summary::-webkit-details-marker { display: none; }
.ask summary::after { content: "+"; font-family: var(--sans); font-size: 24px; transition: rotate .3s var(--out); }
.ask details[open] summary::after { rotate: 45deg; }
.ask details p { padding: 0 0 22px; max-width: 60ch; font-size: 17.5px; }

.foot { display: grid; gap: 10px; padding: 56px var(--gut) 64px; background: var(--deep); color: var(--cream); }
.foot__preview { opacity: .7; font-size: 14.5px; }

/* ---- Cart and the preview note ---- */
dialog { color: var(--green); }
dialog::backdrop { background: rgb(15 42 31 / .4); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.cart { position: fixed; inset: 0 0 0 auto; width: min(440px, 100vw); height: 100dvh; max-height: none; margin: 0; padding: 0; border: 0; background: var(--cream); display: none; flex-direction: column; }
.cart[open] { display: flex; animation: slide .5s var(--out); } @keyframes slide { from { translate: 100% 0; } }
.cart header, .cart footer { padding: 24px 28px; }
.cart header { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid rgb(23 58 44 / .12); }
.cart h2 { font-size: 40px; }
.x { padding: 8px 14px; border: 1px solid rgb(23 58 44 / .35); border-radius: 99px; background: transparent; }
.cart__body { flex: 1; padding: 20px 28px; font-size: 18px; }
.cart__line { display: grid; grid-template-columns: 72px 1fr auto; gap: 16px; align-items: center; }
.cart__line img { width: 72px; height: 88px; object-fit: cover; object-position: 50% 45%; border-radius: 4px; }
.cart__line b { font: 400 26px/1 var(--serif); }
.cart footer { display: grid; gap: 8px; border-top: 1px solid rgb(23 58 44 / .12); }
.cart footer p:first-child { display: flex; justify-content: space-between; font-size: 18px; } .cart footer b { font: 400 32px/1 var(--serif); }
.cart__ship { font-size: 14.5px; opacity: .75; }
.cart .btn { margin-top: 8px; }
.note { max-width: min(520px, calc(100vw - 32px)); padding: 36px; border: 0; border-radius: 20px; background: var(--cream); }
.note[open] { animation: pop .45s var(--out); } @keyframes pop { from { scale: .94; opacity: 0; } }
.note h2 { font-size: 46px; } .note p { margin-top: 14px; font-size: 18px; }
.note__acts { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin-top: 26px; }

/* ---- Phones ---- */
@media (max-width: 860px) {
  .nav nav { display: none; }
  .nav__cart { margin-left: auto; }
  .hero { display: block; min-height: 0; }
  .hero__pic { position: relative; width: 100%; height: 62svh; }
  .hero__copy { margin-top: -64px; padding-top: 0; }
  .hero h1 { font-size: clamp(60px, 18.5vw, 92px); }
  .hero h1 span { text-shadow: 0 0 28px rgb(251 244 236 / .7); }
  .hero__cue, .hero .eyebrow { display: none; }
  .routine { height: 300vh; }
  .routine__pin { padding-inline: 14px; }
  .routine h2 { font-size: clamp(38px, 11vw, 54px); }
  .mosaic { grid-template-columns: 1fr 1.25fr 1fr; grid-template-rows: repeat(4, minmax(0, 1fr)); grid-template-areas: "a b d" "c s e" "g s f" "h i j"; }
  .inside { grid-template-columns: 1fr; padding-right: 0; gap: 0; }
  .inside__pic { min-height: 0; aspect-ratio: 4 / 4.2; }
  .inside__in { padding: 56px var(--gut) 72px; }
  .inside dl div { grid-template-columns: 1fr; gap: 2px; }
  .use { min-height: 0; padding: 220px var(--gut) 40px; align-items: end; }
  .use__img { object-position: 74% 50%; height: 260px; bottom: auto; }
  .use__in { width: 100%; padding: 28px 22px; }
  .out { grid-template-columns: 1fr; }
  .out__in { padding-bottom: 56px; }
  .out__pic { min-height: 0; aspect-ratio: 4 / 3.4; }
  .shop { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .gallery__thumbs { order: 0; grid-template-columns: repeat(3, 72px); margin-top: 0; }
  .gallery__main { aspect-ratio: 1; }
  .ask { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .hero__pic img { height: 100%; }
  .routine { height: auto; }
  .routine__pin { position: static; height: auto; min-height: 80vh; }
  .mosaic { height: 64vh; }
  .finale { display: none; }
  .routine__end { opacity: 1; translate: 0 0; }
}
