/* Cleaned HubSpot ROI Modal Styles */
/* ✅ MODAL OVERLAY */
.hubspot-roi-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  overflow-y: auto;
  padding: 2rem;
}

/* ✅ HIDE MODAL */
.hubspot-roi-modal-hidden {
  display: none;
}

/* ✅ MODAL CONTENT */
.hubspot-roi-modal-content {
  background-color: #fff;
  border-radius: 0.75rem;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  padding: 2rem;
  width: 100%;
  max-width: 600px;
  position: relative;
  margin: 0 1rem;
}

/* ✅ MODAL TITLE */
.hubspot-roi-modal-title {
  border-bottom: 2px solid #f0f0f0;
  color: #1c305d;
  font-family: 'Poppins', sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  margin-top: 0;
  padding-bottom: 0.8rem;
  position: relative;
  text-align: center;
}

/* ✅ CLOSE BUTTON */
.modal-close-button {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.75rem;
  color: #6b7280;
  cursor: pointer;
  transition: color 0.3s ease;
}

.modal-close-button:hover {
  color: #111827;
}


/* ✅ Restrict form width inside modal */
.hubspot-roi-modal-content .hubspot-innovapptive-form {
  max-width: 420px;
  margin: 0 auto;
  width: 100%;
}

/* ✅ Ensure any input with class 'input' is full width inside form */
.hubspot-roi-modal-content .hubspot-innovapptive-form .input {
  width: 100%;
  text-align: left; /* optional, if you don't want centered text */
}


/* ✅ FORM INPUTS (Scoped) */
.hubspot-roi-modal-content .hs-input {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  border: 1px solid #ced4da;
  border-radius: 0.5rem;
  background-color: rgba(156, 156, 156, 0.1);
  margin-bottom: 1.5rem;
  box-sizing: border-box;
}

.hubspot-roi-modal-content .hs-input:focus {
  outline: none;
  border-color: #1c305d;
}

/* ✅ SUBMIT BUTTON CENTERED */
.hubspot-roi-modal-content .actions {
  display: flex;
  justify-content: center;
  margin-top: 1.5rem;
}

.hubspot-roi-modal-content .hs-button.primary.large {
  padding: 0.75rem 2rem;
  font-size: 1rem;
  background-color: #1c305d;
  color: #fff;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
  max-width: 200px;
  width: 100%;
}

.hubspot-roi-modal-content .hs-button.primary.large:hover {
  background-color: #15284a;
}

/* ✅ ERROR MESSAGES (Optional) */
.hubspot-roi-modal-content .hs-error-msgs {
  color: #dc2626;
  font-size: 0.875rem;
  margin-top: -0.5rem;
  margin-bottom: 0.75rem;
}

/* ✅ RESPONSIVE MODAL */
@media (max-width: 480px) {
  .hubspot-roi-modal-content {
    padding: 1.5rem;
  }

  .hubspot-roi-modal-title {
    font-size: 1.5rem;
  }

  .modal-close-button {
    font-size: 1.5rem;
  }
}



/* Self-contained styles - no external dependencies */
            .hubspot-innovapptive-roi-calculator * {
                box-sizing: border-box;
            }
            
            /* Container */
            .hubspot-roi-container {
                padding: 1rem;
                width: 100%;
              
              padding-bottom: 6.25vw !important;
    padding-top: 6.25vw !important;
    position: relative;
   
            }
            
            /* Header */
            .hubspot-roi-header {
                text-align: center;
                margin-bottom: 2rem;
            }
            
            .hubspot-roi-title-small {
                font-size: 1.125rem;
                font-weight: 600;
                color: #6b7280;
                text-transform: uppercase;
                letter-spacing: 0.05em;
                margin-bottom: 0.5rem;
                animation: hubspot-roi-fadeInDown 1.2s ease-out;
            }
            
            .hubspot-roi-title-main {
                font-size: 1.875rem;
                font-weight: 700;
                color: #1f2937;
                margin-bottom: 0.5rem;
            }
            
            .hubspot-roi-title-accent {
                font-size: 1.5rem;
                font-weight: 600;
                color: #6a3cff;
            }
            
            /* Calculator Card */
            .hubspot-roi-calculator-card {
                box-shadow: 0 10px 25px rgba(0,0,0,0.07);
                transition: all 0.3s ease;
                background-color: white;
                border-radius: 1rem;
                padding: 1.5rem 2rem;
                margin-bottom: 1.5rem;
            }
            
            .hubspot-roi-calculator-card:hover {
                box-shadow: 0 15px 35px rgba(0,0,0,0.1);
            }
            
            /* Grid Layout */
            .hubspot-roi-grid {
                display: grid;
                grid-template-columns: 1fr;
                gap: 2rem;
            }
            
            .hubspot-roi-inputs {
                display: flex;
                flex-direction: column;
                gap: 1.5rem;
            }
            
            .hubspot-roi-results {
                background-color: #f9fafb;
                border-radius: 0.75rem;
                padding: 1.5rem;
            }
            
            
            
            .hubspot-roi-label {
                display: block;
                font-size: 0.875rem;
                font-weight: 500;
                color: #374151;
                margin-bottom: 0.25rem;
            }
            
            .hubspot-roi-input {
                width: 100%;
                padding: 0.75rem 1rem;
                border-radius: 0.5rem;
                border: 1px solid #d1d5db;
                font-size: 1rem;
                transition: all 0.3s ease;
            }
            
            .hubspot-roi-input:focus {
                border-color: #6a3cff;
                box-shadow: 0 0 0 3px rgba(106, 60, 255, 0.15);
                outline: none;
            }
            
            .hubspot-roi-input-with-icon {
              font-size:20px;
                position: relative;
            }
            
            .hubspot-roi-input-with-icon input {
                padding-left: 2rem;
            }
            
            .hubspot-roi-input-with-icon::before {
                content: "$";
                position: absolute;
                left: 0.75rem;
                top: 50%;
                transform: translateY(-50%);
                color: #6b7280;
                font-weight: 500;
                z-index: 1;
            }
            
            .hubspot-roi-help-text {
                font-size: 0.75rem;
                color: #6b7280;
                margin-top: 0.25rem;
            }
            
            .hubspot-roi-section-title {
                font-size: 1.25rem;
                font-weight: 600;
                color: #1f2937;
                margin-bottom: 1rem;
            }
            
            /* Results Section */
            .hubspot-roi-total-container {
                margin-bottom: 1.5rem;
            }
            
            .hubspot-roi-total-amount {
                font-size: 2.25rem;
                font-weight: 700;
                color: #4338ca;
                animation: hubspot-roi-fadeIn 0.5s ease-out;
            }
            
            .hubspot-roi-total-label {
                font-size: 0.875rem;
                color: #6b7280;
            }
            
            .hubspot-roi-savings-list {
                display: flex;
                flex-direction: column;
                gap: 1.5rem;
            }
            
            .hubspot-roi-savings-item {
                padding: 1rem;
                background-color: white;
                border-radius: 0.5rem;
                box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
                transition: all 0.3s ease;
            }
            
            .hubspot-roi-savings-item:hover {
                transform: translateX(5px);
            }
            
            .hubspot-roi-savings-header {
                display: flex;
                justify-content: space-between;
                align-items: center;
                margin-bottom: 0.75rem;
            }
            
            .hubspot-roi-savings-title {
                display: flex;
                align-items: center;
                gap: 0.5rem;
            }
            
            .hubspot-roi-savings-title h3 {
              font-size:1.25rem;
                font-weight: 500;
                color: #1f2937;
                margin: 0;
            }
            
            .hubspot-roi-savings-amount {
                font-size: 1.25rem;
                font-weight: 600;
                color: #4338ca;
            }
            
            .hubspot-roi-impact-section {
                margin-top: 0.75rem;
            }
            
            .hubspot-roi-impact-header {
                display: flex;
                justify-content: space-between;
                font-size: 0.9rem;
                color: #6b7280;
                margin-bottom: 0.25rem;
            }
            
            .hubspot-roi-progress-bar {
                height: 6px;
                background: #e5e7eb;
                border-radius: 3px;
                overflow: hidden;
            }
            
            .hubspot-roi-progress-fill {
                height: 100%;
                background: #6a3cff;
                border-radius: 3px;
                transition: width 0.8s ease;
            }
            
            .hubspot-roi-impact-high {
                color: #ef4444;
                font-weight: 600;
            }
            
            .hubspot-roi-impact-medium {
                color: #f59e0b;
                font-weight: 600;
            }
            
            .hubspot-roi-impact-bar-high {
                background: #ef4444;
            }
            
            .hubspot-roi-impact-bar-medium {
                background: #f59e0b;
            }
            
            /* Button */
            .hubspot-roi-cta-button {
                width: 100%;
                background: linear-gradient(135deg, #6a3cff 0%, #5429e0 100%);
                color: white;
                font-weight: 500;
                padding: 0.75rem 1.5rem;
                border-radius: 0.5rem;
                border: none;
                cursor: pointer;
                display: flex;
                align-items: center;
                justify-content: center;
                gap: 0.5rem;
                transition: all 0.3s ease;
                box-shadow: 0 4px 12px rgba(106, 60, 255, 0.25);
                margin-top: 2rem;
            }
            
            .hubspot-roi-cta-button:hover {
                transform: translateY(-2px);
                box-shadow: 0 6px 15px rgba(106, 60, 255, 0.35);
            }
            
            /* Tooltip */
            .hubspot-roi-tooltip {
                position: relative;
                display: inline-block;
                cursor: pointer;
            }
            
            .hubspot-roi-tooltip-icon {
                width: 1.25rem;
                height: 1.25rem;
                color: #9ca3af;
            }
            
            .hubspot-roi-tooltiptext {
                visibility: hidden;
                width: 250px;
                background-color: #fff;
                color: #333;
                text-align: center;
                border-radius: 8px;
                padding: 16px;
                position: absolute;
                z-index: 1000;
                bottom: 125%;
                left: 50%;
                margin-left: -125px;
                opacity: 0;
                transition: opacity 0.3s, transform 0.3s;
                transform: translateY(10px);
                font-weight: normal;
                font-size: 0.875rem;
                box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
                border: 1px solid #f0f0f0;
            }
            
            .hubspot-roi-tooltiptext::after {
                content: "";
                position: absolute;
                top: 100%;
                left: 50%;
                margin-left: -10px;
                border-width: 10px;
                border-style: solid;
                border-color: #fff transparent transparent transparent;
                filter: drop-shadow(0 2px 1px rgba(0,0,0,0.1));
            }
            
            .hubspot-roi-tooltip:hover .hubspot-roi-tooltiptext {
                visibility: visible;
                opacity: 1;
                transform: translateY(0);
            }
            
            .hubspot-roi-tooltip-percentage {
                font-size: 2.5rem;
                font-weight: 700;
                color: #6a3cff;
                line-height: 1;
                margin-bottom: 8px;
            }
            
            .hubspot-roi-tooltip-divider {
                width: 40px;
                height: 3px;
                background: #6a3cff;
                margin: 8px auto;
                border-radius: 2px;
            }
            
            /* Modal */
            .hubspot-roi-modal-overlay {
                position: fixed;
                top: 0;
                left: 0;
                right: 0;
                bottom: 0;
                background-color: rgba(0, 0, 0, 0.5);
                display: flex;
                align-items: center;
                justify-content: center;
                z-index: 99999;
            }
            
            .hubspot-roi-modal-hidden {
                display: none;
            }
            
            .hubspot-roi-modal-content {
                background-color: white;
                border-radius: 0.75rem;
                padding: 1.5rem;
                max-width: 28rem;
                width: 100%;
                margin: 0 1rem;
            }
            
            .hubspot-roi-modal-title {
                font-size: 1.25rem;
                font-weight: 700;
                color: #1f2937;
                margin-bottom: 1rem;
            }
            
            .hubspot-roi-form-grid {
                display: flex;
                flex-direction: column;
                gap: 1rem;
            }
            
            .hubspot-roi-button-group {
                display: flex;
                flex-direction: column;
                gap: 0.5rem;
                margin-top: 0.5rem;
            }
            
            .hubspot-roi-button-secondary {
                width: 100%;
                background-color: #f3f4f6;
                color: #374151;
                font-weight: 500;
                padding: 0.5rem 1.5rem;
                border-radius: 0.5rem;
                border: none;
                cursor: pointer;
                transition: all 0.3s ease;
            }
            
            .hubspot-roi-button-secondary:hover {
                background-color: #e5e7eb;
            }
            
            .hubspot-roi-success-icon {
                width: 4rem;
                height: 4rem;
                background-color: #dcfce7;
                border-radius: 50%;
                display: flex;
                align-items: center;
                justify-content: center;
                margin: 0 auto 1rem;
            }
            
            .hubspot-roi-success-icon svg {
                width: 2rem;
                height: 2rem;
                color: #22c55e;
            }
            
            .hubspot-roi-disclaimer {
                margin-top: 1.5rem;
                text-align: center;
                font-size: 0.875rem;
                color: #6b7280;
            }
            
            /* Animations */
            @keyframes hubspot-roi-fadeIn {
                from { opacity: 0; transform: translateY(10px); }
                to { opacity: 1; transform: translateY(0); }
            }
            
            @keyframes hubspot-roi-fadeInDown {
                from { opacity: 0; transform: translateY(-20px); }
                to { opacity: 1; transform: translateY(0); }
            }
            
            .hubspot-roi-result-appear {
                animation: hubspot-roi-fadeIn 0.5s ease-out;
            }
            
            /* Responsive */
            @media (min-width: 768px) {
                .hubspot-roi-container {
                    padding: 2rem;
                }
                
                .hubspot-roi-title-main {
                    font-size: 2.25rem;
                }
                
                .hubspot-roi-title-accent {
                    font-size: 1.875rem;
                }
                
                .hubspot-roi-grid {
                    grid-template-columns: 1fr 1fr;
                }
            }


    /* Form Elements */
 .hubspot-roi-modal-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background-color: rgba(0, 0, 0, 0.5);
        display: flex;
        align-items: center;
        justify-content: center;
        z-index: 99999;
    }

    .hubspot-roi-modal-hidden {
        display: none;
    }

    .hubspot-roi-modal-content {
        background-color: white;
        border-radius: 0.75rem;
        padding: 1.5rem;
        max-width: 28rem;
        width: 100%;
        margin: 0 1rem;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    }

    .hubspot-roi-modal-title {
        font-size: 1.25rem;
        font-weight: 700;
        color: #1f2937;
        margin-bottom: 1rem;
    }

    .hubspot-roi-form-grid {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    .hubspot-roi-button-group {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        margin-top: 0.5rem;
    }

    .hubspot-roi-button-secondary {
        width: 100%;
        background-color: #f3f4f6;
        color: #374151;
        font-weight: 500;
        padding: 0.5rem 1.5rem;
        border-radius: 0.5rem;
        border: none;
        cursor: pointer;
        transition: all 0.3s ease;
    }

    .hubspot-roi-button-secondary:hover {
        background-color: #e5e7eb;
    }

    .hubspot-roi-cta-button {
        width: 100%;
        background: linear-gradient(135deg, #6a3cff 0%, #5429e0 100%);
        color: white;
        font-weight: 500;
        padding: 0.75rem 1.5rem;
        border-radius: 0.5rem;
        border: none;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        transition: all 0.3s ease;
        box-shadow: 0 4px 12px rgba(106, 60, 255, 0.25);
        margin-top: 2rem;
    }

    .hubspot-roi-cta-button:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 15px rgba(106, 60, 255, 0.35);
    }
    
/* End of Form Elements */

/* For screens with a width of 414px or smaller, set input container width to 80% */
@media (max-width: 414px) {
    .hubspot-roi-inputs {
        width: 80%;
     /*   margin: 0 auto; /* Center align the inputs */
    }
  .hubspot-roi-savings-item {
  margin-right:1.5rem !important;
  }
}

/* For screens between 415px to 768px (smaller tablets and large phones) */
@media (min-width: 415px) and (max-width: 768px) {
    .hubspot-roi-inputs {
        width: 85%; /* Adjust slightly larger for mid-size devices */
       /* margin: 0 auto; */
    }
}

/* For larger screens (tablets and desktops), keep width as 100% or per original design */
@media (min-width: 769px) {
    .hubspot-roi-inputs {
        width: 100%;
    }
}


/* ✅ Fix ROI results responsiveness */
@media (max-width: 767px) {
  .hubspot-roi-results {
    width: 100%;
    overflow-x: hidden;
  }

  .hubspot-roi-savings-item {
    margin-right: 0 !important;
    padding: 1rem;
    word-wrap: break-word;
  }

  .hubspot-roi-grid {
    grid-template-columns: 1fr !important;
  }
  
    .hubspot-roi-savings-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.5rem;
  }

  .hubspot-roi-savings-amount {
    font-size: 1.25rem;
  }
  
  
    .hubspot-roi-tooltiptext {
    width: 92vw;
    max-width: 92vw;
    left: 50% !important;
    transform: translateX(-50%) translateY(10px) !important;
    margin-left: 0 !important;
    white-space: normal !important;
    padding: 0.75rem 1rem !important;
    font-size: 0.75rem !important;
    word-wrap: break-word;
    text-align: left;
    box-sizing: border-box;
  }

  .hubspot-roi-tooltip-percentage {
    font-size: 1.5rem !important;
    font-weight: 700;
    margin-bottom: 0.5rem;
  }

  .hubspot-roi-tooltip-divider {
    display: none !important;
  }

  .hubspot-roi-tooltiptext div:nth-child(3) {
    font-weight: 600;
    margin-bottom: 0.25rem;
  }

  .hubspot-roi-tooltiptext div:nth-child(4) {
    display: block;
    font-size: 0.75rem;
    line-height: 1.2rem;
    word-break: break-word;
  }

  .hubspot-roi-tooltip-divider {
    display: none !important;
  }

}

