
@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Nunito:wght@400;600;700;800&display=swap');


:root {
  color-scheme: light;
  --paper: #181C14;
  --card: #fffdf7;
  --ink: #ECDFCC;
  --muted: #929483;
  --green: #789477;
  --green-dark: #536f55;
  --green-pale: #e5ecdf;
  --peach: #edc8a8;
  --line: #e9e4d8;
  font-family: "Silkscreen", sans-serif;
}



* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
}

button {
  font: inherit;
  cursor: pointer;
}

.app {
  width: min(760px, 100%);
  margin: 0 auto;
  padding: 28px 22px 24px;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.topbar > div {
  margin-right: auto;
}

h1, h2, h3, p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(1.35rem, 4vw, 1.8rem);
  letter-spacing: -.04em;
}

h1 span {
  color: var(--green);
}

.eyebrow {
  margin-bottom: 7px;
  color: var(--muted);
  letter-spacing: .12em;
}

.tab {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  padding: 9px 16px;
}

.tab.active {
  background: var(--green-dark);
  border-color: var(--green-dark);
  color: white;
}

.welcome {
  margin: 8px 0 20px;
}

.welcome h3,
.garden-heading h3 {
  margin-bottom: 0;
  font-size: clamp(1.3rem, 4vw, 1.85rem);
  line-height: 1.12;
  letter-spacing: -.04em;
}

#guest-button {
  margin-top: 16px;
  width: 100%;
}


.plant-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--card);
}

.plant-scene {
  position: relative;
  min-height: 320px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #edf0df;
}


.plant-display {
  position: relative;
  z-index: 1;
  width: 180px;
  height: 190px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
}

.plant-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: pixelated;
}

.plant-fallback {
  font-size: 90px;
}

.plant-caption {
  position: absolute;
  bottom: 19px;
  margin: 0;
  color: #77836c;
  font-size: .85rem;
}

.timer-area {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 28px 22px;
  text-align: center;
}

.timer {
  margin: 8px 0;
  font-size: clamp(2.2rem, 7vw, 3.1rem);
  font-weight: 500;
  letter-spacing: -.06em;
  color: #181C14;
}

.timer-note {
  display: block;
  width: 100%;
  max-width: 260px;
  min-height: 0;
  margin: 0;
  color: var(--green-dark);
  font-size: .9rem;
  text-align: center;
  flex-shrink: 0;
}

.timer-label {
  display: block;
  width: 100%;
  max-width: 300px;
  min-height: 36px;
  margin-bottom: 5%;
  color: rgb(141, 123, 123);
  font-size: .7rem;
  text-align: center;
  flex-shrink: 0;
}

.timer-actions {
  display: flex;
  width: 100%;
  gap: 9px;
}

.primary-button,
.secondary-button,
.complete-button {
  border: 0;
  border-radius: 12px;
  padding: 12px 15px;
  font-weight: 500;
}

.primary-button {
  flex: 1;
  background: var(--green-dark);
  color: white;
}

#reset-timer {
  flex: 1;
  border: 1px solid #d8cbb9;
  border-radius: 12px;
  padding: 12px 15px;
  background: #f4e9dc;
  color: #806d5b;
  font: inherit;
  font-weight: 500;
  transition: background 0.2s ease, border-color 0.2s ease;
}

#reset-timer:hover {
  background: #e9d9c6;
  border-color: #c8b49b;
}

#reset-timer:active {
  background: #dfcbb4;
}

#reset-timer:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
}

.secondary-button {
  background: var(--green-pale);
  color: var(--green-dark);
}

.complete-button {
  width: 100%;
  margin-top: 10px;
  background: #f4e5d6;
  color: #906d50;
}

.complete-button:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.feedback {
  min-height: 20px;
  margin: 10px 0 0;
  color: var(--green-dark);
  font-size: .85rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 17px;
}

.stats > div {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 16px 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fffdf7;
  text-align: center;
}

.stats strong {
  font: 500 1.35rem 'DM Mono', monospace;
  color: var(--green-dark);
}

.stats span {
  color: var(--muted);
  font-size: .78rem;
}

/* WEEKLY GARDEN */

.garden-heading {
  margin: 8px 0 12px;
}

.garden-description {
  margin-bottom: 22px;
  color: var(--muted);
  font-size: .9rem;
}

.garden-shelves {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.week-shelf {
  padding: 16px 16px 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--green-pale);
}

.shelf-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 15px;
}

.shelf-heading h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--green-dark);
}

.shelf-heading span {
  color: var(--green-dark);
  font-size: .78rem;
}

.shelf-plants {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
  gap: 12px 8px;
  padding: 4px 2px 12px;
}

.shelf-plant {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: end;
  gap: 5px;
}

.shelf-plant img {
  width: 100%;
  height: 88px;
  object-fit: contain;
  image-rendering: pixelated;
}

.shelf-fallback {
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 42px;
}

.shelf-plant small {
  color: var(--muted);
  font: .65rem 'DM Mono', monospace;
}

.shelf-board {
  height: 9px;
  margin: 0 -16px;
  border-radius: 2px 2px 12px 12px;
  background: #553d28;
  box-shadow: 0 4px 0 #332011;
}

.empty-garden {
  padding: 35px 15px;
  border: 1px dashed #d8d8c7;
  border-radius: 18px;
  color: var(--muted);
  text-align: center;
  font-size: .9rem;
}


.hidden {
  display: none;
}

@media (max-width: 580px) {
  .app {
    padding: 20px 14px;
  }

  .topbar {
    gap: 7px;
  }

  .topbar > div {
    flex-basis: 100%;
    margin-bottom: 8px;
  }

  .plant-card {
    grid-template-columns: 1fr;
  }

  .plant-scene {
    min-height: 230px;
  }

  .plant-display {
    width: 150px;
    height: 155px;
  }

  .timer-area {
    padding: 24px 18px;
  }

  .stats {
    gap: 7px;
  }

  .stats > div {
    padding: 13px 5px;
  }

  .stats strong {
    font-size: 1.1rem;
  }

  .stats span {
    font-size: .7rem;
  }

  .week-shelf {
    padding-left: 12px;
    padding-right: 12px;
  }

  .shelf-board {
    margin-left: -12px;
    margin-right: -12px;
  }

  .shelf-plants {
    grid-template-columns: repeat(auto-fill, minmax(65px, 1fr));
    gap: 10px 5px;
  }

  .shelf-plant img,
  .shelf-fallback {
    height: 75px;
  }
}


/* AUTHENTICATION */

.auth-view {
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-card {
  width: min(420px, 100%);
  padding: 30px 25px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--paper);
  color: var(--ink);
  text-align: center;
}

.auth-card h2 {
  font-size: 1.4rem;
  line-height: 1.5;
}

.auth-description {
  color: var(--muted);
  font-size: .8rem;
  margin-bottom: 28px;
}

#auth-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}

#auth-form label {
  font-size: .75rem;
}

#auth-form input {
  width: 100%;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: .8rem;
  margin-bottom: 8px;
}

#auth-form input:focus {
  outline: 1px solid var(--green);
}

#auth-submit {
  width: 100%;
  min-height: 45px;
  margin-top: 8px;
}

.auth-switch {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: .7rem;
}

#auth-toggle {
  border: none;
  background: none;
  color: var(--green);
  font: inherit;
  font-weight: bold;
  cursor: pointer;
}

#auth-feedback {
  text-align: center;
  overflow-wrap: anywhere;
}

.hidden {
  display: none !important;
}
