/* EQ-T Responsive & Alignment Polish */

:root {
  --tap-target: 44px;
}

html, body {
  overflow-x: clip !important;
  max-width: 100vw;
}

/* Touch target accessibility */
button,
a,
input,
select,
.side-link,
.dash-tabs span,
.copilot-chip {
  -webkit-tap-highlight-color: transparent;
}

/* --- Breakpoint: 1280px (Laptop) --- */
@media (max-width: 1280px) {
  .hero {
    gap: 36px;
  }

  .main-nav {
    gap: 24px;
    margin-right: 20px;
  }

  .ai-copilot {
    right: 0;
    width: 300px;
  }
}

/* --- Breakpoint: 1024px (Tablet Landscape) --- */
@media (max-width: 1024px) {
  .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 40px;
    padding-top: 48px;
    padding-bottom: 60px;
  }

  .hero-copy {
    max-width: 680px;
  }

  .hero-visual {
    max-width: 780px;
  }

  .dashboard-body {
    grid-template-columns: 120px minmax(0, 1fr);
  }

  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .research-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .manifesto {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 72px 0;
  }

  .waitlist-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .full-form {
    max-width: 600px;
  }

  .footer-main {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }

  .footer-parent-brand {
    align-items: flex-start;
    text-align: left;
    grid-column: 1 / -1;
  }
}

/* --- Breakpoint: 768px (Tablet Portrait & Mobile Nav) --- */
@media (max-width: 768px) {
  :root {
    --nav-height: 64px;
  }

  .section-shell {
    width: calc(100% - 36px);
  }

  .menu-toggle {
    display: flex;
    order: 3;
  }

  .nav-cta {
    order: 2;
    margin-left: auto;
    margin-right: 12px;
    height: 38px;
    padding: 0 14px;
    font-size: 12px;
  }

  /* Mobile Slide-down Navigation */
  .main-nav {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--line);
    padding: 20px 24px;
    margin: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    box-shadow: 0 16px 24px -6px rgba(15, 23, 42, 0.08);
    z-index: 49;
  }

  .main-nav.open {
    display: flex;
  }

  .main-nav a {
    font-size: 15px;
    font-weight: 600;
    width: 100%;
    padding: 6px 0;
  }

  /* Hamburger state when open */
  .menu-toggle[aria-expanded="true"] span:first-child {
    transform: translateY(3.25px) rotate(45deg);
  }

  .menu-toggle[aria-expanded="true"] span:last-child {
    transform: translateY(-3.25px) rotate(-45deg);
  }

  /* Hero Mobile Adjustment */
  .hero {
    gap: 32px;
    padding-top: 36px;
    padding-bottom: 48px;
  }

  .hero h1 {
    font-size: clamp(34px, 7.5vw, 44px);
    margin-bottom: 16px;
  }

  .hero-description {
    font-size: 16px;
    margin-bottom: 24px;
  }

  /* Stage & Docked Copilot on Tablet/Mobile */
  .dashboard-stage {
    display: flex;
    flex-direction: column;
    gap: 16px;
  }

  .ai-copilot {
    position: static;
    width: 100%;
    max-width: 100%;
    box-shadow: var(--shadow-sm);
  }

  .ai-copilot.is-minimized {
    width: 100%;
  }

  .market-ticker {
    margin-top: 0;
  }

  .feature-card {
    padding: 22px;
  }

  .research-section,
  .waitlist-section {
    padding: 64px 0;
  }

  .full-form {
    padding: 24px 20px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

/* --- Breakpoint: 480px / 430px (Standard Mobile) --- */
@media (max-width: 480px) {
  .section-shell {
    width: calc(100% - 28px);
  }

  .brand-logo-img {
    height: 24px;
  }

  .nav-cta {
    padding: 0 10px;
    font-size: 11px;
    height: 34px;
    gap: 4px;
  }

  .hero-copy {
    width: 100%;
  }

  .hero h1 {
    font-size: 32px;
    letter-spacing: -0.03em;
  }

  .quick-form {
    flex-direction: column;
    gap: 10px;
    max-width: 100%;
  }

  .email-field,
  .quick-form .button {
    width: 100%;
    height: 48px;
  }

  /* Compact Dashboard on Mobile */
  .dashboard-topbar {
    height: 48px;
    padding: 0 12px;
    gap: 10px;
  }

  .dash-logo {
    height: 18px;
  }

  .search-pill {
    height: 28px;
    font-size: 11px;
    padding: 0 8px;
  }

  .search-pill kbd {
    display: none;
  }

  .avatar {
    width: 24px;
    height: 24px;
  }

  .dashboard-body {
    grid-template-columns: 1fr;
  }

  .dashboard-sidebar {
    display: none;
  }

  .dashboard-main {
    padding: 12px;
  }

  .company-head {
    align-items: center;
  }

  .company-name {
    font-size: 16px;
  }

  .company-price strong {
    font-size: 15px;
  }

  .dash-tabs {
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 2px;
    gap: 12px;
    margin-top: 10px;
  }

  .dash-tabs::-webkit-scrollbar {
    display: none;
  }

  .dash-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .feature-card {
    padding: 20px 16px;
  }

  .feature-icon {
    margin-bottom: 14px;
  }

  .manifesto-logo-img {
    height: 38px;
  }

  .manifesto-copy h2 {
    font-size: 26px;
  }

  .waitlist-copy h2 {
    font-size: 28px;
  }

  .footer-main {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-links-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* --- Breakpoint: 360px (Compact Mobile) --- */
@media (max-width: 360px) {
  .section-shell {
    width: calc(100% - 20px);
  }

  .hero h1 {
    font-size: 28px;
  }

  .hero-description {
    font-size: 14px;
  }

  .full-form {
    padding: 20px 14px;
  }

  .ticker-demo {
    display: none;
  }
}

/* --- Accessibility: Motion Reduction --- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .ticker-items {
    animation: none !important;
    transform: none !important;
    overflow-x: auto;
  }
}
