body,
html {
    height: 100%;
}

body {
    background: linear-gradient(to bottom,
            rgb(12, 106, 116),
            rgb(110, 187, 195),
            rgba(122, 184, 191, 1),
            rgba(196, 237, 242, 1),
            rgb(178, 126, 218));
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    background-attachment: fixed;
}

#fotomia {
    display: block;
    margin: 20px auto;
}

h1 {
    color: white;
    font-weight: 600;
}

h2 {
    color: rgb(15, 140, 138);
}

h3 {
    text-align: center;
}

h4 {
    color: rgb(144, 30, 140);
}

#titolo_principale {
    color: #fff;
    text-shadow:
        2px 2px 2px #1C6EA4,
        4px 4px 3px #2285C7,
        6px 6px 4px #289DEA;
    text-align: center;
    font-style: italic;
    font-family: 'Georgia', serif;
    font-size: 2.5em;
    padding: 1%;
}

#sottotitolo {
    font-family: 'Montserrat', sans-serif;
    /* Prova uno di quelli sopra */
    font-size: 1.1rem;
    color: #ffffff;
    /* Il tuo colore scuro attuale va benissimo */
    letter-spacing: 1.5px;
    /* Dà aria alla frase */
    opacity: 0.8;
    /* Lo rende leggermente meno "aggressivo" del titolo principale */
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
    margin-top: 10px;
    letter-spacing: 0.5px;
}

.card-presentazione {
    border: 3px solid #b3e5fc;
    background: linear-gradient(to right, #ffffff, #e0f7fa);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 3px solid #b3e5fc;
    box-shadow:
        /* Ombra esterna per il rilievo (azzurro scuro/grigio) */
        8px 8px 0px #162d3620,
        /* Luce sul bordo per l'effetto 3D */
        inset 2px 2px 0px rgba(255, 255, 255, 0.9),
        /* Ombra interna per dare spessore */
        inset -2px -2px 5px rgba(18, 90, 116, 0.1);

    transition: all 0.3s ease;
}

.testo-bio {
    font-family: 'Georgia', serif;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #2c3e50;
    text-align: center;
    font-weight: normal;
}

.testo-bio h1,
.testo-bio h2,
.testo-bio p {
    font-weight: normal;
}

.highlight {
    color: #0003af;
    text-shadow:
        4px 4px 3px #e5eef4;
    font-style: italic;
    margin-top: 20px;
    font-weight: normal;
}

.image-hero {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 30px;
    padding: 50px;
    display: block;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .card-presentazione .row {
        flex-direction: column-reverse;
    }

    .image-hero {
        height: auto;
    }
}

#categorietiktok {
    text-align: left;
    font-family: 'Georgia', sans-serif;
}

p {
    font-weight: bold;
}

.btn-rettangolare {
    background-color: #6e70d2;
    /* Il tuo viola */
    color: white !important;
    font-family: 'Georgia', serif;
    font-size: 1.1rem;
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    /* Bordi poco arrotondati per farlo sembrare un tasto solido */
    font-weight: normal !important;
    box-shadow: 0 4px 0px #4d4f96;
    /* Ombra netta sotto per effetto 3D premibile */
    transition: all 0.2s ease;
    cursor: pointer;
    display: inline-block;
    margin-top: 10px;
}

.btn-rettangolare:hover {
    background-color: #5b5da8;
    /* Si scurisce leggermente al passaggio */
    transform: translateY(2px);
    /* Si abbassa un po' */
    box-shadow: 0 2px 0px #4d4f96;
    /* L'ombra diminuisce quando si preme */
    color: white !important;
}

.btn-rettangolare:active {
    transform: translateY(4px);
    /* Si schiaccia del tutto al click */
    box-shadow: 0 0px 0px #4d4f96;
}

h2.colorato {
    color: rgb(59, 59, 141);
}

#titolipagine {
    text-align: center;
    background: linear-gradient(to bottom,
            rgb(12, 106, 116),
            rgb(110, 187, 195),
            rgba(122, 184, 191, 1),
            rgba(196, 237, 242, 1),
            rgb(178, 126, 218));
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    background-attachment: fixed;
    font-style: italic;
    font-family: 'Georgia', serif;
    padding: 1.5%;
    margin-bottom: 25px;
    margin-top: 25px;
}

.book {
    max-width: 800px;
    margin: 50px auto;
}

.card-header {
    background-color: #E0F2F7;
    border-bottom: 1px solid #B3E5FC;
}

.card-header-tabs {
    justify-content: center;
}

.card-header-tabs .nav-link {
    color: #2c3e50;
}

.card-header-tabs .nav-link:hover {
    color: #007bff;
}

.card-header-tabs .nav-link.active {
    color: #05445E;
    font-weight: bold;
}

.col-lg-4 .card {
    border: none;
    background: transparent;
    width: 100%;
    max-width: none;
    margin: 0;
    transition: transform 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    /* Imposta una larghezza massima uguale per tutto il sito */
    margin: 0 auto;
}

.col-lg-4 .card:hover {
    transform: translateY(-10px);
    cursor: pointer;
}

.card-img-top {
    width: 100%;
    border-radius: 15px 15px 0 0;
    display: block;
    object-fit: cover;
    margin: 0;
}

.card-body {
    border: none;
    background: linear-gradient(to bottom, rgb(179, 247, 255), rgb(255, 255, 255));
    border-radius: 0 0 15px 15px;
    padding: 40px 30px;
    width: 100%;
    box-shadow: 0 10px 20px #1a617aa6;
    margin-top: -1px;
    transition: box-shadow 0.3s ease-in-out;
}

.col-lg-4 .card:hover .card-body {
    box-shadow: 0 15px 30px #1a617ad0;
}

.book .card {
    width: 100%;
    transform: none;
}

.book .card:hover {
    transform: none;
    cursor: default;
}

.card-header {
    background-color: #E0F2F7;
    border-bottom: 1px solid #B3E5FC;
}

.card-header-tabs {
    display: flex;
    justify-content: center;
    flex-wrap: nowrap;
    margin: 0 auto;
    padding: 10px 0;
    border-bottom: none;
}

.card-header-tabs .nav-item {
    flex: 0 1 auto;
    margin: 0 5px;
}

.card-header-tabs .nav-link {
    white-space: nowrap;
    color: #305b77;
    background: transparent;
    border: none;
    border-radius: 8px 8px 0 0;
    padding: 10px 20px;
    transform: none;
    transition: background-color 0.3s ease;
}

.card-header-tabs .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.6);
    color: #305b77;
    transform: none;
}

.card-header-tabs .nav-link.active {
    background-color: #ffffff;
    color: #05445E;
    font-weight: bold;
    transform: none;
    box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.05);
}

#barra-bassa {
    background-color: #1f6f73;
    color: white;
    text-align: center;
    padding: 15px;
}

.corpo-libro {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

#sin {
    font-family: Arial, Helvetica, sans-serif;
    text-align: justify;
    line-height: 1.8;
}

#dedica {
    font-family: Arial, Helvetica, sans-serif;
    text-align: justify;
    line-height: 1.8;
}

#c1 {
    font-family: Arial, Helvetica, sans-serif;
    text-align: justify;
    line-height: 1.8;
}

#c2 {
    font-family: Arial, Helvetica, sans-serif;
    text-align: justify;
    line-height: 1.8;
}

.pagina-interna {
    width: 100%;
    padding: 0 20px;
}

.nav-pagine {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 25px;
    padding-top: 15px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    column-span: all;
    clear: both;
}

#contatore {
    font-size: 0.9rem;
    color: #666;
    font-weight: bold;
}

@media (max-width: 768px) {
    .pagina-interna {
        column-count: 1;
    }
}

#c2 {
    font-family: Arial, Helvetica, sans-serif;
    text-align: justify;
}

.button-container {
    display: flex;
    justify-content: flex-end;
    width: 100%;
}

.home-icon {
    position: absolute;
    top: 25px;
    left: 50px;
    font-size: 3.5rem;
    color: #072f5a;
    display: inline-block;
    transition: 0.2s;
    z-index: 1000;
    text-decoration: none;
}

.home-icon:hover {
    transform: scale(1.1);
    color: #3568a3;
    cursor: pointer;
}
