* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

a:link { color: Blue; }
a:hover { color: Red; }

body {
    background-color: LightGray;
    font-size: 100%;
    text-align: center;
    line-height: 1.4;
    padding: 10px;
    font-family: Verdana, Arial, Trebuchet MS, Geneva, sans-serif;
}

button {
    background-color: inherit;
    font-weight: bold;
    font-size: 125%;
    outline: none;
    padding: 5px 0;
    border-width: medium;
    border-style: solid;
    border-color: #804000;
    color: black;
    font-family: serif;
    text-align: center;
}

.button3:hover {
    border-color: black;
    color: red;
    background-color: #efeeed;
}

h1 {
    color: #000000;
    font-family: Times, Times New Roman, Georgia, serif;
    padding: 20px 0 10px 0;
    text-align: center;
    font-size: 120%;
}

h2 {
    color: #000000;
    font-family: Times, Verdana, Arial, Trebuchet MS, Geneva, sans-serif;
    text-align: center;
    margin-bottom: 10px;
    font-size: 125%;
}

p {
    color: black;
    font-family: Verdana, Arial, Trebuchet MS, Geneva, sans-serif;
    font-size: 100%;
    border: none;
    line-height: 1.6;
    padding: 5px 0;
}

strong { 
    font-weight: bold;
}

sup {
    vertical-align: super;
    font-size: smaller;
}

sub {
    vertical-align: sub;
    font-size: smaller;
}

/* Form Controls Base Styling */
input[type="text"],
input[type="number"],
select {
    width: 20%;
    min-width: 220px;
    max-width: 320px;
    min-height: 40px;
    padding: 6px 12px;
    font-size: 1rem;
    display: block;
    margin-right: auto;
    margin-left: auto;
    text-align: center;
    background-color: #ffffcc;
    border-radius: 6px;
    border: 1px solid #999;
    transition: border-color 0.2s, box-shadow 0.2s;
}

select {
    text-align-last: center;
}

input:focus, select:focus {
    outline: none;
    border-color: #0056b3;
    box-shadow: 0 0 5px rgba(0, 86, 179, 0.5);
}

.centerPage {
    text-align: center;
    margin-right: auto;
    margin-left: auto;
    font-size: 100%;
}

option {
    text-align: center;
}

table, th, td {
    color: black;
    font-family: Verdana, Arial, Trebuchet MS, Geneva, sans-serif;
    text-align: left;
}

.greyMatter {
    color: darkgray;
}

/* Sticky Navigation Header */
.myNav {
    background-color: LightGray;
    width: 100%;
    padding: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    border-bottom: 1px solid #ccc;
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.lornmac {
    font-size: 170%;
}

.lornmac a {
    text-decoration: none;
    color: black;
    font-family: Times, Times New Roman, Georgia, serif;
}

/* Navigation Button Base Styles */
.styled, .styled1, .styled2, .styled3, .styled4 {
    flex: 0 1 120px;
    width: 25%; /* was 20 */
    min-width: 100px;
    max-width: 180px;
    height: 38px;
    padding: 5px;
    font-size: 0.9rem;
    font-weight: bold;
    outline: none;
    border-width: medium;
    border-style: solid;
    color: black;
    text-align: center;
    display: inline-block;
    cursor: pointer;
}

.styled {
    border-radius: 20px;
    border-color: blue;
    background-color: #e0e0e0;
    font-weight: normal;
    border-width: thin;
}

.styled:hover {
    border-color: Orange;
    border-width: medium;
    color: White;
    font-weight: bold;
    background-color: grey;
}

.styled1 {
    border-radius: 30px 5px 30px 5px;
    border-color: orchid;
    background-color: yellow;
}

.styled1:hover {
    border-color: yellow;
    color: black;
    font-weight: normal;
    background-color: orchid;
}

.styled2 {
    border-radius: 30px 5px 30px 5px;
    border-color: blue;
    background-color: Orange;
}

.styled2:hover {
    border-color: orange;
    color: white;
    font-weight: normal;
    background-color: blue;
}

.styled3 {
    border-radius: 30px 5px 30px 5px;
    border-color: green;
    background-color: #ff3333;
}

.styled3:hover {
    border-color: #ff3333;
    color: white;
    font-weight: normal;
    background-color: green;
}

.styled4 {
    border-radius: 30px 5px 30px 5px;
    border-color: White;
    background-color: Black;
    color: White;
}

.styled4:hover {
    border-color: Black;
    color: Black;
    font-weight: normal;
    background-color: White;
}

/* Report Action Buttons */
.styled-action-btn {
    width: 20%;
    min-width: 220px;
    max-width: 320px;
    min-height: 40px;
    padding: 8px 12px;
    margin: 6px auto;
    font-size: 0.95rem;
    font-weight: bold;
    background-color: #0056b3;
    color: white;
    border: 2px solid #003d80;
    border-radius: 8px;
    cursor: pointer;
    display: inline-block;
}

.styled-action-btn:hover {
    background-color: #003d80;
    color: #ffffff;
}

.btnBar {
    text-align: center !important;
}

/* Outer Main Container */
.calc-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 10px;
}

.box {
    border: 3px solid black;
    color: black;
    background-color: white;
    margin-right: auto;
    margin-left: auto;
    padding: 20px;
    margin: 20px;
    border-radius: 25px;
}

/* Text Report Output Container */
#resultsOutput {
    white-space: pre-wrap;
    word-break: break-word;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1.1rem; /* was 1.2rem */
    line-height: 1.4;
    text-align: left;
    background-color: #ffffff;
    border: 2px solid #ccc;
    padding: 15px;
    margin: 20px auto;
    border-radius: 6px;
    max-width: 1000px; /* was 800px */
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    overflow-x: auto;
}

/* Responsive Media Queries */

/* Mobile Phones */
@media only screen and (max-width: 500px) {
    .mobileDontShowThis { display: none; }

    input[type="text"],
    input[type="number"],
    select {
        width: 85%;
        min-width: unset;
    }

    .styled, .styled1, .styled2, .styled3, .styled4 {
        flex: 1 1 28%;
        width: auto;
        min-width: unset;
        font-size: 0.8rem;
        padding: 4px;
    }

    .styled-action-btn {
        width: 85%;
        min-width: unset;
    }

    #resultsOutput {
        font-size: 0.85rem;
        padding: 10px;
    }
}

/* Tablets / iPads */
@media only screen and (min-width: 501px) and (max-width: 960px) {
    .mobileDontShowThis { display: none; }
    .DontShowThis { display: none; }

    input[type="text"],
    input[type="number"],
    select {
        width: 45%;
    }

    .styled, .styled1, .styled2, .styled3, .styled4 {
        flex: 0 1 130px;
        width: auto;
    }

    .styled-action-btn {
        width: 45%;
    }
}

/* Desktop & Wide Screens */
@media only screen and (min-width: 961px) {
    input[type="text"],
    input[type="number"],
    select {
        width: 25%; /* was 20 */
        max-width: 320px;
    }

    .styled, .styled1, .styled2, .styled3, .styled4 {
        width: 25%; /* was 20 */
        max-width: 180px;
    }

    .styled-action-btn {
        width: 25%; /* was 20 */
        max-width: 320px;
    }
}

/* Footer */
footer {
    height: auto;
    width: auto;
    padding: 5px;
    font-size: 75%;
    text-align: center;
    font-family: Verdana, Arial, Trebuchet MS, Geneva, sans-serif;
    margin-bottom: 1%;
    margin-top: 1%;
}

.hiddenUntilPrinted { display: none; }

/* Print Overrides */
@media print {
    .myPageBreaker { page-break-before: always; }
    p.pageBreak { page-break-before: always; }

    h1 {
        margin-bottom: 40px;
        text-align: center;
    }

    .noPrint { display: none; }
    .hiddenUntilPrinted { display: block; }

    footer {
        padding: 0;
        margin: 0;
        text-align: center;
    }

    a:link, a:visited, a:hover {
        color: #000000;
        text-decoration: none;
    }
}