/**
 * HabitFlow - Base Typography & Structural Layout
 * Strict mathematical scale, clean mobile-first spacing and layouts.
 */

/* Container Setup */
.container {
  width: 100%;
  max-width: 1240px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

@media (min-width: 640px) {
  .container {
    padding-left: var(--space-6);
    padding-right: var(--space-6);
  }
}

@media (min-width: 1024px) {
  .container {
    padding-left: var(--space-8);
    padding-right: var(--space-8);
  }
}

/* Typography Hierarchy */
.hero-heading {
  font-size: clamp(2rem, 5.5vw, 3.75rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: var(--space-4);
}

.hero-heading .highlight {
  color: var(--primary);
  display: inline-block;
  position: relative;
}

.section-heading {
  font-size: clamp(1.65rem, 3.5vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.025em;
  color: var(--text);
  margin-bottom: var(--space-3);
}

.subheading {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  font-weight: 400;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 68ch;
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-12);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.section-header .subheading {
  margin-left: auto;
  margin-right: auto;
}

.body-text {
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text-secondary);
}

.small-text {
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--text-muted);
}

.label-text {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--primary);
}

.dashboard-number {
  font-family: var(--font-sans);
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--text);
}

/* Section Spacing */
.section {
  padding-top: var(--space-16);
  padding-bottom: var(--space-16);
  position: relative;
}

@media (min-width: 768px) {
  .section {
    padding-top: var(--space-20);
    padding-bottom: var(--space-20);
  }
}

.section-alt {
  background-color: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

/* Visually Hidden */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
