/* =============================================== */
/* Custom properties */
:root {
    --font-base: 1rem;
    /* --line-height: 1.5; */

    --clr-black: 18, 18, 18;
    --clr-dark-blue: 25, 32, 45;
    --clr-white: 255, 255, 255;
    --clr-grey-100: 231, 234, 238;
    --clr-grey-200: 207, 207, 207;
    --clr-grey-400: 103, 109, 126;
    --clr-grey-500: 72, 85, 106;
    --clr-purple-50: 237, 228, 255;
    --clr-purple-300: 167, 117, 241;
    --clr-purple-500: 115, 63, 200;
    --clr-background: 246, 245, 246;

    --fs-20: 1.25rem;
    --fs-13: 0.813rem;
    --fs-11: 0.688rem;
}

@media (width < 36em) {
    :root {}
}

@media (36em <=width <=48em) {
    :root {}
}

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

html {
    -moz-text-size-adjust: none;
    -webkit-text-size-adjust: none;
    text-size-adjust: none;
}

body {
    font-size: var(--font-base);
    /* line-height: var(--line-height); */
    font-family: "Barlow Semi Condensed";
    /* color: var(--clr-grey-500); */
    background-color: rgb(var(--clr-background))
}

body,
h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd,
ul,
ol {
    margin: 0;
    padding: 0;
}

ul,
ol {
    list-style: none;
}

h1,
h2,
h3,
h4 {
    /* text-wrap: balance; */
}

a:not([class]) {
    text-decoration-skip-ink: auto;
    text-decoration: none;
    color: currentColor;
}

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

input,
button,
textarea,
select {
    font-family: inherit;
    font-size: inherit;
}

textarea:not([rows]) {
    min-height: 10em;
}

:target {
    scroll-margin-block: 5ex;
}

/* =============================================== */
/* Utility classes */

.container {
    margin: 229px auto;
    max-width: 1236px;
    padding: 0 60px;
}

@media (36em <=width <=48em) {
    .container {
        margin: 83px auto;
        padding: 0 60px;
    }
}

@media (width < 36em) {
    .container {
        margin: 73px auto;
        padding: 0 35px;
    }
}

.text-present-1 {
    font-size: var(--fs-20);
    font-family: "Barlow Semi Condensed";
    font-weight: 600;
    font-style: normal;
    line-height: 1.2;
    letter-spacing: 0;
}

.text-present-2 {
    font-size: var(--fs-13);
    font-family: "Barlow Semi Condensed";
    font-weight: 500;
    font-style: normal;
    line-height: 1.1;
    letter-spacing: 0;
}

.text-present-3 {
    font-size: var(--fs-13);
    font-family: "Barlow Semi Condensed";
    font-weight: 500;
    font-style: normal;
    line-height: 1.4;
    letter-spacing: 0px;
}

.text-present-4 {
    font-size: var(--fs-11);
    font-family: "Barlow Semi Condensed";
    font-weight: 500;
    font-style: normal;
    line-height: 1.1;
    letter-spacing: 0px;
}

.bg-purple-500 {
    background-color: rgb(var(--clr-purple-500));
}

.bg-grey-500 {
    background-color: rgb(var(--clr-grey-500));
}

.bg-white {
    background-color: rgb(var(--clr-white));
}

.bg-dark-blue {
    background-color: rgb(var(--clr-dark-blue));
}

/* =============================================== */
/* Custom components */
.grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
}

article:nth-child(1) {
    grid-column: 1 / span 2;
}

article:nth-child(4) {
    grid-column: 2 / span 2;
}

article:nth-child(5) {
    grid-column: 4;
    grid-row: 1 / 3;
}

@media (36em <=width <=48em) {
    .grid {
        grid-template-columns: repeat(2, 1fr);
    }

    article:nth-child(4) {
        grid-column: 1 / span 2;
    }

    article:nth-child(5) {
        grid-column: 1 / span 2;
        grid-row: auto;
    }
}

@media (width < 36em) {
    .grid {
        grid-template-columns: 1fr;
    }
    
    article:nth-child(1),
    article:nth-child(2),
    article:nth-child(3),
    article:nth-child(4),
    article:nth-child(5) {
        grid-column: auto;
        grid-row: auto;
    }
}

article {
    border-radius: 8px;
    padding: 32px;
    box-shadow: 40px 60px 50px -47px rgb(var(--clr-grey-500), 0.2474);
}

article:nth-child(1) {
    color: rgb(var(--clr-white));
    position: relative;
    z-index: 1;
}

.absolute {
    position: absolute;
    top: 0;
    right: 60px;
    z-index: -1;
}

@media (width < 36em) {
    .absolute {
display: none;
    }
}

article:nth-child(1) .author p:last-child,
article:nth-child(1)> :last-child {
    color: rgb(var(--clr-purple-50));
}

article:nth-child(2) {
    color: rgb(var(--clr-white));
}

article:nth-child(2) .author p:last-child,
article:nth-child(2)> :last-child {
    color: rgb(var(--clr-grey-100));
}

article:nth-child(3) {
    color: rgb(var(--clr-grey-500));
}

article:nth-child(3) .author p:last-child,
article:nth-child(3)> :last-child {
    color: rgb(var(--clr-grey-400));
}

article:nth-child(4) {
    color: rgb(var(--clr-white));
}

article:nth-child(4) h2 {
    color: rgb(var(--clr-grey-200));
}

article:nth-child(4)> :last-child {
    color: rgb(var(--clr-grey-100));
}

article:nth-child(5) {
    color: rgb(var(--clr-grey-500));
}

article:nth-child(5) .author p:last-child,
article:nth-child(5)> :last-child {
    color: rgb(var(--clr-grey-400));
}

.heading {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

h2 {
    margin-bottom: 16px;
}

article .img img {
    border-radius: 50%;
    width: 28px;
}

article:first-child .img img {
    border: 2px solid rgb(var(--clr-purple-300));
}


article:nth-last-child(2) .img img {
    border: 2px solid rgb(var(--clr-purple-500));
}