/*
Theme Name: SUSTRA® Theme
Theme URI: https://stajnia.jarcewo.pl
Author: Jakub Klonowski-Rosploch
Author URI: https://qubity.pl
Description: Lekki, szybki i modularny motyw WordPress stworzony dla Stajni Jarcewo.
             Oparty na klasycznym podejsciu (Classic Theme + ACF/SCF), bez builderow,
             zoptymalizowany pod wydajnosc, SEO oraz pelna customizacje pod strone stajni
             i uslug jezdzieckich.
Version: 1.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 8.0
Text Domain: stajnia-jarcewo
License: Private / Proprietary
Tags: custom-theme, horses, stable, equestrian, riding, minimal, fast, acf, starter, business
*/

/* ==========================================================================
   0. IMPORT FONTÓW
   @import MUSI być na początku pliku — przed jakimikolwiek regułami CSS
   ========================================================================== */

@import url("https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap");

/* ==========================================================================
   1. ZMIENNE GLOBALNE (:root)
   Jedno miejsce — wszystkie tokeny projektu
   ========================================================================== */

:root {
  /* --- Kolory: Szarości (Blue Shades) --- */
  --color-shade-lightest: #f2f2f2;
  --color-shade-lighter: #d8d9d9;
  --color-shade-light: #b2b4b4;
  --color-shade: #7f8382;
  --color-shade-dark: #4c5250;
  --color-shade-darker: #292929;
  --color-shade-darkest: #000806;

  /* --- Kolory: Niebieski (Blue Ribbon) --- */
  --color-blue-lightest: #e6efff;
  --color-blue-lighter: #cedfff;
  --color-blue-light: #548fff;
  --color-blue: #0b5fff;
  --color-blue-dark: #084ccc;
  --color-blue-darker: #042666;
  --color-blue-darkest: #031c4c;

  /* --- Kolory: Pomarańczowy (Pizazz) --- */
  --color-orange-lightest: #fff3e5;
  --color-orange-lighter: #ffe7cc;
  --color-orange-light: #ffad4c;
  --color-orange: #ff8a00;
  --color-orange-dark: #cc6e00;
  --color-orange-darker: #663700;
  --color-orange-darkest: #4c2900;

  /* --- Kolory: Zielony (Jade) --- */
  --color-jade-lightest: #e5f6f1;
  --color-jade-lighter: #ccede4;
  --color-jade-light: #4cc2a0;
  --color-jade: #00a878;
  --color-jade-dark: #008660;
  --color-jade-darker: #004330;
  --color-jade-darkest: #003224;

  /* --- Kolory: Semantyczne (przypisz tutaj gdy projekt dojrzeje) --- */
  --color-primary: var(--color-jade);
  --color-accent: var(--color-jade-darkt);
  --color-bg: #fff7f5;
  --color-surface: #ffffff;
  --color-text: var(--color-shade-darker);
  --color-text-muted: var(--color-shade);
  --color-border: var(--color-shade-lighter);

  /* --- Typografia: Fonty --- */
  --font-heading: "Poppins", sans-serif;
  --font-body: "Inter", sans-serif;

  /* --- Typografia: Rozmiary — fluid clamp(mobile, fluid, desktop)
       Skaluje się płynnie ~375px → ~1440px, zero breakpointów     --- */
  --fs-h1: clamp(1.75rem, 4vw + 0.5rem, 3rem); /* 28px → 48px */
  --fs-h2: clamp(1.5rem, 3vw + 0.5rem, 2.5rem); /* 24px → 40px */
  --fs-h3: clamp(1.25rem, 2vw + 0.5rem, 1.875rem); /* 20px → 30px */
  --fs-h4: clamp(1.125rem, 1.5vw + 0.4rem, 1.5rem); /* 18px → 24px */
  --fs-p: clamp(1rem, 0.5vw + 0.75rem, 1.125rem); /* 16px → 18px */
  --fs-sm: clamp(0.8125rem, 0.25vw + 0.75rem, 0.9375rem); /* 13px → 15px */
  --fs-xs: 0.75rem; /* 12px — stały, etykiety / przyciski */

  /* --- Typografia: Grubości --- */
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  /* --- Spacing — skala rem (1rem = 16px)
       Skaluje się z preferencjami użytkownika → lepsza dostępność --- */
  --space-1: 0.25rem; /*  4px */
  --space-2: 0.5rem; /*  8px */
  --space-3: 0.75rem; /* 12px */
  --space-4: 1rem; /* 16px */
  --space-6: 1.5rem; /* 24px */
  --space-8: 2rem; /* 32px */
  --space-12: 3rem; /* 48px */
  --space-16: 4rem; /* 64px */
  --space-20: 5rem; /* 80px */
  --space-24: 6rem; /* 96px */

  /* --- Border radius --- */
  --radius-sm: 0.25rem; /*  4px */
  --radius-md: 0.5rem; /*  8px */
  --radius-lg: 1rem; /* 16px */
  --radius-pill: 9999px;

  /* --- Cienie --- */
  --shadow-sm: 0.125rem 0.125rem 0.375rem rgba(0, 0, 0, 0.15);
  --shadow-md: 0.25rem 0.25rem 0.625rem rgba(0, 0, 0, 0.25);
  --shadow-lg: 0.5rem 0.5rem 1.5rem rgba(0, 0, 0, 0.2);

  /* --- Transitions --- */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.4s ease;
  --transition-slow: 0.6s ease;
}

/* clamp() skaluje typografię płynnie — breakpointy dla fontów nie są potrzebne */

/* ==========================================================================
   2. RESET / NORMALIZE
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 100%; /* 1rem = 16px (respektuje ustawienia użytkownika) */
  scroll-behavior: smooth;
}

body {
  background-color: var(--color-surface);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--fs-p);
  line-height: 1.6;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

ul,
ol {
  list-style: none;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
}

/* ==========================================================================
   3. TYPOGRAFIA BAZOWA
   ========================================================================== */

h1 {
  font-family: var(--font-heading);
  font-size: var(--fs-h1);
  font-weight: var(--fw-bold);
  line-height: 1.2;
}

h2 {
  font-family: var(--font-heading);
  font-size: var(--fs-h2);
  font-weight: var(--fw-bold);
  line-height: 1.3;
}

h3 {
  font-family: var(--font-heading);
  font-size: var(--fs-h3);
  font-weight: var(--fw-medium);
  line-height: 1.4;
}

h4 {
  font-family: var(--font-heading);
  font-size: var(--fs-h4);
  font-weight: var(--fw-medium);
}

p {
  font-family: var(--font-body);
  font-size: var(--fs-p);
  line-height: 1.7;
}

/* ==========================================================================
   4. KOMPONENTY BAZOWE
   ========================================================================== */

.wrapper {
  min-width: 360px;
  max-width: 1920px;
  margin: auto;
}

/* --- Przycisk --- */
.btn {
  display: inline-block;
  padding: var(--space-3) var(--space-6);
  background-color: var(--color-primary);
  color: #fff;
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    background-color var(--transition-slow),
    transform var(--transition-slow);
}

.btn:hover {
  background-color: transparent;
  transform: translateY(-1px);
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
}

.btn:active {
  transform: translateY(0);
}

/* Wariant wtórny */
.btn--outline {
  background-color: transparent;
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
}

.btn--outline:hover {
  background-color: var(--color-primary);
  color: #fff;
}

/* --- Cień (helper class) --- */
.shd {
  box-shadow: var(--shadow-md);
}

/* --- Dostępność: elementy tylko dla czytników ekranu --- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* line */
.line {
  width: 80%;
  height: 1px;
  background-color: var(--color-primary);
  margin: auto;
}
