*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}

:root {
  --bg-main: #f4f7fc;
  --surface: #ffffff;
  --primary: #2152e0;
  --primary-light: #4870e6;
  --primary-soft: #e3ebff;
  --accent-pink: #b84a8c;
  --accent-orange: #e0682b;
  --accent-green: #20b08a;
  --text-heading: #0c1826;
  --text-body: #2b3a55;
  --text-muted: #62748c;
  --border-light: #dde5ed;
  --card-shadow: 0 8px 32px -10px rgba(0, 30, 80, 0.13);
  --hover-shadow: 0 20px 40px -12px rgba(20, 50, 100, 0.18);
  --radius-card: 1.8rem;
  --radius-btn: 2.5rem;
  --transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  --font-display: "DM Sans", system-ui, sans-serif;
  --font-mono: "DM Mono", monospace;
}

body {
  font-family: var(--font-display);
  background: var(--bg-main);
  color: var(--text-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.bg-ambient {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse at 20% 20%,
      rgba(33, 82, 224, 0.07) 0%,
      transparent 45%
    ),
    radial-gradient(
      ellipse at 80% 70%,
      rgba(184, 74, 140, 0.05) 0%,
      transparent 45%
    ),
    radial-gradient(
      ellipse at 90% 10%,
      rgba(32, 176, 138, 0.04) 0%,
      transparent 35%
    ),
    linear-gradient(160deg, #edf3ff 0%, #f9fbff 60%, #fff5f0 100%);
}

h1,
h2,
h3,
h4 {
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: -0.025em;
}
a {
  text-decoration: none;
  color: inherit;
}
img,
video {
  max-width: 100%;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(1.2rem, 5vw, 2rem);
  position: relative;
  z-index: 2;
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 2rem;
  border-radius: var(--radius-btn);
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition);
  cursor: pointer;
  border: none;
  background: transparent;
  gap: 0.5rem;
  white-space: nowrap;
  font-family: var(--font-display);
}
.btn-primary {
  background: var(--primary);
  color: white;
  box-shadow: 0 6px 18px -6px rgba(33, 82, 224, 0.45);
}
.btn-primary:hover {
  background: var(--primary-light);
  transform: translateY(-2px);
}
.btn-secondary {
  background: white;
  color: var(--primary);
  border: 1.5px solid var(--border-light);
}
.btn-secondary:hover {
  border-color: var(--primary-light);
  transform: translateY(-2px);
}

/* ===================== NAVBAR ===================== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(244, 247, 252, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(220, 230, 245, 0.6);
}
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem clamp(1.2rem, 5vw, 2rem);
  max-width: 1400px;
  margin: 0 auto;
  gap: 1rem;
}

/* Logo */
.logo-wrap {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  cursor: pointer;
  user-select: none;
  flex-shrink: 0;
}
.logo-badge {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.88rem;
  color: white;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 4px 14px -4px rgba(33, 82, 224, 0.4);
}
.logo-badge::before,
.logo-badge::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  transition: opacity 0.7s ease;
}
.logo-badge::before {
  background: linear-gradient(135deg, #2152e0, #4870e6);
  opacity: 1;
}
.logo-badge::after {
  background: linear-gradient(135deg, #b84a8c, #d43f6b);
  opacity: 0;
}
.logo-badge.c1::before {
  background: linear-gradient(135deg, #2152e0, #4870e6);
  opacity: 1;
}
.logo-badge.c1::after {
  background: linear-gradient(135deg, #b84a8c, #d43f6b);
  opacity: 0;
}
.logo-badge.c2::before {
  background: linear-gradient(135deg, #b84a8c, #d43f6b);
  opacity: 1;
}
.logo-badge.c2::after {
  background: linear-gradient(135deg, #e0682b, #f5883c);
  opacity: 0;
}
.logo-badge.c3::before {
  background: linear-gradient(135deg, #e0682b, #f5883c);
  opacity: 1;
}
.logo-badge.c3::after {
  background: linear-gradient(135deg, #20b08a, #2bd4a0);
  opacity: 0;
}
.logo-badge.c4::before {
  background: linear-gradient(135deg, #20b08a, #2bd4a0);
  opacity: 1;
}
.logo-badge.c4::after {
  background: linear-gradient(135deg, #2152e0, #4870e6);
  opacity: 0;
}
.logo-badge.flip-anim {
  animation: badgeFlip 0.55s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes badgeFlip {
  0% {
    transform: rotateY(0deg);
  }
  50% {
    transform: rotateY(90deg);
  }
  100% {
    transform: rotateY(0deg);
  }
}
.logo-badge span {
  position: relative;
  z-index: 2;
}
.logo-sep {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--border-light);
  flex-shrink: 0;
}
.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.logo-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: -0.025em;
}
.logo-tag {
  font-size: 0.6rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

/* Desktop nav links */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.nav-links {
  display: flex;
  list-style: none;
  gap: 1.8rem;
}
.nav-links a {
  font-weight: 500;
  color: var(--text-heading);
  transition: var(--transition);
  padding: 0.3rem 0;
  border-bottom: 2px solid transparent;
  position: relative;
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--primary);
  border-bottom-color: var(--primary-light);
}

/* ---- Dropdown mega menu ---- */
.has-dropdown {
  position: relative;
}

/* chevron rotates on hover */
.has-dropdown > a .dd-chevron {
  display: inline-block;
  font-size: 0.55rem;
  margin-left: 4px;
  vertical-align: middle;
  opacity: 0.5;
  transition: transform 0.22s ease;
}
.has-dropdown:hover > a .dd-chevron {
  transform: rotate(180deg);
  opacity: 0.8;
}

.nav-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(8px) scale(0.97);
  background: white;
  border-radius: 1.2rem;
  padding: 0.5rem;
  min-width: 240px;
  box-shadow:
    0 4px 6px -1px rgba(0, 0, 0, 0.05),
    0 20px 50px -10px rgba(10, 30, 80, 0.16);
  border: 1px solid rgba(220, 232, 248, 0.8);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.18s ease,
    transform 0.22s cubic-bezier(0.34, 1.2, 0.64, 1);
  z-index: 200;
}
.has-dropdown:hover .nav-dropdown,
.has-dropdown:focus-within .nav-dropdown {
  opacity: 1;
  pointer-events: all;
  transform: translateX(-50%) translateY(0) scale(1);
}
/* caret tip */
.nav-dropdown::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 10px;
  height: 10px;
  background: white;
  border-left: 1px solid rgba(220, 232, 248, 0.8);
  border-top: 1px solid rgba(220, 232, 248, 0.8);
  border-radius: 2px;
}
/* dropdown label (section header inside dropdown) */
.dd-label {
  font-size: 0.62rem;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 0.5rem 0.9rem 0.25rem;
}
.dd-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.55rem 0.8rem;
  border-radius: 0.8rem;
  color: var(--text-body);
  font-size: 0.875rem;
  font-weight: 500;
  transition:
    background 0.15s,
    color 0.15s,
    transform 0.15s;
  cursor: pointer;
  text-decoration: none;
}
.dd-item:hover {
  background: var(--primary-soft);
  color: var(--primary);
  transform: translateX(3px);
}
.dd-item:hover .dd-icon {
  background: var(--primary) !important;
  color: white !important;
}
.dd-icon {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  flex-shrink: 0;
  transition:
    background 0.15s,
    color 0.15s;
}
.dd-item .dd-text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}
.dd-item .dd-text b {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-heading);
}
.dd-item .dd-text small {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 1px;
}
.dd-item:hover .dd-text b {
  color: var(--primary);
}
.dd-divider {
  height: 1px;
  background: var(--border-light);
  margin: 0.3rem 0.6rem;
}
.nav-auth {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}
.nav-login {
  padding: 0.45rem 1.2rem;
  color: var(--text-heading);
  border: 1.5px solid var(--border-light);
  border-radius: 2rem;
  font-weight: 600;
  font-size: 0.88rem;
  transition: var(--transition);
  background: white;
}
.nav-login:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-soft);
}
.nav-signup {
  padding: 0.45rem 1.3rem;
  background: var(--primary);
  color: white;
  border-radius: 2rem;
  font-weight: 600;
  font-size: 0.88rem;
  transition: var(--transition);
  box-shadow: 0 4px 12px -4px rgba(33, 82, 224, 0.4);
}
.nav-signup:hover {
  background: var(--primary-light);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px -6px rgba(33, 82, 224, 0.5);
}
.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--primary);
  cursor: pointer;
  padding: 0.3rem;
  flex-shrink: 0;
}

/* ── MOBILE MENU ── */
@media (max-width: 820px) {

  .nav-toggle { display: block; }

  /* Slide-down panel */
  .nav-menu {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    position: fixed;
    top: 62px;
    left: 0;
    right: 0;
    /* hard max-height + scroll so it never covers whole page */
    max-height: calc(100vh - 62px);
    overflow-y: auto;
    scrollbar-width: none;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 0.5rem 1.2rem 1.4rem;
    box-shadow: 0 16px 40px -8px rgba(0,0,0,0.14);
    border-radius: 0 0 1.4rem 1.4rem;
    border-top: 1px solid rgba(220,232,248,0.6);
    transform: translateY(-110%);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1), opacity 0.25s ease;
    pointer-events: none;
    z-index: 99;
  }
  .nav-menu::-webkit-scrollbar { display: none; }
  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  /* Nav link rows */
  .nav-links {
    flex-direction: column;
    gap: 0;
    list-style: none;
  }
  .nav-links li {
    border-bottom: 1px solid rgba(220,232,248,0.7);
  }
  .nav-links li:last-child { border-bottom: none; }

  /* Top-level links — block layout for simple links */
  .nav-links > li > a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.82rem 0.2rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-heading);
    border-bottom: none;
  }
  .nav-links > li > a:hover { color: var(--primary); }

  /* Chevron smooth rotation */
  .dd-chevron {
    font-size: 0.65rem !important;
    margin-left: 4px !important;
    opacity: 0.5;
    transition: transform 0.22s ease, opacity 0.22s;
    display: inline-block;
    flex-shrink: 0;
  }
  .has-dropdown.mob-open > a .dd-chevron {
    transform: rotate(180deg) !important;
    opacity: 0.85;
  }

  /* ── DROPDOWN ACCORDION ── */
  .has-dropdown { position: static; }

  .nav-dropdown {
    position: static !important;
    transform: none !important;
    opacity: 1;
    pointer-events: all;
    box-shadow: none;
    border: none;
    border-radius: 0.9rem;
    background: #f4f8fe;
    min-width: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0.4,0,0.2,1),
                padding 0.22s ease,
                margin 0.22s ease;
    padding: 0 0.4rem;
    margin: 0;
  }
  .nav-dropdown::before { display: none; }

  .has-dropdown.mob-open .nav-dropdown {
    max-height: 360px;
    padding: 0.35rem 0.4rem 0.5rem;
    margin: 0.1rem 0 0.55rem;
  }

  /* ── DROPDOWN ITEMS — force row layout ── */
  .dd-item {
    display: flex !important;       /* override any block from nav-links a */
    flex-direction: row !important;
    align-items: center !important;
    gap: 0.6rem;
    padding: 0.52rem 0.6rem;
    border-radius: 0.7rem;
    font-size: 0.86rem;
    color: var(--text-body);
    font-weight: 500;
    width: 100%;
    text-decoration: none;
  }
  .dd-item:hover {
    background: var(--primary-soft);
    color: var(--primary);
    transform: none;
  }
  .dd-icon {
    width: 28px;
    height: 28px;
    border-radius: 7px;
    font-size: 0.76rem;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .dd-item .dd-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
  }
  .dd-item .dd-text b {
    font-size: 0.86rem;
    font-weight: 600;
  }
  /* Hide descriptions on mobile — too cluttered */
  .dd-item .dd-text small { display: none; }

  .dd-label {
    font-size: 0.6rem;
    padding: 0.4rem 0.65rem 0.18rem;
    letter-spacing: 0.07em;
    color: var(--text-muted);
  }
  .dd-divider { margin: 0.2rem 0.5rem; }

  /* Auth buttons */
  .nav-auth {
    flex-direction: column;
    width: 100%;
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(220,232,248,0.7);
    gap: 0.5rem;
  }
  .nav-login,
  .nav-signup {
    width: 100%;
    text-align: center;
    padding: 0.75rem;
    border-radius: 0.9rem;
    font-size: 0.95rem;
    display: flex;
    justify-content: center;
  }
}

/* ===================== HERO ===================== */
.hero {
  padding: clamp(2.5rem, 6vw, 4.5rem) 0 clamp(3rem, 7vw, 5rem);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.8rem, 4vw, 3.5rem);
  align-items: center;
}
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.6rem);
  line-height: 1.12;
  margin-bottom: 1.2rem;
}
.hero-subhead {
  font-size: clamp(0.95rem, 2.5vw, 1.2rem);
  color: var(--text-muted);
  margin-bottom: 1.8rem;
}
.badge-row {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  margin-bottom: 1.6rem;
  flex-wrap: wrap;
}
.badge {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(4px);
  padding: 0.28rem 0.9rem 0.28rem 0.7rem;
  border-radius: 2rem;
  font-size: 0.82rem;
  font-weight: 500;
  border: 1px solid rgba(200, 215, 235, 0.6);
  color: var(--text-muted);
}
.hero-buttons {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.dashboard-mock {
  background: white;
  border-radius: 2rem;
  padding: clamp(1.1rem, 3vw, 1.8rem);
  box-shadow: var(--card-shadow);
  border: 1px solid rgba(220, 230, 248, 0.6);
  display: flex;
  flex-direction: column;
  gap: 0.95rem;
}
.mock-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.timer-badge {
  background: var(--primary-soft);
  padding: 0.4rem 1rem;
  border-radius: 3rem;
  font-weight: 700;
  color: var(--primary);
  font-size: clamp(0.95rem, 2.5vw, 1.25rem);
  font-family: var(--font-mono);
}
.score-ring {
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  background: conic-gradient(var(--primary) 0deg 240deg, #eef2f8 240deg);
  flex-shrink: 0;
}
.metrics-row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.metric-block {
  background: #f6f9fd;
  flex: 1 1 110px;
  border-radius: 1rem;
  padding: 0.7rem 0.85rem;
  min-width: 0;
}
.metric-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  display: block;
  margin-bottom: 0.1rem;
}
.metric-value {
  font-size: clamp(1.3rem, 3vw, 1.75rem);
  font-weight: 700;
  color: var(--text-heading);
}
.mini-heat {
  display: flex;
  gap: 4px;
  margin: 0.4rem 0;
  flex-wrap: wrap;
}
.heat-dot {
  width: 16px;
  height: 16px;
  background: #e2eaf3;
  border-radius: 4px;
}
.heat-dot.filled {
  background: var(--primary-light);
}
.heat-dot.high {
  background: var(--primary);
}
.session-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.pill {
  background: #f0f5fe;
  border-radius: 2rem;
  padding: 0.22rem 0.8rem;
  font-size: 0.82rem;
}

@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .dashboard-mock {
    max-width: 100%;
  }
}
@media (max-width: 480px) {
  .hero-buttons {
    flex-direction: column;
  }
  .hero-buttons .btn {
    width: 100%;
    justify-content: center;
  }
}

/* ===================== SECTION UTILS ===================== */
.section {
  padding: clamp(2rem, 5vw, 4rem) 0;
}
.section-title {
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  text-align: center;
  margin-bottom: 0.7rem;
}
.section-sub {
  text-align: center;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 2.5rem;
  font-size: clamp(0.9rem, 2vw, 1rem);
}

/* ===================== FEATURES ===================== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 1.4rem;
}
.feature-card {
  background: var(--surface);
  border-radius: var(--radius-card);
  padding: clamp(1.3rem, 3vw, 2rem);
  box-shadow: var(--card-shadow);
  transition: var(--transition);
  border: 1px solid rgba(220, 232, 248, 0.5);
}
.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--hover-shadow);
}
.icon-circle {
  background: var(--primary-soft);
  width: 3rem;
  height: 3rem;
  border-radius: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  color: var(--primary);
  margin-bottom: 1.1rem;
}
.feature-card h3 {
  font-size: clamp(1.05rem, 2.5vw, 1.25rem);
  margin-bottom: 0.4rem;
}
.feature-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ===================== STATS ===================== */
.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
  gap: 1.1rem;
  margin-bottom: 1.8rem;
}
.stat-tile {
  background: white;
  border-radius: 1.5rem;
  padding: clamp(1rem, 2.5vw, 1.5rem);
  box-shadow: var(--card-shadow);
}
.stat-tile .big {
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  font-weight: 700;
  color: var(--text-heading);
  font-family: var(--font-mono);
  line-height: 1.2;
}
.stat-trend {
  font-size: 0.8rem;
  color: var(--accent-green);
  font-weight: 600;
}

/* ===================== ANALYTICS PANEL ===================== */
.analytics-panel {
  background: white;
  border-radius: 2rem;
  padding: clamp(1.1rem, 3vw, 2rem);
  margin-bottom: 1.5rem;
  box-shadow: var(--card-shadow);
  border: 1px solid rgba(220, 232, 248, 0.5);
}
.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 1.5rem;
}
.panel-tabs {
  display: flex;
  gap: 0.4rem;
  flex-shrink: 0;
}
.tab-btn {
  padding: 0.35rem 0.85rem;
  border-radius: 2rem;
  font-size: 0.8rem;
  font-weight: 600;
  border: 1.5px solid var(--border-light);
  background: transparent;
  cursor: pointer;
  transition: var(--transition);
  color: var(--text-muted);
  font-family: var(--font-display);
}
.tab-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}
.tab-btn:hover:not(.active) {
  border-color: var(--primary-light);
  color: var(--primary);
}

/* 3-col analytics grid → responsive */
.analytics-grid {
  display: grid;
  grid-template-columns: 1fr 170px 1fr;
  gap: 1.5rem;
  align-items: start;
}
@media (max-width: 900px) {
  .analytics-grid {
    grid-template-columns: 1fr 1fr;
  }
  .heatmap-col {
    grid-column: 1 / -1;
  }
}
@media (max-width: 540px) {
  .analytics-grid {
    grid-template-columns: 1fr;
  }
  .heatmap-col {
    grid-column: auto;
  }
}

/* Bar chart */
.chart-col {
  min-width: 0;
}
.chart-title {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
.bar-chart {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 155px;
}
.bar-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  min-width: 0;
}
.bar {
  width: 100%;
  border-radius: 5px 5px 2px 2px;
  background: linear-gradient(180deg, #6490f0, #2152e0);
  animation: barGrow 0.9s cubic-bezier(0.34, 1.2, 0.64, 1) both;
  transform-origin: bottom;
  cursor: pointer;
  transition: filter 0.2s;
  position: relative;
}
.bar:hover {
  filter: brightness(1.12);
}
.bar::after {
  content: attr(data-val);
  position: absolute;
  top: -22px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--text-heading);
  color: white;
  font-size: 0.65rem;
  font-family: var(--font-mono);
  font-weight: 500;
  padding: 2px 5px;
  border-radius: 4px;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.15s;
  pointer-events: none;
}
.bar:hover::after {
  opacity: 1;
}
@keyframes barGrow {
  0% {
    transform: scaleY(0);
    opacity: 0;
  }
  100% {
    transform: scaleY(1);
    opacity: 1;
  }
}
.bar-lbl {
  font-size: 0.68rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* Donut */
.donut-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
}
.donut-wrap {
  position: relative;
  width: 110px;
  height: 110px;
  flex-shrink: 0;
}
.donut-wrap svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.donut-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.donut-center .pct {
  font-size: 1.3rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--text-heading);
}
.donut-center .lbl {
  font-size: 0.58rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  font-family: var(--font-mono);
}
.donut-legend {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.76rem;
}
.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

@media (max-width: 540px) {
  .donut-col {
    flex-direction: row;
    align-items: flex-start;
    width: 100%;
  }
  .donut-legend {
    margin-left: 1.2rem;
    justify-content: center;
  }
}

/* Heatmap */
.heatmap-col {
  min-width: 0;
}
.heat-days-row {
  display: flex;
  gap: 0;
  margin-bottom: 3px;
}
.heat-day-lbl {
  flex: 1;
  text-align: center;
  font-size: 0.62rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}
.heat-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.h-sq {
  aspect-ratio: 1/1;
  border-radius: 4px;
  background: #e8eef7;
  transition:
    transform 0.18s,
    background 0.18s;
  cursor: pointer;
  position: relative;
}
.h-sq:hover {
  transform: scale(1.25);
  z-index: 2;
}
.h-sq.l1 {
  background: #c5d6f5;
}
.h-sq.l2 {
  background: #85a9ee;
}
.h-sq.l3 {
  background: #4870e6;
}
.h-sq.l4 {
  background: #2152e0;
}
.heat-legend-row {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 0.5rem;
  font-size: 0.68rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* ===================== CALENDAR + INSIGHTS ===================== */
.cal-insights-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.3rem;
  margin-top: 1.8rem;
  padding-top: 1.6rem;
  border-top: 1px solid var(--border-light);
  align-items: start;
}
@media (max-width: 680px) {
  .cal-insights-row {
    grid-template-columns: 1fr;
  }
}

.cal-widget {
  background: var(--bg-main);
  border-radius: 1.5rem;
  padding: clamp(0.9rem, 2vw, 1.3rem);
  border: 1.5px solid var(--border-light);
  width: 250px;
}
@media (max-width: 680px) {
  .cal-widget {
    width: 100%;
    max-width: 340px;
  }
}

.cal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.8rem;
}
.cal-header h4 {
  font-size: 0.87rem;
}
.cal-nav {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 0.82rem;
  padding: 0.22rem 0.4rem;
  border-radius: 6px;
  transition: var(--transition);
}
.cal-nav:hover {
  background: var(--primary-soft);
  color: var(--primary);
}
.cal-days-header {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 1px;
  margin-bottom: 2px;
}
.cal-day-name {
  text-align: center;
  font-size: 0.6rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  padding: 0.18rem 0;
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.cal-cell {
  aspect-ratio: 1/1;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}
.cal-cell:hover {
  background: var(--primary-soft);
  color: var(--primary);
}
.cal-cell.has-session::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--primary);
}
.cal-cell.today {
  background: var(--primary);
  color: white;
  font-weight: 700;
}
.cal-cell.today::after {
  background: rgba(255, 255, 255, 0.7);
}
.cal-cell.other-month {
  opacity: 0.25;
}
.cal-cell.high-focus::after {
  background: var(--accent-green);
}
.cal-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 0.8rem;
  padding-top: 0.6rem;
  border-top: 1px solid var(--border-light);
}
.cal-stat {
  font-size: 0.68rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
}
.cal-stat span {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
}

.insights-col {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  min-width: 0;
}
.insight-card {
  background: #f6f9fd;
  border-radius: 1.2rem;
  padding: clamp(0.85rem, 2vw, 1.1rem) clamp(0.9rem, 2vw, 1.3rem);
  border: 1.5px solid var(--border-light);
}
.insight-card.highlight {
  background: linear-gradient(135deg, #eef3ff, #f5e8ff);
  border-color: rgba(100, 120, 255, 0.15);
}
.insight-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.45rem;
}
.insight-head i {
  font-size: 1rem;
  flex-shrink: 0;
}
.insight-head strong {
  font-size: 0.88rem;
  color: var(--text-heading);
}
.insight-card p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ===================== STEPS ===================== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 1.4rem;
  margin: 2.5rem 0;
}
.step-card {
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(4px);
  padding: clamp(1.3rem, 3vw, 2rem);
  border-radius: 2rem;
  border: 1px solid rgba(220, 232, 248, 0.7);
  transition: var(--transition);
}
.step-card:hover {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.85);
  box-shadow: var(--hover-shadow);
}
.step-num {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--primary-soft);
  font-family: var(--font-mono);
  margin-bottom: 0.55rem;
}
.step-card h3 {
  font-size: clamp(1rem, 2.5vw, 1.12rem);
  margin-bottom: 0.38rem;
}
.step-card p {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* ===================== TRUST ===================== */
.trust-row {
  display: flex;
  justify-content: center;
  gap: clamp(1rem, 3vw, 2rem);
  flex-wrap: wrap;
  background: white;
  padding: clamp(1.1rem, 2.5vw, 1.7rem) clamp(1.2rem, 3vw, 2rem);
  border-radius: 3rem;
  margin: 2.5rem 0;
  box-shadow: var(--card-shadow);
}
.trust-row span {
  font-weight: 500;
  color: var(--text-body);
  font-size: 0.88rem;
}
@media (max-width: 500px) {
  .trust-row {
    flex-direction: column;
    align-items: center;
    gap: 0.9rem;
    border-radius: 1.8rem;
  }
}

/* ===================== CTA ===================== */
.cta-block {
  background: linear-gradient(145deg, white, #eef3ff);
  border-radius: clamp(1.5rem, 4vw, 3rem);
  padding: clamp(2.5rem, 6vw, 5rem) clamp(1.2rem, 4vw, 2rem);
  text-align: center;
  margin: 3rem 0;
  border: 1px solid rgba(200, 220, 255, 0.6);
  box-shadow: var(--card-shadow);
}
.cta-block h2 {
  font-size: clamp(1.7rem, 5vw, 2.8rem);
  margin-bottom: 1.6rem;
}
.cta-btn {
  font-size: clamp(0.95rem, 2.5vw, 1.25rem);
  padding: clamp(0.7rem, 2vw, 1rem) clamp(1.8rem, 4vw, 3rem);
}
@media (max-width: 420px) {
  .cta-btn {
    width: 100%;
  }
}

/* ===================== FOOTER ===================== */
.footer {
  padding: clamp(2.5rem, 5vw, 3.5rem) 0 1.5rem;
  border-top: 1px solid var(--border-light);
}
.footer-grid {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
}
.footer-brand {
  font-size: 1.6rem;
  font-weight: 800;
  background: linear-gradient(130deg, #2152e0, #b84a8c);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}
.footer-desc {
  max-width: 220px;
  margin-top: 0.6rem;
  color: var(--text-muted);
  font-size: 0.88rem;
}
.footer-features {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-top: 1.2rem;
}
.footer-feat {
  background: white;
  border: 1.5px solid var(--border-light);
  border-radius: 1rem;
  padding: 0.58rem 0.95rem;
  font-size: 0.8rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: default;
  position: relative;
  overflow: hidden;
}
.footer-feat::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity 0.25s;
}
.footer-feat:hover {
  transform: translateY(-3px) scale(1.03);
  border-color: transparent;
  color: white;
}
.footer-feat:hover::before {
  opacity: 1;
}
.footer-feat:nth-child(1)::before {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
}
.footer-feat:nth-child(2)::before {
  background: linear-gradient(135deg, var(--accent-pink), #d43f6b);
}
.footer-feat:nth-child(3)::before {
  background: linear-gradient(135deg, var(--accent-orange), #f5883c);
}
.footer-feat:nth-child(4)::before {
  background: linear-gradient(135deg, var(--accent-green), #2bd4a0);
}
.footer-feat i,
.footer-feat span {
  position: relative;
  z-index: 1;
}
.footer-feat:hover i {
  color: white !important;
}

.footer-links {
  display: flex;
  gap: clamp(1.4rem, 3vw, 3rem);
  flex-wrap: wrap;
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.footer-col-title {
  font-size: 0.68rem;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}
.footer-link {
  color: var(--text-body);
  font-weight: 500;
  font-size: 0.9rem;
  position: relative;
  width: fit-content;
  transition: color 0.2s;
}
.footer-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent-pink));
  transition: width 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 2px;
}
.footer-link:hover {
  color: var(--primary);
}
.footer-link:hover::after {
  width: 100%;
}
.footer-copy {
  text-align: center;
  margin-top: 3rem;
  color: var(--text-muted);
  font-size: 0.83rem;
}

@media (max-width: 600px) {
  .footer-grid {
    flex-direction: column;
    gap: 1.8rem;
  }
  .footer-desc {
    max-width: 100%;
  }
  .footer-links {
    gap: 1.4rem;
  }
}

/* Mobile dropdown accordion */
@media (max-width: 820px) {
  .has-dropdown {
    position: static;
  }
  .nav-dropdown {
    position: static;
    transform: none !important;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    box-shadow: none;
    border: none;
    padding: 0 0 0 1rem;
    border-radius: 0;
    background: transparent;
    transition:
      opacity 0.25s ease,
      max-height 0.3s ease;
    min-width: 0;
  }
  .nav-dropdown::before {
    display: none;
  }
  .has-dropdown.mob-open .nav-dropdown {
    opacity: 1;
    max-height: 400px;
    padding: 0.4rem 0 0.4rem 1rem;
  }
  .dd-item {
    padding: 0.45rem 0.6rem;
    font-size: 0.85rem;
  }
  .dd-item .dd-text small {
    display: none;
  }
  .dd-divider {
    display: none;
  }
}

/* ── MOBILE EDGE PADDING — hard override ── */
@media (max-width: 600px) {
  .container,
  .hero.container,
  .section.container {
    padding-left: 1.2rem !important;
    padding-right: 1.2rem !important;
  }
  .nav-container {
    padding-left: 1.1rem !important;
    padding-right: 1.1rem !important;
  }
}
@media (max-width: 380px) {
  .container,
  .hero.container,
  .section.container {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
}