/*
 * VD Robotics - v4
 * Vzhled stránky. Texty se upravují v index.html.
 * Samostatná animace v animace/robot-cell.svg obsahuje vlastní CSS i pohyby.
 * Pozdější opravy z v3 jsou sloučené přímo do příslušných sekcí níže.
 */
/* 1. Barvy a společný základ */
:root {
  --ink: #111820;
  --paper: #f3f1ec;
  --white: #ffffff;
  --muted: #69727b;
  --line: #d8d6d0;
  --orange: #ff791a;
  --orange-2: #ffad55;
  --max: 1240px;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  /* Při kliknutí na menu záhlaví nezakryje cílovou sekci. */
  scroll-padding-top: 100px;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, Aptos, "Segoe UI", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-decoration: none;
}
img {
  display: block;
  max-width: 100%;
}
svg {
  display: block;
}
.section-shell {
  width: min(var(--max), calc(100% - 48px));
  margin-inline: auto;
}
/* 2. Záhlaví zůstává nahoře při posouvání stránky */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  width: min(var(--max), calc(100% - 48px));
  height: 82px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 850;
  letter-spacing: .12em;
  font-size: 14px;
}
/* Původní bílé SVG logo je na světlém pozadí zobrazeno černě. */
.brand-logo {
  width: 72px;
  height: auto;
  filter: brightness(0);
}
.site-header nav {
  display: flex;
  align-items: center;
  gap: 34px;
  font-size: 14px;
  font-weight: 650;
}
.site-header nav a {
  transition: color .2s ease;
}
.site-header nav a:hover {
  color: var(--orange);
}
.nav-contact {
  padding: 11px 18px;
  border: 1px solid var(--ink);
  border-radius: 99px;
}
/* 3. Úvod a společné prvky */
.hero {
  min-height: 620px;
  padding: 72px 0 68px;
  display: grid;
  grid-template-columns: .88fr 1.12fr;
  align-items: center;
  gap: 58px;
}
.kicker {
  margin: 0 0 25px;
  color: var(--muted);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.hero h1, .contact h2 {
  margin: 0;
  letter-spacing: -.065em;
  font-weight: 820;
}
.hero h1 {
  font-size: clamp(42px, 4.6vw, 68px);
  line-height: .93;
}
.hero h1 em, .contact h2 em {
  color: var(--orange);
  font-style: normal;
}
.hero-lead {
  max-width: 590px;
  margin: 27px 0 0;
  color: #4f5962;
  font-size: 17px;
  line-height: 1.62;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}
.button {
  min-height: 51px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 0 23px;
  border-radius: 99px;
  font-size: 14px;
  font-weight: 800;
  transition: transform .2s ease, background .2s ease;
}
.button svg, .contact-links svg {
  width: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}
.button:hover {
  transform: translateY(-2px);
}
.button.primary {
  background: var(--ink);
  color: var(--white);
}
.button.primary:hover {
  background: var(--orange);
}
.secondary-button {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .55);
}
/* Pouze rámeček animace. Vlastní kresba a @keyframes jsou v samostatném SVG. */
.robot-cell {
  position: relative;
  overflow: hidden;
  border-radius: 4px 40px 4px 40px;
  background: var(--ink);
  box-shadow: 0 30px 80px rgb(17 24 32 / .22);
}
.robot-cell::before {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  background: radial-gradient(circle at 45% 70%, rgb(255 121 26 / .12), transparent 28%), linear-gradient(145deg, rgb(255 255 255 / .05), transparent 45%);
  pointer-events: none;
}
.robot-animation {
  position: relative;
  width: 100%;
  height: auto;
}
/* 4. Co dělám
 * padding = mezery kolem celé sekce; margin-bottom u nadpisu = mezera ke kartám.
 * Sloupce nadpisů zachovávají rozložení dodané v3.
 */
.services {
  padding: 120px 0 100px;
}
.section-heading {
  display: grid;
  grid-template-columns: .5fr 1.1fr .75fr;
  align-items: end;
  gap: 50px;
  margin-bottom: 24px;
}
.section-heading .kicker {
  align-self: start;
  margin: 0;
  line-height: 1.7;
}
.service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.service-card {
  min-height: 300px;
  position: relative;
  padding: 32px 28px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgb(255 255 255 / .34);
  transition: transform .25s ease, background .25s ease;
}
.service-card:hover {
  transform: translateY(-7px);
  background: var(--white);
}
.service-card.featured {
  background: var(--ink);
  color: var(--white);
}
.card-number {
  position: absolute;
  right: 25px;
  top: 25px;
  color: #a2a7aa;
  font: 11px Consolas, monospace;
}
.service-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  margin-bottom: 50px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--orange);
  font-family: Consolas, monospace;
  font-weight: 800;
}
.featured .service-icon {
  border-color: #46515a;
}
.service-card h3 {
  margin: 0 0 15px;
  font-size: 20px;
  letter-spacing: -.025em;
}
.service-card p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}
.featured p {
  color: #aeb6bd;
}
/* 5. Nadpis Práce na projektech (v obsahu v3 nyní „Zkušenosti“)
 * Nadpis a první čára projektů začínají shodně na 28 % šířky obsahové části.
 */
.experience {
  background: var(--ink);
  color: var(--white);
  padding: 125px 0 78px;
}
.experience .section-heading {
  display: block;
  margin-left: 28%;
}
.section-heading.light .kicker {
  color: var(--orange-2);
}
.timeline {
  margin-left: 28%;
}
.timeline article {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 35px;
  padding: 38px 0;
  border-top: 1px solid #35404a;
}
.timeline article:last-child {
  border-bottom: 1px solid #35404a;
}
.timeline-year {
  padding-top: 4px;
  color: #8d969e;
  font: 12px Consolas, monospace;
  letter-spacing: .06em;
}
.timeline h3 {
  margin: 0 0 12px;
  font-size: 21px;
}
.timeline ul {
  max-width: 760px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: #aab2b9;
  line-height: 1.72;
}
.timeline li {
  position: relative;
  padding-left: 18px;
}
.timeline li::before {
  content: "/";
  position: absolute;
  left: 0;
  color: var(--orange-2);
  font-weight: 800;
}
.project-strip {
  margin-top: 85px;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  color: #717b83;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .14em;
}
/* 6. O mně - text pod nadpisem přes celou šířku */
.about {
  padding: 100px 0;
}
.about-copy .kicker {
  margin: 0 0 24px;
  color: var(--muted);
  line-height: 1.4;
}
.about-lead, .about-note {
  width: 100%;
  margin: 0;
  color: #4f5962;
  font-size: 16px;
  line-height: 1.8;
  text-align: left;
}
.about-note {
  margin-top: 22px;
}
/* 7. Vzdělání, školení a certifikace */
.expertise {
  padding: 10px 0 100px;
}
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
.expertise-grid article {
  min-height: 320px;
  padding: 36px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgb(255 255 255 / .3);
}
.expertise-grid h3 {
  margin: 0 0 28px;
  font-size: 20px;
  letter-spacing: -.025em;
}
.expertise-grid ul {
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  columns: 2;
  column-gap: 28px;
}
.expertise-grid li {
  position: relative;
  break-inside: avoid;
  padding: 0 0 10px 16px;
  font-size: 14px;
  line-height: 1.55;
}
.expertise-grid li::before {
  content: "/";
  position: absolute;
  left: 0;
  color: var(--orange);
  font-weight: 800;
}
/* 8. Kontakt */
.contact {
  position: relative;
  overflow: hidden;
  background: #dfe5e5;
  padding: 115px 0;
}
.contact::after {
  content: "VD";
  position: absolute;
  right: -35px;
  bottom: -145px;
  color: rgb(17 24 32 / .045);
  font-size: 400px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: -.11em;
}
.contact-inner {
  position: relative;
  z-index: 1;
}
/* clamp(minimum, hodnota podle šířky okna, maximum) - hodnoty převzaté z v3. */
.contact h2 {
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.1;
}
.contact-availability {
  margin: 30px 0 0;
  color: #5d686d;
  font-size: 17px;
}
.contact-links {
  width: min(720px, 100%);
  margin-top: 65px;
}
.contact-links a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 4px;
  border-top: 1px solid #aeb8ba;
  font-size: clamp(17px, 2vw, 20px);
  font-weight: 700;
  letter-spacing: -.035em;
}
.contact-links a:last-child {
  border-bottom: 1px solid #aeb8ba;
}
.contact-links a:hover {
  color: var(--orange);
}
/* 9. Zápatí */
.site-footer {
  min-height: 120px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  gap: 20px;
  color: var(--muted);
  font-size: 12px;
}
.site-footer p:nth-child(2) {
  text-align: center;
}
.site-footer p:last-child {
  text-align: right;
}
/* 10. Tablety a menší okna */
@media (max-width: 1050px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 65px;
  }
  .robot-cell {
    max-width: 820px;
  }
  .section-heading {
    grid-template-columns: 1fr 1fr;
  }
  .section-heading > p:last-child {
    grid-column: 2;
  }
  .service-grid {
    grid-template-columns: 1fr 1fr;
  }
  .expertise-grid ul {
    columns: 1;
  }
}
/* 11. Mobilní rozložení */
@media (max-width: 760px) {
  .section-shell, .site-header {
    width: min(100% - 32px, var(--max));
  }
  .site-header {
    height: 76px;
  }
  .site-header nav a:not(.nav-contact) {
    display: none;
  }
  .site-header nav {
    gap: 0;
  }
  .hero {
    min-height: auto;
    padding: 64px 0 75px;
    gap: 48px;
  }
  .hero h1 {
    font-size: clamp(40px, 12vw, 56px);
  }
  .hero-lead {
    font-size: 16px;
  }
  .robot-cell {
    margin-inline: -8px;
  }
  .services {
    padding: 85px 0 75px;
  }
  .section-heading {
    display: block;
  }
  .section-heading > p:last-child {
    margin-top: 23px;
  }
  .service-grid {
    grid-template-columns: 1fr;
  }
  .service-card {
    min-height: 270px;
  }
  .service-icon {
    margin-bottom: 44px;
  }
  .experience {
    padding: 90px 0 60px;
  }
  /* Na mobilu jsou projekty přes celou šířku. */
  .experience .section-heading, .timeline {
    margin-left: 0;
  }
  .timeline article {
    grid-template-columns: 1fr;
    gap: 13px;
  }
  .project-strip {
    margin-top: 55px;
    flex-wrap: wrap;
    justify-content: flex-start;
  }
  .about {
    padding: 75px 0;
  }
  .expertise {
    padding: 0 0 75px;
  }
  .expertise-grid {
    grid-template-columns: 1fr;
  }
  .expertise-grid article {
    min-height: auto;
  }
  .contact {
    padding: 90px 0;
  }
  .contact::after {
    font-size: 240px;
    bottom: -75px;
  }
  .site-footer {
    padding: 35px 0;
    grid-template-columns: 1fr;
  }
  .site-footer p, .site-footer p:nth-child(2), .site-footer p:last-child {
    margin: 0;
    text-align: left;
  }
}
/* 12. Respektování nastavení omezeného pohybu v systému návštěvníka.
 * Samostatné SVG má stejnou podporu ve svém vlastním \3c style> bloku.
 */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
