html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background: #fff url("assets/page_bg.png") repeat-x left top;
  color: #777;
  font: 400 12px/1.45 Arial, Tahoma, Verdana, Helvetica, sans-serif;
}

a {
  color: #777;
  text-decoration: none;
}

a:hover {
  color: #f83e47;
}

img {
  border: 0;
  max-width: 100%;
  height: auto;
}

p {
  margin: 0 0 10px;
}

h1,
h2,
h3 {
  line-height: 1.25;
}

h2 {
  margin: 0 0 12px;
  color: #f83e47;
  font-size: 18px;
}

.site-header {
  position: relative;
  width: 981px;
  height: 385px;
  margin: 0 auto;
  background: var(--header-image, url("heder foto/02.jpg")) no-repeat center top;
  background-size: cover;
}

.home-page {
  --header-image: url("heder foto/01.jpg");
}

.top-menu {
  width: 921px;
  height: 29px;
  padding: 3px 30px 0;
  overflow: hidden;
  background: url("assets/t_menu_bg.png") no-repeat center top;
}

.site-title {
  position: absolute;
  left: 50px;
  top: 188px;
  margin: 0;
  visibility: hidden;
  font-size: 7px;
}

.logo {
  position: absolute;
  bottom: 0;
  left: 10px;
  width: 230px;
  height: 74px;
  background: url("assets/viesmilibasskola_logo_.png") no-repeat left top;
}

.content-wrap {
  width: 960px;
  margin: 0 auto;
  padding-top: 36px;
  background: url("assets/content_t.png") no-repeat center top;
}

.layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 20px;
}

.sidebar {
  width: 220px;
}

.module {
  margin-bottom: 25px;
}

.module-box {
  width: 230px;
  padding-bottom: 20px;
  background: url("assets/box_b.png") no-repeat center bottom;
}

.module-title {
  box-sizing: border-box;
  width: 220px;
  height: 56px;
  margin: 0;
  padding: 0 20px;
  overflow: hidden;
  background: url("assets/box_h3.png") no-repeat center top;
  color: #fff;
  font: 400 11px/28px Tahoma, Verdana, Arial, sans-serif;
}

.lang-inline,
.menu {
  margin: 0;
  padding: 0;
  list-style: none;
}

.lang-inline {
  padding-left: 20px;
}

.lang-inline li {
  display: inline-block;
  margin: 0 5px;
}

.menu {
  margin: 0 20px 0 10px;
}

.menu li a {
  display: block;
  margin: 0;
  padding: 0 4px;
  background: url("assets/menu_arrow.gif") no-repeat left top;
  color: #888;
  font-size: 11px;
  line-height: 17px;
}

.menu li a span {
  display: block;
  padding-left: 10px;
}

.menu .active span {
  color: #f00;
}

.menu ul {
  margin: 2px 0 8px 12px;
  padding: 0;
  list-style: none;
}

.menu ul li a {
  background-position: left 1px;
  font-size: 10px;
}

.custom {
  margin-left: 20px;
}

.content {
  padding: 10px;
}

.page-content h1 {
  margin: 0 0 14px;
  color: #f83e47;
  font-size: 24px;
}

.page-content h3 {
  margin: 18px 0 8px;
  color: #f83e47;
  font-size: 14px;
}

.blog .items-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 30px 18px;
  margin-bottom: 30px;
}

.home-page .blog .items-row {
  grid-template-columns: 1fr;
}

.blog .item {
  min-width: 0;
}

.item-page {
  padding: 10px;
  background: #f0f0f0;
  border: 1px solid #e7e7e7;
  border-radius: 5px;
}

.item-page > h1,
.item-page > h2 {
  margin-top: 0;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 30px 18px;
}

.item {
  padding: 10px;
  background: #f0f0f0;
  border: 1px solid #e7e7e7;
  border-radius: 5px;
  text-align: justify;
}

.item strong {
  color: inherit;
}

.professors-page .item-page table {
  width: 100%;
}

.professors-page .item-page td:first-child {
  width: 280px;
  vertical-align: top;
}

.professors-page .item-page td:first-child img {
  width: min(280px, 100%);
  max-width: none;
  height: auto;
  display: block;
}

.lead-red {
  color: #f00;
  font-family: Helvetica, Arial, sans-serif;
  font-size: large;
}

.muted {
  color: #999;
}

.center {
  text-align: center;
}

.media-note {
  display: grid;
  place-items: center;
  min-height: 170px;
  padding: 16px;
  background: #e6e6e6;
  color: #777;
  text-align: center;
}

.site-footer {
  width: 980px;
  min-height: 20px;
  margin: 0 auto;
  padding: 20px 0;
  color: #666;
  line-height: 20px;
  text-align: center;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 1000px) {
  .site-header,
  .content-wrap,
  .site-footer {
    width: min(100% - 24px, 960px);
  }

  .site-header {
    height: 39vw;
    min-height: 260px;
    background-size: cover;
  }

  .top-menu {
    box-sizing: border-box;
    width: 100%;
  }
}

@media (max-width: 760px) {
  .layout,
  .blog-grid,
  .blog .items-row {
    grid-template-columns: 1fr;
  }

  .professors-page .item-page table,
  .professors-page .item-page tbody,
  .professors-page .item-page tr,
  .professors-page .item-page td {
    display: block;
    width: 100% !important;
  }

  .professors-page .item-page td:first-child img {
    width: min(320px, 100%);
    margin: 0 auto 12px;
  }

  .sidebar,
  .module-box,
  .module-title {
    width: 100%;
  }

  .site-header {
    min-height: 220px;
  }

  .logo {
    transform: scale(0.9);
    transform-origin: left bottom;
  }
}
