
/* =========================================
   SHRI GORAKSHANATH DEVSTHAN RECEIPT
   A4 SINGLE PAGE PRINT DESIGN
========================================= */

.receipt-container {
    width: 100%;
    margin: 0 auto;
}

.receipt {
    width: 100%;
    max-width: 850px;
    margin: 0 auto;
    background: #fffdf8;
    border: 5px double #b83b32;
    padding: 28px 34px;
    color: #9f3029;
    box-shadow: 0 8px 25px #4b261018;
    box-sizing: border-box;
}

.receipt * {
    box-sizing: border-box;
}

.receipt-head {
    display: grid;
    grid-template-columns: 75px 1fr 70px;
    align-items: center;
    gap: 12px;
    text-align: center;
}

.logo-box {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff8e7;
    padding: 3px;
}

.logo-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    display: block;
}

.receipt-title .mantra {
    font-size: 12px;
}

.receipt-title h2 {
    font-size: 25px;
    margin: 5px 0;
}

.receipt-title p {
    margin: 0;
    font-size: 13px;
}

.receipt-title strong {
    display: inline-block;
    background: #a52c25;
    color: white;
    padding: 5px 25px;
    margin-top: 10px;
    border-radius: 2px;
}

.seal {
    border: 2px solid #b83b32;
    border-radius: 50%;
    width: 66px;
    height: 66px;
    display: grid;
    place-items: center;
    font-size: 11px;
    transform: rotate(-12deg);
}

.receipt-meta {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid #c76b63;
    padding: 18px 0 10px;
    margin-bottom: 8px;
}

.receipt-line {
    padding: 13px 0;
    border-bottom: 1px solid #d9a39e;
    min-height: 45px;
}

.receipt-amount {
    padding: 16px 0;
    font-size: 18px;
}

.receipt-amount b {
    font-size: 24px;
}

.receipt-foot {
    display: flex;
    justify-content: space-between;
    margin: 35px 0 15px;
    font-weight: 700;
}

.thanks {
    text-align: center;
    font-weight: 700;
    padding: 12px;
    border-top: 1px solid #d9a39e;
}

.receipt-bottom {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
    font-weight: 700;
    font-size: 12px;
}

/* Mobile view */
@media (max-width: 600px) {
    .receipt {
        padding: 16px 12px;
    }

    .receipt-head {
        grid-template-columns: 48px 1fr 48px;
        gap: 5px;
    }

    .receipt-title h2 {
        font-size: 17px;
    }

    .receipt-title p {
        font-size: 10px;
    }

    .seal {
        width: 45px;
        height: 45px;
        font-size: 9px;
    }

    .receipt-meta {
        font-size: 12px;
    }
}

/* =========================================
   PRINT: FIT COMPLETE RECEIPT ON ONE A4 PAGE
========================================= */

@page {
    size: A4 portrait;
    margin: 8mm;
}

@media print {

    html,
    body {
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        background: white !important;
    }

    .top,
    .wrap > .actions,
    .no-print,
    nav,
    button,
    .btn {
        display: none !important;
    }

    .wrap {
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .receipt-container {
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .receipt {
        width: 100% !important;
        max-width: none !important;
        min-height: 0 !important;
        height: auto !important;
        margin: 0 !important;
        padding: 10mm !important;
        border: 4px double #b83b32 !important;
        box-shadow: none !important;
        background: #fffdf8 !important;

        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    .receipt-head {
        gap: 8px !important;
    }

    .receipt-title h2 {
        font-size: 21px !important;
    }

    .receipt-meta {
        padding: 10px 0 7px !important;
        margin-bottom: 5px !important;
    }

    .receipt-line {
        padding: 8px 0 !important;
        min-height: 0 !important;
    }

    .receipt-amount {
        padding: 10px 0 !important;
        font-size: 16px !important;
    }

    .receipt-amount b {
        font-size: 21px !important;
    }

    .receipt-foot {
        margin: 25px 0 12px !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    .thanks {
        padding: 8px !important;
    }

    .receipt-bottom {
        margin-top: 10px !important;
    }

    
}
