:root {
  --bg: #f6f8fb;
  --card: #ffffff;
  --muted: #6b7280;
  --accent: #2563eb;
  --radius: 14px;
  --max-width: 920px;
  --gap: 1.25rem;
  --shadow: 0 6px 20px rgba(16,24,40,0.08);
  --text-color: #0f172a;
}

body.dark-mode {
  --bg: #0f172a;
  --card: #1e293b;
  --muted: #94a3b8;
  --accent: #60a5fa;
  --text-color: #f1f5f9;
  --shadow: 0 6px 20px rgba(0,0,0,0.6);
}

* { box-sizing: border-box; }
html,body { height:100%; }
body {
  margin:0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  background: var(--bg);
  color: var(--text-color);
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  line-height:1.5;
  padding:clamp(1rem, 2vw, 2rem);
  transition: background 0.3s, color 0.3s;
}

header {
    background-color: var(--bg-color);
    color: var(--text-color);
    box-shadow: var(--shadow);
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    margin-bottom: 1rem;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--text-color);
}

.logo img {
    margin-right: 0.5rem;
}

.site-title {
    font-size: 1.2rem;
    font-weight: 700;
}

.nav-links {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    padding: 0.4rem 0.6rem;
    border-radius: var(--radius);
    transition: background-color 0.3s;
}

.nav-links a:hover {
    background-color: rgba(37,99,235,0.1);
}

/* Hamburger button */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 3px;
    background-color: var(--text-color);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.nav-links span#currentDate {
    padding: 0.4rem 0.6rem;
    border-radius: var(--radius);
    font-size: 0.95rem;
    color: var(--text-color);
    background-color: rgba(37,99,235,0.05); /* jemné pozadí pro odlišení */
}

/* Mobile nav hidden by default */
@media (max-width: 768px) {
    .nav-links {
        position: absolute;
        top: 65px;
        left: 50%;
        transform: translateX(-50%);
        width: calc(100% - 2rem); /* stejný vnitřní okraj jako sekce */
        max-width: 1200px;         /* aby to nepřesahovalo obsah */
        background-color: var(--bg);
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
        padding: 1rem;
        box-shadow: var(--shadow);
        border-radius: var(--radius);
        display: none;
        z-index: 999; /* aby překrývalo ostatní obsah */
    }

    .nav-links.show {
        display: flex;
    }

    .hamburger {
        display: flex;
    }
}


.container {
  max-width: var(--max-width);
  margin: 0 auto;
}

.intro-section {
  background: linear-gradient(180deg, rgba(37,99,235,0.06), transparent);
  padding: clamp(1rem, 2.5vw, 2rem);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: var(--gap);
  text-align: center;
  padding: 3rem 1rem;
}

.youtube-link {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.5rem;
  padding: 0.8rem 1.6rem;
  font-weight: 600;
  text-decoration: none;
  color: #fff;
  background: #ff0000;
  border-radius: 12px;
  transition: transform 0.2s ease, background 0.3s ease;
}

.youtube-link:hover {
  background: #cc0000;
  transform: translateY(-2px);
}

.youtube-icon {
  width: 24px;
  height: 24px;
  fill: white;
}

@media (max-width: 768px) {
  .youtube-link {
    width: 100%;
    justify-content: center;
    font-size: 1rem;
  }
  .youtube-icon {
    width: 20px;
    height: 20px;
  }
}


.intro-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.intro-text {
  text-align: center;
}

.intro-section h1 {
  margin:0 0 .25rem 0;
  font-size: clamp(1.1rem, 2.6vw, 1.6rem);
}

.intro-section.lead {
  font-size: clamp(1.1rem, 1.5vw, 1.5rem); /* responsivní velikost */
  line-height: 1.6;
  color: #374151; /* šedý text, lepší čitelnost než čistě černá */
  max-width: 65ch; /* omezení délky řádku kvůli čitelnosti */
  margin: 1.2rem auto;
  text-align: center; /* pěkně uprostřed – působí moderně */
  padding: 0.5rem 1rem;
}

.intro-section.lead strong {
  color: #111827; /* zvýrazněný text */
}

@media (max-width: 768px) {
  .intro-section.lead {
    text-align: left; /* na mobilech spíš zarovnání doleva pro čitelnost */
    font-size: 1rem;
    padding: 0.5rem;
  }
}
#themeToggle {
  margin-top: 1rem;
  padding: 0.5rem 1rem;
  background: var(--accent);
  border: none;
  border-radius: var(--radius);
  color: white;
  cursor: pointer;
  transition: background 0.3s;
}
#themeToggle:hover {
  background: #1d4ed8;
}

.intro-image img {
  max-width: 360px;
  width: 100%;
  height: auto;
  border-radius: 10%;
  box-shadow: var(--shadow);
}

@media (min-width: 768px) {
  .intro-content {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    text-align: left;
  }

  .intro-text {
    flex: 1;
  }
  .intro-image {
    flex: 0 0 auto;
  }
}

.section-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    padding: 0.6rem 1rem;
    border-radius: var(--radius);
    background-color: rgba(37,99,235,0.08);
    color: var(--accent);
    box-shadow: var(--shadow);
}

/* Tmavý režim */
body.dark-mode .section-title {
    background-color: rgba(96,165,250,0.15);
    color: var(--accent);
}

.qa-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--gap);
}

.qa {
  background: var(--card);
  padding: clamp(.9rem, 1.6vw, 1.2rem);
  border-radius: 12px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: transform .18s ease, box-shadow .18s ease, background 0.3s;
}
.qa:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(16,24,40,0.08); }

.question {
  font-weight: bold;
  font-size: clamp(.98rem, 1.9vw, 1.05rem);
}

.answer {
  color: var(--text-color);
  font-size: clamp(.95rem, 1.8vw, 1rem);
}

.note-section {
  margin-top: var(--gap);
  color:var(--text-color);
  font-size:.95rem;
  text-align:center;
}

.details {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1rem;
  gap: 1rem;
  flex-wrap: wrap;
}

.author-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.95rem;
  color: var(--muted);
}

.author-card {
  position: relative;
  cursor: pointer;
}

.author-name {
  font-weight: 600;
  color: var(--text-color);
  transition: color 0.3s;
}

.author-card:hover .author-name {
  color: var(--accent);
}

.author-popup {
  position: absolute;
  top: 120%;
  left: 0;
  background: var(--card);
  color: var(--text-color);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  text-align: center;
  width: 180px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.3s, transform 0.3s;
  z-index: 10;
}

.author-card:hover .author-popup {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.author-popup img {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 0.5rem;
}

.author-popup h4 {
  margin: 0;
  font-size: 1rem;
}

.author-popup a {
  display: inline-block;
  margin-top: 0.25rem;
  font-size: 0.85rem;
  color: var(--accent);
  text-decoration: none;
}

.author-popup a:hover {
  text-decoration: underline;
}

@media (min-width: 820px) {
  .qa-list {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1200px) {
  :root { --gap: 1.75rem; }
}

.qa:focus-within, .qa:focus { outline: 3px solid rgba(37,99,235,0.12); }

@media print {
  body { background: #fff; padding:0; }
  .intro-section, .qa { box-shadow:none; border-radius:0; }
  .qa-list { grid-template-columns: 1fr; }
}

.site-footer {
    background-color: var(--card); /* stejné jako header */
    color: var(--text-color);
    padding: 1.5rem 1rem;
    margin-top: 2rem;
    font-size: 0.9rem;
}

.site-footer .container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.site-footer p {
    margin: 0.3rem 0;
}

.footer-link {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-link:hover {
    text-decoration: underline;
    color: var(--link-hover, #1d4ed8);
}

.social-link {
    display: inline-flex;
    align-items: center;
    margin-left: 0.5rem;
    color: var(--text-color);
    transition: color 0.3s ease;
}

.social-link:hover {
    color: var(--link-color, #2563eb);
}




