/* global.css */
:root {
    --light-blue: #b0d2ec;
    --deep-brown: #533b30;
    --font-main: 'Montserrat', sans-serif;
    --font-note: 'Caveat', cursive;
    --font-title: 'Architects Daughter', cursive;
    --paper-white: #fdfdfd;
}

/* Fixes the box calculation for all elements */
* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--paper-white);
    color: var(--deep-brown);
    font-size: 23px;
    font-family: var(--font-main);
    font-weight: 500;
}

.content-container {
    width: 100%;
    padding-left: 0%;
    padding-right: 0%;
    box-sizing: border-box;
}

@media (min-width: 1112px) {
    .content-container {
        /* Back to small landscape mode padding for all pages in small laptop/tablet landscape mode */
        padding-left: 5%;
        padding-right: 5%;
    }
}

@media (min-width: 1440px) {
    .content-container {
        /* Back to small landscape mode for all pages in large laptop/desktop mode */
        padding-left: 10%;
        padding-right: 10%;
    }
}

/* Header */
site-header {
    display: block;
}

.site-header {
    width: 100%;
    background-color: var(--deep-brown);
    position: relative;
    z-index: 999;
}

.site-header__desktop {
    display: none;
}

.site-header__inner {
    width: 100%;
    min-height: 120px;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    column-gap: clamp(24px, 4vw, 56px);
}

.site-header__brand {
    display: flex;
    align-items: center;
}

.site-header__brand img {
    height: 120px;
    width: auto;
    display: block;
}

.site-header__nav {
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    width: fit-content;
    margin-left: auto;
    gap: clamp(80px, 2.6vw, 160px);
    /* used for navigation bar spacing change */
}

.site-header__mobile {
    display: flex;
}

.site-header__mobile-bar {
    min-height: 80px;
    width: 100%;
    padding-left: 10%;
    padding-right: 10%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-header__mobile .site-header__brand img {
    height: 70px;
}

.site-header__menu-button,
.site-header__menu-close {
    border: 0;
    background: transparent;
    color: var(--light-blue);
    padding: 0;
    cursor: pointer;
    font-family: var(--font-main);
}

.site-header__menu-button {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: stretch;
}

.site-header__menu-bar {
    display: block;
    width: 28px;
    height: 4px;
    background-color: var(--light-blue);
}

.site-header__mobile-menu {
    position: fixed;
    inset: 0;
    background-color: var(--deep-brown);
    z-index: 1000;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 40px;
}

.site-header__mobile-menu.is-open {
    display: flex;
}

.site-header__menu-close {
    position: absolute;
    top: 40px;
    right: 10%;
    font-size: 50px;
    line-height: 1;
}

.site-header__mobile-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.site-header__mobile-link {
    color: var(--light-blue);
    font-family: var(--font-main);
    font-size: 30px;
    font-weight: 800;
    line-height: 1.2 !important;
    text-decoration: none;
}

.site-header-menu-open {
    overflow: hidden;
}

.nav-link {
    transition: opacity 0.3s;
    position: relative;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--light-blue);
}

.nav-active {
    text-decoration: underline;
    text-underline-offset: 4px;
}

.nav-link:hover {
    text-decoration: underline;
}

header nav a {
    font-family: var(--font-main) !important;
    font-size: clamp(22px, 2.4vw, 30px) !important;
    font-weight: 800 !important;
}

@media (width < 1112px) {

    /* Reserve space so content does not sit under the fixed mobile bar (Tailwind: fixed top-0 left-0 w-full). */
    .site-header {
        padding-top: 80px;
    }

    .site-header__mobile-bar {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        width: 100%;
        z-index: 998;
        background-color: var(--deep-brown);
    }
}

@media (min-width: 1112px) {
    .site-header__desktop {
        display: flex;
        align-items: center;
        min-height: 120px;
    }

    .site-header__mobile {
        display: none;
    }
}

/* Footer */
footer {
    width: 100%;
    background-color: var(--deep-brown);
}

footer .content-container {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    /* Icons sit closer to text as requested */
    align-items: center;
    flex-wrap: wrap;
    row-gap: 24px;
    padding-top: 80px;
    padding-bottom: 80px;
}

.footer-copy {
    flex: 0 0 auto;
}

button,
input,
textarea,
a {
    line-height: 30px !important;
    /* 统一所有元素的行高基准 */
}

.footer-link {
    transition: opacity 0.3s;
    white-space: nowrap;
    display: inline-flex;
    align-items: center !important;
    gap: 12px;
    font-weight: 600;
    font-size: 20px;
    line-height: 1 !important;
    text-decoration: none;
    color: var(--light-blue);
    flex-shrink: 0;
}

.footer-link span {
    display: block;
    line-height: 1;
}

.footer-text-offset .footer-link span {
    transform: translateY(-1px);
}

.footer-link:hover {
    text-decoration: underline;
}

/* This creates the gap BETWEEN the individual social media items */
.social-group {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 32px;
    /* Adjust this number to match the "wider gap" you see in contact.html */
    flex: 0 0 auto;
    margin-left: auto;
}

footer .footer-desktop {
    flex-direction: column;
    row-gap: 44px;
}

footer .footer-desktop-main {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    row-gap: 24px;
}

/* This push social media items to align left directly below copyright line in less wide desktop */
footer .footer-desktop-main.footer-stack-social .social-group {
    margin-left: 0;
    flex-basis: 100%;
    width: 100%;
}

footer .footer-legal-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    column-gap: 6px;
    row-gap: 10px;
    width: 100%;
}

footer .footer-mobile .footer-legal-row {
    column-gap: 6px !important;
}

footer .footer-tablet .footer-legal-row {
    column-gap: 6px !important;
}

footer .footer-legal-link {
    font-family: 'Montserrat', sans-serif;
    color: var(--light-blue);
    text-decoration: none;
    font-size: 17px;
    line-height: 1 !important;
    white-space: nowrap;
}

footer .footer-legal-link:hover {
    text-decoration: underline;
}

footer .footer-legal-sep {
    opacity: 0.6;
}

footer svg {
    width: 28px !important;
    height: 28px !important;
    fill: var(--light-blue);
    flex-shrink: 0;
    display: block;
    align-self: center;
}