/* Rima · Threads and Treats: full home page. Cream base, berry + olive, peach / plum / butter blocks. Hero = "Unstitched". */
:root {
  --cream: #FBF3E6; --paper: #FFF9F1;
  --berry: #A33A52; --berry-d: #852A40;
  --olive: #5F6B3B; --olive-l: #8E9A6A;
  --peach: #E8AC90; --peach-l: #F6D7C6;
  --plum: #5A3550; --butter: #F2DD9E; --rose: #C97C7C;
  --ink: #3E2230; --text: #5E4249; --line: rgba(163,58,82,.45);
  --serif: "Fraunces", "Noto Serif Sinhala", Georgia, serif;
  --sans: "Jost", "Noto Sans Sinhala", system-ui, sans-serif;
  --script: "Great Vibes", cursive;
  --r: 18px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--cream); color: var(--text); font: 400 16px/1.6 var(--sans); overflow-x: hidden; -webkit-tap-highlight-color: transparent;
  background-image: repeating-linear-gradient(0deg, rgba(94,66,73,.022) 0 1px, transparent 1px 3px), repeating-linear-gradient(90deg, rgba(94,66,73,.018) 0 1px, transparent 1px 3px); }
:lang(si) body { font-family: "Noto Sans Sinhala", "Jost", system-ui, sans-serif; }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
button { font: inherit; color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skip { position: absolute; left: 12px; top: -60px; background: var(--berry); color: #fff; padding: 10px 14px; border-radius: 10px; z-index: 50; }
.skip:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--berry); outline-offset: 3px; }

h2 { font: 600 clamp(34px, 9vw, 54px)/1.02 var(--serif); color: var(--ink); margin: 0; letter-spacing: -.01em; }
:lang(si) h2 { font-size: clamp(26px, 7vw, 40px); line-height: 1.3; letter-spacing: 0; }
.script { font: 400 clamp(30px, 8vw, 42px)/.9 var(--script); color: var(--olive); margin: 0 0 -4px; }
:lang(si) .script { font: 500 18px/1.4 "Noto Serif Sinhala", serif; margin-bottom: 4px; }
.center { text-align: center; }
.lead { margin: 10px auto 0; color: var(--text); font-size: 15px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 24px; border-radius: 999px; text-decoration: none; font: 500 16px/1.2 var(--sans); transition: transform .16s ease, background-color .2s ease, box-shadow .2s ease; user-select: none; }
:lang(si) .btn { font-family: "Noto Sans Sinhala", sans-serif; font-size: 15px; }
.btn:active { transform: scale(.97); }
.btn.tug { animation: tug .5s cubic-bezier(.3,.7,.3,1); }
.btn .wa { width: 21px; height: 21px; fill: currentColor; flex: none; }
.btn--berry { background: var(--berry); color: #FFF9F1; box-shadow: 0 12px 24px -14px rgba(133,42,64,.9); }
.btn--line { color: var(--berry); box-shadow: inset 0 0 0 1.5px var(--berry); background: rgba(255,249,241,.6); }
.btn--cream { background: var(--paper); color: var(--berry-d); }
.btn--big { min-height: 58px; width: 100%; font-size: 17px; }
@media (hover: hover) {
  .btn:hover { transform: translateY(-2px); }
  .btn--berry:hover { background: var(--berry-d); box-shadow: 0 18px 28px -14px rgba(133,42,64,.95); }
  .btn--line:hover { background: var(--paper); } .btn--cream:hover { background: #fff; box-shadow: 0 14px 24px -14px rgba(40,10,20,.6); }
}

/* top */
.bar { background: var(--berry); color: #FBE7E4; font-size: 12.5px; letter-spacing: .06em; text-align: center; padding: 7px 12px; display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }
.bar__dot { opacity: .7; }
.top { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 14px; max-width: 1200px; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-width: 0; }
.brand img { width: 72px; height: 72px; flex: none; border-radius: 50%; box-shadow: 0 0 0 1.5px rgba(163,58,82,.35), 0 6px 14px -8px rgba(62,34,48,.5); }
.brand__txt { display: flex; flex-direction: column; line-height: 1; min-width: 0; }
.brand__name { font: 400 42px/.8 var(--script); color: var(--berry); }
.brand__sub { font-size: 10.5px; letter-spacing: .17em; text-transform: uppercase; color: var(--olive); margin-top: 6px; font-weight: 500; white-space: nowrap; }
.top__end { display: flex; align-items: center; gap: 6px; flex: none; }
.lang { font: 500 14px/1 "Noto Sans Sinhala", "Jost", sans-serif; color: var(--berry); background: var(--paper); border: 1.5px dashed rgba(163,58,82,.5); border-radius: 999px; padding: 10px 13px; min-height: 42px; cursor: pointer; }
.snd { width: 40px; height: 40px; border-radius: 50%; border: 1.5px dashed rgba(163,58,82,.5); background: var(--paper); color: var(--berry); display: grid; place-items: center; cursor: pointer; padding: 0; }
.snd svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.snd .snd__spk { fill: currentColor; }
.snd .snd__off, .snd.is-off .snd__on { display: none; }
.snd.is-off .snd__off { display: inline; }
.snd.is-off { color: var(--text); opacity: .8; }
@media (max-width: 370px) { .top { padding: 10px 10px; } .brand { gap: 8px; } .brand img { width: 64px; height: 64px; } .brand__sub { letter-spacing: .1em; font-size: 10px; } .lang { padding: 10px 10px; } }

/* hero: "Unstitched" */
.uh { --wy: 50; max-width: 1280px; margin: 0 auto; }
.uh__stage { position: relative; overflow: hidden; height: clamp(360px, calc(100svh - 378px), 640px); background: #EFE4D2; border-radius: 0 0 26px 26px; touch-action: pan-y; user-select: none; -webkit-user-select: none; isolation: isolate; }
.uh__stage { perspective: 1500px; }
.uh__slides { position: absolute; inset: 0; }
.uh__set { position: absolute; inset: 0; opacity: 0; transform: scale(1.07); }
.uh__set.is-on { opacity: 1; }
.uh.is-open .uh__set.is-on { transform: scale(1); transition: transform 7s cubic-bezier(.2,.6,.3,1); }
.uh.is-still .uh__set { transform: none; transition: opacity .5s ease; }
.uh__ph { position: absolute; inset: 0; overflow: hidden; opacity: 0; transition: opacity .7s ease; }
.uh__ph.is-cur { opacity: 1; }
.uh__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.uh__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(22px) saturate(1.05) brightness(.9); transform: scale(1.15); }
.uh__ph::after { content: ""; position: absolute; inset: 0; pointer-events: none; box-shadow: inset 0 0 60px rgba(40,20,28,.12); }
/* the two halves of cloth peel back in 3D, curling away from the seam, with shade on the turned cloth */
.uh__flap { position: absolute; inset: -1px; display: none; z-index: 2; pointer-events: none; will-change: transform; transform-style: preserve-3d;
  transition: transform .85s cubic-bezier(.7,0,.2,1); }
.js .uh__flap { display: block; }
.uh.is-still .uh__flap { display: none; }
.uh__flap--l { transform-origin: 0 30%; }
.uh__flap--r { transform-origin: 100% 30%; }
.uh.is-open .uh__flap { filter: drop-shadow(0 0 12px rgba(62,34,48,.36)); }
.uh.is-open .uh__flap--l { transform: translateX(-50%) rotateY(38deg) rotate(-4deg); transition: transform 1.05s cubic-bezier(.3,1.25,.45,1); }
.uh.is-open .uh__flap--r { transform: translateX(50%) rotateY(-38deg) rotate(4deg); transition: transform 1.05s cubic-bezier(.3,1.25,.45,1); }
.uh__cloth { position: absolute; inset: 0; background: #F6ECDC url("img/linen.webp") 0 0 / 420px; }
.uh__cloth::after { content: ""; position: absolute; inset: 0; background: radial-gradient(120% 90% at 50% 40%, transparent 55%, rgba(120,90,60,.12)); }
.uh__cloth::before { content: ""; position: absolute; inset: 0; z-index: 1; opacity: 0; transition: opacity .9s ease; pointer-events: none;
  background: linear-gradient(90deg, rgba(255,250,240,.18) 0%, transparent 35%, rgba(90,55,35,.32) 100%); }
.uh__flap--r .uh__cloth::before { background: linear-gradient(270deg, rgba(255,250,240,.18) 0%, transparent 35%, rgba(90,55,35,.32) 100%); }
.uh.is-open .uh__cloth::before { opacity: 1; }
.uh__fray { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; opacity: 0; transition: opacity .25s ease; }
.uh__fray path { fill: none; stroke: #E6D7BE; stroke-width: 1.3; stroke-linecap: round; transform-box: fill-box; transform-origin: 0 50%; }
.uh__flap--r .uh__fray path { transform-origin: 100% 50%; }
.uh.is-open .uh__fray { opacity: 1; }
.uh.is-open .uh__fray path { animation: flutter 1.3s ease-in-out var(--fd, 0s) infinite alternate; }
.uh__word { position: absolute; left: 6%; width: 88%; height: auto; top: calc(var(--wy) * 1%); transform: translateY(-50%); overflow: visible; clip-path: inset(-30% 100% -30% -6%); }
.uh.is-word .uh__word { animation: uhWord 1s cubic-bezier(.45,.05,.4,1) forwards; }
.uh.is-open .uh__word { clip-path: inset(-30% -6% -30% -6%); }
.uh__w1 { fill: #A33A52; stroke: #7A263B; stroke-width: .9; paint-order: stroke; }
.uh__w2 { fill: none; stroke: rgba(255,236,230,.5); stroke-width: .7; stroke-dasharray: 2.2 2.4; }
.uh__seam { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 3; pointer-events: none; clip-path: inset(0 0 100% 0); }
.uh__seam path { fill: none; stroke: #A33A52; stroke-width: 2.3; stroke-dasharray: 8 6; stroke-linecap: round; }
.uh.is-seam .uh__seam { animation: uhSeam .75s cubic-bezier(.45,.05,.4,1) forwards; }
.uh.is-open .uh__seam { opacity: 0; transition: opacity .12s; }
.uh__needle { position: absolute; left: 0; top: 0; z-index: 4; width: 54px; height: 7px; margin: -3.5px 0 0 -5px; transform-origin: 5px 3.5px; opacity: 0; pointer-events: none;
  background: linear-gradient(180deg, #FAFBFC, #B7BDC4 70%, #8E959D); border-radius: 2px 60% 60% 2px / 2px 50% 50% 2px; box-shadow: 0 3px 4px rgba(62,34,48,.3); }
.uh__needle::before { content: ""; position: absolute; left: 3px; top: 2px; width: 7px; height: 3px; border-radius: 50%; background: #F1E8DA; }
.uh__needle::after { content: ""; position: absolute; right: 100%; top: 3px; width: 46px; height: 1.6px; background: #A33A52; border-radius: 2px; transform-origin: 100% 50%; transform: rotate(-8deg); }
.uh__tag { position: absolute; z-index: 5; top: 0; right: 6%; width: clamp(104px, 28vw, 156px); border: 0; padding: 0; background: none; cursor: pointer; transform-origin: 50% 0;
  transform: translateY(-130%) rotate(-10deg); transition: transform .4s ease-in; }
.uh.is-open .uh__tag { transform: none; animation: uhTag 1.8s linear .35s both, uhSway 5s ease-in-out 2.2s infinite; }
.uh.is-still .uh__tag { animation: none; transition: none; }
.hang__tag { display: block; position: relative; z-index: 1; aspect-ratio: 560 / 906; background: url("img/tag-kraft.webp") center / 100% 100% no-repeat; filter: drop-shadow(0 12px 12px rgba(40,20,28,.3)); }
.uh__tagtxt { position: absolute; left: 12%; right: 12%; top: 25%; bottom: 9%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .3em; text-align: center; color: var(--ink); }
.uh__tagname { font: italic 600 clamp(12.5px, 3.4vw, 18px)/1.12 var(--serif); }
:lang(si) .uh__tagname { font: 600 clamp(11px, 3vw, 15px)/1.35 "Noto Serif Sinhala", serif; }
.uh__tagprice { font: 600 clamp(14px, 4.1vw, 22px)/1 var(--sans); color: var(--berry-d); white-space: nowrap; }
.uh__tagask { font: 600 clamp(10px, 2.7vw, 13px)/1.2 var(--sans); color: var(--plum); opacity: .85; }
:lang(si) .uh__tagask { font-family: "Noto Sans Sinhala", sans-serif; }
.uh__dots { position: absolute; z-index: 5; left: 0; right: 0; bottom: 8px; display: flex; justify-content: center; gap: 2px; }
.uh__dot { position: relative; width: 30px; height: 30px; border: 0; padding: 0; background: none; cursor: pointer; }
.uh__dot::after { content: ""; position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 4px; background: rgba(255,249,241,.75); box-shadow: 0 1px 4px rgba(0,0,0,.4); transition: width .3s ease, margin .3s ease, background-color .3s; }
.uh__dot[aria-current="true"]::after { width: 22px; margin-left: -11px; background: #fff; }
.uh:not(.is-open) .uh__dot::after { background: rgba(163,58,82,.3); box-shadow: none; }
.uh:not(.is-open) .uh__dot[aria-current="true"]::after { background: var(--berry); }
.uh__copy { text-align: center; padding: 16px 18px 4px; }
.uh__kick { margin: 0 0 6px; font-size: 11.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--olive); font-weight: 600; }
:lang(si) .uh__kick { letter-spacing: .02em; font-size: 13px; }
h1 { margin: 0; font: 600 clamp(31px, 8.6vw, 60px)/1.02 var(--serif); color: var(--ink); letter-spacing: -.015em; text-wrap: balance; }
h1 em { font: 400 1.25em/.8 var(--script); color: var(--berry); letter-spacing: 0; padding: 0 .04em; }
:lang(si) h1 { font-size: clamp(24px, 6.6vw, 44px); line-height: 1.3; letter-spacing: 0; }
:lang(si) h1 em { font: 600 1em/1.3 "Noto Serif Sinhala", serif; }
.uh__sub { margin: 6px 0 0; font: italic 500 17px/1.3 var(--serif); color: var(--berry-d); }
:lang(si) .uh__sub { font: 500 15px/1.5 "Noto Serif Sinhala", serif; }
.hours { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 8px 0 0; font-size: 13.5px; }
.hours__dot { width: 9px; height: 9px; border-radius: 50%; background: var(--rose); flex: none; }
.hours__dot.is-open { background: var(--olive-l); animation: pulse 2.4s ease-in-out infinite; }
.uh__btn { margin-top: 14px; }
.uh__studio { display: inline-block; margin-top: 12px; font-size: 14.5px; color: var(--berry); text-decoration: underline dashed rgba(163,58,82,.5); text-underline-offset: 5px; padding: 6px 4px; }

/* studio */
.studio-sec { max-width: 1100px; margin: 54px auto 0; padding: 0 16px; scroll-margin-top: 12px; }
.studio { margin-top: 20px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.stage, .panel { min-width: 0; }
.stage { position: relative; background: var(--paper); border-radius: 22px; padding: 12px 12px 10px; box-shadow: 0 1px 0 rgba(255,255,255,.8) inset, 0 18px 40px -26px rgba(62,34,48,.5); border: 1.5px dashed rgba(163,58,82,.35); }
.stage__item { position: relative; width: 100%; max-width: min(420px, 46svh); aspect-ratio: 1; margin: 0 auto; perspective: 900px; }
.item { position: absolute; inset: 0; width: 100%; height: 100%; }
.item--photo { object-fit: contain; }
.stage__item.is-swap .item, .stage__item.is-swap .zone { animation: itemIn .7s cubic-bezier(.3,1.35,.5,1) both; }
/* Rima's flowers: the item on the left, clear; her design in a hoop on the right, overlapping it a little */
.item { transform-origin: 0 50%; transition: transform .7s cubic-bezier(.3,1.2,.45,1); }
.stage__item.is-motif .item { transform: translateX(1%) scale(.58); }
.stage__item.is-motif .zone { display: none; }
.zone { position: absolute; transform-origin: 50% 50%; border-radius: 12px; transition: box-shadow .3s; }
/* Rima's design: a big hoop over the faded item, the whole design inside, caption in a pill underneath */
.badge { position: absolute; z-index: 2; left: 41%; top: 14%; width: 57%; margin: 0; display: flex; flex-direction: column; align-items: center; }
.badge__hoop { position: relative; display: block; width: 100%; aspect-ratio: 900 / 950; }
.badge.is-in .badge__hoop { animation: hoopIn .9s cubic-bezier(.3,1.2,.4,1) both; }
.badge.is-in figcaption { animation: fillIn .4s ease .45s both; }
.badge__in { position: absolute; left: 6.45%; top: 10.3%; width: 87.1%; height: 82.5%; border-radius: 50%; overflow: hidden; background: #EFE4D2; box-shadow: inset 0 4px 14px rgba(62,34,48,.25); }
.badge__in img { width: 100%; height: 100%; object-fit: cover; }
.badge__ring { position: absolute; inset: 0; width: 100%; height: 100%; filter: drop-shadow(0 10px 14px rgba(62,34,48,.3)); }
.badge figcaption { margin-top: 4px; padding: 6px 14px; border-radius: 999px; background: var(--paper); box-shadow: 0 6px 14px -8px rgba(62,34,48,.45), inset 0 0 0 1.5px rgba(163,58,82,.25); text-align: center; font: italic 500 14px/1.2 var(--serif); color: var(--berry-d); white-space: nowrap; }
:lang(si) .badge figcaption { font: 500 12.5px/1.35 "Noto Serif Sinhala", serif; }
.own { display: flex; gap: 12px; align-items: flex-start; margin: 0; padding: 14px 16px; border-radius: 14px; background: #fff; border: 1.5px dashed rgba(163,58,82,.45); font-size: 15px; line-height: 1.45; color: var(--ink); }
.own svg { width: 26px; height: 26px; flex: none; fill: #25A35A; margin-top: 1px; }
.sw__ripple { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--c); pointer-events: none; animation: ripple .65s cubic-bezier(.2,.8,.2,1) forwards; }
.design { width: 100%; height: 100%; overflow: visible; }
.design text { paint-order: stroke; }
.stitching .st { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw var(--d, .9s) cubic-bezier(.45,.05,.4,1) var(--w, 0s) forwards; }
.stitching .fl { opacity: 0; animation: fillIn .5s ease var(--wf, .6s) forwards; }
.stitching .tx { stroke-dasharray: 700; stroke-dashoffset: 700; fill-opacity: 0; animation: drawTx 1.4s cubic-bezier(.45,.05,.4,1) forwards, fillTx .6s ease 1s forwards; }
.stitching .img { clip-path: inset(0 100% 0 0); animation: wipe 1.6s cubic-bezier(.45,.05,.4,1) forwards; }
.needle { position: absolute; left: 0; top: 30%; width: 22%; height: auto; opacity: 0; pointer-events: none; overflow: visible; color: var(--berry); }
.stitching ~ .needle, .zone.stitching .needle { animation: needleRun 1.5s cubic-bezier(.45,.05,.4,1) forwards; }
.stage__note { margin: 4px 0 0; text-align: center; font-size: 12px; color: var(--text); opacity: .85; }

.panel { background: var(--paper); border-radius: 22px; padding: 16px 16px 18px; box-shadow: 0 18px 40px -28px rgba(62,34,48,.45); }
.step + .step { margin-top: 14px; }
.step__h { display: flex; align-items: center; gap: 9px; margin: 0 0 9px; font: 600 15px/1.2 var(--sans); color: var(--ink); }
.step__n { width: 24px; height: 24px; border-radius: 50%; background: var(--berry); color: #fff; display: grid; place-items: center; font-size: 13px; flex: none; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 2px 4px; margin: 0 -2px; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; min-height: 42px; padding: 0 15px; border-radius: 999px; border: 1.5px solid rgba(94,66,73,.22); background: #fff; cursor: pointer; font: 500 14.5px/1 var(--sans); color: var(--text); display: inline-flex; align-items: center; gap: 7px; transition: background-color .2s, border-color .2s, color .2s; }
:lang(si) .chip { font-family: "Noto Sans Sinhala", sans-serif; font-size: 14px; }
.chip[aria-checked="true"] { background: var(--berry); border-color: var(--berry); color: #fff; }
.chips--sm .chip { min-height: 38px; font-size: 14px; }
.chips--motif .chip { padding: 0 12px 0 6px; }
.chip svg { width: 30px; height: 30px; flex: none; }
.chips--motif .chip img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 2px #fff; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); background: #F3E8DA; border-radius: 999px; padding: 4px; gap: 2px; margin-bottom: 10px; }
.seg button { border: 0; background: transparent; border-radius: 999px; min-height: 38px; cursor: pointer; font: 500 13.5px/1.1 var(--sans); color: var(--text); padding: 0 6px; }
:lang(si) .seg button { font-family: "Noto Sans Sinhala", sans-serif; font-size: 12.5px; }
.seg button[aria-selected="true"] { background: #fff; color: var(--berry); box-shadow: 0 2px 8px -4px rgba(62,34,48,.4); }
.field input { width: 100%; min-height: 50px; border-radius: 14px; border: 1.5px dashed rgba(163,58,82,.45); background: #fff; padding: 0 16px; font: 500 18px/1 var(--sans); color: var(--ink); margin-bottom: 10px; }
.field input:focus { outline: none; border-style: solid; border-color: var(--berry); }
.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.sw { width: 36px; height: 36px; border-radius: 50%; border: 0; cursor: pointer; background: var(--c); position: relative; box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
  background-image: repeating-linear-gradient(38deg, rgba(255,255,255,.22) 0 1.5px, transparent 1.5px 4px); transition: transform .35s cubic-bezier(.3,1.6,.5,1); }
.sw:active { transform: scale(.88); }
.sw[aria-checked="true"] { transform: scale(1.08); }
.sw[aria-checked="true"]::after { content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 2px solid var(--ink); }
.chip { transition: background-color .2s, border-color .2s, color .2s, transform .3s cubic-bezier(.3,1.6,.5,1); }
.chip:active { transform: scale(.95); }
.order { margin-top: 16px; padding-top: 14px; border-top: 1.5px dashed rgba(163,58,82,.3); }
.order__price { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin: 0 0 10px; font-size: 14.5px; }
.order__price b { font: 600 22px/1 var(--serif); color: var(--berry); white-space: nowrap; }
.order__after { font-size: 12.5px; text-align: center; margin: 8px 0 0; }

/* seam (thread) dividers */
.seam { display: block; width: 100%; height: 44px; margin: 8px 0 -8px; }
.seam path { fill: none; stroke: var(--line); stroke-width: 1.6; stroke-dasharray: 6 6; vector-effect: non-scaling-stroke; }

/* perks */
.perks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; max-width: 980px; margin: 18px auto 0; padding: 0 16px; }
.perk { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 8px; text-align: center; font: 500 14px/1.25 var(--sans); color: var(--ink); }
.perk svg { width: 38px; height: 38px; fill: none; stroke: var(--olive); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

/* made by hand */
.made { max-width: 1100px; margin: 40px auto 0; padding: 0 20px; display: grid; gap: 26px; justify-items: center; text-align: center; }
.hoop { position: relative; width: min(78vw, 380px); aspect-ratio: 900 / 950; }
.hoop__canvas { position: absolute; left: 6.45%; top: 10.3%; width: 87.1%; height: 82.5%; border-radius: 50%; background: #F7F0E4; box-shadow: inset 0 6px 22px rgba(62,34,48,.22); }
.hoop__ring { position: absolute; inset: 0; width: 100%; height: 100%; filter: drop-shadow(0 10px 16px rgba(62,34,48,.25)); pointer-events: none; }
.hoop__needle { position: absolute; left: 0; top: 0; width: 46px; height: 8px; margin: -4px 0 0 -4px; background: linear-gradient(90deg, #E9ECEF, #AEB4BB); border-radius: 0 50% 50% 0 / 0 50% 50% 0; opacity: 0; transform-origin: 4px 4px; transition: opacity .3s; pointer-events: none; }
.hoop__needle.on { opacity: 1; }
.made__copy { max-width: 460px; }
.made__copy p:not(.script) { margin: 12px 0 18px; }

/* favourites: gift tags */
.favs { margin: 60px auto 0; padding: 0 16px; max-width: 1100px; }
.line-wrap { position: relative; margin-top: 18px; }
/* one berry thread across the top; every tag hangs straight down from it on its own strand */
.tags { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 24px 16px 22px; margin: 0 -16px; scrollbar-width: none;
  background: linear-gradient(180deg, transparent 0 22.8px, #A33A52 22.8px 25.1px, transparent 25.1px) 0 0 / 100% 100% no-repeat local; }
.tags::-webkit-scrollbar { display: none; }
.tag { flex: none; width: 200px; scroll-snap-align: center; border: 0; background: none; padding: 0; cursor: pointer; transform-origin: 50% 0; position: relative; }
.tag.swing { animation: swing 1.8s cubic-bezier(.3,.7,.3,1) var(--sd, 0s) both; }
.tag__in { display: block; position: relative; z-index: 1; margin-top: 27.273%; perspective: 700px; transform-style: preserve-3d; transition: transform .95s cubic-bezier(.3,1.35,.45,1); }
.tag.is-flipped .tag__in { transform: rotateY(180deg); }
/* the whole face is one flip button; "Ask Rima" sits above it and is the only way to WhatsApp */
.tag__flip { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; border: 0; padding: 0; background: none; cursor: pointer; border-radius: 12px; }
.tag__flip:focus-visible { outline: 2px solid var(--berry); outline-offset: -6px; }
.tag__face > :not(.tag__flip) { position: relative; pointer-events: none; }
.tag__face > .tag__ask { pointer-events: auto; z-index: 2; }
.tag:not(.is-flipped) .tag__back, .tag.is-flipped .tag__front { pointer-events: none; }
.tag:not(.is-flipped) .tag__back .tag__ask { pointer-events: none; }
.tag__face { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 5px; aspect-ratio: 560 / 906; padding: 31% 9% 8%; color: var(--ink); text-align: center;
  background: center / 100% 100% no-repeat; backface-visibility: hidden; -webkit-backface-visibility: hidden; filter: drop-shadow(0 12px 12px rgba(62,34,48,.22)); transition: filter .95s ease; }
.tag.is-flipped .tag__face { filter: drop-shadow(-10px 14px 14px rgba(62,34,48,.22)); }
.tag.is-blush .tag__face { background-image: url("img/tag-blush.webp"); }
.tag.is-butter .tag__face { background-image: url("img/tag-butter.webp"); }
.tag.is-sage .tag__face { background-image: url("img/tag-sage.webp"); }
.tag.is-kraft .tag__face { background-image: url("img/tag-kraft.webp"); }
.tag__back { position: absolute; inset: 0; transform: rotateY(180deg); justify-content: center; padding-top: 28%; }
.tag img { width: 80%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 8px; box-shadow: 0 0 0 3px rgba(255,249,241,.75); margin-bottom: 3px; }
.tag__name { display: block; width: 100%; font: 600 15px/1.2 var(--serif); overflow-wrap: break-word; text-wrap: balance; }
:lang(si) .tag__name { font-family: "Noto Serif Sinhala", serif; font-size: 14px; line-height: 1.35; }
.tag__price { display: flex; flex-direction: column; align-items: center; gap: 3px; font: 600 18px/1 var(--sans); color: var(--berry-d); }
.tag__price s { display: block; font-size: 13px; color: var(--text); font-weight: 400; }
/* shared: berry thread through the brass eyelet (drawn by site.js) */

.hang__sw { display: flow-root; position: relative; transform-origin: 50% 0; transform: rotate(calc(var(--sw, 0) * var(--sk, 1) * 1deg)); }
.hang__back, .hang__front { position: absolute; left: 0; top: 0; width: 100%; height: auto; overflow: visible; pointer-events: none; }
.hang__back { z-index: 0; }
.hang__front { z-index: 2; filter: drop-shadow(0 1.5px 1.2px rgba(40,20,28,.35)); }
.hang .th { fill: none; stroke: #A33A52; stroke-width: 2.3; stroke-linecap: round; }
.hang .tw { fill: none; stroke: rgba(255,230,225,.45); stroke-width: .8; stroke-dasharray: 1.6 2.2; stroke-linecap: round; }
.uh__tag .hang__tag { margin-top: 27.273%; }
.tag__txt { font-size: 13px; line-height: 1.42; }
.tag__ask { display: inline-flex; align-items: center; min-height: 44px; margin-top: 8px; padding: 0 18px; border-radius: 999px; background: var(--berry); color: #FFF9F1; font-weight: 600; font-size: 14px; text-decoration: none;
  box-shadow: 0 10px 18px -10px rgba(133,42,64,.9); transition: transform .2s ease, background-color .2s; }
.tag__ask:active { transform: scale(.95); }
@media (hover: hover) { .tag__ask:hover { background: var(--berry-d); transform: translateY(-1px); } }
:lang(si) .tag__ask { font-family: "Noto Sans Sinhala", sans-serif; font-size: 13px; }

/* how to order (plum) */
.how { background: var(--plum); color: #F4E4EC; margin-top: 54px; padding: 52px 20px 46px; }
.how h2 { color: #FFF4EE; }
.light { color: var(--peach) !important; }
.steps { position: relative; list-style: none; padding: 0; margin: 30px auto 0; max-width: 460px; display: grid; gap: 22px; }
.steps__thread { position: absolute; left: 21px; top: 12px; bottom: 12px; width: 10px; height: calc(100% - 24px); }
.steps__thread path { fill: none; stroke: var(--peach); stroke-width: 2; stroke-dasharray: 7 6; vector-effect: non-scaling-stroke; }
.steps li { position: relative; display: flex; align-items: center; gap: 16px; font-size: 16.5px; line-height: 1.4; }
.steps__n { width: 44px; height: 44px; border-radius: 50%; background: var(--peach); color: var(--plum); font: 600 19px/1 var(--serif); display: grid; place-items: center; flex: none; box-shadow: 0 0 0 5px var(--plum); }
.how__note { text-align: center; margin: 28px auto 0; max-width: 34ch; color: #E5CBD8; font-size: 14.5px; }

/* to order, send (butter) */
.send { background: var(--butter); padding: 46px 18px; }
.send__card { max-width: 520px; margin: 0 auto; background: var(--paper); border-radius: 20px; padding: 26px 22px; position: relative; box-shadow: 0 18px 30px -24px rgba(62,34,48,.6); }
.send__card::before { content: ""; position: absolute; inset: 8px; border: 1.5px dashed rgba(95,107,59,.45); border-radius: 14px; pointer-events: none; }
.send h2 { font-size: clamp(28px, 7.4vw, 40px); }
.send__list { list-style: none; padding: 0; margin: 16px 0 22px; display: grid; gap: 12px; }
.send__list li { display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; line-height: 1.4; color: var(--ink); }
.send__list svg { width: 30px; height: 30px; flex: none; padding: 5px; border-radius: 50%; background: var(--olive); fill: none; stroke: #FFF9F1; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.send .btn { width: 100%; }

/* prices */
.prices { padding: 54px 16px 10px; max-width: 760px; margin: 0 auto; }
.price-card { margin-top: 20px; background: var(--paper); border-radius: 20px; padding: 10px 20px 18px; position: relative; box-shadow: 0 18px 34px -28px rgba(62,34,48,.55); }
.price-card::before { content: ""; position: absolute; inset: 8px; border: 1.5px dashed rgba(163,58,82,.35); border-radius: 14px; pointer-events: none; }
.plist { list-style: none; padding: 0; margin: 0; }
.plist li { display: flex; align-items: baseline; gap: 10px; padding: 12px 4px; border-bottom: 1px solid rgba(94,66,73,.1); font-size: 15.5px; color: var(--ink); }
.plist li::after { content: ""; order: 1; flex: 1; border-bottom: 1.5px dotted rgba(94,66,73,.3); transform: translateY(-4px); }
.plist b { order: 2; font: 600 16px/1 var(--sans); color: var(--berry); white-space: nowrap; }
.price-card__note { margin: 14px 4px 0; font-size: 13.5px; text-align: center; }
.plist li.has-pics { cursor: pointer; border-radius: 10px; transition: background-color .2s; }
.plist li.has-pics:focus-visible { outline-offset: 0; }
.plist li.has-pics[aria-expanded="true"] { background: rgba(163,58,82,.07); }
@media (hover: hover) { .plist li.has-pics:hover { background: rgba(163,58,82,.06); } }
.plist__pic { display: inline-block; vertical-align: -3px; margin-left: 7px; }
.plist__pic svg { width: 17px; height: 17px; fill: none; stroke: var(--olive); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
/* photo box: under the row on phones */
.plist li.pbox { display: grid; grid-template-rows: 0fr; padding: 0; border: 0; transition: grid-template-rows .45s cubic-bezier(.3,1.1,.4,1); }
.plist li.pbox::after { display: none; }
.plist li.pbox.is-open { grid-template-rows: 1fr; }
.pbox__in { overflow: hidden; min-height: 0; }
.pbox__card { margin: 4px 0 12px; padding: 8px; border-radius: 16px; background: #fff; box-shadow: 0 14px 30px -18px rgba(62,34,48,.55); transform: scale(.9); opacity: 0; transform-origin: 50% 0;
  transition: transform .5s cubic-bezier(.3,1.5,.45,1), opacity .25s ease; }
.pbox.is-open .pbox__card { transform: none; opacity: 1; }
.pbox__stack { position: relative; aspect-ratio: 1 / 1; border-radius: 11px; overflow: hidden; background: #EFE4D2; }
.pb__ph { position: absolute; inset: 0; overflow: hidden; opacity: 0; transition: opacity .6s ease; }
.pb__ph.is-cur { opacity: 1; }
.pb__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.pb__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(16px) brightness(.92); transform: scale(1.15); }
.pbox__dots { display: flex; justify-content: center; gap: 5px; margin-top: 7px; }
.pbox__dots:empty { display: none; }
.pbox__dots i { width: 6px; height: 6px; border-radius: 3px; background: rgba(163,58,82,.25); transition: width .3s, background-color .3s; }
.pbox__dots i.is-cur { width: 16px; background: var(--berry); }
.pbox__cap { margin: 6px 2px 0; text-align: center; font: italic 500 14px/1.25 var(--serif); color: var(--berry-d); }
:lang(si) .pbox__cap { font: 500 13px/1.4 "Noto Serif Sinhala", serif; }
/* wide screens: the box pops out beside the list, level with the row, alternating right and left */
@media (min-width: 1100px) {
  .prices { max-width: 1100px; }
  .price-card { max-width: 600px; margin-left: auto; margin-right: auto; }
  .plist { position: relative; }
  .plist li.pbox { display: block; position: absolute; z-index: 5; width: 270px; top: 0; transform: translateY(-50%); pointer-events: none; transition: none; }
  .plist li.pbox.is-open { pointer-events: auto; }
  .pbox.is-right { left: calc(100% + 40px); }
  .pbox.is-left { right: calc(100% + 40px); }
  .pbox__in { overflow: visible; }
  .pbox__card { margin: 0; transform: scale(.6) translateX(var(--from, -30px)); transform-origin: var(--orig, 0 50%); position: relative; }
  .pbox.is-left .pbox__card { --from: 30px; --orig: 100% 50%; }
  .pbox__card::before { content: ""; position: absolute; top: 50%; width: 16px; height: 16px; background: #fff; transform: translateY(-50%) rotate(45deg); border-radius: 3px; }
  .pbox.is-right .pbox__card::before { left: -7px; }
  .pbox.is-left .pbox__card::before { right: -7px; }
}

/* gallery ring: clipped only at the sides so hoops are never cut at the top or bottom */
.gallery { padding: 56px 0 30px; overflow: hidden; overflow-x: clip; overflow-y: visible; }
.ring { position: relative; height: 330px; margin-top: 18px; touch-action: pan-y; cursor: grab; width: 100vw; margin-left: calc(50% - 50vw); overflow: hidden; overflow: clip;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent); mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent); }
.ring:active { cursor: grabbing; }
.ring__spin { position: absolute; left: 50%; top: 50%; width: 0; height: 0; }
.ring__item { position: absolute; width: 130px; height: 137px; left: -65px; top: -68px; border: 0; padding: 0; background: none; cursor: pointer; transform-origin: 50% 50%; }
.ring__item img { position: absolute; left: 6.45%; top: 10.3%; width: 87.1%; height: 82.5%; border-radius: 50%; object-fit: cover; }
.ring__item::after { content: ""; position: absolute; inset: 0; background: url("img/hoop.webp") center / 100% 100% no-repeat; pointer-events: none; }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 60; background: rgba(40,20,28,.86); display: grid; place-items: center; padding: 20px; }
.lightbox[hidden] { display: none; }
.lightbox img { max-height: 84vh; border-radius: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.lightbox__x { position: absolute; top: 14px; right: 14px; width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--paper); color: var(--ink); font-size: 28px; cursor: pointer; }

/* footer (berry) */
.foot { background: var(--berry); color: #FBE3E1; text-align: center; padding: 48px 20px max(36px, env(safe-area-inset-bottom)); margin-top: 30px; }
.foot__in { max-width: 1000px; margin: 0 auto; }
.foot__logo { width: 168px; height: 168px; border-radius: 50%; margin: 0 auto; border: 6px solid var(--paper); box-shadow: 0 0 0 8px rgba(255,249,241,.22), 0 22px 40px -18px rgba(40,10,20,.7); }
.foot__script { font: 400 34px/1.1 var(--script); color: #FFF2EC; margin: 16px 0 20px; }
:lang(si) .foot__script { font: 500 19px/1.5 "Noto Serif Sinhala", serif; }
.foot .btn { max-width: 420px; flex-wrap: wrap; row-gap: 0; }
.foot .num { font-weight: 600; letter-spacing: .02em; }
.foot__hours { margin: 26px auto 0; max-width: 340px; display: grid; gap: 8px; }
.foot__hours div { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px dashed rgba(255,249,241,.3); padding-bottom: 8px; }
.foot__hours dt, .foot__hours dd { margin: 0; }
.foot__hours dd { color: #fff; font-weight: 500; }
.foot__place { margin: 18px 0 0; }
.foot__copy { margin: 8px 0 0; font-size: 12.5px; opacity: .75; }

/* reveal on scroll */
.rv { opacity: 0; transform: translateY(18px); transition: opacity .7s ease var(--rd, 0s), transform .8s cubic-bezier(.3,1.25,.45,1) var(--rd, 0s); }
.rv--side { transform: translateX(-16px); }
.rv.in { opacity: 1; transform: none; }
/* a thread stitches itself in under each heading */
.stitch-h::after { content: ""; display: block; width: 74px; height: 3px; margin: 12px auto 0; border-radius: 2px;
  background: repeating-linear-gradient(90deg, var(--berry) 0 9px, transparent 9px 14px); clip-path: inset(0 100% 0 0); transition: clip-path 1.1s cubic-bezier(.45,.05,.4,1) .2s; }
.stitch-h.in::after { clip-path: inset(0 0 0 0); }
.how .stitch-h::after { background-image: repeating-linear-gradient(90deg, var(--peach) 0 9px, transparent 9px 14px); }
.send .stitch-h::after { margin-left: 0; }
.seam--scroll { clip-path: inset(0 var(--sp, 100%) 0 0); }
.draw-on { clip-path: inset(0 100% 0 0); transition: clip-path 1.8s cubic-bezier(.45,.05,.4,1); }
.draw-on.in { clip-path: inset(0 0 0 0); }
.steps__thread.draw-on { clip-path: inset(0 0 100% 0); }
.steps__thread.draw-on.in { clip-path: inset(0 0 0 0); transition-duration: 2.4s; }

/* desktop */
@media (min-width: 900px) {
  .top { padding: 14px 32px; }
  .brand { gap: 14px; }
  .brand img { width: 90px; height: 90px; }
  .brand__name { font-size: 52px; }
  .brand__sub { font-size: 12px; letter-spacing: .2em; }
  .top__end { gap: 10px; }
  .snd { width: 44px; height: 44px; }
  .lang { padding: 10px 16px; }
  .made .stitch-h::after { margin-left: 0; }
  .foot { text-align: left; padding-top: 60px; }
  .foot__in { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 56px; align-items: center; }
  .foot__logo { width: 250px; height: 250px; margin: 0; }
  .foot__script { margin-top: 0; }
  .foot__hours { margin-left: 0; }
  .uh { display: grid; grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr); gap: 52px; align-items: center; padding: 6px 32px 0; }
  .uh__copy { grid-column: 1; grid-row: 1; text-align: left; padding: 0 0 10px; }
  .uh__stage { grid-column: 2; grid-row: 1; height: min(calc(100svh - 150px), 740px); min-height: 540px; border-radius: 28px; }
  .uh h1 { font-size: clamp(46px, 4.7vw, 70px); }
  .uh .hours { justify-content: flex-start; }
  .uh__btn { width: auto; min-width: 320px; }
  .uh__studio { display: block; width: fit-content; }
  .uh__tag { width: 158px; right: 7%; }
  .studio-sec { padding: 0 32px; margin-top: 80px; }
  .studio { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
  .stage { position: sticky; top: 16px; }
  .perks { grid-template-columns: repeat(4, 1fr); }
  .made { grid-template-columns: 1fr 1fr; text-align: left; justify-items: start; align-items: center; margin-top: 70px; }
  .made__hoop { justify-self: center; }
  .tags { justify-content: center; overflow: visible; gap: 40px; }
  .tag { width: 240px; }
  .tag__name { font-size: 16.5px; }
  .steps { max-width: 980px; grid-template-columns: repeat(4, 1fr); gap: 20px; }
  .steps li { flex-direction: column; text-align: center; }
  .steps__thread { display: none; }
  .steps::before { content: ""; position: absolute; left: 12%; right: 12%; top: 21px; border-top: 2px dashed var(--peach); opacity: .8; }
  .ring { height: 520px; }
  .ring__item { width: 230px; height: 243px; left: -115px; top: -121px; }
  .send { padding: 60px 18px; }
}

@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(142,154,106,.18); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fillIn { to { opacity: 1; } }
@keyframes drawTx { to { stroke-dashoffset: 0; } }
@keyframes fillTx { to { fill-opacity: 1; } }
@keyframes wipe { to { clip-path: inset(0 0 0 0); } }
@keyframes itemIn { from { opacity: 0; transform: translateY(14px) rotateX(18deg) scale(.94); } }
@keyframes needleRun { 0% { opacity: 0; left: -6%; top: 40%; } 10% { opacity: 1; } 30% { top: 22%; } 50% { top: 48%; } 70% { top: 26%; } 90% { opacity: 1; } 100% { opacity: 0; left: 96%; top: 38%; } }
@keyframes seam { to { stroke-dashoffset: 0; } }
@keyframes uhWord { to { clip-path: inset(-30% -6% -30% -6%); } }
@keyframes uhSeam { to { clip-path: inset(0 0 0 0); } }
/* the tag drops on its thread, overshoots, bounces and settles (a spring) */
@keyframes uhTag {
  0% { transform: translateY(-130%) rotate(-10deg); animation-timing-function: cubic-bezier(.5,0,.9,.5); }
  30% { transform: translateY(5%) rotate(7deg); animation-timing-function: ease-out; }
  44% { transform: translateY(-3%) rotate(-6deg); animation-timing-function: ease-in-out; }
  60% { transform: translateY(1.2%) rotate(3.5deg); animation-timing-function: ease-in-out; }
  76% { transform: translateY(0) rotate(-1.6deg); animation-timing-function: ease-in-out; }
  90% { transform: rotate(.6deg); }
  100% { transform: rotate(0); } }
@keyframes flutter { from { transform: rotate(calc(var(--fa, 10deg) * -1)) scaleX(.9); } to { transform: rotate(var(--fa, 10deg)) scaleX(1.05); } }
@keyframes hoopIn { 0% { opacity: 0; transform: translateY(-28px) scale(.86) rotate(-7deg); } 45% { opacity: 1; } 62% { transform: translateY(3px) scale(1.02) rotate(3deg); } 80% { transform: rotate(-1.4deg); } 100% { transform: none; } }
@keyframes ripple { from { transform: scale(1); opacity: .9; } to { transform: scale(2.1); opacity: 0; } }
@keyframes tug { 0% { transform: none; } 30% { transform: translateY(3px) scaleY(.96); } 60% { transform: translateY(-3px); } 100% { transform: none; } }
@keyframes uhSway { 0%, 100% { transform: rotate(0); } 50% { transform: rotate(2.5deg); } }
@keyframes swing { 0% { transform: rotate(-14deg); opacity: 0; } 12% { opacity: 1; } 35% { transform: rotate(9deg); } 58% { transform: rotate(-5deg); } 78% { transform: rotate(2deg); } 100% { transform: rotate(0); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001s !important; animation-delay: 0s !important; transition-duration: .001s !important; }
  .rv { opacity: 1; transform: none; }
  .needle, .uh__needle { display: none; }
  .uh__set { transform: none !important; }
  .hang__sw { transform: none !important; }
  .seam--scroll { clip-path: none; }
  .stitch-h::after { clip-path: none; }
}
