/* ============================================================
   FC AJAX BEZMĚROV — Shared Styles
   Sdílené styly napříč celým webem (homepage + týmy + článek)
   ============================================================ */

/* Skrytí prvku musí přebít i .trida { display: flex }.
   Bez !important zůstal blok schovaný přes [hidden] pořád vidět. */
[hidden] { display: none !important; }

/* === DESIGN TOKENS === */
:root {
  --yellow: #f4ce0e;
  --yellow-soft: #fde35a;
  --green: #1c5a28;
  --green-deep: #0e3818;
  --green-light: #2a8a3e;
  --paper: #faf9f4;
  --white: #ffffff;
  --ink: #0f1a12;
  --ink-soft: #3a4640;
  --ink-faded: #7a8580;
  --line: #e5e3da;
  --line-strong: #d4d2c5;
  --error: #c8462f;
  --warning: #c9a73f;
  --success: #2a8a3e;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
::selection { background: var(--yellow); color: var(--green-deep); }

/* === ANIMACE === */
@keyframes fadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes pulseDot { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.3); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .8s cubic-bezier(0.22,1,0.36,1), transform .8s cubic-bezier(0.22,1,0.36,1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

.reveal-stagger > * {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .7s cubic-bezier(0.22,1,0.36,1), transform .7s cubic-bezier(0.22,1,0.36,1);
}
.reveal-stagger.visible > *:nth-child(1) { transition-delay: 0s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(2) { transition-delay: 0.05s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(3) { transition-delay: 0.10s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(4) { transition-delay: 0.15s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(5) { transition-delay: 0.20s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(6) { transition-delay: 0.25s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(7) { transition-delay: 0.30s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(8) { transition-delay: 0.35s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(9) { transition-delay: 0.40s; opacity: 1; transform: translateY(0); }
.reveal-stagger.visible > *:nth-child(n+10) { opacity: 1; transform: translateY(0); }

/* === SITE HEADER === */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 249, 244, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  transition: background .2s, border-color .2s;
}
.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 16px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo {
  display: flex; align-items: center; gap: 12px;
  flex-shrink: 0;
}
.logo img { width: 44px; height: 44px; }
.logo .name {
  font-family: 'Fraunces', serif;
  font-weight: 800;
  font-size: 18px;
  line-height: 1;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.logo small {
  display: block;
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  letter-spacing: 0.18em;
  color: var(--ink-faded);
  margin-top: 4px;
  text-transform: uppercase;
}
.site-header nav ul {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}
.site-header nav a {
  display: inline-block;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-soft);
  border-radius: 8px;
  transition: background .2s, color .2s;
}
.site-header nav a:hover {
  background: var(--white);
  color: var(--ink);
}
.site-header nav a.nav-cta {
  background: var(--green);
  color: var(--paper);
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 999px;
  margin-left: 8px;
}
.site-header nav a.nav-cta:hover {
  background: var(--green-deep);
  color: var(--paper);
}

/* MOBILE MENU BTN */
/* HAMBURGER MENU BUTTON */
.menu-btn {
  display: none;
  width: 44px; height: 44px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
  padding: 0;
  position: relative;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}
.menu-btn span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .25s ease, opacity .25s ease;
}
/* Animace hamburger -> X */
.menu-btn.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.menu-btn.active span:nth-child(2) {
  opacity: 0;
}
.menu-btn.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 960px) {
  .site-header nav {
    position: fixed;
    top: 76px; left: 0; right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 16px 24px;
    /* Menu se schovává nahoru nad obrazovku. Posun musí být o vlastní
       výšku PLUS těch 76px odsazení odshora — jinak spodní okraj (tlačítko
       E-shop) vykoukne přes hlavičku. Procenta samotná nestačí, protože
       se počítají jen z výšky menu, a ta se mění podle počtu položek. */
    transform: translateY(calc(-100% - 76px));
    transition: transform .3s ease;
    box-shadow: 0 10px 40px rgba(15,26,18,0.1);
    max-height: calc(100vh - 76px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .site-header nav.open { transform: translateY(0); }
  .site-header nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }
  .site-header nav a {
    padding: 14px 16px !important;
    font-size: 15px;
    min-height: 48px;
    display: flex !important;
    align-items: center;
  }
  .menu-btn { display: flex !important; }
}

/* === BUTTONS === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  border-radius: 999px;
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: background .2s, transform .2s, box-shadow .2s, border-color .2s;
  white-space: nowrap;
}
.btn-primary {
  background: var(--green);
  color: var(--paper);
}
.btn-primary:hover {
  background: var(--green-deep);
  transform: translateY(-1px);
  box-shadow: 0 8px 16px -4px rgba(28,90,40,0.4);
}
.btn-ghost {
  background: var(--white);
  color: var(--ink);
  border: 1px solid var(--line-strong);
}
.btn-ghost:hover { border-color: var(--ink); }
.btn-yellow { background: var(--yellow); color: var(--green-deep); }
.btn-yellow:hover { background: var(--yellow-soft); }
.btn-arrow { transition: transform .2s; display: inline-block; }
.btn:hover .btn-arrow { transform: translateX(4px); }

/* === SECTION EYEBROW === */
.section-eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--green);
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 12px;
}

/* === BREADCRUMB === */
.breadcrumb {
  max-width: 1280px;
  margin: 24px auto 0;
  padding: 0 32px;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--ink-faded);
  text-transform: uppercase;
}
.breadcrumb a {
  color: var(--ink-faded);
  border-bottom: 1px solid transparent;
  transition: color .2s, border-color .2s;
}
.breadcrumb a:hover {
  color: var(--green);
  border-bottom-color: currentColor;
}
.breadcrumb span {
  margin: 0 10px;
  color: var(--line-strong);
}

/* === FOOTER === */
footer {
  /* Stejně jako na titulce, stránce týmu a článku — dřív tu byla zelená
     a patička měla na každé stránce jinou barvu. */
  background: var(--ink);
  color: var(--paper);
  padding: 80px 32px 32px;
  margin-top: 80px;
  position: relative;
  overflow: hidden;
}
footer::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--green), var(--yellow), var(--green));
}
.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
}
footer h4 {
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: 17px;
  margin-bottom: 14px;
  color: var(--yellow);
}
footer p {
  font-size: 14px;
  color: rgba(250, 249, 244, 0.75);
  line-height: 1.6;
}
footer p a, footer ul a {
  color: rgba(250, 249, 244, 0.75);
  transition: color .2s;
}
footer p a:hover, footer ul a:hover { color: var(--yellow); }
footer ul {
  list-style: none;
}
footer ul li {
  margin-bottom: 8px;
  font-size: 14px;
}
.footer-logo {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 20px;
}
.footer-logo img {
  width: 56px; height: 56px;
}
.footer-logo .name {
  font-family: 'Fraunces', serif;
  font-weight: 800;
  font-size: 18px;
  color: var(--paper);
  line-height: 1;
}
.footer-logo small {
  display: block;
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  letter-spacing: 0.18em;
  color: var(--yellow);
  margin-top: 4px;
  text-transform: uppercase;
}
.footer-bottom {
  max-width: 1280px;
  margin: 48px auto 0;
  padding-top: 24px;
  border-top: 1px solid rgba(250, 249, 244, 0.1);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: rgba(250, 249, 244, 0.5);
  text-transform: uppercase;
}
.footer-bottom a {
  color: rgba(250, 249, 244, 0.5);
  transition: color .2s;
}
.footer-bottom a:hover { color: var(--yellow); }

@media (max-width: 880px) {
  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }
}
@media (max-width: 540px) {
  .footer-inner { grid-template-columns: 1fr; gap: 32px; }
  .header-inner { padding: 14px 20px; }
}

/* === HIDDEN ADMIN ACCESS === */
.admin-access {
  display: inline-block;
  font-size: 10px;
  font-family: 'DM Mono', monospace;
  letter-spacing: 0.12em;
  color: rgba(250, 249, 244, 0.3);
  border: 1px solid rgba(250, 249, 244, 0.15);
  padding: 6px 12px;
  border-radius: 6px;
  transition: all .2s;
  text-transform: uppercase;
}
.admin-access:hover {
  color: var(--yellow);
  border-color: var(--yellow);
}

/* ============================================================
   VYLEPŠENÝ MOBILE MENU (lepší overlay, blokace scroll)
   ============================================================ */
body.menu-open {
  overflow: hidden;
}

/* Lepší backdrop a animace pro mobilní menu */
@media (max-width: 960px) {
  .site-header nav {
    max-height: calc(100vh - 76px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  /* Větší klik plocha na mobilu */
  .site-header nav a {
    min-height: 48px;
    display: flex !important;
    align-items: center;
  }
  .menu-btn {
    width: 44px;
    height: 44px;
  }
}

/* ============================================================
   PWA "PŘIDAT NA PLOCHU" — Tlačítko a iOS install dialog
   ============================================================ */
.install-app-btn {
  display: none;  /* JS to ukáže když je install dostupný */
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--yellow);
  color: var(--green-deep);
  border-radius: 999px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all .2s;
  text-decoration: none;
}
.install-app-btn:hover {
  background: var(--yellow-soft);
  transform: translateY(-1px);
  box-shadow: 0 8px 16px -4px rgba(244, 206, 14, 0.5);
}
.install-app-btn svg {
  width: 16px;
  height: 16px;
}

/* iOS Install Dialog */
.ios-install-dialog {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s;
}
.ios-install-dialog.show {
  opacity: 1;
  pointer-events: auto;
}
.iid-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 26, 18, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.iid-card {
  position: relative;
  background: var(--paper);
  border-radius: 24px;
  padding: 32px 28px;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
  transform: translateY(20px);
  transition: transform .3s;
}
.ios-install-dialog.show .iid-card {
  transform: translateY(0);
}
.iid-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  background: transparent;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  color: var(--ink-soft);
  transition: background .2s;
}
.iid-close:hover {
  background: var(--line);
}
.iid-icon {
  font-size: 48px;
  margin-bottom: 12px;
}
.iid-card h3 {
  font-family: 'Fraunces', serif;
  font-weight: 800;
  font-size: 26px;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}
.iid-card p {
  color: var(--ink-soft);
  font-size: 15px;
  margin-bottom: 18px;
}
.iid-card ol {
  margin: 0 0 24px 20px;
  padding: 0;
  color: var(--ink);
}
.iid-card ol li {
  margin-bottom: 10px;
  font-size: 14px;
  line-height: 1.5;
}
.iid-card ol li strong {
  color: var(--green-deep);
}
.iid-ok {
  width: 100%;
  padding: 14px;
  background: var(--green);
  color: var(--paper);
  border: none;
  border-radius: 12px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s;
}
.iid-ok:hover {
  background: var(--green-deep);
}

/* ============================================================
   NÁBOROVÝ PRUH NAHOŘE (recruit-banner)
   Hned pod hlavičkou, výrazně viditelný
   ============================================================ */
.recruit-banner {
  background: linear-gradient(135deg, var(--green-deep) 0%, var(--green) 50%, var(--green-deep) 100%);
  background-size: 200% 100%;
  color: var(--paper);
  padding: 16px 24px;
  border-bottom: 3px solid var(--yellow);
  position: relative;
  overflow: hidden;
  animation: gradientShift 12s ease infinite;
}
@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}
.recruit-banner::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at top right, rgba(244, 206, 14, 0.18), transparent 60%);
  pointer-events: none;
}
.rb-inner {
  position: relative;
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.rb-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--yellow);
  color: var(--green-deep);
  padding: 6px 14px;
  border-radius: 999px;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(244, 206, 14, 0.4);
}
.rb-dot {
  width: 8px;
  height: 8px;
  background: var(--green-deep);
  border-radius: 50%;
  animation: pulseDot 1.5s infinite;
}
.rb-message {
  flex: 1;
  min-width: 200px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.rb-message strong {
  font-family: 'Fraunces', serif;
  font-weight: 700;
  font-size: 17px;
  color: var(--paper);
  letter-spacing: -0.01em;
}
.rb-message .rb-detail {
  font-size: 13px;
  color: rgba(250, 249, 244, 0.75);
  line-height: 1.3;
}
.rb-contacts {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.rb-contact {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  background: rgba(250, 249, 244, 0.08);
  border: 1px solid rgba(244, 206, 14, 0.3);
  border-radius: 10px;
  color: var(--paper);
  font-size: 13px;
  transition: all .2s;
}
.rb-contact:hover {
  background: rgba(244, 206, 14, 0.15);
  border-color: var(--yellow);
  transform: translateY(-1px);
  color: var(--paper);
}
.rb-contact svg {
  width: 16px;
  height: 16px;
  color: var(--yellow);
  flex-shrink: 0;
}
.rb-contact span {
  display: flex;
  flex-direction: column;
  gap: 1px;
  line-height: 1.1;
}
.rb-contact strong {
  font-size: 12px;
  font-weight: 600;
  color: rgba(250, 249, 244, 0.75);
}
.rb-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: var(--yellow);
  color: var(--green-deep);
  border-radius: 999px;
  font-weight: 700;
  font-size: 13px;
  transition: all .2s;
  white-space: nowrap;
}
.rb-cta:hover {
  background: var(--yellow-soft);
  color: var(--green-deep);
  transform: translateY(-1px);
  box-shadow: 0 6px 14px -2px rgba(244, 206, 14, 0.5);
}
.rb-cta svg {
  width: 14px;
  height: 14px;
}

/* Mobilní layout */
@media (max-width: 880px) {
  .recruit-banner { padding: 14px 16px; }
  .rb-inner { gap: 12px; }
  .rb-message strong { font-size: 15px; }
  .rb-message .rb-detail { font-size: 12px; }
  .rb-contacts { width: 100%; }
  .rb-contact { flex: 1; padding: 8px 12px; }
  .rb-cta { width: 100%; justify-content: center; padding: 12px; }
}
@media (max-width: 480px) {
  .rb-contacts { flex-direction: column; gap: 8px; }
  .rb-contact { width: 100%; }
}


/* Na telefonu se odkazy v patičce a v drobečkách trefovaly špatně — text má
   14 px a celý řádek vycházel na 18 px, což je pod hranicí pohodlného doteku.
   Zvětšujeme plochu, na kterou jde klepnout, ne velikost písma. */
@media (max-width: 640px) {
  footer ul li { margin-bottom: 2px; }
  footer ul a,
  footer p a {
    display: inline-block;
    padding: 9px 0;
    line-height: 1.3;
  }
  .crumbs a,
  .crumbs b,
  .breadcrumb-inline a {
    display: inline-block;
    padding: 8px 0;
  }

  /* Telefon, e-mail a odkazy „Vše →" u nadpisů sekcí — stejný důvod. */
  .vd-value a,
  .ci-value a,
  a.panel-meta,
  .head-link {
    display: inline-block;
    padding: 8px 0;
  }
}


/* Položky pro přihlášeného správce v hlavním menu. Odlišené žlutou, ať je
   jasné, že to není běžná navigace pro návštěvníky — ti je ostatně vůbec
   neuvidí, přidávají se až po přihlášení. */
.site-header nav .nav-sprava {
  display: inline-block;
  padding: 8px 14px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--green-deep);
  background: rgba(244, 206, 14, 0.22);
  border: 1px solid rgba(244, 206, 14, 0.55);
  border-radius: 8px;
  cursor: pointer;
  transition: background .2s, border-color .2s;
}
.site-header nav .nav-sprava:hover {
  background: rgba(244, 206, 14, 0.4);
  border-color: var(--yellow);
  color: var(--green-deep);
}
@media (max-width: 960px) {
  .site-header nav .nav-sprava {
    display: block;
    width: 100%;
    text-align: left;
    padding: 14px 16px;
    min-height: 48px;
  }
}
