* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: #f8faf9;
  color: #1e293b;
  font-family: "Inter", sans-serif;
}

.app {
  display: flex;
  height: 100vh;
}

/* ── Sidebar ── */

.sidebar {
  width: 72px;
  background: white;
  border-right: 1px solid #e5e7eb;
  padding: 20px 12px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow: hidden;
  flex-shrink: 0;
  transition: width 0.3s ease;
}

.sidebar:hover {
  width: 220px;
}

/* Logo */

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 2px;
}

.logo-icon {
  cursor: pointer;
  width: 32px;
  height: 32px;
  background: #111827;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.logo-text {
  font-size: 13px;
  font-weight: 600;
  color: #111827;
  white-space: nowrap;
  opacity: 0;
  width: 0;
  overflow: hidden;
  transition: opacity 0.2s ease;
}

.sidebar:hover .logo-text {
  opacity: 1;
  width: auto;
}

/* New Entry button */

.new-entry-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #111827;
  color: #e5e7eb;
  border: none;
  border-radius: 10px;
  padding: 11px 16px;
  cursor: pointer;
  white-space: nowrap;
  width: 100%;
  transition: background 0.2s ease;
}

.new-entry-btn:hover {
  background: #3c475a;
}

.new-entry-btn svg {
  flex-shrink: 0;
}

.new-entry-btn span {
  font-size: 13px;
  font-weight: 500;
  opacity: 0;
  width: 0;
  overflow: hidden;
  transition: opacity 0.2s ease;
}

.sidebar:hover .new-entry-btn span {
  opacity: 1;
  width: auto;
}

/* Menu items */

.sidebar-menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  border-radius: 10px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s ease;
}

.menu-item svg {
  flex-shrink: 0;
  color: #374151;
}

.menu-item span {
  font-size: 14px;
  color: #374151;
  opacity: 0;
  width: 0;
  overflow: hidden;
  transition: opacity 0.2s ease;
}

.sidebar:hover .menu-item span {
  opacity: 1;
  width: auto;
}

.menu-item:hover {
  background: #f3f4f6;
}

.menu-item.active {
  background: #c5ebd6;
}

.menu-item.active svg,
.menu-item.active span {
  color: #065f46;
}

/* ── Main section ── */

.main-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 24px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  background: white;
}

.nav-logo {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #eff1f0;
  padding: 6px 14px;
  border-radius: 999px;
}

.search-box input {
  border: none;
  outline: none;
  background: transparent;
  font-size: 13px;
  width: 160px;
  color: #111827;
  font-family: inherit;
}

.search-box input::placeholder {
  color: #9ca3af;
}

.icon-btn {
  border: none;
  background: #f8faf9;
  border-radius: 50%;
  height: 34px;
  width: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #374151;
  transition: background 0.2s ease;
}

.icon-btn:hover {
  background: #111827;
  color: white;
}

.dashboard {
  flex: 1;
  background: #f8faf9;
  padding: 24px;
  overflow-y: auto;
}

.hero-card {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  background-color: #e1e3e2;
  border-radius: 30px;
  padding: 20px;
}

.hero-right button {
  border-radius: 10px;
  outline: none;
  background-color: #111827;
  color: white;
  font-weight: 400;
  padding: 10px;
  white-space: nowrap;
  border: none;
  cursor: pointer;
  transition: 0.2s all ease;
}
.hero-right button:hover {
  background: #1f2937;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transform: translateY(-0.5px);
  transition: all 0.2s ease;
}

.hero-right {
  flex-shrink: 0;
  display: flex;
  align-self: stretch;
  align-items: flex-end;
}

.badge {
  background-color: #d1fae5;
  color: #065f46;
  border-radius: 30px;
  padding: 10px;
  display: inline-block;
  margin-bottom: 8px;
}

.hero-sub {
  margin-top: 8px;
  font-size: 14px;
  color: #6b7280;
  max-width: 520px;
  line-height: 1.6;
}

.hero-stat {
  font-weight: 700;
  font-size: 48px;
}

/* CSS for streak section */
.sections-row {
  padding: 20px;
  display: flex;
  /* align-items: center; */
  justify-content: space-between;
  margin-top: 24px;
}

.manage-habits {
  text-decoration: none;
  color: #6b7280;
  transition: 0.2s all ease;
}

.manage-habits:hover {
  color: #065f46;
}

.view-logs {
  text-decoration: none;
  color: #6b7280;
  transition: 0.2s all ease;
}

.view-logs:hover {
  color: #065f46;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px;
  gap: 0;
}

.streak-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: white;
  border-radius: 12px;
  padding: 14px;
  margin-top: 8px;
  transition: 0.2s all ease;
}

.streak-item:hover {
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.05),
    0 1px 3px rgba(0, 0, 0, 0.03);
}

.streak-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #d1fae5;
  flex-shrink: 0;
}

.streak-middle {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.progress-track {
  background: #e5e7eb;
  border-radius: 999px;
  height: 6px;
  width: 100%;
}

.progress-fill {
  height: 100%;
  border-radius: 999px;
  background: #111827;
  width: 65%;
}

.streak-section {
  width: 45%;
}
.journal-section {
  width: 45%;
}

.streak-days {
  flex-shrink: 0;
  font-size: 13px;
  color: #6b7280;
  white-space: nowrap;
}

.progress-fill.green {
  background: #059669;
  width: 40%;
}
.progress-fill.orange {
  background: #f97316;
  width: 18%;
}
.progress-fill.dark {
  background: #111827;
  width: 90%;
}

/* CSS for journal section */

.journal-timeline {
  display: flex;
  flex-direction: column;
  gap: 30px;
  padding: 10px;
}

.journal-entry {
  display: flex;
  flex-direction: row;
  gap: 14px;
}

.journal-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #9ca3af;
  flex-shrink: 0;
  position: relative;
  margin-top: 4px;
}

.journal-dot.current {
  background: #f97316;
}

.journal-content.current .journal-title:hover {
  color: #f97316;
}

.journal-dot::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 100%;
  transform: translateX(-50%);
  width: 2px;
  height: 300%;
  background: #e5e7eb;
  height: calc(100% + 80px);
}

/* .journal-dot::after:hover{
    background: #f97316;
  } */

.journal-entry:last-child .journal-dot::after {
  display: none;
}

.journal-content {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.journal-time {
  font-size: 11px;
  color: #9ca3af;
  letter-spacing: 0.05em;
}
.journal-title {
  font-size: 15px;
  font-weight: 600;
  color: #111827;
  line-height: 1.4;
  cursor: pointer;
}

.journal-entry .journal-title:hover {
  color: #065f46;
}

.journal-entry:hover {
  .journal-title {
    color: #065f46;
  }
  .journal-title.current {
    color: #f97316;
  }

  .journal-dot.current {
    background: #f97316;
  }
  .journal-dot {
    background: #065f46;
  }
}
.journal-preview {
  font-size: 13px;
  color: #6b7280;
  line-height: 1.6;
}
.journal-content.current .journal-preview:hover {
  .journal-title {
    color: #f97316;
  }
}

/* Modal Card CSS */

.modal-overlay {
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.4);

  /* Step 2: Apply the blur to what's behind the element */
  backdrop-filter: blur(10px);

  position: fixed;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  display: none;
}

.modal-overlay.active {
  display: flex;
}

.modal-card {
  display: flex;
  flex-direction: column;
  background: white;
  padding: 40px;
  border-radius: 20px;
  width: 100%;
  max-width: 480px;
  gap: 16px;
}

.option-card {
  display: flex;

  flex-direction: row;
  gap: 14px;
  background: #f3f4f6;
  border-radius: 12px;
  padding: 16px;
  cursor: pointer;
  font-size: 13px;
}

.option-card:hover {
  background: #e5e7eb;
}

.modal-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: #d1fae5;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-title,
.modal-description {
  display: flex;
  flex-direction: column;
  gap: 7px;
  flex: 1;
}

.modal-cancel {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px 22px;
  transition: 0.2s all ease;
  align-self: center;
}

.modal-cancel:hover {
  background: whitesmoke;
  border-radius: 30px;
  color: black;
  font-weight: 545;
  transform: translateY(-0.8px);
  flex-shrink: 0;
}

.modal-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.option-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.option-text h3 {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
}

.option-text p {
  font-size: 13px;
  color: #6b7280;
}

.modal-overlay-2 {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  align-items: center;
  justify-content: center;
  transition: 0.2s all ease;
}

.modal-overlay-2.active {
  display: flex;
}

.entry-title {
  width: 100%;
  padding: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  color: #111827;
}

.entry-title:focus {
  border-color: #059669;
}

.entry-body {
  width: 100%;
  padding: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  color: #111827;
  resize: none;
  height: 140px;
  line-height: 1.6;
}

.entry-body:focus {
  border-color: #059669;
}

.entry-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.entry-cancel-btn {
  background: none;
  border: none;
  color: #6b7280;
  font-size: 14px;
  cursor: pointer;
  padding: 10px 16px;
  border-radius: 10px;
}

.entry-cancel-btn:hover {
  background: #f3f4f6;
}

.entry-submit-btn {
  background: #111827;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 14px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease;
}

.entry-submit-btn:hover {
  background: #3c475a;
}

.modal-overlay-3 {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  align-items: center;
  justify-content: center;
  transition: 0.2s all ease;
}

.modal-overlay-3.active {
  display: flex;
}

.logs-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 400px;
  overflow-y: auto;
}

.log-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f3f4f6;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 14px;
  color: #111827;
}

.delete-btn {
  background: none;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  color: #ef4444;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.delete-btn:hover {
  background: #ef4444;
  color: white;
  border-color: #ef4444;
}

.modal-cancel-3 {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px 22px;
  align-self: center;
  color: #6b7280;
  font-size: 14px;
  transition: 0.2s all ease;
}

.modal-cancel-3:hover {
  background: whitesmoke;
  border-radius: 30px;
}

.modal-overlay-4 {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  align-items: center;
  justify-content: center;
}

.modal-overlay-4.active {
  display: flex;
}

.color-options {
  display: flex;
  gap: 12px;
}

.color-option {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  border: 3px solid transparent;
  transition: 0.2s all ease;
}

.color-option.active {
  border: 3px solid #111827;
  transform: scale(1.1);
}

.habit-name,
.habit-goal {
  width: 100%;
  padding: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  color: #111827;
}

.habit-name:focus,
.habit-goal:focus {
  border-color: #059669;
}

.habit-save-button {
  background: #111827;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 14px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease;
}

.habit-save-button:hover {
  background: #3c475a;
}

.habit-cancel-btn {
  background: none;
  border: none;
  color: #6b7280;
  font-size: 14px;
  cursor: pointer;
  padding: 10px 16px;
  border-radius: 10px;
}

.habit-cancel-btn:hover {
  background: #f3f4f6;
}

/* Focus Page CSS */

.focus {
  display: flex;
  flex: 1;
  background: #f0f7f4;
  overflow: hidden;
  overflow-y: auto;
}

.focus-main {
  width: 70%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #f0f7f4;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 60px;
}

.focus-timer {
  width: 480px;
  height: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 0.5px solid #5b7f6c;
  gap: 8px;
  position: relative;
  cursor: pointer;
  transition: 0.6s all ease;
}

.clicked {
  background: #57c785;
  background: radial-gradient(
    circle,
    rgb(46, 183, 103) 0%,
    rgb(59, 181, 148) 50%
  );
  .timer-label,
  .timer-display {
    color: white;
  }
  transform: scale(0.96);
}

.timer-display {
  display: flex;
  font-size: 110px;
  color: #111827;
  font-weight: 700;
  cursor: pointer;
}

.timer-label {
  color: #000;
  font-weight: 300;
}

.focus-queue {
  width: 30%;
  background: white;
  border-left: 1px solid #e5e7eb;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.focus-end-session-btn {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  padding: 10px 24px;
  font-size: 14px;
  cursor: pointer;
  color: #111827;
  transition: 0.2s all ease;
}

.focus-end-session-btn:hover {
  background: #f3f4f6;
}

.focus-sounds-btn {
  background: none;
  border: none;
  font-size: 13px;
  color: #6b7280;
  cursor: pointer;
}

.focus-main-footer {
  position: absolute;
  bottom: 24px;
  display: flex;
  width: 70%;
  justify-content: space-between;
  align-items: center;
  padding: 0 40px;
}

.current-task-label {
  font-size: 11px;
  letter-spacing: 0.1em;
  color: #6b7280;
  margin-top: 32px;
}

.current-task-text {
  font-size: 22px;
  font-weight: 600;
  color: #111827;
}

.session-streak {
  display: flex;
  gap: 6px;
  align-items: center;
}

.streak-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #e5e7eb;
}

.streak-dot.completed {
  background: #059669;
}

.queue-heading {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: #9ca3af;
}
/* 
  .queue-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 0;
    border-bottom: 1px solid #f3f4f6;
  } */

.queue-tag {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: #059669;
}

.queue-task-name {
  font-size: 14px;
  font-weight: 500;
  color: #111827;
}

.queue-sessions {
  font-size: 11px;
  color: #9ca3af;
}

.add-to-queue-btn {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 10px;
  font-size: 13px;
  cursor: pointer;
  color: #374151;
  margin-top: auto;
  transition: 0.2s all ease;
}

.add-to-queue-btn:hover {
  background: #f3f4f6;
}

.modal-overlay-5 {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  align-items: center;
  justify-content: center;
  transition: 0.2s all ease;
}

.modal-overlay-5.active {
  display: flex;
}

.task-name,
.task-sessions {
  width: 100%;
  padding: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  color: #111827;
}

.task-name:focus,
.task-duration:focus {
  border-color: #059669;
}

.task-submit-btn {
  background: #111827;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 14px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease;
}

.null-entry-error {
  color: red;
  font-size: 14px;
  margin-top: 8px;
}

/* .queue-delete-btn {
    background: none;
    border: 1px solid #57c785;
    color: #ef4444;
    font-size: 12px;
    cursor: pointer;
    padding: 4px 0;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: space-between;
  } */

.queue-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.queue-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #f3f4f6;
}

.queue-delete-btn {
  background: #f8faf9;
  border: 1px solid #e5e7eb;
  color: #ef4444;
  font-size: 12px;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.queue-delete-btn:hover {
  background: #ef4444;
  color: white;
  border-color: #ef4444;
}

.queue-play-btn {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  color: #111827;
  transition: 0.2s all ease;
}

.queue-play-btn:hover {
  background: #f3f4f6;
}

/* Builder's Journal Page CSS */
/* .builder-journal {
  display: flex;
  flex: 1;
  background: #f0f7f4;
  overflow: hidden;
  overflow-y: auto;
} */

/* .builder-main {
  width: 70%;
  height: 100%; */
  /* display: flex;
  justify-content: center;
  align-items: center; */
  /* background: #f0f7f4;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 60px;
} */

/* .journal-date-nav {
  align-self: flex-start;

}

.builder-row{
  display: flex;
  justify-content: space-between;
  margin-left: 2%;
  margin-top: 2%;
} */
