/* Font */

@font-face {
  font-family: 'Atkinson Hyperlegible Next';
  src: url('/_font/AtkinsonHyperlegibleNext/AtkinsonHyperlegibleNext-Regular.woff2') format('woff2'),
       url('/_font/AtkinsonHyperlegibleNext/AtkinsonHyperlegibleNext-Regular.ttf') format('ttf');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Atkinson Hyperlegible Next';
  src: url('/_font/AtkinsonHyperlegibleNext/AtkinsonHyperlegibleNext-RegularItalic.woff2') format('woff2'),
       url('/_font/AtkinsonHyperlegibleNext/AtkinsonHyperlegibleNext-RegularItalic.ttf') format('ttf');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'Atkinson Hyperlegible Next';
  src: url('/_font/AtkinsonHyperlegibleNext/AtkinsonHyperlegibleNext-Bold.woff2') format('woff2'),
       url('/_font/AtkinsonHyperlegibleNext/AtkinsonHyperlegibleNext-Bold.ttf') format('ttf');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* Definizioni globali */

* {
  font-family: "Atkinson Hyperlegible Next", Arial, Verdana, sans-serif;
}

html {
  max-width: 1280px;
  width: 99%;
  margin: 1px auto;
  font-synthesis: none; /* evita finto bold/italic */
}

h1 {
  font-size: 150%;
}

h2:first-of-type {
  margin-top: 1rem;
}

h2,
h3 {
  margin-top: 2rem;
}

a {
  color: #0000ff;
  font-size: 110%;
}

.navigazione a:visited {
  color: #0000ff
}

ul,
ol,
dd {
  margin-left: 0;
  padding-left: 1.2rem;
}

li,
dd {
  margin-bottom: 0.5rem;
}

hr {
  color: #14d600;
  border: 2px solid #14d600;
  background-color: #14d600;
  width: 100%;
  height: 0;
  text-align: left;
}

fieldset {
  border: 1px solid #14d600;
}

input,
textarea {
  border: 1px solid #5f9f5f;
  background-color: #eeeeee;
  color: #000000;
  font-weight: bold;
  max-width: 90% !important;
}

input:focus,
textarea:focus {
  border-width: 2px;
}

.mpx-error strong {
  color: red;
}


/* Responsive */

@media screen and (max-width: 760px) {
  body {
    width: 100%;
    margin: 0;
    padding: 0;
    background-position: 150px -80px; /* Cielo */
  }

  img {
    max-width: 90%;
    height: auto;
    float: none !important;
    display: block;
    margin: 1em auto !important;
  }

  textarea {
    width: 95% !important;
  }
}

/* DARK MODE */

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
  }

  body {
    background: #222;
    color: #fff
  }

  a,
  strong {
    color: #14d600;
  }

  a:visited,
  .mpx-error strong {
    color: #ff7171;
  }

  .navigazione a:visited {
    color: #14d600;
  }

  input,
  select,
  textarea {
    background-color: #38383d;
    color: #ddd;
  }

  textarea:focus,
  input.text:focus,
  select:focus {
    background-color: #38383d;
    border-color: green;
  }
}

