How can I reduce the space at the top of my form?

  • Profile Image
    midtownmetro
    Asked on March 02, 2015 at 04:38 PM

    Hello,

    I would like to reduce the padding at the top of my form. It is currently embedded in my site and there is too much space before the title.

    I suspect it can be solved with a CSS code? 

    Here is the form: https://secure.jotform.us/form/50155609953156

    Here is the site (in beta mode) where there is too much space. I would like the form to start right after the line about Midtown COP:

    chelsea-davis-1p5b.squarespace.com/apply

     

    Thanks!

  • Profile Image
    Ben
    Answered on March 02, 2015 at 05:23 PM

    Please try adding this code right above the source code of the form on your website page:

    <style type="text/css">
    form.jotform-form {
        padding-top: 0;
        margin-top: -50px;
    }
    </style>

    If you want to adjust the code a bit, you can do that with -50 (marked it in bold). Bigger the minus (like -60) less space above and lesser the minus (-20) more space it has above the jotform.

    Do let us know how it goes once you do so.

  • Profile Image
    midtownmetro
    Answered on March 04, 2015 at 12:02 PM

    Hi Ben,

    That worked for the page I mentioned. I tried to use it to do the same thing on this newsletter block, far right, but it didnt work. Any tips?

    chelsea-davis-1p5b.squarespace.com/homepage

  • Profile Image
    Sean
    Answered on March 04, 2015 at 12:51 PM

    I believe you would like to get title for the form "Sign Up to Receive Our E-Newsletter" to be in line with the other titles in the columns before it? Like this perhaps...



    I can see that you embedded this form using the iFrame method. You should inject this code into your form and it should fix your issue.

    form.jotform-form{
    padding-top: 0px !important;
    }

    Please advise if otherwise.

    Thanks

  • Profile Image
    midtownmetro
    Answered on March 04, 2015 at 01:01 PM

    Hi!

    Yes, that is exactly what I want to do. I tried embedding the code into that section of the form that you mentioned in the "inject" link... however, it didn't work. I wasn't sure where to put it though, I have this other CSS code in there from the designer?

     

    @import "https://fonts.googleapis.com/css?family=Muli:light,lightitalic,normal,italic,bold,bolditalic";

    .form-all {

    font-family: "Muli", sans-serif;

    }

    .form-all {

    width: 480px;

    width: 100%;

    max-width: 480px;

    }

    .form-label-left,

    .form-label-right {

    width: 150px;

    }

    .form-label {

    white-space: normal;

    }

    .form-label.form-label-auto {

    display: inline-block;

    float: left;

    text-align: left;

    width: 150px;

    }

    .form-label-left {

    display: inline-block;

    white-space: normal;

    float: left;

    text-align: left;

    }

    .form-label-right {

    display: inline-block;

    white-space: normal;

    float: left;

    text-align: right;

    }

    .form-label-top {

    white-space: normal;

    display: block;

    float: none;

    text-align: left;

    }

    .form-all {

    font-size: 14px;

    }

    .form-label {

    font-weight: bold;

    }

    .form-checkbox-item label,

    .form-radio-item label {

    font-weight: normal;

    }

    .supernova {

    background-color: none;

    background-color: #ffffff;

    }

    .supernova body {

    background-color: transparent;

    }

    /*

    @width30: (unit(@formWidth, px) + 60px);

    @width60: (unit(@formWidth, px)+ 120px);

    @width90: (unit(@formWidth, px)+ 180px);

    */

    /* | */

    /* | */

    /* | */

    @media screen and (max-width: 480px) {

    .jotform-form {

    padding: 10px 0;

    }

    }

    /* | */

    /* | */

    @media screen and (min-width: 480px) and (max-width: 768px) {

    .jotform-form {

    padding: 30px 0;

    }

    }

    /* | */

    /* | */

    @media screen and (min-width: 768px) and (max-width: 1024px) {

    .jotform-form {

    padding: 60px 0;

    }

    }

    /* | */

    /* | */

    @media screen and (min-width: 1024px) {

    .jotform-form {

    padding: 90px 0;

    }

    }

    /* | */

    .supernova .form-all,

    .form-all {

    background-color: none;

    border: 1px solid transparent;

    }

    .form-all {

    color: #555555;

    }

    .form-header-group .form-header {

    color: #555555;

    }

    .form-header-group .form-subHeader {

    color: #6f6f6f;

    }

    .form-sub-label {

    color: #6f6f6f;

    }

    .form-label-top,

    .form-label-left,

    .form-label-right,

    .form-html {

    color: #555555;

    }

    .form-checkbox-item label,

    .form-radio-item label {

    color: #6f6f6f;

    }

    .form-line.form-line-active {

    -webkit-transition-property: all;

    -moz-transition-property: all;

    -ms-transition-property: all;

    -o-transition-property: all;

    transition-property: all;

    -webkit-transition-duration: 0.3s;

    -moz-transition-duration: 0.3s;

    -ms-transition-duration: 0.3s;

    -o-transition-duration: 0.3s;

    transition-duration: 0.3s;

    -webkit-transition-timing-function: ease;

    -moz-transition-timing-function: ease;

    -ms-transition-timing-function: ease;

    -o-transition-timing-function: ease;

    transition-timing-function: ease;

    background-color: #ffffe0;

    }

    /* ömer */

    .form-radio-item,

    .form-checkbox-item {

    padding-bottom: 0px !important;

    }

    .form-radio-item:last-child,

    .form-checkbox-item:last-child {

    padding-bottom: 0;

    }

    /* ömer */

    [data-type="control_radio"] .form-input,

    [data-type="control_checkbox"] .form-input,

    [data-type="control_radio"] .form-input-wide,

    [data-type="control_checkbox"] .form-input-wide {

    width: 100%;

    max-width: 195px;

    }

    .form-radio-item,

    .form-checkbox-item {

    width: 100%;

    max-width: 195px;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    .form-textbox.form-radio-other-input,

    .form-textbox.form-checkbox-other-input {

    width: 80%;

    margin-left: 3%;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    .form-multiple-column {

    width: 100%;

    }

    .form-multiple-column .form-radio-item,

    .form-multiple-column .form-checkbox-item {

    width: 10%;

    }

    .form-multiple-column[data-columncount="1"] .form-radio-item,

    .form-multiple-column[data-columncount="1"] .form-checkbox-item {

    width: 100%;

    }

    .form-multiple-column[data-columncount="2"] .form-radio-item,

    .form-multiple-column[data-columncount="2"] .form-checkbox-item {

    width: 50%;

    }

    .form-multiple-column[data-columncount="3"] .form-radio-item,

    .form-multiple-column[data-columncount="3"] .form-checkbox-item {

    width: 33.33333333%;

    }

    .form-multiple-column[data-columncount="4"] .form-radio-item,

    .form-multiple-column[data-columncount="4"] .form-checkbox-item {

    width: 25%;

    }

    .form-multiple-column[data-columncount="5"] .form-radio-item,

    .form-multiple-column[data-columncount="5"] .form-checkbox-item {

    width: 20%;

    }

    .form-multiple-column[data-columncount="6"] .form-radio-item,

    .form-multiple-column[data-columncount="6"] .form-checkbox-item {

    width: 16.66666667%;

    }

    .form-multiple-column[data-columncount="7"] .form-radio-item,

    .form-multiple-column[data-columncount="7"] .form-checkbox-item {

    width: 14.28571429%;

    }

    .form-multiple-column[data-columncount="8"] .form-radio-item,

    .form-multiple-column[data-columncount="8"] .form-checkbox-item {

    width: 12.5%;

    }

    .form-multiple-column[data-columncount="9"] .form-radio-item,

    .form-multiple-column[data-columncount="9"] .form-checkbox-item {

    width: 11.11111111%;

    }

    .form-single-column .form-checkbox-item,

    .form-single-column .form-radio-item {

    width: 100%;

    }

    .supernova {

    height: 100%;

    background-repeat: no-repeat;

    background-attachment: scroll;

    background-position: center top;

    background-repeat: repeat;

    }

    .supernova {

    background-image: none;

    }

    #stage {

    background-image: none;

    }

    /* | */

    .form-all {

    background-repeat: no-repeat;

    background-attachment: scroll;

    background-position: center top;

    background-repeat: repeat;

    }

    .form-header-group {

    background-repeat: no-repeat;

    background-attachment: scroll;

    background-position: center top;

    }

    .form-line {

    margin-top: 7px;

    margin-bottom: 7px;

    }

    .form-line {

    padding: 1px 36px;

    }

    .form-all .form-submit-button,

    .form-all .form-submit-reset,

    .form-all .form-submit-print {

    -webkit-border-radius: 100px;

    -moz-border-radius: 100px;

    border-radius: 100px;

    }

    .form-all .form-sub-label {

    margin-left: 3px;

    }

    .form-all .qq-upload-button,

    .form-all .form-submit-button,

    .form-all .form-submit-reset,

    .form-all .form-submit-print {

    height: 60px;

    font-size: 1.15em;

    padding: 12px 18px;

    font-family: "Muli", sans-serif;

    font-size: 20px;

    font-weight: lighter;

    border: none;

    border-width: 3px !important;

    border-style: solid !important;

    border-color: #e1e3e4 !important;

    }

    .form-all .form-submit-print {

    margin-left: 0 !important;

    margin-right: 0 !important;

    }

    .form-all .qq-upload-button,

    .form-all .form-submit-button,

    .form-all .form-submit-reset,

    .form-all .form-submit-print {

    color: #e4e5e6 !important;

    background: #69696a;

    box-shadow: none;

    text-shadow: none;

    }

    .form-all .form-pagebreak-back,

    .form-all .form-pagebreak-next {

    font-size: 1em;

    padding: 9px 15px;

    font-family: "Muli", sans-serif;

    font-size: 14px;

    font-weight: normal;

    }

    /*

    & when ( @buttonFontType = google ) {

    @import (css) "@{buttonFontLink}";

    }

    */

    h2.form-header {

    line-height: 1.618em;

    }

    h2 ~ .form-subHeader {

    line-height: 1.5em;

    }

    .form-header-group {

    text-align: left;

    }

    .form-line {

    zoom: 1;

    }

    .form-line:before,

    .form-line:after {

    display: table;

    content: '';

    line-height: 0;

    }

    .form-line:after {

    clear: both;

    }

    .form-sub-label-container {

    margin-right: 0;

    float: left;

    white-space: nowrap;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    .form-sub-label-container .date-separate {

    visibility: hidden;

    }

    .form-captcha input,

    .form-spinner input {

    width: 195px;

    }

    .form-textbox,

    .form-textarea {

    width: 100%;

    max-width: 195px;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    .form-input,

    .form-address-table,

    .form-matrix-table {

    width: 100%;

    max-width: 195px;

    }

    .form-radio-item,

    .form-checkbox-item {

    width: 100%;

    max-width: 195px;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    .form-textbox.form-radio-other-input,

    .form-textbox.form-checkbox-other-input {

    width: 80%;

    margin-left: 3%;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    .form-multiple-column {

    width: 100%;

    }

    .form-multiple-column .form-radio-item,

    .form-multiple-column .form-checkbox-item {

    width: 10%;

    }

    .form-multiple-column[data-columncount="1"] .form-radio-item,

    .form-multiple-column[data-columncount="1"] .form-checkbox-item {

    width: 100%;

    }

    .form-multiple-column[data-columncount="2"] .form-radio-item,

    .form-multiple-column[data-columncount="2"] .form-checkbox-item {

    width: 50%;

    }

    .form-multiple-column[data-columncount="3"] .form-radio-item,

    .form-multiple-column[data-columncount="3"] .form-checkbox-item {

    width: 33.33333333%;

    }

    .form-multiple-column[data-columncount="4"] .form-radio-item,

    .form-multiple-column[data-columncount="4"] .form-checkbox-item {

    width: 25%;

    }

    .form-multiple-column[data-columncount="5"] .form-radio-item,

    .form-multiple-column[data-columncount="5"] .form-checkbox-item {

    width: 20%;

    }

    .form-multiple-column[data-columncount="6"] .form-radio-item,

    .form-multiple-column[data-columncount="6"] .form-checkbox-item {

    width: 16.66666667%;

    }

    .form-multiple-column[data-columncount="7"] .form-radio-item,

    .form-multiple-column[data-columncount="7"] .form-checkbox-item {

    width: 14.28571429%;

    }

    .form-multiple-column[data-columncount="8"] .form-radio-item,

    .form-multiple-column[data-columncount="8"] .form-checkbox-item {

    width: 12.5%;

    }

    .form-multiple-column[data-columncount="9"] .form-radio-item,

    .form-multiple-column[data-columncount="9"] .form-checkbox-item {

    width: 11.11111111%;

    }

    [data-type="control_dropdown"] .form-dropdown {

    width: 100% !important;

    max-width: 195px;

    }

    [data-type="control_fullname"] .form-sub-label-container {

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    width: 48%;

    }

    [data-type="control_fullname"] .form-sub-label-container:first-child {

    margin-right: 4%;

    }

    [data-type="control_phone"] .form-sub-label-container {

    width: 65%;

    }

    [data-type="control_phone"] .form-sub-label-container:first-child {

    width: 32.5%;

    margin-right: 2.5%;

    }

    [data-type="control_birthdate"] .form-sub-label-container {

    width: 22%;

    margin-right: 3%;

    }

    [data-type="control_birthdate"] .form-sub-label-container:first-child {

    width: 50%;

    }

    [data-type="control_birthdate"] .form-sub-label-container:last-child {

    margin-right: 0;

    }

    [data-type="control_birthdate"] .form-sub-label-container .form-dropdown {

    width: 100%;

    }

    [data-type="control_time"] .form-sub-label-container {

    width: 37%;

    margin-right: 3%;

    }

    [data-type="control_time"] .form-sub-label-container:last-child {

    width: 20%;

    margin-right: 0;

    }

    [data-type="control_time"] .form-sub-label-container .form-dropdown {

    width: 100%;

    }

    [data-type="control_datetime"] .form-sub-label-container {

    width: 28%;

    margin-right: 4%;

    }

    [data-type="control_datetime"] .form-sub-label-container:last-child {

    width: 4%;

    margin-right: 0;

    }

    [data-type="control_datetime"].allowTime .form-sub-label-container {

    width: 12%;

    margin-right: 3%;

    }

    [data-type="control_datetime"].allowTime .form-sub-label-container:last-child {

    width: 4%;

    margin-right: 0;

    }

    [data-type="control_datetime"].allowTime span .form-sub-label-container:first-child {

    width: 3%;

    }

    [data-type="control_datetime"].allowTime span .form-sub-label-container:last-child {

    width: 12%;

    margin-right: 3%;

    }

    [data-type="control_datetime"].allowTime .form-dropdown {

    width: 100%;

    }

    [data-type="control_payment"] .form-sub-label-container {

    width: auto;

    }

    [data-type="control_payment"] .form-sub-label-container .form-dropdown {

    width: 100%;

    }

    .form-address-table td .form-dropdown {

    width: 100%;

    }

    .form-address-table td .form-sub-label-container {

    width: 96%;

    }

    .form-address-table td:last-child .form-sub-label-container {

    margin-left: 4%;

    }

    .form-address-table td[colspan="2"] .form-sub-label-container {

    width: 100%;

    margin: 0;

    }

    /*.form-dropdown,

    .form-radio-item,

    .form-checkbox-item,

    .form-radio-other-input,

    .form-checkbox-other-input,*/

    .form-captcha input,

    .form-spinner input,

    .form-error-message {

    padding: 4px 3px 2px 3px;

    }

    .form-header-group {

    font-family: "Muli", sans-serif;

    }

    .form-section {

    padding: 0px 0px 0px 0px;

    }

    .form-header-group {

    margin: 0px 36px 0px 36px;

    }

    .form-header-group {

    padding: 9px 0px 9px 0px;

    }

    .form-textbox,

    .form-textarea {

    padding: 4px 3px 2px 3px;

    }

    .form-textbox,

    .form-textarea {

    width: 100%;

    max-width: 195px;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    [data-type="control_textbox"] .form-input,

    [data-type="control_textarea"] .form-input,

    [data-type="control_fullname"] .form-input,

    [data-type="control_phone"] .form-input,

    [data-type="control_datetime"] .form-input,

    [data-type="control_address"] .form-input,

    [data-type="control_email"] .form-input,

    [data-type="control_passwordbox"] .form-input,

    [data-type="control_autocomp"] .form-input,

    [data-type="control_textbox"] .form-input-wide,

    [data-type="control_textarea"] .form-input-wide,

    [data-type="control_fullname"] .form-input-wide,

    [data-type="control_phone"] .form-input-wide,

    [data-type="control_datetime"] .form-input-wide,

    [data-type="control_address"] .form-input-wide,

    [data-type="control_email"] .form-input-wide,

    [data-type="control_passwordbox"] .form-input-wide,

    [data-type="control_autocomp"] .form-input-wide {

    width: 100%;

    max-width: 195px;

    }

    [data-type="control_fullname"] .form-sub-label-container {

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    width: 48%;

    }

    [data-type="control_fullname"] .form-sub-label-container:first-child {

    margin-right: 4%;

    }

    [data-type="control_phone"] .form-sub-label-container {

    width: 65%;

    }

    [data-type="control_phone"] .form-sub-label-container:first-child {

    width: 32.5%;

    margin-right: 2.5%;

    }

    [data-type="control_phone"] .form-sub-label-container .date-separate {

    visibility: hidden;

    }

    [data-type="control_datetime"] .form-sub-label-container {

    width: 28%;

    margin-right: 4%;

    }

    [data-type="control_datetime"] .form-sub-label-container:last-child {

    width: 4%;

    margin-right: 0;

    }

    [data-type="control_datetime"] .form-sub-label-container .date-separate {

    visibility: hidden;

    }

    [data-type="control_datetime"].allowTime .form-sub-label-container {

    width: 12%;

    margin-right: 3%;

    }

    [data-type="control_datetime"].allowTime .form-sub-label-container:last-child {

    width: 4%;

    margin-right: 0;

    }

    [data-type="control_datetime"].allowTime span .form-sub-label-container:first-child {

    width: 3%;

    }

    [data-type="control_datetime"].allowTime span .form-sub-label-container:last-child {

    width: 12%;

    margin-right: 3%;

    }

    [data-type="control_datetime"].allowTime .form-dropdown {

    width: 100%;

    }

    .form-matrix-table {

    width: 100%;

    max-width: 195px;

    }

    .form-address-table {

    width: 100%;

    max-width: 195px;

    }

    .form-address-table td .form-dropdown {

    width: 100%;

    }

    .form-address-table td .form-sub-label-container {

    width: 96%;

    }

    .form-address-table td:last-child .form-sub-label-container {

    margin-left: 4%;

    }

    .form-address-table td[colspan="2"] .form-sub-label-container {

    width: 100%;

    margin: 0;

    }

    [data-type="control_dropdown"] .form-input,

    [data-type="control_birthdate"] .form-input,

    [data-type="control_time"] .form-input,

    [data-type="control_dropdown"] .form-input-wide,

    [data-type="control_birthdate"] .form-input-wide,

    [data-type="control_time"] .form-input-wide {

    width: 100%;

    max-width: 195px;

    }

    [data-type="control_dropdown"] .form-dropdown {

    width: 100% !important;

    max-width: 195px;

    }

    [data-type="control_birthdate"] .form-sub-label-container {

    width: 22%;

    margin-right: 3%;

    }

    [data-type="control_birthdate"] .form-sub-label-container:first-child {

    width: 50%;

    }

    [data-type="control_birthdate"] .form-sub-label-container:last-child {

    margin-right: 0;

    }

    [data-type="control_birthdate"] .form-sub-label-container .form-dropdown {

    width: 100%;

    }

    [data-type="control_time"] .form-sub-label-container {

    width: 37%;

    margin-right: 3%;

    }

    [data-type="control_time"] .form-sub-label-container:last-child {

    width: 20%;

    margin-right: 0;

    }

    [data-type="control_time"] .form-sub-label-container .form-dropdown {

    width: 100%;

    }

    .form-buttons-wrapper {

    margin-left: 0 !important;

    text-align: center !important;

    }

    .form-label {

    font-family: "Muli", sans-serif;

    }

    li[data-type="control_image"] div {

    text-align: left;

    }

    li[data-type="control_image"] img {

    border: none;

    border-width: 0px !important;

    border-style: solid !important;

    border-color: false !important;

    }

    .form-line-column {

    width: auto;

    }

    .form-line-error {

    overflow: hidden;

    -webkit-transition-property: none;

    -moz-transition-property: none;

    -ms-transition-property: none;

    -o-transition-property: none;

    transition-property: none;

    -webkit-transition-duration: 0.3s;

    -moz-transition-duration: 0.3s;

    -ms-transition-duration: 0.3s;

    -o-transition-duration: 0.3s;

    transition-duration: 0.3s;

    -webkit-transition-timing-function: ease;

    -moz-transition-timing-function: ease;

    -ms-transition-timing-function: ease;

    -o-transition-timing-function: ease;

    transition-timing-function: ease;

    background-color: #fff4f4;

    }

    .form-line-error .form-error-message {

    background-color: #ff3200;

    clear: both;

    float: none;

    }

    .form-line-error .form-error-message .form-error-arrow {

    border-bottom-color: #ff3200;

    }

    .form-line-error input:not(#coupon-input),

    .form-line-error textarea,

    .form-line-error .form-validation-error {

    border: 1px solid #ff3200;

    -webkit-box-shadow: 0 0 3px #ff3200;

    -moz-box-shadow: 0 0 3px #ff3200;

    box-shadow: 0 0 3px #ff3200;

    }

    .ie-8 .form-all {

    margin-top: auto;

    margin-top: initial;

    }

    .ie-8 .form-all:before {

    display: none;

    }

    /* | */

    @media screen and (max-width: 480px), screen and (max-device-width: 768px) and (orientation: portrait), screen and (max-device-width: 415px) and (orientation: landscape) {

    .jotform-form {

    padding: 0;

    }

    .form-all {

    border: 0;

    width: 100%;

    max-width: initial;

    }

    .form-sub-label-container {

    width: 100%;

    margin: 0;

    }

    .form-input {

    width: 100%;

    }

    .form-label {

    width: 100%!important;

    }

    .form-line {

    padding: 2% 5%;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    input[type=text],

    input[type=email],

    input[type=tel],

    textarea {

    width: 100%;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    max-width: initial !important;

    }

    .form-input,

    .form-input-wide,

    .form-textarea,

    .form-textbox,

    .form-dropdown {

    max-width: initial !important;

    }

    div.form-header-group {

    padding: 9px 0px !important;

    margin: 0 0px 2% !important;

    margin-left: 5% !important;

    margin-right: 5% !important;

    -moz-box-sizing: border-box;

    -webkit-box-sizing: border-box;

    box-sizing: border-box;

    }

    [data-type="control_button"] {

    margin-bottom: 0 !important;

    }

    .form-buttons-wrapper {

    margin: 0!important;

    }

    .form-buttons-wrapper button {

    width: 100%;

    }

    table {

    width: 100%!important;

    max-width: initial !important;

    }

    table td + td {

    padding-left: 3%;

    }

    .form-checkbox-item input,

    .form-radio-item input {

    width: auto;

    }

    .form-collapse-table {

    margin: 0 5%;

    }

    }

    /* | *//*__INSPECT_SEPERATOR__*/

  • Profile Image
    Sean
    Answered on March 04, 2015 at 01:38 PM

    You are on the right track. You should ensure that you paste the code at the end of the existing CSS that you provided above. 

    Please try the code below. 

    form.jotform-form{
    padding-top: 0px !important;
    margin-top: -15px;
    }

    You should ensure you paste it after /* | *//*__INSPECT_SEPERATOR__*/