/* ============================================================
   Turni — DEDICATED MOBILE LAYER  (loaded after landing.css)
   Phone-crafted, compact. Threshold: ≤760px.
   Pairs with landing-mobile.js (carousel · swipe-tabs · sticky CTA).
   ============================================================ */

/* dots + caption + sticky bar are injected only on mobile by JS;
   their styles can sit outside the query safely. */
.m-democap { display: none; }
.m-dots { display: none; }
.m-stickycta { display: none; }

@media (max-width: 900px) {
  /* nav floats over content instead of reserving a 64px flow slot — the cream
     hero bleeds to the very top edge, no strip above the banner. */
  .nav { position: fixed; left: 0; right: 0; }
  html { scroll-padding-top: 64px; }   /* anchor jumps clear the floating bar */
  .drawer { top: 64px; }
  /* keep the mobile bar to logo + menu — cross-link & CTA live in the drawer */
  .nav__in { height: 64px; }
  .nav__right .nav__cross,
  .nav__right > .tk-btn { display: none; }
  .nav__right { gap: 8px; }
}

@media (max-width: 760px) {

  /* ---------- density + type ---------- */
  :root { --gutter: 18px; }

  /* hide the floating bar at the very top so it doesn't sit beside the hero
     wordmark (two logos); JS reveals it once you scroll into content. */
  .nav { transition: transform .32s var(--ease-out), border-color .25s, box-shadow .25s, background .25s; }
  .nav.is-top-hidden { transform: translateY(-100%); }
  .section { padding-block: 44px; }
  .section--tight { padding-block: 36px; }
  .sec-head { gap: 12px; margin-bottom: 24px !important; }
  .t-h1 { font-size: 28px; line-height: 1.1; }
  .t-h2 { font-size: 23px; line-height: 1.14; }
  .t-h3 { font-size: 18px; }
  .lead { font-size: 15.5px; line-height: 1.5; max-width: none; }
  .eyebrow { font-size: 12px; }
  .grid { gap: 14px; }

  /* ---------- hero brand banner ---------- */
  .hero { height: clamp(220px, 50vw, 280px); }
  /* bar floats, so the hero starts at the very top — drop the wordmark ~60px
     so it isn't glued to the top edge. */
  .hero__in { padding-top: 60px; }
  .hero__lottie { width: clamp(148px, 47vw, 196px); }
  .hero__kicker { font-size: 11px; letter-spacing: 0.12em; position: relative; z-index: 0; margin-top: 10px; }
  .hero__kicker b { margin-inline: 5px; }
  /* soften the busy illustration behind the kicker — a full-width backdrop blur
     band (edge-to-edge, so no side boundary) feathered only top/bottom, so it
     melts into the hero with no visible seam. Behind the text (z-index:-1). */
  .hero__kicker::before {
    content: "";
    position: absolute;
    top: -18px;
    bottom: -18px;
    left: 50%;
    width: 100vw;
    transform: translateX(-50%);
    z-index: -1;
    -webkit-backdrop-filter: blur(7px);
    backdrop-filter: blur(7px);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 0%, #000 30%, #000 70%, rgba(0,0,0,0) 100%);
    mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 0%, #000 30%, #000 70%, rgba(0,0,0,0) 100%);
    pointer-events: none;
  }

  /* ---------- offer band ---------- */
  .hero-band__in { text-align: left; padding-block: 22px 28px; row-gap: 16px; }
  .hero-band__title { font-size: clamp(31px, 8.6vw, 40px); line-height: 1.02; max-width: 100%; margin-inline: 0; }
  .hero-band__right { align-items: stretch; gap: 16px; }
  .hero-band__line { font-size: 19px; margin-inline: 0; max-width: none; }
  .hero-band__right .hero__badges { justify-content: flex-start; }

  /* CTAs: full-width, stacked, easy thumb targets */
  .hero__cta { flex-direction: column; align-items: stretch; width: 100%; gap: 10px; margin-top: 2px; }
  .hero__cta .tk-btn { width: 100%; justify-content: center; }
  .tk-btn.is-xl { height: 52px; font-size: 15.5px; }

  /* badges wrap instead of overflow */
  .hero__badges { gap: 8px; }
  .badge { white-space: normal; height: auto; min-height: 34px; padding: 7px 13px; line-height: 1.25; font-size: 13px; }

  /* ---------- "o que é" ---------- */
  .section--tight .display.t-h2 { font-size: 22px; }

  /* ---------- como funciona (vertical stepper) ---------- */
  .steps { gap: 16px; }
  .steps__line, .steps__fill { left: 22px; }
  .step { gap: 14px; }
  .step__num { width: 44px; height: 44px; font-size: 17px; }
  .step h3 { font-size: 15px; }
  .step p { font-size: 13px; }
  .step__txt { padding-top: 3px; }

  /* ---------- product demo → swipe-tabs + dots ---------- */
  .demo-wrap { gap: 16px; }
  .demo-feats, .appfeat { display: none; }      /* replaced by caption + swipe + dots */
  .demo-wrap h2 { margin-top: 12px !important; }
  .demo-wrap .lead { margin-top: 10px !important; }

  .m-democap { display: block; margin-bottom: 12px; }
  .m-democap b { font-family: var(--font-display); font-weight: 600; font-size: 16px; display: block; color: var(--td-ink-900); letter-spacing: -.01em; }
  .m-democap span { display: block; color: var(--fg-muted); font-size: 13px; margin-top: 3px; line-height: 1.4; }

  .browser, .phone { touch-action: pan-y; }
  .browser { user-select: none; }

  .m-dots { display: flex; gap: 7px; justify-content: center; margin-top: 14px; }
  .m-dot { width: 7px; height: 7px; border-radius: 50%; border: 0; background: var(--td-gray-300); padding: 0; cursor: pointer; transition: width .25s var(--ease-out), background .25s; -webkit-tap-highlight-color: transparent; }
  .m-dot.is-on { background: var(--td-teal-600); width: 22px; border-radius: 4px; }

  /* ---------- compliance — mobile flow ----------
     side nodes become slim label cards (cap + title only); the Turni core
     stays the dominant card with its pills; tight down-arrows between. */
  .compliance { gap: 0; }
  .cnode { padding: 16px 16px; border-radius: var(--radius-xl); gap: 6px; }
  .cnode .cap { font-size: 11px; }
  .cnode h3 { font-size: 16px; }
  .cnode:not(.ccore) p { display: none; }   /* drop long desc on the two side nodes */
  .ccore { padding: 20px 18px; }
  .ccore h3 { font-size: 16.5px; }
  .ccore__pills { gap: 6px; margin-top: 4px; }
  .ccore__pills span { font-size: 12px; padding: 4px 10px; }
  /* desktop rotates a full-width connector cell → a sliver on mobile.
     drop the rotate; tiny down-chevron between nodes. */
  .cconn { transform: none; padding: 0; }
  .cconn svg { width: 22px; height: 22px; transform: rotate(90deg); }

  /* ---------- browser mockup: slim the desktop chrome ---------- */
  .browser__bar { padding: 8px 12px; }
  .browser__dots i { width: 8px; height: 8px; }
  .browser__url { height: 22px; max-width: none; font-size: 11px; }

  /* ---------- feature / guarantee cards — icon left, text right ----------
     (column layout left big white gaps on a phone) */
  .feature, .guarantee, .ctrl {
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 14px;
    row-gap: 3px;
    align-items: start;
    padding: 16px 18px;
  }
  .feature__ic, .guarantee__n, .ctrl__ic { grid-row: 1 / span 2; align-self: start; }
  .feature h3, .feature p, .guarantee h3, .guarantee p, .ctrl h3, .ctrl p { grid-column: 2; }
  .feature h3, .guarantee h3, .ctrl h3 { align-self: center; }
  .feature__ic { width: 42px; height: 42px; }
  .feature h3 { font-size: 16px; }
  .feature p { font-size: 14px; }
  .guarantee { padding: 18px 18px; }
  .guarantee h3 { font-size: 17px; }
  .guarantee p { font-size: 14px; }

  /* ---------- dores / persona — compact 3-up segmented control ----------
     all three personas fit one row, so the switch is visible above the panel */
  .persona-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; overflow: visible; }
  .ptab { flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 12px 6px; }
  .ptab__ic { width: 36px; height: 36px; }
  .ptab b { font-size: 11.5px; line-height: 1.15; }
  .ptab b + span { display: none; }   /* hide subtitle on mobile */
  .ba { padding: 18px 20px; }
  .persona-panel__media { aspect-ratio: 16 / 9; }

  /* ---------- economics ---------- */
  .bar { padding: 20px; }
  .econ__delta .big { font-size: clamp(46px, 16vw, 64px); }

  /* ---------- roles → edge-to-edge swipe carousel ---------- */
  .roles {
    display: flex;
    grid-template-columns: none;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin-inline: calc(var(--gutter) * -1);
    padding-inline: var(--gutter);
    padding-bottom: 4px;
  }
  .roles::-webkit-scrollbar { display: none; }
  .role {
    flex: 0 0 44%;
    scroll-snap-align: start;
    aspect-ratio: 3 / 4;
  }
  .role--more { flex: 0 0 44%; aspect-ratio: 3 / 4; }
  .role__cap { font-size: 12px; padding: 16px 10px 8px; }

  /* ---------- proof (alta demanda / JET) ---------- */
  /* !important beats the inline `grid-template-columns:1.1fr 1fr` on the
     "Alta demanda" block — otherwise it stays 2-col on mobile and, with the
     media hidden, the text crams into the left half. */
  .proof { gap: 18px; grid-template-columns: 1fr !important; }
  .proof__media { aspect-ratio: 16 / 11 !important; }
  /* avoid two illustrations back-to-back: drop the high-demand image, keep JET's */
  [data-screen-label="Alta demanda"] .proof__media { display: none; }
  .proof blockquote { font-size: 20px; }
  /* stat cards: full-width, stacked (not squeezed side-by-side) */
  .proof .row { gap: 10px; flex-direction: column; align-items: stretch; }
  .proof .row .tk-stat { width: 100%; min-width: 0; }

  /* ---------- CTA + form ---------- */
  .cta { padding: 26px 20px; border-radius: 22px; }
  .cta::before { width: 320px; height: 320px; right: -120px; top: -140px; }
  .cta__contacts { margin-top: 18px; gap: 10px; }
  .cta__contacts a { font-size: 14.5px; }
  .form { padding: 20px; }

  /* ---------- footer ---------- */
  .foot { padding-block: 40px 26px; }
  .foot__top { grid-template-columns: 1fr 1fr; gap: 26px 22px; padding-bottom: 28px; }
  .foot__top > :first-child { grid-column: 1 / -1; }
  .foot p { max-width: none; font-size: 13.5px; }
  .foot__bottom { flex-direction: column; align-items: flex-start; gap: 10px; padding-top: 22px; }

  /* ============ /trabalhe ============ */

  /* doer hero: tall but not full-screen */
  .hero--doer { min-height: clamp(500px, 84vh, 620px); height: auto; }
  .hero--doer .hero__in { padding-block: 92px 36px; gap: 16px; }
  .hero--doer h1 { font-size: clamp(38px, 11vw, 56px); line-height: .98; max-width: 100%; }
  .hero--doer .hero__sub { font-size: 16px; line-height: 1.45; }
  .hero--doer .hero__cta { align-items: stretch; }
  .hero--doer .hero__cta .tk-btn { width: 100%; }

  /* você no controle (icon-left layout shared with .feature above) */
  .controle { gap: 12px; }
  .ctrl__ic { width: 44px; height: 44px; }
  .ctrl h3 { font-size: 16px; }
  .ctrl p { font-size: 14px; }

  /* fluxo de ganhos → compact 2×2 grid */
  .fluxo { grid-template-columns: 1fr 1fr; gap: 10px; }
  .fstep { padding: 16px 15px; gap: 8px; }
  .fstep__arrow { display: none; }
  .fstep h4 { font-size: 14.5px; }
  .fstep p { font-size: 12.5px; }

  /* earnings card */
  .joy { padding: 24px; border-radius: var(--radius-2xl); gap: 14px; }
  .joy__amt { font-size: clamp(40px, 13vw, 56px); }
  .joy__meta { gap: 14px 18px; flex-wrap: wrap; }
  .joy__meta > div { min-width: 84px; }
  .joy__meta div b { font-size: 19px; }

  /* faq */
  .faq__item summary { padding: 16px 18px; font-size: 15.5px; }
  .faq__body { padding: 0 18px 16px; font-size: 14px; }

  /* trabalhe CTA right column buttons full width */
  .reg-doer .cta .tk-btn { width: 100%; }

  /* ---------- sticky CTA bar (trabalhe only) ---------- */
  .reg-doer .m-stickycta {
    display: flex;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 70;
    gap: 10px;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px));
    background: rgba(255, 255, 255, .94);
    -webkit-backdrop-filter: saturate(1.4) blur(14px);
    backdrop-filter: saturate(1.4) blur(14px);
    border-top: 1px solid var(--td-gray-200);
    box-shadow: 0 -8px 24px -16px rgba(20, 24, 27, .35);
    transform: translateY(115%);
    transition: transform .32s var(--ease-out);
  }
  .reg-doer .m-stickycta.is-show { transform: none; }
  .reg-doer .m-stickycta .tk-btn { flex: 1; justify-content: center; height: 50px; }
  .reg-doer.has-stickycta { padding-bottom: 74px; }
}

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