/*
 * ╔══════════════════════════════════════════════════════════╗
 * ║  danielbenes.cz — Hlavní stylesheet                      ║
 * ║  1.  Fonty                                               ║
 * ║  2.  CSS proměnné (tmavý / světlý motiv)                 ║
 * ║  3.  Základní styly                                      ║
 * ║  4.  Hlavička a navigace                                 ║
 * ║  5.  Přepínač motivu — tvar a ikony                      ║
 * ║  6.  Přepínač motivu — zvýraznění (pill, pulse, animace) ║
 * ║  7.  Mobilní boční menu                                  ║
 * ║  8.  Hero sekce + scroll indikátor                       ║
 * ║  9.  Vizitka karta                                       ║
 * ║  10. Sociální ikony                                      ║
 * ║  11. Harmonogram                                         ║
 * ║  12. Sekundární panely (partneři + adresa)               ║
 * ║  13. (rezervováno — sekce institucí odstraněna)          ║
 * ║  14. Responzivní design                                  ║
 * ║  15. Tlačítko zpět nahoru                                ║
 * ║  16. Sdílené komponenty podstránek                       ║
 * ╚══════════════════════════════════════════════════════════╝
 */


/* ============================================================
   1. FONTY — uloženy lokálně v /media/fonts/
============================================================ */

@font-face {
  font-family: "Special Force";
  src: url("/media/fonts/Special_Elite/SpecialElite-Regular.ttf") format("truetype");
  font-display: swap;
}

@font-face {
  font-family: "Montserrat";
  src: url("/media/fonts/Montserrat/Montserrat-VariableFont_wght.ttf") format("truetype");
  font-display: swap;
}

@font-face {
  font-family: "Inconsolata";
  src: url("/media/fonts/Inconsolata/Inconsolata-VariableFont_wdth,wght.ttf") format("truetype");
  font-display: swap;
}


/* ============================================================
   2. CSS PROMĚNNÉ — TMAVÝ / SVĚTLÝ MOTIV
   Výchozí motiv: světlý (data-theme="light" v HTML).
   Tmavý: data-theme="dark". JS ukládá volbu do localStorage.
============================================================ */

:root {
  --bg:            #000;
  --text:          #fff;
  --muted:         rgba(255, 255, 255, 0.78);
  --border:        rgba(255, 255, 255, 0.08);
  --shadow:        0 18px 50px rgba(0, 0, 0, 0.35);
  --panel-bg:      rgba(10, 10, 10, 0.98);
  --panel-border:  rgba(255, 255, 255, 0.08);
  --accent:        #d90000;
  --nav-underline: #fff;
  --active-bg:     rgba(255, 255, 255, 0.10);
  --active-border: #fff;
}

html[data-theme="light"] {
  --bg:            #fff;
  --text:          #111;
  --muted:         rgba(17, 17, 17, 0.75);
  --border:        rgba(17, 17, 17, 0.1);
  --shadow:        0 18px 50px rgba(0, 0, 0, 0.12);
  --panel-bg:      rgba(255, 255, 255, 0.98);
  --panel-border:  rgba(17, 17, 17, 0.1);
  --nav-underline: #d90000;
  --active-bg:     rgba(217, 0, 0, 0.10);
  --active-border: #d90000;
}


/* ============================================================
   3. ZÁKLADNÍ STYLY
============================================================ */

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: "Montserrat", system-ui, sans-serif;
  overflow-x: clip;
  scroll-behavior: smooth;
}

* { box-sizing: border-box; }

section { scroll-margin-top: 90px; }

/* Čitelnost: obsah nesmí běžet přes celou obrazovku.
   Vlastní strop pro .container + odsazení od krajů. */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: clamp(1rem, 4vw, 2.5rem);
}

body.menu-open {
  overflow: hidden;
  touch-action: none;
}


/* ============================================================
   4. HLAVIČKA A NAVIGACE
============================================================ */

.site-header {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  z-index: 20;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s ease, border-color 0.3s ease,
              backdrop-filter 0.3s ease, box-shadow 0.3s ease;
}

/* Frosted-glass při scrollu */
.site-header.scrolled {
  background: color-mix(in srgb, var(--panel-bg) 85%, transparent);
  border-bottom: 1px solid var(--panel-border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}

.top-nav {
  width: 100%;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .5rem 1rem 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
  margin-right: auto;
  min-width: 0;
  flex-shrink: 0;
}

.brand-logo {
  width: 42px; height: 42px;
  object-fit: contain;
  border-radius: 10px;
  flex: 0 0 auto;
}

.brand span {
  font-family: "Montserrat", system-ui, sans-serif;
  font-weight: 600;
  line-height: 1;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  min-width: 0;
  flex: 0 0 auto;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: clamp(0.4rem, 1.2vw, 1.25rem);
  margin: 0; padding: 0;
  flex-wrap: nowrap;
}

.nav-links a {
  color: var(--text);
  text-decoration: none;
  font-size: .95rem;
  opacity: .92;
  white-space: nowrap;
  position: relative;
  padding: .5rem 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 2px;
  background: var(--nav-underline);
  transition: width .2s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

.nav-links a.active { font-weight: 700; opacity: 1; }


/* ---- Upozornění „prototyp" — pruh pod navigací ---- */
.proto-banner {
  position: relative;
  background: color-mix(in srgb, var(--accent) 8%, var(--bg));
  border-top: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.5;
  text-align: center;
  padding: 0.45rem 3rem 0.45rem 1rem;
}

.proto-banner strong {
  color: var(--accent);
  font-weight: 700;
}

/* Zavírací tlačítko — volba se ukládá v prohlížeči (localStorage) */
.proto-banner-close {
  position: absolute;
  top: 50%;
  right: 0.75rem;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  background: transparent;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1;
  cursor: pointer;
  flex: 0 0 auto;
}

.proto-banner-close:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* ============================================================
   5 + 6. PŘEPÍNAČ MOTIVU — TVAR, IKONY, PILL, ANIMACE
============================================================ */

/* Sdílené základní styly hamburger + zavřít */
.menu-open,
.menu-close {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  height: 42px;
  border-radius: 999px;
  cursor: pointer;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

/* Hamburger — na desktopu skrytý */
.menu-open {
  display: none;
  padding: 0 1rem;
  width: auto;
  gap: .4rem;
  white-space: nowrap;
}

/* Tlačítko přepínání motivu */
.theme-toggle {
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
  height: 42px !important;
  padding: 0 1rem 0 0.65rem !important;
  width: auto !important;
  min-width: 0 !important;
  border-radius: 999px !important;
  border: 1px solid var(--border) !important;
  background: transparent !important;
  color: var(--text) !important;
  cursor: pointer !important;
  flex: 0 0 auto !important;
  white-space: nowrap !important;
  overflow: visible !important;
  position: relative !important;
  box-sizing: border-box !important;
  text-decoration: none !important;
}

/* Obal ikon — relativní pozice pro absolutní ikony uvnitř */
.tt-icon-wrap {
  position: relative;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  display: block;
}

/* Ikony — absolutní uvnitř tt-icon-wrap */
.tt-icon-wrap .theme-icon {
  position: absolute;
  width: 18px;
  height: 18px;
  top: 50%;
  left: 50%;
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
}

/* Tmavý motiv: měsíc viditelný */
.tt-icon-wrap .theme-icon-sun  { opacity: 0; transform: translate(-50%, -50%) rotate(-90deg) scale(.8); }
.tt-icon-wrap .theme-icon-moon { opacity: 1; transform: translate(-50%, -50%) rotate(0deg)   scale(1); }

/* Světlý motiv: slunce viditelné */
html[data-theme="light"] .tt-icon-wrap .theme-icon-sun  { opacity: 1; transform: translate(-50%, -50%) rotate(0deg)   scale(1); }
html[data-theme="light"] .tt-icon-wrap .theme-icon-moon { opacity: 0; transform: translate(-50%, -50%) rotate(90deg) scale(.8); }

/* Popisek "Motiv" */
.tt-label {
  font-size: 0.82rem;
  font-family: "Montserrat", system-ui, sans-serif;
  font-weight: 600;
  white-space: nowrap;
  color: var(--text);
  letter-spacing: 0.03em;
  pointer-events: none;
  flex-shrink: 0;
  line-height: 1;
}

/* ---- Animace ikony slunce (světlý motiv) ---- */
html[data-theme="light"] .tt-icon-wrap .theme-icon-sun {
  animation: tt-sun-wobble 4s ease-in-out 1.5s infinite;
}

@keyframes tt-sun-wobble {
  0%,  100% { transform: translate(-50%, -50%) scale(1)    rotate(0deg); }
  20%        { transform: translate(-50%, -50%) scale(1.18) rotate(14deg); }
  40%        { transform: translate(-50%, -50%) scale(1.18) rotate(-10deg); }
  60%        { transform: translate(-50%, -50%) scale(1.12) rotate(6deg); }
  80%        { transform: translate(-50%, -50%) scale(1.05) rotate(-4deg); }
}

/* ---- Animace ikony měsíce (tmavý motiv) ---- */
html[data-theme="dark"] .tt-icon-wrap .theme-icon-moon {
  animation: tt-moon-pulse 3s ease-in-out 1.5s infinite;
}

@keyframes tt-moon-pulse {
  0%,  100% { transform: translate(-50%, -50%) scale(1);    opacity: 1; }
  50%        { transform: translate(-50%, -50%) scale(1.22); opacity: 0.7; }
}

/* ---- Pulsující kroužek ---- */
.theme-toggle.tt-pulse::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 999px;
  border: 1.5px solid var(--text);
  opacity: 0;
  animation: tt-ring 2s ease-out 0.8s 3;
  pointer-events: none;
}

@keyframes tt-ring {
  0%   { transform: scale(1);    opacity: 0.5; }
  100% { transform: scale(1.5);  opacity: 0; }
}

/* ---- prefers-reduced-motion ---- */
@media (prefers-reduced-motion: reduce) {
  .theme-toggle.tt-pulse::before,
  .tt-icon-wrap .theme-icon-sun,
  .tt-icon-wrap .theme-icon-moon,
  .scroll-indicator,
  .btn-call::before {
    animation: none !important;
    transition: none !important;
  }
}


/* ============================================================
   7. MOBILNÍ BOČNÍ MENU
============================================================ */

.side-menu {
  position: fixed;
  top: 0; left: 0;
  width: min(85vw, 340px);
  height: 100svh;
  background: var(--panel-bg);
  border-right: 1px solid var(--panel-border);
  box-shadow: var(--shadow);
  transform: translateX(-102%);
  will-change: transform;
  transition: transform .28s ease;
  z-index: 40;
  padding: 1.5rem;
  backdrop-filter: blur(16px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.side-menu.open { transform: translateX(0); }

.side-menu nav ul {
  list-style: none;
  padding: 4rem 0 0;
  margin: 0;
  display: grid;
  gap: 1rem;
}

.side-menu nav a {
  display: block;
  color: var(--text);
  text-decoration: none;
  font-size: 1.1rem;
  padding: .9rem 1.2rem;
  border-radius: 8px;
  line-height: 1.3;
}

.side-menu nav a:hover {
  background: color-mix(in srgb, var(--text) 6%, transparent);
}

.side-menu nav a.active {
  font-weight: 700;
  background: var(--active-bg);
  border-left: 4px solid var(--active-border);
}

.menu-close {
  position: absolute;
  top: 1rem; right: 1rem;
  width: 40px;
}

.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .55);
  z-index: 35;
  cursor: pointer;
}


/* ============================================================
   8. HERO SEKCE + SCROLL INDIKÁTOR
============================================================ */

.hero {
  min-height: 100svh;
  display: flex;
  align-items: center;
  background: #000;
  color: #fff;
  padding-top: 72px;
  position: relative;
}

html[data-theme="light"] .hero {
  background: #fff;
  color: #111;
}

.hero-content {
  width: 100%;
  max-width: 1100px;
  margin-left: clamp(0rem, 4vw, 4rem);
}

.eyebrow {
  font-family: "Inconsolata", monospace;
  color: #fff;
  margin-bottom: 1rem;
  font-size: .9rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}

html[data-theme="light"] .eyebrow { color: #111; }

.hero h1 {
  font-family: "Special Force", serif;
  color: #fff;
  font-size: clamp(2.8rem, 5vw, 5.4rem);
  line-height: .95;
  margin: 0 0 1.6rem 0;
  letter-spacing: .06em;
}

html[data-theme="light"] .hero h1 { color: #111; }

/* CTA tlačítko */
.btn-call {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .25rem;
  min-height: 64px;
  padding: 1rem 2rem;
  border-radius: 12px;
  background: linear-gradient(135deg, #d90000 0%, #b80000 100%);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  width: min(100%, 420px);
  border: 2px solid transparent;
  box-shadow: 0 4px 12px rgba(217, 0, 0, 0.25), 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
}

.btn-call::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
  transition: left .6s ease;
}

.btn-call:hover::before { left: 100%; }

.btn-call:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(217,0,0,0.35), 0 4px 8px rgba(0,0,0,0.15);
  background: linear-gradient(135deg, #ff0000 0%, #d90000 100%);
  border-color: rgba(255,255,255,0.1);
}

/* ---- Scroll indikátor ---- */
.scroll-indicator {
  position: absolute;
  left: 50%;
  bottom: 1.5rem;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px; height: 48px;
  border-radius: 999px;
  text-decoration: none;
  z-index: 5;
  animation: scrollBounce 2.2s ease-in-out infinite;
  border: 2px solid rgba(255, 255, 255, 0.5);
  background: rgba(0, 0, 0, 0.25);
}

html[data-theme="light"] .scroll-indicator {
  border: 2px solid rgba(17, 17, 17, 0.35);
  background: rgba(255, 255, 255, 0.5);
}

@keyframes scrollBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%       { transform: translateX(-50%) translateY(8px); }
}

.scroll-chevron {
  display: block;
  flex-shrink: 0;
}

/* Tmavý motiv: bílý tah */
.scroll-chevron polyline {
  stroke: rgba(255, 255, 255, 0.9);
}

/* Světlý motiv: tmavý tah */
html[data-theme="light"] .scroll-chevron polyline {
  stroke: rgba(17, 17, 17, 0.75);
}


/* ============================================================
   9. VIZITKA KARTA
============================================================ */

.vizitka-section { padding: 4rem 0; }

.vizitka-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  background: var(--panel-bg) !important;
  border: 1px solid var(--panel-border) !important;
  box-shadow: var(--shadow);
  padding: 2.5rem !important;
  border-radius: 16px;
  margin-bottom: 2rem;
}

@media (min-width: 992px) {
  .vizitka-card {
    grid-template-columns: 320px 1fr;
    align-items: start;
  }
}

.vizitka-img-wrapper {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
}

.vizitka-img {
  width: 100%; max-width: 320px;
  height: auto;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}

.vizitka-header-block {
  border-bottom: 1px solid var(--border);
  padding-bottom: 1rem;
  margin-bottom: 1.5rem;
}

.vizitka-name {
  font-family: "Special Force", serif;
  font-size: 2.2rem;
  margin: 0 0 0.25rem 0;
}

.vizitka-profession {
  font-family: "Inconsolata", monospace;
  font-size: 1.1rem;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0;
}

.section-sub-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 1.5rem 0 0.75rem 0;
  text-transform: uppercase;
}

.contact-list { list-style: none; padding: 0; margin: 0 0 1.25rem 0; }
.contact-list li { margin-bottom: 0.5rem; }

.contact-link {
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.05rem;
}

.contact-link:hover { color: var(--accent); }


/* ============================================================
   10. SOCIÁLNÍ IKONY
============================================================ */

.social-icons {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  align-items: center;
}

.social-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px; height: 50px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--text) 4%, transparent);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
  opacity: 0.85;
  overflow: hidden;
  position: relative;
}

.social-icons a::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 20%, transparent), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.social-icons a:hover {
  opacity: 1;
  transform: translateY(-4px) scale(1.08);
  border-color: var(--accent);
  box-shadow: 0 8px 20px rgba(217,0,0,0.25);
}

.social-icons a:hover::before { opacity: 1; }
.social-icons a:hover .icon-img { transform: scale(1.15); }

.icon-img {
  width: 28px; height: 28px;
  object-fit: contain;
  transition: transform 0.3s ease;
  position: relative;
  z-index: 1;
}


/* ============================================================
   11. HARMONOGRAM
============================================================ */

.schedule-list {
  list-style: none;
  padding: 0;
  margin: 0 0 0.75rem 0;
  max-width: 280px;
}

.schedule-list li {
  display: flex;
  justify-content: space-between;
  padding: 0.35rem 0;
  border-bottom: 1px dashed var(--border);
  font-family: "Inconsolata", monospace;
}

.schedule-note {
  font-size: 0.9rem;
  font-style: italic;
  color: var(--muted);
  margin: 0;
}


/* ============================================================
   12. SEKUNDÁRNÍ PANELY — PARTNEŘI + ADRESA
============================================================ */

.partner-panel, .address-panel {
  background: var(--panel-bg) !important;
  border: 1px solid var(--panel-border) !important;
  box-shadow: var(--shadow);
  padding: 1.75rem !important;
  border-radius: 16px;
  margin: 0;
}

.partner-logos {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  margin-bottom: 1.25rem;
  justify-content: center;
  flex-wrap: wrap;
}

.partner-logo-img {
  height: 45px; width: 130px;
  object-fit: contain;
  display: inline-block;
  transition: background-color 0.2s ease, padding 0.2s ease;
  margin: 0 auto;
}

html[data-theme="dark"] .partner-logo-img {
  background: #fff;
  padding: 5px 10px;
  border-radius: 6px;
}

.partner-text {
  font-size: 0.95rem;
  line-height: 1.75;
  margin: 0;
  color: var(--muted);
}

.address-content-layout {
  display: flex;
  gap: 1.5rem;
  height: 100%;
}

.address-text-side { flex: 1; }
.address-map-side  { flex: 1.2; min-height: 140px; }

.address-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 0.75rem 0;
  text-transform: uppercase;
}

.address-details { font-size: 1.05rem; color: var(--muted); }

.map-wrapper {
  width: 100%; height: 100%;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
}


/* ============================================================
   14. RESPONZIVNÍ DESIGN
============================================================ */

/* Breakpoint 1200 px — 7 zkrácených položek navigace se do užšího okna nevejde */
@media (max-width: 1200px) {
  .nav-links  { display: none !important; }
  .menu-open  { display: inline-flex; }

  .brand span {
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .hero-content { margin-left: 0; padding: 0 1rem; }
  .btn-call     { width: 100%; max-width: none; }
}

@media (max-width: 992px) {
  .institutions-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 1.75rem; padding: 2.5rem 1.5rem;
  }
  .logo-wrapper { height: 60px; }
}

@media (max-width: 768px) {
  .address-content-layout { flex-direction: column; gap: 1.25rem; }
  .address-map-side       { height: 180px; }
  .institutions-grid      { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
}

@media (max-width: 600px) {
  .top-nav    { padding: .5rem .75rem 0; gap: .5rem; }
  .brand-logo { width: 34px; height: 34px; border-radius: 8px; }
  .brand span { font-size: .9rem; }

  .menu-open, .theme-toggle {
    padding: 0 .75rem;
    height: 38px;
    font-size: .9rem;
  }

  .hero h1         { font-size: clamp(2.4rem, 12vw, 3.6rem); }
  .vizitka-section { padding: 2rem 0; }
  .vizitka-card    { padding: 1.5rem !important; }
  .vizitka-name    { font-size: 1.8rem; }

  .institutions-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem; padding: 2rem 1rem;
  }
  .logo-wrapper  { height: 50px; }
  .social-icons  { gap: 0.75rem; }
  .social-icons a{ width: 44px; height: 44px; }
  .icon-img      { width: 24px; height: 24px; }
}

/* ============================================================
   15. TLAČÍTKO ZPĚT NAHORU — sdílené pro všechny stránky
   (zobrazí se po srolování > 400 px, obsluhuje JS/main.js)
============================================================ */

.scroll-top-btn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  height: 42px;
  padding: 0 1.1rem 0 0.9rem;
  border-radius: 999px;
  background: linear-gradient(135deg, #d90000 0%, #a80000 100%);
  color: #fff;
  border: none;
  cursor: pointer;
  z-index: 50;
  box-shadow: 0 4px 20px rgba(217, 0, 0, 0.40);
  font-family: "Montserrat", system-ui, sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
  /* Výchozí stav — skryté, posunuté dolů */
  opacity: 0;
  transform: translateY(16px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease, box-shadow 0.25s ease;
}

/* Viditelný stav (přidá JS při scrollu > 400 px) */
.scroll-top-btn.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.scroll-top-btn:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 8px 28px rgba(217, 0, 0, 0.50);
}

.scroll-top-btn:active {
  transform: translateY(-1px) scale(1.02);
}

/* Animace výskoku — spustí se při prvním zobrazení */
@keyframes btnBounceIn {
  0%   { transform: translateY(16px) scale(0.88); opacity: 0; }
  55%  { transform: translateY(-6px) scale(1.06); opacity: 1; }
  75%  { transform: translateY(3px)  scale(0.98); }
  100% { transform: translateY(0)    scale(1);    opacity: 1; }
}

.scroll-top-btn.bounce-in {
  animation: btnBounceIn 0.5s cubic-bezier(.22,.61,.36,1) both;
}

/* Na mobilu — menší, dál od okraje */
@media (max-width: 480px) {
  .scroll-top-btn {
    height: 38px;
    font-size: 0.76rem;
    padding: 0 0.85rem 0 0.75rem;
    bottom: 1.25rem;
    right: 1.25rem;
  }
}

/* Skrytí obsahu za bočním menu */
body.menu-open .hero-content,
body.menu-open .scroll-indicator,
body.menu-open .vizitka-section {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

body.menu-open .site-header {
  opacity: 0;
  visibility: hidden;
}


/* ============================================================
   16. SDÍLENÉ KOMPONENTY PODSTRÁNEK
   Dříve duplikováno v inline <style> jednotlivých stránek
   (penzijni-pruvodce, investicni-rozcestnik, hypoteky-uvery,
   zivotni-nezivotni-pojisteni, gdpr, o-mne).
============================================================ */

/* --- Eyebrow sekce --- */
.section-eyebrow {
  font-family: "Inconsolata", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 0.5rem;
}

/* --- Tagy v page-hero --- */
.page-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.page-tag {
  font-family: "Inconsolata", monospace;
  font-size: 0.8rem;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

@media (max-width: 400px) {
  .page-tag { font-size: 0.7rem; padding: 3px 9px; }
}

/* --- Info / warn poznámky --- */
.info-note {
  background: rgba(30, 111, 181, 0.1);
  border-left: 3px solid #1e6fb5;
  border-radius: 0 8px 8px 0;
  padding: 0.75rem 1rem;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 1rem 0;
  text-align: left;
}

html[data-theme="light"] .info-note { background: #E6F1FB; }
.info-note strong { color: var(--text); }

.warn-note {
  background: rgba(217, 120, 0, 0.08);
  border-left: 3px solid #d97800;
  border-radius: 0 8px 8px 0;
  padding: 0.75rem 1rem;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 1rem 0;
  text-align: left;
}

html[data-theme="light"] .warn-note { background: #FAEEDA; }
.warn-note strong { color: var(--text); }

/* --- Obal grafů (Chart.js) --- */
.chart-wrapper {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  margin: 1.5rem 0;
}

.chart-title {
  font-family: "Inconsolata", monospace;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin: 0 0 1rem;
}

.chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1rem;
  margin-top: 0.85rem;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: "Inconsolata", monospace;
  font-size: 0.78rem;
  color: var(--muted);
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}

/* --- Shrnutí na první pohled (tldr box) --- */
.tldr-box {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-left: 3px solid var(--accent);
  border-radius: 0 12px 12px 0;
  padding: 1.1rem 1.5rem;
  margin: 0 0 1.75rem;
  box-shadow: var(--shadow);
}

.tldr-num {
  font-family: "Montserrat", system-ui, sans-serif;
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  font-weight: 800;
  color: var(--accent);
  white-space: nowrap;
  line-height: 1;
  flex-shrink: 0;
}

.tldr-num small {
  display: block;
  font-family: "Inconsolata", monospace;
  font-size: 0.68rem;
  font-weight: 400;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.35rem;
  white-space: normal;
}

.tldr-text {
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.75;
  margin: 0;
  text-align: left;
}

.tldr-text strong { color: var(--text); }

@media (max-width: 600px) {
  .tldr-box { flex-direction: column; align-items: flex-start; gap: 0.75rem; }
}

/* --- Rozbalovací blok (přesné podmínky) --- */
.detail-block {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  margin: 1rem 0;
  overflow: hidden;
}

.detail-block summary {
  cursor: pointer;
  padding: 0.9rem 1.25rem;
  font-family: "Inconsolata", monospace;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  transition: color 0.18s ease;
  user-select: none;
}

.detail-block summary::-webkit-details-marker { display: none; }

.detail-block summary:hover { color: var(--text); }

.detail-block summary .db-arrow {
  display: inline-block;
  color: var(--accent);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.detail-block[open] summary .db-arrow { transform: rotate(90deg); }

.detail-block .detail-body {
  padding: 0 1.25rem 1.25rem;
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.8;
  text-align: left;
}

.detail-body p { margin: 0 0 0.75rem; font-size: 0.88rem; color: var(--muted); text-align: left; }
.detail-body p:last-child { margin-bottom: 0; }
.detail-body strong { color: var(--text); }
.detail-body ul { margin: 0 0 0.75rem; padding: 0 0 0 1.2rem; }
.detail-body li { margin-bottom: 0.4rem; font-size: 0.86rem; text-align: left; }
.detail-body a { color: var(--accent); }

/* --- Animace: scroll reveal + hero fade --- */
.anim-reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.anim-reveal.in-view { opacity: 1; transform: none; }

.anim-stagger .anim-reveal:nth-child(1) { transition-delay: 0.00s; }
.anim-stagger .anim-reveal:nth-child(2) { transition-delay: 0.10s; }
.anim-stagger .anim-reveal:nth-child(3) { transition-delay: 0.20s; }
.anim-stagger .anim-reveal:nth-child(4) { transition-delay: 0.28s; }

.page-hero-content > * { animation: heroFadeUp 0.65s ease both; }
.page-hero-content > *:nth-child(1) { animation-delay: 0.08s; }
.page-hero-content > *:nth-child(2) { animation-delay: 0.18s; }
.page-hero-content > *:nth-child(3) { animation-delay: 0.28s; }
.page-hero-content > *:nth-child(4) { animation-delay: 0.38s; }

@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .anim-reveal,
  .page-hero-content > * {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

/* --- Drobné poznámky (kontrast zvýšen z 0.6–0.65 na 0.85) --- */
.table-note {
  font-size: 0.75rem;
  color: var(--muted);
  opacity: 0.85;
  line-height: 1.5;
  margin: 0;
  text-align: left;
}

.legal-note {
  font-size: 0.78rem;
  color: var(--muted);
  opacity: 0.85;
  line-height: 1.7;
  max-width: 760px;
  margin: 0 auto;
  text-align: left;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--border);
}

/* --- Patička --- */
.page-footer {
  text-align: center;
  padding: 1.5rem 0 2.5rem;
  border-top: 1px solid var(--border);
}

.footer-note {
  font-size: 0.78rem;
  color: var(--muted);
  opacity: 0.85;
  line-height: 1.7;
  max-width: 700px;
  margin: 0 auto;
}