/* =========================
   RESET + BASE
========================= */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family:
    system-ui,
    -apple-system,
    Segoe UI,
    Roboto,
    Arial,
    sans-serif;
  color: #e9eef7;
  background-image: url("../assets/images/background.jpg");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

/* =========================
   LAYOUT
========================= */
.header {
  padding: 24px 16px 8px;
  text-align: center;
}

h1 {
  margin: 0 0 6px;
  font-size: 32px;
}

.subtext {
  margin: 0;
  opacity: 0.85;
}

.container {
  max-width: 720px;
  margin: 0 auto;
  padding: 16px;
  display: grid;
  gap: 14px;
}

/* =========================
   MOBILE NAV 
========================= */
/* NAV: one calm menu button */
.mobileNav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  justify-content: flex-end;
  padding: 12px 16px;
  background: transparent;
  gap: 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease 0.2s;
}

.mobileNav.isVisible {
  opacity: 1;
  pointer-events: auto;
}

/* Hide all nav buttons except the menu toggle */
.mobileNav button {
  display: inline-flex;
}

/* Show only the "menu" button */
.mobileNav #menuBtn {
  align-items: center;
  gap: 8px;
}

/* Only hide non-menu buttons */
.mobileNav button:not(#menuBtn) {
  display: none;
}

/* Always show menu button */
#menuBtn {
  display: inline-flex;
  background: transparent;
  border: 0;
  padding: 6px 8px;
  box-shadow: none;
}

/* Continue button fade (single source of truth) */
#todayContinueBtn {
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

#todayContinueBtn.isVisible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* “Ready when you are” fade */
#todayReadyText {
  opacity: 0;
  transition: opacity 0.6s ease;
}

#todayReadyText.isVisible {
  opacity: 1;
}

/* =========================
   SCREENS (ONE AT A TIME)
========================= */
.screen {
  display: none;
  min-height: 100vh;
  padding: 22px 16px;
  position: relative;
}

.screen .mobileNav {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  justify-content: flex-end;
  z-index: 10;
}

.screen.isActive {
  display: flex;
  justify-content: center;
  padding: 22px 16px;
}

/* A calm centered container inside screens */
.screenInner {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  display: grid;
  gap: 14px;
  justify-items: center;
  padding-top: 64px;
}

/* =========================
   CARDS (GLASS EFFECT)
========================= */
.card {
  background: rgba(20, 24, 36, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  padding: 20px;
  backdrop-filter: blur(6px);
  max-width: 600px;
  margin: 0 auto;
  /* NEW: depth */
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.card .row {
  justify-content: center;
}

/* Card reacts when user interacts inside it */
.card:has(button:active),
.card:has(button:focus-visible),
.card:has(input:focus),
.card:has(textarea:focus) {
  transform: scale(1.02);
  box-shadow:
    0 18px 45px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* =========================
   FORMS
========================= */
.row {
  display: flex;
  gap: 10px;
  margin-top: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

input,
textarea {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(15, 17, 25, 0.85);
  color: #e9eef7;
}

input {
  flex: 1;
}

textarea {
  resize: vertical;
  margin-top: 6px;
}

/* =========================
   BUTTONS
========================= */
button {
  padding: 12px 14px;
  border-radius: 12px;
  border: 0;
  cursor: pointer;
  background: #e9eef7;
  color: #0f1115;
  font-weight: 600;
  transition:
    background-color 0.15s ease,
    transform 0.05s ease;
  width: auto;
  min-width: 180px;
}

button:hover {
  background-color: rgba(255, 255, 255, 0.85);
}
button:active {
  transform: scale(0.97);
}

button.secondary {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #e9eef7;
}

button.secondary:hover {
  background-color: rgba(255, 255, 255, 0.12);
}

.btn-row {
  display: grid;
  gap: 12px;          /* ← this is the spacing between buttons */
  margin-top: 16px;  /* ← space between card and buttons */
  justify-items: center;
}

/* Continue button fade (single source of truth) */
#todayContinueBtn {
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

#todayContinueBtn.isVisible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Back button on Question screen: hidden by default */
#screen-question #backToTodayBtn {
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
}

/* When Question screen becomes active, animate it in after a delay */
#screen-question.isActive #backToTodayBtn {
  pointer-events: auto;
  animation: fadeInUp 0.7s ease forwards;
  animation-delay: 2s;
}

/* Keyframes (only needs to exist once in your CSS file) */
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#screen-brainDump .brainDumpBackBtn {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease;
  transition-delay: 2s;
}

#screen-brainDump.isActive .brainDumpBackBtn {
  opacity: 1;
  pointer-events: auto;
}
/* =========================
   VIBE PANEL
========================= */
.vibeRow {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  justify-content: center;
  flex-wrap: wrap;
}

.vibeRow button {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.vibeRow button:hover {
  background-color: rgba(255, 255, 255, 0.08);
}

.vibeRow button.selected {
  background-color: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.6);
}

.vibeGroup {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}

/* =========================
   TASK LIST
========================= */
.hint {
  margin-top: 10px;
  opacity: 0.75;
  font-size: 14px;
}

.list {
  list-style: none;
  padding: 0;
  margin-top: 10px;
}

.list li {
  padding: 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 8px;
  text-align: left;
}

.list li:hover {
  background: rgba(255, 255, 255, 0.08);
}
.done {
  opacity: 0.55;
}

/* =========================
   FOCUS + BREATHE OVERLAYS
========================= */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: grid;
  place-items: center;
  padding: 16px;
  z-index: 1000;
}

.overlay[hidden] {
  display: none !important;
}

.overlayCard {
  position: relative;
  width: 100%;
  max-width: 640px;
  border-radius: 18px;
  padding: 18px;
  overflow: hidden;
  background: #171a21;
}

.overlayCard .row {
  justify-content: center;
}

#focusNotes {
  width: 100%;
  max-width: 520px;
  min-height: 140px;

  margin: 12px auto 20px;
  display: block;

  padding: 14px;
  line-height: 1.5;
}

#menuOverlay {
  background: rgba(10, 12, 18, 0.95);
}

#menuOverlay .overlayCard {
  background: none;
  box-shadow: none;
  border: none;
}

#focusOverlay .overlayCard {
  background: url("../assets/images/focus-overlay.jpg") center / cover no-repeat;
}

#breatheOverlay .overlayCard {
  background: url("../assets/images/breathe-overlay.jpg") center / cover no-repeat;
}

#focusOverlay .overlayCard::before,
#breatheOverlay .overlayCard::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(10, 12, 18, 0.65);
}

#focusOverlay .overlayCard > *,
#breatheOverlay .overlayCard > * {
  position: relative;
  z-index: 1;
}

/* FULL-PAGE FOCUS overlay (all screens) */
#focusOverlay {
  place-items: stretch;
  padding: 0;
  text-align: center;
}

#focusOverlay .overlayCard {
  max-width: none;
  min-height: 100vh;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  padding: 32px 20px;
}

/* FULL-PAGE BREATHE overlay (all screens) */
#breatheOverlay {
  place-items: stretch;
  padding: 0;
  text-align: center;
}

#breatheOverlay .overlayCard {
  max-width: none;
  border-radius: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 22px 16px;
}

#breatheOverlay h1 {
  text-align: center;
  margin-bottom: 12px;
}

/* =========================
   BREATHE CIRCLE
========================= */
.breatheCircle {
  width: 180px;
  height: 180px;
  margin: 18px auto;
  border-radius: 50%;
  background: rgba(233, 238, 247, 0.08);
  border: 1px solid rgba(233, 238, 247, 0.2);
  box-shadow: 0 0 0 0 rgba(233, 238, 247, 0.18);
  animation: breathePulse 15s ease-in-out infinite;
  animation-play-state: paused;
}

.breatheCircle.isBreathing {
  animation-play-state: running;
}

@keyframes breathePulse {
  0% {
    transform: scale(0.88);
    box-shadow: 0 0 0 0 rgba(233, 238, 247, 0.12);
  }
  40% {
    transform: scale(1.05);
    box-shadow: 0 0 0 18px rgba(233, 238, 247, 0.08);
  }
  100% {
    transform: scale(0.88);
    box-shadow: 0 0 0 0 rgba(233, 238, 247, 0.12);
  }
}

@media (prefers-reduced-motion: reduce) {
  .breatheCircle,
  .breatheCircle.isBreathing {
    animation: none;
  }
}

/* =========================
   TEXT
========================= */
.focusText {
  font-size: 18px;
  margin: 10px 0;
}
.focusTaskText {
  font-size: 20px;
  margin: 8px 0 14px;
}

.header,
.card {
  text-align: center;
}

input,
textarea {
  text-align: left;
}

.footer {
  position: static;
  bottom: 0;
  left: 0;
  right: 0;
  pointer-events: auto;
  padding: 0.75rem;
  text-align: center;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
}


/* Improve readability on glass */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.card,
.header,
.overlayCard {
  text-shadow: 0 1px 2px rgba(0,0,0,0.35);
}


/* =========================
   RESPONSIVE
========================= */

/* Tablets + down */
@media (max-width: 768px) {
  .container {
    padding: 14px;
  }
  h1 {
    font-size: 28px;
  }
  .card {
    max-width: 620px;
  }
}

/* Phones */
@media (max-width: 520px) {
  /* Show mobile nav only on phones */
 
  .header {
    padding: 20px 14px 6px;
  }

  h1 {
    font-size: 24px;
  }

  .subtext {
    font-size: 14px;
  }

  .container {
    padding: 12px;
    gap: 12px;
  }

  .card {
    max-width: 100%;
    padding: 18px;
  }

  .row {
    gap: 10px;
    margin-top: 12px;
  }

  button {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }

  textarea {
    min-height: 110px;
  }

  /* Task action buttons stack nicely */
  .actions {
    display: grid !important;
    gap: 8px !important;
  }
}

/* =========================
   FIX: card + button sizing
   (paste at end of file)
========================= */

/* Stop flex stretching making things feel huge */
.screen.isActive {
  align-items: center; /* important */
}

/* Keep the content area a normal readable width */
.screenInner {
  width: 100%;
  max-width: 640px;
  padding-top: 64px;
}

/* Cards should never feel massive */
.card {
  width: 100%;
  max-width: 600px;   /* your original intent */
}

/* Buttons: stop the big square look */
button,
.btn {
  width: auto;
  min-width: 0;       /* cancels any earlier min-width */
  padding: 10px 14px; /* smaller */
  border-radius: 12px;
}

/* Center buttons under cards */
.row {
  justify-content: center;
}

/* Mobile: stacked, but not edge-to-edge */
@media (max-width: 520px) {
  button,
  .btn {
    width: auto;
    max-width: auto;
    margin: 0 auto;
  }
}
