@charset "utf-8";

.sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

body { 
    background-color:#e3e3e3;
    font-family:Arial,Helvetica,sans-serif;
    margin: 0;
    max-width: 100%;
    min-width: 100%; 
    width:100%;
}

.main {
    margin:0;
    width:100%;
    background-color:#3e7589;    
    padding: 141px 0 0 0;
    overflow-x: hidden;
}

body:not(.home-page) #userInput {
    margin-top: 0;
    padding-top: 6px;
}

/* Header section */

header {
    position: fixed;
    top: 0;
    z-index: 100;    
    display: block;
    height:60px;
    margin: 0 auto;
    overflow-y:hidden;
    padding: 0 4px;
    width:100%;    
    background-image: url(/img/wood.jpg);
    background-repeat: repeat-x;
    font-size: 20px;
}

h1 {
    display:block;
    color: #fff;
    background-color:#3e7589;
    width:100%;
    font-size: 20px;
    text-align: center;
    line-height: 1.3;
    min-height: 40px;
    height: auto;
    background-repeat: no-repeat;
    margin:0 auto;
    padding:5px 8px 8px;
    box-sizing: border-box;
    position: fixed;
    left:0;
    top:100px;   
    border-top: none;
}

#homePageH1 {
    min-height: 40px !important;
    height: auto !important;
    line-height: 1.3 !important;
    padding: 5px 8px 8px !important;
    box-sizing: border-box;
    color: #fff !important;
}

html:lang(en) #homePageH1 {
    min-height: 75px !important;
}

header p {
    font-size: 22px;
    color: #fff;
    font-weight: bold;
    margin: 25px 10px;
}

#logo {
    width: 80%;
    background-size:80%;
    background-repeat: no-repeat;
    top:15px;
}

#topMenu {
    float: right;
    height: 40px;
    margin: 0 1%;
    position: relative;
    top: 10px;
    width: 300px;
    position: fixed;
    right: 150px;
    top: 85px;    
}

#topMenu a {
    display:block;
    height:40px;
    width:40px;
    float:left;
    margin:0 10px;
}

header:has(#language select),
header:has(#homeLanguage select) {
    overflow: visible;
}

#homeLanguage,#language {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 4px 5%;
    background-color: #f4f4f4;
    margin: 0;
    color: #595959;
    font-weight: 700;
    font-size: 16px;
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    width: 100%;
    height: auto;
    min-height: 38px;
    line-height: 1.3;
    border-bottom: 1px solid #e3e3e3;
    box-sizing: border-box;
    z-index: 101;
}

#homeLanguage{
    top:60px;    
}

/* Language bar ends ~98px; fixed page h1 was at 100px leaving a content sliver */
body:has(#language select) h1:not(#homePageH1) {
    top: 98px;
    z-index: 99;
}

#homeLanguage select,#language select {
    position: static;
    right: auto;
    flex-shrink: 0;
    width: 50%;
    max-width: 200px;
    height: 28px;
    box-sizing: border-box;
    color: #000;
    background-color: #fff;
    border: 1px solid #b8b8b8;
    border-radius: 0;
    font-size: 16px;
    font-weight: normal;
    padding: 0 2rem 0 0.75rem;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' stroke='%23000000' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 12px 8px;
}

#breadcrumb {
    font-size: 12px;
    margin: 14px 0 0 20px;
    height: 50px;
    color:#cccccc;
    position: fixed;
    top: 50px;    
    display:none;
}

#breadcrumb a {
    color:#cccccc;
    text-decoration: none;
}

.home {
    background-image: url(/img/home.png);
    background-repeat: no-repeat;
    display: block;
    position:fixed;
    height: 30px;
    width: 40px;
    top:20px;
    right:20px;
}

/* Page structure */

.col {
    margin: 0 0 10px 0;
}

.smallcol {
    margin:0 10px 10px 0;
    max-width:100%;
    width:100%;
    min-width:100%;
    float:none;
}

.narrowcol {
    margin:0 10px 10px 0;
    max-width:100%;
    width:100%;
    min-width:100%;
    float:none;    
}

.removeIcon {
    padding:0 0 0 5% !important;
    max-width:95% !important;
    width:95% !important;
}

.nowrap {
    display:inline-block;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space: nowrap;
}

.sideFeature {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* Unit-to-unit mobile: grey main (like home page) so margin gaps are not teal */
body.unit-to-unit-page .main {
    background-color: #e3e3e3;
}

/* Content starts flush under fixed h1 (98px top + 40px min-height) */
body.unit-to-unit-page:has(#language select) .main {
    padding-top: 138px;
}

body.unit-to-unit-page:not(:has(#language select)) .main {
    padding-top: 140px;
}

body.unit-to-unit-page #userInput,
body.unit-to-unit-page #userConvert,
body.unit-to-unit-page #searchInput {
    width: 100%;
    box-sizing: border-box;
    margin-top: 0;
}

body.unit-to-unit-page #userConvert {
    padding-bottom: 14px;
}

/* No teal strip between article and bottom nav */
body.unit-to-unit-page .smallcol {
    margin: 0 10px 0 0;
}

body.unit-to-unit-page .narrowcol {
    margin: 0 10px 10px 0;
}

.sideNav {
    margin:10px 0 0 0;
    width:100% !important;
    min-width:100%;
    max-width:100%;
}

.clear {
    clear:both;
}

.left, .right {
    display:block;
    float: none;
    margin: 0;
    border-top: 15px solid #e3e3e3;
    border-bottom: 15px solid #e3e3e3;
}

.right {
    max-width:100%;
}

.singleArg,.doubleArg,.tripleArg {
    width: 90%;
    height:40px;
    font-size: 1.8em;
}

.doubleArg {
    width: 25%;        
}

.tripleArg {
    width: 25%;        
}

.hideArg {
    display: none;
}

.showArg {
    display: block;
}

.fractionSelect {
    width: 30%;
    height: 40px;
    font-size: 1.5em;
}

.control {
    background-color:#a6a6a6;
    display: block;
    line-height: 8vw;
    padding: 1% 5%;
    color:#fff;
    font-size: 5vw;
    font-weight: bold;
    margin:0;
    width:90%;
    border-bottom:1px solid #e3e3e3;
}

#fractionNote,#decimalNote,#subNoteNote {
    padding:1% 2%;
}

.controlOptions {
    height: 30px;
    width: 200px;
    margin: 2px 0 0 0;
    float: right;      
    color:#000;
    font-size: 14px;
}

.tableControl {
    padding: 5px 0 0 5%;
    max-width: none;
    width: 94%;
    display: block;
    background-color: #a6a6a6;
    float: none;
    height: 40px;
    line-height: 36px;
    margin: 2px 0;
    min-height: 36px;
}

.tableColumn {
    float:left;
    width: 99%;
    min-width:99%;
    margin:0 0.5%;
}

.tableColumnColumn {
    float:left;
    width:49.5%;
    margin:0 0.5% 0 0;
}

.mobileTableColumn {
    width: 99%;
    min-width:99%;
}

.tableElement {
    width:49%;
    min-height:40px;
    background-color:#eeeeee;
    margin:1px 0.5%;
    text-align:center;
    line-height:40px;
    max-height:40px;
    float:left;
}

.tableTitle {
    background-color:#cccccc;
    width: 49%;
    min-height: 50px;
    line-height: 50px;            
}

.underButton {
    background-color:#3e7589;
    color: #fff;
    display: block;
    font-size: 16px;
    font-weight: bold;
    line-height: 50px;
    padding:0 7%;
    text-decoration: none;              
    height: 35px;   
    margin:0 auto;      
    border-top:1px solid #e3e3e3;
}

.underButton {
    padding:0 0 0 20%;
    background-position:5% 0;
    margin:0;
}

.underButton {
    background-repeat: no-repeat;
    color: #fff;
    display: block;
    font-size: 14px;
    font-weight: bold;
    line-height: 50px;
    min-height: 50px;
    padding:0 0 0 20%;
    text-decoration: none;              
    width: 79%;
    margin: 1px auto;
}

.col {
    background-color:#e3e3e3;
    margin: 0;
    width: 100%;
}

.bgPage {
    background-color:#e3e3e3;
}

.temperature {
    background-image: url(/img/temperature.png);
}

.weight {
    background-image: url(/img/weight.png);
}

.length {
    background-image: url(/img/length.png);
}

.area {
    background-image: url(/img/area.png);
}

.volume {
    background-image: url(/img/volume.png);
}

.speed {
    background-image: url(/img/speed.png);
}

.currency {
    background-image: url(/img/currency.png);
}

.time {
    background-image: url(/img/time.png);
}

.angle {
background-image: url(/img/angle.png);
}

.pressure {
    background-image: url(/img/pressure.png);
}

.energy-and-power,.energy {
    background-image: url(/img/energy.png);
}

.health {
    background-image: url(/img/health.png); 
}

.swapIcon {
    background-image: url(/img/swap.png); 
}

.tableIcon {
    background-image: url(/img/table.png); 
    background-position: 0px 0px;
}

.appIcon {
    background-image: url(/img/app.png); 
}

.calcIcon {
    background-image: url(/img/calc.png); 
    background-position: 5px 5px;
}

.bookmarkIcon {
    background-image: url(/img/bookmark.png);	    
}

.home,.homeIcon {
    background-image: url(/img/home.png);
}

.sitemap {            
    background-image: url(/img/sitemap.png);
}

.links {            
    background-image: url(/img/links.png);
}

.contact {            
    background-image: url(/img/contact.png);
}

.adfreeIcon {
    background-image: url(/img/adfree.png); 
    background-position: 5px;
} 


#result p {
    font-size: 14px;
    width:100%;
    margin:0;   
    background-color:#e3e3e3; 
    border-top: 5px solid #e3e3e3;
    border-bottom: 5px solid #e3e3e3;
}

#result .answer {
    font-size: 9vw;
    line-height: 12vw;        
    margin: 0;
    text-align: center;
    width: 100%;    
    border-top: 10px solid #e3e3e3;
    border-bottom: 10px solid #e3e3e3;
}

#result2 {
    background-color:#e3e3e3;
}

/* Mobile unit-to-unit pages: formula title is an h2 (for heading order) */
#showFormula h2 {
    font-size: 18px;
    line-height: 1.25;
    margin: 0 0 8px;
    font-weight: 700;
}

#showWorkingBox {
    width:95%;
    margin:0;
    background-color: #f4f4f4;
    font-size:18px;
    padding: 5px 2%;
    border:0.5% solid #e3e3e3;
}

#userInput,#searchInput {
    background-color:#3e7589;
    line-height:20px;
    min-height: 55px;
    width:94%;
    margin: 0;
    padding:1% 3%;
    font-size: 20px;
}

#searchInput {
    margin:0;
}

#searchInput h3 {
    color: #fff !important;
    font-size: 15px !important;
    font-weight: bold;
    line-height: 1.3;
    margin: 0.35em 0;
}

#searchInput .unitFieldLabel {
    color: #fff !important;
    font-size: 15px !important;
    font-weight: bold;
    line-height: 1.3;
    margin: 0.35em 0;
    display: block;
}

#userInput h2,
#userInput h3 {
    color: #fff !important;
    font-size: 15px !important;
    font-weight: bold;
    line-height: 1.3;
    max-width: 100%;
    overflow-wrap: break-word;
}

#userInput h2 {
    margin: 0.4em 0;
}

#userInput h3 {
    margin: 0.35em 0;
}

#userInput .unitFieldLabel {
    display: block;
    color: #fff;
    font-weight: bold;
    font-size: 15px;
    line-height: 1.3;
    margin: 0 0 0.5em;
}

@media (max-width: 736px) {
    #userInput .unitFieldLabel {
        display: block;
        margin: 0.5em 0 0.15em;
    }

    #userInput .unitFieldLabel:first-of-type {
        margin-top: 0;
    }
}


.searchSuggestion {
    width: 90%;
    background-color:#3e7589;
    display: block;
    border: 1px solid #fff;
    border-left:none;
    border-right:none;
    border-bottom:none;
    height: 60px;
    line-height: 60px;
    padding: 0 0 0 50px;
    background-repeat:no-repeat;
    background-position:left center;
    color:#ffffff;        
}

.searchField {
    margin:0 5px;
    width:40%;
}

#menulinks {
    display:block;
    width:100%;
    color:#333333;
    text-decoration: none;
    background-color:#a6a6a6;
    height:auto;
    min-height:0;
}

#menulinks ul {
    padding: 0;
    margin: 0;
}

#menulinks li:last-child a {
    margin-bottom: 0;
}

#menulinks a {
    display:block;
    width:100%;
    color:#333333;
    text-decoration: none;
    background-color:#a6a6a6;               
}

ul {
    padding: 10px 10px;
    list-style: none;                
}

li {
    width: 350px;
    float:left;
}

#popLinks {
    display:block;
    width:100%;
    max-width:100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

#popLinks ol{
    list-style-type: none;
    padding: 0;
    margin: 0;
    width: 100%;
    max-width: 100%;
}

#popLinks li{
    list-style-type: none;
    padding: 0;
    margin: 0;
    width: 100%;
    max-width: 100%;
    float: none;
    box-sizing: border-box;
}

#popLinks ol li a {
    display:block;
    background-color: #fff;
    min-height: 50px;
    height: auto;
    line-height: 1.3;
    width:100%;
    max-width:100%;
    margin: 0;
    padding: 12px 10px;
    box-sizing: border-box;
    text-decoration:none;
    color:#3e7589;
    white-space: normal;
}

body.links-page #popLinks ol {
    display: flex;
    flex-direction: column;
    gap: 0;
    background-color: #fff;
}

body.links-page #popLinks ol li a {
    border-bottom: 1px solid #e3e3e3;
}

body.links-page #popLinks ol li:last-child a {
    border-bottom: none;
}

.moveDown {
    margin:20px 0;
}

#userConvert .unitConvertTitle {
    color: #fff;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    line-height: 1.3;
    margin: 0 0 0.5em;
    padding: 0;
}

#userConvert h1 {
    line-height:10px;
    font-size:16px;
}

.colSpace {
    display:none;
}

.feature {
    display:none;
}

.featureTypes,.tableTypes {
    min-height:100px;
    float:none;
    width:94.8%;
    max-width:100%;
    margin: 1px auto;
    padding-top: 0;
    padding-bottom: 0;
}

.sideMenu,table {
    width:100%;
    min-width:140px;
    max-width:100%;
}

.typeConv {
    display:block;
    margin:1px auto;
    height:50px;
    background-color:#3e7589;
    background-repeat: no-repeat;
    background-position: 5px 5px;
    color: #ffffff;
    font-weight: bold;
    line-height: 50px;
    padding: 0 0 0 18%;
    text-decoration: none;
    width: 80%;                              
    font-size: 16px;
}

.unitConv {
    background-color:#595959;
}

.featureConv {
    padding-top: 0;
    line-height: 50px;
}

.type {
    width:87.5%;
    padding:0 0 0 17.5%;
}


.unit2UnitConv {
    background-color:#c3c3c3;
}

.noadcolumn .unit {
    width:86%;
    padding: 0 0 0 19%;    
}

.noadcolumn .tounit {
    width:81%;
    padding: 0 0 0 24%;   
}

.linkDiv {
    margin:-10px 0 0 0;
}

.removeIcon {
    padding:0 0 0 5% !important;
    max-width:100% !important;
    width:100% !important;
}

.mobileWidth88 {
    width:88%;
}

#metricConversionTable {
    margin:-10px 0 0 0;
}


#userConvert {
    background-color:#3e7589;
    margin: 0;
    padding: 6px 5% 18px;
    line-height: 24px;
    height: auto;
    min-height: 0;
    width: 100%;
    box-sizing: border-box;
    font-size: 12px;
}

#userInput p {
    font-size: small;
    line-height: normal;
}

.convertForm {
    display:none;
}

#sideMenu,table {
    margin:0 0;
}

#sideMenu.homeSideMenu {
    width: 100%;
    max-width: 100%;
    margin: 0;
}

#sideMenu.homeSideMenu a.featureConv,
#sideMenu.homeSideMenu a.typeConv {
    display: block;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    margin: 1px 0;
    min-height: 50px;
    height: auto;
    line-height: 50px;
    padding: 0 0 0 18%;
    font-size: 16px;
    font-weight: bold;
    text-decoration: none;
    color: #ffffff;
    background-repeat: no-repeat;
    background-position: 5px 5px;
}

#sideMenu.homeSideMenu a.featureConv {
    background-color: #3e7589;
    padding-top: 0;
}

#sideMenu.homeSideMenu a.typeConv.unitConv {
    background-color: #595959;
}

#sideMenu.homeSideMenu a.featureConv:hover,
#sideMenu.homeSideMenu a.typeConv.unitConv:hover {
    background-color: #413f3f;
}

table {
    width:98%;
    margin:10px 1%;
}

#search li,#softSearch li {
    background-color: #fff;
}

#search a,#softSearch a {
    color: #333333;
    display: block;
    font-size: 17px;
    line-height: 50px;
    margin: 1px 0;
    padding: 0 20px;
    width: 90%;
    text-decoration:none;
    font-weight:bold;
}

.mobileLink {
    min-height:50px;
    overflow-x: hidden;
}

#suggested,#suggestedTable {
    width:100%;
}

#suggested,#suggestedTable {
    padding:0;    
}

.tower {
    display:none;
}

.col {
    float:none;
}

.typeDef {
    width:90%;
    padding:5%;
    font-size:18px;
}

h2 a, p a, h3 a {
    color: #064d6b;
    text-decoration: none;
}

ul,li {
    float:none;
    width:90%;
}

#search, #softSearch {
    width:100%;
}

#search li, #softSearch li {
    width:90%;
}

#search ol li a, #softSearch ol li a {
    display:block;
}

footer {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    box-sizing: border-box;
}

#menulinks,
.footerText {
    width: 100%;
    max-width: none;
    box-sizing: border-box;
}

#conversionlinks, #promolinks {
    position:relative;
    height:180px;
    background-color:inherit;
}

#langlinks {
    position:relative;
    height:auto;
    min-height:0;
    background-color:inherit;
}

#menulinks a, #langlinks a, #conversionlinks a, #promolinks a {
    background-color: #a6a6a6;
    color: #333333;
    display: block;
    text-decoration: none;
    width: 100%;
    line-height:50px;
    padding:0 5%;
    float:none;
    margin:2px 3%;
}

#langlinks ul {
    padding: 0;
    margin: 0;
    width: 100%;
    list-style: none;
}

#langlinks li {
    width: 100%;
    max-width: 100%;
    float: none;
    box-sizing: border-box;
}

#langlinks ul li a {
    display: block;
    width: auto;
    max-width: none;
    margin: 0 3%;
    padding: 12px 10px;
    line-height: 1.3;
    background-color: #3e7589;
    color: #fff;
    border-bottom: 1px solid #e3e3e3;
    box-sizing: border-box;
    white-space: normal;
}

#langlinks li:last-child a {
    border-bottom: none;
}

.blueBg {
    background-color: transparent;
    height: auto;
}

#menulinks {
    min-height:0;
    height:auto;
    background-color: #a6a6a6;
    padding: 8px 0 0;
}

#conversionlinks {
    min-height:650px;
}

.featureTypes p,.tableTypes p {
    width:87.6%;
}

#inlinesearch {
    float: right;
    margin:2% 5%;
    height:35px;
    width:50%;
}

#convertBannerSpace {
    display:block;
    background-color:#FF0000;
    width:300px;
    height:250px;
    margin:0 auto;
}

.left {
    min-width: 300px;
}

/* iOS keypad */

#keypadarea {
    display:block;

}

.blankSpace {
    background-color:#fff;
    height:50px;
    float:left;
    border-bottom: solid 1px #8c8c8c;
    border-right: solid 1px #8c8c8c;
    width:100%;
}

#keyboard {
    font-family:Arial,Helvetica,sans-serif;
    position:fixed;
    bottom:0px;
    display:none;
    width:100%;
    border-top: solid 1px #909497;
}

#status {
    background-color:#eff0f1;
    height:40px;
}

#status a {
    font-size: 36px;
    color:#bfbfc0;
    text-decoration:none;
    line-height:40px;
    margin:0 0 0 20px;
}

#status .doneButton {
    color:#007aff;
    float:right;
    margin:0 20px;
    font-size:18px;
    font-weight:bold;
}
           
.keybutton {
    background-color:#fff;
    max-height:45px;
    float:left;
    border-bottom: solid 1px #8c8c8c;
    border-right: solid 1px #8c8c8c;
    min-width:33.12%;
    font-size:24px;
    color:#000000;
    text-decoration:none;
    text-align: center;
    line-height:45px;
}

.last {
    border-right:none;
}

.desktopField {
    display:none;
}

.mobileField {
    display:block;
}   

#resultBanner,#contentArea,#lowerAd,#contentAd {
    width:300px;
    margin:5px auto;
    background-image:none;
    min-width: 0px;
}


#contentArea,#lowerAd {
    height:250px;
}

#lowerAd {
    height:auto;
}

#contentArea {
    height:auto;
    margin:20px auto;
}

.fractionSlash {
    display:none;
}

fractionSlashMob {
    display:block;
}

.searchField {
    font-size: 24px;
    height: 39px;
    border: 1px solid #064d6b;
    padding: 0 0 0 3%;
    width: 40%;
    box-sizing: border-box;
}

select.searchField,
#userInput select.searchField,
#userInput select#unitFrom,
#userInput select#unitTo,
#userInput select#unitType,
#userConvert select.searchField {
    -webkit-appearance: none;
    appearance: none;
    background-color: #fff;
    color: #333;
    border-radius: 0;
    padding-right: 2rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' stroke='%23064d6b' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 12px 8px;
}

#userInput select.searchField,
#userInput select#unitFrom,
#userInput select#unitTo,
#userInput select#unitType,
#userConvert select.searchField {
    width: 100%;
    max-width: 100%;
    margin: 0;
}

#searchInput input.searchField {
    -webkit-appearance: none;
    appearance: none;
    background-color: #fff;
    color: #333;
    border: 1px solid #064d6b;
    border-radius: 0;
    box-sizing: border-box;
}

#argumentConv1Mob,#argumentConv2Mob {
    width:40%;
}

#argumentConv2aMob,#argumentConv2bMob {
    width:10%;
}

#argumentConv2aMob {
    margin-left:10px;
}

.note {
    display:none;
}

.homeIcon {
    display:block;
    position:relative;
    top:-30px;
    left:85%;
    width:            35px;
    height:           30px;
}

/* Ruler home icon: .homeIcon relative positioning must not override .home fixed placement */
header #logo a.home {
    position: fixed;
    top: 20px;
    right: 20px;
    left: auto;
    width: 40px;
    height: 30px;
    z-index: 102;
}

#webmaster {
    display:none;
}

#towerAd {
    display:block;
    min-height: 160px;
}

.fixTop {
    position:fixed;
    top:0px;
}

.footerText {
    background-color:#413f3f;
    color:#fff;
    padding: 10px 10px;
}

.footerText a {
    color:#ffffcc;
    text-decoration: underline;
}

#adfree, #helpmetric {
    display: none;
}

/* Home page: keep fixed header + language bar; H1 scrolls with content */
body.home-page #homePageH1 {
    position: static !important;
    top: auto !important;
    left: auto !important;
}

body.home-page .main {
    padding-top: 91px;
    background-color: #e3e3e3;
}

body.home-page #userInput,
body.home-page #searchInput {
    width: 100%;
    box-sizing: border-box;
}

body.home-page #userInput {
    margin-top: 0;
    padding-top: 6px;
    padding-bottom: 14px;
}

#mainLinks #homePageH2 {
    color: #4c4c4c;
    margin: 0 0 10px 0;
    padding: 0 5%;
}

#mainLinks a.typeConv {
    display: flex;
    align-items: center;
    height: 50px;
    min-height: 50px;
    max-height: 50px;
    line-height: 1.25;
    font-size: 15px;
    white-space: normal;
    overflow: hidden;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    margin: 1px 0;
    padding: 2px 10px 2px 18%;
    background-position: 5px center;
}

#mainLinks a.typeConv.greybg {
    background-color: #595959;
}

body.home-page .linkDiv {
    margin-top: 0;
}

body.home-page .linkDiv > a.typeConv:first-child {
    margin-top: 0;
}

/* Links page: avoid global fixed h1; use .linksPageTitle on mobile instead */
body.links-page .main,
main.main:has(> .linksPageTitle) {
    padding-top: 100px !important;
    background-color: #e3e3e3 !important;
}

body.links-page .linksPageTitle {
    display: block;
    margin: 0;
    padding: 5px 8px 8px;
    color: #fff;
    background-color: #3e7589;
    font-size: 18px;
    font-weight: bold;
    line-height: 1.3;
    text-align: center;
    box-sizing: border-box;
}

/* Terms / links: body text above type nav (DOM order + flex for safety) */
body.links-page main.main,
main.main:has(> .linksPageTitle) {
    display: flex;
    flex-direction: column;
}

body.links-page .linksPageTitle,
main.main:has(> .linksPageTitle) > .linksPageTitle {
    order: 0;
    flex-shrink: 0;
}

body.links-page article#information,
main.main:has(> .linksPageTitle) article#information,
body.links-page #popLinks,
main.main:has(> .linksPageTitle) #popLinks {
    order: 1;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

body.links-page #sideMenu,
main.main:has(> .linksPageTitle) #sideMenu {
    order: 2;
    width: 100%;
    max-width: 100%;
    float: none;
    clear: both;
    margin-bottom: 0;
}

/* Terms page: match links page text gutters (avoid .typeDef 90% width clipping) */
body.links-page article#information.termsPageContent,
main.main:has(> .linksPageTitle) article#information.termsPageContent {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 8px 5% 12px;
    box-sizing: border-box;
    font-size: 18px;
    background-color: #e3e3e3;
}

/* Site map / terms: in-flow title (see head.blade.php); no extra top pad on article needed */
body.links-page .linksPageTitle,
main.main:has(> .linksPageTitle) > .linksPageTitle {
    flex-shrink: 0;
}

body.links-page article#information.termsPageContent ul,
body.links-page article#information.termsPageContent li {
    width: auto;
    max-width: 100%;
    box-sizing: border-box;
    padding-right: 0;
}

body.links-page article#information.termsPageContent p {
    margin: 0 0 1em;
}

/* Legacy static terms.htm (mainHome): same visual order on mobile */
@media screen and (max-width: 736px) {
    .main.mainbg {
        display: flex;
        flex-direction: column;
    }

    .main.mainbg > h1 {
        order: 0;
    }

    .main.mainbg > article.typeDef,
    .main.mainbg > article.mainHome {
        order: 1;
        width: 100% !important;
        max-width: 100% !important;
        float: none !important;
    }

    .main.mainbg > #sideMenu {
        order: 2;
        float: none !important;
        clear: both;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }
}

body.links-page #linksPageH1,
main.main:has(> #linksPageH1) #linksPageH1 {
    position: static !important;
    top: auto !important;
    left: auto !important;
    border-top: none;
}

/* Conversion calculators page: same mobile title treatment as links page */
body.calc-page .main,
main.main:has(> .calcPageTitle) {
    padding-top: 100px !important;
    background-color: #e3e3e3 !important;
}

body.calc-page .calcPageTitle {
    display: block;
    margin: 0;
    padding: 5px 8px 8px;
    color: #fff;
    background-color: #3e7589;
    font-size: 18px;
    font-weight: bold;
    line-height: 1.3;
    text-align: center;
    box-sizing: border-box;
}

body.calc-page #calcPageH1,
main.main:has(> #calcPageH1) #calcPageH1 {
    position: static !important;
    top: auto !important;
    left: auto !important;
    border-top: none;
}

/* BMI calculator: in-flow page title (fixed .calcPageTitle clipped "Enter height") */
body.calc-page .calcPageTitle,
main.main .calcPageTitle {
    position: static !important;
    top: auto !important;
    left: auto !important;
    z-index: auto !important;
}

/* BMI calculator page only — tight stack under header, one teal panel */
body.bmi-calc-page .main {
    padding-top: 60px !important;
    background-color: #3e7589 !important;
}

body.bmi-calc-page:has(#language select) .main {
    padding-top: 98px !important;
}

body.bmi-calc-page #language:empty,
body.bmi-calc-page #language:not(:has(select)) {
    display: none !important;
    min-height: 0 !important;
    height: 0 !important;
    padding: 0 !important;
    border: none !important;
}

body.bmi-calc-page .left.col,
body.bmi-calc-page .left {
    border-top: none;
    margin-top: 0;
}

body.bmi-calc-page .bmiPanelTitle {
    display: block;
    margin: 0;
    padding: 8px 5% 10px;
    color: #fff;
    background-color: #3e7589;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
    box-sizing: border-box;
}

body.bmi-calc-page #userConvert.bmiUserConvert {
    margin-top: 0;
    padding-top: 0;
}

body.bmi-calc-page .bmiBelowPanel {
    background-color: #e3e3e3;
}

/* Metric conversion table hub: title + teal box stack in content (avoids fixed h1 clipping the label) */
body.table-page .main,
body.type-table-page .main {
    padding-top: 91px !important;
    background-color: #e3e3e3 !important;
}

/* Converter index: same stacked title + teal box as table hub */
body.converter-page .main {
    padding-top: 98px !important;
    background-color: #e3e3e3 !important;
}

body.converter-page .tablePageTitle {
    display: block;
    position: static !important;
    top: auto !important;
    left: auto !important;
    margin: 0;
    padding: 5px 8px 8px;
    color: #fff;
    background-color: #3e7589;
    font-size: 18px;
    font-weight: bold;
    line-height: 1.35;
    text-align: center;
    box-sizing: border-box;
    overflow-wrap: break-word;
}

body.converter-page #userInput.converterTypePanel {
    width: 100%;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    padding: 10px 3% 20px;
    box-sizing: border-box;
}

body.converter-page #userInput.converterTypePanel #convertForm {
    height: auto !important;
}

body.converter-page #userInput.converterTypePanel .unitFieldLabel {
    display: block;
    margin: 0 0 0.5em;
    color: #fff;
    font-size: 15px;
    font-weight: bold;
    white-space: normal;
    overflow-wrap: break-word;
    line-height: 1.35;
}

body.converter-page #userInput.converterTypePanel p {
    margin: 0;
}

body.table-page .tablePageTitle,
body.type-table-page .tablePageTitle {
    display: block;
    position: static !important;
    top: auto !important;
    left: auto !important;
    margin: 0;
    padding: 5px 8px 8px;
    color: #fff;
    background-color: #3e7589;
    font-size: 18px;
    font-weight: bold;
    line-height: 1.35;
    text-align: center;
    box-sizing: border-box;
    overflow-wrap: break-word;
}

body.table-page #userInput.converterTypePanel {
    width: 100%;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    padding: 10px 3% 20px;
    box-sizing: border-box;
}

body.table-page #userInput.converterTypePanel #convertForm {
    height: auto !important;
}

body.table-page #userInput.converterTypePanel .unitFieldLabel {
    display: block;
    margin: 0 0 0.5em;
    color: #fff;
    font-size: 15px;
    font-weight: bold;
    white-space: normal;
    overflow-wrap: break-word;
    line-height: 1.35;
}

body.table-page #userInput.converterTypePanel p {
    margin: 0;
}

/* Type / unit table index: full-width teal box, modest space below select */
body.type-table-page #userInput {
    width: 100%;
    height: auto;
    min-height: 0;
    padding: 10px 3% 26px;
    box-sizing: border-box;
}

body.type-table-page #userInput #convertForm {
    height: auto;
}

body.type-table-page #userInput p {
    margin: 0;
}

body.type-table-page #userInput .unitFieldLabel {
    color: #fff !important;
    font-size: 15px !important;
    font-weight: bold;
    line-height: 1.35;
    margin: 0 0 0.5em;
    display: block;
}

/* Unit table pages (two selects): full-width teal box, space below second dropdown */
body.type-table-page #userInput.unitSelectPanel {
    width: 100%;
    padding: 10px 3% 38px;
}

body.type-table-page #userInput.unitSelectPanel #convertForm {
    height: auto !important;
}

/* Unit-to-unit table page: title is .tablePageTitle above the teal box */
body.type-table-page {
    overflow-x: hidden;
    max-width: 100vw;
}

body.type-table-page .main,
body.type-table-page #metricConversionTable {
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
}

body.type-table-page #metricConversionTable .tableColumn {
    float: none;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100%;
    clear: both;
    margin: 0;
}

body.type-table-page #metricConversionTable > h1 {
    display: none;
}

body.type-table-page #metricConversionTable {
    margin: 0;
}

body.type-table-page .underButton.calcIcon {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

body.type-table-page #metricConversionTable #visibleControls .tableControlPanel .control.tableControl {
    flex-direction: column;
    align-items: stretch;
    height: auto;
    min-height: 0;
    line-height: 1.3;
    padding: 8px 2.5%;
}

body.type-table-page #metricConversionTable #visibleControls .tableControlPanel .control.tableControl input.controlOptions,
body.type-table-page #metricConversionTable #visibleControls .tableControlPanel .control.tableControl select.controlOptions {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
}

/* Type / unit table index: slightly larger links, still max 2 lines */
body.type-table-page #mainLinks a.typeConv {
    font-size: 14px;
    line-height: 1.22;
    min-height: 50px;
    height: auto;
    max-height: 52px;
    padding: 4px 10px 4px 16%;
    overflow: hidden;
}

.featureTypes,
.featureTypesConv,
.tableTypes {
    padding-top: 0;
    padding-bottom: 0;
}

.featureTypes .typeConv {
    display: flex;
    align-items: center;
    height: auto;
    min-height: 50px;
    line-height: 1.3;
    padding-top: 0;
    padding-bottom: 0;
}

/* Bottom link lists: dark grey unit links (#595959), same as type selection page */
.linkDiv .featureTypes a.typeConv.unitConv {
    background-color: #595959;
}

.linkDiv .featureTypes a.typeConv.unitConv:hover {
    background-color: #413f3f;
}

/* Mobile bottom nav: one consistent list (no gaps / mixed inline-block rows) */
.linkDiv {
    margin-top: 0;
}

.linkDiv .featureTypes {
    margin: 0 auto;
    width: 94.8%;
    min-height: 0;
}

.linkDiv .featureTypes + .featureTypes {
    margin-top: 0;
}

.linkDiv .sideNav {
    margin: 0;
}

.linkDiv .featureTypes a.typeConv {
    display: flex;
    align-items: center;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    margin: 1px 0;
    min-height: 50px;
    height: auto;
    line-height: 1.3;
    padding: 8px 5% 8px 18%;
    font-size: 16px;
    font-weight: bold;
    white-space: normal;
    overflow: hidden;
    text-overflow: ellipsis;
}

.linkDiv .featureTypes a.typeConv.nowrap,
.linkDiv .featureTypes a.typeConv.removeIcon,
.linkDiv .featureTypes a.typeConv.mobileWidth88 {
    display: flex;
    width: 100%;
    max-width: 100%;
    padding: 8px 5% 8px 18%;
}

.linkDiv .featureTypes a.typeConv.bluebg {
    background-color: #3e7589;
}

/* Unit selection page: stack From/To selects, full width of teal box */
#userInput.unitSelectPanel #convertForm {
    height: auto;
}

#userInput.unitSelectPanel .unitSelectFields {
    display: flex;
    flex-direction: column;
    gap: 0.5em;
    margin: 0;
}

#userInput.unitSelectPanel select#unitFrom,
#userInput.unitSelectPanel select#unitTo,
#userInput.unitSelectPanel select#unitType {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    margin: 0;
}

#userInput.unitSelectPanel .betweenSelectGap {
    line-height: 20px;
    margin: 0;
    padding: 0;
}

#userInput.unitSelectPanel {
    height: auto;
    min-height: 0;
    padding: 8px 3% 20px;
    box-sizing: border-box;
}

#userInput.unitSelectPanel .unitFieldLabel {
    margin-top: 0;
}

/* Converter index: comfortable padding around the type dropdown */
#userInput.converterTypePanel {
    height: auto;
    min-height: 0;
    padding: 8px 3% 20px;
    box-sizing: border-box;
}

#userInput.converterTypePanel #convertForm {
    height: auto;
}

#userInput.converterTypePanel .unitFieldLabel {
    margin-top: 0;
}

#userInput.converterTypePanel p {
    margin: 0.35em 0 0;
}

/* Unit-to-unit pages: Accuracy section */
.control.precision-section {
    background-color: #595959;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.control.precision-section label {
    display: block;
    font-size: 15px;
    line-height: 1.3;
    margin: 0;
    flex-shrink: 0;
}

.control.precision-section select#sigfig,
.control.precision-section select.sigfigSelect {
    display: block;
    width: 200px;
    min-width: 200px;
    max-width: 200px;
    box-sizing: border-box;
    height: 39px;
    margin: 0;
    float: none;
    flex-shrink: 0;
    background-color: #fff;
    color: #000;
    border: 1px solid #b8b8b8;
    border-radius: 0;
    font-size: 16px;
    font-weight: normal;
    padding: 0 2rem 0 0.75rem;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' stroke='%23000000' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 12px 8px;
}

/* Conversion table controls: Starting value, Increment, Accuracy, etc. */
.control.tableControl {
    background-color: #595959;
}

/* Conversion table controls: align starting value input with selects */
#metricConversionTable #visibleControls .tableControlPanel {
    clear: both;
    box-sizing: border-box;
    width: 99%;
    margin: 0 0.5%;
    padding: 0 0.5% 0 0.5%;
}

#metricConversionTable #visibleControls .tableControlPanel .control.tableControl {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    box-sizing: border-box;
    width: 100%;
    max-width: none;
    min-width: 0;
    margin: 1px 0 0 0;
    padding: 6px 2.5% 6px 2.5%;
    float: none;
    line-height: 1.2;
}

#metricConversionTable #visibleControls .tableControlPanel .control.tableControl input.controlOptions,
#metricConversionTable #visibleControls .tableControlPanel .control.tableControl select.controlOptions {
    float: none;
    margin: 0 !important;
    box-sizing: border-box;
    height: 30px;
    width: 200px;
    min-width: 200px;
    max-width: 200px;
    flex-shrink: 0;
    background: #fff;
    color: #444c4c;
    border: 1px solid #b8b8b8;
    font-size: 14px;
    padding: 2px 5px;
}

#metricConversionTable #visibleControls .tableControlPanel .control.tableControl select.controlOptions {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 28px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%23444c4c' d='M1.41 0L6 4.58 10.59 0 12 1.41l-6 6-6-6z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 12px 8px;
}

/* Information article headings */
article#information h2 {
    color: #333333;
    font-weight: normal;
}

article#information h2 a {
    color: #333333;
    font-weight: normal;
}

article#information a {
    color: #064d6b;
    text-decoration: underline;
}

/* App download promo after conversion */
#appPromo h2,
#appPromo h2 a,
#appPromo p,
#appPromo p a,
#appPromo a {
    color: #333333;
    text-decoration: none;
}

#appPromo u {
    color: #333333;
}

/* BMI calculator (template 19) — mobile layout */
body.calc-page .bmiUserConvert {
    width: 100%;
    box-sizing: border-box;
}

body.calc-page .bmiUserConvert .bmiForm {
    margin: 0 0 14px;
    padding: 0;
}

body.calc-page .bmiUserConvert .bmiFormHeading,
body.calc-page #userConvert.bmiUserConvert h2 {
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 10px;
    padding: 0;
    overflow: visible;
    height: auto;
    min-height: 0;
}

body.calc-page .bmiFieldPair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    width: 100%;
    margin: 0 0 4px;
    box-sizing: border-box;
}

body.calc-page .bmiFieldPair[hidden] {
    display: none !important;
}

body.calc-page .bmiUserConvert .bmiForm input.bmiField.mobileField {
    display: block;
    width: 100% !important;
    min-width: 0;
    min-height: 48px;
    height: 48px;
    margin: 0 !important;
    padding: 10px 12px;
    font-size: 18px;
    line-height: 1.2;
    box-sizing: border-box;
    border: 1px solid #064d6b;
    background-color: #fff;
    color: #333;
    border-radius: 4px;
    -webkit-appearance: none;
    appearance: none;
}

body.calc-page .bmiBelowPanel {
    background-color: #e3e3e3;
    padding: 12px 4% 20px;
    width: 100%;
    box-sizing: border-box;
}

body.calc-page .bmiCategoriesDesktop {
    display: none;
}

body.calc-page .bmiScaleMobile {
    display: none;
    margin: 12px 0;
}

body.calc-page .bmiScaleMobile[aria-hidden="false"] {
    display: block;
}

body.calc-page .bmiScaleLabel {
    margin: 0 0 8px;
    font-size: 14px;
    font-weight: 700;
    color: #333;
}

body.calc-page .bmiScaleTrackWrap {
    position: relative;
    width: 100%;
    padding-bottom: 22px;
}

body.calc-page .bmiScaleTrack {
    display: flex;
    width: 100%;
    height: 28px;
    border: 1px solid #555;
    border-radius: 4px;
    overflow: hidden;
}

body.calc-page .bmiScaleSeg {
    flex: 1 1 25%;
    min-width: 0;
    height: 100%;
}

body.calc-page .bmiScaleSeg--under {
    background-color: #8888ff;
}

body.calc-page .bmiScaleSeg--normal {
    background-color: #00cc00;
}

body.calc-page .bmiScaleSeg--over {
    background-color: #ff8888;
}

body.calc-page .bmiScaleSeg--obese {
    background-color: #7a1010;
}

body.calc-page .bmiScaleIndicator {
    position: absolute;
    top: 32px;
    left: 0;
    width: 0;
    height: 0;
    margin: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 14px solid #333;
    transform: translateX(-50%);
}

body.calc-page .bmiCategoriesMobile {
    list-style: none;
    margin: 0 0 16px;
    padding: 0;
}

body.calc-page .bmiCatRow {
    margin: 0 0 8px;
    padding: 12px 14px;
    font-size: 16px;
    line-height: 1.35;
    font-weight: 700;
    border-radius: 4px;
    box-sizing: border-box;
}

body.calc-page .bmiCatRange {
    font-weight: 700;
}

body.calc-page .bmiCatRow--under {
    background-color: #8888ff;
    color: #1a1a2e;
}

body.calc-page .bmiCatRow--normal {
    background-color: #00cc00;
    color: #1a1a1a;
}

body.calc-page .bmiCatRow--over {
    background-color: #ff8888;
    color: #1a1a1a;
}

body.calc-page .bmiCatRow--obese {
    background-color: #7a1010;
    color: #fff;
}

body.calc-page #result {
    display: none;
    margin: 0 0 12px;
    padding: 12px 0;
    background-color: #e3e3e3;
}

body.calc-page #result:not([hidden]) {
    display: block;
}

body.calc-page #answer {
    font-size: 9vw;
    line-height: 1.2;
    margin: 0;
    text-align: center;
    font-weight: 700;
    color: #333;
}

body.calc-page .bmiAnswerCategory {
    margin: 4px 0 0;
    text-align: center;
    font-size: 9vw;
    line-height: 1.2;
    font-weight: 700;
    color: #333;
}

body.calc-page #paramDetail {
    display: block;
    margin: 8px 0 0;
    text-align: center;
    font-size: 14px;
    color: #333;
}

body.calc-page .bmiBelowPanel article#information {
    color: #333;
}

body.calc-page .bmiBelowPanel article#information p {
    color: #333;
}


.conversionTableLink {
    display: inline-block;
    padding: 12px 32px;
    border-radius: 6px;
    background-color: #a35c18;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    margin:0;
}

.conversionTableLink:hover, .conversionTableLink:focus-visible {
    background-color: #b97222;
    color: #ffffff;
    text-decoration: none;
}

.conversionTableLinkContainer {
    margin:0 0 15px 0;
    text-align: center;
    background-color:#f5f5f5;
}