/* Interactive Calculators Module Styles */

.calculator-card-trigger {
    background: linear-gradient(135deg, #1a1a1a, #2c3e50);
    color: white;
    padding: 30px;
    border-radius: 16px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    min-height: 220px;
    position: relative;
    overflow: hidden;
}

.calculator-card-trigger::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://images.unsplash.com/photo-1554224155-8d04cb21cd6c?w=500&q=50') center/cover;
    opacity: 0.1;
    transition: opacity 0.3s;
}

.calculator-card-trigger:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.calculator-card-trigger:hover::before {
    opacity: 0.2;
}

.calc-icon {
    font-size: 3rem;
    margin-bottom: 15px;
    color: var(--primary-red);
    position: relative;
    z-index: 2;
}

.calc-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 10px;
    position: relative;
    z-index: 2;
}

.calc-desc {
    font-size: 0.9rem;
    opacity: 0.8;
    position: relative;
    z-index: 2;
}

/* Modal Styles for Calculator */
.calculator-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.calculator-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.calc-modal-content {
    background: white;
    width: 90%;
    max-width: 500px;
    border-radius: 20px;
    padding: 30px;
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s;
    max-height: 90vh;
    overflow-y: auto;
}

.calculator-modal.active .calc-modal-content {
    transform: translateY(0);
}

.calc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

.calc-header h2 {
    font-size: 1.5rem;
    color: var(--primary-dark);
    margin: 0;
}

.close-calc {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #999;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #444;
}

.calc-input {
    width: 100%;
    padding: 12px;
    border: 2px solid #eee;
    border-radius: 10px;
    font-size: 1.1rem;
    transition: border-color 0.3s;
}

.calc-input:focus {
    border-color: var(--primary-red);
    outline: none;
}

.calc-range-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-calc-action {
    width: 100%;
    padding: 16px;
    background: var(--primary-red);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.3s;
    margin-top: 10px;
}

.btn-calc-action:hover {
    background: #a93226;
}

/* Result Section */
.calc-result-box {
    margin-top: 30px;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    border: 1px solid #eee;
    text-align: center;
    display: none;
    /* Hidden by default */
}

.calc-result-box.show {
    display: block;
    animation: fadeIn 0.5s;
}

.result-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin: 10px 0;
}

.result-label {
    color: #666;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Lead Capture Overlay inside Calculator */
.result-gate-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 30px;
    text-align: center;
    z-index: 10;
    border-radius: 12px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}