*, ::before, ::after {
  --tw-border-spacing-x: 0;
  --tw-border-spacing-y: 0;
  --tw-translate-x: 0;
  --tw-translate-y: 0;
  --tw-rotate: 0;
  --tw-skew-x: 0;
  --tw-skew-y: 0;
  --tw-scale-x: 1;
  --tw-scale-y: 1;
  --tw-pan-x:  ;
  --tw-pan-y:  ;
  --tw-pinch-zoom:  ;
  --tw-scroll-snap-strictness: proximity;
  --tw-gradient-from-position:  ;
  --tw-gradient-via-position:  ;
  --tw-gradient-to-position:  ;
  --tw-ordinal:  ;
  --tw-slashed-zero:  ;
  --tw-numeric-figure:  ;
  --tw-numeric-spacing:  ;
  --tw-numeric-fraction:  ;
  --tw-ring-inset:  ;
  --tw-ring-offset-width: 0px;
  --tw-ring-offset-color: #fff;
  --tw-ring-color: rgb(59 130 246 / 0.5);
  --tw-ring-offset-shadow: 0 0 #0000;
  --tw-ring-shadow: 0 0 #0000;
  --tw-shadow: 0 0 #0000;
  --tw-shadow-colored: 0 0 #0000;
  --tw-blur:  ;
  --tw-brightness:  ;
  --tw-contrast:  ;
  --tw-grayscale:  ;
  --tw-hue-rotate:  ;
  --tw-invert:  ;
  --tw-saturate:  ;
  --tw-sepia:  ;
  --tw-drop-shadow:  ;
  --tw-backdrop-blur:  ;
  --tw-backdrop-brightness:  ;
  --tw-backdrop-contrast:  ;
  --tw-backdrop-grayscale:  ;
  --tw-backdrop-hue-rotate:  ;
  --tw-backdrop-invert:  ;
  --tw-backdrop-opacity:  ;
  --tw-backdrop-saturate:  ;
  --tw-backdrop-sepia:  ;
  --tw-contain-size:  ;
  --tw-contain-layout:  ;
  --tw-contain-paint:  ;
  --tw-contain-style:  ;
}

::backdrop {
  --tw-border-spacing-x: 0;
  --tw-border-spacing-y: 0;
  --tw-translate-x: 0;
  --tw-translate-y: 0;
  --tw-rotate: 0;
  --tw-skew-x: 0;
  --tw-skew-y: 0;
  --tw-scale-x: 1;
  --tw-scale-y: 1;
  --tw-pan-x:  ;
  --tw-pan-y:  ;
  --tw-pinch-zoom:  ;
  --tw-scroll-snap-strictness: proximity;
  --tw-gradient-from-position:  ;
  --tw-gradient-via-position:  ;
  --tw-gradient-to-position:  ;
  --tw-ordinal:  ;
  --tw-slashed-zero:  ;
  --tw-numeric-figure:  ;
  --tw-numeric-spacing:  ;
  --tw-numeric-fraction:  ;
  --tw-ring-inset:  ;
  --tw-ring-offset-width: 0px;
  --tw-ring-offset-color: #fff;
  --tw-ring-color: rgb(59 130 246 / 0.5);
  --tw-ring-offset-shadow: 0 0 #0000;
  --tw-ring-shadow: 0 0 #0000;
  --tw-shadow: 0 0 #0000;
  --tw-shadow-colored: 0 0 #0000;
  --tw-blur:  ;
  --tw-brightness:  ;
  --tw-contrast:  ;
  --tw-grayscale:  ;
  --tw-hue-rotate:  ;
  --tw-invert:  ;
  --tw-saturate:  ;
  --tw-sepia:  ;
  --tw-drop-shadow:  ;
  --tw-backdrop-blur:  ;
  --tw-backdrop-brightness:  ;
  --tw-backdrop-contrast:  ;
  --tw-backdrop-grayscale:  ;
  --tw-backdrop-hue-rotate:  ;
  --tw-backdrop-invert:  ;
  --tw-backdrop-opacity:  ;
  --tw-backdrop-saturate:  ;
  --tw-backdrop-sepia:  ;
  --tw-contain-size:  ;
  --tw-contain-layout:  ;
  --tw-contain-paint:  ;
  --tw-contain-style:  ;
}/*
! tailwindcss v3.4.19 | MIT License | https://tailwindcss.com
*//*
1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)
*/

*,
::before,
::after {
  box-sizing: border-box; /* 1 */
  border-width: 0; /* 2 */
  border-style: solid; /* 2 */
  border-color: #e5e7eb; /* 2 */
}

::before,
::after {
  --tw-content: '';
}

/*
1. Use a consistent sensible line-height in all browsers.
2. Prevent adjustments of font size after orientation changes in iOS.
3. Use a more readable tab size.
4. Use the user's configured `sans` font-family by default.
5. Use the user's configured `sans` font-feature-settings by default.
6. Use the user's configured `sans` font-variation-settings by default.
7. Disable tap highlights on iOS
*/

html,
:host {
  line-height: 1.5; /* 1 */
  -webkit-text-size-adjust: 100%; /* 2 */
  -moz-tab-size: 4; /* 3 */
  -o-tab-size: 4;
     tab-size: 4; /* 3 */
  font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 4 */
  font-feature-settings: normal; /* 5 */
  font-variation-settings: normal; /* 6 */
  -webkit-tap-highlight-color: transparent; /* 7 */
}

/*
1. Remove the margin in all browsers.
2. Inherit line-height from `html` so users can set them as a class directly on the `html` element.
*/

body {
  margin: 0; /* 1 */
  line-height: inherit; /* 2 */
}

/*
1. Add the correct height in Firefox.
2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
3. Ensure horizontal rules are visible by default.
*/

hr {
  height: 0; /* 1 */
  color: inherit; /* 2 */
  border-top-width: 1px; /* 3 */
}

/*
Add the correct text decoration in Chrome, Edge, and Safari.
*/

abbr:where([title]) {
  -webkit-text-decoration: underline dotted;
          text-decoration: underline dotted;
}

/*
Remove the default font size and weight for headings.
*/

h1,
h2,
h3,
h4,
h5,
h6 {
  font-size: inherit;
  font-weight: inherit;
}

/*
Reset links to optimize for opt-in styling instead of opt-out.
*/

a {
  color: inherit;
  text-decoration: inherit;
}

/*
Add the correct font weight in Edge and Safari.
*/

b,
strong {
  font-weight: bolder;
}

/*
1. Use the user's configured `mono` font-family by default.
2. Use the user's configured `mono` font-feature-settings by default.
3. Use the user's configured `mono` font-variation-settings by default.
4. Correct the odd `em` font sizing in all browsers.
*/

code,
kbd,
samp,
pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; /* 1 */
  font-feature-settings: normal; /* 2 */
  font-variation-settings: normal; /* 3 */
  font-size: 1em; /* 4 */
}

/*
Add the correct font size in all browsers.
*/

small {
  font-size: 80%;
}

/*
Prevent `sub` and `sup` elements from affecting the line height in all browsers.
*/

sub,
sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

/*
1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
3. Remove gaps between table borders by default.
*/

table {
  text-indent: 0; /* 1 */
  border-color: inherit; /* 2 */
  border-collapse: collapse; /* 3 */
}

/*
1. Change the font styles in all browsers.
2. Remove the margin in Firefox and Safari.
3. Remove default padding in all browsers.
*/

button,
input,
optgroup,
select,
textarea {
  font-family: inherit; /* 1 */
  font-feature-settings: inherit; /* 1 */
  font-variation-settings: inherit; /* 1 */
  font-size: 100%; /* 1 */
  font-weight: inherit; /* 1 */
  line-height: inherit; /* 1 */
  letter-spacing: inherit; /* 1 */
  color: inherit; /* 1 */
  margin: 0; /* 2 */
  padding: 0; /* 3 */
}

/*
Remove the inheritance of text transform in Edge and Firefox.
*/

button,
select {
  text-transform: none;
}

/*
1. Correct the inability to style clickable types in iOS and Safari.
2. Remove default button styles.
*/

button,
input:where([type='button']),
input:where([type='reset']),
input:where([type='submit']) {
  -webkit-appearance: button; /* 1 */
  background-color: transparent; /* 2 */
  background-image: none; /* 2 */
}

/*
Use the modern Firefox focus style for all focusable elements.
*/

:-moz-focusring {
  outline: auto;
}

/*
Remove the additional `:invalid` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)
*/

:-moz-ui-invalid {
  box-shadow: none;
}

/*
Add the correct vertical alignment in Chrome and Firefox.
*/

progress {
  vertical-align: baseline;
}

/*
Correct the cursor style of increment and decrement buttons in Safari.
*/

::-webkit-inner-spin-button,
::-webkit-outer-spin-button {
  height: auto;
}

/*
1. Correct the odd appearance in Chrome and Safari.
2. Correct the outline style in Safari.
*/

[type='search'] {
  -webkit-appearance: textfield; /* 1 */
  outline-offset: -2px; /* 2 */
}

/*
Remove the inner padding in Chrome and Safari on macOS.
*/

::-webkit-search-decoration {
  -webkit-appearance: none;
}

/*
1. Correct the inability to style clickable types in iOS and Safari.
2. Change font properties to `inherit` in Safari.
*/

::-webkit-file-upload-button {
  -webkit-appearance: button; /* 1 */
  font: inherit; /* 2 */
}

/*
Add the correct display in Chrome and Safari.
*/

summary {
  display: list-item;
}

/*
Removes the default spacing and border for appropriate elements.
*/

blockquote,
dl,
dd,
h1,
h2,
h3,
h4,
h5,
h6,
hr,
figure,
p,
pre {
  margin: 0;
}

fieldset {
  margin: 0;
  padding: 0;
}

legend {
  padding: 0;
}

ol,
ul,
menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

/*
Reset default styling for dialogs.
*/
dialog {
  padding: 0;
}

/*
Prevent resizing textareas horizontally by default.
*/

textarea {
  resize: vertical;
}

/*
1. Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)
2. Set the default placeholder color to the user's configured gray 400 color.
*/

input::-moz-placeholder, textarea::-moz-placeholder {
  opacity: 1; /* 1 */
  color: #9ca3af; /* 2 */
}

input::placeholder,
textarea::placeholder {
  opacity: 1; /* 1 */
  color: #9ca3af; /* 2 */
}

/*
Set the default cursor for buttons.
*/

button,
[role="button"] {
  cursor: pointer;
}

/*
Make sure disabled buttons don't get the pointer cursor.
*/
:disabled {
  cursor: default;
}

/*
1. Make replaced elements `display: block` by default. (https://github.com/mozdevs/cssremedy/issues/14)
2. Add `vertical-align: middle` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)
   This can trigger a poorly considered lint error in some tools but is included by design.
*/

img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
  display: block; /* 1 */
  vertical-align: middle; /* 2 */
}

/*
Constrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)
*/

img,
video {
  max-width: 100%;
  height: auto;
}

/* Make elements with the HTML hidden attribute stay hidden by default */
[hidden]:where(:not([hidden="until-found"])) {
  display: none;
}
.filter {
  filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
}

:root {
  --bg: #f7f3ea;
  --paper: #fffdf7;
  --cream: #fbf8ef;
  --line: #e2d9c6;
  --sage: #738f53;
  --sage-dark: #56743e;
  --sage-soft: #ecebd8;
  --ink: #1f2a1f;
  --muted: #7c806f;
  --gold: #cdb343;
  --blue: #dbe7f4;
  --purple: #ddd5f4;
  --shadow: 0 18px 48px rgba(67, 63, 45, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  background:
    radial-gradient(circle at 10% 8%, rgba(255, 255, 255, 0.85), transparent 25rem),
    radial-gradient(circle at 90% 90%, rgba(201, 218, 180, 0.28), transparent 24rem),
    var(--bg);
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  font-family:
    "Hiragino Sans", "Yu Gothic", "Yu Gothic UI", Meiryo, system-ui,
    sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea {
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font: inherit;
}

button {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.app-shell,
.start-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  overflow: hidden;
  padding: 14px;
  background: var(--bg);
}

.phone-frame,
.start-phone {
  position: relative;
  width: min(100%, 390px);
  height: min(844px, calc(100vh - 28px));
  min-height: 720px;
  overflow: hidden;
  border: 1px solid rgba(224, 217, 200, 0.94);
  border-radius: 22px;
  background: var(--paper);
  box-shadow: var(--shadow);
  animation: phone-rise 700ms cubic-bezier(0.2, 0.74, 0.2, 1) both;
}

.status-bar {
  display: flex;
  height: 36px;
  align-items: center;
  justify-content: space-between;
  padding: 10px 22px 0;
  color: #101510;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.status-icons {
  font-size: 9px;
  letter-spacing: 0.02em;
}

.app-header {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 42px;
  height: 52px;
  align-items: center;
  padding: 0 16px;
}

.app-header h1 {
  margin: 0;
  overflow: hidden;
  color: #111a13;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 17px;
  font-weight: 700;
}

.header-action,
.save-link {
  display: grid;
  min-width: 34px;
  min-height: 34px;
  place-items: center;
  border-radius: 50%;
  color: #162018;
  font-size: 23px;
  line-height: 1;
  transition: background 160ms ease, transform 160ms ease;
}

.header-action:active,
.save-link:active {
  transform: scale(0.92);
  background: var(--sage-soft);
}

.save-link {
  border-radius: 999px;
  color: var(--sage-dark);
  font-size: 14px;
  font-weight: 700;
}

.menu-lines::before {
  width: 16px;
  height: 12px;
  border-block: 1.6px solid currentColor;
  content: "";
  box-shadow: inset 0 5px 0 -3.4px currentColor;
}

.search-icon::before {
  width: 15px;
  height: 15px;
  border: 1.6px solid currentColor;
  border-radius: 50%;
  content: "";
}

.search-icon::after {
  width: 7px;
  height: 1.6px;
  margin-left: -9px;
  margin-top: 15px;
  background: currentColor;
  content: "";
  transform: rotate(45deg);
}

.screen-body {
  position: relative;
  height: calc(100% - 88px);
  overflow-y: auto;
  padding: 0 16px 88px;
  scrollbar-width: none;
  animation: page-in 320ms cubic-bezier(0.2, 0.72, 0.22, 1) both;
}

.screen-body::-webkit-scrollbar,
.mood-row::-webkit-scrollbar,
.photo-strip::-webkit-scrollbar {
  display: none;
}

.toast,
.inline-feedback {
  position: absolute;
  left: 50%;
  z-index: 20;
  border-radius: 999px;
  background: rgba(35, 48, 33, 0.92);
  padding: 9px 15px;
  color: #fffdf7;
  font-size: 12px;
  font-weight: 700;
  transform: translateX(-50%);
  animation: toast-in 260ms ease both;
}

.toast {
  top: 84px;
}

.header-panel {
  position: absolute;
  top: 88px;
  right: 16px;
  left: 16px;
  z-index: 18;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  box-shadow: 0 16px 34px rgba(65, 62, 46, 0.15);
  animation: panel-drop 180ms ease both;
}

.menu-panel {
  display: grid;
  gap: 3px;
  padding: 8px;
}

.menu-panel button {
  min-height: 42px;
  border-radius: 9px;
  padding: 0 12px;
  color: #1f2a1f;
  text-align: left;
  font-size: 13px;
  font-weight: 800;
  transition: background 160ms ease, transform 160ms ease;
}

.menu-panel button:active,
.search-results button:active {
  transform: scale(0.98);
  background: var(--sage-soft);
}

.search-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.search-panel label {
  display: grid;
  gap: 7px;
  color: #30382e;
  font-size: 12px;
  font-weight: 800;
}

.search-panel input {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--paper);
  padding: 0 12px;
  outline: none;
  color: #1d251d;
  font-size: 14px;
  font-weight: 700;
}

.search-panel input:focus {
  border-color: rgba(111, 139, 81, 0.75);
  box-shadow: 0 0 0 3px rgba(111, 139, 81, 0.11);
}

.search-results {
  display: grid;
  gap: 6px;
}

.search-results p {
  margin: 2px 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.search-results button {
  display: grid;
  min-height: 44px;
  gap: 2px;
  border-radius: 9px;
  padding: 8px 10px;
  text-align: left;
  transition: background 160ms ease, transform 160ms ease;
}

.search-results strong {
  color: var(--sage-dark);
  font-size: 11px;
}

.search-results span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #1f2a1f;
  font-size: 13px;
  font-weight: 800;
}

.inline-feedback {
  bottom: 22px;
}

.start-phone {
  color: #fffdf7;
}

.start-hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-position: 0% 0%;
  filter: saturate(0.96) contrast(1.04) brightness(0.95);
}

.start-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(23, 40, 24, 0.08) 0%, rgba(23, 40, 24, 0.12) 45%, rgba(23, 40, 24, 0.28) 100%),
    linear-gradient(180deg, rgba(255, 253, 247, 0.04), rgba(255, 253, 247, 0.16));
}

.start-content {
  position: relative;
  z-index: 1;
  display: flex;
  height: 100%;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding: 180px 31px 36px;
  text-align: center;
}

.brand-mark {
  position: absolute;
  top: 238px;
  left: 50%;
  width: 104px;
  height: 28px;
  transform: translateX(-50%);
}

.brand-mark::before,
.brand-mark::after,
.brand-mark span::before,
.brand-mark span::after {
  position: absolute;
  border: 1.4px solid rgba(255, 253, 247, 0.88);
  border-left: 0;
  border-bottom: 0;
  border-radius: 0 12px 0 0;
  content: "";
}

.brand-mark::before {
  left: 12px;
  top: 11px;
  width: 33px;
  height: 13px;
  transform: rotate(164deg);
}

.brand-mark::after {
  right: 12px;
  top: 11px;
  width: 33px;
  height: 13px;
  transform: rotate(-18deg);
}

.brand-mark span::before,
.brand-mark span::after {
  top: 9px;
  width: 11px;
  height: 7px;
}

.brand-mark span::before {
  left: 4px;
  transform: rotate(26deg);
}

.brand-mark span::after {
  right: 4px;
  transform: rotate(-116deg);
}

.brand-name {
  margin: 0 0 18px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 42px;
  font-style: italic;
  font-weight: 400;
  line-height: 1;
  text-shadow: 0 2px 10px rgba(24, 36, 23, 0.26);
}

.start-copy {
  margin: 0 0 86px;
  color: rgba(255, 253, 247, 0.96);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.75;
  text-shadow: 0 1px 9px rgba(24, 36, 23, 0.28);
}

.start-actions {
  display: grid;
  width: 100%;
  gap: 14px;
}

.primary-button,
.ghost-button,
.secondary-button {
  display: inline-flex;
  min-height: 50px;
  width: 100%;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 12px 20px;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.2;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.primary-button {
  background: linear-gradient(180deg, #819b68, #6f8b51);
  color: #fffdf7;
  box-shadow: 0 11px 22px rgba(47, 62, 34, 0.22);
}

.ghost-button {
  border: 1px solid rgba(255, 253, 247, 0.9);
  background: rgba(255, 253, 247, 0.1);
  color: #fffdf7;
  backdrop-filter: blur(5px);
}

.secondary-button {
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--sage-dark);
}

.primary-button:active,
.ghost-button:active,
.secondary-button:active {
  transform: scale(0.97);
}

.mood-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 16px 0 18px;
}

.mood-chip {
  position: relative;
  display: inline-flex;
  min-width: 44px;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: #1f2a1f;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.1;
  border-radius: 12px;
  padding: 2px 4px 5px;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.mood-chip:active {
  transform: scale(0.96);
}

.mood-chip.is-active {
  background: rgba(111, 139, 81, 0.12);
  color: var(--sage-dark);
}

.mood-chip.is-active::after {
  position: absolute;
  right: 5px;
  bottom: -6px;
  left: 5px;
  height: 2px;
  border-radius: 999px;
  background: var(--sage-dark);
  content: "";
}

.mood-chip.is-active .app-icon {
  outline: 2px solid var(--sage-dark);
  outline-offset: 3px;
  box-shadow: 0 7px 14px rgba(86, 116, 62, 0.12);
  background-color: rgba(111, 139, 81, 0.18);
}

.app-icon {
  display: inline-block;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  border-radius: 50%;
  background-image: url("/assets/icon-sheet-transparent.png");
  background-repeat: no-repeat;
  background-size: 500% 300%;
  filter: saturate(0.9);
}

.app-icon-leaf { background-position: 0% 0%; }
.app-icon-sprout { background-position: 25% 0%; }
.app-icon-calendar { background-position: 50% 0%; }
.app-icon-chart { background-position: 75% 0%; }
.app-icon-smile { background-position: 100% 0%; }
.app-icon-sad { background-position: 0% 50%; }
.app-icon-photo { background-position: 25% 50%; }
.app-icon-camera { background-position: 50% 50%; }
.app-icon-pen { background-position: 75% 50%; }
.app-icon-text { background-position: 100% 50%; }
.app-icon-home { background-position: 0% 100%; }
.app-icon-settings { background-position: 25% 100%; }
.app-icon-plus { background-position: 50% 100%; }

.entry-list {
  display: grid;
  gap: 12px;
  padding-bottom: 10px;
}

.diary-card {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 74px;
  min-height: 126px;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  padding: 12px;
  box-shadow: 0 10px 25px rgba(65, 62, 46, 0.07);
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.diary-card:active {
  transform: scale(0.985);
  box-shadow: 0 6px 16px rgba(65, 62, 46, 0.08);
}

.diary-card-date {
  color: #111a13;
  font-weight: 700;
  line-height: 1.15;
  text-align: left;
}

.diary-card-date strong {
  display: block;
  font-size: 25px;
}

.diary-card-date span,
.diary-card-date small {
  display: block;
  font-size: 13px;
}

.diary-card-copy {
  min-width: 0;
}

.diary-card h2,
.calendar-entry-card h3,
.stats-card h2 {
  margin: 0;
  color: #182119;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
}

.diary-card h2 {
  display: flex;
  align-items: center;
  gap: 6px;
}

.diary-card h2 .app-icon,
.calendar-entry-card h3 .app-icon {
  width: 24px;
  height: 24px;
}

.diary-card p,
.calendar-entry-card span {
  display: -webkit-box;
  margin: 7px 0 0;
  overflow: hidden;
  color: #283128;
  font-size: 11.5px;
  font-weight: 600;
  line-height: 1.75;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.photo-crop {
  display: block;
  background: #e8e1cf;
  background-image: url("/assets/nature-sheet.png");
  background-repeat: no-repeat;
  background-size: 300% 200%;
}

.entry-photo {
  width: 74px;
  height: 74px;
  border-radius: 8px;
}

.photo-path { background-position: 0% 0%; }
.photo-cake { background-position: 50% 0%; }
.photo-sunset { background-position: 100% 0%; }
.photo-notebook { background-position: 0% 100%; }
.photo-flowers { background-position: 50% 100%; }
.photo-green { background-position: 100% 100%; }

.floating-action-button {
  position: absolute;
  right: 16px;
  bottom: 70px;
  z-index: 5;
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(180deg, #7f9d5f, #668248);
  color: #fffdf7;
  font-size: 36px;
  font-weight: 300;
  line-height: 1;
  box-shadow: 0 10px 18px rgba(59, 74, 41, 0.26);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.floating-action-button:active {
  transform: scale(0.92);
  box-shadow: 0 6px 13px rgba(59, 74, 41, 0.22);
}

.bottom-nav {
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  z-index: 4;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid rgba(226, 217, 198, 0.82);
  background: rgba(255, 253, 247, 0.96);
  padding: 7px 20px 12px;
  backdrop-filter: blur(10px);
}

.bottom-nav-item {
  display: flex;
  min-width: 0;
  min-height: 52px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border-radius: 12px;
  color: #253025;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.1;
  transition: transform 160ms ease, color 160ms ease;
}

.bottom-nav-item .app-icon {
  width: 24px;
  height: 24px;
  background-size: 500% 300%;
}

.bottom-nav-item.is-active {
  color: var(--sage-dark);
  transform: translateY(-1px);
}

.edit-screen {
  padding-top: 14px;
  padding-bottom: 14px;
}

.section-label,
.field-label span {
  display: block;
  margin-bottom: 8px;
  color: #30382e;
  font-size: 12px;
  font-weight: 700;
}

.mood-selector {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 18px;
}

.mood-option {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 50%;
  background: var(--sage-soft);
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.mood-option:active {
  transform: scale(0.93);
}

.mood-option:nth-child(1).is-selected { background: #8fa16a; }
.mood-option:nth-child(4).is-selected { background: var(--blue); }
.mood-option:nth-child(5).is-selected { background: #efd8c8; }
.mood-option:nth-child(6).is-selected { background: var(--blue); }
.mood-option:nth-child(7).is-selected { background: var(--purple); }
.mood-option.is-selected {
  transform: translateY(-1px);
  outline: 2px solid var(--sage);
  outline-offset: 3px;
  box-shadow: 0 8px 18px rgba(86, 116, 62, 0.18);
}

.mood-option .app-icon {
  width: 30px;
  height: 30px;
}

.selected-mood-label {
  margin: -8px 0 14px;
  color: var(--sage-dark);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.field-label {
  display: block;
  margin-bottom: 16px;
}

.field-label input,
.field-label textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  color: #1d251d;
  outline: none;
  box-shadow: 0 8px 18px rgba(65, 62, 46, 0.045);
  transition: border 160ms ease, box-shadow 160ms ease;
}

.field-label input {
  min-height: 54px;
  padding: 0 16px;
  font-size: 15px;
  font-weight: 700;
}

.field-label input[type="date"] {
  color-scheme: light;
}

.field-label textarea {
  min-height: 324px;
  resize: none;
  padding: 18px 16px;
  font-size: 14px;
  font-weight: 600;
  line-height: 2.05;
}

.field-label input:focus,
.field-label textarea:focus {
  border-color: rgba(111, 139, 81, 0.75);
  box-shadow: 0 0 0 3px rgba(111, 139, 81, 0.11);
}

.editor-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 5px 0 12px;
  padding: 0 8px;
}

.editor-tools .app-icon {
  width: 28px;
  height: 28px;
}

.photo-strip {
  display: flex;
  gap: 9px;
  overflow-x: auto;
  padding: 0 0 16px;
}

.photo-choice,
.photo-thumb,
.add-photo {
  width: 53px;
  height: 53px;
  flex: 0 0 53px;
  border-radius: 8px;
}

.photo-choice {
  display: block;
  padding: 0;
  outline: 2px solid transparent;
  outline-offset: 2px;
  transition: outline-color 160ms ease, transform 160ms ease;
}

.photo-choice.is-selected {
  outline-color: var(--sage);
}

.photo-choice:active {
  transform: scale(0.95);
}

.add-photo {
  display: grid;
  place-items: center;
  border: 1px dashed #cfc8bb;
  color: #202a20;
  font-size: 32px;
  font-weight: 300;
}

.editor-actions {
  display: grid;
  gap: 10px;
  padding-bottom: 10px;
}

.danger-button {
  display: inline-flex;
  min-height: 46px;
  width: 100%;
  align-items: center;
  justify-content: center;
  border: 1px solid #dfc8bf;
  border-radius: 999px;
  background: #fff8f4;
  color: #9b4d35;
  font-size: 14px;
  font-weight: 800;
  transition: transform 160ms ease, background 160ms ease;
}

.danger-button:active {
  transform: scale(0.97);
  background: #f8ece6;
}

.calendar-screen {
  padding-top: 10px;
}

.month-header {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 36px;
  align-items: center;
  margin-bottom: 12px;
}

.month-header button {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  color: #1a241b;
  font-size: 24px;
}

.month-header button:disabled,
.calendar-day:disabled {
  cursor: default;
  opacity: 0.32;
}

.month-title-button {
  width: min(100%, 190px) !important;
  justify-self: center;
  padding: 0 14px;
  border-radius: 999px !important;
  color: #1a241b;
  font-size: 17px !important;
  font-weight: 800;
  transition: background 160ms ease, transform 160ms ease;
}

.month-title-button:active {
  transform: scale(0.97);
  background: var(--sage-soft);
}

.month-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: -2px 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 253, 247, 0.96);
  padding: 10px;
  box-shadow: 0 10px 24px rgba(65, 62, 46, 0.07);
  animation: page-in 180ms ease both;
}

.month-picker label {
  display: grid;
  gap: 5px;
  color: #30382e;
  font-size: 11px;
  font-weight: 800;
}

.month-picker select {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 0 10px;
  color: #1d251d;
  font-size: 13px;
  font-weight: 800;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px 7px;
  text-align: center;
}

.weekday {
  color: #222d22;
  font-size: 12px;
  font-weight: 700;
  line-height: 24px;
}

.weekday:first-child,
.calendar-day:nth-child(7n + 8) {
  color: #c2772b;
}

.calendar-day {
  display: grid;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 50%;
  color: #182118;
  font-size: 14px;
  font-weight: 700;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease;
}

.calendar-day.is-muted {
  color: #b8b3a8;
}

.calendar-day.is-marked {
  background: var(--sage-soft);
}

.calendar-day.is-today {
  background: var(--sage);
  color: #fffdf7;
}

.calendar-day:active {
  transform: scale(0.9);
}

.calendar-entry-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 78px;
  gap: 12px;
  margin-top: 26px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  padding: 13px;
  box-shadow: 0 10px 25px rgba(65, 62, 46, 0.06);
}

.calendar-entry-card p {
  margin: 0 0 9px;
  font-size: 13px;
  font-weight: 700;
}

.calendar-entry-card h3 {
  display: flex;
  align-items: center;
  gap: 6px;
}

.calendar-photo {
  width: 78px;
  height: 78px;
  align-self: center;
  border-radius: 8px;
}

.stats-screen {
  display: grid;
  gap: 16px;
  padding-top: 10px;
}

.segment-control {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  height: 30px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--sage-soft);
  padding: 2px;
}

.segment-control button {
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #263025;
  font-size: 13px;
  font-weight: 800;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.segment-control button:active {
  transform: scale(0.96);
}

.segment-control button.is-active {
  background: var(--sage);
  color: #fffdf7;
}

.stats-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  padding: 16px;
  box-shadow: 0 10px 25px rgba(65, 62, 46, 0.06);
}

.chart-row {
  display: grid;
  grid-template-columns: 134px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  margin-top: 16px;
}

.donut-chart {
  display: grid;
  width: 128px;
  height: 128px;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle, var(--paper) 0 36%, transparent 37%),
    conic-gradient(var(--donut-gradient, #758f55 0deg 112deg, #cfb83f 112deg 198deg, #c9d8a2 198deg 259deg, #9fb49a 259deg 310deg, #d7d3c7 310deg 360deg));
}

.donut-chart .app-icon {
  width: 46px;
  height: 46px;
}

.stats-legend {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
  font-weight: 700;
}

.stats-legend li {
  display: flex;
  align-items: center;
  gap: 7px;
}

.stats-legend strong {
  margin-left: auto;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot.happy { background: #758f55; }
.dot.fun { background: #cfb83f; }
.dot.relax { background: #c9d8a2; }
.dot.effort { background: #9fb49a; }
.dot.irritated { background: #d99b72; }
.dot.sad { background: #9db3cf; }
.dot.other { background: #d7d3c7; }

.count-line {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  margin-top: 12px;
}

.count-line strong {
  font-size: 34px;
  line-height: 0.9;
}

.count-line span {
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.bar-chart {
  display: flex;
  height: 116px;
  align-items: end;
  gap: 7px;
  margin-top: -10px;
  margin-left: 78px;
  border-bottom: 1px solid var(--line);
  background-image: linear-gradient(to top, rgba(226, 217, 198, 0.58) 1px, transparent 1px);
  background-size: 100% 39px;
}

.bar-chart span {
  width: 6px;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(180deg, #9caf73, #768f54);
  animation: grow-bar 620ms cubic-bezier(0.2, 0.72, 0.22, 1) both;
  transform-origin: bottom;
}

.axis-labels {
  display: flex;
  justify-content: space-between;
  margin-left: 78px;
  color: #283128;
  font-size: 12px;
  font-weight: 700;
}

.settings-screen {
  padding-top: 18px;
}

.settings-panel {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  padding: 16px;
  box-shadow: 0 10px 25px rgba(65, 62, 46, 0.06);
}

.settings-panel h2 {
  margin: 0 0 14px;
  font-size: 18px;
}

.settings-summary,
.empty-state {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.7;
}

.empty-state {
  border: 1px dashed var(--line);
  border-radius: 12px;
  background: rgba(255, 253, 247, 0.7);
  padding: 16px;
}

.settings-panel label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding: 15px 0;
  font-weight: 700;
}

.settings-panel .secondary-button {
  margin-top: 10px;
}

.reveal {
  animation: reveal-card 520ms cubic-bezier(0.2, 0.72, 0.22, 1) both;
}

.delay-1 { animation-delay: 70ms; }
.delay-2 { animation-delay: 140ms; }
.delay-3 { animation-delay: 210ms; }

@keyframes phone-rise {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes page-in {
  from {
    opacity: 0;
    transform: translateX(12px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes reveal-card {
  from {
    opacity: 0;
    transform: translateY(13px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translate(-50%, -8px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

@keyframes panel-drop {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes grow-bar {
  from {
    transform: scaleY(0.16);
  }
  to {
    transform: scaleY(1);
  }
}

@media (max-width: 430px) {
  .app-shell,
  .start-shell {
    padding: 0;
  }

  .phone-frame,
  .start-phone {
    width: 100%;
    height: 100vh;
    min-height: 100vh;
    border: 0;
    border-radius: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
