/* Easy Stripe Payments and Donations Plugin v1.3.12 */
body, p {
    font-size: 15px !important;
}
h1.espad_headline .dashicons-money-alt {
    font-size: 34px; 
}
.error {
    color: red;
}
.blue {
    color: #0073aa;
}
.orange {
    color: #A25B00;
}
.green {
    color: #157b00;
}
.grey {
    color: #8A8A8A;
}
.espad-custom-tooltip,
.espad-custom-tooltip-xl {
    position: absolute;
    background-color: #333;
    color: #fff;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 13px;
    z-index: 9999999;
    pointer-events: none;
    white-space: pre-line;
}
.espad-custom-tooltip-xl {
    margin-top: -60px;   
}
.espad-info-box-icon img {
    width: 24px;
    cursor: pointer;
}
#wpfooter {
    position: relative !important;
}
/* Loading Animation */
#espad-loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}
/* Loader-Style */
.loader {
  width: 50px;
  aspect-ratio: 1;
  display: grid;
  border: 4px solid transparent;
  border-radius: 50%;
  border-right-color: #25b09b;
  animation: l15 1s infinite linear;
}
/* Additional rings */
.loader::before,
.loader::after {    
  content: "";
  grid-area: 1/1;
  margin: 2px;
  border: 4px solid transparent;
  border-radius: 50%;
  border-right-color: #25b09b;
  animation: l15 2s infinite;
}
.loader::after {
  margin: 8px;
  animation-duration: 3s;
}
/* Turn-Animation */
@keyframes l15 { 
  100% { transform: rotate(1turn); }
}
/* Main content, welcome page */
#content {
    display: none; 
}
/* END: Loading Animation */
/* Welcome Page */
.welcome_headline {
    position: relative;
    z-index: 999;
}
/* START: Welcome Page - Clean Stats Layout */
.espad-wrapper {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  overflow: hidden;
  margin: 30px 0;
  background: #ffffff;
}
.espad-column {
  display: contents; /* wichtig für gleichmaessige Linien */
}
.balance-box {
  padding: 26px 28px;
  background: #ffffff;
  position: relative;
  transition: background 0.2s ease;
}
/* Linien zwischen den Feldern */
.balance-box:nth-child(odd) {
  border-right: 1px solid #e5e7eb;
}
.balance-box {
  border-bottom: 1px solid #e5e7eb;
}
/* Hover sehr subtil */
.balance-box:hover {
  background: #f6f6f6;
}
.balance-title {
  font-size: 12px;
  font-weight: 600;
  color: #6b7280;
  margin-bottom: 10px;
  letter-spacing: 0.04em;
}
.balance-amount {
  font-size: 34px;
  font-weight: 600;
  color: #111827;
  letter-spacing: -0.02em;
}
/* Connect Button */
.espd-connect-button { 
    display: inline-block; 
    margin-top: 15px; 
    padding: 10px 16px; 
    background-color: #28a745; /* Bootstrap Green */ 
    color: #fff; 
    text-decoration: none; 
    border-radius: 4px; 
    transition: background-color 0.3s ease; 
} 
.espd-connect-button:hover { 
    background-color: #218838; 
    color: #fff; 
}
/* Mobile */
@media (max-width: 782px) {
  .espad-wrapper {
    grid-template-columns: 1fr;
  }

  .balance-box:nth-child(odd) {
    border-right: none;
  }
}
/* END: Welcome Page */
.espad_powered_by_box {
    text-align: center; 
    font-size: 13px !important;
}
/* Help Page */
.espd-faq-accordion {
    max-width: 100%;
    margin: 20px 0;
    font-family: sans-serif;
}
.espd-faq-item {
    border: 1px solid #ccc;
    border-radius: 8px;
    margin-bottom: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
}
.espd-faq-question {
    background-color: #f5f5f5;
    padding: 12px 16px;
    font-weight: bold;
    cursor: pointer;
    position: relative;
    padding-right: 40px;
}
/* Symbol: + or - */
.espd-faq-question::after {
    content: '+';
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 20px;
    color: #666;
    transition: transform 0.2s, content 0.2s;
}
/* If open - Change icon to minus */
.espd-faq-item.open .espd-faq-question::after {
    content: '–';
}
.espd-faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 16px;
    background-color: #fff;
    transition: max-height 0.3s ease, padding 0.3s ease;
}
/* Animate the open state */
.espd-faq-item.open .espd-faq-answer {
    max-height: 500px; /* Must be large enough for the longest answer */
    padding: 16px; 
}
/* END: Help Page */
#toplevel_page_espd_main .wp-submenu li a[href="admin.php?page=espd_main&tab=premium"] {
    background-color: #28a745 !important;
    color: #fff !important;
}
#toplevel_page_espd_main .wp-submenu li a[href="admin.php?page=espd_main&tab=premium"]:hover {
    background-color: #218838 !important;
}
.swal-button--confirm,
.swal2-confirm {
    background-color: #0073aa !important;    
}
.swal-button--confirm:hover,
.swal2-confirm:hover {
    background-color: #000 !important;    
}
.swal-button--cancel {
    width: 100%;
}
.swal-footer .swal-button-container:first-child {
    width: 165px;
}
img.espad_lightbox {
    width:100%; 
    max-width: 424px; 
    border-radius: 8px; 
    margin-bottom: 16px;
    margin-top: -16px;    
}
#espad_page textarea#message {
    border: 1px solid #e1e1e1;
    border-radius: 7px;
}
#espad_page input.form-control:focus,
#espad_page textarea#message:focus {
  outline: none;
  box-shadow: none;
  border-color: #ccc;
}
#espad_page select.form-select {
    border: 1px solid #e1e1e1;
    border-radius: 7px;
    margin-top: 10px;
    margin-bottom: 15px;
    width: 236px;
    text-align: center;
}
#espad_page .btn-check:checked + .btn, 
#espad_page :not(.btn-check) + .btn:active, 
#espad_page .btn:first-child:active, 
#espad_page .btn.active, 
#espad_page .btn.show,
#espad_page #prices_box label.btn:hover {
    background-color: #0d8889 !important;
    color: #fff !important;
}
#espad_page .btn-outline-primary {
    color: #0d8889 !important;
}
#espad_page h2 {
    margin-top: -15px !important;
}
.espad-tab {
    background: #fff; 
    padding: 20px; 
    border: 1px solid #ccd0d4; 
    border-top: none;
}
#espad_page form#payment-form {
    margin: auto;
}
#espad_page form#payment-form.tablet {
    width: 768px !important;
}
#espad_page form#payment-form.mobile {
    width: 400px !important;
}
#espad_page .size-changer {
    margin: auto;
}
.wp-premium-button {
    display: inline-block;
    padding: 12px 24px;
    background-color: #0073aa;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s ease;    
}
.wp-premium-button:hover {
    background-color: #000;
    color: #fff;
}
/* #espd-form-modal Form */
#color {
    cursor: pointer;
    width: 100%;
}
#espd-form-modal .form-container,
#espd-form-campaign-modal .form-container,
#espd-form-recurring-modal .form-container,
#espd-form-subscription-modal .form-container,
#espd-form-advanced-modal .form-container {
    width: 100%;
    max-width: 1000px; /* Width max. 1000px */
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
#espd-form-modal form,
#espd-form-campaign-modal form,
#espd-form-recurring-modal form,
#espd-form-subscription-modal form,
#espd-form-advanced-modal form {
    display: block;
}
#espd-form-modal #espd-admin-notice-wrapper,
#espd-form-campaign-modal #espd-admin-campaign-notice-wrapper,
#espd-form-recurring-modal #espd-admin-notice-wrapper,
#espd-form-subscription-modal #espd-admin-subscription-notice-wrapper,
#espd-form-advanced-modal #espd-admin-advanced-notice-wrapper {
    margin-bottom: 15px;
    width: 98%;
}
#espd-form-modal .form-row,
#espd-form-campaign-modal .form-row,
#espd-form-recurring-modal .form-row,
#espd-form-subscription-modal .form-row,
#espd-form-advanced-modal .form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}
#espd-form-modal .form-group,
#espd-form-campaign-modal .form-group,
#espd-form-recurring-modal .form-group,
#espd-form-subscription-modal .form-group,
#espd-form-advanced-modal .form-group {
    flex: 1;  /* Assigns the same width to each input field. */
    display: flex;
    flex-direction: column;
}
#espd-form-modal .form-group.full-width,
#espd-form-campaign-modal .form-group.full-width,
#espd-form-recurring-modal .form-group.full-width,
#espd-form-subscription-modal .form-group.full-width,
#espd-form-advanced-modal .form-group.full-width {
    flex: 1 0 100%;  /* Makes the field span the full width. */
}
#espd-form-modal label,
#espd-form-campaign-modal label,
#espd-form-recurring-modal label,
#espd-form-subscription-modal label,
#espd-form-advanced-modal label {
    margin-bottom: 8px;
    font-weight: bold;
    font-size: 14px;
}
#espd-form-modal .input,
#espd-form-campaign-modal .input,
#espd-form-recurring-modal .input,
#espd-form-subscription-modal .input,
#espd-form-advanced-modal .input {
    padding: 8px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 4px; 
}
#espd-form-modal input[type="number"],
#espd-form-modal input[type="text"],
#espd-form-modal input[type="url"],
#espd-form-campaign-modal textarea,
#espd-form-campaign-modal input[type="number"],
#espd-form-campaign-modal input[type="text"],
#espd-form-campaign-modal input[type="url"],
#espd-form-recurring-modal input[type="number"],
#espd-form-recurring-modal input[type="text"],
#espd-form-recurring-modal input[type="url"],
#espd-form-subscription-modal textarea,
#espd-form-subscription-modal input[type="number"],
#espd-form-subscription-modal input[type="text"],
#espd-form-subscription-modal input[type="url"],
#espd-form-advanced-modal textarea,
#espd-form-advanced-modal input[type="number"],
#espd-form-advanced-modal input[type="text"],
#espd-form-advanced-modal input[type="url"] {
    width: 100%;
    padding: 8px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
}
#espd-form-modal input[type="number"]:focus,
#espd-form-modal input[type="text"]:focus,
#espd-form-modal input[type="url"]:focus,
#espd-form-campaign-modal input[type="number"]:focus,
#espd-form-campaign-modal input[type="text"]:focus,
#espd-form-campaign-modal input[type="url"]:focus,
#espd-form-recurring-modal input[type="number"]:focus,
#espd-form-recurring-modal input[type="text"]:focus,
#espd-form-recurring-modal input[type="url"]:focus,
#espd-form-subscription-modal input[type="number"]:focus,
#espd-form-subscription-modal input[type="text"]:focus,
#espd-form-subscription-modal input[type="url"]:focus,
#espd-form-advanced-modal input[type="number"]:focus,
#espd-form-advanced-modal input[type="text"]:focus,
#espd-form-advanced-modal input[type="url"]:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 8px rgba(0, 123, 255, 0.25);
}
#espd-form-modal button:hover, 
#espd-form-campaign-modal button:hover,
#espd-form-recurring-modal button:hover,
#espd-form-sub-modal button:hover {
    background-color: #0056b3;
}
#espd-form-modal select.form-control,
#espd-form-campaign-modal select.form-control,
#espd-form-recurring-modal select.form-control,
#espd-form-subscription-modal select.form-control,
#espd-form-advanced-modal select.form-control {
    width: 100%;
    max-width: 100%;
    padding: 8px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
    height: auto; 
}
#espd-form-modal select.form-control:focus,
#espd-form-campaign-modal select.form-control:focus,
#espd-form-recurring-modal select.form-control:focus,
#espd-form-subscription-modal select.form-control:focus,
#espd-form-advanced-modal select.form-control:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 8px rgba(0, 123, 255, 0.25);
}
/* Advanced Checkout Form Modal */
#espd-new-advanced-form .headline {
    font-size: 18px;
    margin-top: 0px;
    margin-bottom: 5px;
}
#espd-new-advanced-form .advanced-section {
  background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px 22px;
  margin-bottom: 24px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}
#espd-new-advanced-form .advanced-section:hover {
  border-color: #d1d5db;
}
#espd-new-advanced-form .advanced-section .headline {
  font-size: 14px;
  font-weight: 500;
  color: #6b7280;
  margin-bottom: 4px;
  letter-spacing: 0.02em;
}
/* espad-table */
table#espad-table tbody tr:hover,
table#espad-table-stripe-payments tbody tr:hover {
    background-color: #2271b1;
    transition: all 0.3s ease; 
}
table#espad-table tbody tr:hover td,
table#espad-table-stripe-payments tbody tr:hover td {
    color: #fff !important; 
} 
#espad-table-stripe-payments_wrapper {
    overflow-x: auto;
}
/* Payments Page */
.table_stripe_payments_box {
    position: relative;
}
.table_stripe_payments_box .export-button-container {
    position: absolute;
    top: -55px;
    right: 1px;
}
.table_stripe_payments_box select[name="espad-table-stripe-payments_length"] {
    width: 50px;
}
.table_stripe_payments_box .contact-wrapper {
  max-height: 20px;  
  overflow: hidden;
  transition: max-height 1.3s ease;
  line-height: 1.4em;
}
.table_stripe_payments_box .contact-row:hover .contact-wrapper {
  max-height: 200px; 
}
/* END: Payments Page */
/* Recurring Page, Email Page */
.new_stripe_product_box,
.email_configure_box {
    width: 100%;
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);    
}
.new_stripe_product_box {
    max-width: 500px; 
}
.new_stripe_product_box #currency,
.new_stripe_product_box #form_language {
    width: 350px;
}
.new_stripe_product_box .product_image_input {
    width: 345px;
}
.recurring_form_modal_box .product_image_button {
    width: 130px;
}
form#espd-update-recurring-product .subscription_btn {
    margin-bottom: 20px;
    transition: all 0.2s ease;
    background-color: #0d8889;
    border: none;
}
form#espd-update-recurring-product .btn-small {
  font-size: 0.8rem;
  padding: 0.4em 0.8em;
}
form#espd-update-recurring-product .btn-medium {
  font-size: 1rem;
  padding: 0.6em 1.2em;
}
form#espd-update-recurring-product .btn-large {
  font-size: 1.2rem;
  padding: 0.8em 1.6em;
}
form#espd-update-recurring-product .btn-x-large {
  font-size: 1.4rem;
  padding: 1em 2em;
}
form#espd-update-recurring-product .btn-xx-large {
  font-size: 1.8rem;
  padding: 1.2em 2.4em;
}
#button_color,
#button_font_color {
    cursor: pointer;
}
table#espad-table .subscription_btn_preview {
    background-color: #0d8889;
    border: none;
}
.email_configure_box {
    max-width: 600px; 
}
.email_configure_box .switch {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 24px;
}
.email_configure_box .switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.email_configure_box .slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0;
  right: 0; bottom: 0;
  background-color: #ccc;
  transition: 0.4s;
  border-radius: 24px;
}
.email_configure_box .slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}
.email_configure_box input:checked + .slider {
  background-color: #2271b1; /* WP-blue */
}
.email_configure_box input:checked + .slider:before {
  transform: translateX(22px);
}
.email_configure_box .slider.round {
  border-radius: 24px;
}
.email_configure_box .slider.round:before {
  border-radius: 50%;
}
/* Forms */
.espad_img_box {
    display: flex; 
    gap: 8px;
}
/* Settings */
.custom-stripe-btn {
    background-color: #635bff; /* The typical Stripe purple */
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    transition: background-color 0.2s ease, transform 0.1s ease;
    box-shadow: 0 4px 6px rgba(50, 50, 93, 0.11), 0 1px 3px rgba(0, 0, 0, 0.08);
}

.custom-stripe-btn:hover {
    background-color: #7a73ff;
    transform: translateY(-1px);
    color: #fff;
}	

.custom-stripe-btn-test {
    background-color: #313538 !important;
    margin-left: 10px;
}

.custom-stripe-btn-test:hover {
    background-color: #53595e !important;
}

/* ---------------------------------
   ESPAD Admin Tabs (refined)
--------------------------------- */
.espad-admin-tabs .nav-tab-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 20px;
    padding: 0;
    border: none;
    background: transparent;
}

/* Default tab */
.espad-admin-tabs .nav-tab {
    margin: 0;
    padding: 10px 16px;
    border: 1px solid #dcdcde;
    border-bottom: none;
    border-radius: 10px 10px 0 0; /* Rounded only at the top */
    background: #f1f1f1;
    color: #50575e;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    line-height: 1.2;
    transition: all 0.2s ease;
}

/* Hover */
.espad-admin-tabs .nav-tab:hover {
    background: #ececec;
    color: #2271b1;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
} 
 
/* Active tab */
.espad-admin-tabs .nav-tab.nav-tab-active {
    background: #ffffff;
    color: #2271b1;
    font-weight: 600;
    border-color: #dcdcde;
    position: relative;
    top: 1px; 
}

/* Focus */
.espad-admin-tabs .nav-tab:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(13, 136, 137, 0.2);
} 

/* Responsive */
@media (max-width: 782px) {
    .espad-admin-tabs .nav-tab {
        width: 100%;
        text-align: center;
    }
}

/* Preview Tab */
/* Wrapper (Position bottom right) */
.espad-preview-overlay {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 320px;
    background: #fff;
    border: 1px solid #ccd0d4;
    border-left: 4px solid #2271b1; /* WP blue */
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    z-index: 9999;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    animation: espadFadeIn 0.25s ease-out;
}

/* Title */
.espad-preview-overlay__title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f6f7f7;
    padding: 10px 14px;
    font-size: 15px;
    font-weight: 600;
    border-bottom: 1px solid #dcdcde;
    gap: 10px;
}

/* Toggle button */
.espad-toggle {
    all: unset !important; 
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
    cursor: pointer !important;
    color: #50575e;
}

.espad-toggle:hover,
.espad-toggle:focus {
    color: #2271b1;
    outline: none;
    box-shadow: none;
}

.espad-toggle .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    transition: transform 0.2s ease;
}

/* Rotate icon when collapsed */
.espad-preview-overlay.is-collapsed .espad-toggle .dashicons {
    transform: rotate(-90deg);
}

/* Content */
.espad-preview-overlay__content {
    padding: 14px;
    font-size: 13px;
    color: #1d2327;
}

/* Hide content when collapsed */
.espad-preview-overlay.is-collapsed .espad-preview-overlay__content {
    display: none;
}

/* Remove separator line when collapsed */
.espad-preview-overlay.is-collapsed .espad-preview-overlay__title {
    border-bottom: 0;
}

/* Text */
.espad-preview-overlay__content p {
    margin: 0 0 10px;
}

/* Shortcode box */
.espad-preview-overlay code {
    display: block;
    padding: 10px;
    background: #f6f7f7;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    font-size: 14px !important;
    line-height: 1.4;
    word-break: break-all;
    cursor: pointer;
    user-select: all;
}

/* Hover effect */
.espad-preview-overlay code:hover {
    background: #eef1f2;
}

/* Fade-in animation */
@keyframes espadFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Copy feedback */
.espad-copy-feedback {
    display: none;
    margin-top: 8px;
    font-size: 12px;
    color: #46b450;
}

.espad-copy-feedback.is-visible {
    display: block;
}

/* Advanced Checkout Button */
#espd-create-advanced-form,
.espd-create-advanced-form {
    background-color: #494949 !important;
    border: 1px solid #494949 !important;
}
#espd-create-advanced-form:hover,
.espd-create-advanced-form:hover {
    background-color: #000 !important;
}
.espad-recommended {
    position: relative;
} 
 
.espad-badge {
    position: absolute;
    top: -8px;
    right: -5px;
    background: #46b450;
    color: #fff;
    font-size: 9px;
    padding: 1px 5px;
    border-radius: 10px; /* pill shape */
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
}
#espd-new-advanced-form #stripe_product_price_id_sup {
    font-style: normal;
    font-size: 12px;
    color: grey;
}
