/* ============================================
   Fundacja Jamniczek — Base / Reset / Typografia
   ============================================ */

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

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

@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;
  }
}

body {
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: var(--lh-normal);
  color: var(--text-secondary);
  background-color: var(--bg-primary);
  background-image: var(--bg-paws);
  background-size: 240px 240px;
  background-attachment: fixed;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}


main {
  flex: 1;
}

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

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

p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
}

h1,
h2,
h3,
h4 {
  color: var(--text-primary);
  font-weight: var(--fw-bold);
  letter-spacing: -0.02em;
  line-height: var(--lh-tight);
}

h1 {
  font-size: var(--fs-h1);
}

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

h3 {
  font-size: var(--fs-h3);
  font-weight: var(--fw-semibold);
}

h4 {
  font-size: var(--fs-h4);
  font-weight: var(--fw-semibold);
}

h1.brand-title {
  color: var(--accent-green);
}

p {
  line-height: var(--lh-normal);
}

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

a:hover {
  color: var(--accent-green-soft);
  text-decoration: underline;
  text-underline-offset: 3px;
}

ul,
ol {
  padding-left: var(--sp-5);
}

li + li {
  margin-top: var(--sp-2);
}

hr {
  border: 0;
  height: 1px;
  background: var(--border);
  margin: var(--sp-8) 0;
}

::selection {
  background: var(--accent-green-glow);
  color: var(--text-primary);
}

:focus-visible {
  outline: 2px solid var(--accent-green);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* === Container === */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-inline: var(--container-padding);
}

@media (min-width: 1024px) {
  .container {
    width: 80%;
  }
}

.container--narrow {
  width: 100%;
  max-width: var(--container-narrow);
}

/* === Sekcja === */
.section {
  padding-block: var(--sp-10);
}

@media (min-width: 768px) {
  .section {
    padding-block: var(--sp-12);
  }
}

.section--tight {
  padding-block: var(--sp-8);
}

/* === Helpery === */
.sr-only {
  position: absolute;
  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: var(--sp-4);
  background: var(--accent-green);
  color: var(--text-on-green);
  padding: var(--sp-2) var(--sp-4);
  border-radius: var(--radius-md);
  z-index: var(--z-toast);
  font-weight: var(--fw-semibold);
}

.skip-link:focus {
  top: var(--sp-4);
}

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

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

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

.mt-0 {
  margin-top: 0;
}

.mt-2 {
  margin-top: var(--sp-2);
}

.mt-4 {
  margin-top: var(--sp-4);
}

.mt-6 {
  margin-top: var(--sp-6);
}

.mt-8 {
  margin-top: var(--sp-8);
}

.mb-4 {
  margin-bottom: var(--sp-4);
}

.mb-6 {
  margin-bottom: var(--sp-6);
}
