@import url('https://fonts.googleapis.com/css2?family=Bai+Jamjuree:ital,wght@0,200;0,300;0,400;0,500;0,600;0,700;1,200;1,300;1,400;1,500;1,600;1,700&display=swap');

:root {
    --green-500: hsl(171, 66%, 44%);
    --green-500-darker: hsl(171, 65%, 33%);
    --blue-100: hsl(233, 100%, 69%);
    --blue-100-darker: hsl(233, 100%, 64%);
    --gray-700: hsl(210, 10%, 33%);
    --gray-500: hsl(201, 11%, 66%);
    --gray-300: hsl(210, 13%, 91%);
    --white: hsl(0, 0%, 100%) ;

    --font-bai-jamjuree: "Bai Jamjuree", sans-serif;
    
    --round-border: 2rem;
}

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

body {
    display: grid;
    gap: 7rem;
    font-size: 1.125rem;
    text-align: center;
    background: top / 100% no-repeat url(images/bg-header-mobile.png);
    font-family: var(--font-bai-jamjuree);
    margin: 0;
}

.page-header__title,
.section-header__title,
.snippets__item-title,
.workflow__title,
.page-footer__link {
    color: var(--gray-700);
    font-weight: 600;
    overflow-wrap: break-word;
}

.page-header__text,
.section-header__text,
.snippets__item-text,
.workflow__text {
    color: var(--gray-500);
    font-weight: 400;
    max-width: 50ch;
}

.page-header__text,
.section-header__text {
    place-self: center;
}

.btn {
    display: inline-block;
    font-size: 1.1rem;
    width: 100%;
    text-decoration: none;
    border-radius: var(--round-border);
    line-height: 3.5rem;
    color: var(--white);
    font-weight: 600;
    transition: opacity 0.3s ease;
}

.btn--ios {
    background-color: var(--green-500);
    box-shadow: 0px 3px 0.1rem var(--green-500-darker);
    margin-block-end: 1.5rem;
}

.btn--mac {
    background-color: var(--blue-100);
    box-shadow: 0px 3px 0.1rem var(--blue-100-darker);
    margin-block-end: 1.5rem;
}

.btn:active {
    color: var(--white);
    cursor: pointer;
    transform: translateY(4px);
    box-shadow: 0 0 0 var(--white), 0 0px 0px var(--shadow);
}

.btn--ios:hover {
    background-color: var(--green-500-darker);
    box-shadow: 0px 3px 0.1rem var(--green-500);
}

.btn--mac:hover {
    background-color: var(--blue-100-darker);
    box-shadow: 0px 3px 0.1rem var(--blue-100);
}

.page-header {
    display: grid;
    justify-items: center;
    padding-block-start: 5rem;
    gap: 2rem;
    font-size: .9rem;
    margin-inline: 1.5rem;
}

.page-header__logo-container {
    width: 100%;
}

.page-header__logo {
    width: clamp(8rem, 10vw, 10rem);
}

.page-header__title {
    font-size: clamp(1.5rem, 6vw, 4rem);
}

.page-header__text{
    font-size: clamp(1.125rem, 1vw, 2rem);;
}

.main-content {
    display: grid;
    gap: 5rem;
    margin-inline: 1.5rem;
}

.snippets {
    display: grid;
    gap: 2rem;
}

.snippets__content {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.snippets__item {
    margin-block-end: 4rem;
}

.snippets__list,
.workflow__list,
.clients__list,
.page-footer__links,
.page-footer__social-list {
    list-style-type: none;
    padding: 0;
}

.anywhere {
    display: grid;
    gap: 2rem;
}

.workflow {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: center;
    text-align: center;
}

.workflow__list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    list-style: none;
    width: 100%;
}

.workflow__image-container {
    margin-block-end: 2rem;
}

.workflow__image {
    height: 2rem;
}

.workflow__item { 
    max-width: 25rem
}

.clients__list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 5rem;
}

.clients__item {
    margin-block-end: 5rem;
    align-content: center;
}

.clients__logo {
    max-width: 100%;
}

.display-image {
    width: clamp(10rem, 50vw + 5rem, 50rem);
}

.download {
    display: grid;
    justify-items: center;
    gap: 2rem;
}

.page-footer {
    display: flex;
    flex-direction: column;
    background: var(--gray-300);
}

.page-footer__nav {
    display: grid;
    place-items: center;
    margin-block-start: 2rem;
}

.page-footer__logo-container {
    width: 100%;
}

.page-footer__logo {
    width: clamp(3rem, 10vw, 5rem);
}

.page-footer__links {
    margin-block-start: 2rem;
    
}

.page-footer__link-item {
    margin-block-end: 2rem;
}

.page-footer__social-list {
    display: flex;
    justify-content: center;
}

.page-footer__social-item {
    padding-inline: .5rem;
    width: clamp(2rem, 10vw + .5rem , 3rem);
}

.page-footer__link {
    text-decoration: none;
}

.page-footer__link:hover,
.page-footer__attribution a:hover  {
    color: var(--green-500);
    transition: color 0.3s ease;
}

.page-footer__social-item:hover .page-footer__icon{
    fill: var(--green-500);
}

@media screen and (width >= 64rem) {
    body {
        background: top / 100% no-repeat url(images/bg-header-desktop.png);
    }

    .download-buttons {
        display: flex;
        flex-direction: row;
        justify-items: center;
        width: 35rem;
    }

    .btn--ios {
        margin-inline-end: 1.5rem;
    }

    .snippets__content {
        flex-direction: row;
        justify-content: center;
        align-items: center;
        text-align: start;
        gap: 2rem;
    }
    
    .page-footer__nav {
        grid-template-columns: 1fr 3fr 1fr;
    }

    .page-footer__links {
        grid-template-columns: repeat(3, 1fr);
        justify-self: start;
        text-align: start;
    }
}
