/* =========================================================
   Ergoterapie Poděbrady – styly
   Barvy jsou jako proměnné nahoře; tmavý režim je níž.
   ========================================================= */

/* ---------- Písma (hostovaná lokálně, licence OFL ve složce fonts/) ---------- */
@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-display: swap;
  font-weight: 300 900;
  src: url("../fonts/figtree-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-display: swap;
  font-weight: 300 900;
  src: url("../fonts/figtree-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url("../fonts/bricolage-grotesque-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url("../fonts/bricolage-grotesque-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Barvy: světlý režim (výchozí) ---------- */
:root {
  --red: #AC3931;
  --sage: #7CA982;
  --yellow: #FDB833;
  --olive: #373D20;

  --bg: #FAF7F0;
  --surface: #FFFFFF;
  --band: #E9EFE6;
  --text: #373D20;
  --muted: #5B6142;
  --line: #E2DDCF;
  --link: #AC3931;
  --icon-sage: #5E8A65;
  --icon-yellow: #C98A0E;
  --input-bg: #FFFFFF;
  --input-line: #9AA08A;
  --placeholder-line: #B8BCA8;
  --focus: #373D20;
  --blob-opacity: 0.55;

  --font-body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Bricolage Grotesque", "Figtree", system-ui, sans-serif;
  --radius-lg: 28px;
  --radius-md: 24px;
  --radius-sm: 12px;
  --gutter: clamp(16px, 4vw, 40px);
  --section-y: clamp(56px, 8vw, 104px);

  color-scheme: light;
}

/* ---------- Barvy: tmavý režim ----------
   1) podle nastavení zařízení, pokud si návštěvník nevybral ručně
   2) ruční volba přes přepínač (data-theme="dark") */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1E2112;
    --surface: #2F3420;
    --band: #252A19;
    --text: #F2EFE6;
    --muted: #C9C6B3;
    --line: #3B412D;
    --link: #7CA982;
    --icon-sage: #7CA982;
    --icon-yellow: #FDB833;
    --input-bg: #1E2112;
    --input-line: #6B7259;
    --placeholder-line: #5A604A;
    --focus: #FDB833;
    --blob-opacity: 0.35;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #1E2112;
  --surface: #2F3420;
  --band: #252A19;
  --text: #F2EFE6;
  --muted: #C9C6B3;
  --line: #3B412D;
  --link: #7CA982;
  --icon-sage: #7CA982;
  --icon-yellow: #FDB833;
  --input-bg: #1E2112;
  --input-line: #6B7259;
  --placeholder-line: #5A604A;
  --focus: #FDB833;
  --blob-opacity: 0.35;
  color-scheme: dark;
}

/* ---------- Základ ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 16px;
  -webkit-text-size-adjust: 100%;
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.6;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }
picture { display: block; }
a { color: var(--link); }
p { margin: 0 0 16px; }
p:last-child { margin-bottom: 0; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  margin: 0;
}
h1 {
  font-size: clamp(42px, 6vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}
h2 {
  font-size: clamp(32px, 4vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin-bottom: 20px;
}
h3 {
  font-size: 23px;
  line-height: 1.25;
  margin: 14px 0 8px;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

.muted { color: var(--muted); }
.small { font-size: 15px; }

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 10;
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-weight: 600;
}
.skip-link:focus { top: 16px; }

/* ---------- Rozvržení ---------- */
.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Sloupce se zalamují pod sebe bez media queries */
.split {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 40px 64px;
}
.split-top { align-items: flex-start; }
.split > * { min-width: 0; }
.col-wide { flex: 999 1 480px; }
.col-narrow { flex: 1 1 300px; }
.col-half { flex: 1 1 380px; }

.section { padding: var(--section-y) 0; }
.section-rule { border-top: 1px solid var(--line); }
.section-band { background: var(--band); }
.intro { margin-bottom: 28px; }

/* ---------- Hlavička ---------- */
.site-header { border-bottom: 1px solid var(--line); }
.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 32px;
  padding-top: 18px;
  padding-bottom: 18px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  text-decoration: none;
}
.brand-mark { flex: 0 0 auto; }
.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 21px;
  line-height: 1.15;
}
.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 26px;
  font-weight: 500;
  font-size: 17px;
}
.site-nav a {
  color: var(--text);
  text-decoration: none;
  padding: 10px 0;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}
.site-nav a:hover { text-decoration: underline; text-decoration-color: var(--yellow); }

.theme-toggle {
  width: 44px;
  height: 44px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  cursor: pointer;
}
.theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}

/* ---------- Úvod ---------- */
.hero { padding: clamp(48px, 7vw, 96px) 0 var(--section-y); }
.hero .split { gap: 48px 64px; }
.hero-text { flex: 1 1 420px; }
.hero-media { flex: 1 1 380px; position: relative; }
.eyebrow {
  margin-bottom: 16px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.highlight {
  text-decoration: underline;
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 0.12em;
  text-underline-offset: 0.12em;
}
.lead {
  font-size: 20px;
  color: var(--muted);
  max-width: 34em;
  margin-bottom: 32px;
}
.lead-sm { font-size: 20px; }
.hero-blob {
  position: absolute;
  right: -14px;
  bottom: -14px;
  width: 70%;
  height: 70%;
  border-radius: var(--radius-lg);
  background: var(--sage);
  opacity: var(--blob-opacity);
}
.hero-media img {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-lg);
}

/* ---------- Tlačítka ---------- */
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 26px;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}
.btn-primary {
  background: var(--red);
  color: #FFFFFF;
  border: 0;
}
.btn-primary:hover { background: #962F28; }
.btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--text);
}
.btn-secondary:hover { background: var(--surface); }

/* ---------- Fotky ---------- */
.photo { width: 100%; object-fit: cover; border-radius: var(--radius-lg); }
.photo-portrait { aspect-ratio: 4 / 5; }
.photo-wide { aspect-ratio: 16 / 9; }

/* ---------- Pro koho ---------- */
.target-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.target-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 18px;
  border-radius: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.dot {
  flex: 0 0 auto;
  width: 12px;
  height: 12px;
  margin-top: 9px;
  border-radius: 6px;
}
.dot-sage { background: var(--sage); }
.dot-red { background: var(--red); }
.dot-yellow { background: var(--yellow); }

/* ---------- Karty ---------- */
.card {
  padding: 28px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: var(--surface);
}
.card-plain {
  border: 0;
  border-radius: var(--radius-lg);
  padding: clamp(24px, 3vw, 40px);
}
.card-plain h3 { font-size: 26px; margin: 16px 0 12px; }
.cards {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}
.cards > .card { flex: 1 1 280px; min-width: 0; }
#jak-pracuji h2 { margin-bottom: 36px; }

.icon { display: block; flex: 0 0 auto; }
.icon-sage { color: var(--icon-sage); }
.icon-red { color: var(--red); }
.icon-yellow { color: var(--icon-yellow); }
.icon-link { color: var(--link); }

/* ---------- Citát ---------- */
.quote-row { margin-top: clamp(40px, 6vw, 72px); gap: 32px 56px; }
.quote-row > picture { flex: 1 1 480px; min-width: 0; }
.quote { flex: 1 1 320px; margin: 0; }
.quote blockquote {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1.3;
}
.quote figcaption {
  margin-top: 16px;
  color: var(--muted);
  font-weight: 500;
}

/* ---------- O mně ---------- */
.about-photo { max-width: 420px; }
.placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  border: 2px dashed var(--placeholder-line);
  border-radius: var(--radius-lg);
  color: var(--muted);
  font-weight: 500;
  text-align: center;
}
.placeholder-portrait { aspect-ratio: 4 / 5; background: var(--surface); }
.placeholder-map { aspect-ratio: 16 / 9; border-radius: var(--radius-md); }

.edu-list, .contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}
.edu-list { gap: 12px; margin-top: 28px; }
.edu-list li, .contact-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.edu-list .icon, .contact-list .icon { margin-top: 2px; }
.edu-list strong { font-weight: 600; }
.contact-list { gap: 16px; margin-bottom: 28px; }

/* ---------- Formulář ---------- */
.contact-form {
  padding: clamp(24px, 3vw, 40px);
  border-radius: var(--radius-lg);
  background: var(--band);
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-row { display: flex; flex-wrap: wrap; gap: 18px; }
.field-row > .field { flex: 1 1 200px; }
.field label { font-weight: 600; font-size: 16px; }
.optional { font-weight: 400; color: var(--muted); }
.field input, .field textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--input-line);
  background: var(--input-bg);
  color: var(--text);
  font: inherit;
}
.field textarea { resize: vertical; }
.contact-form .btn { align-self: flex-start; padding: 0 32px; }
.form-status:empty { display: none; }
.form-status { font-weight: 600; }
.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---------- Patička ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 32px 0 40px;
  font-size: 15px;
  color: var(--muted);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
}
.footer-inner p { margin: 0; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }

/* ---------- Úzké displeje ---------- */
@media (max-width: 700px) {
  /* Fotky na výšku by na mobilu zabraly celou obrazovku */
  .photo-portrait,
  .placeholder-portrait { aspect-ratio: 4 / 3; }
  .about-photo { max-width: none; }
  .hero-blob { right: -8px; bottom: -8px; }
  .site-nav { gap: 0 20px; font-size: 16px; }
}

/* Portrét terapeutky: při ořezu na 4:3 (mobil) držet obličej v záběru */
.photo-face { object-position: 50% 28%; }

/* ---------- Textové stránky (zásady, 404) ---------- */
.prose { max-width: 46rem; }
.prose h1 { font-size: clamp(36px, 5vw, 56px); }
.prose h2 {
  font-size: clamp(26px, 3vw, 32px);
  margin: 48px 0 16px;
}
.prose h3 { font-size: 21px; margin: 28px 0 10px; }
.prose ul { margin: 0 0 16px; padding-left: 1.25em; }
.prose li { margin-bottom: 8px; }
.prose li::marker { color: var(--icon-sage); }
.prose .lead { margin-bottom: 16px; }
@media (max-width: 700px) {
  .photo-face { aspect-ratio: 1 / 1; object-position: 50% 30%; }
}

/* Tabulky v textových stránkách – na úzkém displeji se posouvají do strany */
.table-wrap { overflow-x: auto; margin: 0 0 16px; }
.prose table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: 16px;
  line-height: 1.5;
}
.prose th, .prose td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}
.prose th { font-weight: 600; background: var(--band); }
