/* michalbures.eu — personal site of Michal Bureš.
   Layout: the site on the left, the Pontra chat docked on the right on wide screens (≥ 1100 px);
   on smaller screens the chat is a full-screen sheet opened from a floating button. */

:root {
  --ink: #0b1020;
  --ink-2: #2a3352;
  --muted: #5b6480;
  --line: #e4e7f0;
  --bg: #ffffff;
  --bg-soft: #f5f7fb;
  --brand: #3b5bfd;
  --brand-2: #8b5cf6;
  --accent: #14b8a6;
  --dark: #0b1020;
  --dark-2: #141b33;
  --radius: 16px;
  --dock-w: 400px;
  --shadow: 0 10px 30px rgba(11, 16, 32, 0.08);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font: 16px / 1.6 "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img {
  max-width: 100%;
  display: block;
}
a {
  color: var(--brand);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
h1,
h2,
h3 {
  font-family: "Space Grotesk", "Inter", sans-serif;
  line-height: 1.15;
  margin: 0;
  letter-spacing: -0.01em;
}
h1 {
  font-size: clamp(2.2rem, 4.6vw, 3.6rem);
}
h2 {
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  margin-bottom: 0.6rem;
}
h3 {
  font-size: 1.12rem;
}
.container {
  width: min(1120px, 100% - 3rem);
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 100;
}
.skip-link:focus {
  left: 1rem;
}

/* ── Layout with the chat dock ─────────────────────────────────────────── */
.layout {
  min-height: 100vh;
}
.site {
  min-width: 0;
}

/* ── Navigation ────────────────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  font-weight: 700;
}
.brand:hover {
  text-decoration: none;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  font: 700 0.9rem "Space Grotesk", sans-serif;
}
.nav-links {
  display: flex;
  gap: 1.5rem;
}
.nav-links a {
  color: var(--ink-2);
  font-weight: 500;
  font-size: 0.95rem;
}

/* ── Buttons ───────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.7rem 1.15rem;
  border-radius: 999px;
  font: 600 0.95rem "Inter", sans-serif;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}
.btn-primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  box-shadow: 0 8px 20px rgba(59, 91, 253, 0.28);
}
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover {
  border-color: var(--ink-2);
}
.btn-on-dark {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
}
.btn-on-dark:hover {
  border-color: #fff;
}

/* ── Hero ──────────────────────────────────────────────────────────────── */
.hero {
  padding: clamp(3rem, 7vw, 6rem) 0 clamp(3rem, 6vw, 5rem);
  background: radial-gradient(60rem 30rem at 85% -10%, rgba(139, 92, 246, 0.12), transparent 60%),
    radial-gradient(50rem 30rem at -10% 10%, rgba(59, 91, 253, 0.1), transparent 60%);
}
.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.eyebrow,
.kicker {
  margin: 0 0 0.9rem;
  color: var(--brand);
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.kicker-gap {
  margin-top: 2.2rem;
}
.grad {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lead {
  font-size: 1.13rem;
  color: var(--ink-2);
  margin: 1.2rem 0 1.8rem;
  max-width: 40rem;
}
.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}
.stats {
  list-style: none;
  padding: 0;
  margin: 2.4rem 0 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.1rem 1.5rem;
  max-width: 36rem;
}
.stats li {
  border-left: 2px solid var(--line);
  padding-left: 0.8rem;
}
.stats b {
  display: block;
  font: 700 1.5rem "Space Grotesk", sans-serif;
}
.stats span {
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.35;
  display: block;
}
.hero-photo {
  margin: 0 0 0 auto;
  position: relative;
  width: 100%;
  max-width: 340px;
}
.hero-photo img {
  width: 100%;
  height: auto;
  border-radius: 28px;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 50% 20%;
  box-shadow: var(--shadow);
  background: var(--bg-soft);
}
.hero-photo figcaption {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
  font-weight: 500;
  box-shadow: var(--shadow);
}
.dot-live {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  margin-right: 0.3rem;
  vertical-align: 1px;
}

/* ── Sections ──────────────────────────────────────────────────────────── */
.section {
  padding: clamp(3.5rem, 7vw, 6rem) 0;
}
.section-soft {
  background: var(--bg-soft);
}
.section-lead {
  color: var(--ink-2);
  font-size: 1.05rem;
  max-width: 46rem;
  margin: 0 0 2.2rem;
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
}
.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem;
  background: #fff;
  transition: box-shadow 0.2s, transform 0.2s;
}
.card:hover {
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}
.card p {
  color: var(--muted);
  margin: 0.5rem 0 0;
  font-size: 0.95rem;
}
.card-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  margin-bottom: 0.9rem;
  background: rgba(59, 91, 253, 0.08);
  color: var(--brand);
  font-size: 1.2rem;
}

/* Pontra (dark) */
.section-dark {
  background: linear-gradient(160deg, var(--dark), var(--dark-2));
  color: #e8ebf7;
}
.section-dark .kicker {
  color: #9fb0ff;
}
.section-dark .section-lead {
  color: #c4cae0;
}
.pontra {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.checks {
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
  display: grid;
  gap: 0.7rem;
}
.checks li {
  padding-left: 1.6rem;
  position: relative;
  color: #c4cae0;
}
.checks li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}
.checks b {
  color: #fff;
}
.pipeline {
  display: grid;
  gap: 0.8rem;
}
.wave {
  display: flex;
  gap: 1rem;
  align-items: center;
  padding: 1rem 1.2rem;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.09);
}
.wave span {
  flex: none;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  font: 700 1rem "Space Grotesk", sans-serif;
}
.wave b {
  display: block;
  color: #fff;
}
.wave small {
  color: #9aa3c0;
}

/* Timeline */
.timeline {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
  border-left: 2px solid var(--line);
}
.timeline li {
  display: grid;
  grid-template-columns: 9rem 1fr;
  gap: 1.5rem;
  padding: 0 0 2rem 1.5rem;
  position: relative;
}
.timeline li::before {
  content: "";
  position: absolute;
  left: -7px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--brand);
}
.timeline time {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.9rem;
  padding-top: 0.1rem;
}
.timeline .where {
  color: var(--brand);
  font-size: 0.9rem;
  margin: 0.2rem 0 0.4rem;
  font-weight: 500;
}
.timeline p {
  margin: 0;
  color: var(--ink-2);
}
/* International experience */
.intl {
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 2rem;
  padding: 1.6rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-soft);
}
.intl h3 {
  font-size: 1.3rem;
  margin-bottom: 0.6rem;
}
.intl-copy p:last-child {
  color: var(--ink-2);
  margin: 0;
}
.places {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
  align-content: start;
}
.places li {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.6rem 0.8rem;
}
.places b {
  display: block;
  font-size: 0.95rem;
}
.places span {
  color: var(--muted);
  font-size: 0.82rem;
}
@media (max-width: 900px) {
  .intl {
    grid-template-columns: 1fr;
  }
}
.more {
  color: var(--muted);
}

/* Education & stack */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
}
.edu {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: grid;
  gap: 0.9rem;
}
.edu b {
  display: block;
}
.edu span {
  color: var(--muted);
  font-size: 0.92rem;
}
.chips {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.chips li {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0.35rem 0.8rem;
  font-size: 0.88rem;
  color: var(--ink-2);
}
.lang {
  color: var(--muted);
  margin-top: 1.4rem;
}

/* Contact */
.contact-inner {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.contact-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.2rem;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}
.contact-list li:last-child {
  border-bottom: 0;
}
.contact-list span {
  color: var(--muted);
}

.footer {
  border-top: 1px solid var(--line);
  padding: 1.5rem 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ── Chat dock ─────────────────────────────────────────────────────────── */
.chat-dock {
  display: flex;
  flex-direction: column;
  background: var(--dark);
  color: #e8ebf7;
}
.chat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.chat-id {
  display: flex;
  gap: 0.7rem;
  align-items: center;
}
.chat-id b {
  display: block;
  font-size: 0.98rem;
}
.chat-id small {
  color: #9aa3c0;
  font-size: 0.8rem;
}
.chat-avatar {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  font: 700 1rem "Space Grotesk", sans-serif;
}
.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: transparent;
  color: #e8ebf7;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
}
.icon-btn:hover {
  background: rgba(255, 255, 255, 0.06);
}
.chat-body {
  flex: 1;
  min-height: 0;
  display: flex;
}
.video-body {
  flex: 1;
  min-height: 0;
  display: flex;
}
.video-body[hidden],
.chat-body[hidden] {
  display: none;
}
.video-player {
  flex: 1;
  width: 100%;
  min-height: 0;
  background: #000;
  object-fit: contain;
  align-self: center;
}
.video-placeholder {
  flex: 1;
  display: grid;
  place-content: center;
  gap: 0.3rem;
  text-align: center;
  padding: 1.2rem;
  color: #9aa3c0;
}
.video-placeholder b {
  color: #fff;
}
.chat-frame {
  flex: 1;
  width: 100%;
  border: 0;
  background: var(--dark);
}
.chat-preview {
  padding: 1.2rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.bubble {
  border-radius: 14px;
  padding: 0.9rem 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
}
.bubble-bot {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.try {
  margin: 0.4rem 0 0;
  color: #9aa3c0;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.starters {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.5rem;
}
.starters li {
  border: 1px solid rgba(159, 176, 255, 0.35);
  color: #c9d3ff;
  border-radius: 12px;
  padding: 0.6rem 0.8rem;
  font-size: 0.92rem;
}
.soon {
  margin-top: auto;
  border-radius: 12px;
  padding: 0.9rem 1rem;
  background: rgba(20, 184, 166, 0.1);
  border: 1px solid rgba(20, 184, 166, 0.3);
  font-size: 0.88rem;
  color: #c4cae0;
}
.soon b {
  display: block;
  color: #fff;
  margin-bottom: 0.2rem;
}
.soon a {
  color: #5eead4;
}

.chat-fab {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.2rem;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: #fff;
  font: 600 0.95rem "Inter", sans-serif;
  box-shadow: 0 12px 30px rgba(59, 91, 253, 0.35);
}

/* Wide screens: the chat is docked on the right, full height, and can be collapsed. */
@media (min-width: 1100px) {
  .layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) var(--dock-w);
  }
  .chat-dock {
    position: sticky;
    top: 0;
    height: 100vh;
    border-left: 1px solid rgba(255, 255, 255, 0.08);
  }
  .container {
    width: min(1040px, 100% - 4rem);
  }
  .chat-fab {
    display: none;
  }
  .layout.dock-closed {
    grid-template-columns: minmax(0, 1fr);
  }
  .layout.dock-closed .chat-dock {
    display: none;
  }
  .layout.dock-closed .chat-fab {
    display: inline-flex;
  }
}

/* Narrow screens: a full-screen sheet behind the floating button. */
@media (max-width: 1099.98px) {
  .chat-dock {
    position: fixed;
    inset: 0;
    z-index: 50;
    transform: translateY(100%);
    transition: transform 0.25s ease;
    visibility: hidden;
  }
  .layout.sheet-open .chat-dock {
    transform: none;
    visibility: visible;
  }
  .layout.sheet-open .chat-fab {
    display: none;
  }
  body.no-scroll {
    overflow: hidden;
  }
}

@media (max-width: 900px) {
  .hero-inner,
  .pontra,
  .two-col,
  .contact-inner {
    grid-template-columns: 1fr;
  }
  .hero-photo {
    max-width: 260px;
    margin: 0;
    order: -1;
  }
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 640px) {
  .nav-links {
    display: none;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .timeline li {
    grid-template-columns: 1fr;
    gap: 0.3rem;
  }
  .fab-label {
    display: none;
  }
  .chat-fab {
    padding: 1rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .card,
  .btn,
  .chat-dock {
    transition: none;
  }
}
