:root {
    color-scheme: light dark;
    
    --accent: #DB2732;
    --accent2: silver;
    
    --max-width: 600px;
}

html {
    margin: 0;
    padding: 0;
}

body {
    background: light-dark(#EEEDED, #000);
    color: light-dark(#000, #FFF);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    margin: 0;
    padding: 60px 0;
}

header,
main,
section,
footer {
    padding-inline: max(calc(((100vw - var(--max-width))/2) + env(safe-area-inset-right)), 16px);
}

header {
    text-align: center;
    img {
        border: 0;
        display: block;
        margin: 0 auto;
        max-width: 128px;
        &:first-child {
            margin-bottom: 20px;
        }
    }
    h1,
    p.title {
        font-size: 4rem;
        font-weight: 1000;
        margin: 0px 0 0;
        padding: 0;
    }
    h2 {
        font-size: 1.5rem;
        font-weight: 300;
        margin: 0;
        padding: 20px 0 50px;
        text-wrap: balance;
    }
}

main,
section {
    padding-block: 50px;
    &.gallery {
        background-color: light-dark(var(--accent2), color-mix(in srgb, var(--accent2), transparent 25%));
        p {
            font-size: 1.2rem;
            max-width: 45ch;
            text-wrap: balance;
        }
        ul {
            display: flex;
            justify-content: space-around;
            list-style-type: none;
            margin: 0;
            padding: 0;
            li {
                text-align: center;
                text-wrap: balance;
                width: calc(100%/var(--appCount));
                span {
                    display: block;
                }
            }
        }
        a {
            color: black;
            font-size: 1.5rem;
            text-decoration: none;
            &:hover {
                text-decoration: underline;
            }
        }
        img {
            width: 128px;
        }
    }
    h1 {
        font-size: 2rem;
    }
    h2 {
        font-size: 1.7rem;
    }
    h3 {
        font-size: 1.4rem;
    }
}

footer {
    padding-top: 50px;
    text-align: center;
    img {
        display: block;
        margin: 0 auto 100px;
        max-width: 300px;
    }
    p {
        font-size: 1.5rem;
        text-align: center;
    }
    a {
        color: light-dark(black, white);
    }
}

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

dt {
    font-weight: bold;
}

dd {
    margin: 0;
    &:not(:last-child) {
        margin-bottom: 20px;
    }
}

.app-store {
    border: 0;
}

@media (prefers-color-scheme: dark) {
    .app-store {
        filter: invert(1);
    }
}

@supports (animation-timeline: scroll()) {

    .app-on-device {
    animation: deviceParallax linear both;
    animation-timeline: scroll();
    } 
    
    @keyframes deviceParallax {
        from {
            transform: translateY(20vh);
        }
        to {
            transform: translateY(-20vh);
        }
    }

}