/**
 * Typography - xTools.com
 *
 * Font definitions and text styles matched to Figma.
 * Fonts: Cairo (headings), Lato (body)
 */

/* ========================================
   FONT FACE DEFINITIONS
   ======================================== */

/* Cairo - Primary (Headings) - Variable Font */
@font-face {
  font-family: Cairo;
  src: url('/fonts/cairo.woff2') format('woff2');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

/* Lato - Secondary (Body) */
@font-face {
  font-family: Lato;
  src: url('/fonts/lato-regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: Lato;
  src: url('/fonts/lato-semibold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: Lato;
  src: url('/fonts/lato-bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* xTools brand wordmark font — used for product names (xTags, xImages, …) */
@font-face {
  font-family: xTools;
  src: url('/fonts/xtools-brand.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* Brand wordmark (xCloud / xTools) — rendered in the xTools font wherever it
   appears in copy. Applied automatically by the brandWordmark transform. */
.wordmark {
  font-family: var(--font-brand);
}

/* ========================================
   HEADING STYLES
   ======================================== */

h1, .h1 {
  font-family: var(--font-primary);
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-snug);
  letter-spacing: -0.01em;
  color: var(--color-text);
}

/* Hero title - Figma: 80px Cairo Semibold */
.hero-title {
  font-family: var(--font-primary);
  font-size: var(--font-size-hero);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-tight);
  letter-spacing: -0.01em;
  color: var(--color-text);
}

@media (width <= 1023px) {
  .hero-title {
    font-size: var(--font-size-5xl);
  }
}

@media (width <= 767px) {
  .hero-title {
    font-size: var(--font-size-4xl);
  }
}

h2, .h2 {
  font-family: var(--font-primary);
  font-size: 40px;
  font-weight: var(--font-weight-semibold);
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--color-text);
}

h3, .h3 {
  font-family: var(--font-primary);
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-tight);
  color: var(--color-text);
}

h4, .h4 {
  font-family: var(--font-primary);
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-semibold);
  line-height: var(--line-height-tight);
  color: var(--color-text);
}

h5, .h5 {
  font-family: var(--font-primary);
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-medium);
  line-height: var(--line-height-tight);
  color: var(--color-text);
}

h6, .h6 {
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-medium);
  line-height: var(--line-height-tight);
  color: var(--color-text);
}

/* Responsive heading sizes */
@media (width <= 767px) {
  h1, .h1 {
    font-size: 32px;
  }

  h2, .h2 {
    font-size: var(--font-size-xl);
  }

  h3, .h3 {
    font-size: var(--font-size-lg);
  }
}

/* ========================================
   BODY TEXT STYLES
   ======================================== */

p {
  font-family: var(--font-secondary);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-regular);
  line-height: var(--line-height-relaxed);
  letter-spacing: -0.08px;
  color: var(--color-text);
  margin-bottom: var(--spacing-4);
}

p:last-child {
  margin-bottom: 0;
}

/* Lead/intro text */
.lead {
  font-size: var(--font-size-lg);
  line-height: var(--line-height-relaxed);
}

/* Small text */
small, .small {
  font-size: var(--font-size-sm);
}

/* Extra small text */
.text-xs {
  font-size: var(--font-size-xs);
}

/* ========================================
   LINKS
   ======================================== */

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--color-primary-hover);
  text-decoration: underline;
}

a:focus {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* ========================================
   LISTS
   ======================================== */

.list {
  font-family: var(--font-secondary);
  padding-left: var(--spacing-6);
  margin-bottom: var(--spacing-4);
}

.list li {
  margin-bottom: var(--spacing-2);
}

.list-disc {
  list-style-type: disc;
}

.list-decimal {
  list-style-type: decimal;
}

/* ========================================
   TEXT UTILITIES
   ======================================== */

.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.text-uppercase {
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-wide);
}

.text-muted {
  color: var(--color-text-subtle);
}

.text-light {
  color: var(--color-text-light);
}

.text-inverse {
  color: var(--color-text-inverse);
}

.font-primary {
  font-family: var(--font-primary);
}

.font-secondary {
  font-family: var(--font-secondary);
}

.font-bold {
  font-weight: var(--font-weight-bold);
}

.font-semibold {
  font-weight: var(--font-weight-semibold);
}

.font-medium {
  font-weight: var(--font-weight-medium);
}

.font-regular {
  font-weight: var(--font-weight-regular);
}
