/* ================================
   Print Result
================================ */

@media print {

    @page {
        size: auto;
        margin: 15mm;
    }

    body {
        margin: 0;
        padding: 0;
    }

    body * {
        visibility: hidden;
    }

    #resultsSection,
    #resultsSection * {
        visibility: visible;
    }

    #resultsSection {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        margin: 0;
        padding: 0;
        border: none;
        box-shadow: none;
    }

    .results-grid {
        page-break-inside: avoid;
        break-inside: avoid;
    }

    .calculator-summary {
        page-break-inside: avoid;
        break-inside: avoid;
    }

}

.print-header {
    text-align: center;
    border-bottom: 2px solid #ccc;
    padding-bottom: 15px;
    margin-bottom: 25px;
}

.print-header h1 {
    margin: 0;
    font-size: 28px;
    font-weight: bold;
}

.print-header p {
    margin: 6px 0 0;
    font-size: 16px;
}

.field-note {
    display: block;
    margin-top: 6px;
    margin-bottom: 0;
    font-size: 13px;
    line-height: 1.5;
    color: #666;
}

/* ==========================================
   Page Layout With Advertisement Sidebar
   ========================================== */

.page-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 32px;
    align-items: start;
}


.page-main-content {
    min-width: 0;
}


/* ==========================================
   Advertisement Sidebar
   ========================================== */

.ad-sidebar {
    display: flex;
    flex-direction: column;
    gap: 32px;
}


.ad-placeholder {
    min-height: 280px;

    border: 1px dashed #cbd5e1;
    border-radius: 8px;

    display: flex;
    align-items: center;
    justify-content: center;

    color: #94a3b8;
    font-size: 14px;

    background: #f8fafc;
}


/* ==========================================
   Tablet Layout
   ========================================== */

@media (max-width: 1100px) {

    .page-layout {
        grid-template-columns: 1fr;
    }

    .ad-sidebar {
        display: flex;
        flex-direction: row;
        gap: 24px;
        margin-top: 32px;
    }

    .ad-placeholder {
        flex: 1;
        min-height: 180px;
    }

}


/* ==========================================
   Mobile Layout
   ========================================== */

@media (max-width: 600px) {

    .ad-sidebar {
        flex-direction: column;
        gap: 20px;
        margin-top: 24px;
    }

    .ad-placeholder {
        width: 100%;
        min-height: 120px;
    }

}
/* ==========================================
   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) {

    .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;
    }

}

/* ==========================================
   HIDE SIDEBAR ADS ON MOBILE
========================================== */

@media (max-width: 768px) {

    .ad-sidebar {
        display: none !important;
    }

}