/* ========================================
                CSS variables
                [START]
========================================= */

:root {
    /* Global properties */
    --page-width: 90%;
    --page-width-padding: calc( (100% - var(--page-width)) / 2 );
    --font-family: 'Merriweather', arial, sans-serif;
    --line-height: 1.6;
    --block-zoom-transition-curves: cubic-bezier(0.06, 0.62, 0.22, 0.88);
    --soft-border: 1px solid rgb(0, 0, 0, 8%);
    --soft-shadow: 0 0 8px 0 rgb(0, 0, 0, 6%);
    --soft-text-shadow: 1px 1px 4px rgb(0, 0, 0, 40%);
    --scroll-bar-width: var(--space-sm);
    --header-height: 301.61px;
    --min-screen-width: 320px;
    --top-z-index: 999999999;
    --under-top-z-index: 999999998;

    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 12px;
    --space-lg: 16px;
    --space-xl: 20px;
    --space-xxl: 24px;
    --space-xxxl: 32px;
    --space-4xl: 40px;
    --space-5xl: 48px;
    --space-6xl: 56px;
    --space-7xl: 64px;

    /* Border radius */
    --border-radius-xs: 4px;
    --border-radius-sm: 8px;
    --border-radius-lg: 16px;
    --border-radius-xl: 32px;
    --border-radius-full: 50%;

    /* Button */
    --button-font-size: 1rem;
    --button-font-weight: 300;
    --button-border-radius: .5rem;
}

@media (min-width: 1200px) {

    :root {
        --page-width: 80%;
        --header-height: 125.83px;
    }

}

/* ========================================
                CSS variables
                [END]
========================================= */




/* ========================================
            Initial setup & page layout
                [START]
========================================= */

*,
*::after,
*::before { 
    box-sizing: border-box;
}

* {
    margin: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--space-md);
}

html:has(.page-header--sticky) {
    scroll-padding-top: var(--header-height);
}

body {
    min-height: 100vh;
    /* font-size: clamp(1rem, 2.5vw, 2rem); */
    font-family: var(--font-family);
    font-weight: 300;
    line-height: var(--line-height);
    color: var(--color-on-background);
    -webkit-font-smoothing: antialiased;
    accent-color: var(--color-primary);
    background-color: var(--color-background);
}

body.page--disabled-scroll {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.page__main {
    width: 100%;
    min-height: calc(100vh - var(--header-height));
}

body:has(.page-header--sticky) .page__main {
    padding-top: var(--header-height);
}

:focus-visible {
    outline-color: var(--color-primary); 
}

::marker {
    color: var(--color-primary); 
}

:is(::-webkit-calendar-picker-indicator,
    ::-webkit-clear-button,
    ::-webkit-inner-spin-button, 
    ::-webkit-outer-spin-button) {
    color: var(--color-primary);
}

/* ========================================
            Initial setup & page layout
                [END]
========================================= */




/* ========================================
                Reset
                [START]
========================================= */

p, h1, h2, h3, h4, h5, h6 {
    overflow-wrap: break-word;
}

a {
    color: inherit;
}

li {
    list-style: none;
}

img, picture, video, canvas, svg {
    display: block;
    max-width: 100%;
}

input,
textarea,
select,
button {
    font: inherit;
}

/* ========================================
                Reset
                [END]
========================================= */




/* ========================================
                Components
                [START]
========================================= */

#hbd-debug {
    width: 90%;
    height: 500px;
    margin-left: auto;
    margin-right: auto;
    padding: 12px;
    border: 1px solid rgb(0, 0, 0, 30%);
    border-radius: 4px;
    font-size: 1rem;
    color: #3e0000;
    background-color: #f5f0e6;
    overflow: scroll;
}

input:not([type="submit"], [type="checkbox"], [type="radio"]),
textarea {
    /* Sets input font size to a min of 16px */
    /* https://css-tricks.com/16px-or-larger-text-prevents-ios-form-zoom/ */
    font-size: 16px !important;

    padding: var(--space-xs);
    border: var(--soft-border);
    border-radius: var(--border-radius-xs);
}

input:not([type="submit"]):hover,
textarea:hover {
    filter: brightness(98%);
}

textarea {
    min-width: 100%;
    max-width: 100%;
    min-height: calc( (1rem * var(--line-height)) + 2rem + (var(--space-xs) * 2) );
    max-height: 300px;
}

/* ========================================
                Components
                [END]
========================================= */




/* ========================================
            Helpers / utility
                [START]
========================================= */

.global-container {
    width: var(--page-width);
    height: 100%;
    margin-left: auto;
    margin-right: auto;
	padding:40px 0;
}

.message-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding-top: var(--space-sm);
    padding-bottom: var(--space-sm);
    padding-left: var(--space-4xl);
    padding-right: var(--space-4xl);
    border-radius: var(--border-radius-sm);
}

.message-container--success {
    background-color: var(--color-success);
}

.message-container--error {
    background-color: var(--color-error);
}

.message__text {
    font-size: 1rem;
    font-style: italic;
    font-weight: normal;
}

.message__text--success {
    color: var(--color-on-sucess);
}

.message__text--error {
    color: var(--color-on-error);
}

.responsive-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-sm);
}

.horizontal-scroll-container {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    column-gap: var(--space-sm);
    scroll-snap-type: x mandatory;
    overflow-x: scroll;
}

.u-full-width {
    /* Creates full-width banner inside limited width parent */
    /* https://css-tricks.com/full-width-containers-limited-width-parents/#aa-no-calc-needed */
    width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

.underline::after {
    content: '';
    display: block;
    width: 30%;
    height: 4px;
    background-color: var(--color-primary);
}

.spacer {
    width: 100%;
    height: 80px;
    background-color: transparent;
}

.u-excerpt-text {
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.phone-number {
    direction: ltr;
}

.u-uppercase {
    text-transform: uppercase;
}

.scroll-animation-wrapper {
    overflow: clip; /* overflow: hidden; causes view() animations to break (https://www.bram.us/2024/02/14/scroll-driven-animations-you-want-overflow-clip-not-overflow-hidden/) */
}

.prettify-text {
    line-height: 1.9;
    word-spacing: 1px;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 300;
    text-transform: none;
    color: var(--color-on-background);
}

@media (min-width: 1200px) {

    .section-title {
        font-size: 1.75rem;
    }

}

.title--small {
    font-size: 1.5rem;
    font-weight: 300;
}

.title--big {
    font-size: 2rem;
    font-weight: 700;
}

.u-show {
    display: block;
}

.u-hidden {
    display: none;
}

.u-clickable {
    cursor: pointer;
}

.zoom-in {
    transition: scale .4s var(--block-zoom-transition-curves);
}

.zoom-in:hover {
    scale: 1.05;
    transition: scale .4s var(--block-zoom-transition-curves);
}

.slide-right {
    transition: transform .4s var(--block-zoom-transition-curves);
}

.slide-right:hover {
    transform: translateX(5px);
    transition: transform .4s var(--block-zoom-transition-curves);
}

/* ========================================
            Helpers / utility
                [END]
========================================= */