/* ===========================================
   Karstens Watercut & Welding — Globals
   Industrial / Professional theme
   =========================================== */

:root {
  /* Brand colours */
  --brand-primary: #00397c;
  --brand-primary-dark: #002a5d;
  --brand-primary-darker: #001b3e;
  --brand-primary-light: #1a4f96;
  --brand-accent: #4a73b3;
  --brand-steel: #6b7d97;

  /* Neutrals */
  --white: #ffffff;
  --off-white: #f7f8fa;
  --grey-50: #f3f4f6;
  --grey-100: #e5e7eb;
  --grey-200: #d1d5db;
  --grey-300: #9ca3af;
  --grey-400: #6b7280;
  --grey-500: #4b5563;
  --grey-600: #374151;
  --grey-700: #1f2937;
  --grey-800: #111827;
  --grey-900: #0a0e17;

  /* Type */
  --font-display: 'Oswald', 'Arial Narrow', sans-serif;
  --font-body: 'Barlow', system-ui, sans-serif;

  /* Spacing */
  --container-max: 1280px;
  --section-pad-y: clamp(3.5rem, 8vw, 6rem);
  --section-pad-x: clamp(1.25rem, 5vw, 3rem);

  /* Effects */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 32px rgba(0, 14, 40, 0.12);
  --shadow-xl: 0 24px 60px rgba(0, 14, 40, 0.18);
  --shadow-brand: 0 8px 24px rgba(0, 57, 124, 0.25);

  --radius-sm: 2px;
  --radius-md: 4px;
  --radius-lg: 8px;

  --tr-fast: 0.18s ease;
  --tr-mid: 0.3s ease;
  --tr-slow: 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

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

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--grey-700);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--brand-primary);
  text-decoration: none;
  transition: color var(--tr-fast);
}
a:hover { color: var(--brand-primary-light); }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--grey-800);
  letter-spacing: 0.01em;
  line-height: 1.15;
  margin: 0 0 0.75em;
  font-weight: 600;
}
h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: clamp(1.2rem, 2.4vw, 1.5rem); }
h4 { font-size: 1.125rem; }

p { margin: 0 0 1rem; }

ul, ol { padding-left: 1.25rem; margin: 0 0 1rem; }
ul li, ol li { margin-bottom: 0.4rem; }

/* ===== Layout ===== */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-left: var(--section-pad-x);
  padding-right: var(--section-pad-x);
}

main { display: block; }

section {
  padding: var(--section-pad-y) 0;
  position: relative;
}

/* Alternating section backgrounds */
.section-light  { background: var(--white); color: var(--grey-700); }
.section-grey   { background: var(--grey-50); color: var(--grey-700); }
.section-dark   {
  background: linear-gradient(135deg, var(--brand-primary-darker) 0%, var(--brand-primary) 100%);
  color: var(--off-white);
}
.section-dark h1, .section-dark h2, .section-dark h3 { color: var(--white); }
.section-dark a { color: #9ec0ed; }
.section-dark a:hover { color: var(--white); }

/* ===== Eyebrow tag ===== */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brand-primary);
  font-weight: 500;
  margin-bottom: 1rem;
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--brand-primary);
  display: inline-block;
}
.section-dark .eyebrow { color: #9ec0ed; }
.section-dark .eyebrow::before { background: #9ec0ed; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.95rem 1.75rem;
  min-height: 48px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--tr-mid);
  text-decoration: none;
  position: relative;
  overflow: hidden;
}
.btn-primary {
  background: var(--brand-primary);
  color: var(--white);
  box-shadow: var(--shadow-brand);
}
.btn-primary:hover {
  background: var(--brand-primary-dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0, 57, 124, 0.35);
}
.btn-outline {
  background: transparent;
  color: var(--brand-primary);
  border-color: var(--brand-primary);
}
.btn-outline:hover {
  background: var(--brand-primary);
  color: var(--white);
}
.section-dark .btn-outline {
  color: var(--white);
  border-color: rgba(255,255,255,0.5);
}
.section-dark .btn-outline:hover {
  background: var(--white);
  color: var(--brand-primary);
  border-color: var(--white);
}
.btn-ghost {
  background: transparent;
  color: var(--grey-700);
  padding: 0.5rem 0;
  min-height: auto;
  font-size: 0.85rem;
}
.btn-ghost::after {
  content: "→";
  transition: transform var(--tr-fast);
}
.btn-ghost:hover::after { transform: translateX(4px); }

/* ===== Selection ===== */
::selection { background: var(--brand-primary); color: var(--white); }

/* ===== Scroll-reveal ===== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Focus ===== */
:focus-visible {
  outline: 3px solid var(--brand-primary-light);
  outline-offset: 2px;
}

/* ===== Section titles ===== */
.section-title {
  text-align: center;
  margin-bottom: 3rem;
}
.section-title h2 { margin-bottom: 0.5rem; }
.section-title p { color: var(--grey-500); max-width: 720px; margin: 0 auto; }
.section-dark .section-title p { color: rgba(255,255,255,0.78); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
