:root {
  --ink: #1b2430;
  --ink-soft: #4a5568;
  --paper: #ffffff;
  --paper-alt: #f4f6f8;
  --line: #dde3e8;
  --accent: #1d4e6b;
  --radius: 10px;
  --wrap: 960px;
  --shell: 1200px;
  --page-bg: #e7ecf1;
  --font: Verdana, Tahoma, Geneva, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
  font-size: clamp(0.95rem, 0.89rem + 0.3vw, 1.05rem);
}

h1, h2, h3, h4 {
  font-family: var(--font);
  line-height: 1.3;
  color: var(--ink);
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(1.9rem, 1.4rem + 2.2vw, 3rem); }
h2 { font-size: clamp(1.3rem, 1.1rem + 1vw, 1.8rem); }
h3.lead, h2.lead { color: var(--accent); font-size: clamp(1.05rem, 1rem + 0.4vw, 1.25rem); }
h3 { font-size: 1.05rem; margin-top: 1.2em; }
h4 { font-size: 1.05rem; margin-bottom: 0.4em; }

p { margin: 0 0 1em; }
ul { margin: 0 0 1em; padding-left: 1.2em; }
li { margin-bottom: 0.4em; }

a { color: var(--accent); }

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Outer bars (header/footer) span the full shell width */
.wrap-shell {
  max-width: var(--shell);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Page shell: on wide screens the whole site renders as a ~1200px
   card centered on a soft side background, LinkedIn-style. Below the
   breakpoint the shell simply fills the viewport (no visual change). */
.page-shell {
  max-width: var(--shell);
  margin: 0 auto;
  background: var(--paper);
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: rgba(255,255,255,0.95);
  backdrop-filter: saturate(180%) blur(6px);
  z-index: 20;
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.brand {
  font-weight: 700;
  font-size: 1rem;
}

.site-header nav { display: flex; gap: 1.25rem; }
.site-header nav a {
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 0.9rem;
}
.site-header nav a:hover { color: var(--accent); }

/* Sections stacked, mobile-first */
.section { padding: 2.75rem 0; scroll-margin-top: 64px; }
.section.alt { background: var(--paper-alt); }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.8rem;
  color: var(--ink-soft);
}

/* Hero banner with parallax photo */
.hero-section {
  position: relative;
  overflow: hidden;
  min-height: 56vh;
  display: flex;
  align-items: flex-end;
  scroll-margin-top: 64px;
  color: #fff;
}

.hero-visual {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: #10171f;
}

.hero-visual img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 145%;
  object-fit: cover;
  will-change: transform;
  transform: translate3d(0,0,0);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(12,18,26,0.16) 0%, rgba(12,18,26,0.22) 45%, rgba(12,18,26,0.72) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  padding-top: 3rem;
  padding-bottom: 2.75rem;
}

.hero-content .eyebrow { color: #dcecf3; text-shadow: 0 1px 3px rgba(0,0,0,0.35); }
.hero-content h1 { color: #fff; margin-bottom: 0.35em; text-shadow: 0 2px 6px rgba(0,0,0,0.45); }
.hero-content .lead {
  color: #eef4f7;
  font-size: clamp(1.05rem, 1rem + 0.4vw, 1.25rem);
  max-width: 42em;
  margin: 0;
  text-shadow: 0 1px 3px rgba(0,0,0,0.35);
}

@media (prefers-reduced-motion: reduce) {
  .hero-visual img { transform: none !important; }
}

/* Intro (znalecké oprávnění) */
.intro-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

/* Posudky cards */
.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 1rem;
}

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem 1.4rem;
}
.section.alt .card { background: var(--paper); }
.card.wide { margin-top: 1rem; }

/* Kontakt */
.kontakt-inner {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  align-items: flex-start;
}
.name { font-weight: 600; font-size: 1.05rem; }

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  align-items: center;
}
.badge {
  display: block;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.6rem 0.8rem;
  background: #fff;
  max-width: 260px;
  text-decoration: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.badge:hover, .badge:focus-visible {
  border-color: var(--accent);
  box-shadow: 0 4px 12px -6px rgba(20, 34, 46, 0.3);
}
.badge img { display: block; width: 100%; height: auto; }

/* Desktop breakpoint */
@media (min-width: 768px) {
  .hero-section { min-height: 68vh; }

  .intro-grid { grid-template-columns: 1fr 1fr; }

  .cards { grid-template-columns: 1fr 1fr; }

  .kontakt-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

/* Wide screens: reveal the side background around the ~1200px shell */
@media (min-width: 1264px) {
  body { background: var(--page-bg); }

  .site-header {
    background: rgba(255,255,255,0.97);
  }

  .page-shell {
    overflow: hidden;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 16px;
    box-shadow:
      0 0 0 1px var(--line),
      0 24px 48px -28px rgba(20, 34, 46, 0.28);
  }
}
