:root {
  --white: #ffffff;

  --accent-600: #4863f7;
  --accent-500: #7878d7;

  --alert-600: #ff5c5c;

  --gray-900: #0d0d0d;
  --gray-800: #111111;
  --gray-700: #1a1a1a;
  --gray-200: #424242;
  --gray-100: #737373;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background-color: transparent;
}

::-webkit-scrollbar-thumb {
  background-color: var(--gray-100);
  border-radius: 8px;
}
body,
input,
button {
  font-family: "Inter", sans-serif;
}

body {
  background-color: var(--gray-900);
  color: var(--white);
}
.app {
  display: flex;
  height: 100vh;
  width: 100vw;
}

.main {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 62px 124px;
  gap: 32px;
  overflow-y: scroll;
}

.main-header {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 16px;
  width: 100%;
}

.btn-outline {
  display: flex;
  align-items: center;
  font-weight: 500;
  font-size: 14px;
  border-radius: 6px;
  cursor: pointer;
  gap: 10px;
  padding: 0 16px;
  height: 44px;
  background: rgba(27, 27, 27, 0.3);
  border: 0.5px solid var(--gray-200);
  color: var(--white);

  transition: background 0.5s;
}
.btn-outline:hover {
  background: var(--gray-200);
}

.btn-outline .icon {
  width: 20px;
  height: 20px;
  display: inline-block;
}

.btn-outline .text {
  color: var(--white);
}

.btn-primary {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 0 24px;
  width: 150px;
  height: 44px;
  border-radius: 6px;
  background: var(--accent-600);
  border: 1px solid var(--accent-500);
  color: var(--white);
  font-family: "Inter", sans-serif;
  font-weight: 500;
  font-size: 14px;
  cursor: pointer;
  transition: opacity 0.5s;
}
.btn-primary:hover {
  opacity: 0.5;
}

.btn-primary .text {
  color: var(--white);
}

.prompt-title {
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: 32px;
  color: var(--white);
  margin: 0;
  outline: none;
}

.prompt-content {
  font-family: "Inter", sans-serif;
  font-weight: 400;
  font-size: 16px;
  color: var(--white);
  line-height: 32px;
  outline: none;
}

.editable-wrapper {
  position: relative;
}

.editable-wrapper::before {
  content: attr(data-placeholder);
  position: absolute;
  color: var(--gray-200);
  pointer-events: none;
  opacity: 0;
}
.editable-wrapper.is-empty::before {
  opacity: 1;
}

#title-wrapper.is-empty {
  font-size: 32px;
  font-weight: 600;
  color: var(--gray-200);
}

#content-wrapper.is-empty {
  font-size: 16px;
  color: var(--gray-200);
  line-height: 32px;
}

.icon-button {
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
}

.open-toggle {
  position: absolute;
  top: 62px;
  left: 62px;
}

.sidebar {
  width: 400px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 50px;
  padding: 32px;
  background-color: var(--gray-800);
  border-right: 0.5px solid var(--gray-700);
}

.sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  height: 24px;
}
.sidebar-content {
  display: flex;
  flex-direction: column;
}
.search-container {
  display: flex;
  flex-direction: column;
  width: 100%;
  position: relative;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--gray-700);
  gap: 20px;
}
.search-icon {
  position: absolute;
  left: 16px;
  top: 22px;
  transform: translateY(-50%);
}
.search-icon img {
  width: 20px;
  height: 20px;
  display: block;
}
.search-input {
  width: 100%;
  padding: 12px 12px 12px 44px;
  border: none;
  border-radius: 8px;
  background: var(--gray-700);
  color: var(--white);
  font-size: 16px;
  font-family: "Inter", sans-serif;
  outline: none;
  transition: background 0.2s;
}
.search-input::placeholder {
  color: var(--gray-200);
  opacity: 1;
}

.btn-full {
  width: 100%;
}

.prompt-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.prompt-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  margin-top: 20px;
}
.prompt-item-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}
.prompt-item-title {
  font-family: "Inter", sans-serif;
  font-weight: 500;
  font-size: 14px;
  color: var(--white);
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}
.prompt-item-description {
  font-family: "Inter", sans-serif;
  font-weight: 400;
  font-size: 12px;
  color: var(--gray-100);
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}
.btn-icon {
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s;
}
.btn-icon:hover {
  opacity: 0.7;
}
.icon-trash {
  width: 20px;
  height: 20px;
  display: block;
}

@media (max-width: 950px) {
  .open-toggle {
    top: 38px;
    left: 24px;
  }

  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 80%;
    max-width: 360px;
    z-index: 1000;
  }

  .main {
    padding: 24px 32px;
    margin-left: 0;
    overflow-y: auto;
  }
}
