/* I Bieg z taczką ziemniaków — LKS Raciążek
   Motyw: zieleń LKS + ciepłe złoto zachodu słońca i ziemniaków. */

:root {
  --czerwien: #2e7d32;  /* kolor główny (nazwa zmiennej z kodu Biegu Niepodległości) */
  --blad: #c62828;
  --ziemniak: #d9a441;
  --czerwien-ciemna: #1b5e20;
  --zloto: #c9ccd3;
  --zloto-jasne: #ffffff;
  --atrament: #1f2430;
  --szary: #5a6273;
  --szary-jasny: #8a92a6;
  --linia: #e6e8ec;
  --tlo: #f5f3ec;
  --bialy: #ffffff;
  --zielony: #1f8a4c;
  --zielony-tlo: #e8f6ee;
  --czerwony-tlo: #fdecef;
  --zolty-tlo: #fff8e6;
  --zolty-linia: #f0d68a;
  --cien: 0 2px 8px rgba(15, 22, 40, .08);
  --cien-mocny: 0 8px 24px rgba(15, 22, 40, .12);
  --promien: 12px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--tlo);
  color: var(--atrament);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--czerwien); }

/* ----------------------------------------------------------- Pasek */

.pasek {
  background: var(--czerwien);
  color: #fff;
  box-shadow: var(--cien);
  position: sticky;
  top: 0;
  z-index: 50;
}

.pasek-in {
  max-width: 1100px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.pasek-logo { text-decoration: none; color: #fff; display: block; }
.pasek-nazwa { display: block; font-weight: 700; font-size: 17px; line-height: 1.25; }
.pasek-pod { display: block; font-size: 13px; opacity: .88; }

.pasek-nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pasek-nav a {
  color: #fff;
  text-decoration: none;
  padding: 7px 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  transition: background .15s;
}
.pasek-nav a:hover { background: rgba(255, 255, 255, .16); }
.pasek-nav .btn-mini {
  background: #fff;
  color: var(--czerwien);
  font-weight: 700;
}
.pasek-nav .btn-mini:hover { background: var(--zolty-tlo); }

/* ---------------------------------------------------------- Treść */

.tresc { max-width: 1100px; margin: 0 auto; padding: 28px 20px 56px; }

.karta {
  background: var(--bialy);
  border-radius: var(--promien);
  box-shadow: var(--cien);
  padding: 28px;
  margin-bottom: 24px;
}

.karta h2 {
  margin: 0 0 18px;
  font-size: 21px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.karta h3 { margin: 24px 0 10px; font-size: 17px; }
.karta > :last-child { margin-bottom: 0; }

/* --------------------------------------------------------- Licznik */

.licznik {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.licznik-poz {
  flex: 1 1 150px;
  background: var(--bialy);
  border-radius: var(--promien);
  box-shadow: var(--cien);
  padding: 18px 20px;
  text-align: center;
}
.licznik-liczba { font-size: 30px; font-weight: 700; line-height: 1.1; color: var(--czerwien); }
.licznik-opis { font-size: 13px; color: var(--szary); margin-top: 4px; }

/* ------------------------------------------------------ Formularz */

.pola { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.pole { display: flex; flex-direction: column; gap: 6px; }
.pole.szerokie { grid-column: 1 / -1; }

.pole label { font-weight: 600; font-size: 14px; }
.pole .wymagane { color: var(--blad); }
.pole .podpowiedz { font-size: 13px; color: var(--szary-jasny); font-weight: 400; }

.pole input[type="text"],
.pole input[type="email"],
.pole input[type="tel"],
.pole input[type="password"],
.pole input[type="date"],
.pole input[type="number"],
.pole input[type="file"],
.pole select,
.pole textarea {
  padding: 11px 13px;
  border: 1.5px solid var(--linia);
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  background: #fff;
  color: var(--atrament);
  transition: border-color .15s, box-shadow .15s;
  width: 100%;
}
.pole input:focus, .pole select:focus, .pole textarea:focus {
  outline: none;
  border-color: var(--czerwien);
  box-shadow: 0 0 0 3px rgba(200, 16, 46, .12);
}
.pole.blad input, .pole.blad select { border-color: var(--blad); background: var(--czerwony-tlo); }
.pole .komunikat-bledu { font-size: 13px; color: var(--blad); font-weight: 600; }

.zgoda {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  background: var(--tlo);
  border: 1px solid var(--linia);
  border-radius: 8px;
  padding: 13px 15px;
  margin-bottom: 10px;
}
.zgoda input[type="checkbox"] { width: 19px; height: 19px; margin-top: 2px; flex-shrink: 0; accent-color: var(--czerwien); }
.zgoda label { font-size: 14px; font-weight: 400; line-height: 1.5; }
.zgoda.blad { border-color: var(--blad); background: var(--czerwony-tlo); }

/* -------------------------------------------------------- Przyciski */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border: none;
  border-radius: 9px;
  font-size: 16px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  transition: transform .1s, box-shadow .15s, background .15s;
}
.btn:active { transform: translateY(1px); }
.btn-glowny { background: var(--czerwien); color: #fff; box-shadow: 0 3px 10px rgba(46, 125, 50, .3); }
.btn-glowny:hover { background: var(--czerwien-ciemna); }
.btn-jasny { background: #fff; color: var(--czerwien); }
.btn-jasny:hover { background: var(--zolty-tlo); }
.btn-obwodka { background: transparent; border: 1.5px solid var(--linia); color: var(--atrament); }
.btn-obwodka:hover { border-color: var(--szary); }
.btn-zielony { background: var(--zielony); color: #fff; }
.btn-blok { width: 100%; }
.btn-maly { padding: 7px 14px; font-size: 14px; border-radius: 7px; }

/* --------------------------------------------------------- Alerty */

.alert {
  border-radius: 9px;
  padding: 15px 18px;
  margin-bottom: 20px;
  font-size: 15px;
  border: 1px solid transparent;
}
.alert > :first-child { margin-top: 0; }
.alert > :last-child { margin-bottom: 0; }
.alert-info    { background: #eef4fd; border-color: #c9dcf7; }
.alert-sukces  { background: var(--zielony-tlo); border-color: #b4e0c6; }
.alert-blad    { background: var(--czerwony-tlo); border-color: #f5c2cc; }
.alert-uwaga   { background: var(--zolty-tlo); border-color: var(--zolty-linia); }

/* -------------------------------------------------------- Tabele */

.tabela { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.tabela th {
  text-align: left;
  padding: 11px 12px;
  background: var(--tlo);
  border-bottom: 2px solid var(--linia);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--szary);
  white-space: nowrap;
}
.tabela td { padding: 11px 12px; border-bottom: 1px solid var(--linia); }
.tabela tbody tr:hover { background: #fafbfc; }
.tabela .liczba { text-align: right; font-variant-numeric: tabular-nums; }
.tabela .srodek { text-align: center; }

.przewijana { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* -------------------------------------------------------- Plakietki */

.plakietka {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
}


/* --------------------------------------------------------- Drobne */

.info-lista { list-style: none; padding: 0; margin: 0; }
.info-lista li { padding: 9px 0; border-bottom: 1px solid var(--linia); display: flex; gap: 10px; }
.info-lista li:last-child { border-bottom: none; }
.info-lista .etykieta { color: var(--szary); min-width: 120px; }


.siatka-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }

.szukajka { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; align-items: flex-end; }
.szukajka .pole { flex: 1 1 180px; }

.pusto { text-align: center; padding: 44px 20px; color: var(--szary-jasny); }

/* --------------------------------------------------------- Stopka */

.stopka { background: var(--atrament); color: #b8bec9; margin-top: 40px; }
.stopka-in {
  max-width: 1100px;
  margin: 0 auto;
  padding: 30px 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 26px;
  font-size: 13.5px;
}
.stopka strong { color: #fff; }
.stopka a { color: #b8bec9; }

/* ---------------------------------------------------- Telefon */

@media (max-width: 760px) {
  .pola { grid-template-columns: 1fr; }
  .siatka-2 { grid-template-columns: 1fr; }
  .karta { padding: 20px; }
  .pasek-in { padding: 10px 16px; }
  .tresc { padding: 18px 14px 40px; }
}

/* ----------------------------------------------------- Do druku */

@media print {
  .pasek, .stopka, .bez-druku, .btn { display: none !important; }
  body { background: #fff; }
  .karta { box-shadow: none; padding: 0; margin-bottom: 18px; }
  .tresc { max-width: none; padding: 0; }
  .tabela th { background: #eee !important; -webkit-print-color-adjust: exact; }
}

/* ======================================================= Bieg z taczką */

/* Hero: zdjęcie taczki na boisku o zachodzie, tekst na przyciemnieniu po lewej */
.hero {
  position: relative;
  border-radius: var(--promien);
  overflow: hidden;
  margin-bottom: 24px;
  box-shadow: var(--cien-mocny);
  min-height: 460px;
  display: flex;
  align-items: flex-end;
  background: #1d2a17;
}
.hero-tlo, .hero-tlo img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-tlo img { object-fit: cover; object-position: 30% 60%; }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(14,24,10,.88) 0%, rgba(14,24,10,.6) 45%, rgba(14,24,10,.05) 80%),
              linear-gradient(0deg, rgba(14,24,10,.6) 0%, transparent 45%);
}
.hero-tekst { position: relative; z-index: 1; padding: 40px 40px 36px; max-width: 640px; color: #fff; }
.hero-nr {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #1d2a17;
  background: var(--ziemniak);
  border-radius: 6px;
  padding: 3px 10px;
  margin-bottom: 14px;
}
.hero h1 {
  margin: 0;
  font-size: clamp(34px, 5.6vw, 58px);
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -.015em;
  text-shadow: 0 2px 18px rgba(0,0,0,.35);
}
.hero-miasto { font-size: 18px; font-weight: 700; color: #f3d48d; margin-top: 8px; }
.hero-fakty { display: flex; flex-direction: column; gap: 4px; font-size: 16px; margin-top: 18px; }
.hero-fakty strong { color: #f3d48d; }
.hero-akcje { margin-top: 22px; display: flex; gap: 10px; flex-wrap: wrap; }

.btn-jasny { background: var(--ziemniak); color: #1d2a17; font-weight: 800; }
.btn-jasny:hover { background: #e8b75a; }
.btn-przezroczysty { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.7); }
.btn-przezroczysty:hover { background: rgba(255,255,255,.12); }

.pasek-nav .btn-mini:hover { background: #e8f5e9; }

/* Karta nagród ze zdjęciem pucharu */
.nagroda { display: grid; grid-template-columns: minmax(220px, 380px) 1fr; gap: 28px; align-items: center; padding: 0; overflow: hidden;
  border: 2px solid var(--ziemniak); }
.nagroda img { width: 100%; height: 100%; min-height: 240px; object-fit: cover; display: block; }
.nagroda-tekst { padding: 24px 26px 24px 0; }
.nagroda-tekst h2 { margin-top: 6px; }
.nagroda-tag { font-size: 12.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #8a5a00; background: #fbecc8; border-radius: 6px; padding: 3px 10px; }

/* Kategorie */
.kategorie {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.kategorie li {
  background: #fff;
  border: 1px solid var(--linia);
  border-left: 4px solid var(--czerwien);
  border-radius: 8px;
  padding: 11px 13px;
  font-weight: 700;
}
.kategorie li span { display: block; font-weight: 400; font-size: 13px; color: var(--szary); }
.kategorie li.dorosli { border-left-color: var(--atrament); }

/* Pasek zapełnienia */
.postep { height: 12px; background: var(--linia); border-radius: 8px; overflow: hidden; margin-top: 10px; }
.postep > div { height: 100%; background: var(--czerwien); border-radius: 8px; }

/* Wiersze uczestników w formularzu */
.uczestnik {
  border: 1.5px solid var(--linia);
  border-radius: 10px;
  padding: 16px 16px 12px;
  margin-bottom: 12px;
  position: relative;
  background: #fff;
}
.uczestnik-naglowek { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.uczestnik-naglowek strong { font-size: 15px; }
.uczestnik .pola { grid-template-columns: 1fr 1fr 150px 150px; gap: 12px; }
.uczestnik .kat-podglad { font-size: 13px; color: var(--czerwien); font-weight: 700; min-height: 18px; margin-top: 6px; }
.btn-usun-wiersz {
  background: none; border: none; color: var(--szary); cursor: pointer; font-size: 14px; padding: 4px 8px; border-radius: 6px;
}
.btn-usun-wiersz:hover { background: var(--czerwony-tlo); color: var(--czerwien); }
.ukryte-pole { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Kod SMS */
.kod-pole input {
  font-size: 30px !important;
  letter-spacing: .4em;
  text-align: center;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  max-width: 280px;
  margin: 0 auto;
}
.kod-karta { max-width: 560px; margin: 0 auto 24px; text-align: center; }
.kod-karta .pole { align-items: center; }

/* Statusy */
.pl-potwierdzony     { background: var(--zielony-tlo); color: var(--zielony); }
.pl-niepotwierdzony  { background: var(--zolty-tlo); color: #8a6d1f; }
.pl-rezerwa          { background: #eef4fd; color: #2c5aa0; }
.pl-zrezygnowal      { background: #f0f1f3; color: var(--szary); }

.lista-osob { list-style: none; padding: 0; margin: 0 0 18px; }
.lista-osob li { padding: 10px 0; border-bottom: 1px solid var(--linia); display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }

@media (max-width: 760px) {
  .hero { min-height: 560px; }
  .hero::after { background: linear-gradient(0deg, rgba(14,24,10,.92) 0%, rgba(14,24,10,.7) 48%, rgba(14,24,10,.05) 78%); }
  .hero-tekst { padding: 24px 20px 24px; }
  .nagroda { grid-template-columns: 1fr; gap: 0; }
  .nagroda img { min-height: 0; aspect-ratio: 16 / 9; }
  .nagroda-tekst { padding: 20px; }
  .uczestnik .pola { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 420px) {
  .uczestnik .pola { grid-template-columns: 1fr; }
}
