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

* {
  padding: 0;
  margin: 0;
}

:root {
  --clr-background: #fff;
  --clr-text: hsl(0, 0%, 18%);
  --clr-hr: #e9e9e9;
  --clr-search-bar: #f4f4f4;
  --clr-modal: #fff;
  --clr-drop-shadow: #2d2d2d;
}

html {
  font-size: 62.5%;
}

body {
  line-height: 1.6;
  min-height: 100vh;
  background-color: var(--clr-background);
  color: var(--clr-text);
}

body[data-font=serif] {
  font-family: "Lora", serif;
}

body[data-font=san-serif] {
  font-family: "Inter", sans-serif;
}

body[data-font=mono] {
  font-family: "Inconsolata", monospace;
}

.dark-mode {
  --clr-background: #050505;
  --clr-text: #fff;
  --clr-hr: #3a3a3a;
  --clr-search-bar: #1f1f1f;
  --clr-modal: #1f1f1f;
  --clr-drop-shadow: hsl(274, 82%, 60%);
}
.dark-mode .moon {
  filter: brightness(0) saturate(100%) invert(35%) sepia(74%) saturate(3090%) hue-rotate(254deg) brightness(93%) contrast(99%);
}

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

form,
select {
  font: inherit;
}

.container {
  width: min(100% - 6rem, 736px);
  margin-inline: auto;
  margin-top: 5rem;
}

.header {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  grid-template-rows: 1fr 1fr;
  align-items: center;
}
@media (max-width: 440px) {
  .header {
    grid-template-columns: 1fr;
  }
}
.header__img {
  display: flex;
}
.header__option {
  display: flex;
  justify-content: space-between;
  grid-column: 5/9;
  align-items: center;
}
@media (max-width: 550px) {
  .header__option {
    grid-column: 4/9;
  }
}
@media (max-width: 440px) {
  .header__option {
    margin-top: 2rem;
    grid-column: 1/-1;
  }
}

.font-select {
  position: relative;
}
.font__type {
  font-size: 1.6rem;
  padding: 0.5rem 3rem 0.5rem 1.5rem;
  border: 0;
  background-color: var(--clr-background);
  color: var(--clr-text);
  cursor: pointer;
  appearance: none;
  outline: 1px solid hsl(274deg, 82%, 60%);
}

.custom-arrow {
  position: absolute;
  width: 3rem;
  height: 100%;
  background-color: var(--clr-background);
  top: 0;
  right: 0;
  display: block;
  pointer-events: none;
  border-radius: 2px;
}
.custom-arrow::after {
  content: url("../assets/img/icon-arrow.svg");
  position: absolute;
  font-size: 1.5rem;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: hsl(274deg, 82%, 60%);
}

.search {
  grid-column: 1/-1;
  width: 100%;
  position: relative;
  margin-top: 4rem;
}
.search::after {
  content: url("../assets/img/icon-search.svg");
  display: block;
  position: absolute;
  right: 15px;
  bottom: 30%;
  z-index: 10;
}
.search-form {
  width: 100%;
}

.form-toggle {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

input[type=search] {
  padding-inline: 2.5rem;
  padding-block: 2.5rem;
  border: none;
  outline: none;
  border-radius: 6px;
  background-color: var(--clr-search-bar);
  color: var(--clr-text);
  font-family: inherit;
  font-size: 1.6rem;
  font-weight: 700;
  position: relative;
}
input[type=search]::placeholder {
  font-size: 0.8;
  color: #757575;
  font-weight: 700;
}
input[type=search]:focus {
  outline: 1px solid hsl(274deg, 82%, 60%);
}

.error-message {
  color: hsl(0deg, 100%, 66%);
  font-size: 1.6rem;
  width: max-content;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.reveal-message {
  opacity: 1;
  transform: translateY(0);
}

#check {
  display: none;
}

#check:checked + label .ball {
  transform: translate(21px);
}

.toggle-ball {
  display: flex;
  align-items: center;
  width: 4rem;
  height: 2.2rem;
  background-color: var(--clr-drop-shadow);
  border-radius: 50px;
  padding: 1px 3px;
  cursor: pointer;
}
.toggle-ball:hover, .toggle-ball:focus {
  background-color: hsl(274deg, 82%, 60%);
}

.ball {
  display: block;
  width: 18px;
  height: 18px;
  background-color: var(--clr-background);
  border-radius: 50%;
  transition: 0.3s ease;
  cursor: pointer;
}

.word {
  margin-top: 4rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.word__heading {
  font-size: 4.5rem;
  font-weight: 700;
}
.word__phonetics {
  font-size: 2.5rem;
  color: hsl(274deg, 82%, 60%);
}
.word__audio {
  background-color: transparent;
  border: none;
  cursor: pointer;
}
.word__definition {
  margin-top: 3rem;
}
.word__definition__heading {
  font-size: 2.5rem;
  font-weight: 700;
  font-style: italic;
  position: relative;
}
.word__definition__heading::after {
  content: "";
  display: block;
  position: absolute;
  width: 100%;
  height: 1px;
}
.word__definition__list {
  margin-top: 1.75rem;
  margin-left: 3rem;
}
.word__definition__list > li {
  font-size: 1.6rem;
  list-style-type: disc;
  color: var(--clr-text);
}
.word__definition__list > li::marker {
  color: hsl(274deg, 82%, 60%);
  margin-right: 1rem;
}
.word__definition__list > li:not(:last-child) {
  margin-bottom: 1rem;
}
.word__definition__synonym {
  font-size: 1.8rem;
  color: #757575;
  margin-top: 4rem;
  display: grid;
  grid-template-columns: max-content 1fr;
  column-gap: 4rem;
  row-gap: 2rem;
}
@media (max-width: 500px) {
  .word__definition__synonym {
    grid-template-columns: 1fr;
  }
}
.word__definition__synonym__example {
  color: hsl(274deg, 82%, 60%);
  font-weight: 700;
  display: flex;
  flex-wrap: wrap;
  gap: 3rem;
}
.word__example {
  color: #757575;
  margin-top: 1rem;
}

.meaning {
  margin-top: 3rem;
  font-size: 2rem;
  color: #757575;
}

.hr {
  width: 100%;
  border: 0.5px solid #e9e9e9;
  display: block;
}
.hr__con {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.source {
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-top: 4rem;
  border-top: 1px solid #e9e9e9;
  padding-top: 2.5rem;
  margin-bottom: 4rem;
}
.source__heading {
  color: #757575;
  font-weight: 400;
}
.source__url {
  font-size: 1.25rem;
  display: flex;
  gap: 0.5rem;
  color: inherit;
}

[type=search]::-webkit-search-cancel-button,
[type=search]::-webkit-search-decoration {
  -webkit-appearance: none;
  appearance: none;
}

/*# sourceMappingURL=style.css.map */
