/*
Theme Name: POUKARdesign
Author: Soft Evolution s.r.o., Josef Vondráček
Version: 1.1
Description: Modernizovaná šablona POUKARdesign (bezpatkový font Plus Jakarta Sans, responzivní mřížka, a11y & UX úpravy)
*/

/* ==========================================================================
   1. Nový bezpatkový font (Plus Jakarta Sans) & typografie
   ========================================================================== */
:root {
  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --accent: #9acc34;
  --bg-dark: #111111;
  --text-light: #ffffff;
  --text-muted: #a3a3a3;
}

body,
p, ul, ol, li, a,
input, textarea, button, select {
  font-family: var(--font-sans) !important;
}

h1, h2, h3, h4, h5, h6,
header #menu li a,
.grid-item h2,
.grid-item.big h2 {
  font-family: var(--font-display) !important;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-light);
  font-weight: 400;
  line-height: 1.6;
}

h1, #content.contact h2, #content.detail h1 {
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  line-height: 1.15;
}

#content.detail h1,
#content.contact h1,
#content.contact h2 {
  font-size: 40px;
}

p, ul, ol {
  font-size: 18px;
  line-height: 1.7;
  font-weight: 400;
}

/* Přístupnost */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ==========================================================================
   2. Kontejner & Hlavička
   ========================================================================== */
.in {
  width: 100%;
  max-width: none;
}

#page {
  overflow: clip;
}

header {
  z-index: 1000;
  background: rgba(17, 17, 17, 0.94);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  -webkit-animation: none !important;
  animation: none !important;
}

header #logo {
  width: 264px;
  height: auto !important;
}

header #logo svg.logo-svg {
  display: block;
  width: 100%;
  height: auto;
  shape-rendering: auto;
}

header #logo svg.logo-svg path:first-child {
  fill: #f5f5f5;
  stroke: #f5f5f5;
  stroke-width: 0.9;
  stroke-linejoin: round;
  paint-order: stroke fill;
}

header #menu li a {
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Sociální ikona X vedle Facebooku */
header .social {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  width: auto;
  right: 20px;
  top: 43px;
}

header .social li {
  float: none !important;
  display: inline-flex;
  align-items: center;
  margin: 0;
}

header .social li.fb a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0 !important;
  color: #ffffff;
  text-decoration: none;
  transition: color 0.25s ease;
}

header .social li.fb a:hover {
  color: var(--accent);
}

header .social li.fb a svg {
  display: block !important;
  flex-shrink: 0 !important;
  width: 18px !important;
  height: 18px !important;
  fill: currentColor !important;
}

/* ==========================================================================
   3. Mřížka portfolia (Desktop – oprava kolizí a vycentrování)
   ========================================================================== */
.grid-sizer,
.grid-item {
  width: 11.625%;
}

.grid-item {
  margin-bottom: 18px;
  overflow: visible;
}

.gutter-sizer {
  width: 1%;
}

.grid-item.big {
  width: 24.25%;
}

.project_list {
  padding-bottom: 100px;
}

.grid-item .title {
  padding: 10px 4px 0 0;
}

.grid-item h2,
.grid-item.big h2 {
  font-size: 15px;
  line-height: 1.3;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #e5e5e5;
  overflow-wrap: break-word;
  word-wrap: break-word;
  hyphens: auto;
  transition: color 0.25s ease;
}

.grid-item .meta {
  display: block;
  margin-top: 8px;
  font-size: 11px;
  line-height: 1.45;
  font-weight: 400;
  letter-spacing: 0.01em;
  text-transform: none;
  text-align: left;
  color: #9a9a9a;
}

.grid-item .meta span {
  display: block;
}

.grid-item .meta span.year {
  margin-top: 2px;
  color: #cfcfcf;
  font-weight: 500;
}

.grid-item a:hover h2 {
  color: #ffffff;
  text-decoration: none;
}

@media (hover: hover) and (min-width: 901px) {
  .grid1 .grid-item {
    transition: opacity 0.25s ease;
  }
  .grid1:not(.is-scrolling):hover .grid-item {
    opacity: 0.26;
  }
  .grid1:not(.is-scrolling):hover .grid-item:hover {
    opacity: 1;
    z-index: 30;
  }
  .grid1 .grid-item .image {
    transition: box-shadow 0.3s ease;
  }
  .grid1:not(.is-scrolling) .grid-item:hover .image {
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.85);
  }
  .grid1 .grid-item .title {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    min-width: 100%;
    padding: 10px 12px 12px;
    background: rgba(17, 17, 17, 0.96);
    border-top: 2px solid var(--accent);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.85);
    opacity: 0;
    transform: translateY(-6px);
    pointer-events: none;
    transition: opacity 0.22s ease, transform 0.22s ease;
  }
  .grid1:not(.is-scrolling) .grid-item:hover .title {
    opacity: 1;
    transform: translateY(0);
    pointer-events: none;
  }
}

.grid-item img,
.grid-item video.poster-video,
#content.detail video.poster-video {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.grid-item video.poster-video,
#content.detail video.poster-video {
  background-color: #161616;
}

.grid-item a:hover img,
.grid-item a:hover video.poster-video {
  -webkit-transform: scale(1.03);
  transform: scale(1.03);
}

.page-404 .col.text.wide {
  max-width: 720px;
  width: 100%;
  float: none;
  padding: 80px 0 !important;
}

.page-404 .btn-back {
  display: inline-block;
  margin-top: 12px;
  padding: 12px 24px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 4px;
  color: #ffffff;
  text-decoration: none !important;
  font-family: var(--font-display) !important;
  font-size: 14px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  transition: border-color 0.25s ease, color 0.25s ease;
}

.page-404 .btn-back:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ==========================================================================
   4. Detail projektu & Navigace Předchozí / Další
   ========================================================================== */
#content.detail .col p,
#content.detail .col ul li {
  text-align: left;
}

#content.detail .col p {
  font-size: 18px;
  line-height: 1.7;
}

#content.detail .col ul li {
  font-size: 15px;
  line-height: 1.6;
  color: #d4d4d4;
}

#content.detail .col ul li span {
  color: var(--text-muted);
}

#content.detail .col ul li a:hover {
  color: var(--accent);
}

#content.detail .title a.close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  color: #d4d4d4;
  transition: color 0.25s ease, transform 0.25s ease;
}

#content.detail .title a.close:hover {
  color: var(--accent);
  transform: rotate(90deg);
}

#content.detail .title a.close svg {
  display: block;
  width: 42px;
  height: 42px;
  stroke: currentColor;
}

/* ==========================================================================
   5. Stránka Kontakt – oprava rozbité mapy & sjednocení s detailem plakátu
   ========================================================================== */
#content.contact .col.map {
  padding: 0 !important;
  height: 520px !important;
  min-height: 400px;
  margin-top: 45px;
  border-radius: 6px;
  overflow: hidden;
  background-color: #1a1a1a;
  position: relative;
}

#content.contact .col.map iframe {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  border: 0;
  display: block;
  filter: grayscale(100%) invert(92%) contrast(88%);
}

#content.contact .col.text a {
  color: #ffffff;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.25s ease;
}

#content.contact .col.text a:hover {
  color: var(--accent);
}

@media screen and (min-width: 901px) {
  #content.detail .in,
  #content.contact .in {
    display: flex;
    flex-direction: row-reverse;
    justify-content: center;
    align-items: flex-start;
    gap: 50px;
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 30px;
  }

  #content.detail .col.gallery,
  #content.contact .col.map {
    float: none !important;
    flex: 0 1 600px;
    width: 100% !important;
    max-width: 600px !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  #content.detail .col.text,
  #content.contact .col.text {
    float: none !important;
    flex: 1 1 0;
    width: auto !important;
    max-width: 620px;
    padding: 45px 0 45px 0 !important;
  }

  #content.detail .col.text {
    position: sticky;
    top: 120px;
  }

  #content.detail .col.text.wide {
    max-width: 900px;
  }

  #content.detail h1 {
    padding-right: 64px;
    margin-right: 0;
  }

  #content.detail .wrap {
    padding-right: 0;
  }
}

/* ==========================================================================
   6. Responzivita (Tablet & Mobil)
   ========================================================================== */
@media screen and (max-width: 1300px) {
  .grid1 .grid-sizer,
  .grid1 .grid-item {
    width: 19.2%;
  }
  .grid1 .grid-item.big {
    width: 39.4%;
  }
}

@media screen and (max-width: 1100px) {
  .grid1 .grid-sizer,
  .grid1 .grid-item {
    width: 24.25%;
  }
  .grid1 .grid-item.big {
    width: 49.5%;
  }
}

@media screen and (max-width: 900px) {
  header {
    height: 64px;
  }
  #page {
    padding-top: 64px !important;
  }
    body #page section#content.home {
    padding-top: 12px !important;
    margin-top: 0 !important;
  }
  body #page section#content.home > .in,
  body #page section#content.home .project_list,
  body #page section#content.home .grid,
  body #page section#content.home #grid {
    padding-top: 0 !important;
    margin-top: 0 !important;
    top: 0 !important;
  }
   
  header .in {
    height: 64px;
    width: 100%;
    padding: 0 18px;
    display: flex !important;
    align-items: center;
    justify-content: space-between;
  }
  header #logo {
    margin: 0 !important;
    width: 165px !important;
    height: auto !important;
    float: none !important;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
  }
  header #logo svg.logo-svg {
    display: block;
    width: 100%;
    height: auto;
  }
  header .hamburger {
    margin: 0 0 0 auto !important;
    padding: 8px 0 8px 14px !important;
    float: none !important;
    flex-shrink: 0;
    display: inline-flex !important;
    align-items: center;
    justify-content: flex-end;
  }
  header .wrap {
    top: 64px !important;
    background: rgba(17, 17, 17, 0.98) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding: 4px 0 16px;
  }
  header nav {
    width: 100%;
    padding: 0 20px;
    margin: 0;
  }
  header #menu li {
    padding: 13px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }
  header #menu li:last-child {
    margin-left: 0;
    border-bottom: none;
  }
  header #menu li a {
    font-size: 16px;
    letter-spacing: 0.12em;
  }
  header .social {
    position: relative;
    top: auto;
    right: auto;
    padding: 12px 20px 4px;
    justify-content: flex-end;
  }
  #content.detail .title {
    padding-top: 0;
    padding-right: 48px;
  }
  #content.detail h1 {
    padding-right: 0;
    margin-right: 0;
    font-size: 30px;
  }
  #content.detail .title a.close {
    width: 36px;
    height: 36px;
    top: 2px;
    right: 0;
  }
  #content.detail .title a.close svg {
    width: 30px;
    height: 30px;
  }
  #content.contact .col.map {
    height: 340px !important;
    min-height: 300px;
    margin-top: 24px !important;
  }
}

@media screen and (max-width: 800px) {
  .grid1 .grid-sizer,
  .grid1 .grid-item {
    width: 48.5%;
  }
  .grid1 .gutter-sizer {
    width: 3%;
  }
  .grid1 .grid-item.big {
    width: 100%;
  }
}

@media screen and (max-width: 600px) {
  .in {
    padding: 0 16px;
  }
  .project_list {
    padding-bottom: 48px;
  }
  
	

  .grid1 .grid-item,
  .grid1 .grid-item.big {
    width: 100% !important;
    margin-bottom: 38px !important;
  }
  .grid1 .gutter-sizer {
    width: 0 !important;
  }
  .grid-item .title {
    position: static !important;
    opacity: 1 !important;
    transform: none !important;
    padding: 14px 0 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
  }
  .grid-item h2,
  .grid-item.big h2 {
    font-size: 22px !important;
    line-height: 1.25 !important;
    letter-spacing: 0.04em;
    color: #ffffff;
  }
  .grid-item .meta {
    margin-top: 6px !important;
    font-size: 13px !important;
    line-height: 1.5 !important;
    color: #9a9a9a;
  }
  #content.detail h1,
  #content.contact h1,
  #content.contact h2 {
    font-size: 28px;
  }
}