/**
 * Copyright (c) 2026 SEVEN TWENTY DEGREES (Pty) Ltd
 * Registration No: 2023/212025/07
 * All rights reserved.
 *
 * This software is the proprietary and confidential information of
 * SEVEN TWENTY DEGREES (Pty) Ltd. Unauthorized
 * copying, modification, distribution, or use is strictly prohibited.
 */

/* =========================================================================
   BASE — reset, root defaults, body typography, links, form defaults.
   Depends on tokens.css.
   ========================================================================= */

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

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  background: var(--color-paper);
  color: var(--color-ink);
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: var(--lh-base);
  font-feature-settings: "ss01", "cv11"; /* Inter stylistic set where available */
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1 0 auto;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

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

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: var(--fw-semibold);
  color: var(--color-ink);
  line-height: var(--lh-tight);
  letter-spacing: -0.01em;
  font-variation-settings: "opsz" 36, "SOFT" 30;
}

h1 { font-size: var(--fs-3xl); }
h2 { font-size: var(--fs-2xl); }
h3 { font-size: var(--fs-xl); }
h4 { font-size: var(--fs-lg); }
h5 { font-size: var(--fs-md); }
h6 { font-size: var(--fs-base); text-transform: uppercase; letter-spacing: 0.08em; }

p { max-width: var(--measure-wide); }

a {
  color: var(--color-primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color var(--dur-quick) var(--ease-out);
}
a:hover { color: var(--color-primary-deep); }
a:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

strong, b { font-weight: var(--fw-semibold); }

small { font-size: var(--fs-sm); color: var(--color-muted); }

::selection {
  background: var(--color-primary);
  color: var(--color-paper);
}

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

blockquote {
  font-family: var(--font-serif);
  font-size: var(--fs-md);
  font-style: italic;
  line-height: var(--lh-snug);
  color: var(--color-ink-soft);
  border-left: 3px solid var(--color-primary);
  padding-left: var(--space-5);
  margin: var(--space-6) 0;
  max-width: var(--measure-article);
}

ul, ol { padding-left: 1.25em; }
li + li { margin-top: 0.35em; }

figure { margin: 0; }
figcaption {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  color: var(--color-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: var(--space-2);
}

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

.skip-link {
  position: absolute;
  top: -40px;
  left: 1rem;
  background: var(--color-ink);
  color: var(--color-paper);
  padding: 0.5rem 1rem;
  text-decoration: none;
  border-radius: var(--radius-md);
  z-index: 1000;
  transition: top var(--dur-base) var(--ease-out);
}
.skip-link:focus {
  top: 1rem;
  color: var(--color-paper);
}
