/**
 * WP Secure Download Button - Unified Styles
 */

/* --- Stile del Pulsante Principale (sovrascritto da stili inline) --- */
.dadb-custom-button {
    padding: 12px 24px;
    border: none;
    cursor: pointer;
    font-weight: bold;
    display: inline-block;
    line-height: 1;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.dadb-custom-button:hover {
    opacity: 0.85;
}


/* --- Contenitore Modale --- */
.dadb-modal-container {
    background-color: #ffffff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    padding: 25px;
    max-width: 480px; /* Larghezza massima */
    box-sizing: border-box;
    border-radius: 8px;
}

/* --- Elementi della Modale --- */
.dadb-modal-container h2,
#TB_ajaxContent .dadb-modal-container h2 {
    margin-top: 0 !important;
    padding-left: 0 !important;
    margin-bottom: 15px !important;
    font-size: 22px !important;
    color: #1e1e1e !important;
    font-weight: 600 !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif !important;
}

.dadb-modal-container .dadb-modal-desc,
#TB_ajaxContent .dadb-modal-container .dadb-modal-desc {
    margin-bottom: 20px !important;
    font-size: 13px !important;
    line-height: 1.6 !important;
    color: #555 !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif !important;
}

#TB_ajaxContent .dadb-modal-container .dadb-modal-desc p {
	font-size: 13px !important;
    line-height: 1.5 !important;
    color: #555 !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif !important;
    margin-top: 13px !important;
    margin-bottom: 13px !important;
    padding: 0 !important;
}

#TB_ajaxContent .dadb-modal-container .dadb-modal-desc p strong {
    font-weight: 600 !important;
}

#TB_ajaxContent .dadb-modal-container .dadb-modal-desc ul,
#TB_ajaxContent .dadb-modal-container .dadb-modal-desc ol {
	padding-left: 20px;
}

#TB_ajaxContent .dadb-modal-container .dadb-modal-desc li {
	margin-bottom: 8px;
}

.dadb-modal-container .dadb-modal-desc p:last-child {
    margin-bottom: 0;
}

.dadb-modal-container #dadbEmail {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
    font-size: 14px;
}
.dadb-modal-container #dadbEmail:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
    outline: none;
}

input[type="email"].dadb-email-input {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
    font-size: 14px;
}
input[type="email"].dadb-email-input:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
    outline: none;
}

.dadb-backend-preview input[type="email"].dadb-email-input::placeholder {
    color: #888; /* A shade of gray for placeholder text */
    opacity: 1; /* Firefox default is lower opacity */
}


/* --- Sezione Privacy --- */
.dadb-privacy-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 25px;
    font-size: 12px;
    color: #666;
}

.dadb-privacy-wrapper input[type="checkbox"] {
    margin: 0;
}


/* --- Footer e Pulsanti della Modale --- */
.dadb-footer {
    text-align: right;
    border-top: 1px solid #eee;
    padding-top: 20px;
    margin-top: 20px;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.dadb-footer-btn {
    padding: 10px 20px;
    border-radius: 4px;
    border: 1px solid transparent;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    display: inline-block;
}

/* Pulsante di Invio (Primario) */
.dadb-btn-send {
    background-color: #0073aa; /* Blu WordPress */
    color: #fff;
}
.dadb-btn-send:hover {
    background-color: #005a87;
}

/* Pulsante Annulla (Secondario) */
.dadb-btn-cancel {
    background-color: #f0f0f1;
    color: #1e1e1e;
    border-color: #ddd;
}
.dadb-btn-cancel:hover {
    background-color: #e0e0e1;
}

/* --- Stili specifici per Thickbox --- */
#TB_window {
    background: transparent !important;
    box-shadow: none !important;
}

#TB_ajaxContent {
    width: 100% !important;
    height: auto !important;
    padding: 0 !important;
    box-sizing: border-box;
}

#TB_title, #TB_closeAjaxWindow {
    display: none !important;
}

@media (max-width: 540px) {
    #TB_window {
        width: 90% !important;
        left: 5% !important;
        margin-left: 0 !important;
    }

    #TB_ajaxContent {
        width: 100% !important;
    }

    .dadb-modal-container {
        max-width: 100% !important;
        border-radius: 0;
    }
}