/* ============================================================
   abcMedia Network — main.css
   Kompletní styly webu (extrahováno z index.html)
   ============================================================ */

:root {
  --navy: #2b2d42;
  --navy-deep: #21232f;
  --ink: #1c1e26;
  --ink-soft: #565a6b;
  --grey: #8d99ae;
  --bg-light: #f6f7f9;
  --white: #ffffff;
  --red: #ef233c;
  /* Značková červená má na bílé jen 4,2:1, což je pod WCAG AA pro běžný
     text. Pro drobné popisky slouží tmavší odstín, pro text na tmavém
     podkladu světlejší. Plochy, linky a ikony zůstávají na --red. */
  --red-ink: #d61f36;
  --red-light: #ff6b7a;
  /* Aliasy pro pages.css, který má vlastní názvy tokenů. Obě sady tak
     berou barvy z jednoho místa. */
  --red-text: var(--red-ink);
  --ink-faint: #666b7c; /* 4,9:1 na --bg-light; Michalův #6c7183 měl 4,49 */
  --paper: var(--white);
  --paper-alt: var(--bg-light);
  /* Šedá --grey má na podkladu fakturační karty (navy + 5 % bílé) jen
     4,0:1. Tenhle odstín tam dá 4,97:1. */
  --grey-light: #a0abbe;
  --line: #e3e5ea;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
}

.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--white);
  color: var(--ink);
  padding: 12px 20px;
  border-radius: 0 0 8px 0;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.skip:focus { left: 0; }
main:focus { outline: none; }

/* Prohlížeč sice vlastní obrys kreslí, ale na tmavě modré je špatně
   vidět. Vlastní rámeček drží 3:1 vůči podkladu na obou motivech. */
:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
  border-radius: 3px;
}
.hero :focus-visible,
.nav-panel :focus-visible,
footer :focus-visible { outline-color: var(--white); }

/* ---------- Hero ---------- */
.hero {
  background: var(--navy);
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.hero-lines {
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  width: 540px;
  max-width: 55vw;
  opacity: 0.9;
  pointer-events: none;
}

nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0;
  position: relative;
  z-index: 2;
}
nav .logo-svg { height: 30px; width: auto; display: block; }
nav ul { display: flex; gap: 32px; list-style: none; }
nav a {
  color: rgba(255,255,255,0.78);
  text-decoration: none;
  font-size: 15px;
  transition: color .15s;
}
nav a:hover { color: var(--white); }

/* Pilulky jen pro položky hlavního menu — ne pro logo, drobečky ani patičku */
.nav-panel ul a {
  display: block;
  padding: 8px 14px;
  border-radius: 100px;
  font-weight: 500;
  transition: background .15s, color .15s;
}
.nav-panel ul a:hover { background: rgba(255,255,255,0.10); }
.nav-panel ul a[aria-current="page"] { background: var(--red-ink); color: var(--white); }

/* Panel menu — na desktopu je to prostě vodorovná navigace */
.nav-panel { display: flex; align-items: center; }
.np-head,
.np-foot,
.nav-close,
.nav-panel em { display: none; }

/* Přepínač mobilního menu — na desktopu skrytý */
.nav-toggle {
  display: none;
  position: relative;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  padding: 0;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 8px;
  color: var(--white);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
/* Popisek je vidět jen tehdy, když se nenačte CSS — pak místo tlačítka
   zbyde čitelné „Menu" a ne čtyřpixelový puntík. */
.nav-toggle-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  white-space: nowrap;
  clip-path: inset(50%);
}
.nav-bar {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 90px 0 100px;
  max-width: 640px;
}

h1 {
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 20px;
}

.hero-content p.sub {
  color: rgba(255,255,255,0.76);
  font-size: 18px;
  margin-bottom: 56px;
  max-width: 480px;
}

.stats {
  display: flex;
  flex-wrap: nowrap;
  gap: 40px 56px;
}
.stat .num {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.stat .label {
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  margin-top: 2px;
}

/* ---------- Sections ---------- */
section { padding: 96px 0; }
/* Obal rolovatelné tabulky na podstránkách je <section> kvůli landmarku,
   odsazení sekce si ale nesmí vzít. */
section.table-scroll { padding: 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--red-ink);
  margin-bottom: 18px;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--red);
}

h2 {
  font-size: clamp(28px, 3.6vw, 38px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}

/* O nás */
.about-lead {
  font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 600;
  line-height: 1.45;
  max-width: 760px;
  margin-bottom: 20px;
}
.about-text {
  color: var(--ink-soft);
  max-width: 640px;
  font-size: 17px;
}
.about-text + .about-text { margin-top: 14px; }

/* Portfolio */
.portfolio { background: var(--bg-light); }
.portfolio .intro {
  color: var(--ink-soft);
  max-width: 92ch;
  margin-bottom: 48px;
  font-size: 17px;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 16px;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 22px 24px;
  text-decoration: none;
  transition: border-color .2s, transform .2s, box-shadow .2s;
  display: block;
  position: relative;
  overflow: hidden;
}
.card > div { position: relative; z-index: 1; }
.card:hover {
  border-color: var(--red);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(43,45,66,0.08);
}
.card .cat {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--red-ink);
}
.card .domain {
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  margin-top: 4px;
  word-break: break-word;
}
.card:hover .domain { color: var(--red-ink); }
.card-icon {
  position: absolute;
  right: -14px;
  bottom: -20px;
  width: 92px;
  height: 92px;
  color: #f4f6f9;
  stroke-width: 0.7;
  transform: rotate(-8deg);
  pointer-events: none;
  transition: color .25s;
}
.card:hover .card-icon { color: rgba(239,35,60,0.06); }
.card:hover .card-icon * {
  stroke: rgba(239,35,60,0.32);
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: icon-draw 1.6s ease-in-out forwards;
}
.card:hover .card-icon *:nth-child(2) { animation-delay: .14s; }
.card:hover .card-icon *:nth-child(3) { animation-delay: .28s; }
.card:hover .card-icon *:nth-child(4) { animation-delay: .42s; }
.card:hover .card-icon *:nth-child(5) { animation-delay: .56s; }
.card:hover .card-icon *:nth-child(6) { animation-delay: .7s; }
.card:hover .card-icon *:nth-child(7) { animation-delay: .84s; }
.card:hover .card-icon *:nth-child(8) { animation-delay: .98s; }
@keyframes icon-draw {
  to { stroke-dashoffset: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .card:hover .card-icon * {
    animation: none;
    stroke-dasharray: none;
    stroke-dashoffset: 0;
  }
}

/* ---------- LIVE TICKER ---------- */
.ticker {
  padding: 0;
  background: var(--navy-deep);
  color: var(--white);
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: stretch;
}
.ticker-label {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  /* Michalova značková červená má pod bílým textem 4,2:1; tmavší dá 5,1:1 */
  background: var(--red-ink);
  padding: 12px 22px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.18em;
  position: relative;
  z-index: 2;
  box-shadow: 8px 0 16px rgba(0,0,0,0.18);
}
.ticker-label time {
  font-weight: 600;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.85);
  font-variant-numeric: tabular-nums;
}
.onair-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--white);
  position: relative;
}
.onair-dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid #4ade80;
  opacity: 0;
  animation: pulse 1.6s ease-out infinite;
}
@keyframes pulse {
  0%   { transform: scale(0.6); opacity: 0.9; }
  70%  { transform: scale(1.5); opacity: 0; }
  100% { opacity: 0; }
}

.ticker-viewport {
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
  display: flex;
  align-items: center;
}
.ticker-track {
  display: inline-flex;
  animation: ticker 36s linear infinite;
  will-change: transform;
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-group { display: inline-flex; }
.ticker-group span {
  display: inline-block;
  padding: 12px 26px 12px 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.62);
}
.ticker-group span::before {
  content: "•";
  margin-right: 26px;
  opacity: 0.55;
}
@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .ticker-track { animation: none; }
  .onair-dot::after { animation: none; }
}

/* Tým */
.team .intro {
  color: var(--ink-soft);
  max-width: 92ch;
  margin-bottom: 48px;
  font-size: 17px;
}
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.person {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 24px;
  background: var(--white);
  display: flex;
  flex-direction: column;
  position: relative;
}
.p-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.p-head .avatar { margin-bottom: 0; }
.p-social {
  display: flex;
  gap: 14px;
  margin-top: auto;
  justify-content: flex-end;
}
.p-glyph {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink-faint);
  transition: color .15s, border-color .15s;
}
.p-glyph svg { width: 16px; height: 16px; display: block; }
.p-glyph:hover { border-color: var(--navy); color: var(--navy); }
.avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.03em;
  margin-bottom: 14px;
}
.p-name { font-weight: 700; font-size: 16px; }
.p-role { color: var(--ink-soft); font-size: 14px; margin: 2px 0 0; }
.p-sites {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  margin-bottom: 32px;
}
.chip {
  display: inline-flex;
  align-items: center;
  font-size: 12px;
  color: var(--ink-soft);
  background: var(--bg-light);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 11px;
  text-decoration: none;
  transition: border-color .15s, color .15s;
}
.chip:hover { border-color: var(--navy); color: var(--ink); }

/* Kontakt */
.contact {
  background: var(--bg-light);
  color: var(--ink);
}
.contact p.lead { color: var(--ink-soft); max-width: 92ch; font-size: 17px; }

footer {
  background: var(--navy);
  color: rgba(255,255,255,0.55);
  padding: 40px 0 26px;
  font-size: 13px;
}
.footer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255,255,255,0.10);
}
.footer-nav { display: flex; gap: 26px; flex-wrap: wrap; }
.footer-nav a,
.to-top {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  transition: color .2s;
}
.footer-nav a:hover,
.to-top:hover { color: var(--white); }
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 22px;
}
footer .logo-svg { height: 22px; width: auto; color: rgba(255,255,255,0.7); }

@media (max-width: 720px) {
  .nav-toggle { display: inline-flex; }

  /* nav má z-index 2 a tvoří vrstvící kontext — panel uvnitř se proto
     nedokáže dostat nad .hero-content, které má z-index taky 2 a je
     v DOM později. Kontext je potřeba zvednout tady, ne uvnitř panelu.
     Jen u hlavní navigace: drobečky a patička jsou taky <nav> a se
     stejným z-indexem by se kreslily přes otevřený panel. */
  nav[aria-label="Hlavní"] { z-index: 100; }

  /* Celoobrazovkový panel vyjíždějící zprava */
  .nav-panel {
    position: fixed;
    inset: 0;
    z-index: 100;
    flex-direction: column;
    align-items: stretch;
    padding: 22px 24px calc(22px + env(safe-area-inset-bottom, 0px));
    background: linear-gradient(160deg, var(--navy-deep) 0%, #1a1c2b 100%);
    overflow-y: auto;
    overscroll-behavior: contain;
    visibility: hidden;
    transform: translateX(100%);
    transition: transform .34s cubic-bezier(.32,.72,.24,1), visibility 0s linear .34s;
  }
  .nav-panel.is-open {
    visibility: visible;
    transform: translateX(0);
    transition: transform .34s cubic-bezier(.32,.72,.24,1), visibility 0s;
  }
  body.menu-open { overflow: hidden; }

  .np-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
  }
  .np-head .logo-svg { height: 26px; width: auto; display: block; }
  .nav-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    padding: 0;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.22);
    border-radius: 8px;
    color: var(--white);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .nav-close svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
  }

  .nav-panel ul {
    display: grid;
    gap: 2px;
    margin-top: 44px;
  }
  .nav-panel li a {
    display: flex;
    align-items: baseline;
    gap: 14px;
    padding: 10px 0;
    color: var(--white);
    font-size: clamp(28px, 9vw, 40px);
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.15;
    opacity: 0;
    transform: translateX(22px);
    transition: opacity .3s ease, transform .38s cubic-bezier(.32,.72,.24,1), color .2s;
  }
  .nav-panel em {
    display: block;
    font-style: normal;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--red-light);
  }
  .nav-panel ul a,
  .nav-panel ul a:hover,
  .nav-panel ul a[aria-current="page"] { background: none; border-radius: 0; }
  .nav-panel ul a[aria-current="page"] { color: var(--red-light); }
  .nav-panel.is-open li a { opacity: 1; transform: translateX(0); }
  .nav-panel.is-open li:nth-child(1) a { transition-delay: .10s; }
  .nav-panel.is-open li:nth-child(2) a { transition-delay: .16s; }
  .nav-panel.is-open li:nth-child(3) a { transition-delay: .22s; }
  .nav-panel.is-open li:nth-child(4) a { transition-delay: .28s; }

  .np-foot {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: auto;
    padding-top: 32px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.16em;
    color: var(--grey);
  }

  .hero-content { padding: 56px 0 72px; }

  /* Tři údaje na jednom řádku. Stejně široké sloupce lámaly dlouhý
     popisek do tří řádek, proto si každý blok bere šířku podle svého
     obsahu a zbytek místa se rozdělí do mezer mezi ně. nowrap drží
     řádek i na nejužších displejích — text se tam zalomí, blok ne. */
  .stats {
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
  }
  .stat { flex: 0 1 auto; }
  .stat .num { font-size: clamp(15px, 4.4vw, 26px); line-height: 1.2; }
  .stat .label {
    font-size: clamp(10px, 2.9vw, 12px);
    line-height: 1.35;
    margin-top: 4px;
  }
  .hero-lines { display: none; }
  section { padding: 64px 0; }
  
  
}

/* Vypnuté animace: panel naskočí rovnou, bez posuvu a prokreslování */
@media (prefers-reduced-motion: reduce) {
  .nav-panel { transition: transform 0s, visibility 0s; }
  .nav-panel li a { transition: none; opacity: 1; transform: none; }
  .nav-panel.is-open li a { transition-delay: 0s; }
}

/* ============ TISK ============ */
@media print {
  .hero,
  .contact,
  footer,
  .portfolio { background: #fff !important; color: #000 !important; }
  .hero-content p.sub,
  .stat .label,
  .contact .lead,
  footer,
  footer .logo-svg { color: #333 !important; }
  .contact a,
  

  .skip,
  .nav-toggle,
  .nav-panel,
  .ticker,
  .hero-lines,
  .card-icon,
  .p-social,
  .footer-nav,
  .to-top { display: none !important; }

  .hero-content { padding: 24px 0 32px; }
  section { padding: 32px 0; }
  .card,
  .person,
  
  
  .card::after,
  .card:hover::after { display: none; }
  .grid { gap: 12px; }
  h2 { break-after: avoid; }
}
