/*
Theme Name: Avada Child
Description: Child theme for Avada theme
Author: ThemeFusion
Author URI: https://theme-fusion.com
Template: Avada
Version: 1.0.0
Text Domain:  Avada
/* ==========================================================
   TIMELINE COOPERATIVA ABBRACCI
   Desktop: linea centrale
   Tablet e smartphone: linea a sinistra
   La linea termina all'ultimo pallino
   ========================================================== */

:root {
    --main: #4cd984;
    --timeline-arancione: #f3744b;
    --timeline-blu: #29275c;
    --timeline-card-bg: #ece7da;
}

/* ==========================================================
   STRUTTURA GENERALE
   ========================================================== */

.timeline {
    position: relative;
}

/* Linea centrale desktop */

.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background: var(--timeline-arancione);
    left: 0;
    right: 0;
    margin: auto;
    top: 0;
    bottom: 0;
    z-index: 0;
}

/* Righe */

.timeline > .row {
    position: relative;
    margin-bottom: 40px;
}

/* Pallini */

.timeline > .row::after {
    content: '';
    position: absolute;
    width: 22px;
    height: 22px;
    box-sizing: content-box;
    left: 0;
    right: 0;
    margin: auto;
    top: 0;
    background-color: var(--timeline-blu);
    border: 4px solid var(--timeline-arancione);
    border-radius: 50%;
    z-index: 3;
}

/* ==========================================================
   CARD
   ========================================================== */

.timeline .card.shadow {
    background-color: var(--timeline-card-bg) !important;
    border: none !important;
    border-radius: 10px !important;
    box-shadow: 0 6px 18px rgba(0,0,0,0.15) !important;
    margin-bottom: 40px;
}

.timeline .card-header {
    background-color: transparent;
    border-bottom: none;
    padding: 20px 20px 0;
    margin: 0;
}

.timeline .card-body {
    background-color: transparent;
    padding: 10px 20px 20px;
    margin: 0;
    color: #3c3c3b;
    font-size: 14px;
    line-height: 1.6;
}

/* Spaziature desktop */

.timeline .pr-5 {
    padding-right: 60px;
}

.timeline .pl-5 {
    padding-left: 60px;
}

/* ==========================================================
   BADGE ANNO
   ========================================================== */

.timeline-anno {
    display: inline-block;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    padding: 4px 14px;
    border-radius: 999px;
    margin-bottom: 10px;
}

.timeline-text-right .timeline-anno {
    background-color: var(--timeline-blu);
}

.timeline-text-left .timeline-anno {
    background-color: var(--timeline-arancione);
}

/* ==========================================================
   TITOLI
   ========================================================== */

.timeline-titolo {
    font-size: 17px;
    font-weight: 700;
    font-style: normal;
    color: var(--timeline-blu);
    border-bottom: none;
    margin-bottom: 8px;
}

/* ==========================================================
   IMMAGINI
   ========================================================== */

.timeline-immagine {
    margin: 0 40px 60px;
}

.timeline-immagine img {
    margin-bottom: 40px;
}

@media only screen and (min-width: 1200px) {

    .timeline-immagine.condorelli-timeline-4-min img {
        max-width: 250px;
        float: right;
    }

    .timeline-immagine.condorelli-timeline-3-min img {
        max-width: 250px;
    }

    .timeline-immagine.condorelli-timeline-5-min img {
        max-width: 420px;
    }

    .timeline-immagine.mocksito-min img {
        max-width: 350px;
    }
}

/* ==========================================================
   DESKTOP - DA 1025PX
   ========================================================== */

@media only screen and (min-width: 1025px) {

    .timeline-text-right,
    .timeline-text-left {
        text-align: left;
    }
}

/* ==========================================================
   TABLET E SMARTPHONE - FINO A 1024PX
   ========================================================== */

@media only screen and (max-width: 1024px) {

    /* Disabilita la linea globale desktop */

    .timeline::after {
        content: none !important;
        display: none !important;
    }

    /* Righe */

    .timeline > .row {
        position: relative;
        display: grid;
        margin-bottom: 60px;
        z-index: auto;
    }

    /* Pallini allineati a sinistra */

    .timeline > .row::after {
        content: '';
        display: block;
        left: 0;
        right: auto;
        top: 0;
        margin: 0;
        z-index: 3;
    }

    /* 
       LINEA VERTICALE TRA I PALLINI

       La linea parte dal centro del pallino
       e prosegue fino al pallino successivo.
       L'ultima riga è esclusa.
    */

    .timeline > .row:not(:last-child)::before {
        content: '' !important;
        display: block !important;
        position: absolute !important;
        width: 2px !important;
        height: auto !important;
        left: 14px !important;
        right: auto !important;
        top: 15px !important;
        bottom: -75px !important;
        margin: 0 !important;
        padding: 0 !important;
        background: var(--timeline-arancione) !important;
        z-index: 1 !important;
        border: 0 !important;
        pointer-events: none;
    }

    /* Ultima riga: nessuna linea successiva */

    .timeline > .row:last-child::before {
        content: none !important;
        display: none !important;
    }

    /* Spaziatura colonne */

    .timeline .pr-5,
    .timeline .pl-5 {
        padding: 0 !important;
        padding-left: 50px !important;
        padding-right: 30px !important;
    }

    /* Ordine elementi */

    .timeline > .row:nth-child(odd) > div:nth-child(1) {
        order: 1;
    }

    /* Allineamento testi */

    .timeline-text-right,
    .timeline-text-left {
        text-align: left;
    }

    /* Immagini */

    .timeline-immagine,
    .timeline-immagine img {
        margin-bottom: 0;
    }

    .timeline .card-header,
    .timeline .card-body,
    .timeline-immagine {
        margin: 0;
    }
}

/* ==========================================================
   SMARTPHONE - FINO A 640PX
   ========================================================== */

@media only screen and (max-width: 640px) {

    .timeline > .row {
        margin-bottom: 45px;
    }

    /* Collegamento tra i pallini su smartphone */

    .timeline > .row:not(:last-child)::before {
        bottom: -60px !important;
    }

    .timeline .pr-5,
    .timeline .pl-5 {
        padding-left: 45px !important;
        padding-right: 10px !important;
    }

    .timeline .card-header {
        padding: 18px 18px 0;
    }

    .timeline .card-body {
        padding: 10px 18px 20px;
    }

    .timeline-titolo {
        font-size: 16px;
    }

    .timeline-anno {
        font-size: 12px;
    }
}