1
resposta

HTML e CSS: Atividade 11 (mobile-first)

<!DOCTYPE html>
<html lang="pt-br">
    <head>
        <meta charset="UTF-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <link rel="stylesheet" href="./styles/style.css">
        <link rel="stylesheet" href="./styles/reset.css">
        <link rel="icon" href="./assets/iconmudar.png" type="image/png">

        <title>AluraBooks</title>
    </head>
    <body>
        <h1>AluraBooks</h1>
    </body>
</html>


:root {
    --cor-de-fundo: #EBECEE;
}

body {
    background-color: var(--cor-de-fundo);
}

/* http://meyerweb.com/eric/tools/css/reset/ 
   v2.0 | 20110126
   License: none (public domain)
*/

html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
}
/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
    display: block;
}
body {
    line-height: 1;
}
ol, ul {
    list-style: none;
}
blockquote, q {
    quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
    content: '';
    content: none;
}
table {
    border-collapse: collapse;
    border-spacing: 0;
}
1 resposta

Oi, Anna Luiza! Como vai?

Agradeço por compartilhar seu código com a comunidade Alura.

Seu código HTML e CSS está bem organizado e estruturado, principalmente com o uso do :root para centralizar variáveis de cor. Isso facilita bastante a manutenção do projeto e torna seu CSS mais reutilizável.

Uma dica interessante para o futuro é usar media queries para aplicar o mobile-first de forma progressiva.Por exemplo:



body {
    font-size: 14px;
}

@media (min-width: 768px) {
    body {
        font-size: 16px;
    }
}

Esse código aumenta o tamanho da fonte quando a largura da tela for maior que 768px. Isso é útil para adaptar seu layout conforme o tamanho da tela.

Alura

Conte com o apoio da comunidade Alura na sua jornada. Abraços e bons estudos!