/* ==========================================================================
   marekujcik.cz — statická verze
   Fonty: Bebas Neue (nadpisy), Roboto (text), Open Sans (patička)
   Písma jsou na vlastním serveru (assets/fonts), nic se nenačítá z Googlu.
   ========================================================================== */

@font-face {
  font-family: "Bebas Neue";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/bebas-neue-400.woff2") format("woff2");
}

@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/roboto-400.woff2") format("woff2");
}

@font-face {
  font-family: "Open Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/open-sans-400.woff2") format("woff2");
}

@font-face {
  font-family: "Open Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/open-sans-600.woff2") format("woff2");
}

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

:root {
  --barva-text: #3d4144;
  --barva-nadpis: #000;
  --barva-tlumena: #8a8f93;
  --barva-linka: rgba(155, 155, 155, 1);
  --barva-pozadi: #fff;
  --barva-sede: #e9e9e9;
  --sirka: 1140px;
  --hlavicka-v: 92px;
}

html { scroll-behavior: smooth; scroll-padding-top: var(--hlavicka-v); }

body {
  margin: 0;
  background: var(--barva-pozadi);
  color: var(--barva-text);
  font-family: "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  font-size: 15px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4, h5 {
  font-family: "Bebas Neue", "Segoe UI", Impact, sans-serif;
  font-weight: 400;
  color: var(--barva-nadpis);
  line-height: 1.1;
  letter-spacing: .02em;
  margin: 0 0 20px;
}
h1 { font-size: 50px; }
h2 { font-size: 45px; }
h3 { font-size: 35px; }
h5 { font-size: 24px; }
p  { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

.obal { width: 100%; max-width: var(--sirka); margin: 0 auto; padding: 0 24px; }
.stred { text-align: center; }
.skryto-vizualne {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* ---------- Hlavička ---------- */

.hlavicka {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid rgba(0, 0, 0, .06);
}
.hlavicka__obal {
  max-width: var(--sirka); margin: 0 auto; padding: 0 24px;
  min-height: var(--hlavicka-v);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.logo img { width: 210px; }

.navigace ul {
  list-style: none; margin: 0; padding: 0;
  display: flex; align-items: center; gap: 4px;
}
.navigace a {
  display: inline-block; padding: 10px 18px;
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--barva-text); position: relative;
}
.navigace a::after {
  content: ""; position: absolute; left: 18px; right: 18px; bottom: 4px;
  height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: center; transition: transform .25s ease;
}
.navigace a:hover::after,
.navigace a[aria-current]::after { transform: scaleX(1); }

.prepinac {
  display: none; width: 44px; height: 44px; padding: 0;
  background: none; border: 0; cursor: pointer;
}
.prepinac span {
  display: block; width: 24px; height: 1px; margin: 6px auto;
  background: var(--barva-text); transition: transform .25s ease, opacity .2s ease;
}
.prepinac[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.prepinac[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.prepinac[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Sekce ---------- */

.sekce { padding: 70px 0; }
.sekce--uvod { padding: 0; }
.sekce--temata {
  padding: 60px 0 70px;
  background: var(--barva-sede);
}
.sekce--citat { padding: 60px 0; border-top: 1px solid #f3f3f3; }
.sekce--kontakt { background: var(--barva-sede); }

/* Úvodní fotografie */
.uvod-foto img { width: 100%; }

/* O mně */
.o-mne { display: grid; grid-template-columns: 2fr 1fr; gap: 48px; align-items: center; }
.o-mne__text { max-width: 62ch; }
.o-mne__text p { font-size: 16px; }

/* Oblíbená témata */
.temata {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 30px; margin-top: 44px;
}
/* Dlaždice je jedna karta — fotka a její popis drží pohromadě */
.tema {
  border: 1px solid rgba(0, 0, 0, .1);
  background: #f8f8f8;
}
.tema__obrazek {
  display: block; overflow: hidden; background: #ececec;
  aspect-ratio: 3 / 2;
}
.tema__obrazek img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .8s cubic-bezier(.2, .7, .3, 1);
}
.tema:hover .tema__obrazek img { transform: scale(1.06); }
.tlacitko {
  display: block; padding: 22px 20px;
  text-align: center; color: #55595c;
  border-top: 1px solid rgba(0, 0, 0, .1);
  font-family: "Open Sans", sans-serif; font-weight: 600;
  font-size: 12px; letter-spacing: .18em; text-transform: uppercase;
  transition: background-color .25s ease, color .25s ease;
}
.tema:hover .tlacitko,
.tlacitko:hover { background: #000; color: #fff; }

/* Citát */
.citat blockquote {
  position: relative;
  margin: 0;
  padding-left: 80px;
  min-height: 64px;
}
.citat blockquote::before {
  content: "\201D";
  position: absolute;
  top: 2px;
  left: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 140px;
  line-height: 0.62;
  color: #dfdfdf;
}
.citat h3 { font-size: 64px; margin-bottom: 10px; }
.citat__autor {
  text-align: right; font-size: 15px; color: var(--barva-tlumena);
  font-family: "Roboto", sans-serif;
}

/* ---------- Galerie ---------- */

.galerie-hlavicka { padding: 56px 0 28px; text-align: center; }
.galerie-hlavicka h1 { margin-bottom: 6px; }
.galerie-hlavicka p {
  font-size: 12px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--barva-tlumena);
}
.zpet {
  display: inline-block; margin-top: 18px;
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  border-bottom: 1px solid var(--barva-linka); padding-bottom: 3px;
}
.zpet:hover { border-color: #000; color: #000; }

/* Zděné rozvržení — zachovává původní poměry stran fotografií */
.mrizka { column-count: 3; column-gap: 16px; padding-bottom: 70px; }
.mrizka a {
  display: block; overflow: hidden; background: #ececec;
  margin: 0 0 16px; break-inside: avoid; cursor: zoom-in;
}
.mrizka img {
  width: 100%; height: auto; display: block;
  transition: transform .8s cubic-bezier(.2, .7, .3, 1), opacity .4s ease;
}
.mrizka a:hover img { transform: scale(1.05); }

/* ---------- Lightbox ---------- */

.lightbox {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(12, 12, 12, .96);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s;
}
.lightbox[open], .lightbox.je-videt { opacity: 1; visibility: visible; }
.lightbox img {
  max-width: 92vw; max-height: 86vh; width: auto; height: auto;
  object-fit: contain;
}
.lightbox__ovladac {
  position: absolute; background: none; border: 0; cursor: pointer;
  color: #fff; opacity: .65; padding: 16px; line-height: 0;
  transition: opacity .2s ease;
}
.lightbox__ovladac:hover { opacity: 1; }
.lightbox__zavrit { top: 8px; right: 12px; font-size: 34px; line-height: 1; }
.lightbox__predchozi { left: 4px; top: 50%; transform: translateY(-50%); }
.lightbox__dalsi { right: 4px; top: 50%; transform: translateY(-50%); }
.lightbox__pocitadlo {
  position: absolute; top: 20px; left: 24px; color: #fff; opacity: .6;
  font-size: 12px; letter-spacing: .14em;
}
body.lightbox-otevren { overflow: hidden; }

/* ---------- Patička ---------- */

.paticka {
  font-family: "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
}
/* Kontaktní údaje na šedé, spodní řádek s copyrightem na bílé */
.paticka__kontakt { background: var(--barva-sede); padding: 54px 0 46px; }
.paticka__copyright { background: var(--barva-pozadi); padding: 24px 0; }
.paticka__mrizka {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 32px; align-items: start;
}
.paticka h2 {
  font-family: "Open Sans", sans-serif; font-weight: 600;
  font-size: 12px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--barva-text); margin-bottom: 10px;
}
.paticka a:hover { color: #000; }
.paticka__znacka img { width: 150px; }
.socialni { display: flex; gap: 14px; align-items: center; }
.socialni a { color: var(--barva-text); opacity: .8; line-height: 0; }
.socialni a:hover { opacity: 1; }
.socialni svg { width: 20px; height: 20px; fill: currentColor; }

.paticka__spodek {
  margin: 0;
  font-size: 13px; color: var(--barva-tlumena); text-align: center;
  font-family: "Roboto", sans-serif;
}

/* ---------- Nahoru ---------- */

.nahoru {
  position: fixed; right: 22px; bottom: 22px; z-index: 90;
  width: 44px; height: 44px; display: grid; place-items: center;
  background: rgba(0, 0, 0, .72); color: #fff; border: 0; cursor: pointer;
  opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s;
}
.nahoru.je-videt { opacity: 1; visibility: visible; }
.nahoru:hover { background: #000; }
.nahoru svg { width: 16px; height: 16px; fill: currentColor; }

/* ---------- Responzivita ---------- */

@media (max-width: 900px) {
  :root { --hlavicka-v: 76px; }
  .prepinac { display: block; }
  .logo img { width: 170px; }

  .navigace {
    position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid rgba(0, 0, 0, .08);
    display: none;
  }
  .navigace.je-otevrena { display: block; }
  .navigace ul { flex-direction: column; align-items: stretch; gap: 0; padding: 8px 0; }
  .navigace a { padding: 14px 24px; font-size: 13px; }
  .navigace a::after { display: none; }

  .o-mne { grid-template-columns: 1fr; gap: 32px; }
  .o-mne__foto { max-width: 340px; margin: 0 auto; }
  .temata { grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .mrizka { column-count: 2; }
  .paticka__mrizka { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  h1 { font-size: 40px; } h2 { font-size: 36px; } h3 { font-size: 28px; }
  .citat h3 { font-size: 44px; }
}

@media (max-width: 560px) {
  .sekce { padding: 48px 0; }
  .temata { grid-template-columns: 1fr; }
  .mrizka { column-count: 1; }
  .paticka__mrizka { grid-template-columns: 1fr; text-align: left; }
  .citat__autor { text-align: left; }
  .citat blockquote { padding-left: 52px; min-height: 44px; }
  .citat blockquote::before { font-size: 92px; }
  .citat h3 { font-size: 30px; }
  .lightbox__predchozi, .lightbox__dalsi { padding: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
