/* Fonts */
@font-face {
    font-family: 'Monserrat';
    src: url("/assets/fonts/Montserrat-VariableFont_wght.ttf"),
         url("/assets/fonts/Montserrat-Italic-VariableFont_wght.ttf");
    /* font-weight: 800; */
}

/* Variables */
:root {
    scroll-behavior: smooth;

    /* Fonts */
    --font-primary: Cambria, Cochin, Georgia, Times, 'Times New Roman', serif;
    --font-button: 'Monserrat', Arial, sans-serif;

    /* Backgrounds */
    --bg: rgb(221, 229, 235);
    /* --bg-light: rgb(247, 251, 255); */
    --bg-lighter: white;
    --border: #afccdf;

    --bg-overlay: color-mix(in srgb, transparent, var(--bg) 90%);

    /* Colors */
    --heading-color: rgb(3, 16, 71);
    --text: black;
    --text-2: rgb(29, 29, 29);

    --brand-blue: #1e84c9;
    --brand-dark: #166aa1;

    /* Sizing */
    --container-width: 960px;
    --container-horizontal-padding: 24px;

    /* SVG */
    --bg-fill: var(--bg);
}

/* Dark theme */
.dark_theme {
    /* Backgrounds */
    --bg: rgb(38, 50, 59);
    --bg-lighter: rgb(57, 75, 88);
    --border: rgb(73, 93, 109);

    /* Colors */
    --heading-color: white;
    --text: white;
    --text-2: rgb(224, 224, 224);

    /* --brand-blue: #3b86f7; */
    /* --brand-dark: #286b97; */
}
.dark_theme .card {
    --brand-dark: #4c9fd6;
}

::selection {
    background-color: var(--brand-blue);
    color: white;
}


/* Reset */
* {
    box-sizing: border-box;
    padding: 0;
    margin: 0;

    font-family: var(--font-primary);
    
    color: var(--text);
}

body {
    background-color: var(--bg);
    color: var(--text);
    font-size: 14pt;
    line-height: 1.2em;
}
#background_layer {
    /* --gradient-color: color-mix(in srgb, var(--brand-blue), transparent 60%); */
    /* background:
        radial-gradient(circle at right center, var(--gradient-color) 0%, transparent 25%),
        radial-gradient(circle at left center, rgba(255, 176, 29, 0.25) 0%, transparent 25%); */

    --gradient-color: color-mix(in srgb, transparent, var(--bg) 50%);

    padding-top: 156px;

    background-image:
        linear-gradient(var(--gradient-color), var(--gradient-color)),
        url(/img/wheat.jpeg);
    /* background-repeat: no-repeat; */
    background-position-x: center;
    background-position-y: calc(var(--bg-y) - 300px);
    background-size: cover;

    position: absolute;
    top: 0; left: 0; right: 0;
    height: 240px;
    z-index: -1;
}

/* Color Inheriting */
svg path {
    fill: var(--fill);
}
svg path.bg_fill { fill: var(--bg-fill); }

/* Styles */
.flex { display: flex; }
.flex_direction_column { flex-direction: column; }
.gap_medium { gap: 10px; }

.font_button {
    font-family: var(--font-button);
}

.margin_left_auto { margin-left: auto; }
.text_align_left { text-align: left !important; }
.width100 { width: 100%; }
.text_2 { color: var(--text-2); }
.inline_icon {
    --fill: var(--text);
    vertical-align: -16.5%;
    height: 0.8lh;
}
.rotate180 { transform: rotate(180deg); }

p {
    padding: 6px 0;
    color: var(--text-2);
}

h1, h2, h3, h4, h5, h6 {
    color: var(--heading-color);

    line-height: 1em;
    padding: 8px 0;
    font-weight: 900;
}
h1 { font-size: 64pt; }
h2 {
    font-size: 40pt;
    border-bottom: 1px solid var(--border);
}
h3 { font-size: 28pt; }
h4 { font-size: 18pt; }
/* h5 { font-size: 14pt; } */
h6 { font-size: initial; }

button {
    border: none;
    background-color: unset;
    color: var(--text)
}

ul {
    list-style: none;
}

ol {
    margin: 10px 0;
}
ol li {
    padding-left: 5px;
    padding-bottom: 10px;
    margin-left: 30px;
}
li::marker {
    color: var(--brand-dark);
    font-weight: bold;
}


/* Anchor */
* {
    text-underline-offset: 5px;
}


/* Button */
.button {
    --button-color: var(--bg);
    --hover-text: black;
    --shadow-color: rgba(0, 0, 0, 0.25);

    display: inline-block;

    background-color: var(--button-color);
    color: var(--text);
    border: 2px solid var(--border);
    /* box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); */

    padding: 6px 24px;
    border-radius: 16px;

    font-family: var(--font-button);
    font-size: 13pt;
    font-weight: 700;
    text-align: center;
    text-decoration: none;

    user-select: none;
    cursor: pointer;

    --ttf: cubic-bezier(0.075, 0.82, 0.165, 1);
    transition:
        color 0.25s var(--ttf),
        background-color 0.35s var(--ttf),
        border-color 0.6s ease,
        border-radius 0.35s cubic-bezier(0.68,-0.55,0.27,1.55),
        opacity 0.35s ease,
        filter 0.35s ease;
}
.button:hover,
.button:focus-visible {
    --text: var(--hover-text);

    background: white;
    border-radius: 12px;

    /* Wobble */
    --glow-x: 0; --glow-y: 1px;
    transform: scale(1.1) translate(calc(var(--glow-x) * -0.3), calc(var(--glow-y) * -0.3));
    box-shadow: var(--glow-x) var(--glow-y) 18px var(--shadow-color);
}
.button[disabled],
body:not(:has(.conditional_checkbox:checked)) .button.disabled {
    opacity: 0.5;
    filter: saturate(20%);
    pointer-events: none;
}
.button_large {
    padding: 12px 36px;
}
.button_blue {
    --button-color: var(--brand-blue);
    --shadow-color: var(--brand-blue);
    --hover-text: var(--brand-blue);
    --text: white;
}
.button_transparent {
    --button-color: transparent;
    --border: transparent;
}



/* Form button */



.color_red { color: rgb(182, 39, 39); }

/* Inputs */
.checkbox_container {
    --text: var(--text);
    cursor: pointer;
    padding: 5px 0;

    user-select: none;
}
.checkbox_container:hover .label,
.checkbox_container:focus-visible .label {
    text-decoration: underline;
}
input[type="checkbox"] {
    border-radius: 5px;
    margin-right: 10px;

    width: 16px;
    height: 16px;

    cursor: pointer;
}


/* Details */
details {
    width: 100%;
}
details summary {
    position: relative;

    font-size: 15pt;
    font-weight: 600;

    color: var(--heading-color);
    background-color: var(--bg-lighter);
    padding: 8px 20px;
    border: 2px solid var(--border);
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);

    transform: translateY(-2px);

    cursor: pointer;
    transition-property: background-color, box-shadow, transform;
    transition-duration: 200ms;
    transition-timing-function: ease-out;
}
details[open] summary {
    background-color: var(--bg);
    box-shadow: unset;
    transform: unset;
}

details .contents {
    opacity: 0;
    transition: opacity 200ms ease;
    margin: 12px 0;
    padding-left: 24px;

    position: relative;


}
details .contents::after {
    content: "";
    position: absolute;
    left: 0; top: 0; bottom: 0;

    width: 5px;
    background-color: var(--border);
    border-radius: 100px;
}
details[open] .contents {
    opacity: 1;
}


/* Container */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 64px var(--container-horizontal-padding);
}


/* Tooltip */
[data-tooltip] { position: relative; }
[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    top: calc(100% + 4px);
    left: 50%;

    font-size: 13pt;

    display: inline-block;
    width: max-content;

    background-color: var(--bg-lighter);
    padding: 5px 15px;
    border-radius: 5px;
    border: 2px solid var(--border);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);

    transform: translateX(-50%) scale(0.95);
    transform-origin: top;
    opacity: 0;
    transition: transform 150ms ease, opacity 150ms ease;

    pointer-events: none;
}
[data-tooltip]:hover::after,
[data-tooltip]:focus-visible::after {
    opacity: 1;
    transform: translateX(-50%);
}




/* Nav */
#nav {
    --text: var(--heading-color);

    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1;

    background-color: var(--bg);
    backdrop-filter: blur(16px);
    /* background-color: var(--bg); */
    border-bottom: 2px solid var(--border);

    transition: all 0.3s ease;
}
#nav.transparent {
    background-color: transparent;
    backdrop-filter: unset;
    border-color: transparent;
}
#nav.nav_blue {
    background-color: var(--brand-dark);
    --border: #235f86;
    --bg-fill: var(--brand-dark);
}
#nav > .inner {
    padding: 9px var(--container-horizontal-padding);
}

#nav .nav_upper {
    align-items: center;
    gap: 24px;
}
#nav .right {
    margin-left: auto;
    display: flex;
    gap: 24px;
}

/* Logo */
/* img#nav_logo {
    max-height: 96px;
} */
#nav_logo {
    /* --text: var(--brand-dark); */
    --nav-hover-travel-x: 16px;

    font-size: 24pt;
    font-weight: bold;
    text-decoration: none;

    padding-right: 20px;

    display: flex;
    align-items: center;
    gap: 12px;

    filter: drop-shadow(0 1px 4px var(--bg));
    transition: transform 0.3s ease;
}
#nav_logo:hover,
#nav_logo:focus-visible {
    color: var(--text-2);
}
#nav[data-home="false"] #nav_logo:hover,
#nav[data-home="false"] #nav_logo:focus-visible {
    transform: translateX(var(--nav-hover-travel-x));
}

/* Back arrow */
#nav_logo .inline_icon {
    position: absolute;
    z-index: -1;
    margin-left: calc(var(--nav-hover-travel-x) * -2);

    height: 26px;
    opacity: 0;
    transform: translateX(calc(var(--nav-hover-travel-x) + 10px)) scale(0.8);
    transition: 0.3s ease;
}
#nav[data-home="false"] #nav_logo:hover .inline_icon,
#nav[data-home="false"] #nav_logo:focus-visible .inline_icon {
    opacity: 1;
    transform: unset;
}
#nav_logo > svg {
    --fill: var(--text);

    height: 44px;
    width: 44px;
}

#nav .nav_icon {
    display: flex;
    align-items: center;
    gap: 6px;
    opacity: 0.9;

    border-radius: 100px;
    padding: 0 12px;

    text-decoration: none;
}
#nav .nav_icon:hover,
#nav .nav_icon:focus-visible {
    background-color: var(--bg-lighter);
}
#nav .nav_icon svg {
    --fill: var(--text-2);
    height: 24px;
    width: 24px;
}


/* Header */
header {
    /* background-color: var(--brand-blue); */
}

.home_title {
    word-break:normal;
}

/* h1 .title_smaller {
    display: block;
    margin-top: 6px;
    font-size: 0.65em;
    line-height: 1.2em;
} */

/* Landing Header */
.parallax {
    --bg-y: 0;
    background-position-y: var(--bg-y);
}
header#landing {
    /* position: relative;
    overflow: hidden; */

    padding: 160px 0 160px 0;

    background-image:
        linear-gradient(0deg, var(--bg-overlay), var(--bg-overlay)),
        url(/img/banner_placeholder.jpeg);
    background-size: cover;
}
header#landing > .inner {
    /* outline: 1px solid red; */
    column-gap: 64px;
    row-gap: 20px;

    /* .col_1 {
        outline: 1px solid blue;
    } */
}
header#landing > .inner > div {
    width: 100%;
}
header#landing > .inner > .col_2 {
    max-width: 380px;
    justify-content: flex-end;
}

.divider {
    --height: 140px;

    /* background-color: var(--brand-dark); */

    height: 0;

    position: relative;
    overflow-x: clip;

    /* outline: 2px solid rgb(0, 255, 0); */
}
.divider_top {
    transform: translateY(-54px);
}
.wave {
    /* outline: 1px solid red; */

    position: absolute;

    --fill: var(--brand-dark);
    /* --fill: brown; */

    /* position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%); */


    /* object-fit: cover; */
    /* width: max-content; */
    min-width: 100vw;
    /* height: var(--height); */
}


.blurb {
    font-size: 15pt;
    text-align: center;
}



/* Main */
#main_home {
    --sidebar-width: 280px;

    position: relative;
    /* isolation: isolate; */
}
#main_home .container {
    padding-left: calc(var(--sidebar-width) + 24px);
}
#sidebar {
    position: sticky;
    left: 0;
    top: 100px;
    bottom: 0;
    /* transform: translateY(-50%); */
    z-index: 1;

    height: 0;
    overflow: visible;

    max-width: var(--container-width);
    margin: 0 auto;

    /* Filter */
    /* filter: saturate(0) contrast(500%); */
    transition: color 0.5s ease;

}
#sidebar > .inner {
    /* outline: 1px solid red; */

    position: relative;
    max-width: var(--sidebar-width);
    padding: 0 18px;
    padding-top: 100px;

    /* --text: white; */

    font-size: 24pt;
    font-weight: 600;
    line-height: 1.5em;
}
#sidebar > .inner a {
    text-decoration: none;
}
#sidebar > .inner a {
    display: inline-block;
    line-height: 1.1em;
    opacity: 0.8;

    /* --text: white; */
    /* clip-path: url(#svgTextPath); */
    /* backdrop-filter: invert(); */

    /* Temporary */
    /* background-color: var(--brand-dark); */
    /* border-radius: 10px; */
    /* padding: 0 18px; */
    margin-bottom: 3px;

    transition: transform 0.15s ease, color 0.4s ease, opacity 0.15s ease;
}
#sidebar ul:has(a:hover) a {
    opacity: 0.5;
}
#sidebar > .inner a:hover,
#sidebar > .inner a:focus-visible {
    opacity: 1;
    transform: translateX(-5px);
}

#sidebar > .inner a .inline_icon {
    font-size: inherit;
    opacity: 0;
    transform: translateX(-10px);
    transition: 0.25s ease;
}
#sidebar > .inner a:hover .inline_icon,
#sidebar > .inner a:focus-visible .inline_icon {
    opacity: 1;
    transform: unset;
}

/* Sections */
#section_1 {
    background-color: var(--brand-dark);
}
#section_2 {
    --gradient-color: color-mix(in srgb, transparent, var(--bg) 30%);

    padding-top: 156px;

    background-image:
        linear-gradient(var(--gradient-color) 0%, var(--bg) 70%),
        url(/img/wheat.jpeg);
    background-position: center;
    background-size: cover;
}

/* Img inline */
.img_inline {
    width: 100%;
    max-height: 200px;
    object-fit: cover;

    margin: 5px 0;
    border: 3px solid var(--brand-blue);
    border-radius: 10px;

    box-shadow: 6px 6px 0 var(--brand-blue);
}

/* Cards */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
    gap: 15px;
}
.card {
    /* max-height: fit-content; */
    display: block;
    position: relative;

    background-color: var(--bg-lighter);
    padding: 12px 18px;
    border: 2px solid var(--brand-dark);
    border-radius: 10px;

    box-shadow: 6px 6px 0 var(--brand-dark);
}
.card h4 {
    padding-right: 64px;
}
/* .card .card_icon {
    border: 2px solid var(--brand-dark);
    border-top: unset; border-right: unset;
    color: var(--brand-dark);

    font-size: 16pt;
    font-weight: bold;
    font-family: var(--font-button);

    width: 64px;
    height: 40px;
    border-radius: 0 0 0 10px;

    position: absolute;
    top: 0; right: 0;

    display: flex;
    justify-content: center;
    align-items: center;
} */


main .left_col {
    width: 100%;
}
main .right_col {
    min-width: 360px;
}



/* Gallery */
.gallery {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-template-rows: repeat(5, 1fr);
    gap: 10px;
    
    & > :nth-child(1) { grid-area: 1 / 1 / 2 / 5; }
    & > :nth-child(2) { grid-area: 1 / 5 / 3 / 7; }
    & > :nth-child(3) { grid-area: 2 / 1 / 4 / 3; }
    & > :nth-child(4) { grid-area: 2 / 3 / 4 / 5; }
    & > :nth-child(5) { grid-area: 3 / 5 / 4 / 7; }
    & > :nth-child(6) { grid-area: 4 / 1 / 6 / 4; }
    & > :nth-child(7) { grid-area: 4 / 4 / 6 / 7; }
}
.gallery img {
    width: 100%;
    object-fit: cover;

    border-radius: 5px;
}
.gallery img:hover,
.gallery img:focus-visible {
    
}




/* Footer */
#footer {
    position: relative;
    border-top: 2px solid var(--border);

    margin-top: 48px;
}
#footer > .inner {
    gap: 20px;
}
.footer_icon {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -50%);

    width: 80px;
    height: 80px;

    background-color: var(--bg);
    padding: 6px;

    --fill: var(--brand-dark);
}
.col {
    width: 100%;
}


/* Resize */
@media screen and (max-width: 940px) {
    .home_title {
        font-size: 56pt;
    }
}
@media screen and (max-width: 850px) {
    .home_title {
        font-size: 48pt;
    }
}


/* Mobile */
@media screen and (max-width: 790px) {
    .media_flex {
        flex-direction: column;
    }
    h2 {
        font-size: 34pt;
    }

    /* Header */
    header#landing {
        padding: 120px 0 120px 0;
    }
    header#landing > .inner {
        max-width: 400px;
    }
    header#landing > .inner > .col_2 {
        max-width: unset;
        /* margin: 0 auto; */
    }
    .home_title {
        font-size: 40pt;
    }

    /* Main */
    #main_home {
        --sidebar-width: 0px;
    }

    #sidebar {
        max-width: var(--container-width);
        position: unset;
        height: unset;
    }
}

/* Mobile smaller */
@media screen and (max-width: 620px) {
    #nav .nav_upper {
        flex-direction: column;
        gap: 15px;
    }
    #nav .right {
        margin-left: unset;
    }
    #nav #nav_cta {
        margin: 0 auto;

        font-size: 10pt;
    }
}
