/* =========================
   styles.css
   ŠKL barvna shema
   Primarne: #00569d (modra), #e7891a (oranžna)
========================= */

:root {
  --color-primary: #00569d;
  --color-secondary: #e7891a;
  --color-dark: #002b50;
  --color-light: #f8f9fa;
  --color-muted: #6c757d;
}

/* Reset & base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html, body {
  font-family: 'Segoe UI', Roboto, sans-serif;
  color: #222;
  background-color: var(--color-light);
  line-height: 1.6;
}
a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.2s;
}
a:hover {
  color: var(--color-secondary);
}

/* Header & nav */
.header {
  position: relative;
  z-index: 1000;
  background: var(--color-primary);
  color: white;
  padding: .5rem 0;
}
.header .brand img,
.header .brand span {
  vertical-align: middle;
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.navlinks a {
  margin: 0 1rem;
  color: white;
  font-weight: 500;
}
.navlinks a.active,
.navlinks a:hover {
  color: var(--color-secondary);
}

/* Hamburger button (hidden by default, shown on mobile) */
.menu-btn {
  display: none; /* desktop hidden */
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 32px;
  height: 32px;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
}
.menu-btn span {
  display: block;
  width: 100%;
  height: 3px;
  background: white;
  border-radius: 2px;
  transition: all 0.35s ease;
  transform-origin: center;
}
/* transform into X */
.menu-btn.active span:nth-child(1) {
  transform: rotate(45deg) translate(4px, 4px);
}
.menu-btn.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.menu-btn.active span:nth-child(3) {
  transform: rotate(-45deg) translate(4px, -4px);
}

/* Hero */
.hero {
  background: linear-gradient(rgba(0, 86, 157, 0.85), rgba(0, 86, 157, 0.85)), url('images/skl-zoge.jpg');
  background-size: cover;
  background-position: center;
  color: white;
  padding: 4rem 0;
}
.hero h1 {
  font-size: 2rem;
  margin-bottom: 1rem;
}
.hero .btn-primary {
  background: var(--color-secondary);
  color: white;
}
.hero .btn-outline {
  border: 2px solid white;
  color: white;
}
.hero .btn-outline:hover {
  background: white;
  color: var(--color-primary);
}
.hero-stat {
  display: flex;
  gap: 2rem;
  margin-top: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
}
.hero-stat .stat {
  background: var(--color-secondary);
  color: white;
  padding: 1rem 1.5rem;
  border-radius: 12px;
  text-align: center;
  min-width: 120px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.hero-stat .stat strong {
  font-size: 1.5rem;
  display: block;
}
.hero-stat .stat span {
  font-size: 0.9rem;
  font-weight: 500;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: .75rem 1.25rem;
  border-radius: 6px;
  font-weight: 600;
  transition: 0.2s;
}
.btn-primary {
  background: var(--color-primary);
  color: white;
}
.btn-primary:hover {
  background: var(--color-dark);
}
.btn-outline {
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
}
.btn-outline:hover {
  background: var(--color-primary);
  color: white;
}

/* Sections */
.section {
  padding: 1rem 0;
}
.section h2 {
  color: var(--color-primary);
  margin-bottom: 1.5rem;
}
.lead {
  font-size: 1.1rem;
  color: var(--color-muted);
  margin-bottom: 2rem;
}

/* Cards */
.card {
  background: white;
  padding: 1.5rem;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}
.card img {
  max-width: 100%;
  border-radius: 12px;
  margin-bottom: 1rem;
}
.badge {
  display: inline-block;
  background: var(--color-secondary);
  color: white;
  padding: .25rem .75rem;
  border-radius: 20px;
  font-size: .8rem;
  font-weight: 600;
}

/* Footer */
.footer {
  background: var(--color-dark);
  color: white;
  padding: 2rem 0;
  margin-top: 3rem;
}
.footer a {
  color: var(--color-secondary);
}
.footer a:hover {
  text-decoration: underline;
}
.footer h3, .footer h4 {
  color: var(--color-secondary);
}
.copy {
  margin-top: 2rem;
  text-align: center;
  font-size: .9rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1rem;
}

/* Layout helpers */
.container {
  width: 90%;
  max-width: 1100px;
  margin: 0 auto;
}
.grid {
  display: grid;
  gap: 2rem;
}
.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}
.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* Inputs */
.input {
  width: 100%;
  padding: .75rem;
  border-radius: 6px;
  border: 1px solid #ddd;
  margin-top: .25rem;
  margin-bottom: 1rem;
}
textarea.input {
  resize: vertical;
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp .6s forwards;
}
.fade-in:nth-child(1) { animation-delay: .1s; }
.fade-in:nth-child(2) { animation-delay: .2s; }
.fade-in:nth-child(3) { animation-delay: .3s; }
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .navlinks {
    display: flex;
    flex-direction: column;
    background: var(--color-primary);
    position: absolute;
    right: 0;
    top: 100%;
    padding: 1rem;
    gap: 1rem;

    /* animation prep */
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.4s ease;
  }
  .navlinks.open {
    max-height: 500px; /* enough to fit links */
    opacity: 1;
    transform: translateY(0);
  }
  /* animate links individually */
  .navlinks a {
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
  }
  .navlinks.open a {
    opacity: 1;
    transform: translateY(0);
  }
  .navlinks.open a:nth-child(1) { transition-delay: 0.05s; }
  .navlinks.open a:nth-child(2) { transition-delay: 0.1s; }
  .navlinks.open a:nth-child(3) { transition-delay: 0.15s; }
  .navlinks.open a:nth-child(4) { transition-delay: 0.2s; }

  .hero .cta {
    display: flex;
    flex-direction: column; /* stack buttons vertically */
    gap: 1rem;
    align-items: flex-start;
    margin-top: 1.5rem; 
  }

  /* Show hamburger only on mobile */
  .menu-btn {
    display: flex;
    position: relative;
    z-index: 1000;
    cursor: pointer;
  }
}
