/* ============================================================
   HALM — base.css
   Design tokens, reset, typography, buttons, shared primitives.
   Palette is strictly 3 colors + neutrals (see CLAUDE.md).
   ============================================================ */

:root {
  /* Palette */
  --c-bg: #ffffff;
  --c-bg-alt: #f7f5f2;
  --c-text: #1e1e1e;
  --c-text-2: #5a5a5a;
  /* Exact brand blue, color-picked from the client logo (ref/halm_logo.jpg) */
  --c-accent: #0c54a0;
  --c-accent-hover: #094480;
  --c-border: #e5e5e5;

  /* Layout */
  --container: 1200px;
  --pad-x: clamp(20px, 4vw, 48px);
  --header-h: 72px;

  /* Type
     Manrope: geometric sans with full Cyrillic support.
     (Archivo was the first pick but has no Cyrillic subset.) */
  --font: "Manrope", "Inter", -apple-system, "Segoe UI", sans-serif;
}

/* ---------- Reset ---------- */

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

html {
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--c-text);
  background: var(--c-bg);
}

body.menu-open {
  overflow: hidden;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
}

img,
svg,
iframe {
  max-width: 100%;
  vertical-align: middle;
}

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

:focus-visible {
  outline: 2px solid var(--c-accent);
  outline-offset: 2px;
}

::selection {
  background: var(--c-accent);
  color: #fff;
}

/* ---------- Layout primitives ---------- */

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--pad-x);
}

.section {
  padding-block: clamp(64px, 9vw, 112px);
}

.section--alt {
  background: var(--c-bg-alt);
}

[id] {
  scroll-margin-top: calc(var(--header-h) + 16px);
}

/* ---------- Typography ---------- */

.eyebrow {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-accent);
}

h2 {
  font-size: clamp(26px, 3.4vw, 38px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.section-head {
  max-width: 720px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

.section-head .eyebrow {
  margin-bottom: 12px;
}

.section-sub {
  margin-top: 16px;
  color: var(--c-text-2);
  line-height: 1.65;
  max-width: 62ch;
}

/* ---------- Icons ---------- */

.icon {
  width: 24px;
  height: 24px;
  flex: none;
}

/* ---------- Buttons & links ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 32px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  border: 1px solid transparent;
  border-radius: 0;
  transition: background-color 0.15s ease, color 0.15s ease,
    border-color 0.15s ease;
}

.btn--primary {
  background: var(--c-accent);
  color: #fff;
}

.btn--primary:hover {
  background: var(--c-accent-hover);
}

.btn--secondary {
  background: var(--c-bg);
  color: var(--c-text);
  border-color: var(--c-text);
}

.btn--secondary:hover {
  color: var(--c-accent);
  border-color: var(--c-accent);
}

.btn--sm {
  padding: 11px 22px;
  font-size: 12px;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 4px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--c-text);
  border-bottom: 2px solid var(--c-text);
  transition: color 0.15s ease, border-color 0.15s ease;
}

.link-arrow:hover {
  color: var(--c-accent);
  border-color: var(--c-accent);
}

.link-arrow .icon {
  width: 16px;
  height: 16px;
}

/* ---------- Accessibility helpers ---------- */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  padding: 12px 20px;
  background: var(--c-accent);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

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