/* docs/css/extra.css */

/* Mřížka pro předměty */
.grid-predmety {
  display: grid;
  grid-template-columns: repeat(
    auto-fit,
    minmax(250px, 1fr)
  ); /* Automatické přizpůsobení */
  gap: 20px;
  margin: 1em 0;
}

/* Styl karty */
.karta {
  padding: 0; /* Padding řešíme uvnitř odkazu pro lepší klikatelnost */
  border-radius: 16px;
  text-align: center;
  background: linear-gradient(145deg, #6a11cb, #2575fc);
  color: white;
  font-weight: 500;
  font-size: 1.1rem;
  transition: all 0.4s ease;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  position: relative;
  overflow: hidden;
  display: flex; /* Zarovnání obsahu */
  align-items: center;
  justify-content: center;
}

/* Efekt najetí myší na kartu */
.karta:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.2);
  background: linear-gradient(145deg, #2575fc, #6a11cb); /* Prohození barev */
}

/* Styl odkazu uvnitř karty - aby byl klikatelný celý čtverec */
.karta a {
  text-decoration: none;
  color: white !important; /* Vynucení bílé barvy textu */
  display: block;
  width: 100%;
  height: 100%;
  padding: 25px 15px;
  z-index: 2; /* Aby byl text nad efektem pozadí */
  position: relative;
}

.karta a:hover {
  color: white;
}

/* Lesklý efekt přes kartu */
.karta::after {
  content: "";
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: rgba(255, 255, 255, 0.2);
  transform: skewX(-25deg);
  transition: all 0.5s ease;
  pointer-events: none; /* Aby to neblokovalo kliknutí */
}

.karta:hover::after {
  left: 125%;
}

/* Styl pro Info Boxy */
.info-box {
  background-color: var(--md-code-bg-color);
  padding: 25px 15px;
  border-radius: 8px;
  border: 4px solid var(--md-code-bg-color);
  margin-bottom: 1rem;
}
