/*
# Front-end Style Guide

## Layout

The designs were created to the following widths:

- Mobile: 375px
- Desktop: 1440px

## Colors

### Primary

- Red: hsl(0, 100%, 74%) 
- Green: hsl(154, 59%, 51%)

### Accent
- Blue: hsl(248, 32%, 49%)

### Neutral

- Dark Blue: hsl(249, 10%, 26%) 
- Grayish Blue: hsl(246, 25%, 77%)

## Typography

### Body Copy

- Font size: 16px

### Font

- Family: [Poppins](https://fonts.google.com/specimen/Poppins)
- Weights: 400, 500, 600, 700
*/
/* import font*/

@import url("https://fonts.googleapis.com/css?family=Poppins&display=swap");

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

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;
}

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

:root {
  --primary-bg-red: hsl(0, 100%, 74%);
  --primary-bg-neutral-dark: hsl(249, 10%, 26%);
  --primary-bg-neutral-light: hsl(246, 25%, 77%);
  --primary-bg-accent: hsl(248, 32%, 49%);
  --button-primary: hsl(154, 59%, 51%);
  --text-white: white;
  --text-size: 16px;
}

body {
  margin: 0;
  font-family: "Poppins";
  background: url("../../images/bg-intro-desktop.png"), var(--primary-bg-red);
  background-blend-mode: screen;
  font-size: var(--text-size);
  line-height: 1.5rem;
}
p {
  font-weight: 200;
  font-size: 0.75rem;
  letter-spacing: 0.036rem;
}

h1 {
  margin-top: 0.5rem;
  margin-left: 0.5rem;
  margin-bottom: 1rem;
  line-height: 2rem;
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: 0.053rem;
}
div {
  width: 90%;
}

.text-bold {
  font-weight: 600;
}

main {
  margin-top: 4rem;
  padding-left: 1rem;
  padding-right: 1rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-gap: 2rem;
  align-items: center;
}
.intro {
  display: grid;
  justify-self: right;
  text-align: left;
  color: var(--text-white);
  width: 100%;
  max-width: 50vmin;
}
.heading {
  padding-right: 2rem;
  max-width: 25ch;
}

form {
  display: grid;
  grid-auto-flow: row;
  grid-row-gap: 1.5rem;
  justify-items: left;
}

.formHeading {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  background: var(--primary-bg-accent);
  border-radius: 0.4rem;
  box-shadow: 0px 0.45rem hsla(249, 10%, 26%, 0.2);
  color: var(--text-white);
  font-size: 0.75rem;
  text-align: center;
  justify-content: center;
  font-weight: 100;
  width: 100%;
  max-width: 50vmin;
}

fieldset {
  display: grid;
  grid-auto-flow: row;
  grid-row-gap: 0.5rem;
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
  background: white;
  border-radius: 0.7rem;
  box-shadow: 0px 0.5rem 0.2rem hsla(249, 10%, 26%, 0.2);
  align-items: center;
  justify-items: center;
  width: 100%;
  max-width: 50vmin;
}

.form-input-text {
  width: 100%;
  justify-self: center;
  padding: 10px 18px;
  border: 1.5px solid lightgray;
  border-radius: 0.2rem;
  font-family: "Poppins";
  font-size: 0.7rem;
  letter-spacing: 0.05rem;
  font-weight: 400;
}

.visually-hidden {
  border-width: 0;
  clip: rect(0, 0, 0, 0);
  height: 1px;
  overflow: hidden;
  position: absolute;
  width: 1px !important;
}

.btn-primary {
  width: 90%;
  padding: 10px 18px;
  border-radius: 0.2rem;
  border: 0.5px solid var(--button-primary);
  background-color: var(--button-primary);
  box-shadow: inset 0 0 0.03rem 0.03rem hsl(154.1, 95%, 31.6%),
    0 0.2rem 0.07rem 0.02rem hsl(154.1, 95%, 31.6%);
  color: var(--text-white);
  text-transform: uppercase;
  font-family: "Poppins";
  font-size: 0.8rem;
  letter-spacing: 0.05rem;
  justify-self: center;
  font-weight: 500;
}

.infoalert {
  padding-top: 0;
  font-size: 0.7rem;
  max-width: 35ch;
  font-weight: 500;
  text-align: center;
  line-height: 1rem;
  letter-spacing: 0.063;
  color: var(--primary-bg-neutral-light);
}
.text-red {
  color: var(--primary-bg-red);
}
.error {
  border: 2px solid var(--primary-bg-red);
}
.error:focus-visible {
  outline: 0.5px solid var(--primary-bg-red);
}

.hidden {
  display: none;
}

.img-invalid {
  width: 4%;
  height: 4%;
  float: right;
  position: relative;
  margin-top: -1.7rem;
  margin-right: 1.5rem;
}

.invalid {
  float: right;
  font-size: 0.5rem;
  letter-spacing: 0.044rem;
  color: var(--primary-bg-red);
}

@media (max-width: 480px) {
  body {
    background: url("../../images/bg-intro-mobile.png"), var(--primary-bg-red);
  }
  h2 {
    max-width: 20ch;
  }
  main {
    grid-template-columns: repeat(1, 1fr);
    grid-auto-flow: row;
    grid-row-gap: 1rem;
  }

  .intro {
    text-align: center;
    justify-self: center;
    max-width: 90%;
  }

  form {
    justify-items: center;
  }

  .formHeading {
    display: flex;
    justify-content: center;
    text-align: center;
    min-width: 90%;
  }
  fieldset {
    grid-row-gap: 1rem;
    max-width: 90%;
  }

  .img-invalid {
    width: 5%;
    height: 5%;
  }
}
