/* Václav Filip — profesní profil */

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

/* ── THEME VARIABLES ── */
:root {
  /* Light (default – vendaweb.cz palette) */
  --bg:       #eafbfa;
  --bg-soft:  #f5fdff;
  --surface:  #fff;
  --surface2: #f0f7ff;
  --border:   #dcebee;
  --accent:   #0891b2;
  --accent2:  #0e7490;
  --text:     #0f172a;
  --muted:    #607086;
  --heading:  #0f172a;
  --current:  #059669;
  --radius:   10px;
  --shadow:   0 2px 16px rgba(0,0,0,.08);
  --trans:    .25s ease;
}

body.dark {
  --bg:       #0b1824;
  --bg-soft:  #0e1d2b;
  --surface:  #0e1621;
  --surface2: #162030;
  --border:   #1e3350;
  --accent:   #3d8ef8;
  --accent2:  #2563eb;
  --text:     #dde6f3;
  --muted:    #7a94b0;
  --heading:  #fff;
  --current:  #22c55e;
  --shadow:   0 2px 16px rgba(0,0,0,.35);
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  min-height: 100vh;
  transition: background-color var(--trans), color var(--trans);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(8,145,178,.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(8,145,178,.055) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: .75;
  z-index: -1;
}
body.dark::before { opacity: .18; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

/* ── SKIP LINK ── */
.skip-link {
  position: absolute; left: -999px; top: 8px;
  background: var(--accent); color: #fff;
  padding: 6px 12px; border-radius: 4px; z-index: 999;
}
.skip-link:focus { left: 8px; }

/* ── CONTAINER ── */
.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 28px; }

/* ── TOP BAR ── */
.topbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  transition: background var(--trans), border-color var(--trans);
}
body.dark .topbar { background: rgba(14,22,33,.92); }

.topbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 52px;
}
.topbar-brand { font-weight: 700; font-size: 14px; color: var(--text); letter-spacing: .04em; }
.topbar-brand span { color: var(--accent); }
.topbar-nav { display: flex; gap: 4px; align-items: center; }
.topbar-nav a {
  font-size: 13px; color: var(--muted); padding: 4px 10px;
  border-radius: 6px; transition: color var(--trans), background var(--trans);
}
.topbar-nav a:hover { color: var(--text); background: var(--surface2); text-decoration: none; }
.lang-switch {
  display: flex; gap: 4px; margin-left: 8px;
  border-left: 1px solid var(--border); padding-left: 8px;
}
.lang-switch a {
  font-size: 11px; font-weight: 700; letter-spacing: .06em;
  padding: 3px 7px; border-radius: 5px; color: var(--muted);
  border: 1px solid transparent;
}
.lang-switch a.active { color: var(--accent); border-color: var(--border); }
.lang-switch a:hover { color: var(--text); text-decoration: none; }

/* ── THEME TOGGLE ── */
.theme-toggle {
  width: 32px; height: 32px; border: 1px solid var(--border);
  border-radius: 7px; background: var(--surface); color: var(--text);
  cursor: pointer; font-size: 16px;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--trans), border-color var(--trans);
  margin-left: 6px; flex-shrink: 0;
}
.theme-toggle:hover { background: var(--surface2); }

/* ── HERO ── */
.hero {
  position: relative; overflow: visible;
  padding: 80px 0 64px;
  border-bottom: 1px solid var(--border);
}
.hero-bg {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 70% 60% at 80% 50%, rgba(8,145,178,.07) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(37,99,235,.05) 0%, transparent 60%);
}
body.dark .hero-bg {
  background:
    radial-gradient(ellipse 70% 60% at 80% 50%, rgba(61,142,248,.07) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(37,99,235,.06) 0%, transparent 60%);
}
.hero-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(8,145,178,.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(8,145,178,.06) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 80%);
}
body.dark .hero-grid {
  background-image:
    linear-gradient(rgba(61,142,248,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(61,142,248,.05) 1px, transparent 1px);
}

/* Hero 2-col layout */
.hero-layout {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: start;
  position: relative; z-index: 1;
  background: rgba(255,255,255,.62);
  border: 1px solid rgba(191,232,247,.85);
  border-radius: 24px;
  padding: 42px;
  box-shadow: 0 18px 48px rgba(8,145,178,.08);
}
body.dark .hero-layout { background: rgba(14,22,33,.72); border-color: var(--border); }
.hero-content { min-width: 0; }
.hero-photo-wrap {
  flex-shrink: 0;
  align-self: start;
  position: relative; z-index: 2;
  /* Partial float: photo dips 80px below hero border */
  margin-bottom: -80px;
  min-width: 168px; /* prevent collapse if image slow to load */
}
.hero-photo {
  width: 168px;
  border-radius: 14px;
  border: 3px solid var(--border);
  box-shadow: 0 12px 40px rgba(0,0,0,.12), 0 2px 8px rgba(0,0,0,.08);
  display: block;
  object-fit: cover;
  aspect-ratio: 3/4;
  transition: border-color var(--trans), box-shadow var(--trans);
}
body.dark .hero-photo { box-shadow: 0 12px 40px rgba(0,0,0,.50), 0 2px 8px rgba(0,0,0,.3); }

.hero-label {
  display: inline-block;
  font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--accent); background: rgba(8,145,178,.1);
  border: 1px solid rgba(8,145,178,.25);
  padding: 4px 12px; border-radius: 20px; margin-bottom: 20px;
}
body.dark .hero-label { background: rgba(61,142,248,.1); border-color: rgba(61,142,248,.25); }

.hero h1 {
  font-size: clamp(28px, 5vw, 48px);
  font-weight: 800; letter-spacing: -.02em; line-height: 1.15;
  color: var(--heading); margin-bottom: 10px;
}
.hero-name { color: var(--accent); }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero-born {
  color: var(--heading);
  font-size: .62em;
  font-weight: 700;
  letter-spacing: 0;
  white-space: nowrap;
}
.hero-sub {
  font-size: clamp(14px, 2vw, 17px);
  color: var(--muted); margin-bottom: 24px; letter-spacing: .02em;
}
.hero-contact {
  font-size: 13px; color: var(--muted); margin-bottom: 32px;
  display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center;
}
.hero-contact a { color: var(--muted); transition: color var(--trans); }
.hero-contact a:hover { color: var(--accent); text-decoration: none; }
.hero-contact .dot { opacity: .35; }
.hero-summary {
  max-width: 640px;
  font-size: 15px; color: var(--text); opacity: .85;
  margin-bottom: 14px; line-height: 1.7;
}
.hero-tagline {
  max-width: 580px;
  font-size: 14px; color: var(--muted);
  border-left: 3px solid var(--accent);
  padding-left: 14px; margin-bottom: 36px; line-height: 1.6;
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; }

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 14px; font-weight: 600; padding: 10px 20px;
  border-radius: 8px; border: none; cursor: pointer;
  transition: background var(--trans), transform var(--trans), box-shadow var(--trans);
  line-height: 1;
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent2); text-decoration: none; color: #fff; }
.btn-ghost {
  background: var(--surface); color: var(--text);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--surface2); text-decoration: none; color: var(--text); }

/* ── SECTION COMMON ── */
.section { padding: 34px 0; border-bottom: 1px solid var(--border); }
.section:last-child { border-bottom: none; }
.section-label {
  display: inline-block;
  font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 10px;
}
.section-head { margin-bottom: 18px; }
.section-head h2 {
  font-size: clamp(20px, 3.5vw, 30px);
  font-weight: 800; letter-spacing: -.02em; color: var(--heading);
}

/* First section after hero gets extra top padding to clear floating photo */
.hero + .section { padding-top: 52px; }

/* ── COMPETENCIES GRID ── */
.comp-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.comp-tag {
  font-size: 13px; color: var(--text);
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 6px; padding: 7px 14px;
  transition: border-color var(--trans), color var(--trans), background var(--trans);
}
.comp-tag:hover { border-color: var(--accent); color: var(--accent); background: var(--surface2); }
.comp-tag .icon { margin-right: 6px; font-style: normal; }

/* ── TIMELINE ── */
/* Časová osa – levá páteř, karty chronologicky pod sebou */
.timeline {
  position: relative;
  padding: 6px 0 6px 42px;
}
.timeline::before {
  content: "";
  position: absolute;
  top: 16px;
  bottom: 16px;
  left: 13px;
  width: 3px;
  border-radius: 99px;
  background: linear-gradient(180deg, rgba(8,145,178,.65), rgba(8,145,178,.18));
}

.tl-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  overflow: visible;
  transition: border-color var(--trans), transform var(--trans), box-shadow var(--trans);
  position: relative;
  z-index: 1;
  margin-bottom: 14px;
}
.tl-card::before {
  content: "";
  position: absolute;
  top: 26px;
  left: -22px;
  width: 22px;
  height: 2px;
  background: rgba(8,145,178,.32);
}
.tl-card::after {
  content: "";
  position: absolute;
  top: 19px;
  left: -34px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(8,145,178,.13);
  transition: transform var(--trans), box-shadow var(--trans);
  z-index: 2;
}
.tl-card:first-child::after {
  background: var(--current);
  box-shadow: 0 0 0 5px rgba(5,150,105,.18);
  animation: tlPulse 2.4s ease-in-out infinite;
}
@keyframes tlPulse {
  0%, 100% { box-shadow: 0 0 0 5px rgba(5,150,105,.18); }
  50%      { box-shadow: 0 0 0 11px rgba(5,150,105,.03); }
}
.tl-card:hover { border-color: rgba(8,145,178,.5); transform: translateX(3px); box-shadow: 0 8px 26px rgba(8,145,178,.14); }
.tl-card:hover::after { transform: scale(1.22); box-shadow: 0 0 0 6px rgba(8,145,178,.2); }
.tl-card.is-open { border-color: rgba(8,145,178,.65); }
body.dark .tl-card:hover { border-color: rgba(61,142,248,.35); }
body.dark .tl-card.is-open { border-color: rgba(61,142,248,.5); }

.tl-header {
  width: 100%; background: none; border: none; cursor: pointer;
  padding: 14px 18px;
  display: flex; align-items: center; gap: 14px;
  text-align: left; color: inherit;
}
.tl-header:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; border-radius: var(--radius); }

.tl-icon {
  flex-shrink: 0; width: 36px; height: 36px;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: 8px; display: flex; align-items: center; justify-content: center;
  font-size: 17px;
}
.tl-meta { flex: 1; min-width: 0; overflow: hidden; }
.tl-period {
  font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 2px; display: flex; align-items: center; gap: 8px;
}
.badge-current {
  font-size: 9px; font-weight: 700; letter-spacing: .08em;
  background: rgba(5,150,105,.12); color: var(--current);
  border: 1px solid rgba(5,150,105,.25);
  padding: 2px 7px; border-radius: 10px;
}
body.dark .badge-current {
  background: rgba(34,197,94,.15); border-color: rgba(34,197,94,.3);
}
.tl-company {
  font-size: 15px; font-weight: 700; color: var(--heading);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block;
}
.tl-role {
  font-size: 12px; color: var(--muted); margin-top: 1px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block;
}

.tl-arrow {
  flex: 0 0 28px;
  width: 28px !important;
  height: 28px !important;
  display: grid;
  place-items: center;
  margin: 0 0 0 auto;
  color: var(--muted);
  border: 0 !important;
  transform: none !important;
  transition: color var(--trans);
}
.tl-arrow::before {
  content: '';
  display: block;
  width: 9px;
  height: 9px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform var(--trans), border-color var(--trans);
}
.tl-card.is-open .tl-arrow { color: var(--accent); }
.tl-card.is-open .tl-arrow::before { transform: rotate(-135deg); }
svg.tl-arrow {
  flex: 0 0 24px;
  width: 24px !important;
  height: 24px !important;
  display: block;
}
svg.tl-arrow::before { content: none; }
svg.tl-arrow polyline { stroke: currentColor; }
.tl-card.is-open svg.tl-arrow { transform: rotate(180deg) !important; }

.tl-body { max-height: 0; overflow: hidden; transition: max-height .35s ease; }
.tl-body-inner {
  padding: 0 18px 18px 68px;
  font-size: 14px; color: var(--text); opacity: .85; line-height: 1.7;
}
.tl-body-inner p + p { margin-top: 10px; }
.tl-body-inner .sub-role {
  font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--accent); margin: 14px 0 6px; display: block;
}
.tl-body-inner .projects { margin-top: 14px; font-size: 13px; color: var(--muted); }
.tl-body-inner .projects strong { color: var(--text); }

/* no-js fallback */
.no-js .tl-body { max-height: none !important; }

@media (min-width: 701px) {
  .tl-header { cursor: default; align-items: flex-start; }
  .tl-arrow { display: none; }
  .tl-body {
    max-height: none !important;
    overflow: visible;
  }
  .tl-body-inner {
    padding: 0 18px 20px 68px;
    opacity: .88;
  }
  .tl-company,
  .tl-role {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
  }
}

/* ── CERTIFICATIONS ── */
.compact-section { padding-top: 30px; padding-bottom: 30px; }
.cert-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.cert-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow);
}
.cert-card h3 {
  font-size: 15px;
  line-height: 1.25;
  color: var(--heading);
  margin-bottom: 8px;
}
.cert-card p {
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
}

/* ── FAQ ── */
.faq-intro {
  font-size: 14px; color: var(--muted); line-height: 1.7;
  max-width: 820px; margin-bottom: 22px;
  border-left: 3px solid var(--border); padding-left: 14px;
}
.faq-list { display: grid; gap: 8px; }

.faq-item {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  transition: border-color var(--trans), background var(--trans);
}
.faq-item:hover { border-color: rgba(8,145,178,.35); }
.faq-item[open] { border-color: rgba(8,145,178,.55); }
body.dark .faq-item:hover { border-color: rgba(61,142,248,.3); }
body.dark .faq-item[open] { border-color: rgba(61,142,248,.45); }

.faq-item summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 13px 18px; cursor: pointer;
  font-size: 14px; font-weight: 600; color: var(--text);
  list-style: none; user-select: none;
  transition: color var(--trans);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::marker { display: none; }
.faq-item summary:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; border-radius: var(--radius); }
.faq-item[open] summary { color: var(--heading); }

.faq-icon {
  flex-shrink: 0; width: 20px; height: 20px; color: var(--muted);
  transition: transform var(--trans), color var(--trans);
  position: relative;
}
.faq-icon::before,
.faq-icon::after {
  content: ''; position: absolute;
  background: currentColor; border-radius: 2px;
  transition: transform var(--trans), opacity var(--trans);
}
.faq-icon::before { width: 10px; height: 2px; top: 9px; left: 5px; }
.faq-icon::after  { width: 2px; height: 10px; top: 5px; left: 9px; }
.faq-item[open] .faq-icon::after { transform: rotate(90deg); opacity: 0; }
.faq-item[open] .faq-icon { color: var(--accent); }

.faq-body {
  padding: 0 20px 18px 20px;
  font-size: 14px; color: var(--text); opacity: .82; line-height: 1.75;
}

/* ── PROJECTS ── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}
.project-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px 22px 20px;
  display: block; color: var(--text);
  transition: border-color var(--trans), transform var(--trans), box-shadow var(--trans);
}
.project-card:hover {
  border-color: var(--accent); transform: translateY(-2px); text-decoration: none; color: var(--text);
  box-shadow: 0 8px 24px rgba(8,145,178,.12);
}
body.dark .project-card:hover { box-shadow: 0 8px 24px rgba(61,142,248,.1); }
.project-card .proj-icon { font-size: 22px; margin-bottom: 10px; }
.project-card .proj-logo {
  display: block; height: 34px; width: auto; max-width: 100%;
  object-fit: contain; object-position: left center;
  margin-bottom: 14px; border-radius: 5px;
}
.project-card h3 { font-size: 15px; font-weight: 700; color: var(--heading); margin-bottom: 7px; }
.project-card p { font-size: 13px; color: var(--muted); line-height: 1.6; }
.project-card .proj-link {
  display: inline-block; margin-top: 12px;
  font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent);
}

/* ── FOOTER ── */
.site-footer {
  padding: 48px 0 36px;
  border-top: 1px solid var(--border);
  background: var(--surface);
  transition: background var(--trans);
}
.footer-name { font-size: 18px; font-weight: 800; color: var(--heading); margin-bottom: 6px; }
.footer-contact { font-size: 13px; color: var(--muted); margin-bottom: 24px; }
.footer-contact a { color: var(--muted); transition: color var(--trans); }
.footer-contact a:hover { color: var(--accent); text-decoration: none; }
.footer-btns { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 32px; }
.footer-copy { font-size: 12px; color: var(--muted); opacity: .6; }

/* ── RESPONSIVE ── */
@media (min-width: 640px) {
  .hero { padding: 80px 0 60px; }
}
@media (max-width: 700px) {
  .hero-layout { grid-template-columns: 1fr; }
  .hero-photo-wrap { display: none; }
  .hero-layout {
    border-radius: 0;
    border: 0;
    box-shadow: none;
    padding: 0;
    background: transparent;
  }
}
@media (max-width: 500px) {
  .topbar-nav > a:not([href^="http"]):not([href^="."]) { display: none; }
  .topbar-nav .lang-switch { border: none; padding: 0; margin: 0; }
  .tl-body-inner { padding-left: 22px; }
}

/* Compact portrait mobile layout */
@media (max-width: 700px) {
  body { font-size: 15px; line-height: 1.5; }
  .container { padding: 0 14px; }

  .topbar { border-bottom-color: rgba(8,145,178,.16); }
  .topbar-inner { height: 44px; }
  .topbar-brand { font-size: 13px; letter-spacing: .02em; }
  .topbar-nav { gap: 2px; }
  .topbar-nav > a:not([href^="http"]):not([href^="."]) { display: none; }
  .topbar-nav a { padding: 3px 7px; font-size: 12px; }
  .lang-switch { border-left: 0; padding-left: 0; margin-left: 2px; }
  .lang-switch a { padding: 2px 6px; }
  .theme-toggle { width: 30px; height: 30px; margin-left: 2px; border-color: transparent; }

  .hero { padding: 34px 0 28px; border-bottom: 0; }
  .hero-bg { opacity: .7; }
  .hero-grid { background-size: 36px 36px; opacity: .45; }
  .hero-label {
    margin-bottom: 10px;
    padding: 3px 9px;
    border: 0;
    font-size: 9px;
    letter-spacing: .1em;
  }
  .hero h1 {
    margin-bottom: 6px;
    font-size: clamp(30px, 11vw, 42px);
    line-height: 1.04;
  }
  .hero-born { font-size: .45em; vertical-align: baseline; }
  .hero-sub { margin-bottom: 10px; font-size: 13px; line-height: 1.4; }
  .hero-contact { gap: 4px 10px; margin-bottom: 14px; font-size: 12px; }
  .hero-summary { display: none; }
  .hero-tagline {
    margin-bottom: 16px;
    padding-left: 10px;
    border-left-width: 2px;
    font-size: 13px;
    line-height: 1.45;
  }
  .hero-cta { gap: 8px; }
  .btn { padding: 9px 12px; border-radius: 7px; font-size: 13px; }

  .section {
    padding: 28px 0;
    border-bottom-color: rgba(8,145,178,.14);
  }
  .hero + .section { padding-top: 30px; }
  .section-head { margin-bottom: 14px; }
  .section-label { margin-bottom: 5px; font-size: 9px; letter-spacing: .12em; }
  .section-head h2 { font-size: 22px; line-height: 1.12; }

  .comp-grid { gap: 7px; }
  .comp-tag {
    padding: 6px 9px;
    border-color: rgba(8,145,178,.14);
    border-radius: 999px;
    font-size: 12px;
    line-height: 1.35;
  }
  .comp-tag .icon { margin-right: 4px; }
  .comp-tag:nth-child(n+7) { display: none; }

  .timeline {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 0;
  }
  .timeline::before { display: none; }
  .timeline, .faq-list { gap: 6px; }
  .tl-card:nth-of-type(5),
  .tl-card:nth-of-type(8),
  .tl-card:nth-of-type(9),
  .tl-card:nth-of-type(10) { display: none; }
  .tl-card::before,
  .tl-card::after { display: none; }
  .tl-card, .faq-item, .project-card {
    border-color: rgba(8,145,178,.14);
    border-radius: 8px;
    box-shadow: none;
  }
  .tl-header { gap: 9px; padding: 10px 12px; }
  .tl-icon { width: 30px; height: 30px; border: 0; border-radius: 7px; font-size: 15px; }
  .tl-period {
    margin-bottom: 1px;
    gap: 5px;
    font-size: 9px;
    letter-spacing: .08em;
    line-height: 1.25;
  }
  .badge-current { padding: 1px 6px; font-size: 8px; }
  .tl-company { font-size: 14px; line-height: 1.22; white-space: normal; }
  .tl-role { font-size: 11px; line-height: 1.32; white-space: normal; }
  .tl-arrow { flex-basis: 22px; width: 22px !important; height: 22px !important; }
  .tl-body-inner {
    padding: 0 12px 12px 51px;
    font-size: 13px;
    line-height: 1.55;
  }
  .tl-body-inner p + p { margin-top: 7px; }
  .tl-body-inner .projects { margin-top: 8px; font-size: 12px; }

  .faq-intro {
    display: none;
    margin-bottom: 14px;
    padding-left: 10px;
    border-left-width: 2px;
    font-size: 13px;
    line-height: 1.55;
  }
  .faq-item:nth-of-type(n+6) { display: none; }
  .faq-item summary { padding: 10px 12px; gap: 10px; font-size: 13px; line-height: 1.35; }
  .faq-icon { width: 18px; height: 18px; }
  .faq-icon::before { top: 8px; left: 4px; }
  .faq-icon::after { top: 4px; left: 8px; }
  .faq-body { padding: 0 12px 12px; font-size: 13px; line-height: 1.55; }

  .projects-grid { grid-template-columns: 1fr; gap: 8px; }
  .project-card:nth-child(n+3) { display: none; }
  .project-card { padding: 14px; }
  .project-card .proj-icon { margin-bottom: 4px; font-size: 18px; }
  .project-card h3 { margin-bottom: 4px; font-size: 14px; }
  .project-card p { font-size: 12px; line-height: 1.45; }
  .project-card .proj-link { margin-top: 8px; font-size: 10px; }

  .interests-text { font-size: 13px; line-height: 1.5; }

  .compact-section { padding-top: 24px; padding-bottom: 24px; }
  .cert-grid { grid-template-columns: 1fr; gap: 8px; }
  .cert-card {
    padding: 13px 14px;
    border-color: rgba(8,145,178,.14);
    border-radius: 8px;
    box-shadow: none;
  }
  .cert-card h3 { margin-bottom: 4px; font-size: 14px; }
  .cert-card p { font-size: 12px; line-height: 1.45; }

  .site-footer {
    padding: 28px 0 24px;
    border-top-color: rgba(8,145,178,.14);
  }
  .footer-name { margin-bottom: 4px; font-size: 16px; }
  .footer-contact { margin-bottom: 14px; font-size: 12px; line-height: 1.55; }
  .footer-btns { gap: 8px; margin-bottom: 18px; }
  .footer-copy { font-size: 11px; }
}

@media (max-width: 700px) and (max-height: 760px) {
  .hero { padding-top: 24px; padding-bottom: 22px; }
  .hero-label { display: none; }
  .hero h1 { font-size: clamp(28px, 10vw, 38px); }
  .hero-summary { display: none; }
  .hero-tagline { margin-bottom: 12px; }
}

/* ════════════════════════════════════════════
   DYNAMIKA: scroll-reveal + hover (v20260626-cv2)
   ════════════════════════════════════════════ */

/* Scroll reveal – aktivní jen když JS nasadí .js-reveal na <html>,
   takže bez JS zůstává vše plně viditelné. */
html.js-reveal .section-head,
html.js-reveal .tl-card,
html.js-reveal .cert-card,
html.js-reveal .project-card,
html.js-reveal .comp-tag,
html.js-reveal .faq-item {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}
html.js-reveal .in-view {
  opacity: 1 !important;
  transform: none !important;
}

/* Hover oživení dlaždic */
.comp-tag {
  transition: border-color var(--trans), transform var(--trans), background var(--trans), color var(--trans);
}
.comp-tag:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  color: var(--accent);
}
.cert-card {
  transition: border-color var(--trans), transform var(--trans), box-shadow var(--trans);
}
.cert-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent);
  box-shadow: 0 8px 24px rgba(8,145,178,.12);
}

/* Respekt k vypnutým animacím */
@media (prefers-reduced-motion: reduce) {
  html.js-reveal .section-head,
  html.js-reveal .tl-card,
  html.js-reveal .cert-card,
  html.js-reveal .project-card,
  html.js-reveal .comp-tag,
  html.js-reveal .faq-item {
    opacity: 1 !important;
    transform: none !important;
    transition: none;
  }
  .tl-card:first-child::after { animation: none; }
}

/* ════════════════════════════════════════════
   SEBEVĚDOMÝ KONTRAST (v20260626-cv3)
   ════════════════════════════════════════════ */

/* Vyšší kontrast tlumeného textu */
:root { --muted: #4a5a72; }
body.dark { --muted: #93a9c4; }

/* Výraznější nadpisy + akcentní pruh u labelu */
.section-head h2 { font-size: clamp(24px, 4vw, 38px); letter-spacing: -.03em; }
.section-label { font-size: 11px; position: relative; padding-left: 26px; }
.section-label::before {
  content: ""; position: absolute; left: 0; top: 50%;
  width: 18px; height: 2px; background: var(--accent); transform: translateY(-50%);
}

/* Rytmus sekcí – střídání pozadí */
.section:nth-of-type(even) { background: rgba(8,145,178,.05); }
body.dark .section:nth-of-type(even) { background: rgba(61,142,248,.06); }

/* Karty víc vystoupí + výraznější hover */
.tl-card, .cert-card, .project-card { border-color: #cfe1e6; }
body.dark .tl-card, body.dark .cert-card, body.dark .project-card { border-color: var(--border); }
.project-card:hover, .cert-card:hover { transform: translateY(-4px); }

/* Silnější typografická hierarchie v ose (desktop) */
@media (min-width: 701px) {
  .tl-company { font-size: 17px; font-weight: 800; letter-spacing: -.01em; }
  .tl-role { font-size: 12.5px; }
  .tl-period { font-size: 12px; letter-spacing: .12em; }
}

/* Plynulejší reveal (kaskádu řídí JS přes transition-delay) */
html.js-reveal .section-head,
html.js-reveal .tl-card,
html.js-reveal .cert-card,
html.js-reveal .project-card,
html.js-reveal .comp-tag,
html.js-reveal .faq-item { transition-timing-function: cubic-bezier(.2,.7,.2,1); }

/* ════════════════════════════════════════════
   TYPOGRAFICKÁ ŠKÁLA – sjednocení (v20260626-cv5)
   stupně: 11 / 13 / 15 / 18 / 28 / 34
   ════════════════════════════════════════════ */

/* Display + nadpisy – stažené extrémy */
.hero h1 { font-size: clamp(26px, 4.2vw, 34px); }
.hero-born { font-size: .5em; }
.section-head h2 { font-size: clamp(22px, 3vw, 28px); }

/* Tělo – jednotně 15 px */
.hero-summary, .hero-tagline,
.tl-body-inner, .tl-body-inner p,
.faq-body, .faq-item summary { font-size: 15px; }

/* Podtitul + mezinadpisy karet – 16 px */
.hero-sub { font-size: 16px; }
.cert-card h3, .project-card h3 { font-size: 16px; }

/* Malé texty – jednotně 13 px */
.hero-contact,
.tl-role, .tl-period,
.cert-card p, .project-card p,
.tl-body-inner .projects { font-size: 13px; }

/* Mikro labely – 11 px */
.hero-label, .section-label { font-size: 11px; }

/* Název firmy v ose jako mezinadpis (jen desktop, mobil ponechán) */
@media (min-width: 701px) {
  .tl-company { font-size: 18px; }
}

/* ════════════════════════════════════════════
   KOMPAKTNÍ HERO + méně prázdna (v20260626-cv6)
   ════════════════════════════════════════════ */

/* Jméno v hlavičce (topbar) zvětšené – lišta neroste */
.topbar-brand { font-size: 18px; letter-spacing: .02em; }
/* Jméno v hero ponecháno dle škály (≤34 px) */

@media (min-width: 701px) {
  /* Hero karta užší a vycentrovaná → zmizí prázdno vpravo */
  .hero { padding: 38px 0 28px; }
  .hero-layout {
    max-width: 960px; margin: 0 auto;
    padding: 26px 30px; gap: 34px;
    align-items: center;          /* fotka na střed → zmizí prázdno dole */
  }
  .hero-photo { width: 176px; }
  .hero-photo-wrap { margin-bottom: 0; }   /* zruší přesah a prázdno pod fotkou */
  /* Menší mezera hero → první sekce */
  .hero + .section { padding-top: 24px; }
}

/* Hutnější sekce celkově */
.section { padding: 26px 0; }
.section-head { margin-bottom: 16px; }

/* ════════════════════════════════════════════
   SVĚTLEMODRÁ VLNA V HERO (v20260626-cv7)
   ════════════════════════════════════════════ */
.hero-bg {
  background: radial-gradient(ellipse 58% 55% at 82% 24%, rgba(8,145,178,.07), transparent 70%);
}
/* Vlna jako samostatná vrstva → může se pomalu posouvat (drift) */
.hero-bg::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0; height: 72%;
  background: url(../assets/hero-wave.svg) 0 bottom / 1440px 100% repeat-x;
  animation: waveDrift 36s linear infinite;
  pointer-events: none;
}
@keyframes waveDrift {
  from { background-position-x: 0; }
  to   { background-position-x: 1440px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg::after, .site-footer::before { animation: none; }
}
/* tmavý motiv ponechá svůj decentní gradient (světlá vlna by na tmavé rušila) */

/* ════════════════════════════════════════════
   ZRCADLOVÁ VLNA V PATIČCE (v20260626-cv8) – bookend
   ════════════════════════════════════════════ */
.site-footer { position: relative; overflow: hidden; }
.site-footer::before {
  content: "";
  position: absolute; left: 0; right: 0; top: 0;
  height: 130px;
  background: url(../assets/hero-wave.svg) 0 center / 1440px 100% repeat-x;
  transform: scaleY(-1);          /* překlopení → vlna míří dolů do patičky */
  opacity: .8;
  pointer-events: none;
  animation: waveDrift 46s linear infinite;   /* pomalejší rytmus než hero */
}
.site-footer .container { position: relative; z-index: 1; }
body.dark .site-footer::before { opacity: .25; }

/* ════════════════════════════════════════════
   OBÁLKA PROJEKTU – cover obrázek (hra) (v20260627-cv10)
   ════════════════════════════════════════════ */
.project-card .proj-cover {
  display: block; width: 100%; height: 66px;
  object-fit: cover; border-radius: 8px;
  margin-bottom: 14px;
}
