/* ========================================
   GARDENGLANCE - Complete Design System
   ======================================== */

:root {
  --primary: #4CAF50;
  --primary-dark: #388E3C;
  --primary-light: #C8E6C9;
  --secondary: #81C784;
  --accent: #FFB300;
  --accent-dark: #FF8F00;
  --danger: #F44336;
  --surface: #FFFFFF;
  --surface-2: #F8FBF8;
  --surface-3: #F1F8F1;
  --on-surface: #1B2A1B;
  --on-surface-2: #4A604A;
  --on-surface-3: #7A967A;
  --divider: #E8F0E8;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.1), 0 2px 4px rgba(0,0,0,0.06);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.12), 0 4px 8px rgba(0,0,0,0.08);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --nav-height: 64px;
  --bar-height: 60px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  width: 100%; height: 100%;
  overflow: hidden;
  background: #1a2e1a;
}

body {
  font-family: var(--font);
  color: var(--on-surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

/* ========================================
   APP SHELL
   ======================================== */

#app {
  width: 100%;
  max-width: 430px;
  height: 100dvh;
  height: 100vh;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  background: var(--surface-2);
  position: relative;
  overflow: hidden;
}

/* ========================================
   TOP APP BAR
   ======================================== */

.app-bar {
  height: var(--bar-height);
  min-height: var(--bar-height);
  background: var(--primary);
  display: flex;
  align-items: center;
  padding: 0 8px;
  position: relative;
  z-index: 10;
  box-shadow: 0 2px 8px rgba(76,175,80,0.3);
}

.app-bar-title {
  flex: 1;
  text-align: center;
  font-size: 18px;
  font-weight: 700;
  color: white;
  letter-spacing: 0.3px;
}

.app-bar-btn {
  width: 44px; height: 44px;
  border: none; background: none;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: white;
  transition: background var(--transition);
  flex-shrink: 0;
}

.app-bar-btn:active { background: rgba(255,255,255,0.2); }
.app-bar-btn svg { width: 22px; height: 22px; }

.app-bar-right {
  width: 44px; height: 44px;
  flex-shrink: 0;
}

/* ========================================
   SCREENS
   ======================================== */

.screens-container {
  flex: 1;
  position: relative;
  overflow: hidden;
}

.screen {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateX(30px);
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}

.screen.active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: all;
}

.screen-scroll {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  padding: 16px 16px 0;
  scroll-behavior: smooth;
}

.screen-scroll::-webkit-scrollbar { display: none; }
.log-scroll { padding-top: 0; }

/* ========================================
   BOTTOM NAVIGATION
   ======================================== */

.bottom-nav {
  height: var(--nav-height);
  min-height: var(--nav-height);
  background: var(--surface);
  display: flex;
  align-items: stretch;
  border-top: 1px solid var(--divider);
  box-shadow: 0 -2px 12px rgba(0,0,0,0.08);
  position: relative;
  z-index: 10;
}

.nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: none;
  background: none;
  cursor: pointer;
  padding: 8px 4px;
  color: var(--on-surface-3);
  transition: color var(--transition);
  position: relative;
  min-height: 44px;
}

.nav-item::before {
  content: '';
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 32px;
  background: var(--primary-light);
  border-radius: 16px;
  transition: width var(--transition), opacity var(--transition);
  opacity: 0;
}

.nav-item.active { color: var(--primary); }
.nav-item.active::before { width: 64px; opacity: 1; }

.nav-icon {
  width: 24px; height: 24px;
  fill: currentColor;
  position: relative;
  z-index: 1;
  transition: transform var(--transition);
}

.nav-item.active .nav-icon { transform: scale(1.1); }

.nav-label {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.3px;
  position: relative;
  z-index: 1;
}

/* ========================================
   DASHBOARD
   ======================================== */

.dashboard-greeting {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding: 4px 0;
}

.greeting-sub {
  font-size: 13px;
  color: var(--on-surface-3);
  font-weight: 400;
}

.greeting-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--on-surface);
  margin-top: 2px;
}

.greeting-avatar {
  width: 52px; height: 52px;
  background: var(--primary-light);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
}

/* Stats */
.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.stat-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 14px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  box-shadow: var(--shadow-sm);
}

.stat-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
}

.stat-icon svg { width: 20px; height: 20px; }

.stat-value {
  font-size: 22px;
  font-weight: 700;
  color: var(--on-surface);
  line-height: 1;
}

.stat-label {
  font-size: 10px;
  color: var(--on-surface-3);
  font-weight: 500;
  text-align: center;
  line-height: 1.2;
}

/* Section Headers */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  margin-top: 4px;
}

.section-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--on-surface);
}

.section-action {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 0;
}

/* Growth Overview */
.card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
}

.growth-item {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.growth-item:last-child { margin-bottom: 0; }

.growth-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--on-surface-2);
  min-width: 75px;
  text-transform: capitalize;
}

.growth-bar-wrap {
  flex: 1;
  height: 8px;
  background: var(--surface-3);
  border-radius: 4px;
  overflow: hidden;
}

.growth-bar {
  height: 100%;
  border-radius: 4px;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.growth-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--on-surface-2);
  min-width: 20px;
  text-align: right;
}

.empty-inline {
  text-align: center;
  font-size: 13px;
  color: var(--on-surface-3);
  padding: 8px 0;
}

/* Recent Plants */
.empty-state-small {
  text-align: center;
  padding: 24px 16px;
  background: var(--surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
}

.empty-state-small span { font-size: 32px; display: block; margin-bottom: 8px; }
.empty-state-small p { font-size: 13px; color: var(--on-surface-3); }

/* Quick Actions */
.quick-actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.quick-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: none;
  border-radius: var(--radius-md);
  padding: 14px 6px;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.quick-action-btn:active {
  transform: scale(0.95);
  box-shadow: none;
}

.qa-icon {
  width: 40px; height: 40px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
}

.qa-icon svg { width: 22px; height: 22px; }

.quick-action-btn span {
  font-size: 10px;
  font-weight: 600;
  color: var(--on-surface-2);
  text-align: center;
}

/* ========================================
   SEARCH & FILTERS
   ======================================== */

.search-bar-wrap {
  background: var(--surface);
  padding: 12px 16px 0;
  border-bottom: 1px solid var(--divider);
}

.library-search-wrap {
  padding: 12px 16px 8px;
}

.search-bar {
  display: flex;
  align-items: center;
  background: var(--surface-3);
  border-radius: var(--radius-xl);
  padding: 0 14px;
  gap: 8px;
  height: 42px;
}

.search-bar svg { width: 18px; height: 18px; flex-shrink: 0; }

.search-bar input {
  flex: 1;
  border: none;
  background: none;
  font-size: 14px;
  font-family: var(--font);
  color: var(--on-surface);
  outline: none;
}

.search-bar input::placeholder { color: var(--on-surface-3); }

.clear-search {
  width: 24px; height: 24px;
  border: none; background: none;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; border-radius: 50%;
  flex-shrink: 0;
}

.clear-search svg { width: 16px; height: 16px; }

/* Filter Chips */
.filter-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 10px 0 10px;
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.filter-chips::-webkit-scrollbar { display: none; }

.chip {
  flex-shrink: 0;
  height: 30px;
  padding: 0 14px;
  border-radius: 15px;
  border: 1.5px solid var(--divider);
  background: var(--surface);
  font-size: 12px;
  font-weight: 500;
  font-family: var(--font);
  color: var(--on-surface-3);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.chip.active {
  background: var(--primary);
  border-color: var(--primary);
  color: white;
}

/* ========================================
   PLANT LIST CARDS
   ======================================== */

.plant-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  margin: 10px 16px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  cursor: pointer;
}

.plant-card:active {
  transform: scale(0.98);
  box-shadow: none;
}

.plant-card-inner {
  display: flex;
  align-items: center;
  padding: 14px;
  gap: 14px;
}

.plant-avatar {
  width: 52px; height: 52px;
  border-radius: var(--radius-sm);
  background: var(--primary-light);
  display: flex; align-items: center; justify-content: center;
  font-size: 28px;
  flex-shrink: 0;
  position: relative;
  overflow: hidden;
}

.plant-avatar-img {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: var(--radius-sm);
}

.plant-info { flex: 1; min-width: 0; }

.plant-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--on-surface);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.plant-species {
  font-size: 12px;
  color: var(--on-surface-3);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-style: italic;
}

.plant-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  flex-wrap: wrap;
}

.stage-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: 600;
  text-transform: capitalize;
}

.watered-badge {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  color: #2196F3;
  font-weight: 500;
}

.watered-badge svg { width: 11px; height: 11px; fill: #2196F3; }

.plant-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
}

.plant-action-btn {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: none;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.plant-action-btn:active { transform: scale(0.9); }

.btn-edit {
  background: rgba(76,175,80,0.1);
  color: var(--primary);
}

.btn-trash {
  background: rgba(244,67,54,0.1);
  color: var(--danger);
}

.plant-action-btn svg { width: 16px; height: 16px; }

/* Swipe indicator */
.plant-card-bar {
  height: 3px;
  width: 100%;
}

/* Stage colors */
.stage-seedling { background: rgba(139,195,74,0.15); color: #558B2F; }
.stage-vegetative { background: rgba(76,175,80,0.15); color: #2E7D32; }
.stage-flowering { background: rgba(233,30,99,0.1); color: #C2185B; }
.stage-mature { background: rgba(121,85,72,0.1); color: #4E342E; }
.stage-dormant { background: rgba(96,125,139,0.1); color: #37474F; }
.stage-default { background: rgba(158,158,158,0.1); color: #616161; }

/* ========================================
   EMPTY STATE
   ======================================== */

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 32px;
  text-align: center;
}

.empty-state-icon {
  font-size: 72px;
  margin-bottom: 16px;
  line-height: 1;
}

.empty-state-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--on-surface);
  margin-bottom: 8px;
}

.empty-state-desc {
  font-size: 14px;
  color: var(--on-surface-3);
  line-height: 1.5;
  max-width: 240px;
}

.empty-state-btn {
  margin-top: 24px;
  padding: 12px 24px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: var(--radius-xl);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(76,175,80,0.4);
  transition: transform 0.15s ease;
}

.empty-state-btn:active { transform: scale(0.97); }

/* ========================================
   FAB
   ======================================== */

.fab {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 56px; height: 56px;
  border-radius: 16px;
  background: var(--primary);
  border: none;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(76,175,80,0.45);
  z-index: 5;
  transition: transform 0.2s cubic-bezier(0.34,1.56,0.64,1), box-shadow 0.2s ease;
}

.fab:active {
  transform: scale(0.92);
  box-shadow: 0 2px 8px rgba(76,175,80,0.3);
}

/* ========================================
   BOTTOM SHEETS
   ======================================== */

.sheet-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
  backdrop-filter: blur(2px);
}

.sheet-overlay.visible {
  opacity: 1;
  pointer-events: all;
}

.bottom-sheet {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: 430px;
  background: var(--surface);
  border-radius: 24px 24px 0 0;
  z-index: 51;
  transition: transform 0.35s cubic-bezier(0.34,1.2,0.64,1);
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.bottom-sheet.open {
  transform: translateX(-50%) translateY(0);
}

.sheet-handle {
  width: 40px; height: 4px;
  background: var(--divider);
  border-radius: 2px;
  margin: 12px auto 0;
  flex-shrink: 0;
}

.sheet-header {
  display: flex;
  align-items: center;
  padding: 16px 20px 0;
  flex-shrink: 0;
}

.sheet-title {
  flex: 1;
  font-size: 18px;
  font-weight: 700;
  color: var(--on-surface);
}

.sheet-close {
  width: 36px; height: 36px;
  border: none; background: var(--surface-3);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--on-surface-2);
}

.sheet-close svg { width: 18px; height: 18px; }

.sheet-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
  -webkit-overflow-scrolling: touch;
}

/* ========================================
   FORMS
   ======================================== */

.form-field {
  position: relative;
  margin-bottom: 20px;
}

.form-input {
  width: 100%;
  height: 54px;
  background: var(--surface-3);
  border: 1.5px solid var(--divider);
  border-radius: var(--radius-sm);
  padding: 18px 14px 6px;
  font-size: 15px;
  font-family: var(--font);
  color: var(--on-surface);
  outline: none;
  transition: border-color var(--transition), background var(--transition);
  -webkit-appearance: none;
  appearance: none;
}

.form-input:focus {
  border-color: var(--primary);
  background: var(--surface);
}

.form-input:not(:placeholder-shown) + .form-label,
.form-input:focus + .form-label {
  transform: translateY(-10px) scale(0.75);
  color: var(--primary);
}

.form-label {
  position: absolute;
  left: 14px;
  top: 16px;
  font-size: 15px;
  color: var(--on-surface-3);
  pointer-events: none;
  transform-origin: left top;
  transition: transform var(--transition), color var(--transition);
  font-family: var(--font);
}

.form-label-active {
  transform: translateY(-10px) scale(0.75);
  color: var(--on-surface-3);
}

.form-label-date {
  transform: translateY(-10px) scale(0.75);
}

.form-select {
  cursor: pointer;
  padding-top: 20px;
}

.btn-primary {
  width: 100%;
  height: 52px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(76,175,80,0.4);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  margin-top: 4px;
}

.btn-primary:active {
  transform: scale(0.97);
  box-shadow: 0 2px 6px rgba(76,175,80,0.3);
}

/* ========================================
   DETAIL MODAL
   ======================================== */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 60;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition);
}

.modal-overlay.visible {
  opacity: 1;
  pointer-events: all;
}

.detail-modal {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  width: 100%;
  max-width: 430px;
  height: 92vh;
  background: var(--surface-2);
  z-index: 61;
  border-radius: 20px 20px 0 0;
  overflow: hidden;
  transition: transform 0.35s cubic-bezier(0.34,1.1,0.64,1);
  display: flex;
  flex-direction: column;
}

.detail-modal.open {
  transform: translateX(-50%) translateY(0);
}

.detail-header {
  padding: 20px 16px 24px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex-shrink: 0;
}

.detail-back {
  width: 40px; height: 40px;
  border: none;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
}

.detail-back svg { width: 20px; height: 20px; }

.detail-title-wrap { flex: 1; }

.detail-name {
  font-size: 22px;
  font-weight: 700;
  color: white;
}

.detail-species {
  font-size: 14px;
  color: rgba(255,255,255,0.8);
  font-style: italic;
  margin-top: 3px;
}

.detail-edit-btn {
  width: 40px; height: 40px;
  border: none;
  background: rgba(255,255,255,0.2);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
}

.detail-edit-btn svg { width: 18px; height: 18px; }

.detail-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  -webkit-overflow-scrolling: touch;
}

.detail-body::-webkit-scrollbar { display: none; }

.detail-section {
  background: var(--surface);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
}

.detail-row {
  display: flex;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--divider);
  gap: 14px;
}

.detail-row:last-child { border-bottom: none; }

.detail-row-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.detail-row-content { flex: 1; }

.detail-row-label {
  font-size: 11px;
  color: var(--on-surface-3);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.detail-row-value {
  font-size: 15px;
  font-weight: 500;
  color: var(--on-surface);
  margin-top: 2px;
}

.detail-actions {
  display: flex;
  gap: 10px;
  padding: 0 0 16px;
}

.detail-action-btn {
  flex: 1;
  height: 48px;
  border: none;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.15s ease;
}

.detail-action-btn:active { transform: scale(0.97); }
.detail-action-btn svg { width: 18px; height: 18px; }

.btn-edit-full {
  background: rgba(76,175,80,0.1);
  color: var(--primary);
}

.btn-delete-full {
  background: rgba(244,67,54,0.1);
  color: var(--danger);
}

.btn-water-full {
  background: rgba(33,150,243,0.1);
  color: #2196F3;
  flex: 1.5;
}

/* ========================================
   CONFIRM DIALOG
   ======================================== */

.confirm-dialog {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.85);
  width: calc(100% - 64px);
  max-width: 320px;
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 28px 24px 20px;
  z-index: 71;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition);
  box-shadow: var(--shadow-lg);
}

.confirm-dialog.open {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  pointer-events: all;
}

.confirm-icon { font-size: 44px; margin-bottom: 12px; }

.confirm-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--on-surface);
  margin-bottom: 8px;
}

.confirm-msg {
  font-size: 14px;
  color: var(--on-surface-3);
  line-height: 1.5;
}

.confirm-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

.btn-cancel {
  flex: 1;
  height: 44px;
  border: 1.5px solid var(--divider);
  background: var(--surface);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font);
  color: var(--on-surface-2);
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-cancel:active { background: var(--surface-3); }

.btn-delete {
  flex: 1;
  height: 44px;
  border: none;
  background: var(--danger);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font);
  color: white;
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.btn-delete:active { opacity: 0.85; }

/* ========================================
   SNACKBAR
   ======================================== */

.snackbar {
  position: fixed;
  bottom: calc(var(--nav-height) + 12px);
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #323232;
  color: white;
  padding: 12px 20px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
  white-space: nowrap;
  max-width: calc(100% - 32px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.snackbar.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ========================================
   PLANT LIBRARY
   ======================================== */

.lib-section-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--on-surface-3);
  padding: 12px 16px 6px;
}

.lib-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  margin: 6px 16px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform 0.15s ease;
}

.lib-card:active { transform: scale(0.98); }

.lib-emoji {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
  flex-shrink: 0;
}

.lib-info { flex: 1; min-width: 0; }

.lib-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--on-surface);
}

.lib-species {
  font-size: 12px;
  color: var(--on-surface-3);
  font-style: italic;
  margin-top: 2px;
}

.lib-tags {
  display: flex;
  gap: 4px;
  margin-top: 5px;
  flex-wrap: wrap;
}

.lib-tag {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 8px;
  background: var(--primary-light);
  color: var(--primary-dark);
}

.lib-chevron {
  flex-shrink: 0;
  color: var(--on-surface-3);
}

.lib-chevron svg { width: 18px; height: 18px; }

/* Library Detail */
.lib-detail-banner {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 60px;
  background: var(--primary-light);
}

.lib-care-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 12px 0;
}

.lib-care-item {
  background: var(--surface);
  border-radius: var(--radius-sm);
  padding: 12px;
  box-shadow: var(--shadow-sm);
}

.lib-care-label {
  font-size: 10px;
  color: var(--on-surface-3);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.lib-care-value {
  font-size: 14px;
  color: var(--on-surface);
  font-weight: 500;
  margin-top: 4px;
}

/* ========================================
   CALENDAR
   ======================================== */

.calendar-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.cal-month-label {
  font-size: 16px;
  font-weight: 700;
  color: var(--on-surface);
}

.cal-nav-btn {
  width: 36px; height: 36px;
  border: none;
  background: var(--surface-3);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--on-surface-2);
  transition: background 0.15s ease;
}

.cal-nav-btn:active { background: var(--primary-light); }
.cal-nav-btn svg { width: 18px; height: 18px; }

.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
  margin-bottom: 4px;
}

.cal-weekdays span {
  text-align: center;
  font-size: 11px;
  font-weight: 600;
  color: var(--on-surface-3);
  padding: 4px 0;
}

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}

.cal-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  color: var(--on-surface);
  position: relative;
  transition: background 0.15s ease;
  border: none;
  background: none;
  font-family: var(--font);
}

.cal-day:hover { background: var(--surface-3); }
.cal-day.other-month { color: var(--on-surface-3); opacity: 0.4; }
.cal-day.today { color: var(--primary); font-weight: 700; }
.cal-day.today::after {
  content: '';
  position: absolute;
  bottom: 3px;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--primary);
}

.cal-day.selected {
  background: var(--primary);
  color: white;
  font-weight: 700;
}

.cal-day.selected::after { display: none; }

.cal-day.has-event::before {
  content: '';
  position: absolute;
  top: 3px;
  right: 3px;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.cal-day.selected.has-event::before {
  background: white;
}

/* Event Items */
.event-item {
  background: var(--surface);
  border-radius: var(--radius-md);
  margin: 6px 16px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--shadow-sm);
}

.event-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.event-info { flex: 1; }

.event-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--on-surface);
}

.event-subtitle {
  font-size: 12px;
  color: var(--on-surface-3);
  margin-top: 2px;
}

.event-delete-btn {
  width: 30px; height: 30px;
  border: none;
  background: rgba(244,67,54,0.1);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--danger);
  flex-shrink: 0;
}

.event-delete-btn svg { width: 14px; height: 14px; }

.reminder-item {
  background: var(--surface);
  border-radius: var(--radius-md);
  margin: 6px 16px;
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
}

.reminder-type-badge {
  width: 40px; height: 40px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.reminder-info { flex: 1; }

.reminder-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--on-surface);
}

.reminder-date {
  font-size: 11px;
  color: var(--on-surface-3);
  margin-top: 2px;
}

.reminder-delete {
  width: 30px; height: 30px;
  border: none;
  background: rgba(244,67,54,0.1);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--danger);
}

.reminder-delete svg { width: 14px; height: 14px; }

/* Recent plant card (dashboard) */
.recent-plant-card {
  background: var(--surface);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  margin-bottom: 8px;
  transition: transform 0.15s ease;
}

.recent-plant-card:active { transform: scale(0.98); }

.recent-plant-avatar {
  width: 44px; height: 44px;
  border-radius: 10px;
  background: var(--primary-light);
  display: flex; align-items: center; justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.recent-plant-info { flex: 1; min-width: 0; }

.recent-plant-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--on-surface);
}

.recent-plant-species {
  font-size: 12px;
  color: var(--on-surface-3);
  font-style: italic;
}

.chevron-right {
  color: var(--on-surface-3);
}

.chevron-right svg { width: 16px; height: 16px; }

/* ========================================
   LOADING / SKELETON
   ======================================== */

@keyframes shimmer {
  0% { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}

.skeleton {
  background: linear-gradient(90deg, var(--surface-3) 25%, var(--divider) 50%, var(--surface-3) 75%);
  background-size: 800px 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 6px;
}

/* ========================================
   RIPPLE EFFECT
   ======================================== */

.ripple-container { overflow: hidden; position: relative; }

@keyframes ripple {
  to { transform: scale(4); opacity: 0; }
}

.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  animation: ripple 0.6s linear;
  pointer-events: none;
}

/* ========================================
   UTILITIES
   ======================================== */

.d-none { display: none !important; }

/* Smooth scroll to active tab highlight */
@keyframes tabPop {
  0% { transform: scale(1); }
  50% { transform: scale(1.2); }
  100% { transform: scale(1.1); }
}

.nav-item.active .nav-icon {
  animation: tabPop 0.3s ease;
}
