/* Universal styles */
* {
    box-sizing: border-box;
}

/* Global styles for the document */
body {
    background-color: #90C7E3;
    color: #666666;
    font-family: Verdana, Arial, sans-serif;
    margin: 0;
}

/* Styles for the header */
header {
    background-color: #002171;
    color: #FFFFFF;
    font-family: Georgia, serif;
    padding: 1em;
}

h1 {
    text-align: center;
    font-size: 1.5em;
    color: #FFFFFF;
}

/* Header and nav link styling */
header a, nav a {
    text-decoration: none;
    color: #FFFFFF;
}

/* Nav styles */
nav {
    text-align: center;
    font-size: 1.2em;
    background-color: #FFFFFF;
}

nav ul {
    display: flex;
    flex-direction: column;
    list-style-type: none;
    padding: 0;
    margin: 0;
}

nav li {
    padding: 0.5em 1em;
    width: 100%;
    border-bottom: 1px solid #ccc;
}

/* Nav link states */
nav a:link {
    color: #5C7FA3;
}

nav a:visited {
    color: #344873;
}

nav a:hover {
    color: #A52A2A;
}

/* Single-column display for narrow viewports */
form {
    display: flex;
    flex-direction: column;
    padding-left: 1em;
    width: 80%;
}

input, textarea {
    margin-bottom: 0.5em;
}

#reshero {
    height: 300px;
    background-image: url('ocean.jpg');
    background-size: 200% 100%;
    background-repeat: no-repeat;
}

/* Hero section styles */
#homehero, #yurthero, #trailhero {
    height: 300px;
    background-size: 200% 100%;
    background-repeat: no-repeat;
}

#homehero {
    background-image: url('coast.jpg');
}

#yurthero {
    background-image: url('yurt.jpg');
}

#trailhero {
    background-image: url('trail.jpg');
}

/* Section and Wrapper */
#wrapper {
    background-color: #FFFFFF;
}

main, section {
    padding: 0.5em 1em;
}

/* Footer */
footer {
    font-size: 0.70em;
    font-style: italic;
    text-align: center;
    padding: 1em;
    background-color: #FFFFFF;
}

/* Table styles */
table {
    border-collapse: collapse;
    width: 100%;
}

th, td {
    padding: 5px;
    border: 1px solid #3399CC;
    text-align: center;
}

.text {
    text-align: left;
}

tr:nth-of-type(even) {
    background-color: #DFEDF8;
}

/* Responsive adjustments */
@media (min-width: 600px) {
    h1 {
        font-size: 2em;
        letter-spacing: 0.25em;
    }

    nav ul {
        flex-direction: row;
        justify-content: space-around;
        padding-right: 2em;
    }

    nav li {
        width: 12em;
        border-bottom: none;
    }

    #flow {
        display: flex;
        flex-direction: row;
    }

    #mobile {
        display: none;
    }

    #desktop {
        display: inline;
    }

    #homehero, #yurthero, #trailhero {
        background-size: 100% 100%;
    }

    section {
        padding: 2em;
    }

    /* Two-column grid display for form */
    form {
        width: 60%;
        display: grid;
        grid-template-columns: 10em 1fr;
        gap: 1em;
    }

    /* Attribute selector for the submit button */
    input[type="submit"] {
        grid-column: 2;
        width: 9em;
    }

    #reshero {
        background-size: 100% 100%;
    }
}

@media (min-width: 1024px) {
    body {
        background-image: linear-gradient(to bottom, #FFFFFF 20%, #90C7E3 60%, #FFFFFF 100%);
    }

    nav ul li {
        padding: 0 10%;
    }

    #wrapper {
        margin: auto;
        width: 80%;
    }
}
