/* == BASE STYLES == */
@import url("https://fonts.googleapis.com/css2?family=Lato:wght@300&display=swap");

/* VARIABLES */
:root {
    --ligth-gray: #b4becb;
    --dark-gray: #333;
    --blue: #047aed;
    --dark-blue: #1c3fa8;
    --shadow-blue: #002240;
    --light-bg: #f4f4f4;
    --success-color: #5cb85c;
}


/* RESETS */
*,
::before,
::after {
  box-sizing: border-box;
  padding: 0;
  margin: 0;
}

body {
    font-family: 'Lato', sans-serif;
    color: var(--dark-gray);
    line-height: 1.6;
}


ul {
    list-style-type: none;
}


a {
    text-decoration: none;
    color: var(--dark-gray);
}

h1,
h2,
h3 {
    font-weight: 300;
    line-height: 1.2;
    /* ou padding: .5em 0; nesse caso, não haveria colapso de margem */
    margin: .5em 0;
}

p {
    margin: .5em 0;
}

img {
    max-width: 100%;
}

form input {
    font-family: inherit;
    font-size: inherit;
    font-weight: bold;
    border: none;
}


/* NAVBAR */
.navbar {
    color: #fff;
    height: 70px;
}

.navbar ul {
    display: flex;
}

.navbar a {
    color: #fff;
    padding: .5em;
    margin: 0 .5em;
}

.navbar a:hover {
    border-bottom: 2px #fff solid;
}

/* se houver algum elemento com a classe .flex dentro da .navbar a propriedade a seguir será aplicada */
.navbar .flex {
    justify-content: space-between;
}


/* SHOWCASE */
.showcase {
    background-color: var(--blue);
    color: #fff;
    height: 25rem; /* altura de 400px baseado no font-size de 16px */
    position: relative;
}

.showcase .grid {
    grid-template-columns: 55% 45%;
    gap: 2rem;
    /* para o overflow do meu showcase-form ser visível */
    overflow: visible;
}

.showcase h2 {
    font-size: 2.5rem;
}

.showcase p {
    margin: 1em 0;
}

.showcase-form {
    width: 400px;
    position: relative;
    top: 60px;
    z-index: 100;
    justify-self: flex-end;
}

.showcase-form h3 {
    font-size: x-large;
}

.form-control {
    margin: 2em 0;
}

.form-control > input {
    width: 100%;
    border-bottom: 1px solid var(--ligth-gray);
}

.form-control > input:focus {
    outline: none;
}


.showcase::after { /* adicionando o slant */
    display: block;
    content: '';
    background-color: #fff;
    height: 100px;
    position: absolute;
    bottom: -70px;
    left: 0;
    right: 0;
    transform: skewY(-2deg);
}

/* STATS */
.stats-heading {
    max-width: 600px;
    margin: 2em auto;
    text-align: center;
    font-weight: bold;
}

.stats-info.flex {
    justify-content: space-around;
    text-align: center;
}


.stats-info h3 {
    font-size: 2rem;
    font-weight: bold;
}

.text-secondary {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--dark-blue);
}

.stats-card {
    font-weight: bold;
    padding: 1em 2em;
}

.cli .grid {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
}

.cli .grid :first-child {
    grid-column: 1 / span 2;
    grid-row: 1 / span 2;
}

/* Cloud */
.cloud {
    color: #fff;
    padding: 1em 0;
}

.cloud .grid {
    grid-template-columns: 4fr 3fr;
}

.cloud-info {
    text-align: center;
}

.cloud-info h2 {
    font-size: 3rem;
}

.cloud-info p {
    font-size: 1.3rem;
}

/* LANGUAGES */
.languages {
    text-align: center;
}

.languages .card {
    margin: 1em .625em;
    padding: 1em 1.3em;
    transition: transform 0.2s ease;
}

.languages .card:hover {
    transform: translateY(-10px);

}

.languages-heading {
    padding: 1.5em 0;
    font-size: 2rem;
}

.languages .flex {
    flex-wrap: wrap;
}

.languages .card h4 {
    margin-bottom: .5em;
}


/* FOOTER */
footer {
    padding: 3em 0;
    margin: 3rem 0 0;
}

.footer-heading {
    font-size: 2rem;
}

small {
    font-size: 1rem;
}

footer .grid {
    grid-template-columns: repeat(3, 1fr);
}

.bg-dark {
    background: var(--shadow-blue);
    color: #fff;
}

.footer-links a {
    color: #fff;
}

.social-media li {
    display: inline-block;
}


/* FEATURES */
.features-head {
    background: var(--blue);
    color: #fff;
}

.features-head img,
.docs-section img {
    width: 200px;
    justify-self: flex-end;
}


.features-subheading img {
    width: 300px;
    justify-self: flex-end;
}


.features-main .flex {
    justify-content: start;
}

.features-main .card {
    padding: 1em;
}

.features-main i {
    margin-right: .5em;
}

.features-main .grid > :first-child {
    grid-column: 1 / span 3;
}

.features-main .grid > :nth-child(2) {
    grid-column: 1 / span 2;
}



/* DOCS */
.docs-section {
    background: var(--blue);
    color: #fff;
}


.deployment-nav li {
    border-bottom: 1px solid var(--ligth-gray);
    padding: .5em 0;
}

.docs-main .grid {
    grid-template-columns: 1fr 2fr;
    align-items: flex-start;
}


.docs-main ul a:hover {
    color: #333;
    font-weight: bold;
}

.docs-main h3 {
    font-weight: bold;
}

.alert-success {
    background: var(--success-color);
    color: #fff;
    font-weight: bold;
    padding: .5em 1em;
}

.alert-success i {
    margin-right: 1em;
}

pre {
    background: var(--dark-gray);
    color: #fff;
}

/* Tablets and under */
@media (max-width: 780px) {
    .cli .grid,
    .cloud .grid,
    footer .grid,
    .features-head .grid,
    .features-subheading .grid,
    .features-main .grid,
    .docs-section .grid,
    .docs-main .grid {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr;
    }

    .stats-info.flex {
        flex-direction: column;
    }

    .features-head,
    .features-subheading,
    .docs-section {
        text-align: center;
    }

    .features-head img,
    .features-subheading img,
    .docs-section img {
        justify-self: center;
    }

    .features-main .grid :first-child,
    .features-main .grid :nth-child(2) {
        grid-column: 1;
    }

}


@media (max-width: 920px) {
    .showcase .grid {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr;
    }

    .showcase {
        height: auto;
    }

    .showcase-form {
        justify-self: center;
    }

    .showcase-text {
        text-align: center;
    }
}



/* Mobile */
@media (max-width: 500px) {
    .navbar {
        height: 8rem;
    }

    .navbar .flex {
        justify-content: center;
        flex-direction: column;
    }

    .showcase-form {
        max-width: 250px;
    }

    .cli .grid :first-child {
        grid-column: 1;
        grid-row: 1;
    }
}
