:root {
  --bg: #fff7fb;
  --bg2: #fdf1f8;
  --card: rgba(255, 255, 255, 0.88);
  --text: #5d4756;
  --heading: #a04d7c;
  --accent: #ecb7cf;
  --accent-dark: #d884ad;
  --accent-soft: #f8dce9;
  --border: #f1ccdc;
  --shadow: 0 10px 30px rgba(192, 124, 159, 0.12);
}

body.lavender {
  --bg: #faf6ff;
  --bg2: #f3ecff;
  --card: rgba(255, 255, 255, 0.9);
  --text: #534b67;
  --heading: #7f60b3;
  --accent: #d9caf8;
  --accent-dark: #ae94df;
  --accent-soft: #ece3ff;
  --border: #ddd0f6;
  --shadow: 0 10px 30px rgba(130, 102, 188, 0.13);
}

body.sage {
  --bg: #f7fcf7;
  --bg2: #eef8ef;
  --card: rgba(255, 255, 255, 0.92);
  --text: #506055;
  --heading: #6c9172;
  --accent: #d5e9d6;
  --accent-dark: #96be9d;
  --accent-soft: #e7f4e8;
  --border: #d6e7d7;
  --shadow: 0 10px 30px rgba(103, 143, 110, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", sans-serif;
  background: linear-gradient(180deg, var(--bg), var(--bg2));
  color: var(--text);
  min-height: 100vh;
}

h1, h2, h3 {
  font-family: "Playfair Display", serif;
  color: var(--heading);
  margin-top: 0;
}

button,
select,
input,
textarea {
  font-family: inherit;
}

.hero {
  margin: 24px auto 18px;
  width: min(1180px, calc(100% - 24px));
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 18px;
  background: linear-gradient(135deg, rgba(255,255,255,0.75), rgba(255,255,255,0.5));
  border: 1px solid var(--border);
  border-radius: 28px;
  box-shadow: var(--shadow);
  padding: 26px;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  width: 260px;
  height: 260px;
  right: -80px;
  top: -80px;
  background: radial-gradient(circle, var(--accent-soft), transparent 70%);
  pointer-events: none;
}

.tag {
  display: inline-block;
  padding: 8px 14px;
  background: var(--accent-soft);
  border-radius: 999px;
  font-size: 13px;
  margin-bottom: 10px;
}

.hero h1 {
  font-size: 54px;
  margin-bottom: 10px;
}

.hero-desc {
  max-width: 650px;
  line-height: 1.7;
}

.hero-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 20px;
  align-self: center;
  box-shadow: var(--shadow);
}

.hero-actions,
.button-row,
.input-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.primary-btn,
.secondary-btn,
.small-btn,
button {
  border: none;
  background: var(--accent);
  color: var(--text);
  padding: 11px 16px;
  border-radius: 14px;
  cursor: pointer;
  transition: 0.25s ease;
  font-weight: 600;
}

button:hover,
.primary-btn:hover,
.secondary-btn:hover,
.small-btn:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

.top-nav {
  width: min(1180px, calc(100% - 24px));
  margin: 0 auto 14px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  background: rgba(255,255,255,0.68);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 14px;
  position: sticky;
  top: 10px;
  z-index: 20;
  backdrop-filter: blur(10px);
}

.theme-bar {
  width: min(1180px, calc(100% - 24px));
  margin: 0 auto 18px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
}

main {
  width: min(1180px, calc(100% - 24px));
  margin: 0 auto 40px;
}

.page {
  display: none;
}

.page.active {
  display: block;
}

.grid {
  display: grid;
  gap: 18px;
  margin-bottom: 18px;
}

.grid.two {
  grid-template-columns: repeat(2, 1fr);
}

.grid.three {
  grid-template-columns: repeat(3, 1fr);
}

.grid.four {
  grid-template-columns: repeat(4, 1fr);
}

.card,
.mini-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}

.mini-card {
  padding: 16px;
}

.styled-list,
.tip-list,
.journal-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.styled-list li,
.journal-item {
  background: white;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 12px 14px;
  margin-bottom: 10px;
}

.list-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.list-row span.done {
  text-decoration: line-through;
  opacity: 0.65;
}

.small-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.icon-btn {
  padding: 7px 10px;
  border-radius: 10px;
  font-size: 12px;
}

.progress-shell,
.chart-bar-shell {
  width: 100%;
  height: 16px;
  background: #f3e3eb;
  border-radius: 999px;
  overflow: hidden;
  margin-top: 12px;
}

.chart-bar-shell.large {
  height: 20px;
}

.progress-fill,
.chart-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent-dark), var(--heading));
  border-radius: 999px;
  transition: width 0.35s ease;
}

.chart-box {
  margin-top: 16px;
}

.chart-label {
  font-size: 14px;
  margin-bottom: 8px;
}

.breathing-circle {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  margin: 14px auto;
  background: radial-gradient(circle at top, var(--accent-soft), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  box-shadow: inset 0 8px 18px rgba(255,255,255,0.5), 0 10px 20px rgba(0,0,0,0.06);
  transition: transform 4s ease-in-out;
}

.secondary-circle {
  width: 140px;
  height: 140px;
}

.breathing-circle.animate {
  transform: scale(1.18);
}

.floating-decor {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.butterfly,
.flower {
  position: absolute;
  opacity: 0.65;
  font-size: 26px;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}

.b1 { left: 6%; top: 80%; animation: floatUp 18s infinite; }
.b2 { left: 85%; top: 90%; animation: floatUp 15s infinite 2s; }
.b3 { left: 45%; top: 88%; animation: floatUp 20s infinite 4s; }

.f1 { left: 15%; top: 15%; animation: sway 7s infinite; }
.f2 { right: 10%; top: 24%; animation: sway 8s infinite; }
.f3 { left: 8%; bottom: 15%; animation: sway 9s infinite; }
.f4 { right: 12%; bottom: 10%; animation: sway 8.5s infinite; }

@keyframes floatUp {
  0% { transform: translateY(0) translateX(0) rotate(0deg); }
  50% { transform: translateY(-45vh) translateX(18px) rotate(8deg); }
  100% { transform: translateY(-95vh) translateX(-12px) rotate(-8deg); }
}

@keyframes sway {
  0%, 100% { transform: translateX(0px) rotate(0deg); }
  50% { transform: translateX(12px) rotate(7deg); }
}

@media (max-width: 1000px) {
  .hero,
  .grid.two,
  .grid.three,
  .grid.four {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 42px;
  }

  .theme-bar {
    justify-content: center;
  }
}

@media (max-width: 640px) {
  .hero {
    padding: 18px;
  }

  .top-nav {
    justify-content: flex-start;
  }

  .card,
  .mini-card {
    padding: 16px;
  }

  .breathing-circle {
    width: 130px;
    height: 130px;
  }
}