/*
Theme Name: Allison Lister
Theme URI: https://itamde.com
Description: A custom theme for Allison Lister
Author: Antonella De Chiara
Author URI: https://itamde.com
Version: 1.0.2
Text Domain: allisonlister
Template: chapterone
*/

::selection {
    background: #2e0089 !important;
}

a,
p a {
    color: purple;
    text-decoration: none;
    transition: color .2s ease-out;
    font-weight: 500;
}

/* Featured image come <img> indicizzabile invece che CSS background.
   L'img è posizionato come prima era il background. Override invariato visivamente. */
.mkdf-post-image-background.mkdf-post-image-bg-img {
    overflow: hidden;
}
.mkdf-post-image-background.mkdf-post-image-bg-img > .mkdf-post-image-bg-img-el {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
}
.mkdf-post-image-background.mkdf-post-image-bg-img > a {
    z-index: 1;
}

/* Nome autore in archivio: era H2, ora <p> per non duplicare H1 della title-area.
   Manteniamo l'aspetto visivo dell'H2 originale. */
p.mkdf-archive-author-title {
    font-family: inherit;
    font-size: 32px;
    line-height: 1.2;
    font-weight: 700;
    margin: 0;
}
.mkdf-header-vertical .mkdf-vertical-area-background {
    background-color: rgba(46, 0, 137, 0.2) !important;
}
/*
.mkdf-header-vertical .mkdf-vertical-menu ul li.current-menu-ancestor>a,
.mkdf-header-vertical .mkdf-vertical-menu ul li.current-menu-item>a,
.mkdf-header-vertical .mkdf-vertical-menu ul li.current_page_item>a,
.mkdf-header-vertical .mkdf-vertical-menu ul li.mkdf-active-item>a {
    background-color: rgba(46, 0, 137, 0.6) !important;
}
    */
.woocommerce-page .mkdf-content .wc-forward:not(.added_to_cart):not(.checkout-button), 
.woocommerce-page .mkdf-content a.added_to_cart, .woocommerce-page .mkdf-content a.button, 
.woocommerce-page .mkdf-content button[type=submit]:not(.mkdf-search-submit), 
.woocommerce-page .mkdf-content input[type=submit], 
div.woocommerce .wc-forward:not(.added_to_cart):not(.checkout-button), 
div.woocommerce a.added_to_cart, 
div.woocommerce a.button, div.woocommerce button[type=submit]:not(.mkdf-search-submit), div.woocommerce input[type=submit],
.mkdf-btn.mkdf-btn-solid {
    background-color: rgba(46, 0, 137, 1) !important;
}
#mkdf-back-to-top>span {
    background-color:  #2e0089 !important;
    border: 1px solid #2e0089 !important;
}
a:hover, p a:hover {
    color: #2e0089 !important;
}
.mkdf-header-vertical .mkdf-vertical-menu ul li a:hover,
.mkdf-blog-holder article.format-quote .mkdf-post-mark .mkdf-quote-mark,
.mkdf-blog-holder article.format-link .mkdf-post-mark .mkdf-link-mark,
.mkdf-owl-slider .owl-nav .owl-next:hover,
.mkdf-owl-slider .owl-nav .owl-prev:hover {
    color: #2e0089 !important;
}
.mkdf-shopping-cart-holder .mkdf-header-cart .mkdf-sc-opener-count,
.woocommerce-page .mkdf-content a.button:hover {
    background-color: rgba(46, 0, 137, 1) !important;
}
.mkdf-btn.mkdf-btn-solid:not(.mkdf-btn-custom-border-hover):hover,
.mkdf-btn.mkdf-btn-solid:not(.mkdf-btn-custom-hover-bg):hover {
    background-color: rgb(30, 0, 90) !important;
}
.mkdf-header-vertical .mkdf-vertical-menu ul li.current-menu-ancestor>a,
.mkdf-header-vertical .mkdf-vertical-menu ul li.current-menu-item>a,
.mkdf-header-vertical .mkdf-vertical-menu ul li.current_page_item>a,
.mkdf-header-vertical .mkdf-vertical-menu ul li.mkdf-active-item>a {
    color: #2e0089 !important;
}

/* HEADER */
.mkdf-mobile-header .mkdf-mobile-logo-wrapper img {
    height: 75% !important;
}

/* Contact form */
.wpcf7-form p, p.form-submit {
    margin: 28px 0 0 0;
}
.mkdf-side-menu .widget.mkdf-contact-form-7-widget p {
    margin: 8px 0 0 0;
}

/* POSTS */
body.wp-singular.post-template-default.single.single-post .mkdf-post-text-main {
    padding-top: 20px;
    /* padding-bottom: 20px; */
}
.post-views.content-post {
    margin-top: 20px;
}
/*.mkdf-blog-single-navigation .mkdf-blog-single-navigation-inner .mkdf-blog-share {
  bottom: 1px !important;
} */

/* ============================================
   GUTENBERG EDITOR
   ============================================ */
.block-editor .editor-styles-wrapper [data-block],
.block-editor .editor-styles-wrapper [data-block]  {
    margin-left: auto !important;
    margin-right: auto !important;
}

/* ============================================
   ITAMDE BOOKS MANAGER - STYLE.CSS
   Ottimizzato per tema Allison Lister
   ============================================ */

/* Books Container */
.books-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}
pre.wp-block-preformatted {
    padding-top: 5px;
}

/* ============================================
   FILTERS SECTION
   ============================================ */
.books-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 50px;
    padding: 30px;
    background: rgba(46, 0, 137, 0.05);
    border-radius: 0;
    border-left: 4px solid #2e0089;
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.filter-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #2e0089;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.book-filter {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 0;
    font-size: 15px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.book-filter:hover,
.book-filter:focus {
    border-color: #2e0089;
    outline: none;
    box-shadow: 0 0 0 1px rgba(46, 0, 137, 0.1);
}

/* ============================================
   BOOKS GRID — unica definizione del componente, Flexbox.
   Il plugin itamde-books NON ridichiara .books-grid.

   Perché flex e non grid: in grid, justify-content centra le TRACCE nel
   contenitore, non gli item nella riga; la traccia vuota dell'ultima
   riga resta e lascia un buco a destra. In flex con flex-wrap: wrap +
   justify-content: center, le righe incomplete vengono centrate come
   gruppo di item, che è il comportamento voluto.
   ============================================ */
.books-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px;
    margin: 0 auto 40px;
}

/* Basis fissa. Niente max-width, niente percentuali sui figli:
   le percentuali sui figli dentro un contenitore grid si risolvevano
   sulla cella e rompevano il layout — qui restiamo lontani da quel pattern. */
.books-grid > .book-card {
    flex: 0 0 373px;
}

/* Varianti colonne: cappano la larghezza del CONTENITORE, mai dei figli. */
.books-grid-cols-1 { max-width: 373px; }
.books-grid-cols-2 { max-width: 786px; }   /* 2 × 373 + 1 × 40 */
.books-grid-cols-3 { max-width: 1199px; }  /* 3 × 373 + 2 × 40 */
.books-grid-cols-4 { max-width: 1612px; }  /* 4 × 373 + 3 × 40 */

/* ============================================
   BOOK CARD
   ============================================ */
.book-card {
    background: white;
    border-radius: 0;
    overflow: hidden;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
    position: relative;
}

.book-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px rgba(46, 0, 137, 0.15);
}

.book-card .book-cover {
    width: 100%;
    height: 450px;
    overflow: hidden;
    background: #f5f5f5;
    position: relative;
}

.book-card .book-cover::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(46, 0, 137, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.book-card .book-cover a {
    display: block;
    width: 100%;
    height: 100%;
}

.book-card:hover .book-cover::after {
    opacity: 1;
}

.book-card .book-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.book-card:hover .book-cover img {
    transform: scale(1.08);
}

.book-card .book-content {
    padding: 30px 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.book-card .book-title {
    font-size: 22px;
    margin: 0 0 15px 0;
    color: #1a1a1a;
    line-height: 1.3;
    font-weight: 600;
    transition: color 0.3s ease;
}

.book-card:hover .book-title {
    color: #2e0089;
}

.book-card .book-excerpt {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.7;
    flex: 1;
    font-size: 15px;
}

/* ============================================
   BOOK LINKS IN CARDS
   ============================================ */
.book-card .book-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.book-card .book-link {
    padding: 8px 16px;
    border-radius: 0;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.book-card .amazon-link {
    background: #FF9900;
    color: white;
}

.book-card .amazon-link:hover {
    background: #e68a00;
    transform: translateY(-2px);
}

.book-card .kofi-link {
    background: #29ABE0;
    color: white;
}

.book-card .kofi-link:hover {
    background: #1a8fc4;
    transform: translateY(-2px);
}

.book-card .audio-link {
    background: #8B5CF6;
    color: white;
}

.book-card .audio-link:hover {
    background: #7C3AED;
    transform: translateY(-2px);
}

.book-card .youtube-link {
    background: #FF0000;
    color: white;
}

.book-card .youtube-link:hover {
    background: #cc0000;
    transform: translateY(-2px);
}

.book-card .book-read-more {
    display: inline-block;
    padding: 12px 30px;
    background: #2e0089;
    color: white !important;
    text-decoration: none;
    border-radius: 0;
    text-align: center;
    font-weight: 600;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 13px;
    align-self: flex-start;
}

.book-card .book-read-more:hover {
    background: rgb(30, 0, 90);
    transform: translateX(5px);
}

/* ============================================
   SINGLE BOOK - TITLE & META
   ============================================ */
.single-book .single-book-cover {
    flex: 0 0 300px !important;
    position: sticky;
    top: 20px;
    align-self: flex-start;
}

.single-book .single-book-cover img {
    width: 100% !important;
    height: auto !important;
    max-width: 100%;
    border-radius: 4px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    display: block;
}

.single-book--purchasable { --book-cover-mobile-width: 120px; }

.book-main-title {
    font-size: 3em !important;
    font-weight: 700 !important;
    margin-bottom: 20px !important;
    line-height: 1.2 !important;
    color: #1a1a1a !important;
    margin-top: 0 !important;
}

.book-taxonomies {
    margin: 25px 0 40px 0 !important;
    padding: 20px 0;
    border-top: 1px solid #e0e0e0;
    border-bottom: 1px solid #e0e0e0;
}

.book-categories,
.book-languages {
    margin: 8px 0;
    color: #666 !important;
    font-size: 15px;
}

.book-categories strong,
.book-languages strong {
    color: #2e0089;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.5px;
}

.book-taxonomies a {
    color: #666 !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.book-taxonomies a:hover {
    color: #2e0089 !important;
}

/* ============================================
   SINGLE BOOK - DESCRIPTION SECTIONS
   ============================================ */
.book-description {
    background: white;
    padding: 50px !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    border-radius: 0;
    margin-bottom: 40px !important;
    border-left: 4px solid #2e0089;
}

.book-opening {
    font-size: 1.25em !important;
    font-weight: 500 !important;
    color: #1a1a1a !important;
    margin-bottom: 35px !important;
    padding-left: 25px !important;
    border-left: 4px solid rgba(46, 0, 137, 0.3) !important;
    line-height: 1.8 !important;
    font-style: italic;
}

.book-main-text {
    margin-bottom: 30px !important;
    text-align: justify;
    color: #333;
    font-size: 16px;
}

.book-main-text p {
    margin-bottom: 20px !important;
    line-height: 1.9 !important;
    font-size: 1.25em;
}

.book-separator {
    text-align: center !important;
    margin: 45px 0 !important;
    color: #2e0089 !important;
    font-size: 1.5em !important;
    letter-spacing: 10px !important;
    opacity: 0.4;
}

.book-comparison {
    font-style: italic !important;
    color: #555 !important;
    margin: 35px 0 !important;
    padding: 25px !important;
    background: rgba(46, 0, 137, 0.03) !important;
    border-radius: 0;
    font-size: 1.1em !important;
    border-left: 3px solid rgba(46, 0, 137, 0.3);
}

.book-tagline {
    font-weight: 600 !important;
    color: #2e0089 !important;
    margin-top: 40px !important;
    padding-top: 30px !important;
    border-top: 2px solid rgba(46, 0, 137, 0.2) !important;
    font-size: 1.15em !important;
    text-align: center !important;
    font-style: italic !important;
}

/* ============================================
   SINGLE BOOK - LINKS SECTION
   ============================================ */
.book-links-section {
    background: white !important;
    padding: 40px 50px !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    border-radius: 0;
    margin-bottom: 40px !important;
    border-left: 4px solid #2e0089;
}

.book-links-section h3 {
    margin-top: 0 !important;
    margin-bottom: 25px !important;
    font-size: 1.5em !important;
    color: #2e0089;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.single-book .book-links {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.single-book .book-link {
    padding: 14px 28px;
    border-radius: 0;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.single-book .amazon-link {
    background: #FF9900;
    color: white !important;
}

.single-book .amazon-link:hover {
    background: #e68a00;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(255, 153, 0, 0.3);
}

.single-book .kofi-link {
    background: #29ABE0;
    color: white !important;
}

.single-book .kofi-link:hover {
    background: #1a8fc4;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(41, 171, 224, 0.3);
}

.single-book .audio-link {
    background: #8B5CF6;
    color: white !important;
}

.single-book .audio-link:hover {
    background: #7C3AED;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.3);
}

/* ============================================
   SINGLE BOOK - SEO SECTION
   ============================================ */
.book-seo-section {
    background: white !important;
    padding: 40px 50px !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    border-radius: 0;
    margin-bottom: 40px !important;
    line-height: 1.9 !important;
    border-left: 4px solid rgba(46, 0, 137, 0.3);
}

.book-seo-section p {
    color: #333 !important;
}

/* ============================================
   SINGLE BOOK - YOUTUBE SECTION
   ============================================ */
.book-youtube-section {
    background: white !important;
    padding: 40px 50px !important;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
    border-radius: 0;
    margin-bottom: 40px !important;
    border-left: 4px solid #2e0089;
}

.book-youtube-section h3 {
    margin-top: 0 !important;
    margin-bottom: 25px !important;
    font-size: 1.5em !important;
    color: #2e0089;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.book-youtube-video {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.book-youtube-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
}

/* ============================================
   HIDE THEME ELEMENTS
   ============================================ */
.single-book .mkdf-post-heading,
.single-book .mkdf-title-holder.mkdf-standard-type.mkdf-title-va-header-bottom,
.single-book .mkdf-post-info-top,
.single-book h2.entry-title.mkdf-post-title,
.single-book .mkdf-post-info-bottom {
    display: none !important;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 1024px) {
    .single-book .single-book-wrapper {
        gap: 40px;
    }
    

}

@media (min-width: 769px) and (max-width: 1024px) {
    .single-book .single-book-cover { flex-basis: 350px !important; }
}

@media (max-width: 768px) {
    .books-filters {
        flex-direction: column;
        padding: 25px;
    }

    .books-grid {
        gap: 30px;
    }

    /* Su mobile le card possono crescere oltre la basis per riempire
       il viewport: flex: 1 1 260px → basis 260, grow 1. Mantiene
       la logica "no percentuali esplicite", il grow fa il responsive. */
    .books-grid > .book-card {
        flex: 1 1 260px;
    }

    .book-card .book-cover {
        height: 380px;
    }

    /* Single Book Responsive */
    .single-book {
        padding: 40px 20px;
    }
    
    .single-book .single-book-wrapper {
        flex-direction: column !important;
        gap: 40px;
    }

    .single-book .single-book-cover {
        flex: none !important;
        width: var(--book-cover-mobile-width, 300px);
        max-width: 100%;
        margin: 0 auto;
        position: static !important;
    }

    .book-main-title {
        font-size: 2.2em !important;
    }

    .book-description,
    .book-links-section,
    .book-youtube-section,
    .book-seo-section {
        padding: 30px !important;
    }
}

@media (max-width: 480px) {
    .books-grid {
        gap: 25px;
    }

    /* Card già flex: 1 1 260px dalla @media 768 → su viewport <= 480
       cresce fino a riempire la larghezza disponibile, mono-colonna
       automatica senza percentuali esplicite. */

    .book-card .book-cover {
        height: 350px;
    }

    .book-card .book-links {
        flex-direction: column;
    }

    .book-card .book-link {
        text-align: center;
    }

    .single-book {
        padding: 10px 5px;
    }

    .single-book .single-book-cover {
        width: var(--book-cover-mobile-width, 250px);
    }

    .book-main-title {
        font-size: 1.8em !important;
    }

    .book-description,
    .book-links-section,
    .book-youtube-section,
    .book-seo-section {
        padding: 25px !important;
    }

    .book-opening {
        font-size: 1.1em !important;
        padding-left: 15px !important;
    }

    .single-book .book-links {
        flex-direction: column;
    }

    .single-book .book-link {
        text-align: center;
        width: auto;
    }
}



/* ============================================
   PAID MEMBERSHIPS PRO - CUSTOM STYLING
   ============================================ */

.page-template-page-restricted-area h2.mkdf-page-title.entry-title,
.page-template-page-login-register h2.mkdf-page-title.entry-title,
.page-template-page-custom-blog h2.mkdf-page-title.entry-title {
    text-align: center;
}

/* Account Page - Il tuo spazio */
.pmpro_account {
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 20px;
}

.pmpro_account h2,
.pmpro_account h3 {
    color: #2e0089;
    font-weight: 700;
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 1.8em;
}

/* Account Sections */
.pmpro_account-membership,
.pmpro_account-profile,
.pmpro_account-invoices {
    background: white;
    padding: 40px;
    margin-bottom: 40px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border-radius: 0;
    border-left: 4px solid #2e0089;
}

/* Membership Box - Welcome Section */
.pmpro_account-membership .pmpro_box {
    background: rgba(46, 0, 137, 0.05);
    padding: 30px;
    border-radius: 0;
    border: none;
    border-left: 4px solid #2e0089;
}

.pmpro_account-membership .pmpro_box h3 {
    margin-top: 0;
    color: #2e0089;
}

/* Profile Edit Links */
.pmpro_account-profile .pmpro_actionlinks {
    margin-top: 20px;
}

.pmpro_account-profile .pmpro_actionlinks a {
    display: inline-block;
    padding: 12px 28px;
    background: #2e0089;
    color: white !important;
    text-decoration: none;
    border-radius: 0;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
    font-size: 13px;
    transition: all 0.3s ease;
}

.pmpro_account-profile .pmpro_actionlinks a:hover {
    background: rgb(30, 0, 90);
    transform: translateX(5px);
}

/* Levels Page - Livelli */
.pmpro_levels-container {
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 20px;
}

.pmpro_level {
    background: white;
    padding: 40px;
    margin-bottom: 30px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border-radius: 0;
    border-left: 4px solid #2e0089;
    transition: all 0.3s ease;
}

.pmpro_level:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(46, 0, 137, 0.15);
}

.pmpro_level h2 {
    color: #2e0089;
    font-weight: 700;
    margin-bottom: 20px;
    font-size: 2em;
}

.pmpro_level .pmpro_level-price {
    font-size: 1em;
    color: #2e0089;
    font-weight: 700;
    margin: 20px 0;
}

/* Buttons */
.pmpro_btn,
.pmpro .pmpro_btn,
.pmpro_btn-select,
.pmpro_section #loginform .login-submit .button,
input[type="submit"].pmpro_btn {
    background-color: transparent !important;
    color: black !important;
    padding: 14px 30px !important;
    border: 1px solid black !important;
    border-radius: 0 !important;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pmpro_btn:hover,
.pmpro .pmpro_btn:hover,
.pmpro_btn-select:hover,
.pmpro_section #loginform .login-submit .button:hover,
input[type="submit"].pmpro_btn:hover {
    background: rgb(30, 0, 90) !important;
    transform: translateY(-2px);
    color: white !important;
}

#respond input[type=text], #respond textarea, .mkdf-style-form textarea, .post-password-form input[type=password], .wpcf7-form-control.wpcf7-date, .wpcf7-form-control.wpcf7-number, .wpcf7-form-control.wpcf7-quiz, .wpcf7-form-control.wpcf7-select, .wpcf7-form-control.wpcf7-text, .wpcf7-form-control.wpcf7-textarea, input[type=email], input[type=password], input[type=text] {
    text-transform: none;
}

/* Cancel Button */
.pmpro_btn-cancel,
a.pmpro_btn-cancel {
    background: #dc3545 !important;
    color: white !important;
}

.pmpro_btn-cancel:hover {
    background: #c82333 !important;
}

/* Invoice Table - Storico */
.pmpro_invoice {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.pmpro_invoice thead {
    background: rgba(46, 0, 137, 0.1);
}

.pmpro_invoice th {
    padding: 15px;
    text-align: left;
    color: #2e0089;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 0.5px;
}

.pmpro_invoice td {
    padding: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.pmpro_invoice tbody tr:hover {
    background: rgba(46, 0, 137, 0.03);
}

/* Forms - Checkout */
.pmpro_form {
    max-width: 800px;
    margin: 0 auto;
}

.pmpro_form label {
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    display: block;
}

.pmpro_form input[type="text"],
.pmpro_form input[type="email"],
.pmpro_form input[type="password"],
.pmpro_form select,
.pmpro_form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 0;
    font-size: 15px;
    margin-bottom: 20px;
    transition: border-color 0.3s ease;
}

.pmpro_form input:focus,
.pmpro_form select:focus,
.pmpro_form textarea:focus {
    border-color: #2e0089;
    outline: none;
    box-shadow: 0 0 0 1px rgba(46, 0, 137, 0.1);
}

/* Messages */
.pmpro_message,
.pmpro_success,
.pmpro_error {
    padding: 20px;
    margin-bottom: 30px;
    border-radius: 0;
    border-left: 4px solid;
}

.pmpro_success {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

.pmpro_error {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

/* Responsive */
@media (max-width: 768px) {
    .pmpro_account-membership,
    .pmpro_account-profile,
    .pmpro_account-invoices,
    .pmpro_level {
        padding: 25px !important;
    }

    .pmpro_invoice {
        font-size: 14px;
    }

    .pmpro_invoice th,
    .pmpro_invoice td {
        padding: 10px;
    }
}

/* Area Riservata Container */
.area-riservata-container {
    max-width: 1400px;
    margin: 60px auto;
    padding: 0 20px;
}

.area-riservata-header {
    text-align: center;
    margin-bottom: 50px;
}

.area-riservata-header h1 {
    font-size: 3em;
    color: #2e0089;
    margin-bottom: 15px;
}

/* Tabs Navigation */
.area-riservata-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 40px;
    border-bottom: 2px solid #e0e0e0;
    flex-wrap: wrap;
}

.tab-button {
    padding: 15px 30px;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: #666;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tab-button:hover {
    color: #2e0089;
}

.tab-button.active {
    color: #2e0089;
    border-bottom-color: #2e0089;
}

/* Tab Content */
.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive Tabs */
@media (max-width: 768px) {
    .area-riservata-tabs {
        flex-direction: column;
        border-bottom: none;
    }

    .tab-button {
        border-bottom: 1px solid #e0e0e0;
        border-left: 3px solid transparent;
        text-align: left;
    }

    .tab-button.active {
        border-left-color: #2e0089;
        border-bottom-color: #e0e0e0;
    }
}

/* ========================================
   Breadcrumbs - SEO Optimized
   ======================================== */
.mkdf-container .mkdf-container-inner.clearfix:nth-child(3) {
    padding-top: 15px !important;
}
.allisonlister-breadcrumbs {
    margin: 20px 0 30px;
    padding: 15px 0;
    font-size: 14px;
    color: #666;
}
nav.mkdf-container-inner.clearfix.allisonlister-breadcrumbs {
    padding-top: 30px !important;
    padding-bottom: 10px !important;
}
.breadcrumb-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 5px;
}

.breadcrumb-list li {
    display: inline-flex;
    align-items: center;
}

.breadcrumb-list li.separator {
    color: #999;
    margin: 0 5px;
}

.breadcrumb-list a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-list a:hover {
    color: #2e0089;
}

.breadcrumb-list li.current span {
    color: #2e0089;
    font-weight: 500;
}

span.current-level-badge {
    background: rgba(46, 0, 137, 0.2);
    font-size: 0.6em;
    padding: 5px 10px;
    border-radius: 20px;
}

.level-current-message {
    color: green;
    font-weight: bold;
}

/* Responsive Breadcrumbs */
@media only screen and (max-width: 768px) {
    .allisonlister-breadcrumbs {
        font-size: 13px;
        margin: 15px 0 20px;
    }

    .breadcrumb-list {
        gap: 3px;
    }

    .breadcrumb-list li.separator {
        margin: 0 3px;
    }
}

/* ========================================
   MAILPOET
   ======================================== */
.mailpoet_form.mailpoet_form_successfully_send .mailpoet_validate_success {
    position: relative;
    top: 30px;
    text-align: left;
    left: 49%;
}
.mailpoet_page-template-default .mkdf-post-info-top {
    display: none !important;
}

/* ========================================
   Custom Blog Content
   ======================================== */
.custom-blog-content .page-custom-header {
    border-bottom: 1px solid #e0e0e0;
}

/* ========================================
   FOOTER
   ======================================== */
h5#newslettertitlefooter {
    padding-top: 0;
    margin-top: 0;
    margin-bottom: 18px;
}
.parsley-required {
    margin-top: 10px !important;
    font-weight: bold;
    text-transform: unset !important;
}
.buttonnewsletterfooter .mailpoet_submit:hover {
    background-color: #313131 !important;
    cursor: pointer;
}
@media screen and (max-width: 499px) {
    h5#newslettertitlefooter {
        font-size:25px !important;
        font-weight: 100;
    }
}

.mkdf-main-menu span.item_outer {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

/* First-screen purchase details: owned by the child theme. */
.book-purchase { margin: 0 0 30px; padding: 18px 0; border-top: 1px solid #e0e0e0; border-bottom: 1px solid #e0e0e0; }
.book-purchase-genre { margin: 0 0 8px; color: #555; }
.book-purchase-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; }
.book-purchase-amount { font-size: 28px; line-height: 1.3; font-weight: 700; color: #1a1a1a; white-space: nowrap; }
.book-purchase-meta, .book-purchase-publisher { font-size: 14px; color: #555; }
.book-purchase-publisher { margin: 6px 0 0; }
.single-book .book-purchase .book-links--primary { margin-top: 14px; }
.single-book .book-purchase .book-links--secondary { margin-top: 10px; gap: 8px; }
.single-book .book-purchase .book-link { text-transform: none; letter-spacing: 0; }
.single-book .book-purchase .book-link--primary { background: #2e0089; color: #fff !important; font-size: 16px; padding: 14px 24px; }
.single-book .book-purchase .book-link--primary:hover { background: #1e005a; transform: none; box-shadow: none; }
.single-book .book-purchase .book-link--secondary { background: transparent; color: #2e0089 !important; border: 1px solid #d5cde5; padding: 8px 12px; font-size: 13px; }
.single-book .book-purchase .book-link--secondary:hover { background: #f3effa; transform: none; box-shadow: none; }
.book-cover-link, .single-book-cover picture { display: block; }
.book-cover-link:focus-visible, .book-purchase .book-link:focus-visible { outline: 3px solid #2e0089; outline-offset: 4px; }
@media (max-width: 768px) {
    .single-book.single-book--purchasable .single-book-wrapper { margin: 12px auto; padding: 10px; gap: 18px; }
    .single-book.single-book--purchasable .single-book-content { width: 100%; }
    .single-book--purchasable .book-main-title { margin-bottom: 12px !important; }
    .book-purchase { padding: 12px 0; margin-bottom: 22px; }
    .single-book .book-purchase .book-links--secondary { flex-direction: row; }
}

/* ============================================
   COOKIE BANNER COMPLIANZ — override mobile
   ============================================
   Scritto contro Complianz GDPR 7.5.6
   (wp-content/plugins/complianz-gdpr/cookiebanner/css/cookiebanner.css).

   PROBLEMA: il banner di default e' position:fixed centered (top:50% +
   translate -50%,-50%) con max-height calc(100vh - 20px). Su mobile copre
   il centro del viewport, dove ora cade la CTA d'acquisto nelle schede
   libro (y ≈ 400 su 375×667). Un lettore che arriva da Google vede il
   banner, non il bottone.

   SOLUZIONE: su mobile il banner si ancora in basso, full-width. Il centro
   del viewport resta libero → CTA visibile sopra la fold mentre il consent
   e' ancora accessibile. Pattern comune (Google, Amazon, iAbrek).

   PRESIDI GDPR DELIBERATAMENTE PRESERVATI:
   - Non tocchiamo .cmplz-body (resta max-height:55vh): le opzioni di
     consenso restano leggibili senza compressione.
   - Non tocchiamo .cmplz-buttons: parita' visiva Accetta/Rifiuta/Prefer.
     invariata.
   - Max-height 90vh: lascia 10vh in alto per vedere la pagina sotto il
     banner; evita che un body molto lungo spinga i buttons fuori banner
     (il body ha overflow:auto interno, scrolla senza coprire i buttons).

   DA RICONTROLLARE DOPO OGNI UPDATE DI COMPLIANZ:
   1. La classe .cmplz-cookiebanner esiste ancora al top-level del banner?
   2. L'ordine DOM e' ancora: header, body, divider, links, buttons? Se
      riordinato con buttons sopra il body (improbabile ma possibile), la
      logica cambia e questo blocco va rifatto.
   3. .cmplz-body ha ancora overflow:auto + max-height propria? Senza
      overflow interno, body lungo spinge buttons fuori banner.
   Vedi: wp-content/plugins/complianz-gdpr/cookiebanner/css/cookiebanner.css
*/
@media (max-width: 768px) {
    .cmplz-cookiebanner {
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        transform: none !important;
        width: 100% !important;
        max-width: 100% !important;
        max-height: 90vh !important;
        border-radius: 12px 12px 0 0 !important;
    }
}

/* Event single — header a tre colonne (data | titolo+luogo | tickets).
   Parent chapterone-core: flex row con flex-grow 1/3/3/3 → data stretta,
   titolo e venue (location) a stesso peso tipografico, risultato "copia
   incolla" quando il venue coincide col titolo. Qui:
   - impila titolo e venue in colonna 2 su due righe;
   - venue diventa riga di contesto (più piccolo, meno marcato);
   - data e tickets occupano colonne laterali con allineamento verticale;
   - sotto 1024px lascia impilare come fa già il parent (display:block). */
body.single-event .mkdf-event-single-holder .mkdf-event-header-content-holder {
    display: grid;
    grid-template-columns: minmax(140px, max-content) 1fr auto;
    grid-template-rows: auto auto;
    column-gap: 32px;
    row-gap: 2px;
    align-items: start;
}
body.single-event .mkdf-event-single-holder .mkdf-event-header-date-holder {
    grid-column: 1;
    grid-row: 1 / span 2;
    align-self: center;
}
body.single-event .mkdf-event-single-holder .mkdf-event-header-title-holder {
    grid-column: 2;
    grid-row: 1;
}
body.single-event .mkdf-event-single-holder .mkdf-event-header-location-holder {
    grid-column: 2;
    grid-row: 2;
}
body.single-event .mkdf-event-single-holder .mkdf-event-buy-tickets-holder {
    grid-column: 3;
    grid-row: 1 / span 2;
    align-self: center;
    text-align: right;
}
body.single-event .mkdf-event-single-holder .mkdf-event-header-location-holder .mkdf-event-header-venue {
    font-size: 16px;
    line-height: 1.4;
    font-weight: 400;
    color: #6b6b6b;
}
@media (max-width: 1024px) {
    body.single-event .mkdf-event-single-holder .mkdf-event-header-content-holder {
        display: block;
    }
}

/* Events list shortcode (mkdf_events_list) — respira di piu' e titolo coerente.
   Parent chapterone-core:
   - .mkdf-event-title senza font-size → eredita H2 globale (35px) dal tema,
     che da quando le card hanno titolo H2 risulta sovradimensionato nella
     riga stretta della lista.
   - padding verticale 20/16px sui figli → righe appiccicate quando il titolo
     va a due righe.
   Qui riduco solo il titolo della list-row (non tocco il single, che e'
   gia' coerente col suo contesto a 25px) e amplio il padding su desktop.
   Mobile (<=1024) lascio il parent: li' il parent fa column + padding 5px. */
.mkdf-events-list-holder .mkdf-event-content .mkdf-event-title-holder .mkdf-event-title {
    font-size: 20px;
    line-height: 1.35;
    letter-spacing: 0;
}
@media (min-width: 1025px) {
    .mkdf-events-list-holder .mkdf-event-content > div {
        padding: 28px 0 24px;
    }
    .mkdf-events-list-holder .mkdf-event-content > div:last-child {
        padding: 28px 0;
    }
    /* Respiro orizzontale tra titolo e bottone biglietti (parent: 0). */
    .mkdf-events-list-holder .mkdf-event-content .mkdf-event-title-holder {
        padding-right: 32px;
    }
}
