/* ============================================================
   SOLANTIR TECHNOLOGIES — styles.css
   Global variables, resets, typography, layout
   ============================================================ */

/* ── Google Fonts ── */
/* Geist + Geist Mono — a clean, modern, tech-forward neo-grotesque
   family. Geist drives headings and body copy — legible, unfussy,
   built to carry a "clarity" message without decoration getting in
   the way. Geist Mono is mixed in for data-native details: eyebrow
   labels, coordinates, metrics, engine readouts — the small technical
   texture that signals "this company actually handles data." */
@import url('https://fonts.googleapis.com/css2?family=Geist:wght@100..900&family=Geist+Mono:wght@400;500;600;700&display=swap');

/* ── Design Tokens ── */
:root {
  /* Colours — derived from the Solantir mark (ink #332F2F) plus a
     restrained two-accent system:
       --signal (lucid blue)  → clarity / trust / interactive data
       --bronze (statesman)   → quiet authority, used sparingly */
  --white:        #FFFFFF;
  --paper:        #FAF9F6;
  --paper-dim:    #F1EFEA;
  --line:         rgba(51, 47, 47, 0.12);
  --line-strong:  rgba(51, 47, 47, 0.22);
  --muted:        #726C68;
  --ink:          #332F2F;
  --ink-deep:     #211E1D;
  --ink-void:     #161413;

  --signal:       #2C5F8A;
  --signal-deep:  #1B3E5C;
  --signal-bright:#4A88BC;
  --signal-soft:  rgba(44, 95, 138, 0.09);

  --bronze:       #A07234;
  --bronze-deep:  #6E4E23;
  --bronze-soft:  rgba(160, 114, 52, 0.10);

  --risk:         #A8462E;
  --good:         #3D7A5C;

  /* Typography */
  --font:         'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body:    'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono:    'Geist Mono', ui-monospace, SFMono-Regular, monospace;
  --size-xs:      0.75rem;
  --size-sm:      0.875rem;
  --size-base:    1rem;
  --size-md:      1.125rem;
  --size-lg:      1.25rem;
  --size-xl:      1.5rem;
  --size-2xl:     2rem;
  --size-3xl:     2.75rem;
  --size-4xl:     3.75rem;
  --size-5xl:     5rem;

  /* Spacing */
  --space-1:   0.25rem;
  --space-2:   0.5rem;
  --space-3:   0.75rem;
  --space-4:   1rem;
  --space-6:   1.5rem;
  --space-8:   2rem;
  --space-10:  2.5rem;
  --space-12:  3rem;
  --space-16:  4rem;
  --space-20:  5rem;
  --space-24:  6rem;
  --space-32:  8rem;
  --space-40:  10rem;

  /* Corners — deliberately sharp. No pill shapes, no circular chrome. */
  --radius-sm: 2px;
  --radius-md: 3px;
  --radius-lg: 4px;

  /* Corner cut — the signature top-right bevel used on every card,
     button, tag, and panel sitewide. Three sizes scaled to element size. */
  --cut-xs: 6px;
  --cut-sm: 10px;
  --cut-lg: 22px;

  /* Layout */
  --max-width:     1200px;
  --page-padding:  clamp(1.25rem, 5vw, 4rem);

  /* Motion */
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --duration-fast:   200ms;
  --duration-base:   300ms;
  --duration-slow:   600ms;
  --duration-slower: 800ms;
}

/* ── Reset ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--size-base);
  color: var(--ink);
  background-color: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

button {
  font-family: var(--font);
  cursor: pointer;
  border: none;
  background: none;
}

input, textarea, select {
  font-family: var(--font-body);
  font-size: var(--size-base);
}

/* ── Layout Primitives ── */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--page-padding);
  padding-right: var(--page-padding);
}

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

.section--compact {
  padding-top: var(--space-20);
  padding-bottom: var(--space-20);
}

.section--flush {
  padding-top: 0;
  padding-bottom: 0;
}

/* Background variants */
.bg-white    { background-color: var(--paper); }
.bg-off      { background-color: var(--white); }
.bg-light    { background-color: var(--paper-dim); }
.bg-dark     { background-color: var(--ink-void); color: var(--white); }
.bg-charcoal { background-color: var(--ink-deep); color: var(--white); }

/* ── Typography Scale ── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.display-1 {
  font-size: clamp(2.75rem, 7vw, var(--size-5xl));
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.0;
}

.display-2 {
  font-size: clamp(2rem, 5vw, var(--size-4xl));
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.05;
}

.heading-1 {
  font-size: clamp(1.75rem, 4vw, var(--size-3xl));
  font-weight: 700;
  letter-spacing: -0.03em;
}

.heading-2 {
  font-size: clamp(1.375rem, 3vw, var(--size-2xl));
  font-weight: 600;
  letter-spacing: -0.025em;
}

.heading-3 {
  font-size: clamp(1.125rem, 2.5vw, var(--size-xl));
  font-weight: 600;
  letter-spacing: -0.02em;
}

.body-lg {
  font-size: clamp(var(--size-base), 1.5vw, var(--size-md));
  line-height: 1.7;
  font-weight: 400;
}

.body-md {
  font-size: var(--size-base);
  line-height: 1.6;
}

.body-sm {
  font-size: var(--size-sm);
  line-height: 1.5;
}

.caption {
  font-size: var(--size-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
}

/* Colour utilities */
.text-muted   { color: var(--muted); }
.text-signal  { color: var(--signal); }
.text-bronze  { color: var(--bronze); }
.text-ink     { color: var(--ink); }
.text-white   { color: var(--white); }
.text-light   { color: rgba(255,255,255,0.65); }

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

/* ── Eyebrow / Label ── */
.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--size-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--signal);
  margin-bottom: var(--space-4);
  display: block;
}

.eyebrow--light {
  color: var(--signal-bright);
}

.eyebrow--bronze {
  color: var(--bronze);
}

/* ── Divider ── */
.divider {
  width: 2.5rem;
  height: 2px;
  background-color: var(--signal);
  margin: var(--space-6) 0;
}

.divider--center {
  margin-left: auto;
  margin-right: auto;
}

/* ── Grid Helpers ── */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-8);
}

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

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

/* ── Flex Helpers ── */
.flex         { display: flex; }
.flex-center  { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-col     { display: flex; flex-direction: column; }
.gap-2  { gap: var(--space-2); }
.gap-4  { gap: var(--space-4); }
.gap-6  { gap: var(--space-6); }
.gap-8  { gap: var(--space-8); }
.gap-12 { gap: var(--space-12); }

/* ── Spacing Utilities ── */
.mt-2  { margin-top: var(--space-2); }
.mt-4  { margin-top: var(--space-4); }
.mt-6  { margin-top: var(--space-6); }
.mt-8  { margin-top: var(--space-8); }
.mt-10 { margin-top: var(--space-10); }
.mt-12 { margin-top: var(--space-12); }
.mt-16 { margin-top: var(--space-16); }
.mt-20 { margin-top: var(--space-20); }

.mb-2  { margin-bottom: var(--space-2); }
.mb-4  { margin-bottom: var(--space-4); }
.mb-6  { margin-bottom: var(--space-6); }
.mb-8  { margin-bottom: var(--space-8); }
.mb-10 { margin-bottom: var(--space-10); }
.mb-12 { margin-bottom: var(--space-12); }
.mb-16 { margin-bottom: var(--space-16); }

/* ── Max-Width Variants ── */
.max-60  { max-width: 60ch; }
.max-70  { max-width: 70ch; }
.max-80  { max-width: 80ch; }
.mx-auto { margin-left: auto; margin-right: auto; }

/* ── Corner Cut Utilities ──
   Bevels only the top-right corner — the other three stay square.
   Used directly as classes on one-off elements; baked in via the
   clip-path property on most shared component selectors instead. */
.corner-cut-lg { clip-path: polygon(0 0, calc(100% - var(--cut-lg)) 0, 100% var(--cut-lg), 100% 100%, 0 100%); }
.corner-cut-sm { clip-path: polygon(0 0, calc(100% - var(--cut-sm)) 0, 100% var(--cut-sm), 100% 100%, 0 100%); }
.corner-cut-xs { clip-path: polygon(0 0, calc(100% - var(--cut-xs)) 0, 100% var(--cut-xs), 100% 100%, 0 100%); }

/* ── Responsive Breakpoints ── */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  :root {
    --space-32: 5rem;
    --space-24: 4rem;
    --space-20: 3.5rem;
  }

  .section { padding-top: var(--space-20); padding-bottom: var(--space-20); }
  .section--compact { padding-top: var(--space-12); padding-bottom: var(--space-12); }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }
}

/* ── Reduced Motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}
