/* Asas Asmara, catalog version */
:root {
  --wine: #A31A1E;
  --wine-deep: #8C1519;
  --line: #D42A1F;
  --cream: #FBF3E8;
  --desk: #EEDDC7;
  --ink: #5A1014;
  --sage: #B9C4A7;
  --print: #FFFCF6;
  --display: "Yellowtail", "Brush Script MT", cursive;
  --script: "Pinyon Script", "Snell Roundhand", cursive;
  --sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --c: 74px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--desk);
  color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--line); outline-offset: 3px; border-radius: 6px; }
.cover :focus-visible, .backcover :focus-visible, .page--wine :focus-visible, .float-wa:focus-visible { outline-color: var(--cream); }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; background: var(--cream); color: var(--wine); padding: 10px 16px; border-radius: 999px; font-weight: 600; }
.skip:focus { top: 12px; }
.nojs { padding: 40px 20px; text-align: center; }

/* ---------- frame: thin double red line with Art Nouveau corners ---------- */
.frame { --fc: var(--line); position: relative; padding: calc(var(--c) * .5) clamp(18px, 5vw, 44px) calc(var(--c) * .55); }
.frame::before, .frame::after { content: ""; position: absolute; pointer-events: none; border: solid var(--fc); }
.frame::before { inset: calc(var(--c) * .03 - .5px); border-width: 1px; border-radius: calc(var(--c) * .2 + .5px); }
.frame::after { inset: calc(var(--c) * .06 - .3px); border-width: .6px; border-radius: calc(var(--c) * .18 + .3px); }
.cn { position: absolute; width: var(--c); height: var(--c); background: var(--fc); pointer-events: none; z-index: 1;
  -webkit-mask: url(ornaments/corner.svg) center / contain no-repeat; mask: url(ornaments/corner.svg) center / contain no-repeat; }
.cn-tl { top: 0; left: 0; }
.cn-tr { top: 0; right: 0; transform: scaleX(-1); }
.cn-bl { bottom: 0; left: 0; transform: scaleY(-1); }
.cn-br { bottom: 0; right: 0; transform: scale(-1, -1); }
.scroll { display: block; width: min(190px, 52%); aspect-ratio: 240 / 52; margin: calc(var(--c) * -.38) auto 14px; background: var(--fc);
  -webkit-mask: url(ornaments/top-scroll.svg) center / contain no-repeat; mask: url(ornaments/top-scroll.svg) center / contain no-repeat; }
.frame { display: flex; flex-direction: column; }
.frame-in { position: relative; z-index: 2; flex: 1; display: flex; flex-direction: column; }
.frame-in > .flower { margin-top: auto; }
.frame-in > :nth-last-child(2) { margin-bottom: 28px; }
.flower { display: block; width: 40px; aspect-ratio: 120 / 260; margin: 28px auto 0; background: var(--line);
  -webkit-mask: url(ornaments/flower.svg) center / contain no-repeat; mask: url(ornaments/flower.svg) center / contain no-repeat; }

/* ---------- pills, buttons ---------- */
.pill { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 46px; padding: 10px 22px;
  border-radius: 999px; font: 800 17px/1.15 var(--sans); text-decoration: none; letter-spacing: .01em; border: 0; }
.pill--wine { background: var(--wine); color: #fff; }
.pill--cream { background: var(--cream); color: var(--wine); }
.pill--line { background: transparent; color: var(--line); box-shadow: inset 0 0 0 1.5px var(--line); }
.pill--ghost { color: var(--cream); box-shadow: inset 0 0 0 1.5px var(--cream); font-weight: 600; }
a.pill { transition: transform .2s ease, background-color .2s ease; }
a.pill:hover { transform: translateY(-1px); }
a.pill--wine:hover { background: var(--wine-deep); }
.price { gap: 0; align-self: flex-start; }
.pill small { font-weight: 600; font-size: .7em; margin-left: 1px; }
.wa-ico { flex: none; width: 20px; height: 20px; border-radius: 50%; background: #25D366 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='1.8' stroke-linejoin='round'%3E%3Cpath d='M12 4.6a7.4 7.4 0 0 0-6.4 11.1L4.7 19.3l3.7-.9A7.4 7.4 0 1 0 12 4.6Z'/%3E%3Cpath d='M9.4 8.9c.2-.4.5-.4.7-.4.2 0 .4.6.6 1.1.1.3-.4.7-.4.9.4.9 1.4 1.9 2.4 2.3.2 0 .5-.5.8-.5.4.1 1 .4 1.1.6 0 .4-.3 1.2-1.1 1.3-1.5.2-4.6-2.4-4.6-4.3 0-.5.2-.8.5-1Z' fill='white' stroke-width='.4'/%3E%3C/svg%3E") center / 18px no-repeat; }
.ig-ico { flex: none; width: 18px; height: 18px; border: 1.8px solid currentColor; border-radius: 6px; position: relative; }
.ig-ico::before { content: ""; position: absolute; inset: 3.2px; border: 1.8px solid currentColor; border-radius: 50%; }
.ig-ico::after { content: ""; position: absolute; width: 2.6px; height: 2.6px; right: 1.6px; top: 1.6px; background: currentColor; border-radius: 50%; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 20px; }
.actions--center { justify-content: center; }
.link-ig { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-weight: 600; color: var(--wine); text-underline-offset: 4px; }

/* ---------- cover + back cover ---------- */
.cover, .backcover { background: var(--wine); color: var(--cream); padding: 12px; }
.cover { min-height: 100vh; min-height: 100svh; display: flex; }
.frame--cover { --fc: var(--cream); --c: clamp(84px, 20vw, 170px); flex: 1; display: flex; flex-direction: column; align-items: center; }
.cover-in, .back-in { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 8px 0; }
.cover-lock { width: clamp(96px, 26vw, 136px); filter: drop-shadow(0 6px 14px rgba(40, 0, 0, .35)); }
.cover-title { font: 400 clamp(54px, 16.5vw, 168px)/1 var(--display); margin: 14px 0 6px; transform: rotate(-4deg); text-shadow: 0 2px 0 rgba(60, 0, 0, .25); white-space: nowrap; }
.cover-kind { font: 800 clamp(13px, 3.6vw, 17px)/1.3 var(--sans); letter-spacing: .22em; text-transform: uppercase; margin-top: 14px; }
.cover-tag { font: 400 clamp(28px, 8vw, 42px)/1.2 var(--script); margin-top: 6px; }
.cover-cta { margin-top: 30px; min-width: 200px; font-size: 18px; }
.cover-foot { font-size: 14px; letter-spacing: .08em; opacity: .85; padding-bottom: 6px; }

.backcover { padding-bottom: 96px; }
.back-in { padding: 14px 0 6px; }
.back-lock { width: 92px; }
.back-title { font: 400 clamp(46px, 13vw, 92px)/1.2 var(--display); margin: 12px 0 22px; padding-bottom: .12em; transform: rotate(-3deg); }
.back-text { max-width: 30em; }
.back-area { max-width: 30em; margin-top: 26px; font-size: 15px; opacity: .92; }
.back-small { margin-top: 10px; font-size: 14px; }
.back-small a { display: inline-block; padding: 12px 4px; text-underline-offset: 4px; }
.backcover .actions { margin-top: 24px; }
.backcover .pill { min-width: 200px; }

/* ---------- book, spreads, pages ---------- */
.book { padding: 22px 8px 30px; }
.spread { max-width: 1280px; margin: 0 auto; }
.page { position: relative; display: flex; flex-direction: column; background: var(--cream); padding: 14px 12px 44px; margin-bottom: 16px;
  border-radius: 3px; box-shadow: 0 1px 1px rgba(90, 16, 20, .08), 0 14px 30px -18px rgba(90, 16, 20, .45); scroll-margin-top: 12px; }
.page > .frame { flex: 1; margin-top: 12px; }
.page--wine { background: var(--wine); color: var(--cream); padding-top: 12px; }
.page--wine > .frame { margin-top: 0; }
.pnum { position: absolute; bottom: 14px; right: 20px; font: 600 13px/1 var(--sans); letter-spacing: .12em; color: var(--line); }
.page--wine .pnum { color: var(--cream); }

/* header bar: "Package A ........ Draping Backdrop" */
.hbar { border: 1.5px solid var(--line); border-radius: 18px; padding: 8px 16px 7px; color: var(--line); }
.hbar h2 { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-weight: 400; }
.hbar-l { font: 800 clamp(19px, 5.4vw, 28px)/1.2 var(--sans); letter-spacing: -.01em; }
.hbar-r { font: 400 clamp(22px, 6.2vw, 32px)/1.1 var(--display); margin-left: auto; text-align: right; }
.hbar-r small { font: 800 10px/1 var(--sans); letter-spacing: .06em; text-transform: uppercase; margin-right: 4px; vertical-align: middle; }
.hbar-r--pinyon { font-family: var(--script); font-size: clamp(26px, 7vw, 36px); }

.lede { font-size: 17px; max-width: 34em; }
.mini { font: 800 14px/1.3 var(--sans); color: var(--line); margin: 22px 0 8px; letter-spacing: .02em; }
.dots { list-style: none; padding: 0; display: grid; gap: 4px; }
.dots li { position: relative; padding-left: 22px; }
.dots li::before { content: ""; position: absolute; left: 2px; top: .58em; width: 9px; height: 9px; border-radius: 50%; background: var(--line); box-shadow: 0 0 0 3px var(--cream), 0 0 0 4px var(--line); transform: scale(.8); }
.price { margin-top: 24px; font-size: 19px; }
.note { font-size: 14px; margin-top: 8px; opacity: .85; }

/* contents */
.toc { list-style: none; padding: 0; margin-top: 18px; }
.toc a { display: flex; align-items: baseline; gap: 8px; padding: 11px 0; text-decoration: none; color: var(--ink); }
.toc-name { font: 800 19px/1.25 var(--sans); }
.toc-name small { display: block; font: 400 15px/1.3 var(--sans); color: var(--line); margin-top: 2px; }
.leader { flex: 1; min-width: 20px; border-bottom: 2px dotted var(--line); transform: translateY(-5px); opacity: .7; }
.toc-num { font: 400 30px/1 var(--display); color: var(--line); min-width: 36px; text-align: right; }
.toc-kid a { padding: 10px 0 10px 18px; }
.toc-kid .toc-name { font-weight: 600; font-size: 16px; }
.toc-kid .toc-num { font-size: 24px; }
.toc a:hover .toc-name { color: var(--line); }
.toc li + li:not(.toc-kid) { border-top: 1px solid rgba(212, 42, 31, .25); }

/* who are we */
.snap--hero { width: min(330px, 86%); margin: 4px auto 26px; }
.about { max-width: 34em; }
.about-en { font: 400 26px/1.3 var(--script); color: var(--line); margin-top: 16px; }
.meta { margin-top: 18px; font-size: 14px; font-weight: 600; color: var(--line); }

/* pasted photos */
.snap { position: relative; background: var(--print); padding: 7px 7px 9px; transform: rotate(var(--r, 0deg));
  box-shadow: 0 1px 2px rgba(90, 16, 20, .18), 0 12px 22px -14px rgba(90, 16, 20, .55); }
.snap::before { content: ""; position: absolute; top: -10px; left: 50%; width: 76px; height: 22px; margin-left: -38px; z-index: 1;
  background: rgba(185, 196, 167, .78); transform: var(--tape, rotate(calc(var(--r, 0deg) * -2))); box-shadow: 0 1px 1px rgba(90, 16, 20, .08);
  clip-path: polygon(0 8%, 6% 0, 12% 10%, 20% 2%, 28% 9%, 100% 0, 96% 50%, 100% 100%, 0 100%, 4% 50%); }
.snap--corner::before { top: -4px; left: auto; right: -4px; width: 52px; margin-left: 0; --tape: rotate(42deg); }
.board { padding: 22px 4px 4px; }
.board--2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.board-cap { order: 0; font: 400 clamp(26px, 7vw, 36px)/1.2 var(--display); color: var(--line); text-align: center; padding: 6px 8px 0; }
.page--svc-photos .board-cap { margin-bottom: 6px; }
.board-note { text-align: center; font-size: 14px; margin-top: 22px; opacity: .85; }
.board--many { columns: 2; column-gap: 16px; }
.board--many .snap { display: inline-block; width: 100%; break-inside: avoid; margin: 14px 0 12px; }
.board--3 { display: grid; grid-template-columns: 1fr 1fr; gap: 30px 16px; align-items: start; }
.board--3 .snap:first-child { grid-column: 1 / -1; width: 74%; justify-self: center; }
.page--svc-photos { justify-content: center; padding-top: 26px; }

/* wine section dividers */
.divider-in { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 30px 0 20px; min-height: 52vh; }
.divider-lock { width: 54px; margin-bottom: 26px; }
.page--divider h2 { font-weight: 400; display: flex; flex-direction: column; align-items: center; }
.divider-over { font: 800 14px/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 14px; }
.divider-title { font: 400 clamp(64px, 17vw, 112px)/1 var(--display); transform: rotate(-5deg); }
.divider-note { margin-top: 26px; max-width: 22em; }

/* package pages: their own catalog artwork is the page */
.page--pkg { padding-top: 10px; }
.pkg-art { margin: 0 -4px; }
.pkg-info { padding: 6px clamp(6px, 3vw, 30px) 0; }
.pkg-art img { mix-blend-mode: darken; }
.pkg-info .actions { margin-top: 8px; }
.pkg-info .note { margin-top: 10px; }

/* make your own */
.step { text-align: center; font-size: 16px; letter-spacing: .04em; color: var(--line); }
.step-h { text-align: center; font: 800 clamp(20px, 5.6vw, 26px)/1.2 var(--sans); text-transform: uppercase; color: var(--line); }
.step-sub { text-align: center; font-size: 15px; margin-top: 4px; }
.opts { border: 0; padding: 0; margin: 20px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; min-width: 0; }
.opt { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 8px 12px; border: 1.5px solid var(--line);
  border-radius: 16px; background: var(--cream); cursor: pointer; text-align: center; color: var(--ink); transition: background-color .2s ease, box-shadow .2s ease; }
.opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.opt:has(input:focus-visible) { outline: 3px solid var(--line); outline-offset: 3px; }
.opt:has(input:checked), .opt.is-on { background: #F6DDD3; box-shadow: inset 0 0 0 2px var(--wine); }
.opt:has(input:checked)::after, .opt.is-on::after { content: ""; position: absolute; top: 9px; right: 9px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--wine) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E") center / 14px no-repeat; }
/* the crop box keeps its exact ratio and fits inside the .art box, so the sprite never shows neighbouring art */
.art { --ah: 104px; height: var(--ah); width: 100%; display: flex; align-items: center; justify-content: center; }
.art i { position: relative; display: block; mix-blend-mode: darken; aspect-ratio: var(--ar); width: min(100%, calc(var(--ah) * var(--ar))); height: auto; background-repeat: no-repeat; }
.art-hide { position: absolute; background: var(--cream); }
.art--custom i { --ar: 1; width: 66px; border: 1.5px solid var(--line); border-radius: 50%; mix-blend-mode: normal;
  background: linear-gradient(var(--line), var(--line)) center / 26px 1.5px no-repeat, linear-gradient(var(--line), var(--line)) center / 1.5px 26px no-repeat; }
.art--custom i::after { content: ""; position: absolute; inset: 5px; border: .6px solid var(--line); border-radius: 50%; }
.opt-t { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; font: 800 14px/1.25 var(--sans); }
.badge { display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 5px; border-radius: 999px; background: var(--line); color: #fff; font: 800 12px/1 var(--sans); }
.opt-p { font: 800 18px/1 var(--sans); color: var(--wine); }
.opt-need { font-size: 12px; line-height: 1.3; opacity: .8; }
.opt--qty:not(.is-locked) .opt-need { display: none; }
.qty { display: inline-flex; align-items: center; gap: 2px; margin-top: 2px; }
.qty output { min-width: 22px; font-weight: 800; font-size: 18px; text-align: center; }
.qb { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--wine); background: var(--cream); color: var(--wine); font: 600 22px/1 var(--sans); cursor: pointer; }
.qb:hover:not(:disabled) { background: var(--wine); color: #fff; }
.qb:disabled { opacity: .35; cursor: default; }
.opt--qty { cursor: default; }
.custom { margin-top: 16px; }
.custom label { display: block; font-weight: 600; font-size: 15px; margin-bottom: 6px; }
.custom textarea { width: 100%; border: 1.5px solid var(--line); border-radius: 14px; background: #fff; color: var(--ink); font: 400 16px/1.5 var(--sans); padding: 10px 12px; resize: vertical; }

.tally { position: sticky; bottom: 10px; z-index: 20; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px;
  margin: 0 0 16px; padding: 12px 12px 10px; background: var(--cream); border: 1.5px solid var(--wine); border-radius: 22px;
  box-shadow: 0 16px 34px -14px rgba(90, 16, 20, .6); }
.tally-sum { order: 1; flex: 1 1 calc(100% - 110px); min-width: 0; font-size: 14px; font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.tally-total { order: 3; flex: 0 1 auto; min-height: 44px; padding: 8px 14px; font-size: 16px; white-space: nowrap; }
.tally-total.bump { animation: bump .35s ease; }
.tally-wa { order: 4; flex: 1 0 auto; min-height: 44px; padding: 8px 16px; font-size: 15px; white-space: nowrap; }
.tally-reset { order: 2; min-height: 44px; background: none; border: 0; padding: 0 8px; color: var(--wine); font: 600 14px/1 var(--sans); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.tally-note { display: none; font-size: 12px; opacity: .8; }
.wa-long { display: none; }
@keyframes bump { 40% { transform: scale(1.06); } }

/* floating WhatsApp */
.float-wa { position: fixed; right: 16px; bottom: 16px; z-index: 30; display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 10px 18px 10px 12px;
  background: var(--wine); color: #fff; border-radius: 999px; font: 800 16px/1 var(--sans); text-decoration: none;
  box-shadow: 0 0 0 2px var(--cream), 0 12px 26px -10px rgba(90, 16, 20, .7);
  opacity: 0; visibility: hidden; transform: translateY(14px); transition: opacity .3s ease, transform .3s ease, visibility 0s linear .3s; }
.float-wa.is-on { opacity: 1; visibility: visible; transform: none; transition: opacity .3s ease, transform .3s ease; }

/* one load moment: the cover */
@media (prefers-reduced-motion: no-preference) {
  .cover-lock { animation: drop .9s cubic-bezier(.2, .8, .2, 1) both; }
  .cover-title { animation: ink 1s .25s ease both; }
  .cover-kind, .cover-tag { animation: rise .8s .7s ease both; }
  .cover-cta { animation: rise .8s .95s ease both; }
  @keyframes drop { from { opacity: 0; transform: translateY(-28px) rotate(-8deg); } }
  @keyframes ink { from { opacity: 0; clip-path: inset(0 100% 0 0); } to { opacity: 1; clip-path: inset(0 -10% 0 0); } }
  @keyframes rise { from { opacity: 0; transform: translateY(10px); } }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- wider screens ---------- */
@media (min-width: 560px) {
  .opts--base { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .wa-long { display: inline; }
}
@media (min-width: 700px) {
  :root { --c: 96px; }
  .book { padding: 40px 24px 50px; }
  .page { padding: 20px 20px 50px; }
  .art { --ah: 120px; }
}
@media (min-width: 1000px) {
  :root { --c: 104px; }
  .book { padding: 64px 32px 72px; }
  .spread { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 56px; filter: drop-shadow(0 26px 30px rgba(90, 16, 20, .22)); }
  .page { margin: 0; box-shadow: none; padding: 24px 26px 56px; }
  .page--l { border-radius: 6px 0 0 6px; }
  .page--r { border-radius: 0 6px 6px 0; }
  .page--l::after, .page--r::after { content: ""; position: absolute; top: 0; bottom: 0; width: 46px; pointer-events: none; }
  .page--l::after { right: 0; background: linear-gradient(to left, rgba(90, 16, 20, .14), transparent); }
  .page--r::after { left: 0; background: linear-gradient(to right, rgba(90, 16, 20, .1), transparent); }
  .page--l .pnum { right: auto; left: 28px; }
  .page--r .pnum { right: 28px; }
  .divider-in { min-height: 0; }
  .tally { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr auto auto auto; width: min(820px, 92%); justify-self: center; margin: 22px 0 0; padding: 12px 14px 12px 22px; }
  .tally-sum { grid-column: 1; grid-row: 1; font-size: 15px; }
  .tally-reset { grid-column: 4; grid-row: 1; }
  .tally-note { display: block; grid-column: 1; grid-row: 2; text-align: left; }
  .tally-sum { -webkit-line-clamp: 2; }
  .wa-long { display: inline; }
  .tally-total, .tally-wa { grid-row: 1 / span 2; }
  .tally-total { grid-column: 2; }
  .tally-wa { grid-column: 3; }
  .tally-reset { grid-row: 1 / span 2; }
  .spread--config { margin-bottom: 56px; }
  .board--many { padding-top: 40px; }
  .cover { padding: 16px; }
}
