@charset "UTF-8";

/* ====== Proměnné a základ ====== */
:root {
  --bg: #0b0f0d;
  --neon: #00ff80;
  --neon-soft: rgba(0,255,128,0.35);
  --text: #f5fff9;
  --muted: #b8c7bf;
  --tile-bg: rgba(255,255,255,0.06);
  --tile-hover: rgba(0,255,128,0.12);
  --ring: rgba(0,255,128,0.55);
}

html, body { height: 100%; }

body {
  margin: 0;
  font-family: 'Orbitron', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 800px at 10% 10%, rgba(0,255,128,0.08), transparent 45%),
    radial-gradient(1000px 700px at 90% 20%, rgba(0,255,128,0.07), transparent 50%),
    repeating-linear-gradient(90deg, rgba(0,255,128,0.05) 0 1px, transparent 1px 80px),
    repeating-linear-gradient(0deg, rgba(0,255,128,0.04) 0 1px, transparent 1px 80px),
    url('background.jpg') center/cover fixed no-repeat,
    var(--bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  overflow-x: hidden;
}

/* Pokud v HTML zůstává .overlay, nechme ji světlejší, ať stránka není ponuřilá */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5); /* dříve 0.75 */
  z-index: 0;
}

/* Jemné „dýchání“ pozadí */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  animation: pulseGlow 8s ease-in-out infinite;
}
@keyframes pulseGlow {
  0%, 100% { filter: brightness(1); }
  50%      { filter: brightness(1.07); }
}

/* Respektovat omezení animací */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* ====== Hlavička / logo ====== */
header {
  text-align: center;
  margin-top: clamp(36px, 6vw, 80px);
  z-index: 1;
  padding: 0 16px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: clamp(10px, 2.2vw, 18px);
}

.logo h1 {
  font-size: clamp(28px, 6vw, 54px);
  color: var(--text);
  letter-spacing: 1.5px;
  text-shadow: 0 0 14px var(--neon-soft);
}

.triangle {
  width: clamp(44px, 10vw, 72px);
  height: auto;
  fill: none;
  stroke: var(--neon);
  stroke-width: 5;
  filter: drop-shadow(0 0 12px var(--neon-soft));
}

.tagline {
  font-size: clamp(12px, 2.8vw, 16px);
  color: var(--muted);
  margin-top: 8px;
  letter-spacing: 1px;
}

/* ====== Dlaždice (grid) ====== */
.tiles {
  display: grid;
  /* základ: flexibilní mřížka fungující dobře na šířku i výšku */
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: clamp(14px, 3vw, 26px);
  width: min(1100px, 92%);
  margin: clamp(28px, 6vw, 64px) auto;
  z-index: 1;
}

.tile {
  background: var(--tile-bg);
  border: 1.5px solid rgba(255,255,255,0.08);
  border-radius: 18px;
  text-align: center;
  padding: clamp(18px, 4.5vw, 32px) clamp(14px, 3.5vw, 24px);
  text-decoration: none;
  color: var(--text);
  box-shadow: 0 8px 24px rgba(0,0,0,0.25), 0 0 0 0 rgba(0,255,128,0);
  backdrop-filter: blur(6px);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease, background .25s ease;
  position: relative;
  overflow: hidden;
}

/* Horní neonová linka */
.tile::before {
  content: "";
  position: absolute; inset: 0 0 auto 0; height: 3px;
  background: linear-gradient(90deg, transparent, var(--neon), transparent);
  opacity: .55;
  transform: translateY(-6px);
  transition: transform .25s ease, opacity .25s ease;
}

.tile:hover,
.tile:focus-visible {
  background: var(--tile-hover);
  transform: translateY(-6px);
  box-shadow: 0 14px 36px rgba(0,0,0,0.35), 0 0 0 3px var(--ring);
  border-color: rgba(0,255,128,0.35);
}
.tile:hover::before,
.tile:focus-visible::before {
  transform: translateY(0);
  opacity: .85;
}

.tile .icon {
  font-size: clamp(24px, 5.2vw, 34px);
  margin-bottom: 8px;
}

.tile h2 {
  font-size: clamp(18px, 4.8vw, 22px);
  margin: 4px 0 6px;
}

.tile .desc {
  font-size: clamp(12px, 3.6vw, 14px);
  margin: 0;
  color: var(--muted);
}

/* ====== Patička ====== */
footer {
  text-align: center;
  margin-top: auto;
  padding: 18px;
  font-size: 0.95rem;
  color: #93a39a;
  z-index: 1;
}

/* ====== Breakpointy – tvrdé zajištění responzivity ====== */

/* Tablet: dvě kolony */
@media (min-width: 601px) and (max-width: 900px) {
  .tiles {
    grid-template-columns: 1fr 1fr !important;
  }
}

/* Telefon: jedna kolona */
@media (max-width: 600px) {
  .tiles {
    grid-template-columns: 1fr !important;
  }
  header { margin-top: 28px; }
  .tile { padding: 18px 16px; }
}

/* Focus pro klávesnici */
.tile:focus { outline: none; }
.tile:focus-visible {
  box-shadow: 0 0 0 3px var(--ring);
  border-color: rgba(0,255,128,0.4);
}

