@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@200..700&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

:root {
    font-family: "Poppins", serif;
    line-height: 1.3;
    font-weight: 400;
    color-scheme: light dark;
    font-synthesis: none;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  }
  
  body {
    margin: 0;
    padding: 0;
  }
  
#app {
  display: flex;
  flex-direction: column; /* 👈 KLÍČ */
  height: 100vh;
}
  
  /* Main view styles */
  #map-container {
    flex: 1;
    height: 100%;

    display: flex;
    justify-content: center;
  }
  /*top header info banner*/
      #uppon-header{
      width: 80%;
      height: 90px;
      position: relative;
      background-color: white;
      z-index: 1000;
      margin-top: 10px;
      border-radius: 10px 10px 10px 10px;
      box-shadow: 5px 4px 20px 0px rgba(0, 0, 0, 0.5);
      font-family: "Poppins", serif;
    }


    .uppon-header-inside{
      display: flex;
      flex-direction: row;
      justify-content:space-around;
      align-items: center;
    }
  .uppon-header-inside .left {
  width: 20%;
     overflow-wrap: break-word;
    
}
.left img {
  width: 80%;
 
}
.uppon-header-inside .middle {
  width: 40%;
  overflow-wrap: break-word;
  text-align: center;
  font-size: 1.2em;
}

.uppon-header-inside .right {
  width: 20%;
  text-align: right;
  font-size: 1.2em;
 
}
  #project-list {

  
    overflow-y: auto;
    background: white;
    border-left: 1px solid #e5e7eb;
    padding: 1rem;
    color: black;
  }
  
  .project-list-header{
    display:flex;
    flex-direction:column;
    gap:12px;
    margin-bottom:15px;
}

  .project-list-header h2{
    text-align: center;
  }
.controls{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
    align-items:center;
}

.controls input,
.controls select,
.controls button{
    
    width: 100%;
}
  
  .filter-search,
  .filter-select, button, input, select {
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    background: white;
    color: black;
    font-family: "Poppins", serif;
  
  }
  
.project-item{
    padding:18px;
    border:none;
    border-radius:14px;
    background:white;
    box-shadow:
      0 3px 12px rgba(0,0,0,.06);
    transition:.25s;
      position:relative;
    padding-left:22px;
}
.project-item::before{
    content:"";
    position:absolute;
    left:0;
    top:0;
    bottom:0;
    width:5px;
    border-radius:999px;
    background:#22c55e;
}
  .project-item:hover{
    transform:translateY(-3px);
    box-shadow:
      0 12px 30px rgba(0,0,0,.10);
}
.project-type-uzavirka::before{
    background:#ef4444;
}

.project-type-omezeni::before{
    background:#f97316;
}

.project-type-objizdka::before{
    background:#3b82f6;
}
.project-finished.project-type-uzavirka::before,
.project-finished.project-type-omezeni::before,
.project-finished.project-type-objizdka::before{
    background:#22c55e !important;
}

.project-item.active{
    border-left:4px solid #2563eb;
}
   button:hover {
    background: #f3f4f6;
  }
  
  .project-item-header {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
  }
  
  .project-status {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 0.5rem;
  }
  
 .road-number{
  font-weight:600;
  padding:4px 8px;
  border-radius:6px;
  font-size:16px;
  display:inline-block;
}
  
  .road-number-large {
    font-size: 1.25rem;
    font-weight: 600;
    color: #4b5563;
    background: #f3f4f6;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    display: inline-block;
    margin-top: 0.5rem;
  }
  
  .project-item-name {
    font-weight: 500;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
  }
  
  .project-item-dates {
    color: #6b7280;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
  }
  
  .project-item-price {
    font-weight: 500;
    color: #059669;
  }
  
  .status-finished { background: #22c55e; }
  .status-in-progress { background: #ef4444; }
  .status-new { background: #3b82f6; }
  
  /* Detail view styles */
  .detail-page {
    width: 100%;
    height: 100%;
    background: white;
    color: black;
    overflow-y: auto;
  }
  
 
  
 .back-button{
    background:rgba(255,255,255,.15);
    color:white;
    border:none;
    padding:10px 16px;
    border-radius:10px;
    margin-bottom:16px;
    backdrop-filter:blur(4px);
}

.back-button:hover{
    background:rgba(255,255,255,.25);
    color:white;
}
  .status-badge{
    display:inline-flex;
    align-items:center;
    gap:8px;
    padding:10px 18px;
    border-radius:999px;
    font-weight:600;
    font-size:.9rem;
    margin-bottom:20px;
}
  .detail-content {
    padding: 1.5rem;
    display: flex;
   
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
  }
  @media screen and (max-width: 767px){
  .detail-content {
    display: flex;
    flex-direction: column;
  }
  #app{
    flex-direction: column;
    min-height: 90vh;
  }
  #map-container{
    min-height: 70vh;
  }
  #project-list{
    width: auto;
  }
  #uppon-header{
 
     width: auto;
     margin-top: 0px; 
     border-radius: 0px 0px 0px 0px;
  }
  }


  
  .description {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
  }
  
.info-grid{
    display:grid;
    grid-template-columns:1fr;
    gap:12px;
}
.info-item{
    background:#f8fafc;
    border:1px solid #e2e8f0;
    border-radius:12px;
    padding:16px;
    transition:.2s;
}
button#groupModeBtn, button#singleModeBtn{
  display: none
}
.info-item:hover{
    transform:translateY(-2px);
    box-shadow:
      0 8px 20px rgba(0,0,0,.06);
}

.info-item strong{
    display:block;
    color:#64748b;
    font-size:.85rem;
    text-transform:uppercase;
    letter-spacing:.05em;
    margin-bottom:6px;
}

.info-item span{
    font-size:1rem;
    color:#0f172a;
    font-weight:500;
}
  .pagination{
    text-align: center;
  }
  #detail-map {
    min-height: 650px;
    border-radius: 0.5rem;
    overflow: hidden;
  }
  .project-item.active {
      background-color: #f0f0f0; /* Highlight background */
      border-left: 4px solid #3b82f6; /* Blue border */
      transition: background-color 0.3s;
    }

.site-footer{
    margin-top:auto;
    text-align:center;
    padding:20px;
    color:#666;
    font-size:13px;
    border-top:1px solid #e5e7eb;
}

/* typy úseků */

.type-uzavirka{
  background:#ef4444;
  color:white;
}

.type-objizdka{
  background:#3b82f6;
  color:white;
}

.type-omezeni{
  background:#f97316;
  color:white;
}

.info-container {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.5rem;
  margin-bottom: 1rem;
}



/* mobil */
@media screen and (max-width: 767px){
  .info-container {
    grid-template-columns: repeat(2, 1fr);
  }
}
.top-info-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
  padding:16px;
    background:
      linear-gradient(
        135deg,
        #fff5f5,
        #ffffff
      );
  border-bottom: 1px solid #e5e7eb;
  align-items: center; 
}

/* boxy */
.info-box {
   background:rgba(255,255,255,.75);
    backdrop-filter:blur(10px);
    border:none;
    box-shadow:
      0 8px 24px rgba(0,0,0,.06);
  padding: 0.75rem;
  border-radius: 0.5rem;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 500;

}
.info-number {
  font-size: 1.5rem;
  font-weight: 700;
}

.info-label {
  font-size: 0.8rem;
  color: #6b7280;
}
/* spodní část (mapa + list) */
.main-content {
  display:flex;
    gap:0;
  flex: 1; /* zabere zbytek */
  overflow: hidden;
  /*flex-direction: row-reverse;*/
  min-height: 94vh;
}

.project-district{
    margin-top:6px;
    font-size:13px;
    color:#64748b;
}

.detail-header{
    padding:2rem;
    background:linear-gradient(
        135deg,
        #f46b6b
    );
    color:white;
}
.detail-header-finished{
    background: linear-gradient(
        135deg,
        #4ade80,
        #16a34a
    ) !important;
}

.detail-header-uzavirka{
    background: linear-gradient(
        135deg,
        #f46b6b,
        #dc2626
    ) !important;
}
.detail-header-omezeni{
    background: linear-gradient(
        135deg,
        #fb923c,
        #f97316
    ) !important;
}

.detail-header h1{
    margin:0;
    font-size:2rem;
    font-weight:700;
}

.detail-info{
  width: 100%;
    background:white;
    border-radius:16px;
    padding:24px;
    box-shadow:
      0 10px 25px rgba(0,0,0,.08);
}

#detail-map{
    border-radius:16px;
    overflow:hidden;
    box-shadow:
      0 10px 25px rgba(0,0,0,.08);
}
.info-item.term-item{
    background:#eff6ff;
    border:1px solid #93c5fd;
}

@media (max-width:767px){
    .info-grid{
        grid-template-columns:1fr;
    }
}

.project-status-info{
    margin-top:8px;
    font-size:13px;
    font-weight:600;
    color:#2563eb;
}
.progress-card{
    margin-top:20px;
}

.progress-header{
    display:flex;
    justify-content:space-between;
    margin-bottom:8px;
    font-weight:600;
}

.progress-bar{
    height:12px;
    background:#e5e7eb;
    border-radius:999px;
    overflow:hidden;
}

.progress-fill{
    height:100%;
    background:linear-gradient(
      90deg,
      #4ade80,
      #22c55e,
      #16a34a
    );
    transition:.5s ease;
}
.detail-footer{

    padding:20px;
    text-align:center;
    color:#64748b;
    font-size:14px;
    border-top:1px solid #e2e8f0;
    background:#f8fafc;
}
.sidebar-header{
    padding:20px;
    margin-bottom:16px;
    border-radius:16px;
    background:linear-gradient(
      135deg,
      #f46b6b,
      #dc2626
    );
    color:white;
}

.sidebar-header h2{
    margin:0;
    font-size:22px;
}

.sidebar-header span{
    opacity:.9;
    font-size:14px;
}
.toggle-sidebar{
    position:absolute;
    top:50%;
    right:-18px;
    transform:translateY(-50%);
    width:40px;
    height:70px;
    border:none;
    border-radius:0 12px 12px 0;
    background:white;
    z-index:2000;
    box-shadow:
        0 4px 15px rgba(0,0,0,.15);
    cursor:pointer;
}

.toggle-sidebar:hover{
    background:#f8fafc;
}

.main-content{
    position:relative;
}
#project-list{
    position:relative;
    width:350px;
    min-width:350px;
    transition:.35s ease;
    
}

#project-list.hidden{
    width:0;
    min-width:0;
    padding:0;
    overflow:visible;
}
.toggle-sidebar.collapsed{
    right:0;
}



.project-finished .project-item-name{
    color: #166534;
    font-weight: 600;
}

.project-finished .project-status-info{
    color: #22c55e;
}


.filter-card{

display:flex;
align-items:center;

background:white;
border:1px solid #ddd;
border-radius:8px;

padding:10px 12px;
margin-bottom:8px;

cursor:pointer;
transition:0.2s;

box-shadow:0 2px 6px rgba(0,0,0,0.15);
}

.filter-card:hover{
background:#f7f7f7;
}

.filter-card input{
display:none;
}

.filter-title{
font-size:14px;
font-weight:600;
padding-right: 10px;
}

.filter-check{

margin-left:auto;

width:22px;
height:22px;

background:#4CAF50;
color:white;

border-radius:4px;

display:flex;
align-items:center;
justify-content:center;

font-size:14px;
}

/* vypnutý checkbox */
.filter-card input:not(:checked) + .filter-title + .filter-check{

background:#ccc;
opacity:0.5;

}


.filter-card.addTextPromp{
  pointer-events: none;
  cursor: default;
}

.filter-card:hover{
  background-color: rgb(233, 233, 233);;
}

.filter-group{
  position:absolute;
    top:100px;
    left:10px;
    z-index:1000;
}

select#district-filter {
    width: 100%;
}