AltoCode

Scala 4 Statistiche

HTML


<!-- ============================================ -->
<!--                Statistiche                   -->
<!-- ============================================ -->

<section id="stats-1574">
    <div class="cs-container">
        <ul class="cs-card-group">
            <li class="cs-item">
                <img class="cs-icon" src="https://csimg.nyc3.cdn.digitaloceanspaces.com/Images/Icons/ecomm-thumb.svg"
                        alt="icona grafica" width="48" height="48" loading="lazy" decoding="async">
                <span class="cs-stat">99%</span>
                <span class="cs-info">Feedback positivo dei clienti</span>
            </li>
            <li class="cs-item">
                <img class="cs-icon" src="https://csimg.nyc3.cdn.digitaloceanspaces.com/Images/Icons/ecomm-package.svg"
                        alt="icona grafica" width="48" height="48" loading="lazy" decoding="async">
                <span class="cs-stat">10</span>
                <span class="cs-info">Giorni di reso gratuito</span>
            </li>
            <li class="cs-item">
                <img class="cs-icon" src="https://csimg.nyc3.cdn.digitaloceanspaces.com/Images/Icons/ecomm-hand.svg"
                        alt="icona grafica" width="48" height="48" loading="lazy" decoding="async">
                <span class="cs-stat">24/7</span>
                <span class="cs-info">Assistenza clienti online</span>
            </li>
            <li class="cs-item">
                <img class="cs-icon" src="https://csimg.nyc3.cdn.digitaloceanspaces.com/Images/Icons/ecomm-hand.svg"
                        alt="icona grafica" width="48" height="48" loading="lazy" decoding="async">
                <span class="cs-stat">24/7</span>
                <span class="cs-info">Assistenza clienti online</span>
            </li>
        </ul>
    </div>
    <img class="cs-background" src="https://csimg.nyc3.cdn.digitaloceanspaces.com/Images/Icons/ecomm-waves.svg"
            alt="" width="1920" height="500" loading="lazy" decoding="async">
</section>

CSS


/*-- -------------------------- -->
<---        Statistiche         -->
<--- -------------------------- -*/

/* Mobile - 360px */
@media only screen and (min-width: 0rem) {
  #stats-1574 {
    padding: var(--sectionPadding);
    position: relative;
  }
  #stats-1574 .cs-container {
    list-style: none;
    width: 100%;
    max-width: 36.5rem;
    margin: auto;
  }
  #stats-1574 .cs-card-group {
    width: 100%;
    padding: 0;
    display: grid;
    grid-auto-flow: row;
    gap: clamp(1rem, 2vw, 1.25rem);
  }
  #stats-1574 .cs-item {
    text-align: center;
    width: 100%;
    padding: clamp(1.5rem, 4vw, 2.5rem) clamp(1rem, 3vw, 1.5rem);
    background-color: #F7F7F7;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  #stats-1574 .cs-icon {
    width: auto;
    height: 3rem;
    margin-bottom: 1.5rem;
  }
  #stats-1574 .cs-stat {
    font-size: clamp(1.9375rem, 4vw, 2.4375rem);
    font-weight: 900;
    line-height: 1.2em;
    margin-bottom: 0.25rem;
    color: var(--headerColor);
    display: block;
  }
  #stats-1574 .cs-info {
    font-size: clamp(0.875rem, 2vw, 1.25rem);
    line-height: 1.5em;
    color: var(--bodyTextColor);
  }
  #stats-1574 .cs-background {
    width: 100%;
    height: 9.375rem;
    object-fit: cover;
    background-color: var(--primary);
    position: absolute;
    top: 0;
    left: 0;
    z-index: -1;
  }
}
/* Tablet - 768px */
@media only screen and (min-width: 48rem) {
  #stats-1574 .cs-container {
    max-width: 80rem;
  }
  #stats-1574 .cs-card-group {
    grid-template-columns: repeat(12, 1fr);
  }
  #stats-1574 .cs-item {
    grid-column: span 3;
  }
}
/* Desktop - 1024px */
@media only screen and (min-width: 64rem) {
  #stats-1574 .cs-background {
    height: 50%;
  }
}