/* ---------------------------------------------------------------------------
   CNY campaign: the hero arch, the closing band and the product mockups in
   the feature-hub, proof-bento and scene-tabs sections.
   Mockup markup lives in resources/views/pages/landing/cny-campaign/; the
   cream and brown are the Sunfold demo store's own colours.

   Loaded by resources/views/pages/landing/cny-campaign.blade.php.
   Plain CSS, no Tailwind @apply here.
   Bump the ?v on that <link> whenever this file changes.
--------------------------------------------------------------------------- */

:root {
  --cny-cream: #f7f3ea;
  --cny-cream-field: #eae6dc;
  --cny-cream-line: #e2dbce;
  --cny-brown: #30251d;
  --cny-ink: #242a31;
  --cny-line: #e0e4ea;
  --cny-muted: var(--color-gray-500);
  --cny-green: #168643;
  --cny-green-light: #eaf5ec;
  --cny-pointer: #17243d;
}

/* One gap between all sections. [class] lifts these over the py-10 every
   section carries; a section on the same background as the one before keeps
   no top padding, so the gap stays one step there too. */
main > section[class] {
  padding-top: 56px;
  padding-bottom: 56px;
}

main > .section-bg-gray + .section-bg-gray {
  padding-top: 0;
}

.section-plan-cards > .py-6 {
  padding-top: 0;
  padding-bottom: 0;
}

.section-feature-grid .section-title {
  padding-top: 0;
}

.section-feature-grid .wrapper-container {
  margin-bottom: 0;
  padding-bottom: 0;
}

@media (min-width: 1024px) {
  main > section[class] {
    padding-top: 80px;
    padding-bottom: 80px;
  }
}

/* The hero already sits below the header, and its columns carry their own
   bottom padding. */
main > section.cny-hero {
  padding-top: 40px;
  padding-bottom: 40px;
}

/* The feature section's columns would add their own gap at the band's
   edges: on phones the photo stacks above the copy. */
section.cny-closing .lg\:min-h-\[450px\] {
  padding-top: 0;
}

section.cny-closing .py-6 {
  padding-bottom: 0;
}

@media (min-width: 1024px) {
  main > section.cny-hero {
    padding-bottom: 64px;
  }

  section.cny-closing .lg\:min-h-\[450px\] {
    min-height: 0;
    padding-bottom: 0;
  }
}

/* Hero and closing photos */

.section-hero.cny-hero img:not(.hero-logo) {
  border-radius: 50% 50% 12px 12px;
  aspect-ratio: 1;
  object-fit: cover;
}

.section-feature.cny-closing img {
  border-radius: 20px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

p:has(> .cny-contact-link) {
  margin-top: 1rem;
}

@media (max-width: 767px) {
  p:has(> .cny-contact-link) {
    text-align: center;
  }
}

/* Shared mockup surfaces */

.cny-ui {
  width: 100%;
  max-width: 480px;
  margin: auto;
  padding: 20px;
  border: 1px solid var(--cny-line);
  border-radius: 12px;
  background: var(--color-white);
  box-shadow: 0 14px 30px rgba(31, 45, 69, 0.06);
  color: var(--cny-ink);
  font-size: 14px;
  line-height: 1.5;
  text-align: left;
}

.cny-ui p {
  margin: 0;
}

.cny-ui--sunfold {
  border-color: var(--cny-cream-line);
  background: var(--cny-cream);
  color: var(--cny-brown);
}

.cny-ui-head {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--cny-line);
  font-size: 16px;
  font-weight: 700;
}

.cny-ui-head span {
  color: var(--cny-muted);
  font-size: 12px;
  font-weight: 400;
}

.cny-ui .cny-ui-label {
  margin: 12px 0 6px;
  font-size: 13px;
}

.cny-field {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--cny-line);
  border-radius: 7px;
  background: var(--color-white);
}

.cny-bubble {
  padding: 16px;
  border-radius: 0 12px 12px 12px;
  background: var(--cny-green-light);
  color: #234637;
  line-height: 1.8;
}

.cny-bubble u {
  color: var(--color-primary);
}

.cny-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.cny-chips span {
  padding: 6px 10px;
  border: 1px solid #d8e0ec;
  border-radius: 6px;
  color: var(--color-primary);
  font-size: 12px;
}

.cny-product-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.cny-product-row img {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border-radius: 9px;
  object-fit: cover;
}

.cny-product-row strong {
  display: block;
  margin-top: 2px;
}

/* The demo pointer the scripted walkthroughs move between controls. */
.cny-pointer {
  position: absolute;
  z-index: 2;
  top: 50%;
  right: 15%;
  width: 24px;
  height: 28px;
  pointer-events: none;
  opacity: 0;
  transform: translate(12px, 12px);
  transition: opacity 180ms ease-out, transform 360ms cubic-bezier(0.22, 1, 0.36, 1);
  filter: drop-shadow(0 2px 2px rgba(23, 36, 61, 0.15));
}

.cny-cal-day .cny-pointer {
  top: 60%;
  right: auto;
  left: 55%;
}

.is-demo-hover .cny-pointer {
  opacity: 1;
  transform: none;
}

.is-demo-press .cny-pointer {
  transform: translate(0, 2px) scale(0.92);
}

/* Overview: Sunfold storefront in a browser frame */

.cny-browser {
  overflow: hidden;
  border: 7px solid #233047;
  border-radius: 17px;
  background: var(--cny-cream);
  box-shadow: 0 20px 50px rgba(22, 51, 98, 0.14);
}

.cny-browser-bar {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 30px;
  padding: 0 9px;
  background: #f2f3f5;
  color: #67717e;
  font-size: 10px;
}

.cny-browser-bar i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #b8c1cc;
}

.cny-browser-bar span {
  margin: auto;
}

.cny-shop-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 15px;
  color: var(--cny-brown);
  font-size: 10px;
}

.cny-shop-nav img {
  width: 80px;
  height: auto;
}

.cny-shop-banner {
  position: relative;
}

.cny-shop-banner img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.cny-shop-banner div {
  position: absolute;
  top: 20px;
  left: 17px;
  color: var(--color-white);
  font-size: 20px;
  line-height: 1.4;
  text-shadow: 0 1px 9px rgba(0, 0, 0, 0.53);
}

.cny-shop-products {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
  padding: 15px;
}

.cny-shop-products img {
  aspect-ratio: 1;
  border-radius: 5px;
  object-fit: cover;
}

.cny-shop-products span {
  color: var(--cny-brown);
  font-size: 10px;
}

.cny-shop-link {
  display: block;
  margin-top: 20px;
  color: var(--color-primary);
  font-size: 14px;
  text-align: center;
  text-decoration: underline;
}

/* Proof: delivery date picker */

.cny-cal {
  padding: 12px;
  border: 1px solid #d9d9d9;
  border-radius: 8px;
  background: var(--color-white);
}

.cny-cal > b {
  display: block;
  text-align: center;
}

.cny-cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-top: 8px;
  text-align: center;
}

.cny-cal-days > span {
  color: #6f757b;
  font-size: 12px;
}

.cny-cal-day {
  position: relative;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: #333;
  font-size: 13px;
  transition: background-color 180ms ease-out, color 180ms ease-out, box-shadow 180ms ease-out;
}

.cny-cal-day.is-demo-hover {
  background: #edf3ff;
  box-shadow: inset 0 0 0 2px rgba(21, 92, 228, 0.25);
}

.cny-cal-day.is-chosen {
  background: var(--color-primary);
  color: var(--color-white);
}

.cny-select {
  width: 100%;
  min-height: 42px;
  padding: 8px 46px 8px 16px;
  border: 0;
  border-radius: 24px;
  background: var(--cny-cream-field)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2330251d' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E")
    no-repeat right 18px center / 16px;
  color: inherit;
  font: inherit;
  appearance: none;
}

/* Proof: greeting card */

.cny-gift-summary {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--cny-cream-line);
}

.cny-gift-summary img {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 7px;
  object-fit: cover;
}

.cny-gift-summary b,
.cny-gift-summary span {
  display: block;
}

.cny-gift-summary span {
  color: #7a7065;
  font-size: 11px;
}

.cny-greeting-input {
  width: 100%;
  min-height: 42px;
  padding: 8px 16px;
  border: 0;
  border-radius: 24px;
  background: var(--cny-cream-field);
  color: inherit;
  font: inherit;
}

.cny-greeting-card {
  margin-top: 12px;
  padding: 14px 10px;
  border: 1px solid #c5ae88;
  background: #fffdf5;
  text-align: center;
}

.cny-greeting-card small {
  font-size: 10px;
  letter-spacing: 2px;
}

.cny-ui .cny-greeting-preview {
  min-height: 3.3em;
  margin: 10px 0;
  color: #6e3c27;
  font-size: 16px;
  overflow-wrap: anywhere;
}

.cny-greeting-preview.is-typing::after {
  content: '';
  display: inline-block;
  width: 1px;
  height: 1em;
  margin-left: 2px;
  vertical-align: -0.12em;
  background: currentColor;
  animation: cny-caret 900ms step-end infinite;
}

@keyframes cny-caret {
  50% {
    opacity: 0;
  }
}

.cny-greeting-card span {
  font-size: 12px;
}

/* Proof: same-day courier choice */

.cny-shipping-choices {
  padding: 3px 5px;
}

.cny-shipping {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 60px;
  margin: 10px 0;
  padding: 12px 14px;
  border: 2px solid var(--cny-line);
  border-radius: 7px;
  background: var(--color-white);
  color: var(--cny-muted);
  text-align: left;
  transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1), border-color 180ms ease-out, background-color 180ms ease-out;
}

.cny-shipping.is-active {
  z-index: 1;
  border-color: var(--color-primary);
  background: #f3f7ff;
  box-shadow: 0 5px 14px rgba(21, 92, 228, 0.08);
  transform: scale(1.035);
}

.cny-shipping-dot {
  flex: 0 0 16px;
  height: 16px;
  border: 1.5px solid #aab6c9;
  border-radius: 50%;
}

.cny-shipping.is-active .cny-shipping-dot {
  border: 5px solid var(--color-primary);
}

/* cover trims the padding baked into the Lalamove logo file. */
.cny-shipping img {
  width: 100px;
  height: 28px;
  object-fit: cover;
}

.cny-shipping-caption {
  margin-left: auto;
  font-size: 12px;
  white-space: nowrap;
}

/* Proof: WhatsApp order form, phone width */

.cny-wa {
  width: 100%;
  max-width: 310px;
  margin: auto;
  overflow: hidden;
  border: 1px solid var(--cny-line);
  border-radius: 22px;
  background: var(--color-white);
  box-shadow: 0 14px 30px rgba(31, 45, 69, 0.06);
  color: #15191f;
  text-align: left;
}

.cny-wa-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px;
  padding: 13px 12px;
  border-bottom: 1px solid #eef0f3;
  font-size: 10px;
}

.cny-wa-toolbar span:first-child {
  font-weight: 700;
}

.cny-wa-catalog {
  height: 340px;
  padding: 0 10px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.cny-wa-product {
  margin: 12px 0 0;
  overflow: hidden;
  border: 1px solid #e3e7ee;
  border-radius: 14px;
}

.cny-wa-product img {
  width: 100%;
  height: 150px;
  object-fit: contain;
}

.cny-wa-product h4 {
  margin: 12px;
  font-size: 15px;
  line-height: 1.4;
}

.cny-wa-variant {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 12px;
  border-top: 1px solid #e9ecf0;
}

.cny-wa-variant small,
.cny-wa-variant strong {
  display: block;
}

.cny-wa-variant small {
  color: #778090;
  font-size: 12px;
}

.cny-wa-variant strong {
  color: #414c5e;
  font-size: 14px;
}

.cny-wa-quantity {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
}

.cny-wa-quantity button {
  position: relative;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid #d5dce6;
  border-radius: 50%;
  background: var(--color-white);
  color: #182230;
  font-size: 20px;
}

.cny-wa-quantity button:disabled {
  color: #c6ccd5;
}

.cny-wa-plus.is-demo-hover {
  border-color: var(--color-primary);
  background: #f0f5ff;
}

.cny-wa-footer {
  padding: 11px 12px 13px;
  border-top: 1px solid #e1e5eb;
}

.cny-wa-send {
  padding: 10px;
  border-radius: 12px;
  background: #21ce63;
  color: var(--color-white);
  font-weight: 600;
  text-align: center;
}

.cny-wa-buy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 9px;
  padding: 12px 10px;
  border: 1px solid #e1e5ed;
  border-radius: 12px;
  background: #f8f9fb;
  font-size: 13px;
}

.cny-wa-total {
  color: #7c8798;
  font-size: 12px;
}

.cny-wa-footer small {
  display: block;
  margin-top: 10px;
  color: #97a2b2;
  font-size: 9px;
  text-align: center;
}

/* Proof: guest checkout */

.cny-checkout {
  display: grid;
}

.cny-checkout-form,
.cny-checkout-success {
  grid-area: 1 / 1;
  transition: opacity 220ms ease-out;
}

.cny-data-bar {
  display: block;
  width: 88%;
  height: 8px;
  border-radius: 6px;
  background: #d8dde4;
}

.cny-data-bar--phone {
  width: 55%;
}

.cny-data-bar--short {
  width: 62%;
}

.cny-field--address {
  flex-direction: column;
  align-items: flex-start;
  gap: 9px;
}

.cny-checkout-pay {
  position: relative;
  width: 100%;
  min-height: 46px;
  margin-top: 16px;
  border: 0;
  border-radius: 5px;
  background: var(--cny-brown);
  color: var(--color-white);
}

.cny-checkout-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  visibility: hidden;
  opacity: 0;
}

.cny-checkout-success svg {
  width: 76px;
  height: 76px;
}

.cny-checkout-success circle {
  fill: #edf6ef;
}

.cny-checkout-success path {
  fill: none;
  stroke: var(--cny-green);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cny-ui .cny-checkout-success p {
  font-size: 20px;
  font-weight: 700;
}

.cny-checkout.is-paid .cny-checkout-form {
  visibility: hidden;
  opacity: 0;
}

.cny-checkout.is-paid .cny-checkout-success {
  visibility: visible;
  opacity: 1;
}

/* Proof: shipment progress; the bar grows to a stop before the stop lights up. */

.cny-tracking {
  --cny-track-progress: 0.666667;
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 24px 0 0;
  padding: 0;
  color: #7c8690;
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
  list-style: none;
}

.cny-tracking::before,
.cny-tracking::after {
  content: '';
  position: absolute;
  top: 6px;
  left: 12.5%;
  width: 75%;
  height: 2px;
  background: #dce5df;
}

.cny-tracking::after {
  background: var(--cny-green);
  transform: scaleX(var(--cny-track-progress));
  transform-origin: left center;
  transition: transform 700ms cubic-bezier(0.4, 0, 0.2, 1);
}

.cny-tracking.is-resetting::after {
  transition: none;
}

.cny-tracking li {
  position: relative;
  z-index: 1;
  min-width: 0;
  margin: 0;
  padding: 24px 4px 0;
  overflow-wrap: anywhere;
}

.cny-tracking li::before {
  content: '';
  position: absolute;
  top: 0;
  left: calc(50% - 7px);
  width: 14px;
  height: 14px;
  border: 2px solid #dce5df;
  border-radius: 50%;
  background: var(--color-white);
  box-sizing: border-box;
}

.cny-tracking .is-complete {
  color: var(--cny-green);
}

.cny-tracking .is-complete::before {
  border-color: var(--cny-green);
  background: var(--cny-green);
}

.cny-tracking .is-current {
  color: var(--cny-green);
  font-weight: 700;
}

.cny-tracking .is-current::before {
  border: 3px solid var(--color-white);
  background: var(--cny-green);
  box-shadow: 0 0 0 2px var(--cny-green);
}

/* Scenes: voucher and order list */

.cny-voucher {
  padding: 28px 15px;
  border: 1px dashed #b49a65;
  background: #fff9e9;
  text-align: center;
}

.cny-voucher small {
  font-size: 10px;
  letter-spacing: 2px;
}

.cny-voucher strong {
  display: block;
  margin: 14px 0;
  color: #825b29;
  font-size: 20px;
}

.cny-order-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 0;
  border-bottom: 1px solid #eee;
}

.cny-order-row b {
  color: #62705a;
  font-size: 13px;
}

@media (prefers-reduced-motion: reduce) {
  .cny-pointer {
    display: none;
  }

  .cny-cal-day,
  .cny-shipping,
  .cny-checkout-form,
  .cny-checkout-success,
  .cny-tracking::after {
    transition: none;
  }

  .cny-greeting-preview.is-typing::after {
    display: none;
  }
}

/* Buying experience: the draft's four-column bento. The date card spans two
   rows on the left; the lead cards sit copy beside mockup; the mockups are
   zoomed down to fit. */
section.cny-proofs .pb-card:nth-child(2) {
  background: #fcf8f2;
}

section.cny-proofs .pb-card:nth-child(3),
section.cny-proofs .pb-card:nth-child(5),
section.cny-proofs .pb-card:nth-child(6) {
  background: #f9fbff;
}

@media (min-width: 1101px) {
  section.cny-proofs .pb-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-rows: minmax(230px, auto) minmax(230px, auto) minmax(440px, auto);
    gap: 18px;
  }

  /* Copy and mockup carry their own padding, as in the draft, so the
     mockup side can sit closer to the card edge than the copy. */
  section.cny-proofs .pb-card {
    grid-row: auto;
    grid-template-rows: auto 1fr;
    gap: 0;
    padding: 0;
    border-radius: 20px;
  }

  section.cny-proofs .pb-card-head {
    padding: 20px 18px 4px;
  }

  section.cny-proofs .pb-proof {
    padding: 10px 14px 16px;
  }

  section.cny-proofs .pb-card:nth-child(1),
  section.cny-proofs .pb-card:nth-child(2),
  section.cny-proofs .pb-card:nth-child(3),
  section.cny-proofs .pb-card:nth-child(4) {
    grid-template-rows: none;
    grid-template-columns: 0.9fr 1.1fr;
    align-items: center;
  }

  section.cny-proofs .pb-card:nth-child(-n + 4) .pb-card-head {
    padding: 18px 0 18px 18px;
  }

  section.cny-proofs .pb-card:nth-child(-n + 4) .pb-proof {
    padding: 14px;
  }

  section.cny-proofs .pb-card:nth-child(1) .pb-card-head {
    padding: 22px 0 22px 22px;
  }

  section.cny-proofs .pb-card:nth-child(1) .pb-proof {
    padding: 16px 14px;
  }

  section.cny-proofs .pb-tags {
    gap: 4px;
  }

  section.cny-proofs .pb-card:nth-child(1) {
    grid-column: 1 / 3;
    grid-row: 1 / 3;
    grid-template-columns: 0.85fr 1.15fr;
  }

  section.cny-proofs .pb-card:nth-child(2) {
    grid-column: 3 / 5;
    grid-row: 1;
  }

  section.cny-proofs .pb-card:nth-child(3) {
    grid-column: 3 / 5;
    grid-row: 2;
  }

  section.cny-proofs .pb-card:nth-child(4) {
    grid-column: 3 / 5;
    grid-row: 3;
    grid-template-columns: 1.12fr 0.88fr;
  }

  section.cny-proofs .pb-card:nth-child(5) {
    grid-column: 1;
    grid-row: 3;
  }

  section.cny-proofs .pb-card:nth-child(6) {
    grid-column: 2;
    grid-row: 3;
  }

  section.cny-proofs .pb-card-title {
    font-size: 18px;
    line-height: 1.45;
  }

  section.cny-proofs .pb-card:nth-child(1) .pb-card-title,
  section.cny-proofs .pb-card:nth-child(4) .pb-card-title {
    font-size: 23px;
  }

  section.cny-proofs .pb-card-text {
    margin-top: 8px;
    font-size: 13px;
    line-height: 1.65;
  }

  section.cny-proofs .pb-proof {
    justify-content: center;
  }

  section.cny-proofs .pb-card:nth-child(3) .cny-product-row {
    display: none;
  }

  section.cny-proofs .pb-proof > .cny-ui {
    zoom: 0.68;
  }

  section.cny-proofs .pb-card:nth-child(1) .cny-ui {
    zoom: 0.7;
  }

  section.cny-proofs .pb-card:nth-child(4) .cny-wa {
    zoom: 0.62;
  }
}
