/* ==================================================================
   BodyFoorce Base Styles (base.css)
   Bold, energetic, modern, high-contrast foundation
   ================================================================== */

/* ==================================================================
   1. CSS VARIABLES (THEME TOKENS)
   ================================================================== */
:root {
  /* Color Palette - BodyFoorce Brand */
  --color-bg: #050608;            /* Main page background - near black */
  --color-bg-alt: #101218;        /* Elevated sections / cards */
  --color-surface: #181b22;       /* Panels, nav, modals */

  --color-text: #f5f5f7;          /* Primary text on dark background */
  --color-text-muted: #a3a7b3;    /* Secondary / helper text */
  --color-border-subtle: #262933; /* Subtle dividers */

  --color-primary: #ff1637;       /* Energetic red - primary brand */
  --color-primary-soft: #ff2647;  /* Hover/soft accent variant */

  --color-success: #27c96b;       /* Positive / success */
  --color-warning: #ffb02e;       /* Warning / caution */
  --color-danger: #ff3b4f;        /* Error / destructive */

  --color-neutral-50:  #f9fafb;
  --color-neutral-100: #f3f4f6;
  --color-neutral-200: #e5e7eb;
  --color-neutral-300: #d1d5db;
  --color-neutral-400: #9ca3af;
  --color-neutral-500: #6b7280;
  --color-neutral-600: #4b5563;
  --color-neutral-700: #374151;
  --color-neutral-800: #1f2933;
  --color-neutral-900: #111827;

  --color-focus-ring: #ff6f8a;    /* High contrast focus outline */

  /* Typography */
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Inter", 
                "SF Pro Text", "Roboto", "Segoe UI", sans-serif;
  --font-display: "Oswald", "Anton", system-ui, -apple-system, sans-serif;

  /* Font Sizes (rem) */
  --text-xs: 0.75rem;   /* 12px */
  --text-sm: 0.875rem;  /* 14px */
  --text-base: 1rem;    /* 16px */
  --text-lg: 1.125rem;  /* 18px */
  --text-xl: 1.25rem;   /* 20px */
  --text-2xl: 1.5rem;   /* 24px */
  --text-3xl: 1.875rem; /* 30px */
  --text-4xl: 2.25rem;  /* 36px */
  --text-5xl: 3rem;     /* 48px */

  /* Line Heights */
  --leading-tight: 1.1;
  --leading-snug: 1.25;
  --leading-normal: 1.5;

  /* Spacing Scale (px) -> rem based on 16px root */
  --space-0: 0;
  --space-1: 0.25rem;   /* 4px */
  --space-2: 0.5rem;    /* 8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-5: 1.25rem;   /* 20px */
  --space-6: 1.5rem;    /* 24px */
  --space-8: 2rem;      /* 32px */
  --space-10: 2.5rem;   /* 40px */
  --space-12: 3rem;     /* 48px */
  --space-16: 4rem;     /* 64px */
  --space-20: 5rem;     /* 80px */
  --space-24: 6rem;     /* 96px */

  /* Radii */
  --radius-sm: 0.25rem;     /* 4px */
  --radius-md: 0.5rem;      /* 8px */
  --radius-lg: 0.75rem;     /* 12px */
  --radius-full: 999px;     /* pills / circles */

  /* Shadows - crisp, performance-focused depth */
  --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-strong: 0 18px 45px rgba(0, 0, 0, 0.55);

  /* Motion */
  --transition-fast: 120ms ease-out;
  --transition-base: 180ms ease-out;
  --transition-slow: 260ms ease-out;
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  :root {
    --transition-fast: 0ms;
    --transition-base: 0ms;
    --transition-slow: 0ms;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ==================================================================
   2. RESET / NORMALIZE
   ================================================================== */

/* Box sizing */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Remove default margins */
body,
 h1,
 h2,
 h3,
 h4,
 h5,
 h6,
 p,
 figure,
 blockquote,
 dl,
 dd {
  margin: 0;
}

/* Remove list styles on ul, ol elements with a list role */
ul[role="list"],
ol[role="list"] {
  list-style: none;
  padding: 0;
}

/* Default body */
html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Images and media responsive by default */
img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
  max-width: 100%;
  height: auto;
}

img,
svg {
  display: block;
}

/* Form elements inherit font */
input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  border: none;
  background: none;
  padding: 0;
}

/* Prevent text overflows */
p,
 h1,
 h2,
 h3,
 h4,
 h5,
 h6 {
  overflow-wrap: break-word;
}

/* Root stacking context */
#root,
#__next {
  isolation: isolate;
}

/* ==================================================================
   3. BASE TYPOGRAPHY & ELEMENTS
   ================================================================== */

body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
}

/* Headings - bold, compressed, energetic */
h1,
 h2,
 h3,
 h4,
 h5,
 h6 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text);
}

h1 {
  font-size: clamp(2.5rem, 4vw, var(--text-5xl));
  line-height: var(--leading-tight);
  margin-bottom: var(--space-4);
}

h2 {
  font-size: clamp(2rem, 3vw, var(--text-4xl));
  line-height: var(--leading-tight);
  margin-bottom: var(--space-3);
}

h3 {
  font-size: clamp(1.5rem, 2.4vw, var(--text-3xl));
  line-height: var(--leading-snug);
  margin-bottom: var(--space-3);
}

h4 {
  font-size: var(--text-2xl);
  line-height: var(--leading-snug);
  margin-bottom: var(--space-2);
}

h5 {
  font-size: var(--text-xl);
  line-height: var(--leading-snug);
  margin-bottom: var(--space-2);
}

h6 {
  font-size: var(--text-lg);
  line-height: var(--leading-snug);
  margin-bottom: var(--space-2);
}

p {
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text-muted);
  /* Comfortable line length */
}

p + p {
  margin-top: var(--space-3);
}

strong,
b {
  font-weight: 700;
}

small {
  font-size: var(--text-sm);
}

/* Links - bold, clean, high-contrast */
a {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 600;
  transition: color var(--transition-base),
              text-shadow var(--transition-base);
}

a:hover {
  color: var(--color-primary-soft);
  text-shadow: 0 0 12px rgba(255, 22, 55, 0.7);
}

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

/* Horizontal rule */
hr {
  border: none;
  border-top: 1px solid var(--color-border-subtle);
  margin: var(--space-6) 0;
}

/* ==================================================================
   4. ACCESSIBILITY HELPERS
   ================================================================== */

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

.sr-only-focusable:active,
.sr-only-focusable:focus {
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

/* Focus styles */
:focus-visible {
  outline: 2px solid var(--color-focus-ring);
  outline-offset: 3px;
}

/* ==================================================================
   5. LAYOUT UTILITIES
   ================================================================== */

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

@media (min-width: 1280px) {
  .container {
    max-width: 1320px;
  }
}

/* Spacing utilities (commonly used) */
.section {
  padding-top: var(--space-16);
  padding-bottom: var(--space-16);
}

.section--tight {
  padding-top: var(--space-10);
  padding-bottom: var(--space-10);
}

/* Flex helpers */
.flex {
  display: flex;
}

.inline-flex {
  display: inline-flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.flex-column {
  display: flex;
  flex-direction: column;
}

.flex-wrap {
  flex-wrap: wrap;
}

/* Gap utilities */
.gap-2 {
  gap: var(--space-2);
}

.gap-3 {
  gap: var(--space-3);
}

.gap-4 {
  gap: var(--space-4);
}

.gap-6 {
  gap: var(--space-6);
}

/* Grid helpers */
.grid {
  display: grid;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6);
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
}

@media (max-width: 768px) {
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* Alignment helpers */
.text-center {
  text-align: center;
}

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

.text-uppercase {
  text-transform: uppercase;
}

/* Width helpers */
.w-full {
  width: 100%;
}

.max-w-xl {
  max-width: 42rem;
}

.max-w-2xl {
  max-width: 48rem;
}

/* ==================================================================
   6. FORM ELEMENTS
   ================================================================== */

input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="number"],
input[type="search"],
select,
textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border-subtle);
  background-color: #0d0f14;
  color: var(--color-text);
  font-size: var(--text-base);
  outline: none;
  transition: border-color var(--transition-base),
              box-shadow var(--transition-base),
              background-color var(--transition-base);
}

input::placeholder,
textarea::placeholder {
  color: var(--color-neutral-500);
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 1px var(--color-primary);
}

input:disabled,
select:disabled,
textarea:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

label {
  display: inline-block;
  margin-bottom: var(--space-2);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text);
}

/* ==================================================================
   7. BUTTONS
   ================================================================== */

.button,
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  background: linear-gradient(135deg, #ff1637 0%, #ff6b3d 40%, #ff1637 100%);
  color: #ffffff;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  cursor: pointer;
  transition: transform var(--transition-fast),
              box-shadow var(--transition-fast),
              background var(--transition-fast),
              opacity var(--transition-fast);
  white-space: nowrap;
}

.button--primary {
  /* alias; same as default */
}

.button--outline {
  background: transparent;
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.button--ghost {
  background: rgba(255, 255, 255, 0.02);
  border-color: rgba(255, 255, 255, 0.08);
  color: var(--color-text);
}

.button:hover,
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-soft);
}

.button:active,
button:active,
input[type="submit"]:active,
input[type="button"]:active,
input[type="reset"]:active {
  transform: translateY(0);
  box-shadow: none;
}

.button:disabled,
button:disabled,
input[type="submit"]:disabled,
input[type="button"]:disabled,
input[type="reset"]:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.button:focus-visible,
button:focus-visible,
input[type="submit"]:focus-visible,
input[type="button"]:focus-visible,
input[type="reset"]:focus-visible {
  outline: 2px solid var(--color-focus-ring);
  outline-offset: 3px;
}

/* ==================================================================
   8. CARD COMPONENT
   ================================================================== */

.card {
  background-color: var(--color-bg-alt);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.04);
  box-shadow: var(--shadow-soft);
  padding: var(--space-6);
}

.card--elevated {
  background: radial-gradient(circle at top left, rgba(255, 22, 55, 0.18), transparent 55%),
              var(--color-bg-alt);
}

.card__header {
  margin-bottom: var(--space-4);
}

.card__title {
  margin-bottom: var(--space-1);
}

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

/* ==================================================================
   9. MEDIA & HERO HELPERS (PHOTOGRAPHY-HEAVY LAYOUTS)
   ================================================================== */

.hero {
  position: relative;
  padding-top: var(--space-20);
  padding-bottom: var(--space-20);
  overflow: hidden;
}

.hero--overlay::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, rgba(255, 22, 55, 0.45), transparent 55%),
              linear-gradient(135deg, rgba(5, 6, 8, 0.9), rgba(5, 6, 8, 0.96));
  mix-blend-mode: multiply;
  pointer-events: none;
}

.hero__content {
  position: relative;
  z-index: 1;
}

.hero__eyebrow {
  font-size: var(--text-sm);
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: var(--space-2);
}

.hero__kpi {
  font-family: var(--font-display);
  font-size: var(--text-4xl);
  line-height: var(--leading-tight);
}

/* ==================================================================
   10. MISC UTILITIES
   ================================================================== */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.125rem 0.75rem;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-size: var(--text-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.badge--primary {
  background-color: rgba(255, 22, 55, 0.1);
  border-color: rgba(255, 22, 55, 0.65);
  color: var(--color-primary);
}

.badge--success {
  background-color: rgba(39, 201, 107, 0.1);
  border-color: rgba(39, 201, 107, 0.6);
  color: var(--color-success);
}

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

.bg-surface {
  background-color: var(--color-surface);
}

.bg-primary {
  background-color: var(--color-primary);
}

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

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

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

.text-uppercase-tracking {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: var(--text-xs);
}

.shadow-soft {
  box-shadow: var(--shadow-soft);
}

.shadow-strong {
  box-shadow: var(--shadow-strong);
}

.rounded-sm {
  border-radius: var(--radius-sm);
}

.rounded-md {
  border-radius: var(--radius-md);
}

.rounded-lg {
  border-radius: var(--radius-lg);
}

.rounded-full {
  border-radius: var(--radius-full);
}

/***** End of base.css *****/
