Hello,
I'm encountering an issue with my survey's mobile view. While it appeared fine during the mobile preview, upon attempting to check it via an anonymized link, a section of my survey is displaying incorrectly on mobile devices. This section comprises multiple questions involving HTML and JavaScript, with 3 to 5 tables included within the text. In mobile devices, options cover the tables, and they mix. I suspect there might be an issue with my CSS, but I haven't been able to pinpoint the problem.
I am very close to launching and would very much appreciate it if you could help me solve this issue.
I've attached screenshots illustrating the issue and HTML and CSS codes as well.
HTML:
<div id="preamble">
<div id="MixedYN_SP1">Assume you are traveling to ${e://Field/WorkerOrStudent} and have to pick between the options provided below for how to get there.</div><br>
Which of these options do you pick?
</div>
<div id="drive" class="option">
<div><b>Auto</b></div>
<table class="attribute">
<tbody>
<tr>
<th> </th>
<th> </th>
</tr>
<tr class="attribute">
<td class="attribute label"><u>Travel Time</u> :</td>
<td class="attribute value">
<p id="driveTime_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Travel Cost</u> :</td>
<td class="attribute value">
<p id="driveCost_SP1" class="" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Parking Cost</u> :</td>
<td class="attribute value">
<p id="driveParking_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Condo Parking Cost</u> :</td>
<td class="attribute value">
<p id="drivehomepark_SP1" class="attribute" align="right"> </p>
<p style="color: yellow; font-size: 9.5px; font-weight: bold; font-style: italic; margin-top: 4px;">(Condo charges per parking<br> leave, plus monthly fee)</p>
</td>
</tr>
</tbody>
</table>
</div>
<div id="Passenger" class="option">
<div><b>Passenger</b></div>
<table class="attribute">
<tbody>
<tr>
<th> </th>
<th> </th>
</tr>
<tr class="attribute">
<td class="attribute label"><u>Travel Time</u> :</td>
<td class="attribute value">
<p id="PassTime_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Travel Cost</u> :</td>
<td class="attribute value">
<p id="PassCost_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Parking Cost</u> :</td>
<td class="attribute value">
<p id="PassParking_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Condo Parking Cost</u> :</td>
<td class="attribute value">
<p id="Passhomepark_SP1" class="attribute" align="right"> </p>
<p style="color: yellow; font-size: 9.5px; font-weight: bold; font-style: italic; margin-top: 4px;">(Condo charges per parking<br> leave, plus monthly fee)</p>
</td>
</tr>
</tbody>
</table>
</div>
<div id="transit" class="option">
<div><b>Transit</b></div>
<table class="attribute">
<tbody>
<tr>
<th> </th>
<th> </th>
</tr>
<tr class="attribute">
<td class="attribute label"><u>Travel Time</u> :</td>
<td class="attribute value">
<p id="transitTime_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr class="attribute">
<td class="attribute label"><u>Wait Time</u> :</td>
<td class="attribute value">
<p id="TransitWait_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr class="attribute">
<td class="attribute label"><u>Walk Time</u> :</td>
<td class="attribute value">
<p id="Transitwalk_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Travel Cost</u> :</td>
<td class="attribute value">
<p id="TransitCost_SP1" class="attribute" align="right"> </p>
<p style="color: yellow; font-size: 9px; font-weight: bold; font-style: italic; margin-top: 4px;">(Condo offers 50% discount<br> on transit fare)</p>
</td>
</tr>
</tbody>
</table>
</div>
<div id="Bike" class="option">
<div><b>Bike</b></div>
<table class="attribute">
<tbody>
<tr>
<th> </th>
<th> </th>
</tr>
<tr class="attribute">
<td class="attribute label"><u>Bike share station</u> :</td>
<td class="attribute value">
<p id="BikeshareSt_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Bike share membership cost</u> :</td>
<td class="attribute value">
<p id="BikeshareMem_SP1" class="attribute" align="right"> </p>
<p style="color: yellow; font-size: 9px; font-weight: bold; font-style: italic; margin-top: 0px;">(100% cost paid by condo)</p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Bicycle parking</u> :</td>
<td class="attribute value">
<p id="Bikeparking_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>E-bike share station</u> :</td>
<td class="attribute value">
<p id="EbikeSt_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Bike repair station</u> :</td>
<td class="attribute value">
<p id="Repair_SP1" class="attribute" align="right"> </p>
</td>
</tr>
<tr>
<td class="attribute label"><u>Free annual Bike tuning</u> :</td>
<td class="attribute value">
<p id="Tuning_SP1" class="attribute" align="right"> </p>
</td>
</tr>
</tbody>
</table>
</div>
<div id="avShare" class="option">
<div><b>Walk</b></div>
<table class="attribute">
<tbody>
<tr>
<th> </th>
<th> </th>
</tr>
<tr class="attribute">
<td class="attribute label"><u>Travel distance</u> :</td>
<td class="attribute value">
<p id="walkdistance_SP1" class="attribute" align="right"> </p>
</td>
</tr>
</tbody>
</table>
</div>
CSS:
CSS:
#CustomNextButton {
background: #007ac0;
font-family: Poppins, Arial, sans-serif;
border: none;
border-radius: 5px;
padding: 8px 14px;
font-size: 18px;
color: #fff;
}
.option {
background: #007ac0;
color: white;
float: left;
margin-top: 10px;
margin-bottom: 10px;
margin-right: 20px;
width: 325px;
height: 425px;
padding: 10px;
border: 5px solid #007ac0;
border-radius: 10px;
font-size: 16px;
}
.OptionTitle {
font-size: 20px;
}
table.attributeHolder, th, td {
border: 1px #68c0f3 ;
height: 25px;
width: 320px;
padding: 1px;
}
tr, td, th {
border-bottom: 1px solid #ddd;
}
.attribute {
padding: 1px;
margin: 0px;
}
td.label {
width: 60%;
}
p.attribute, td.attribute, tr.attribute, table.attribute {
padding: 1px;
margin: 0px;
}
td.attribute.value {
max-width: 165px;
max-height: 50px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
padding-bottom: 0.0000002px;
}
.tooltip {
position:relative; /* making the .tooltip span a container for the tooltip text */
border-bottom:1px dashed #000; /* little indicater to indicate it's hoverable */
}
.tooltip:before {
content: attr(data-text);
position:absolute;
/* vertically center */
top:100%;
transform:translateY(-50%);
/* move to right */
left:-25%;
margin-left:0px;
/* basic styles */
width:250px;
padding:5px;
border-radius:5px;
background:#000;
color: #fff;
text-align:left;
line-height: normal;
font-size: 12px;
display:none; /* hide by default */
}
.tooltip:after {
}
.tooltip:hover:before, .tooltip:hover:after {
display:block;
}
.video-container{
position: relative;
padding-bottom: 56.25%;
padding-top: 30px;
height: 0;
overflow: hidden;
}
.video-container iframe, .video-container object, .video-container embed{
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}