/* ==========================================
   CIRCLE CALCULATOR
   Page-specific styling
========================================== */


/* ==========================================
   CIRCLE CALCULATOR CARD
========================================== */

.circle-calculator-card {
    max-width: 650px;
}


/* ==========================================
   CIRCLE INSTRUCTION
========================================== */

.circle-instruction {
    margin: 8px 0 22px;

    color: #555555;

    font-size: 14px;
    line-height: 1.6;

    text-align: center;
}


/* ==========================================
   CIRCLE INPUT GROUP
========================================== */

.circle-input-group {
    margin-bottom: 20px;
}

.circle-input-group label {
    display: block;

    margin-bottom: 8px;

    color: #123f68;

    font-size: 15px;
    font-weight: 600;
}

.circle-input-group input {
    width: 100%;
    height: 44px;

    padding: 0 13px;

    border: 1px solid #b8c4d1;
    border-radius: 6px;

    background: #ffffff;

    color: #1f2937;

    font-family: "Poppins", Arial, sans-serif;
    font-size: 15px;

    outline: none;

    box-sizing: border-box;
}

.circle-input-group input:focus {
    border-color: #2563eb;
}


/* ==========================================
   ACTION BUTTONS
========================================== */

.calculator-actions {
    display: flex;

    justify-content: center;
    align-items: center;

    gap: 12px;

    margin: 25px auto;

    max-width: 850px;
}

.calculator-actions button {
    padding: 11px 18px;

    border: 1px solid #cbd5e1;
    border-radius: 6px;

    background: #ffffff;

    color: #123f68;

    font-family: "Poppins", Arial, sans-serif;

    font-size: 14px;
    font-weight: 600;

    cursor: pointer;
}

.calculator-actions button:hover {
    background: #f4f7fb;
}


/* ==========================================
   CIRCLE RESULTS
========================================== */

.circle-results {
    margin-top: 25px;
}

.circle-result-box {
    display: flex;

    justify-content: space-between;
    align-items: center;

    padding: 14px 16px;

    margin-bottom: 10px;

    background: #f7f9fc;

    border: 1px solid #dbe3ec;
    border-radius: 7px;
}

.circle-result-box span {
    color: #123f68;

    font-size: 15px;
    font-weight: 600;
}

.circle-result-box strong {
    color: #0f3b66;

    font-size: 17px;
}


/* ==========================================
   INFORMATION SECTION
========================================== */

.calculator-info {
    margin-top: 40px;
}

.calculator-info h2 {
    margin: 30px 0 12px;

    color: #123f68;

    font-size: 24px;
    font-weight: 600;
}

.calculator-info p {
    line-height: 1.7;
}


/* ==========================================
   FORMULA
========================================== */

.formula-list {
    margin: 18px 0 25px;
}

.formula-item {
    margin-bottom: 10px;

    padding: 14px 18px;

    background: #f7f9fc;

    border: 1px solid #dbe3ec;
    border-radius: 7px;

    color: #123f68;

    line-height: 1.6;
}


/* ==========================================
   FAQ
========================================== */

.faq-section {
    margin-top: 45px;
}

.faq-item {
    padding: 15px 0;

    border-bottom: 1px solid #e1e7ef;
}

.faq-item h3 {
    margin: 0 0 7px;

    color: #123f68;

    font-size: 17px;
}

.faq-item p {
    margin: 0;

    line-height: 1.6;
}


/* ==========================================
   DISCLAIMER
========================================== */

.calculator-disclaimer {
    margin-top: 40px;

    padding: 25px 30px;

    background: #f7f9fc;

    border-radius: 8px;
}

.calculator-disclaimer h2 {
    margin-top: 0;

    color: #123f68;
}

.calculator-disclaimer p {
    line-height: 1.7;
}


/* ==========================================
   TOP AD
   NORMAL PAGE FLOW
========================================== */

/*
   The top advertisement is NOT fixed.

   It stays below the breadcrumb and scrolls
   away naturally with the page.

   This is the same working pattern used
   by the Break-Even Calculator.
*/

.top-ad {
    position: static;

    width: 100%;
    max-width: 970px;

    min-height: 90px;

    margin: 0 auto 35px;

    display: flex;

    align-items: center;
    justify-content: center;

    box-sizing: border-box;

    border: 1px dashed #cbd5e1;
    border-radius: 8px;

    background: #f8fafc;

    color: #94a3b8;

    font-size: 14px;
}


/* ==========================================
   RIGHT SIDEBAR ADS
   DESKTOP
========================================== */

.ad-sidebar {
    width: 300px;

    display: flex;

    flex-direction: column;

    gap: 24px;

    align-self: start;

    box-sizing: border-box;
}


/*
   Both sidebar advertisements are visible.

   They are NOT fixed to the viewport.
   They move naturally with the page.
*/

.ad-sidebar .ad-placeholder {
    width: 300px;

    min-height: 250px;

    position: static;

    display: flex;

    align-items: center;
    justify-content: center;

    box-sizing: border-box;

    opacity: 1;
    visibility: visible;
}


/* ==========================================
   BOTTOM STICKY AD
   DESKTOP + MOBILE
========================================== */

.bottom-sticky-ad {
    display: flex;

    position: fixed;

    left: 50%;
    bottom: 0;

    transform: translateX(-50%);

    width: min(970px, calc(100% - 40px));

    min-height: 90px;

    z-index: 9998;

    align-items: center;
    justify-content: center;

    box-sizing: border-box;

    border: 1px solid #d9e0e7;
    border-bottom: none;

    border-radius: 8px 8px 0 0;

    background: #eef1f5;

    color: #94a3b8;

    font-size: 14px;
}


/* ==========================================
   MOBILE
========================================== */

@media (max-width: 768px) {


    /* ======================================
       CALCULATOR CARD
    ====================================== */

    .circle-calculator-card {
        width: 100%;

        box-sizing: border-box;

        padding: 20px;
    }


    /* ======================================
       INPUTS
    ====================================== */

    .circle-input-group input {
        height: 44px;
    }


    /* ======================================
       ACTION BUTTONS
    ====================================== */

    .calculator-actions {
        flex-direction: column;

        width: 100%;
    }

    .calculator-actions button {
        width: 100%;
    }


    /* ======================================
       INFORMATION / FAQ / DISCLAIMER
    ====================================== */

    .calculator-info h2,
    .faq-section h2,
    .calculator-disclaimer h2 {
        font-size: 21px;
    }

    .calculator-disclaimer {
        padding: 20px;
    }


    /* ======================================
       TOP AD
       NORMAL PAGE FLOW
    ====================================== */

    .top-ad {
        position: static;

        width: 100%;

        min-height: 60px;
        height: 60px;

        margin: 0 auto 25px;

        border-radius: 0;
    }


    /* ======================================
       HIDE SIDEBAR ADS
    ====================================== */

    .ad-sidebar {
        display: none;
    }


    /* ======================================
       BOTTOM STICKY AD
    ====================================== */

    .bottom-sticky-ad {
        left: 0;
        right: 0;

        bottom: 0;

        transform: none;

        width: 100%;

        min-height: 60px;

        border-radius: 0;

        border-left: none;
        border-right: none;
        border-bottom: none;

        border-top: 1px solid #d9e0e7;

        z-index: 9999;
    }


    /* ======================================
       CIRCLE RESULTS
    ====================================== */

    .circle-result-box {
        flex-direction: column;

        align-items: flex-start;

        gap: 5px;
    }

}

/* =========================================
   RESULT ACTION BUTTONS
   ========================================= */

.result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.result-action-btn {
    padding: 10px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #ffffff;
    color: #0f3b68;
    font-size: 14px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
}

.result-action-btn:hover {
    background: #f1f5f9;
    border-color: #2563eb;
}

.result-action-btn:active {
    transform: translateY(1px);
}

@media (max-width: 480px) {

    .result-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .result-action-btn {
        width: 100%;
        padding: 10px 8px;
        font-size: 13px;
    }

}