@font-face {
  font-family: tomserif;
  src: url("tomserif.woff");
}


/* =========================
   BASE
   ========================= */

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Times New Roman", Times, serif;
  overflow-x: hidden;
}


/* =========================
   TOPBAR
   ========================= */

.topbar {
  position: fixed;
  top: 0;
  left: 0;

  width: 100%;
  z-index: 10;

  background-image: url("media/topbar.png");
  background-position: bottom;
  background-repeat: repeat-x;
}

.menu {
  padding: 20px;
  font-family: tomserif;
}

.menu a {
  display: inline-block;
  padding: 10px 50px 10px 0;
}

t {
  position: absolute;
  top: 20px;
  left: 50%;

  transform: translateX(-50%);

  font-family: tomserif;
  font-size: 20px;
  white-space: nowrap;
}


/* =========================
   CONTENITORE
   ========================= */

.items {
  width: min(900px, 100%);
  margin: 0 auto;
  padding: 100px 20px 40px;
}


/* =========================
   PROGETTI
   ========================= */

.pri,
.lgdd,
.soft {
  width: 100%;
  margin: 0 auto;
  padding: 40px 0;
}

.pri {
  padding-top: 30px;
}


/* =========================
   TESTO
   ========================= */

.testo {
  width: min(700px, 100%);
  margin: 0 auto 25px;
  text-align: center;
}

h1 {
  margin: 0 0 12px;

  font-family: tomserif;
  font-size: 28px;
  font-weight: normal;
}

b1 {
  display: block;
  text-align: center;
  line-height: 1.35;
}


/* =========================
   GALLERIA DESKTOP
   ========================= */

.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);

  gap: 10px;

  width: 100%;
}

.gallery-item {
  width: 100%;
}

.gallery-item a {
  display: block;
}

.gallery-item img {
  display: block;
  width: 100%;
  height: auto;
}


/* =========================
   LINK
   ========================= */

a:link,
a:visited {
  text-decoration: none;
  color: black;
}

a:hover {
  color: maroon;
}

a:active {
  color: black;
}


/* =========================
   MOBILE
   ========================= */

@media (max-width: 600px) {

  .menu {
    padding: 15px;
  }

  .menu a {
    padding: 10px 30px 10px 0;
  }

  t {
    top: 15px;
    font-size: 17px;
  }

  .items {
    width: 100%;
    padding: 80px 15px 30px;
  }

  .pri,
  .lgdd,
  .soft {
    width: 100%;
    padding: 30px 0;
  }

  .testo {
    width: 100%;
    margin-bottom: 20px;
  }

  h1 {
    font-size: 22px;
    margin-bottom: 10px;
  }

  b1 {
    font-size: 14px;
    line-height: 1.4;
  }


  /* =========================
     GALLERIA ORIZZONTALE
     ========================= */

  .gallery {
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-start;
    align-items: flex-start;

    width: 100%;

    overflow-x: auto;
    overflow-y: hidden;

    gap: 6px;

    padding: 0;
    margin: 0;

    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .gallery::-webkit-scrollbar {
    display: none;
  }

  .gallery-item {
    flex: 0 0 auto;
    width: auto;
    margin: 0;
    padding: 0;
  }

  .gallery-item a {
    display: block;
  }

  .gallery-item img {
    display: block;
    width: auto;
    height: 250px;
  }
}