:root {
    --white: #fff;
    --black: #000;
    --gray: #cfcfcf;
    --light-gray: #e3e3e3;

    --background: #fefefe;
    --foreground: var(--black);

    --accent: #2596be;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: all 0.1s ease-in-out;
}

html,
body {
    background: var(--background);
    color: var(--foreground);
    font-family: system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Oxygen,
    Ubuntu,
    "Adwaita Sans",
    Cantarell,
    "Open Sans",
    "Helvetica Neue",
    sans-serif;
    min-height: 100vh;
    width: 100%;
}

button {
    cursor: pointer;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;

    &.primary {
        background: var(--accent);
        color: var(--white);
    }

    &#cta {
        padding: 12px 32px;
        width: 80%;
        font-size: 1rem;
    }

    &:hover {
        filter: brightness(110%);
    }

    &:active {
        filter: brightness(80%);
    }
}

a {
    text-decoration: none;
}

nav {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid var(--black);
    padding: 8px;
    background: var(--accent);
    color: var(--white);

    a {
        color: var(--white);
    }
}

.center-fullscreen {
    width: 100%;
    height: 100vh;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

header {
    position: relative;
    width: 100%;
    height: 100vh;
    /*background: url("bg.avif");*/
}

#track-form {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(32px);
}

input {
    border: 1px solid var(--black);
    border-radius: 4px;
    padding: 8px 16px;
    background: var(--white);
    color: var(--black);

    &:focus {
        outline: 2px var(--accent) solid;
        outline-offset: 2px;
    }

    &.hero {
        width: 80%;
        font-size: 1rem;
        text-align: center;
        background: rgba(255, 255, 255, 0.6);
        color: var(--black);

        &:focus {
            background: rgba(255, 255, 255, 1);
        }
    }
}

#attribution {
    display: none;
    position: absolute;
    color: #fefefe;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
    padding: 4px;
    left: 0;
    bottom: 0;
    margin: 12px;
    font-size: 0.4rem;
}

#track-view {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    padding: 16px;
}

#delivery-status {
    display: flex;
    align-items: center;
    position: relative;

    & ul {
        z-index: 1;
        display: flex;
        justify-content: space-around;
        width: 100%;
        list-style: none;
        flex-wrap: wrap;

        & li {
            display: flex;
            justify-content: center;
            align-items: center;
            flex-direction: column;
            text-align: center;
            gap: 8px;
            flex: 1;
            min-width: 180px;

            & .circle {
                border-radius: 50%;
                background: var(--gray);
                width: 48px;
                height: 48px;
                display: flex;
                justify-content: center;
                align-items: center;
                user-select: none;

                &.checked {
                    background: var(--accent);

                    & img {
                        filter: invert(1);
                    }
                }

                & img {
                    width: 32px;
                    height: 32px;
                }
            }

            & .caption {
                height: 32px;
            }
        }
    }

    & #progress {
        position: absolute;
        top: 20%;
        height: 12px;
        border-radius: 4px;
        background: var(--accent);
        transition: none;
    }
}

#messages-list ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    padding: 16px;

    & li {
        padding: 4px;
        border-radius: 4px;
        background: var(--light-gray);

        & small {
            color: var(--black);
        }
    }
}

@media screen and (max-width: 800px) {
    #delivery-status {
        & #progress {
            display: none;
        }
    }
}