/* general styling */
* {
  padding: 0;
  margin: 0;
  font-family: var(--font, arial);
  box-sizing: border-box;
  color: var(--color4);
  caret-color: var(--color4);
}

.hidden {
  display: none;
}

.no-scroll {
  overflow: hidden;
}

/* elements */
body {
  height: 100vh;
  display: flex;
  flex-direction: column;
  --font: roboto;

  /* global variables */

  /* theme applied */
  --color1: var(--teal1);
  --color2: var(--teal2);
  --color3: var(--teal3);
  --color4: var(--teal4);

  /* color palletes */

  /* teal */
  --teal1: #e9efec;
  --teal2: #c4dad2;
  --teal3: #6a9c89;
  --teal4: #16423c;

  /* pink */
  --pink1: #f3dbe3;
  --pink2: #ecc5d1;
  --pink3: #b37489;
  --pink4: #340914;

  /* yellow */
  --yellow1: #f9ffd6;
  --yellow2: #f7ffad;
  --yellow3: #a4ad4f;
  --yellow4: #394600;

  /* green */
  --green1: #dbead7;
  --green2: #94c186;
  --green3: #558745;
  --green4: #20331a;

  /* sky  */
  --sky1: #e8f3fe;
  --sky2: #a4cefc;
  --sky3: #5076a5;
  --sky4: #000441;

  /* purple */
  --purple1: #faf0ff;
  --purple2: #f3ccff;
  --purple3: #805a96;
  --purple4: #2f0141;

  /* brown */
  --brown1: #ede0d4;
  --brown2: #e6ccb2;
  --brown3: #b08968;
  --brown4: #2a0800;

  /* gray */
  --gray1: #f8f9fa;
  --gray2: #adb5bd;
  --gray3: #6c757d;
  --gray4: #212529;
}

header {
  background-color: var(--color1);
  font-size: 60px;
  font-style: italic;
  font-weight: bold;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 50px 100px;
}

.change-color {
  display: none;
  color: var(--color2);
  font-size: 20px;
  position: absolute;
  right: 0;
  top: 0;
  line-height: 100px;
  background-color: var(--color4);
  width: 80px;
  height: 100px;
  text-align: center;
}

.theme-palette {
  position: absolute;
  right: 0;
  top: 0;
  line-height: 100px;
  background-color: var(--color4);
  width: 50px;
  height: 100px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  row-gap: 5px;
  flex-direction: column;
}

.color {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  cursor: pointer;
}

.color:hover {
  transform: scale(1.2);
}

.color:active {
  transform: scale(1);
}

.teal {
  background-color: var(--teal3);
}

.purple {
  background-color: var(--purple3);
}

.yellow {
  background-color: var(--yellow3);
}

.green {
  background-color: var(--green3);
}

.sky {
  background-color: var(--sky3);
}

.pink {
  background-color: var(--pink3);
}

.brown {
  background-color: var(--brown3);
}

.gray {
  background-color: var(--gray3);
}

section {
  background-color: var(--color2);
  max-width: 100vw;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  padding: 40px 40px;
  gap: 20px 20px;
  flex-grow: 1;
}

/* classes */

/* default mode */
.add-note,
.note {
  background-color: var(--color3);
  width: 300px;
  height: 200px;
  border-radius: 10px;
  cursor: pointer;
}

.add-note {
  color: var(--color1);
  text-shadow: 5px 5px 5px var(--color4);
  font-size: 200px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.note {
  font-size: 20px;
  padding: 15px 20px;
  line-height: 1.5;
  overflow: hidden;
  text-overflow: ellipsis;
}

.add-note:hover,
.note:hover {
  transform: scale(1.02);
  box-shadow: 5px 5px 15px var(--color4);
}

.note:active,
.add-note:active {
  transform: scale(0.98);
}

/* zoom mode */
.overlay {
  display: none;
  /* justify-content: center;
  align-items: center; */
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgb(0, 0, 0, 0.6);
  z-index: 1;
}

.zoomed-note {
  background-color: var(--color3);
  border-radius: 10px;
  width: 90vw;
  height: 90vh;
  position: absolute;
  left: calc(50% - 45vw);
  top: calc(50% - 45vh);
  z-index: 2;
  padding: 20px;
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: center;
  justify-content: center;
}

.text-content {
  background-color: var(--color1);
  width: 95%;
  height: 85%;
  padding: 30px;
  border-radius: 10px;
  font-size: 30px;
  overflow: auto;
}

.button {
  background-color: var(--color4);
  color: var(--color1);
  width: 30%;
  height: 10%;
  border-radius: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 25px;
  box-shadow: 2px 2px 2px black;
  cursor: pointer;
  margin: auto;
}

.button:hover {
  transform: scale(1.02);
  box-shadow: 5px 5px 10px black;
  color: var(--color2);
}

.button:active {
  transform: scale(0.95);
}

/* Responsive styling */

/* medium screens  */
@media (max-width: 800px) {
  header {
    height: 80px;
    font-size: 50px;
    padding: 30px 60px;
  }

  .theme-palette {
    height: 80px;
    width: 40px;
    row-gap: 5px;
  }

  .color {
    width: 15px;
    height: 15px;
  }

  .add-note,
  .note {
    width: 240px;
    height: 120px;
    font-size: 100px;
  }

  .note {
    font-size: 15px;
    line-height: 1.4;
  }
}

/* small screens  */
@media (max-width: 400px) {
  header {
    height: 80px;
    font-size: 40px;
    padding: 20px 40px;
  }

  .add-note,
  .note {
    width: 240px;
    height: 120px;
    font-size: 100px;
  }

  .note {
    font-size: 15px;
  }
}
