.kosher-form-page {
    --kf-blue: #1f4e79;
    --kf-blue-2: #2e5c8a;
    --kf-border: #9db3c8;
    --kf-soft: #f2f6fb;
    direction: rtl;
    max-width: 980px;
    margin: 40px auto;
    padding: 0 16px;
    color: #1a1f26;
}

.kosher-form {
    background: #fff;
    border: 1px solid var(--kf-border);
    box-shadow: 0 12px 35px rgba(31, 78, 121, .10);
}

.kosher-form * {
    box-sizing: border-box;
}

.kf-header {
    background: var(--kf-blue);
    color: #fff;
    text-align: center;
    padding: 18px 22px;
    border: 1px solid var(--kf-blue);
}

.kf-header h1 {
    margin: 4px 0;
    color: #fff;
    font-size: 28px;
    line-height: 1.25;
    font-weight: 700;
}

.kf-header p {
    margin: 3px 0;
    color: #fff;
    font-size: 15px;
}

.kf-title {
    text-align: center;
    padding: 22px 20px 12px;
}

.kf-title h2 {
    margin: 0 0 8px;
    color: var(--kf-blue);
    font-size: 30px;
    line-height: 1.2;
}

.kf-title p {
    margin: 0;
    font-size: 17px;
}

.kf-section-title {
    background: var(--kf-blue-2);
    color: #fff;
    padding: 10px 16px;
    margin: 22px 0 10px;
    font-size: 18px;
    font-weight: 700;
}

.kf-subtitle {
    color: var(--kf-blue);
    border-bottom: 2px solid var(--kf-blue);
    margin: 18px 0 10px;
    padding-bottom: 8px;
    font-size: 20px;
    font-weight: 700;
}

.kf-body {
    padding: 0 18px 24px;
}

.kf-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border-top: 1px solid var(--kf-border);
    border-right: 1px solid var(--kf-border);
    margin: 14px 0;
}

.kf-grid.two {
    grid-template-columns: 1fr 2fr;
}

.kf-grid.two-even,
.kf-grid.two.kf-even {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kf-grid.four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.kf-cell {
    min-height: 58px;
    padding: 10px;
    border-left: 1px solid var(--kf-border);
    border-bottom: 1px solid var(--kf-border);
}
.kf-cell.border-none, .kf-grid.border-none {
    border: none !important;
}
.kf-cell.owner-signature {
    display: flex;
    gap: 10px;
}
.kf-label {
    display: block;
    margin-bottom: 7px;
    font-weight: 700;
}

.kf-note,
.kf-contract p,
.kf-contract li {
    margin: 0 0 10px;
    line-height: 1.75;
}

.kf-contract ol {
    padding-right: 24px;
    margin: 8px 0 16px;
}

.kf-input,
.kf-textarea {
    width: 100%;
    border: 0;
    border-bottom: 1px solid #6c7a89;
    border-radius: 0;
    background: transparent;
    padding: 7px 2px;
    font-size: 16px;
    direction: rtl;
    height: 40px !important;
}

.kosher-form .kf-inline-input {
    display: inline-block !important;
    width: 170px !important;
    max-width: 45vw;
    min-width: 120px;
    margin: 0 5px;
    vertical-align: baseline;
}

.kosher-form .kf-inline-input[type="date"] {
    width: 185px !important;
}

.kf-textarea {
    min-height: 110px;
    border: 1px solid var(--kf-border);
    padding: 10px;
    resize: vertical;
}

.kf-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 22px;
    align-items: center;
}

.kf-check {
    display: inline-flex;
    gap: 7px;
    align-items: center;
    margin: 4px 0;
    font-weight: 400;
}

.kf-check input {
    width: 18px;
    height: 18px;
    margin: 0;
}

.kf-table {
    width: 100%;
    border-collapse: collapse;
    margin: 10px 0 16px;
}

.kf-table th,
.kf-table td {
    border: 1px solid var(--kf-border);
    padding: 9px;
    vertical-align: top;
}

.kf-table th,
.kf-shaded {
    background: var(--kf-soft);
    font-weight: 700;
}

.kf-signature {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.kf-signature canvas {
    display: block;
    width: 100%;
    height: 120px;
    border: 1px solid var(--kf-border);
    background: #fff;
    touch-action: none;
    cursor: crosshair;
}

.kf-clear-signature {
    align-self: flex-start;
    border: 1px solid var(--kf-border);
    border-radius: 4px;
    background: var(--kf-soft);
    color: #1a1f26;
    padding: 5px 12px;
    font-size: 13px;
    cursor: pointer;
    line-height: 1.4;
}

.kf-actions {
    display: flex;
    justify-content: center;
    padding: 22px 0 8px;
}

.kf-submit {
    min-width: 220px;
    border: 0;
    border-radius: 4px;
    background: var(--kf-blue);
    color: #fff;
    padding: 13px 26px;
    font-size: 17px;
    font-weight: 700;
    cursor: pointer;
}

.kf-alert {
    margin: 0 0 18px;
    padding: 13px 16px;
    border-radius: 4px;
    font-weight: 700;
    text-align: center;
}

.kf-alert.success {
    background: #e7f6ec;
    color: #176b34;
    border: 1px solid #b9e3c6;
}

.kf-alert.error {
    background: #fff0f0;
    color: #a12b2b;
    border: 1px solid #efc0c0;
}

.kf-footer {
    text-align: center;
    color: #777;
    font-size: 13px;
    margin-top: 20px;
}

.mainforms_logo {
    margin: 0 auto 15px;
    display: block;
    max-height: 180px;
}
.f4-form {
    padding: 25px;
}

.f4-form h1 {
    text-align: center;
    font-size: 24px;
    margin: 0 0 28px;
    font-weight: 700;
    text-decoration: underline
}

.f4-form h2 {
    font-size: 18px;
    padding: 7px 10px;
    margin: 28px 0 12px
}

.f4-form section h2 {
    background: #c6d9f1;
    font-weight: 700;
}

.f4-grid .f4-field span {
    background: #c6d9f1;
    margin-bottom: 0;
    padding: 5px;
}

.f4-form .f4-instructions {
    font-size: 16px;
    font-weight: 700;
    text-decoration: underline;
    padding-right: 0
}

.f4-form p {
    line-height: 1.65
}

.f4-grid {
    display: grid;
    gap: 10px
}

.f4-grid.four {
    grid-template-columns: repeat(4, 1fr)
}

.f4-grid.three {
    grid-template-columns: repeat(3, 1fr)
}

.f4-grid.two {
    grid-template-columns: repeat(2, 1fr)
}

.f4-field {
    display: block;
    font-size: 14px
}

.f4-field span,
.f4-signature>span {
    display: block;
    margin-bottom: 4px
}

.f4-form input,
.f4-form textarea {
    box-sizing: border-box;
    width: 100%;
    border: 0;
    border-bottom: 1px solid #555;
    background: transparent;
    min-height: 29px;
    padding: 4px
}

.f4-form textarea {
    border: 1px solid #777;
    min-height: 72px
}

.f4-hint {
    font-size: 13px;
    align-self: end
}

.f4-form table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    font-size: 13px
}

.f4-form th,
.f4-form td {
    border: 1px solid #777;
    padding: 5px;
    text-align: right;
    vertical-align: middle
}

.f4-form th {
    font-weight: 700
}

.f4-form thead th {
    background: #c6d9f1
}

.f4-form table input {
    min-width: 0;
    border: 0
}

.f4-line input {
    display: inline-block !important;
    width: 140px !important;
    border-top:none !important;
    border-left:none !important;
    border-right:none !important;
    border-bottom: 1px solid #555 !important;
}

.f4-form section {
    margin-bottom: 24px
}

.f4-checklist {
    margin: 0 25px 15px 0;
    padding-right: 24px
}

.f4-signature canvas {
    display: block;
    max-width: 100%;
    background: #fff;
    border: 1px solid #777
}

.f4-signature .kf-clear-signature {
    margin-top: 5px
}












@media(max-width:700px) {

    .f4-grid.four,
    .f4-grid.three {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .f4-form {
        padding: 15px;
        overflow: visible;
    }

    .f4-table-responsive {
        display: block;
        width: 100%;
        margin: 0 0 16px;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        border: 1px solid #777;
    }

    .f4-table-responsive > table {
        width: max-content;
        min-width: 720px;
        margin: 0;
        table-layout: auto;
        font-size: 14px;
    }

    .f4-table-responsive > table th,
    .f4-table-responsive > table td {
        min-width: 120px;
        padding: 7px;
    }

    .f4-table-responsive > table input {
        min-width: 120px !important;
        min-height: 38px;
        padding: 6px !important;
    }
}

@media (max-width: 760px) {
    .kosher-form-page {
        margin: 20px auto;
        padding: 0 10px;
    }

    .kf-body {
        padding: 0 10px 18px;
    }

    .kf-grid,
    .kf-grid.two,
    .kf-grid.two-even,
    .kf-grid.two.kf-even,
    .kf-grid.four {
        grid-template-columns: 1fr;
    }

    .kf-title h2 {
        font-size: 24px;
    }
}
