/* =========================================================
   Cairnlea Corner Cafe - Stylesheet
   Author: Hai
   Notes: Simple stylesheet using basic CSS only. Colours
          chosen to suit a warm, friendly cafe feel.
   ========================================================= */


/* --- Page reset and base styles --- */

body {
    font-family: Arial, Helvetica, sans-serif;
    color: #2d2118;
    background-color: #fdf6ec;
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

/* Limit content width and centre it on the page */
header,
main,
footer {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}


/* --- Header and site title --- */

header {
    text-align: center;
    border-bottom: 2px solid #6b4423;
    background-color: #fff8ef;
}

header h1 {
    color: #6b4423;
    margin-bottom: 5px;
}

.tagline {
    font-style: italic;
    color: #8a6a4a;
    margin-top: 0;
}


/* --- Navigation menu --- */

nav ul {
    list-style: none;
    padding: 0;
    margin: 15px 0 0 0;
    text-align: center;
}

nav li {
    display: inline-block;
    margin: 0 10px;
}

nav a {
    color: #6b4423;
    text-decoration: none;
    font-weight: bold;
    padding: 8px 12px;
    border-radius: 4px;
}

/* Highlight the link when hovered or for the current page */
nav a:hover,
nav a.active {
    background-color: #6b4423;
    color: #fff8ef;
}


/* --- Main content sections --- */

main h2 {
    color: #6b4423;
    border-bottom: 1px solid #d9c5a8;
    padding-bottom: 5px;
}

main img {
    display: block;
    margin: 15px auto;
}


/* --- Menu table --- */

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

caption {
    text-align: left;
    font-weight: bold;
    padding-bottom: 8px;
    color: #6b4423;
}

th,
td {
    border: 1px solid #d9c5a8;
    padding: 10px;
    text-align: left;
}

thead th {
    background-color: #6b4423;
    color: #fff8ef;
}

/* Slight zebra striping makes the table easier to read */
tbody tr:nth-child(even) {
    background-color: #fff8ef;
}


/* --- Contact form --- */

form {
    margin-top: 15px;
}

label {
    display: block;
    margin-top: 12px;
    font-weight: bold;
}

input,
textarea {
    width: 100%;
    padding: 8px;
    margin-top: 5px;
    border: 1px solid #d9c5a8;
    border-radius: 4px;
    font-family: inherit;
    font-size: 1em;
    box-sizing: border-box;
}

button {
    margin-top: 15px;
    padding: 10px 20px;
    background-color: #6b4423;
    color: #fff8ef;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
}

button:hover {
    background-color: #8a5a30;
}


/* --- FAQ section --- */

.faq-question {
    display: block;
    width: 100%;
    text-align: left;
    margin-top: 10px;
    padding: 12px;
    background-color: #fff8ef;
    color: #6b4423;
    border: 1px solid #d9c5a8;
}

.faq-question:hover {
    background-color: #f0e3cc;
}

.faq-answer {
    padding: 10px 12px;
    margin: 0;
    background-color: #fdf6ec;
    border-left: 3px solid #6b4423;
}

/* The 'hidden' class is used by the JavaScript to hide an answer.
   When the class is removed, the answer becomes visible. */
.hidden {
    display: none;
}


/* --- Footer --- */

footer {
    text-align: center;
    border-top: 1px solid #d9c5a8;
    font-size: 0.9em;
    color: #8a6a4a;
}


/* --- Mobile-friendly adjustments for small screens --- */

@media (max-width: 600px) {
    nav li {
        display: block;
        margin: 5px 0;
    }
    header,
    main,
    footer {
        padding: 15px;
    }
}
