/* Printq Withdrawal — storefront form, matched to the DailyPrint Figma. */

.printq-withdrawal {
    max-width : 100%;
}

/* Legal notice (editable CMS block) rendered inside the card */
.printq-withdrawal__legal {
    margin-bottom : 16px;
    color         : #333;
}

.printq-withdrawal__legal h1 {
    margin      : 0 0 16px;
    line-height : 1.2;
    color       : #333;
}

.printq-withdrawal__legal p {
    margin      : 0;
    font-size   : 14px;
    line-height : 22px;
    color       : #333;
}

.printq-withdrawal__legal a {
    color           : #333;
    text-decoration : underline;
}

/* Field grid: 2 columns on desktop, 1 on small screens */
.printq-withdrawal__grid {
    display               : grid;
    grid-template-columns : 1fr 1fr;
    column-gap            : 24px;
    row-gap               : 16px;
    align-items           : start;
}

.printq-withdrawal__grid .field {
    margin : 0;
}

.printq-withdrawal__full {
    grid-column : 1 / -1;
}

.printq-withdrawal .field > .label {
    display     : block;
    margin      : 0 0 9px;
    padding     : 0;
    font-family : "Arial", "Helvetica Neue", Helvetica, sans-serif;
    font-weight : 400;
    font-size   : 14px;
    line-height : normal;
    color       : #333;
    text-align  : left;
    float       : none;
    width       : auto;
}

.printq-withdrawal .field.required > .label > span:after {
    content     : "*";
    margin-left : 2px;
    color       : #333;
}

.printq-withdrawal .control {
    width    : 100%;
    position : relative;
}

.printq-withdrawal input.input-text,
.printq-withdrawal textarea {
    width         : 100%;
    box-sizing    : border-box;
    height        : 44px;
    padding       : 7px 8px;
    border        : 1px solid #b2b2b2;
    border-radius : 0;
    background    : #fff;
    font-family   : "Arial", "Helvetica Neue", Helvetica, sans-serif;
    font-size     : 14px;
    font-weight   : 400;
    color         : #333;
    box-shadow    : none;
}

.printq-withdrawal textarea {
    height      : auto;
    min-height  : 120px;
    resize      : vertical;
    line-height : 1.4;
}

.printq-withdrawal input.input-text::placeholder,
.printq-withdrawal textarea::placeholder,
.printq-withdrawal .control textarea::placeholder {
    color       : #959595;
    opacity     : 1;
    font-family : "Arial", "Helvetica Neue", Helvetica, sans-serif;
    font-weight : 400;
}

.printq-withdrawal input.input-text:focus,
.printq-withdrawal textarea:focus,
.printq-withdrawal .control textarea:focus {
    border-color : #b9ce00;
    box-shadow   : none;
}

.printq-withdrawal input.mage-error,
.printq-withdrawal textarea.mage-error {
    border-color : #eb5757;
}

/* Valid state — lime border + checkmark (Figma "Filled"). Border matches the
   brand lime so it reads as one colour with the checkmark icon. */
.printq-withdrawal input.pw-valid,
.printq-withdrawal textarea.pw-valid {
    padding-right : 36px;
}

/* The checkmark is an overlay on the .control wrapper (not the input background)
   so browser autofill — which repaints the input background — can't hide it. */
.printq-withdrawal .control.pw-valid-field:after {
    content         : "";
    position        : absolute;
    /* Anchor to the input row (44px input -> 22px centre - 5px half icon = 17px)
       instead of the control's centre, so the tick doesn't shift down when the
       error message appears below and grows the control. */
    top             : 17px;
    right           : 12px;
    width           : 17px;
    height          : 10px;
    margin-top      : 0;
    background      : url("../images/checkmark.svg") no-repeat center;
    background-size : 17px 10px;
    pointer-events  : none;
}

.printq-withdrawal__full .control.pw-valid-field:after {
    top        : 16px;
    margin-top : 0;
}

/* Keep browser-autofilled fields on the white form background. */
.printq-withdrawal input.input-text:-webkit-autofill,
.printq-withdrawal input.input-text:-webkit-autofill:hover,
.printq-withdrawal input.input-text:-webkit-autofill:focus {
    -webkit-box-shadow      : 0 0 0 1000px #fff inset;
    box-shadow              : 0 0 0 1000px #fff inset;
    -webkit-text-fill-color : #333;
}

/* Validation error message (red text below the field) */
.printq-withdrawal label.mage-error,
.printq-withdrawal div.mage-error {
    display     : block;
    margin-top  : 10px;
    color       : #eb5757;
    font-size   : 14px;
    line-height : 1.4;
    font-weight : 400;
}

/* Consent checkbox row */
.printq-withdrawal__consent {
    display     : flex;
    align-items : flex-start;
    gap         : 8px;
    margin      : 16px 0 0;
}

.printq-withdrawal__consent input[type="checkbox"] {
    -webkit-appearance : none;
    appearance         : none;
    flex               : 0 0 auto;
    width              : 19.2px;
    height             : 19.2px;
    margin             : 2px 0 0;
    border             : 1px solid #b2b2b2;
    border-radius      : 2px;
    background         : #fff;
    cursor             : pointer;
}

.printq-withdrawal__consent input[type="checkbox"]:checked {
    background-color    : #b9ce00;
    border-color        : #b9ce00;
    background-image    : url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='17' height='10' viewBox='0 0 17 10' fill='none'%3E%3Cpath d='M1.54492 5.00013L5.87788 8.68434L14.5401 1.31592' stroke='white' stroke-width='2.31908' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat   : no-repeat;
    background-position : center;
    background-size     : 11px 7px;
}

.printq-withdrawal__consent input[type="checkbox"]:focus-visible {
    outline        : 2px solid #00b078;
    outline-offset : 1px;
}

.printq-withdrawal__consent .label {
    margin      : 0;
    padding     : 0;
    font-family : Arial, sans-serif;
    font-size   : 12px;
    line-height : 21px;
    color       : #333;
    font-weight : 400;
}

.printq-withdrawal__consent .label span {
    font-size : 12px;
}

.printq-withdrawal__consent .label a {
    text-decoration : underline;
    color           : #333;
}

.printq-withdrawal__consent .label:after {
    content : "";
}

.printq-withdrawal__note {
    margin      : 8px 0 0;
    font-size   : 12px;
    line-height : 21px;
    color       : #333;
}

/* Submit button — right-aligned, brand lime when enabled, grey when disabled */
.printq-withdrawal__actions {
    display         : flex;
    justify-content : flex-end;
    margin-top      : 24px;
}

.printq-withdrawal__submit {
    display         : inline-flex;
    align-items     : center;
    justify-content : center;
    min-height      : 44px;
    padding         : 10px 60px;
    border          : none;
    border-radius   : 2px;
    background      : #b9ce00;
    color           : #1a1a1a;
    font-size       : 14px;
    font-weight     : 400;
    line-height     : 1;
    text-transform  : uppercase;
    cursor          : pointer;
    transition      : background-color .15s ease;
}

.printq-withdrawal__submit:hover:not([disabled]) {
    background : #b0c000;
}

.printq-withdrawal__submit[disabled] {
    background : #b2b2b2;
    color      : #666;
    cursor     : not-allowed;
}

.pw-server-error {
    margin-top : 6px;
    color      : #eb5757;
    font-size  : 12px;
}

/* Success state (Figma): centered lime check + title, body in a white box,
   CTA right-aligned on desktop / full-width on mobile. */
.printq-withdrawal__success-check {
    width           : 56px;
    height          : 34px;
    margin          : 8px auto 20px;
    background      : url("../images/checkmark.svg") no-repeat center;
    background-size : contain;
}

.printq-withdrawal__success-title {
    margin      : 0 0 24px;
    line-height : 1.2;
    color       : #333;
    text-align  : center;
}

.printq-withdrawal__success-box {
    background : #fff;
    padding    : 18px 24px;
}

.printq-withdrawal__success-text {
    margin      : 0;
    font-size   : 14px;
    line-height : 22px;
    color       : #333;
}

.printq-withdrawal__success-actions {
    display         : flex;
    justify-content : flex-end;
    margin-top      : 24px;
}

.printq-withdrawal__success-cta {
    display         : inline-flex;
    height          : 44px;
    padding         : 0 24px;
    justify-content : center;
    align-items     : center;
    gap             : 10px;
    border-radius   : 2px;
    background      : #b9ce00;
    color           : #333333;
    font-size       : 14px;
    font-weight     : 400;
    text-transform  : uppercase;
    text-decoration : none;
}

.printq-withdrawal__success-cta:visited {
    color : #333333;
}

.printq-withdrawal__success-actions a.printq-withdrawal__success-cta:hover {
    background      : #A4B700;
    color           : #333333 !important;
    text-decoration : none;
}

/* Confirmation modal — vertically centered + brand skin.
   Appended to <body> by Magento, so these rules are NOT scoped under .printq-withdrawal. */
.printq-withdrawal-modal.modal-popup {
    display : flex;
    top     : 25%;
}

.printq-withdrawal-modal.modal-popup .modal-inner-wrap {
    margin    : auto;
    max-width : 702px;
}

/* Grey, centered header (no close button) — matches the design. */
.printq-withdrawal-modal .modal-header {
    display         : flex;
    align-items     : center;
    justify-content : center;
    box-sizing      : border-box;
    width           : 100%;
    padding         : 16px 8px;
    background      : #f2f4f7;
}

.printq-withdrawal-modal .modal-title {
    text-align     : center;
    padding-bottom : 0;
    border-bottom  : none;
    font-size      : 18px;
    font-weight    : 400;
    line-height    : 1.3;
    color          : #000;
}

.printq-withdrawal-modal .action-close {
    display : none;
}

.printq-withdrawal-modal .modal-content {
    padding     : 24px 24px 10px 24px;
    font-size   : 14px;
    line-height : 1.5;
    color       : #333;
}

.printq-withdrawal-modal__content > p:first-of-type {
    margin : 0;
}

.printq-withdrawal-modal__content p {
    color : #000;
}

.printq-withdrawal-modal__prompt {
    box-sizing  : border-box;
    width       : 654px;
    max-width   : 100%;
    height      : 22px;
    margin      : 16px 0 0;
    font-size   : 14px;
    font-weight : 400;
    color       : #333;
}

.printq-withdrawal-modal .modal-footer {
    display         : flex;
    justify-content : space-between;
    gap             : 12px;
    padding         : 0px 24px 24px 24px;
}

/* Buttons: icon + centered label. Secondary = lime outline, primary = lime fill. */
.printq-withdrawal-modal .modal-footer .action {
    display         : inline-flex;
    align-items     : center;
    justify-content : center;
    box-sizing      : border-box;
    gap             : 8px;
    height          : 44px;
    min-height      : 44px;
    padding         : 0 12px;
    border-radius   : 2px;
    font-size       : 14px;
    font-weight     : 400;
    text-transform  : none;
    white-space     : nowrap;
    box-shadow      : none;
}

.printq-withdrawal-modal .modal-footer .action:before {
    content             : "";
    flex                : 0 0 auto;
    width               : 24px;
    height              : 24px;
    background-repeat   : no-repeat;
    background-position : center;
    background-size     : contain;
}

.printq-withdrawal-modal .modal-footer .action.secondary {
    min-width  : 170px;
    background : #fff;
    border     : 1px solid #c2d500;
    color      : #000;
}

.printq-withdrawal-modal .modal-footer .action.secondary:before {
    background-image : url("../images/cancel.svg");
}

.printq-withdrawal-modal .modal-footer .action.primary {
    min-width  : 164px;
    background : #b9cd00;
    border     : 1px solid #b9cd00;
    color      : #000;
}

.printq-withdrawal-modal .modal-footer .action.primary:hover {
    background   : #b0c000;
    border-color : #b0c000;
}

.printq-withdrawal-modal .modal-footer .action.primary:before {
    background-image : url("../images/modal-check.svg");
}


/* Tablet (<= 990px): single column, full-width buttons, stacked modal footer */
@media (max-width : 990px) {
    .printq-withdrawal__grid {
        grid-template-columns : 1fr;
    }

    .printq-withdrawal__legal h1 {
        font-size : 16px;
    }

    .printq-withdrawal__actions {
        justify-content : stretch;
    }

    .printq-withdrawal__submit {
        width         : 100%;
        padding-left  : 16px;
        padding-right : 16px;
    }

    .printq-withdrawal__success-actions {
        justify-content : stretch;
    }

    .printq-withdrawal__success-cta {
        width   : 100%;
        padding : 0;
    }

    .printq-withdrawal-modal .modal-footer {
        flex-direction : column;
    }

    .printq-withdrawal-modal.modal-popup .modal-inner-wrap {
        margin    : 0px 24px;
        width     : calc(100% - 48px);
        max-width : unset;
    }
}

/* Mobile (<= 767.98px): tighter spacing */
@media (max-width : 768px) {
    /*.printq-withdrawal__card {
        padding : 16px;
    }*/

    /* Modal spacing (mobile): title padding 16, body padding 24, buttons stacked
       full-width with 24 between them. */
    /*.printq-withdrawal-modal.modal-popup .modal-header {
        padding : 16px;
    }*/
    .printq-withdrawal-modal.modal-popup .modal-content {
        padding : 24px;
    }

    .printq-withdrawal-modal.modal-popup .modal-footer {
        display        : flex;
        flex-direction : column;
        align-items    : stretch;
        gap            : 24px;
        padding        : 0 24px 24px;
    }

    .printq-withdrawal-modal.modal-popup .modal-footer .action {
        width  : 100%;
        margin : 0;
    }

    .printq-withdrawal-modal.modal-popup .modal-inner-wrap {
        margin : 0px 16px;
        width  : calc(100% - 32px);
    }
}
