/* ==========================================================================
   Technova — Base
   Reset, document defaults, typography and global accessibility behaviour.
   ========================================================================== */

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

* {
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 20px);
  overflow-x: hidden;
}

body {
  font-family: var(--font-primary);
  font-size: var(--fs-body);
  font-weight: var(--fw-regular);
  line-height: var(--lh-body);
  color: var(--text);
  background-color: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* --- Headings ------------------------------------------------------------ */

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--black);
  font-weight: var(--fw-semibold);
  line-height: var(--lh-heading);
  letter-spacing: -0.02em;
  text-wrap: balance;
}

h1 {
  font-size: var(--fs-h1);
  line-height: var(--lh-tight);
}

h2 {
  font-size: var(--fs-h2);
  line-height: 1.1;
}

h3 {
  font-size: var(--fs-h3);
  line-height: 1.2;
}

h4 {
  font-size: var(--fs-h4);
  letter-spacing: -0.01em;
}

h5,
h6 {
  font-size: var(--fs-body);
  letter-spacing: 0;
}

p {
  text-wrap: pretty;
}

/* --- Links --------------------------------------------------------------- */

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

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

/* Inline links inside body copy stay underlined for clarity. */
.prose a,
p > a:not([class]) {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.prose a:hover,
p > a:not([class]):hover {
  color: var(--primary-dark);
}

/* --- Media --------------------------------------------------------------- */

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

img {
  height: auto;
  border: 0;
}

iframe {
  border: 0;
}

/* --- Lists --------------------------------------------------------------- */

ul,
ol {
  list-style: none;
}

.list-bullets {
  list-style: disc;
  padding-left: 1.25rem;
}

.list-bullets li {
  margin-bottom: 0.5rem;
}

/* --- Forms --------------------------------------------------------------- */

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

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

/* --- Tables (legal pages) ------------------------------------------------ */

table {
  width: 100%;
  border-collapse: collapse;
}

/* --- Utilities ----------------------------------------------------------- */

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

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

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

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

.no-wrap {
  white-space: nowrap;
}

/* Marks every unresolved placeholder so it is easy to find and replace. */
.placeholder-text {
  color: var(--muted);
  font-style: normal;
}

/* --- Focus & keyboard accessibility -------------------------------------- */

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Skip link — first tab stop on every page. */
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 200;
  padding: 12px 20px;
  background: var(--black);
  color: var(--white);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 0;
  color: var(--white);
}

/* --- Selection ----------------------------------------------------------- */

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

/* --- Reduced motion ------------------------------------------------------ */

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

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

/* --- Print --------------------------------------------------------------- */

@media print {
  .site-header,
  .site-footer,
  .floating-actions,
  .cta-band {
    display: none !important;
  }
}
