* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: #f9f9f9;
  line-height: 1.7em;
  font-size: 1rem;
  font-family: Arial, Helvetica, sans-serif;
  overflow-x: auto;
}

.body_container {
  display: grid;
  grid-template-columns: 0.2fr repeat(8, 1fr) 0.2fr;
  grid-template-rows: 100px auto 1fr;
  gap: 1rem;
  min-width: 350px;
  justify-items: center;
}

.nav_container {
  grid-column: 1 / -1;
  background-color: #4b0b0b;
  background: repeating-linear-gradient( 135deg, #410505, #410505 4px, #4b0b0b 20px );
  box-shadow: 0px 10px 15px #a9a9a9;
  color: #e9e9e9;
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  width:100%;
}

.logo_box {
  grid-column: 2 / 7;
  align-self: center;
  width: 100%;
  max-width: 1000px;
}

.logo_box > a, .logo_box > span {
  color: #e9e9e9;
  text-decoration: none;
}

.main_container {
  grid-column: 2 / 10;
  display: grid;
  grid-template-columns: 0.1fr repeat(10, 1fr) 0.1fr;
  grid-template-rows: auto auto 1fr;
  grid-auto-rows: auto;
  gap: 1.5em;
  width: 100%;
  max-width: 1400px;
}

.chapter_box {
  grid-column: 1 / -1;
}
.chapter_box > p {
  padding: 10px;
  text-align: justify;
}

.left_box {
  grid-column: 2 / 5;
}

.right_box {
  grid-column: 5 / -1;
}

.menu_box {
  display: grid;
  padding: 15px;
  align-items: center;
  border-radius: 5px;
  background-color: #f3f3f3;
  box-shadow: 0px 1px 10px #beb1b1;
}

.menu_box:hover {
  box-shadow: 0 1px 10px rgba(129, 21, 21, 0.8);
}

.menu_box_title {
  grid-column: 1 / -1;
  grid-row: 1;
  border-bottom: 3px solid red;
  font-weight: bold;
}

.menu_box_list {
  grid-row: 2;
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  padding: 10px;
  gap: 10px;
  letter-spacing: 0.1rem;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
}

.menu_link {
  width: 100%;
  display: flex;
  align-items: center;
  font-weight: bold;
  font-family: 'Courier New', Courier, monospace;
  transition: all 0.3s ease;
  padding: 10px;
  color: #333333;
  background-color: #f9f9f9;
  text-decoration: none;
  border: 1px solid darkgray;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
}

.menu_link:hover, .menu_link:focus {
  outline: none;
  background-color: #B22222;
  color: white;
  box-shadow: 0 1px 4px 0px rgba(129, 21, 21, 0.8);
 
}

.footer_container {
  grid-column: 1 / -1;
  display: grid;
  width: 100%;
  grid-template-columns: repeat(6, 1fr);
}

.footer_box {
  grid-column: 2 / 6;
  min-height: 100px;
  color: #ccc;
  border-top: 1px solid #ccc;
}

.form_box {
  background-color: #f9f9f9;
  border-radius: 4px;
  color: black;
  box-shadow: 0px 1px 10px #beb1b1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto atuo;
  
}

form {
  padding: 20px;
  justify-content: center;
  align-items: center;
  grid-column: 1 / -1;
}

.form-group {
  display: flex;
  align-items: start;
  justify-content: stretch;
  margin-bottom: 15px;
  flex-direction: column;
}

label {
  font-weight: bold;
  flex: 1;
  font-size: 0.9rem;
}

input[type='number'],
input[type='date'],
select {
  flex: 1;
  padding: 8px;
  background-color: white;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
  width: 100%;
  color: inherit;
}

input[type='number'] {
  appearance: none;
}
input[type='date'] {
  appearance: base;
  -webkit-appearance: none;
}

select {
  appearance: base;
  background: white;
}

input[type='number']:hover,
input[type='date']:hover,
select:hover {
  border-color: #811515;
}

input[type='number']:focus,
input[type='date']:focus,
select:focus {
  border-color: #811515;
  outline: none;
}

input[type='number']::placeholder
{  
  color: grey;
  font-size: 0.8rem;
}

button {
  flex: 1;
  background: linear-gradient(to bottom, #f9f9f9 5%, #e9e9e9 100%);
  background-color: #f9f9f9;
  border-radius: 4px;
  border: 1px solid #c0c0c0;
  cursor: pointer;
  color: #666666;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 15px;
  font-weight: bold;
  padding: 12px;
  text-decoration: none;
  width: 100%;
}

button:hover, button:focus {
  outline: none;
  background: linear-gradient(to bottom, #e9e9e9 5%, #f9f9f9 100%);
  background-color: #dfdfdf;
  color: #811515;
  border-color: #811515;
}

.form-group button {
  margin-top: 10px;
}

input[type="radio"] {
  display: none;
}

.tab_label {
  background-color: rgba(204, 204, 204, 0.3);
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5px;
  cursor: pointer;
  color: grey;
  border-radius: 4px 4px 0 0;
}


.tab_label:hover {
  box-shadow: inset 0 -10px 15px -14px #811515;
  color: black;
}

input[type="radio"]:checked+label {
  font-weight: bolder;
  background-color: #f9f9f9;
  box-shadow: none;
  color: #811515;
}

input[type="radio"]+label {
  box-shadow: inset 0 -10px 15px -10px #beb1b1;
}


.tab-content {
  display: none;
  margin: 20px O;
  grid-column: 1 / span 2;
}

#tab1:checked~#content1,
#tab2:checked~#content2 {
  display: block;
}


.title_content {
  font-size: smaller;
  padding: 15px;
  background-color: rgba(255, 255, 224, 0.5);
}

h2 {
  font-size: 1.5rem;
  letter-spacing: 0.1rem;
}

h3 {
  font-size: 1.3rem;
  display: block;
  padding: 10px;
}

.dvousloupcovy_flexstart {
  display: flex; 
  justify-content: flex-start;
  gap: 1rem;
}

.dvousloupcovy_flexstart > h3 {
  letter-spacing: 0.1rem;
  padding: 0px;
}

.dvousloupcovy_titulek {
  display: flex; 
  justify-content: space-between;
}

a.sipka_dolu {
  background-color: rgba(146, 146, 146, 0.2);
  padding: 0px 10px;
  border-radius: 4px;
  text-decoration: none;
  color: gray;
  transition: all 0.3s ease;
}

a.sipka_dolu:hover, a.sipka_dolu:focus {
  outline: none;
  color: white;
  background-color: rgba(0, 0, 0, 0.5);
}

.dulezite_odst {
  padding: 0.5rem;
  margin: 1rem 2rem;
  width: 95%;
  text-align: justify;
  border-left: 4px solid red;
  background-color: rgba(212, 118, 118, 0.1);
}

.dulezite_odst span {
  display: block; 
  font-size: 1.2rem; 
  color: darkred; 
  border-bottom: 1px solid red;
}

.ul_list {
  margin: 5px;
}

ul {
  margin-left: 35px;
}

ul li {
  padding: 5px;
}
.info_box {
  padding: 20px;
}

/*
Stylování tabulek
*/
table {
  color: #a9a9a9;
  font-size: 0.9rem;
  width: 100%;
  margin-bottom: 10px;
}
table:hover {
  color: black;
}
table caption {
  text-align: left;
  border-bottom: 1px solid #ccc;
  border-collapse: collapse;
}

tr td:first-child {
  width: 200px;
  padding-left: 10px;
}

.table_box {
  display: flex;
  flex-direction: column;
  min-width: 300px;
  font-size: 0.9rem;
  padding: 10px;
}
.table_header {
  display: flex;
  flex-wrap: wrap;
  font-weight: bold;
  color: #811515;
  border-bottom: 3px solid #811515;
  margin-bottom: 10px;
}
.table_row {
  display: flex;
  flex-wrap: wrap;
  padding: 6px 0;
  margin: 5px;
  border-radius: 5px;
  font-size: 0.9rem;
}

.table_row:first{
  font-size: 0.9rem;
}
.table_row:hover {
  color: #811515;
  box-shadow: 0 1px 4px 0px rgba(129, 21, 21, 0.8);
  border-radius: 5px;
}

.table_cell {
  padding: 10px;
  min-width: 100px;
  text-align: center;
}

.table_row:nth-child(odd) {
  background-color: #f3f3f3; 
}
.table_header > .table_cell {
  padding: 0px;
}
.table_header .table_cell:first-child {
  min-width: 200px;
  font-weight: bold;
}
.table_row .table_cell:first-child {
  min-width: 200px;
  font-weight: bold;
}


textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1 px solid darkgrey;
  height: 15Opx;
  padding: 0.5rem;
  font-size: 0.9rem;
}


.inline_comment {
  margin: 20px;
}

.text_lighter {
  display: inline;
  padding: 5px;
  background-color: rgba(129, 21, 21,0.2);
}

.timeline {
  border-collapse: collapse;
  text-align: center;
  color: black;
  background-color: rgba(255, 235, 224, 0.1);
  box-shadow: 0 1px 4px 0px rgba(129, 21, 21, 0.2);
  font-size: 1rem;
  width: 30%;
}
.timeline th {
  font-weight: normal;
}

.timeline tr:nth-child(2) td {
  font-size: 1.5rem;
}

.timeline td {
  padding: 5px;
}

.dvousloupcovy_content {
  display: flex; 
  justify-content: space-evenly;
}


@media (max-width: 728px) {
  .body_container {
    grid-template-columns: 0.1fr 1fr 0.1fr;
  }
  .main_container {
    grid-column: 1 / -1;
    grid-template-columns: 0.1fr auto 0.1fr;
    gap: 15px;
  }
  .chapter_box {
    grid-column: 2 / -2;
  }
  .left_box {
    grid-column: 1 / -1;
  }
  .info_box{
    box-shadow: 0 4px 4px 0px rgba(129, 21, 21, 0.8);
  }
  .right_box {
    grid-column: 2 / 3;
  }

  .menu_box {
    grid-column: 1 /-1;
    max-width: 728px;

  }

  .form-group {
    display: flex;
    align-items: start;
    justify-content: stretch;
    margin-bottom: 5px;
    flex-direction: column;
    max-width: 100%;
  }

  .table_box {
    width: 100%;
  }

  .table_row {
    padding: 0;
    margin: 6px;
    box-shadow: 0px 1px 5px #beb1b1;
  }

  .table_row .table_cell:first-child {
    border-bottom: 2px solid #811515;
    background-color: #e6e6e6;
    font-weight: bold;
  }
  .table_header .table_cell {
    padding: 0px;
  }

  .table_cell {
    flex-basis: 100%;
  }

  .dulezite_odst {
    margin: 0;
    width: 100%;
  }
}