/* CSS Variables */
:root {
  --color-ice-cold: #c5c6c7;
  --color-primary: #66fcf1;
  --color-primary-heavy: #45a29e;
  --color-bg: #0d0e10;
  --color-bg-secondary: #1f2833;
  --color-text: white;
  --color-text-light: rgb(203, 203, 203);
}
:root.light {
  --color-bg: white;
  --color-text-light: rgb(75, 75, 75);
  --color-text: black;
  --color-primary: #45a29e;
  --color-primary-heavy: #66fcf1;
  --color-bg-secondary: #c5c6c7;
}
/* Global Styling */
*,
*::after,
*::before {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Outfit", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  color: var(--color-text);
  background-color: var(--color-bg);
  background-image: url(./images/blob.svg);
  background-repeat: no-repeat;
  background-size: cover;
  transition: background 0.5s ease-in-out;
  position: relative;
  accent-color: var(--color-primary);
}
a {
  color: inherit;
}
input,
button,
textarea,
select {
  font: inherit;
  background-color: transparent;
  border: none;
  outline: none;
  color: inherit;
}
button {
  color: var(--color-text);
  border: 2px solid var(--color-primary);
  padding: 0.4em;
  border-radius: 0.1em;
  outline: none;
  background: var(--color-bg);
  transition: all 0.3s ease-in-out;
  margin: 0.5em 0;
  text-transform: uppercase;
  font-weight: 700;
  cursor: pointer;
}
button:hover {
  background-color: var(--color-primary);
  color: var(--color-bg);
}
p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
  font-weight: inherit;
  margin-bottom: 1em;
}
p {
  text-wrap: pretty;
  font-size: 1.125rem;
  max-inline-size: 65ch;
}
h1 {
  font-weight: 500;
  margin-bottom: 0;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  text-wrap: balance;
}
.container {
  min-height: 100vh;
  display: flex;
  flex-flow: column nowrap;
}
.icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  padding: 10px;
  border-radius: 50%;
  transition: all 0.4s ease-in;
  cursor: pointer;
}
.icon-box:hover {
  color: var(--color-bg);
  background-color: var(--color-primary);
}
/* Popup Form */
.popup {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: -100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}
.popup.active {
  opacity: 1;
  z-index: 100;
}
.popup-form {
  background-color: var(--color-bg);
  flex: 0 1 350px;
  border-radius: 5px;
  padding: 1rem;
  display: flex;
  flex-flow: column nowrap;
  gap: 0.5rem;
}
.popup-form .popup-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.popup-form .form-control label {
  display: inline-block;
  margin-bottom: 5px;
  font-size: 0.975;
  color: var(--color-text-light);
}
.popup-form .form-control input {
  font-size: 1rem;
  display: block;
  width: 100%;
  margin-bottom: 0;
  border-bottom: 2px solid rgb(168, 168, 168);
}
.popup-form .form-control.correct input {
  border-color: rgb(5, 189, 140);
  /* margin-bottom: 6px; */
}
.popup-form .form-control.error input {
  border-color: #ff7675;
}
.popup-form .form-control.error small {
  visibility: visible;
}
.popup-form .form-control small {
  color: #ff7675;
  visibility: hidden;
}
.popup-form .checkbox {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
}
/* Header */
.header {
  padding: 5px 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.header .logo {
  display: flex;
  align-items: center;
  gap: 5px;
}
.header .logo i.logo-icon {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-primary);
}
.color-mode {
  position: relative;
}

.color-mode i {
  transition: opacity 0.3s ease;
}
.color-mode i.bx-moon {
  position: absolute;
  opacity: 0;
}
:root.light .color-mode i.bx-sun-bright {
  opacity: 0;
}
:root.light .color-mode i.bx-moon {
  opacity: 1;
}
/* Main */
.main {
  flex: 1;
  display: flex;
  flex-flow: row-reverse wrap;
  padding: 2rem;
  gap: 1rem;
}
.main .cards-wrapper {
  flex: 4 1 900px;
  min-height: 50vh;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  grid-auto-rows: max-content;
  gap: 2rem;
}
.main .cards-wrapper .card {
  background-color: var(--color-bg);
  border-left: 3px solid var(--color-primary);
  padding: 0.5rem;
  border-radius: 0.5rem;
  display: flex;
  flex-flow: column nowrap;
  justify-content: space-between;
  gap: 1rem;
  box-shadow: 3px 3px 15px -2px rgb(0, 0, 0);
}
.main .cards-wrapper .card h2 {
  font-size: 1.3rem;
  margin-bottom: 0.1em;
}
.main .cards-wrapper .card h3.author {
  font-size: 1rem;
  color: var(--color-ice-cold);
}
.main .cards-wrapper .card span.read-status-label {
  font-size: 14px;
  color: var(--color-bg);
  padding: 4px;
  border-radius: 4px;
}
.main .cards-wrapper .card span.read-status-label[data-status="true"] {
  background-color: var(--color-primary);
}
.main .cards-wrapper .card span.read-status-label[data-status="false"] {
  background-color: #ff7675;
}
.main .cards-wrapper .card .card-utils {
  display: flex;
  flex-flow: row wrap;
  justify-content: space-between;
  align-items: center;
}
.card .card-utils .card-btns {
  display: flex;
  flex-flow: row nowrap;
  gap: 0.5rem;
}
.main .cards-wrapper .card .card-utils .card-btns .btn {
  font-size: 12px;
}
.card .card-utils .card-btns .delete-btn {
  border-color: #ff7675;
}
.card .card-utils .card-btns .delete-btn:hover {
  background-color: #ff7675;
}
.main .cards-wrapper .card .card-utils span.pages {
  font-size: 1.5rem;
  font-family: "Sriracha", cursive;
  font-weight: 400;
  font-style: normal;
}
:root.light .main .cards-wrapper .card,
:root.light .main .library-info {
  box-shadow: 3px 3px 12px -2px rgba(0, 0, 0, 0.61);
}
/* Library Info */
.main .library-info {
  flex: 1 0 250px;
  align-self: flex-start;
  display: flex;
  flex-flow: column wrap;
  box-shadow: 3px 3px 15px -2px rgb(0, 0, 0);
  background-color: var(--color-bg);
  padding: 0.5rem 1rem;
}
.main .library-info ul {
  padding: 1rem;
}
.main .library-info span {
  font-family: "Sriracha", cursive;
  font-size: 1.5rem;
}
.main .library-info h1 {
  font-size: 1.25rem;
  border-bottom: 2px solid var(--color-primary);
}
/* Footer */
.footer {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.2rem;
}
