/* Landing page — responsive overrides (media queries).
   Dimuat SETELAH landing.css agar cascade override tetap benar. */

/* — Tablet landscape / small desktop — */
@media (max-width: 1040px) {
  .hero h1 { font-size: clamp(2.4rem, 5.5vw, 3.8rem); }
  .insights__layout { gap: 54px; }
  .comparison__heading h2 { font-size: 2.8rem; }
  .workflow__shell { grid-template-columns: 300px minmax(0,1fr); }
  .workflow__steps { padding-inline: 20px; }
  .workflow__progress { left: 42px; }
}

/* — Tablet portrait / large phone — */
@media (max-width: 820px) {
  :root { --nav-height: 64px; }
  .desktop-nav { display: none; }
  .menu-button { display: block; }
  .section { padding: 80px 0; }
  .section-heading { grid-template-columns: 1fr; gap: 18px; }
  .section-heading > p { max-width: 100%; }

  /* Hero */
  .hero { height: 200vh; min-height: 1200px; }
  .hero__sticky { min-height: 560px; }
  .hero__content { max-width: 90%; padding-inline: 16px; }
  .hero h1 { font-size: clamp(2rem, 7vw, 3.2rem); }
  .hero__lead { font-size: clamp(0.9rem, 3vw, 1.05rem); max-width: 100%; }
  .hero__kicker { margin-bottom: 20px; letter-spacing: .18em; }
  .hero__kicker span { font-size: 0.75rem !important; padding: 5px 10px !important; letter-spacing: 0.12em !important; }

  /* Comparison */
  .comparison { margin-top: -50vh; padding-top: 80px; border-radius: 28px 28px 0 0; }
  .comparison__heading h2 { font-size: 2.45rem; }
  .insights__layout { grid-template-columns: 1fr; }
  .comparison-stage { height: auto; margin-top: 32px; overflow: visible; }
  .comparison-showcase-card { position: relative; top: auto; left: auto; display: none; width: 100%; max-width: 620px; min-height: 0; margin: 0 auto; cursor: default; opacity: 1; filter: none; transform: none !important; }
  .comparison-showcase-card[aria-hidden="false"] { display: flex; }
  .comparison-showcase-card--mirror { display: none; }
  .section-intro { max-width: 100%; }

  /* Workflow */
  .workflow { height: auto; }
  .workflow .container { position: static; top: auto; margin-bottom: 0; }
  .workflow__shell { grid-template-columns: 1fr; min-height: auto; }
  .workflow__steps { display: grid; grid-template-columns: repeat(5, minmax(120px, 1fr)); overflow-x: auto; padding: 16px; border-right: 0; border-bottom: 1px solid var(--border); -webkit-overflow-scrolling: touch; scroll-snap-type: x mandatory; }
  .workflow-step { scroll-snap-align: center; }
  .workflow__progress { display: none; }
  .workflow-step { min-height: 80px; grid-template-columns: 36px 1fr; padding: 8px; }
  .workflow-step__number { width: 36px; height: 36px; }
  .workflow-step small { display: none; }

  /* Dashboard */
  .dashboard-stats { grid-template-columns: repeat(2, 1fr); }
  .dashboard-stats > div:nth-child(2) { border-right: 0; }
  .dashboard-stats > div:nth-child(-n+2) { border-bottom: 1px solid var(--border); }
  .dashboard-grid { grid-template-columns: 1fr; }

  /* CTA & Footer */
  .final-cta { padding: 48px 28px; }
  .footer__inner { grid-template-columns: 1fr 1fr; padding: 24px 0; }
  .footer p { grid-column: 1 / -1; justify-self: start; }
  .footer__support { justify-self: end; }
  .footer__support img { width: 160px; height: 44px; }
}

/* — Phone — */
@media (max-width: 560px) {
  .container { width: min(calc(100% - 32px), var(--container)); }
  .section { padding: 56px 0; }

  /* Hero - tuned for phone performance */
  .hero { height: 150vh; min-height: 820px; }
  .hero__sticky { min-height: 480px; height: 100dvh; overflow: visible; }
  .hero__inner { justify-content: flex-start; padding-top: calc(var(--nav-height) + 24px); padding-bottom: 24px; overflow-y: visible; }
  .hero__content { max-width: 100%; padding-inline: 0; }
  .hero__bottom-mask { height: 35vh; min-height: 200px; }
  .hero h1 { font-size: clamp(1.7rem, 8vw, 2.6rem); line-height: 1.14; letter-spacing: -.03em; }
  .hero__lead { font-size: .86rem; line-height: 1.65; }
  .hero__kicker span { font-size: 0.68rem !important; padding: 4px 8px !important; letter-spacing: 0.1em !important; }
  .hero__actions { width: 100%; margin-top: 24px; flex-direction: column; }
  .hero__actions .button { width: 100%; text-align: center; }

  /* Comparison */
  .comparison { margin-top: -35vh; padding-top: 48px; border-radius: 20px 20px 0 0; }
  .comparison__heading h2 { font-size: 1.9rem; }
  .comparison__heading > p { margin-top: 16px; font-size: .87rem; }
  .comparison-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; margin-top: 26px; }
  .comparison-tabs button { min-width: 0; padding: 6px 5px; justify-content: center; gap: 5px; font-size: .64rem; white-space: nowrap; }
  .comparison-tabs button span { width: 23px; height: 23px; font-size: .56rem; }
  .comparison-stage { margin-top: 24px; }
  .comparison-showcase-card { max-width: 100%; border-radius: 12px; }
  .comparison-showcase-card__surface { padding: 24px 20px 21px; }
  .comparison-showcase-card__top { grid-template-columns: 40px minmax(0, 1fr); gap: 11px; margin-bottom: 22px; }
  .comparison-showcase-card__number { width: 38px; height: 38px; }
  .comparison-showcase-card__top > p { grid-column: 1 / -1; margin-top: 5px; }
  .comparison-showcase-card h3 { font-size: 1.34rem; }
  .comparison-showcase-card__description { font-size: .8rem; }
  .comparison-showcase-card__list { grid-template-columns: 1fr; margin-top: 21px; }
  .comparison-showcase-card__list li { padding: 11px 0; border-top: 1px solid rgba(100,116,139,.2); border-left: 0; }
  .comparison-showcase-card__list li:first-child { padding-top: 0; border-top: 0; }
  .comparison-showcase-card__list li:last-child { padding-bottom: 0; }
  .comparison-showcase-card__list li > span { margin-bottom: 4px; }
  .comparison-showcase-card--product .comparison-showcase-card__list li { border-color: rgba(255,255,255,.22); }
  .comparison-showcase-card__result { grid-template-columns: 42px minmax(0, 1fr); gap: 9px; min-height: 66px; padding: 14px 17px; }
  .comparison-showcase-card__result p { font-size: .78rem; }

  /* Workflow */
  .workflow { height: auto; }
  .workflow .container { position: static; top: auto; margin-bottom: 0; }
  .workflow__steps { grid-template-columns: repeat(5, 100px); gap: 4px; padding: 12px; }
  .workflow-step { grid-template-columns: 32px 1fr; gap: 8px; min-height: 70px; }
  .workflow-step__number { width: 32px; height: 32px; font-size: .68rem; }
  .workflow-step strong { font-size: .76rem; }
  .workflow-preview__body { padding: 24px 18px; }
  .workflow-preview h3 { font-size: 1.4rem; }
  .preview-ui { padding: 16px; }
  .preview-ui__field { min-height: 44px; padding: 12px 14px; font-size: .82rem; }
  .preview-ui__meta { flex-direction: column; gap: 6px; }

  /* Dashboard */
  .dashboard-tabs { display: grid; grid-template-columns: repeat(3,1fr); width: 100%; gap: 3px; padding: 4px; }
  .dashboard-tabs button { padding: 10px 6px; font-size: .76rem; min-height: 44px; }
  .dashboard-shell { border-radius: 16px; }
  .dashboard-shell__topbar { padding: 14px 16px; align-items: flex-start; gap: 8px; }
  .dashboard-shell__topbar div { align-items: flex-start; flex-direction: column; gap: 3px; }
  .dashboard-shell__topbar p { max-width: 140px; text-align: right; line-height: 1.4; }
  .dashboard-stats > div { padding: 14px; }
  .dashboard-stats strong { font-size: 1.3rem; }
  .dashboard-grid { padding: 10px; gap: 10px; }
  .dashboard-module { padding: 16px; border-radius: 12px; }
  .module-heading { flex-direction: column; align-items: flex-start; gap: 6px; }
  .sentiment-summary strong { font-size: 2rem; }
  .issue-title { font-size: 1.3rem; }

  /* Insight */
  .insight-item__body { padding-left: 4px; }
  .insight-item__body > div { grid-template-columns: 1fr; gap: 6px; }
  .insight-item__body blockquote { margin-left: 0; padding: 14px; }
  .insight-item > button { min-height: 80px; padding: 16px 4px; }
  .insight-item > button strong { font-size: .95rem; }

  /* FAQ & CTA */
  .closing__inner { padding-top: 56px; }
  .faq-item > button { min-height: 64px; padding: 14px 2px; gap: 16px; font-size: .9rem; }
  .faq-item p { font-size: .84rem; }
  .final-cta { margin: 48px auto 40px; padding: 28px 16px; border-radius: 18px; }
  .final-cta h2 { font-size: clamp(1.6rem, 6vw, 2.4rem); }
  .final-cta > p:not(.eyebrow) { font-size: .88rem; }
  .final-cta > div { flex-direction: column; }
  .final-cta .button { width: 100%; }

  /* Footer */
  .footer__inner { grid-template-columns: 1fr; gap: 14px; padding: 20px 0; }
  .footer__support, .footer p { justify-self: start; }
  .footer p { grid-column: auto; }
  .footer__support img { width: 140px; height: 38px; }

  /* Animations - lighter on phones */
  .reveal { transition-duration: .6s; }
}

/* — Very small phone (< 380px) — */
@media (max-width: 380px) {
  .container { width: min(calc(100% - 20px), var(--container)); }
  .hero h1 { font-size: 1.6rem; }
  .hero__lead { font-size: .82rem; }
  .hero__kicker span { font-size: 0.62rem !important; }
  .section-intro h2, .section-heading h2 { font-size: 1.6rem; }
  .comparison__heading h2 { font-size: 1.6rem; }
  .comparison-tabs button { font-size: .58rem; }
  .workflow__steps { grid-template-columns: repeat(5, 90px); }
  .workflow-step__number { width: 28px; height: 28px; font-size: .62rem; }
  .workflow-step strong { font-size: .72rem; }
  .dashboard-tabs button { font-size: .7rem; }
  .final-cta h2 { font-size: 1.4rem; }
}

/* — Touch device optimizations — */
@media (hover: none) and (pointer: coarse) {
  .button:hover { transform: none; }
  .button:active { transform: scale(0.97); }
  .desktop-nav a::after { display: none; }
  .workflow-step, .dashboard-tabs button,
  .faq-item > button, .insight-item > button { min-height: 44px; }
}

/* — Reduced motion — */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .hero { height: 100vh; min-height: 680px; }
  .hero__canvas { display: none; }
  .hero__fallback { opacity: 1 !important; }
  .reveal { opacity: 1; transform: none; }
}
