@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@100..900&display=swap');

/* Custom properties */
:root {
  --cl-black: #161718;
  --cl-white: #ffffff;
  --cl-accent: #13f0ae;
  --fs-3xl: 5rem;
  --fs-2xl: 3.2rem;
  --fs-xl: 2.8rem;
  --fs-lg: 2.2rem;
  --fs-md: 1.8rem;
  --fs-base: 1.6rem;
  --fs-sm: 1.4rem;
  --fs-xs: 1.2rem;
  --font-family: 'Outfit', sans-serif;
}

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

body,
h1,
h2,
h3,
h4,
h5,
p,
figure,
picture {
  margin: 0;
}

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

html {
  font-size: 62.5%;
}

body {
  background-color: var(--cl-black);
  color: var(--cl-white);
  line-height: 1.5;
  min-height: 100vh;
  font-family: var(--font-family);
  font-size: var(--fs-base);
  letter-spacing: normal;
  user-select: none;
}

h1,
h2,
h3,
h4,
h5 {
  font-weight: 400;
}

input,
button,
textarea,
select {
  font: inherit;
}

.alert {
  display: flex;
  align-items: center;
  gap: 1rem;
  position: absolute;
  top: 4rem;
  left: 50%;
  right: 50%;
  transform: translateX(-50%) translateY(-300%);
  width: fit-content;
  padding: 0.7rem 1.4rem;
  background-color: var(--cl-black);
  color: var(--cl-accent);
  border: 1px solid var(--cl-accent);
  font-size: var(--fs-sm);
  font-weight: 500;
  border-radius: 0.6rem;
  transition: transform 400ms ease-in-out;
}

.alert span svg {
  vertical-align: middle;
}

.alert.active {
  transform: translateX(-50%) translateY(0);
}

.generator {
  max-width: 80rem;
  height: 100vh;
  margin-inline: auto;
  padding-inline: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.generator-intro {
  text-align: center;
  margin-bottom: 4rem;
  font-weight: 600;
}
.generator-intro h2 {
  font-size: clamp(var(--fs-2xl), 6vw, var(--fs-3xl));
}
.generator-intro h3 {
  color: var(--cl-accent);
  font-size: var(--fs-base);
  text-transform: uppercase;
}

.generator-box {
  width: 100%;
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 3rem;
}

.generator-box > * {
  width: 100%;
}

.generated-password {
  /* height: 10.5rem; */
  padding: 2.2rem;
  box-shadow: 0 0px 3px rgba(255, 255, 255, 0.1);
  border-top-left-radius: 0.6rem;
  border-top-right-radius: 0.6rem;
  border-bottom: 2px solid var(--cl-accent);
  display: flex;
  align-items: center;
  gap: 1rem;
}
.generated-password > input {
  width: 100%;
  padding: 0.5rem 1rem;
  background-color: var(--cl-black);
  border: none;
  outline: none;
  color: var(--cl-white);
  font-size: var(--fs-lg);
}

.generated-password button {
  background-color: transparent;
  border: none;
  outline: none;
  cursor: pointer;
}
.generated-password button svg {
  color: var(--cl-white);
  opacity: 0.7;
  transition: all 300ms ease-in-out;
}
.generated-password button:hover svg {
  opacity: 1;
}

.password-settings {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding: 2.2rem;
  box-shadow: 0 0px 3px rgba(255, 255, 255, 0.1);
  border-radius: 0.6rem;
}

.settings-panel {
  display: flex;
  gap: 2rem;
}

.settings-panel > div {
  flex: 1;
}

.password-length .slider {
  margin: 0;
  margin-top: 2rem;
  -webkit-appearance: none;
  appearance: none;
  width: 20rem;
  height: 0.4rem;
  background-color: var(--cl-accent);
  border-radius: 0.6rem;
}
.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 1.5rem;
  height: 1.5rem;
  background: var(--cl-accent);
  cursor: pointer;
  border-radius: 50%;
}

.slider::-moz-range-thumb {
  width: 1.5rem;
  height: 1.5rem;
  background: var(--cl-black);
  cursor: pointer;
  border-radius: 50%;
}

.checkbox label {
  font-weight: 300;
}

.blog {
  margin: 10%;
  margin-top: 0;
  padding-top: 0;
  padding-bottom: 150px;
  align-items: center;
}

/* Add a black background color to the top navigation */
.topnav {
  margin-top: 10%;
  background-color: #161718;
  overflow: hidden;
  align-content: center;
  align-items: center;
  justify-content: center;
  display: flex;
}

/* Style the links inside the navigation bar */
.topnav a {
  float: left;
  color: #f2f2f2;
  text-align: center;
  padding: 14px 16px;
  text-decoration: none;
  font-size: 17px;
}

/* Change the color of links on hover */
.topnav a:hover {
  background-color: #ddd;
  color: black;
}

/* Add a color to the active/current link */
.topnav a.active, a.sitemap {
  background-color: #04AA6D;
  color: white;
}

/* Style inputs with type="text", select elements and textareas */
input[type=text], select, textarea {
  width: 100%;
  /* Full width */
  padding: 12px;
  /* Some padding */
  border: 1px solid #ccc;
  /* Gray border */
  border-radius: 4px;
  /* Rounded borders */
  box-sizing: border-box;
  /* Make sure that padding and width stays in place */
  margin-top: 6px;
  /* Add a top margin */
  margin-bottom: 16px;
  /* Bottom margin */
  resize: vertical /* Allow the user to vertically resize the textarea (not horizontally) */
}

/* Style the submit button with a specific background color etc */
input[type=submit] {
  background-color: #04AA6D;
  color: white;
  padding: 12px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

/* When moving the mouse over the submit button, add a darker green color */
input[type=submit]:hover {
  background-color: #45a049;
}

/* Add a background color and some padding around the form */
.contact-form {
  margin-bottom: 10%;
  margin: 10%;
  border-radius: 5px;
  background-color: #f2f2f2;
  padding: 20px;
  justify-content: center;
  display: flex;
}

footer {
  position: absolute;
  bottom: 4rem;
  width: 100%;
  display: flex;
  justify-content: center;
}

footer p {
  color: var(--cl-accent);
  text-align: center;
  font-size: var(--fs-xs);
  font-weight: 600;
}