/* ══════════════════════════════════════════════════════════════
   FinClaw MOBILE ADAPTATION
   ══════════════════════════════════════════════════════════════ */

/* ── HAMBURGER BUTTON ── */
.hm-btn {
  display: none;
  position: fixed;
  top: 16px; left: 16px;
  z-index: 200;
  width: 44px; height: 44px;
  background: rgba(37,99,235,0.92);
  backdrop-filter: blur(8px);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 12px rgba(37,99,235,0.3);
  transition: transform 0.2s, box-shadow 0.2s;
}
.hm-btn:active { transform: scale(0.92); }
.hm-btn svg { width: 22px; height: 22px; color: #fff; }
.hm-btn svg path { transition: transform 0.3s ease, opacity 0.3s ease; }
.hm-btn.is-open .line-1 { transform: translateY(5px) rotate(45deg); }
.hm-btn.is-open .line-2 { opacity: 0; }
.hm-btn.is-open .line-3 { transform: translateY(-5px) rotate(-45deg); }
.hm-btn.is-open { background: rgba(37,99,235,1); box-shadow: 0 4px 20px rgba(37,99,235,0.4); }

/* ── MOBILE OVERLAY ── */
.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 99;
}

/* ── MOBILE: ≤768px ── */
@media (max-width: 768px) {
  /* Show hamburger */
  .hm-btn { display: flex; }

  /* Hide nav sidebar — override inline styles */
  nav {
    position: fixed !important;
    top: 0 !important;
    left: -260px !important;
    bottom: 0 !important;
    width: 240px !important;
    z-index: 150 !important;
    transition: left 0.3s ease !important;
    box-shadow: none !important;
    border-right: none !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
  }

  /* Nav open state */
  nav.nav-open {
    left: 0 !important;
    box-shadow: 4px 0 24px rgba(0,0,0,0.15) !important;
  }

  /* Show overlay when nav open */
  .nav-overlay.active { display: block; }

  /* Content area adjustments */
  body { margin-left: 0 !important; width: 100% !important; padding: 70px 16px 24px !important; }

  /* Navigation links in sidebar */
  nav a {
    font-size: 14px !important;
    padding: 10px 8px !important;
    display: block !important;
    text-align: left !important;
  }

  /* Typography */
  h1 { font-size: clamp(22px, 5vw, 28px) !important; }
  h2 { font-size: clamp(18px, 4vw, 22px) !important; }

  /* Cards */
  .section { padding: 16px !important; margin-bottom: 16px !important; }

  /* Images */
  img { max-width: 100% !important; height: auto !important; }

  /* Input fields */
  input[type="text"], input[type="email"], input[type="tel"], input[type="password"], textarea {
    font-size: 16px !important; /* Prevent iOS zoom */
  }
}

/* ── TABLET: ≤1024px ── */
@media (max-width: 1024px) and (min-width: 769px) {
  nav { width: 80px !important; }
  nav a { font-size: 11px !important; padding: 6px 4px !important; text-align: center; }
}
