/* =================================================================
   KS WESOŁA – Main Stylesheet
   Foundation: variables,
reset,
typography,
layout,
components
   ================================================================= */

/* ───────────────────────────────────────────
   CSS CUSTOM PROPERTIES
   ─────────────────────────────────────────── */
:root {
  /* Club colors */
  --club-green: var(--wp--preset--color--club-green); /* było: #0F5A3C */
  --club-green-dark: var(--wp--preset--color--club-green-dark); /* było: #0A3F2A */
  --club-green-light: var(--wp--preset--color--club-green-light); /* było: #E8F5EE */
  --club-yellow: var(--wp--preset--color--club-yellow); /* było: #E8B931 */
  --club-yellow-light: var(--wp--preset--color--club-yellow-light); /* było: #FDF6E3 */
  --club-yellow-dark: var(--wp--preset--color--club-yellow-dark); /* było: #C49A1A */
  --club-red: var(--wp--preset--color--club-red); /* było: #BE2F2F */
  --club-red-light: var(--wp--preset--color--club-red-light); /* było: #FDE8E8 */

  /* Neutrals */
  --ink: var(--wp--preset--color--ink); /* było: #1A1A1A */
  --ink-light: var(--wp--preset--color--ink-light); /* było: #374151 */
  --muted: var(--wp--preset--color--muted); /* było: #667085 */
  --border: var(--wp--preset--color--border); /* było: #E5E7EB */
  --border-light: var(--wp--preset--color--border-light); /* było: #F3F4F6 */
  --bg: var(--wp--preset--color--bg); /* było: #F8FAFC */
  --bg-alt: var(--wp--preset--color--bg-alt); /* było: #F1F5F9 */
  --white: var(--wp--preset--color--white); /* było: #FFFFFF */

  /* Typography */
  --font-heading: var(--wp--preset--font-family--heading); /* było: 'Barlow Semi Condensed', system-ui, -apple-system, sans-serif */
  --font-body: var(--wp--preset--font-family--body); /* było: 'Source Sans 3', system-ui, -apple-system, sans-serif */

  --fs-xs: var(--wp--preset--font-size--xs); /* było: 0.75rem */     /* 12px */
  --fs-sm: var(--wp--preset--font-size--sm); /* było: 0.875rem */    /* 14px */
  --fs-base: var(--wp--preset--font-size--base); /* było: 1rem */      /* 16px */
  --fs-md: var(--wp--preset--font-size--md); /* było: 1.125rem */    /* 18px */
  --fs-lg: var(--wp--preset--font-size--lg); /* było: 1.25rem */     /* 20px */
  --fs-xl: var(--wp--preset--font-size--xl); /* było: 1.5rem */      /* 24px */
  --fs-2xl: var(--wp--preset--font-size--xxl); /* było: 2rem */       /* 32px */
  --fs-3xl: var(--wp--preset--font-size--xxxl); /* było: 2.75rem */    /* 44px – Barlow jest wąski, display podbity o ~10% */
  --fs-4xl: var(--wp--preset--font-size--xxxxl); /* było: 3rem */       /* 48px */
  --fs-5xl: var(--wp--preset--font-size--xxxxxl); /* było: 3.875rem */   /* 62px – j.w. */

  --lh-tight: var(--wp--custom--line-height--tight); /* było: 1.1 */
  --lh-snug: var(--wp--custom--line-height--snug); /* było: 1.3 */
  --lh-normal: var(--wp--custom--line-height--normal); /* było: 1.6 */
  --lh-relaxed: var(--wp--custom--line-height--relaxed); /* było: 1.75 */

  /* Spacing */
  --space-xs: var(--wp--preset--spacing--xs); /* było: 0.25rem */
  --space-sm: var(--wp--preset--spacing--sm); /* było: 0.5rem */
  --space-md: var(--wp--preset--spacing--md); /* było: 1rem */
  --space-lg: var(--wp--preset--spacing--lg); /* było: 1.5rem */
  --space-xl: var(--wp--preset--spacing--xl); /* było: 2rem */
  --space-2xl: var(--wp--preset--spacing--xxl); /* było: 3rem */
  --space-3xl: var(--wp--preset--spacing--xxxl); /* było: 4rem */
  --space-4xl: var(--wp--preset--spacing--xxxxl); /* było: 6rem */
  --space-5xl: var(--wp--preset--spacing--xxxxxl); /* było: 8rem */

  /* Layout */
  --container-max: var(--wp--style--global--content-size); /* było: 1200px */
  --container-padding: 1.5rem;
  --header-height: var(--wp--custom--header-height); /* było: 72px */

  /* Borders & Shadows */
  --radius-sm: var(--wp--custom--radius--sm); /* było: 6px */
  --radius-md: var(--wp--custom--radius--md); /* było: 10px */
  --radius-lg: var(--wp--custom--radius--lg); /* było: 14px */
  --radius-xl: var(--wp--custom--radius--xl); /* było: 20px */
  --radius-full: 9999px;

  --shadow-sm: var(--wp--preset--shadow--sm); /* było: 0 1px 2px rgba(0, 0, 0, 0.05) */
  --shadow-md: var(--wp--preset--shadow--md); /* było: 0 4px 12px rgba(0, 0, 0, 0.08) */
  --shadow-lg: var(--wp--preset--shadow--lg); /* było: 0 8px 30px rgba(0, 0, 0, 0.1) */
  --shadow-xl: var(--wp--preset--shadow--xl); /* było: 0 16px 50px rgba(0, 0, 0, 0.12) */

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 400ms ease;
}

/* === GENEROWANE (css-refactor.py): role spanowe jako akapity === */
.is-style-badge-strip-caption,
.is-style-badge-strip-item,
.is-style-coach-badge,
.is-style-coach-badge-secondary,
.is-style-coach-card-more,
.is-style-coach-initials,
.is-style-coach-year,
.is-style-coach-year-yellow,
.is-style-contact-office-badge,
.is-style-event-day,
.is-style-event-month,
.is-style-event-tag,
.is-style-event-tag-green,
.is-style-event-tag-red,
.is-style-event-year,
.is-style-fee-label,
.is-style-fee-note,
.is-style-fee-value,
.is-style-footer-krs-label,
.is-style-footer-krs-value,
.is-style-group-age,
.is-style-group-category,
.is-style-group-coach-label,
.is-style-group-coach-name,
.is-style-group-emblem-year,
.is-style-krs-banner-kicker,
.is-style-logo-name,
.is-style-map-caption-pin,
.is-style-map-caption-text,
.is-style-news-tag,
.is-style-number-label,
.is-style-number-value,
.is-style-offer-item-num,
.is-style-partner-type,
.is-style-recruitment-step-num,
.is-style-section-label,
.is-style-section-label-light,
.is-style-senior-team-badge,
.is-style-special-coach-name,
.is-style-special-coach-role,
.is-style-special-note,
.is-style-stat-label,
.is-style-stat-value,
.is-style-step-age,
.is-style-step-meta,
.is-style-step-number,
.is-style-training-day-name,
.is-style-training-day-time,
.is-style-trial-banner-kicker {
  color: inherit;
  display: initial;
  flex: initial;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  margin: 0;
  margin-bottom: 0;
  margin-left: 0;
  margin-right: 0;
  max-width: none;
  opacity: 1;
  text-transform: inherit;
}
/* === /GENEROWANE === */

/* ───────────────────────────────────────────
   RESET & BASE
   ─────────────────────────────────────────── */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Reset powyżej kasuje `margin: auto`,
które przeglądarka nadaje elementowi
   <dialog> — bez tego showModal() otwiera okno w lewym górnym rogu ekranu. */
dialog {
  margin: auto;
  max-height: calc(100vh - 2 * var(--space-xl));
  overflow: auto;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  color: var(--ink);
  background-color: var(--white);
  overflow-x: hidden;
}

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

/* The hidden attribute must win over component display rules (img,
flex boxes,
.btn) */
[hidden] {
  display: none !important;
}

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

a:hover {
  color: var(--club-green-dark);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--club-yellow);
  outline-offset: 2px;
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: var(--lh-tight);
  color: var(--ink);
}

/* ───────────────────────────────────────────
   LAYOUT UTILITIES
   ─────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.section {
  padding: var(--space-5xl) 0;
}

.section-header {
  margin-bottom: var(--space-3xl);
}

.section-header.centered {
  text-align: center;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: var(--space-3xl);
}

:is(:is(:is(.section-label,
.is-style-section-label,
.is-style-section-label-light),
.is-style-section-label,
.is-style-section-label-light),
.is-style-section-label,
.is-style-section-label-light) {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: var(--fs-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--club-green);
  margin-bottom: var(--space-md);
}

:is(:is(:is(.section-label-light,
.is-style-section-label-light),
.is-style-section-label-light),
.is-style-section-label-light) {
  color: var(--club-yellow);
}

:is(:is(:is(.section-title,
.is-style-section-title),
.is-style-section-title),
.is-style-section-title) {
  font-size: var(--fs-3xl);
  margin-bottom: var(--space-lg);
}

:is(:is(:is(.section-subtitle,
.is-style-section-subtitle),
.is-style-section-subtitle),
.is-style-section-subtitle) {
  font-size: var(--fs-md);
  color: var(--muted);
  line-height: var(--lh-relaxed);
  max-width: 640px;
  margin: 0 auto;
}

.section-cta {
  margin-top: var(--space-3xl);
}

.centered {
  text-align: center;
}

.text-yellow {
  color: var(--club-yellow);
}

/* ───────────────────────────────────────────
   BUTTONS
   ─────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: var(--fs-sm);
  line-height: 1;
  padding: 0.75rem 1.5rem;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  white-space: nowrap;
}

.btn-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.btn-lg {
  font-size: var(--fs-base);
  padding: 1rem 2rem;
  border-radius: var(--radius-lg);
}

/* Wyrównanie przycisku wstawionego ręcznie w edytorze.
   `.btn` jest `inline-flex`, więc nie ma czym go przesunąć: `text-align` rodzica
   działa tylko wtedy, gdy rodzic je ma (grupy nie mają takiej kontrolki), a auto
   marginesy nie działają na elemencie liniowym. `display: flex` czyni z przycisku
   element blokowy, `width: fit-content` zachowuje jego szerokość, a auto marginesy
   dopiero wtedy mają co rozdzielić. Układ wewnętrzny (ikona + tekst) bez zmian,
   bo `inline-flex` i `flex` różnią się tylko poziomem elementu. */
.btn-align-center {
  display: flex;
  width: fit-content;
  margin-inline: auto;
}

.btn-align-right {
  display: flex;
  width: fit-content;
  margin-inline-start: auto;
}

.btn-full {
  width: 100%;
}

/* Primary: yellow */
.btn-primary {
  background: var(--club-yellow);
  color: var(--ink);
  border-color: var(--club-yellow);
}

.btn-primary:hover {
  background: var(--club-yellow-dark);
  border-color: var(--club-yellow-dark);
  color: var(--ink);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(232, 185, 49, 0.35);
}

/* Outline: green border */
.btn-outline {
  background: transparent;
  color: var(--club-green);
  border-color: var(--club-green);
}

.btn-outline:hover {
  background: var(--club-green);
  color: var(--white);
  transform: translateY(-1px);
}

/* Outline light: white border for dark backgrounds */
.btn-outline-light {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-outline-light:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--white);
  color: var(--white);
}

/* ───────────────────────────────────────────
   CARDS (base styles)
   ─────────────────────────────────────────── */
.card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  border: 1px solid var(--border);
  transition: all var(--transition-base);
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

/* ───────────────────────────────────────────
   FORM ELEMENTS
   ─────────────────────────────────────────── */
.form-group {
  margin-bottom: var(--space-lg);
  flex: 1;
}

.form-label {
  display: block;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--ink);
  margin-bottom: var(--space-sm);
}

.form-optional {
  font-weight: 400;
  color: var(--muted);
}

.form-input {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  color: var(--ink);
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  appearance: none;
  -webkit-appearance: none;
}

.form-input::placeholder {
  color: var(--muted);
  opacity: 0.7;
}

.form-input:focus {
  border-color: var(--club-green);
  box-shadow: 0 0 0 3px rgba(15, 90, 60, 0.12);
  outline: none;
}

.form-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23667085' viewBox='0 0 16 16'%3E%3Cpath d='M8 12L2 6h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-row {
  display: flex;
  gap: var(--space-md);
}

:is(:is(:is(.form-disclaimer,
.is-style-form-disclaimer),
.is-style-form-disclaimer),
.is-style-form-disclaimer) {
  margin-top: var(--space-md);
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: var(--lh-relaxed);
}

.form-error {
  border-color: var(--club-red);
  box-shadow: 0 0 0 3px rgba(190, 47, 47, 0.12);
}

/* ───────────────────────────────────────────
   LOGO
   ─────────────────────────────────────────── */
.logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.logo-img {
  width: 44px;
  height: auto;
  border-radius: 50%;
  object-fit: cover;
}

:is(:is(:is(.logo-name,
.is-style-logo-name),
.is-style-logo-name),
.is-style-logo-name) {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: var(--fs-lg);
  color: var(--ink);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  white-space: nowrap;
}

.logo:hover {
  text-decoration: none;
}

/* ───────────────────────────────────────────
   SCROLL REVEAL ANIMATION
   ─────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ───────────────────────────────────────────
   BODY SCROLL LOCK (for mobile menu)
   ─────────────────────────────────────────── */
body.menu-open {
  overflow: hidden;
}
