/* ============================================================
   Panqui — marketing landing page sheet (PagesController#home)

   Direction C "Soft Modern" + Direction B's center-spine Journal
   timeline, built on the real design system. This sheet consumes
   ONLY tokens.css custom properties and reuses ui.css components
   (.btn, .eyebrow, .chip, .pebble, .card, .m-card, .spine, …).
   Remaining literals are structural (border widths, element
   dimensions, percentages, aspect ratios, viewport clamps,
   1px hairlines) — never brand color/spacing values.

   Mobile-first; the wide layouts open up at the breakpoints near
   the bottom. Loaded only on the landing page.
   ============================================================ */

/* ============================================================
   SHELL
   ============================================================ */
.mkt-wrap {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 var(--space-5);
}

.mkt-section {
  padding: var(--space-9) 0;
}

.mkt-sec-head h2 {
  font-size: var(--fs-display);
}

.mkt-sec-head p {
  max-width: 46ch;
  margin: var(--space-3) 0 0;
  color: var(--muted);
  font-size: var(--fs-md);
}

/* ============================================================
   SKIP LINK  (keyboard escape from the long scroll → main)
   ============================================================ */
.mkt-skip {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  z-index: 100;
  padding: 0.6em 1.1em;
  border-radius: var(--r-pill);
  background: var(--coral-ink);
  color: var(--white);
  font-weight: var(--fw-heavy);
  text-decoration: none;
  box-shadow: var(--shadow-pill);
  transform: translateY(-150%);
  transition: transform var(--dur-base) var(--ease-out);
}

.mkt-skip:focus {
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .mkt-skip {
    transition: none;
  }
}

/* ============================================================
   TOP BAR
   ============================================================ */
.mkt-bar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}

.mkt-bar-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: center;
  justify-content: space-between;
  padding: var(--space-2) var(--space-5);
}

.mkt-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
}

/* the right cluster: the language toggle + the sign-up CTA */
.mkt-bar-end {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

/* small phones: the brand + controls no longer fit on one line, so give the
   controls their own full-width row, balanced edge-to-edge (EN/ES left, CTA
   right) instead of crammed against the left */
@media (max-width: 480px) {
  .mkt-bar-row {
    justify-content: center;
  }

  .mkt-bar-end {
    width: 100%;
    justify-content: space-between;
  }
}

.mkt-brand .dog {
  width: 38px;
  height: 38px;
}

.mkt-wordmark {
  font-family: var(--font-display);
  font-weight: var(--fw-semibold);
  font-size: var(--fs-xl);
  letter-spacing: var(--ls-tight);
  color: var(--ink);
}

.mkt-wordmark b {
  font-weight: var(--fw-semibold);
  color: var(--coral-ink);
}

/* ============================================================
   HERO
   ============================================================ */
.mkt-hero {
  position: relative;
  padding: var(--space-8) 0 var(--space-6);
}

.mkt-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.mkt-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(10px);
}

.mkt-blob-1 {
  top: -120px;
  right: -90px;
  width: 340px;
  height: 340px;
  background: var(--peach);
  opacity: 0.55;
}

.mkt-blob-2 {
  bottom: -100px;
  left: -90px;
  width: 260px;
  height: 260px;
  background: var(--butter);
  opacity: 0.5;
}

.mkt-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: var(--space-8);
  align-items: center;
}

.mkt-hero h1 {
  margin: var(--space-2) 0 var(--space-4);

  /* The marketing hero headline is intentionally larger than the in-app type
     scale (--fs-display tops out for app page heads); this is the single
     landing display size with no token equivalent. */
  font-size: clamp(2.25rem, 7.5vw, 3.6rem);
}

.mkt-lede {
  max-width: 36ch;
  margin: 0 0 var(--space-6);
  color: var(--ink-soft);
  font-size: var(--fs-lg);
}

.mkt-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-4) var(--space-6);
}

/* pebble photo cluster */
.mkt-cluster {
  position: relative;
  width: 100%;
  max-width: 460px;
  margin: 0 auto;
  aspect-ratio: 1 / 1.04;
}

.mkt-cluster .pebble {
  position: absolute;
}

.mkt-cluster .pebble img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mkt-p-main {
  top: 0;
  left: 0;
  width: 70%;
  height: 74%;
  border: 6px solid var(--white);
  box-shadow: var(--shadow-soft);
}

.mkt-p-sec {
  top: 24%;
  right: 0;
  width: 46%;
  height: 46%;
  border: 5px solid var(--white);
}

.mkt-p-thr {
  bottom: 0;
  left: 14%;
  width: 40%;
  height: 38%;
  border: 5px solid var(--white);
}

/* floating moment stickers reuse the .state-tag pill. Capped + wrap-friendly
   so the longer Spanish labels stay inside the cluster (never clip at the
   viewport edge) instead of running off a nowrap pill. */
.mkt-cluster .mkt-tag {
  position: absolute;
  z-index: 3;
  max-width: 62%;
  margin: 0;
}

.mkt-tag-a {
  top: 6%;
  left: 2%;
}

.mkt-tag-b {
  top: 26%;
  right: -4px;
}

.mkt-tag-c {
  bottom: 1%;
  left: 9%;
}

.mkt-tag .ic {
  width: 1em;
  height: 1em;
  color: var(--coral-ink);
}

/* ============================================================
   CAMERA-ROLL PROBLEM
   ============================================================ */
.mkt-problem {
  background: var(--peach-soft);
}

.mkt-problem-grid {
  display: grid;
  gap: var(--space-8);
  align-items: center;
}

.mkt-problem h2 {
  max-width: 18ch;
  font-size: var(--fs-display);
}

.mkt-problem-body {
  max-width: 42ch;
  margin: var(--space-4) 0 0;
  color: var(--ink-soft);
  font-size: var(--fs-md);
}

.mkt-scatter {
  position: relative;
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  aspect-ratio: 1 / 0.82;
}

.mkt-scatter img {
  position: absolute;
  width: 38%;
  aspect-ratio: 1;
  border: 5px solid var(--white);
  border-radius: var(--r-field);
  box-shadow: var(--shadow-card);
  object-fit: cover;
}

.mkt-s1 {
  top: 6%;
  left: 2%;
  rotate: -9deg;
}

.mkt-s2 {
  top: 0;
  left: 34%;
  z-index: 2;
  rotate: 5deg;
}

.mkt-s3 {
  top: 16%;
  right: 2%;
  rotate: 11deg;
}

.mkt-s4 {
  bottom: 2%;
  left: 12%;
  rotate: 7deg;
}

.mkt-s5 {
  right: 8%;
  bottom: 0;
  z-index: 2;
  rotate: -7deg;
}

.mkt-scatter-note {
  position: absolute;
  top: 92%;
  left: 50%;
  z-index: 5;
  padding: 0.5em 1em;
  border-radius: var(--r-pill);
  background: var(--white);
  color: var(--coral-ink);
  font-size: var(--fs-sm);
  font-weight: var(--fw-heavy);
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
  translate: -50% -50%;
  rotate: -4deg;
}

/* ============================================================
   HOW IT WORKS
   ============================================================ */
.mkt-steps {
  display: grid;
  gap: var(--space-5);
  margin-top: var(--space-8);
  align-items: stretch;
}

/* equal-height cards regardless of how long each body runs */
.mkt-step {
  height: 100%;
}

/* each step reuses the ui.css .card component (see the view); this only adds
   the step-specific bits. Neutralize the stacked-card margin so the grid stays
   aligned. */

/* beats ui.css `.card + .card` margin (which loads after marketing.css), so the
   grid cards stay top-aligned instead of cards 2+ dropping a row's margin */
.mkt-steps .mkt-step + .mkt-step {
  margin-top: 0;
}

.mkt-step-ic {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-inline: auto;
  margin-bottom: var(--space-4);
  border-radius: var(--r-field);
}

.mkt-step-ic .ic {
  width: 26px;
  height: 26px;
}

/* the three steps echo the kind-chip color families */
.mkt-step:nth-child(1) .mkt-step-ic {
  background: var(--peach);
  color: var(--coral-ink);
}

.mkt-step:nth-child(2) .mkt-step-ic {
  background: var(--sage);
  color: var(--chip-day-tx);
}

.mkt-step:nth-child(3) .mkt-step-ic {
  background: var(--butter);
  color: var(--chip-vet-tx);
}

.mkt-step h3 {
  margin-bottom: var(--space-2);
  font-size: var(--fs-lg);
}

.mkt-step p {
  margin: 0;
  color: var(--muted);
}

/* ============================================================
   SAMPLE JOURNAL  (reuses ui.css .spine / .mrow / .m-card)
   ============================================================ */
.mkt-journal {
  background: var(--bg-warm);
  scroll-margin-top: var(--space-9);
}

.mkt-journal-head {
  max-width: 46ch;
  margin: 0 auto var(--space-8);
  text-align: center;
}

.mkt-journal-head .eyebrow {
  justify-content: center;
}

.mkt-journal-head p {
  margin-inline: auto;
}

.mkt-journal .m-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ============================================================
   CONTINUITY / TRIBUTE REVEAL  (.is-tribute re-scopes tokens)
   ============================================================ */
.mkt-continuity {
  background: var(--sage-soft);
}

.mkt-continuity-inner {
  max-width: 60ch;
  margin: 0 auto;
  text-align: center;
}

.mkt-continuity-inner .eyebrow {
  justify-content: center;
}

.mkt-leaf {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin: 0 auto var(--space-4);
  border-radius: 50%;
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.mkt-leaf .ic {
  width: 26px;
  height: 26px;
  color: var(--coral-ink);
}

.mkt-continuity-inner h2 {
  max-width: 20ch;
  margin: 0 auto var(--space-4);
  font-size: var(--fs-display);
}

.mkt-continuity-body {
  max-width: 48ch;
  margin: 0 auto;
  color: var(--ink-soft);
  font-size: var(--fs-md);
}

.mkt-continuity-inner .dog {
  width: 48px;
  height: 48px;
  margin: var(--space-7) auto 0;
}

/* ============================================================
   TESTIMONIAL
   ============================================================ */
.mkt-quote .mkt-wrap {
  max-width: 780px;
}

.mkt-quote-card {
  position: relative;
  margin: 0;
  padding: var(--space-8) var(--space-7);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  background: var(--butter-soft);
  box-shadow: var(--shadow-card);
}

.mkt-quote-mark {
  display: block;
  height: 0.5em;
  font-family: var(--font-display);

  /* decorative typographic ornament — sized relative to the quote it opens */
  font-size: 2.2em;
  font-weight: var(--fw-semibold);
  line-height: 0.6;
  color: var(--coral);
}

.mkt-quote-text {
  margin: var(--space-3) 0 var(--space-5);
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: var(--fw-medium);
  line-height: var(--lh-snug);
  color: var(--ink);
}

.mkt-quote-who {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.mkt-quote-avatar {
  width: 52px;
  height: 52px;
  flex: none;
  border: 4px solid var(--white);
}

.mkt-quote-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mkt-quote-who b {
  font-weight: var(--fw-heavy);
}

.mkt-quote-meta {
  display: block;
  color: var(--muted);
  font-size: var(--fs-sm);
}

/* ============================================================
   FINAL CTA
   ============================================================ */
.mkt-final-card {
  position: relative;
  overflow: hidden;
  padding: var(--space-9) var(--space-6);
  border-radius: var(--r-card);
  background: var(--coral-ink);
  color: var(--white);
  text-align: center;
  box-shadow: var(--shadow-soft);
}

.mkt-final-blob {
  position: absolute;
  border-radius: 50%;
  background: var(--white);
  pointer-events: none;
}

.mkt-final-blob-1 {
  top: -90px;
  left: -70px;
  width: 240px;
  height: 240px;
  opacity: 0.14;
}

.mkt-final-blob-2 {
  right: -60px;
  bottom: -80px;
  width: 180px;
  height: 180px;
  background: var(--blush);
  opacity: 0.28;
}

.mkt-final-card .dog {
  position: relative;
  z-index: 1;
  width: 64px;
  height: 64px;
  margin: 0 auto var(--space-3);
}

.mkt-final-card h2 {
  position: relative;
  z-index: 1;

  /* A bespoke landing CTA display size (peaks larger than the in-app
     --fs-display); like the hero at the top, it has no token equivalent. */
  font-size: clamp(1.7rem, 5vw, 2.5rem);
  color: var(--white);
}

.mkt-final-card p {
  position: relative;
  z-index: 1;
  max-width: 36ch;
  margin: var(--space-3) auto var(--space-6);
  color: var(--peach-soft);
}

.mkt-final-card .btn {
  position: relative;
  z-index: 1;
}

/* the global focus ring is coral-ink — invisible on this coral-ink card, so
   override it to white here (WCAG 2.4.7 / 1.4.11). */
.mkt-final-card .btn:focus-visible {
  outline-color: var(--white);
}

/* ============================================================
   FOOTER
   ============================================================ */
.mkt-foot {
  padding: var(--space-7) 0;
  border-top: 1px solid var(--line);
  background: var(--bg-warm);
}

.mkt-foot-row {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  align-items: center;
  text-align: center;
}

@media (min-width: 760px) {
  .mkt-foot-row {
    flex-flow: row wrap;
    gap: var(--space-4) var(--space-6);
    align-items: center;
    justify-content: space-between;
  }
}

.mkt-foot .dog {
  width: 34px;
  height: 34px;
}

.mkt-foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-5);
}

.mkt-foot-links a {
  color: var(--muted);
  font-weight: var(--fw-bold);
  font-size: var(--fs-sm);
  text-decoration: none;
}

.mkt-foot-links a:hover {
  color: var(--coral-ink);
}

.mkt-made {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  color: var(--muted);
  font-weight: var(--fw-bold);
  font-size: var(--fs-sm);
}

.mkt-made .ic {
  width: 1.05em;
  height: 1.05em;
  color: var(--coral-ink);
}

/* ============================================================
   GENTLE SCROLL REVEALS  (restrained motion — .impeccable.md)

   The hidden start state only applies once the reveal Stimulus
   controller has added `.reveal-ready`, so content stays visible
   without JS. It is wrapped in `no-preference` so reduced-motion
   users never see it at all.
   ============================================================ */
@media (prefers-reduced-motion: no-preference) {
  .mkt.reveal-ready [data-reveal] {
    opacity: 0;
    translate: 0 16px;
    transition:
      opacity var(--dur-screen) var(--ease-out),
      translate var(--dur-screen) var(--ease-out);
  }

  .mkt.reveal-ready [data-reveal].is-revealed {
    opacity: 1;
    translate: 0 0;
  }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (min-width: 760px) {
  .mkt-hero {
    padding: var(--space-9) 0 var(--space-7);
  }

  .mkt-hero-grid {
    grid-template-columns: 1.05fr 0.95fr;
    gap: var(--space-9);
  }

  .mkt-cluster {
    max-width: 500px;
  }

  .mkt-problem-grid {
    grid-template-columns: 1fr 1fr;
  }

  .mkt-steps {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1000px) {
  .mkt-section {
    padding: var(--space-10) 0;
  }
}
