/* ============================
   BASE TIPO & COLORI
   ============================ */

body {
    background: #3878c1;
    color: #ffffff;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.6;
}

h1, h2, h3, h4 {
    font-family: "Libre Baskerville", serif;
    letter-spacing: 0.04em;
}


/* ============================
   NAVBAR CON FONT NUNITO
   ============================ */

.navbar-psicologo {
    background: transparent;
    padding-top: 1.6rem;
    padding-bottom: 1.6rem;
    z-index: 1000;

    position: fixed;
    top: 0;
    left: 0;
    right: 0;
}

/* NAVBAR quando la pagina è scrollata */
.navbar-psicologo.navbar-scrolled {
    background: #ffffff;
    padding-top: 0.8rem;
    padding-bottom: 0.8rem;
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

/* Link blu quando scrolled */
.navbar-psicologo.navbar-scrolled .nav-link,
.navbar-psicologo.navbar-scrolled .navbar-nav .menu-item a {
    color: #3878c1 !important;
}

/* Underline blu quando scrolled */
.navbar-psicologo.navbar-scrolled .nav-link::after,
.navbar-psicologo.navbar-scrolled .navbar-nav .menu-item a::after {
    background-color: #3878c1;
}

/* Toggler scrolled: icona scura e bordo leggero */
.navbar-psicologo.navbar-scrolled .navbar-toggler-icon {
    filter: none; /* torna scura sul bianco */
}

.navbar-psicologo.navbar-scrolled .navbar-toggler {
    border-color: rgba(56,120,193,0.4);
}

/* Link del menu (font Nunito) */
.navbar-psicologo .nav-link,
.navbar-psicologo .navbar-nav .menu-item a {
    color: #ffffff !important;
    font-family: "Nunito", sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.12em;
    text-decoration: none;
    padding: 0.4rem 0.75rem;
    position: relative;
    transition: opacity .25s ease;
}

/* Hover */
.navbar-psicologo .nav-link:hover,
.navbar-psicologo .navbar-nav .menu-item a:hover {
    opacity: 0.85;
}

/* Underline animato */
.navbar-psicologo .nav-link::after,
.navbar-psicologo .navbar-nav .menu-item a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 2px;
    width: 0%;
    height: 2px;
    background-color: rgba(255,255,255,0.9);
    transition: width .25s ease;
}

.navbar-psicologo .nav-link:hover::after,
.navbar-psicologo .navbar-nav .menu-item a:hover::after {
    width: 100%;
}

/* Hamburger bianco */
.navbar-psicologo .navbar-toggler {
    border: none;
    outline: none !important;
    box-shadow: none !important;
    padding: 0.25rem 0.35rem;
}

.navbar-psicologo .navbar-toggler-icon {
    filter: invert(1);
}

/* Dropdown */
.navbar-psicologo .dropdown-menu {
    background: #ffffff;
    border-radius: 12px;
    border: none;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.25);
    padding: 0.6rem 0;
}

.navbar-psicologo .dropdown-item {
    font-family: "Nunito", sans-serif;
    font-size: 0.9rem;
    color: #333333;
    padding: 0.55rem 1rem;
}

.navbar-psicologo .dropdown-item:hover {
    background: rgba(0,0,0,0.06);
    color: #111111;
}

/* Mobile */
@media (max-width: 991.98px) {

    .navbar-psicologo {
        padding-top: 1rem;
        padding-bottom: 1rem;
    }

    .navbar-psicologo .navbar-nav .nav-link {
        padding: 0.75rem 0;
        font-size: 1rem;
    }

    .navbar-psicologo .nav-link::after {
        display: none;
    }

    .navbar-psicologo .dropdown-menu {
        box-shadow: none;
        border-radius: 0;
        background: transparent;
        padding: 0;
    }

    .navbar-psicologo .dropdown-item {
        color: #ffffff;
        padding-left: 0;
    }

    .navbar-psicologo .dropdown-item:hover {
        background: none;
        opacity: 0.75;
    }
}

/* ============================
   HOME (FRONT-PAGE)
   ============================ */

.front-hero-blue {
    min-height: 100vh;
    padding-top: 140px;     /* spazio per navbar fixed-top */
    padding-bottom: 140px;
    background: #3878c1;
    color: #ffffff;
}

.front-title {
    font-family: "Libre Baskerville", serif;
    font-size: 4.2rem;
    letter-spacing: 0.04em;
    margin-bottom: 0.25rem;
    margin-top: 80px;
}

.front-subtitle {
    font-family: "Libre Baskerville", serif;
    font-size: 1.4rem;
    line-height: 2.2rem;
    opacity: 0.9;
    letter-spacing: 1px;
}

/* Card base usate in home */
.bio-card,
.photo-card,
.contact-card {
    background-color: #ffffff;
    border-radius: 18px;
    padding: 28px 30px;
    color: #222222;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.25);
}

/* Foto card home */
.photo-card {
    padding: 0;
    overflow: hidden;
}

.photo-card img {
    display: block;
    width: 100%;
}

.photo-caption {
    padding: 10px 16px 14px;
    font-size: 0.95rem;
    color: #555555;
    text-align: center;
}

/* Responsive home */
@media (max-width: 767.98px) {
    .front-hero-blue {
        padding-top: 110px;
        padding-bottom: 80px;
    }

    .front-title {
        font-size: 2.6rem;
    }

    .bio-card {
        padding: 22px 20px;
    }
}

/* ============================
   WRAPPER PAGINE / ARTICOLI / ARCHIVI
   ============================ */

/* Wrapper blu per page, single, archive */
.page-hero-blue {
    min-height: 100vh;
    padding-top: 120px;   /* spazio per navbar fixed-top */
    padding-bottom: 80px;
    background: #3878c1;
    color: #ffffff;
}

/* Layout centrato del contenuto principale */
.page-hero-blue .page-card {
    background-color: #ffffff;
    border-radius: 18px;
    padding: 28px 30px;
    color: #222222;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.25);
}

/* Titolo dentro la card */
.page-card .card-title {
    font-family: "Libre Baskerville", serif;
    letter-spacing: 0.04em;
    margin-bottom: 0.75rem;
}

/* Testo dentro la card */
.page-card .card-text,
.page-card .entry-content {
    font-family: "Libre Baskerville", serif;
    font-size: 1.05rem;
    line-height: 1.8;
}

/* Elementi tipici del contenuto WP */
.page-card .entry-content p {
    margin-bottom: 1.25rem;
}

.page-card .entry-content a {
    color: #3878c1;
    text-decoration: underline;
}

.page-card .entry-content a:hover {
    text-decoration: none;
}

/* Responsive pagine/single */
@media (max-width: 767.98px) {
    .page-hero-blue {
        padding-top: 100px;
        padding-bottom: 60px;
    }

    .page-hero-blue .page-card {
        padding: 22px 20px;
    }
}

/* ============================
   ARCHIVE (LISTA ARTICOLI)
   ============================ */

.archive .page-hero-blue h1.card-title {
    color: #ffffff;
}

.archive .card {
    border: 0;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    background-color: #ffffff;
}

/* Immagine in cima alla card */
.archive .card-img-top {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

/* Body della card */
.archive .card-body {
    padding: 1.2rem 1.4rem;
    color: #222222;
}

.archive .card-title {
    font-family: "Libre Baskerville", serif;
    font-size: 1.05rem;
    margin-bottom: 0.35rem;
}

.archive .card-title a {
    text-decoration: none;
    color: #222222;
}

.archive .card-title a:hover {
    text-decoration: underline;
}

.archive .card-text {
    font-size: 0.95rem;
}

/* Meta: data ecc. */
.archive .card .text-muted {
    font-size: 0.8rem;
}

/* Paginazione */
.archive .navigation,
.archive .pagination,
.archive .page-numbers {
    margin-top: 2.5rem;
}

.archive .page-numbers {
    display: inline-block;
    margin: 0 0.15rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    text-decoration: none;
    font-size: 0.9rem;
}

.archive .page-numbers.current {
    background: #ffffff;
    color: #3878c1;
    font-weight: 600;
}

.archive .page-numbers:hover:not(.current) {
    background: rgba(255, 255, 255, 0.3);
}

/* ============================
   SINGLE (ARTICOLO SINGOLO)
   ============================ */

/* Titolo + meta in alto */
.single .page-card .card-title {
    margin-bottom: 0.5rem;
}

.single .page-card .post-meta,
.single .page-card .text-muted {
    font-size: 0.85rem;
    color: #888888;
}

/* Contenuto */
.single .page-card .entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 1.5rem 0;
}

/* Link navigazione precedente/successivo */
.single .post-navigation a {
    color: #ffffff;
    text-decoration: none;
    font-size: 0.9rem;
}

.single .post-navigation a:hover {
    text-decoration: underline;
}

/* ============================
   PAGE (PAGINE STATICHE)
   ============================ */

/* Le pagine usano la stessa page-card di single
   Quindi qui solo piccoli ritocchi se necessari */

.page-template-default .page-card .card-title {
    font-size: 2rem;
}

.page-template-default .page-card .entry-content ul,
.page-template-default .page-card .entry-content ol {
    margin-left: 1.25rem;
    margin-bottom: 1.25rem;
}

/* ============================
   COMMENTI - STILE PER single.php
   ============================ */

/* Wrapper generale dei commenti */
.comments-area {
    margin-top: 40px;
}

/* titolo "Lascia un commento" */
.comments-area .comments-title,
.comments-area .comment-reply-title {
    font-family: "Libre Baskerville", serif;
    color: #ffffff;
    letter-spacing: 0.04em;
    font-size: 1.6rem;
    margin-bottom: 1.2rem;
}

/* card bianca che contiene commenti */
.comment-list,
.comment-respond {
    background: #ffffff;
    color: #222222;
    border-radius: 18px;
    padding: 28px 30px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.25);
}

/* lista commenti */
.comment-list {
    margin-bottom: 40px;
}

/* singolo commento */
.comment {
    margin-bottom: 25px;
}

/* autore + data */
.comment-meta .comment-author {
    font-weight: 700;
    font-family: "Nunito", sans-serif;
    color: #222222;
}

.comment-meta .comment-metadata {
    font-size: 0.8rem;
    color: #555555;
}

/* testo commento */
.comment-content {
    margin-top: 10px;
    font-family: "Libre Baskerville", serif;
    font-size: 1.05rem;
    line-height: 1.7;
}

/* Rispondi link */
.comment-reply-link {
    display: inline-block;
    margin-top: 10px;
    font-size: 0.85rem;
    color: #3878c1;
    text-decoration: none;
    font-weight: 600;
}

.comment-reply-link:hover {
    text-decoration: underline;
}

/* ============================
   FORM per lasciare un commento
   ============================ */

.comment-respond {
    margin-top: 40px;
}

/* input e textarea */
.comment-respond input[type="text"],
.comment-respond input[type="email"],
.comment-respond input[type="url"],
.comment-respond textarea {
    width: 100%;
    border-radius: 12px;
    border: 1px solid #dddddd;
    padding: 12px 14px;
    font-size: 1rem;
    background: #f8f8f8;
    font-family: "Nunito", sans-serif;
    transition: border-color .2s ease;
}

/* focus */
.comment-respond input:focus,
.comment-respond textarea:focus {
    border-color: #3878c1;
    outline: none;
}

/* label */
.comment-respond label {
    font-weight: 600;
    margin-bottom: 6px;
    font-family: "Nunito", sans-serif;
    display: inline-block;
    color: #333;
}

/* pulsante invio */
.comment-respond input[type="submit"] {
    background: #3878c1;
    color: #ffffff;
    padding: 12px 24px;
    border: none;
    border-radius: 12px;
    font-family: "Nunito", sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: opacity .25s ease;
}

.comment-respond input[type="submit"]:hover {
    opacity: 0.85;
}

/* ============================
   COMMENTI - LISTA + CARD
   ============================ */

.comments-area {
    margin-top: 40px;
}

/* Titoli: "Un commento", "Lascia un commento" */
.comments-area .comments-title,
.comments-area .comment-reply-title {
    font-family: "Libre Baskerville", serif;
    color: #ffffff;
    letter-spacing: 0.04em;
    font-size: 1.6rem;
    margin-bottom: 1.2rem;
}

/* Lista principale dei commenti (ol.commentlist) */
.commentlist {
    list-style: none;
    margin: 0 0 40px 0;
    padding: 0;
}

/* Singolo commento (li.comment) */
.commentlist > .comment {
    margin-bottom: 22px;
}

/* BOX del commento (div.comment-body) */
.comment-body {
    background: #ffffff;
    color: #222222;
    border-radius: 18px;
    padding: 22px 24px;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.18);
}

/* Autore + avatar */
.comment-author {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: "Nunito", sans-serif;
}

/* Avatar */
.comment-author .avatar {
    border-radius: 50%;
    width: 40px;
    height: 40px;
}

/* Nome autore (cite.fn) */
.comment-author .fn {
    font-weight: 700;
    font-style: normal;
    color: #222222;
    font-size: 0.95rem;
}

.comment-author .fn a {
    color: inherit;
    text-decoration: none;
}

.comment-author .fn a:hover {
    text-decoration: underline;
}

/* "ha detto:" */
.comment-author .says {
    font-size: 0.8rem;
    color: #666666;
}

/* Meta (data, link permanente) */
.comment-meta,
.commentmetadata {
    margin-top: 4px;
    font-size: 0.8rem;
    color: #777777;
    font-family: "Nunito", sans-serif;
}

.comment-meta a,
.commentmetadata a {
    color: #777777;
    text-decoration: none;
}

.comment-meta a:hover,
.commentmetadata a:hover {
    text-decoration: underline;
}

/* Testo del commento */
.comment-body p {
    margin-top: 12px;
    margin-bottom: 0.75rem;
    font-family: "Libre Baskerville", serif;
    font-size: 1.0rem;
    line-height: 1.7;
}

.comment-body a {
    color: #3878c1;
    text-decoration: underline;
}

.comment-body a:hover {
    text-decoration: none;
}

/* Link "Rispondi" */
.comment-body .reply {
    margin-top: 10px;
}

.comment-reply-link {
    display: inline-block;
    font-size: 0.8rem;
    font-family: "Nunito", sans-serif;
    font-weight: 600;
    color: #3878c1;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.comment-reply-link:hover {
    text-decoration: underline;
}

/* ============================
   RISPOSTE (nested replies .children)
   ============================ */

/* Lista delle risposte annidate */
.commentlist .children {
    list-style: none;
    margin: 20px 0 0 32px;
    padding-left: 16px;
    border-left: 3px solid rgba(56,120,193,0.25); /* blu soft */
}

/* Ogni risposta (li.comment dentro .children) */
.commentlist .children .comment {
    margin-bottom: 18px;
}

/* Box della risposta */
.commentlist .children .comment-body {
    border-radius: 16px;
    padding: 18px 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

/* Testo delle risposte leggermente più piccolo */
.commentlist .children .comment-body p {
    font-size: 0.95rem;
}

/* Responsive: riduco indentazione su mobile */
@media (max-width: 767.98px) {
    .commentlist .children {
        margin-left: 16px;
        padding-left: 10px;
        border-left-width: 2px;
    }

    .comment-body {
        padding: 18px 18px;
    }
}

/* Link dentro card bianche (testo dei commenti, dei post, dei widget, ecc.) */
.page-card a,
.comment-body a,
.comment-content a,
.entry-content a {
    color: #222222;                /* colore scuro elegante */
    text-decoration: underline;
    transition: color .2s ease;
}

.page-card a:hover,
.comment-body a:hover,
.comment-content a:hover,
.entry-content a:hover {
    color: #000000;
    text-decoration: none;
}

/* Metadati: date, permalinks, autore */
.comment-meta a,
.commentmetadata a,
.post-navigation a,
.single .post-navigation a {
    color: #555555;
    text-decoration: none;
}

.comment-meta a:hover,
.commentmetadata a:hover,
.post-navigation a:hover,
.single .post-navigation a:hover {
    color: #222222;
    text-decoration: underline;
}


@media (max-width: 991.98px) {

    /* Contenitore del menu aperto */
    #mainNavbar {
        background: #3878c1;   /* blu solido */
        padding-top: 1.5rem;
        padding-bottom: 1.5rem;
        animation: slideDown 0.25s ease;
        border-radius: 0;
    }

    /* Voci del menu */
    #mainNavbar .navbar-nav a {
        display: block;
        padding: 0.85rem 0;
        font-family: "Nunito", sans-serif;
        font-size: 1.0rem;
        font-weight: 700;
        color: #ffffff !important;
        text-decoration: none !important;    /* NESSUN SOTTOLINEATO */
        letter-spacing: 0.03em;
        transition: all 0.25s ease;
        border-radius: 0;  /* rende bello l’hover */
    }

    /* Hover mobile: sfondo bianco + testo blu */
    #mainNavbar .navbar-nav a:hover {
        background: rgba(255,255,255,0.70);
        color: #3878c1 !important;
    }

    /* Attivo */
    #mainNavbar .navbar-nav .current-menu-item > a {
        background: rgba(255,255,255,0.70);
        color: #3878c1 !important;
    }

    /* Separatore */
    #mainNavbar .navbar-nav li {
        border-bottom: 1px solid rgba(255,255,255,0.20);
        padding-bottom: 0.6rem;
    }

    #mainNavbar .navbar-nav li:last-child {
        border-bottom: none;
    }

    /* Animazione */
    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-8px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
}
