* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
}
body {
  font-family: "Inter", sans-serif;
}
.container {
  width: 100vw;
  min-height: 100vh;
  margin: 0;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
}
.color-select {
  display: flex;
  gap: 12px;
  width: 100%;
  height: 90px;
  align-items: center;
  justify-content: center;
  border: 1px solid #e5e7eb;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12);
  position: relative;
  z-index: 1;
}
input#base-color {
  width: 61px;
  height: 42px;
  border: 0.5px solid #d1d5db;
  background-color: #e5e5e5;
  cursor: pointer;
}
.select {
  position: relative;
  width: 312px;
}
.select-trigger {
  width: 100%;
  height: 42px;
  padding: 8px 20px 8px 12px;
  border: 0.5px solid #d1d5db;
  border-radius: 6px;
  background-color: #ffffff;
  cursor: pointer;
  font-family: inherit;
  font-size: 1rem;
  color: #111827;
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.select-trigger:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}
.select-arrow {
  width: 10px;
  height: 10px;
  border-right: 2px solid #6b7280;
  border-bottom: 2px solid #6b7280;
  transform: rotate(45deg);
  margin-left: 12px;
  flex-shrink: 0;
}
.select-options {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  width: 100%;
  margin: 0;
  padding: 6px 0;
  list-style: none;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
  max-height: none;
  overflow: visible;
  z-index: 10;
  display: none;
  scrollbar-width: none;
}
.select-options::-webkit-scrollbar {
  width: 0;
  height: 0;
}
.select.is-open .select-options {
  display: block;
}
.select-options [role="option"] {
  padding: 10px 14px;
  cursor: pointer;
  color: #111827;
}
.select-options [role="option"].is-active,
.select-options [role="option"]:hover {
  background: #f3f4f6;
}
.select-options [role="option"][aria-selected="true"] {
  font-weight: 600;
  position: relative;
}
.select-options [role="option"][aria-selected="true"]::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 10px;
  height: 6px;
  border-left: 2px solid #4f46e5;
  border-bottom: 2px solid #4f46e5;
  transform: translateY(-50%) rotate(-45deg);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(8px);
  background: #111827;
  color: #ffffff;
  padding: 10px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease, transform 150ms ease;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
  z-index: 999;
}
.toast.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
button#generate-scheme {
  background-color: #ffffff;
  color: #374151;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.75rem;
  width: 123px;
  height: 42px;
}

button#generate-scheme:hover,
button#generate-scheme:focus-visible {
  background-color: #f3f4f6;
}
button#generate-scheme:active {
  background-color: #e5e7eb;
}
.colors,
.hex-codes {
  display: flex;
  width: 100%;
}
.colors {
  flex: 1;
  align-content: stretch;
}
.color-0,
.color-1,
.color-2,
.color-3,
.color-4 {
  flex: 1 1 20%;
  cursor: pointer;
}
.color-0 {
  background-color: #f55a5a;
}
.color-1 {
  background-color: #2b283a;
}
.color-2 {
  background-color: #fbf3ab;
}
.color-3 {
  background-color: #aad1b6;
}
.color-4 {
  background-color: #a626d3;
}

.hex-codes {
  justify-content: center;
  align-items: center;
}
.hex-code {
  flex: 1 1 20%;
  height: 46px;
  font-size: 0.75rem;
  text-align: center;
  color: #2b283a;
  display: flex;
  justify-content: center;
  align-items: center;

  border: 1px solid #e5e7eb;
  cursor: pointer;
}

@media (min-width: 900px) {
  .color-select {
    height: 100px;
    gap: 16px;
  }

  input#base-color {
    width: 70px;
    height: 48px;
  }

  .select {
    width: 360px;
  }

  button#generate-scheme {
    width: 150px;
    height: 48px;
    font-size: 0.85rem;
  }

  .color-0,
  .color-1,
  .color-2,
  .color-3,
  .color-4 {
    flex-basis: 20%;
  }

  .hex-code {
    height: 54px;
    font-size: 0.85rem;
  }
}

@media (max-width: 600px) {
  .color-select {
    flex-wrap: wrap;
    height: auto;
    padding: 12px;
    gap: 10px;
  }

  .select {
    flex: 1 1 220px;
    width: auto;
  }

  input#base-color {
    flex: 0 0 61px;
  }

  button#generate-scheme {
    flex: 0 0 auto;
  }

  .colors,
  .hex-codes {
    flex-wrap: wrap;
  }

  .color-0,
  .color-1,
  .color-2,
  .color-3,
  .color-4,
  .hex-code {
    flex-basis: 50%;
  }
}

@media (max-width: 400px) {
  .color-0,
  .color-1,
  .color-2,
  .color-3,
  .color-4,
  .hex-code {
    flex-basis: 100%;
  }
}
