/* plants.css — Plant section styles for The Honest Version */

/* ---- NAV ACTIVE ---- */
.nav-active { color: var(--sage) !important; }

/* ---- PLANT HERO ---- */
.plant-hero {
  position: relative;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 5rem 2rem 3rem;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  overflow: hidden;
  border-bottom: 1px solid var(--cream-dark);
}

.plant-hero-inner { max-width: 560px; }

.plant-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(3rem, 7vw, 5rem);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0.5rem 0 1rem;
}

.plant-hero p {
  font-size: 1rem;
  color: var(--ink-light);
  line-height: 1.75;
  max-width: 480px;
}

.plant-hero-deco {
  flex-shrink: 0;
  color: var(--sage);
  opacity: 0.7;
}

.leaf-svg {
  width: 120px;
  height: 180px;
}

/* ---- CONTROLS ---- */
.plant-controls {
  max-width: var(--max-width);
  margin: 2.5rem auto 0;
  padding: 0 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.plant-search {
  width: 100%;
  max-width: 400px;
  padding: 0.85rem 1.25rem;
  background: var(--white);
  border: 1px solid var(--cream-dark);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
  outline: none;
  transition: border-color 0.2s;
}

.plant-search:focus { border-color: var(--sage); }

.plant-filters {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: none;
  border: 1px solid var(--cream-dark);
  padding: 0.45rem 1rem;
  font-family: var(--font-body);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--ink-light);
  cursor: pointer;
  transition: all 0.2s;
  text-transform: uppercase;
}

.filter-btn:hover { border-color: var(--sage); color: var(--sage); }
.filter-btn.active { background: var(--sage); color: white; border-color: var(--sage); }

/* ---- PLANT GRID ---- */
.plant-grid {
  max-width: var(--max-width);
  margin: 2.5rem auto;
  padding: 0 2rem 4rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

/* ---- PLANT CARD ---- */
.plant-card {
  background: var(--white);
  border: 1px solid var(--cream-dark);
  padding: 1.75rem;
  text-decoration: none;
  color: inherit;
  display: flex;
  gap: 1.25rem;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
}

.plant-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(0,0,0,0.06);
}

.plant-card--owned {
  border-left: 3px solid var(--sage);
}

.plant-card-emoji {
  font-size: 2.2rem;
  flex-shrink: 0;
  line-height: 1;
  padding-top: 2px;
}

.plant-card-body { flex: 1; }

.plant-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}

.plant-card-top h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 400;
  line-height: 1.2;
}

.care-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 6px;
}

.botanical {
  font-size: 0.78rem;
  color: var(--ink-faint);
  font-style: italic;
  margin-bottom: 0.6rem;
}

.plant-excerpt {
  font-size: 0.875rem;
  color: var(--ink-light);
  line-height: 1.55;
  margin-bottom: 0.85rem;
}

.plant-card-meta {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
  font-size: 0.7rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.owned-mini {
  color: var(--sage);
  font-weight: 500;
}

.toxic-mini {
  color: var(--rust);
}

/* ---- PLANT PROFILE ---- */
.plant-profile {
  max-width: 820px;
  margin: 0 auto;
  padding: 4rem 2rem 2rem;
}

.plant-profile-back {
  margin-bottom: 2.5rem;
}

.plant-profile-back a {
  font-size: 0.82rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-faint);
  text-decoration: none;
  transition: color 0.2s;
}

.plant-profile-back a:hover { color: var(--sage); }

.plant-profile-header {
  display: flex;
  gap: 2.5rem;
  align-items: flex-start;
  margin-bottom: 3.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--cream-dark);
}

.plant-profile-emoji {
  font-size: 5rem;
  line-height: 1;
  flex-shrink: 0;
}

.plant-profile-tags {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.plant-tag {
  display: inline-block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--cream-dark);
  color: var(--ink-light);
  padding: 0.2rem 0.7rem;
}

.owned-badge {
  display: inline-block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: rgba(122,140,114,0.15);
  color: var(--sage);
  padding: 0.2rem 0.7rem;
  font-weight: 500;
}

.plant-profile-titles h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 400;
  line-height: 1.1;
  margin-bottom: 0.35rem;
}

.botanical-name {
  font-size: 0.9rem;
  color: var(--ink-faint);
  font-style: italic;
  margin-bottom: 1rem;
}

.plant-summary {
  font-size: 1rem;
  color: var(--ink-light);
  line-height: 1.7;
}

/* ---- FACT CARDS ---- */
.plant-facts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1px;
  background: var(--cream-dark);
  border: 1px solid var(--cream-dark);
  margin-bottom: 3rem;
}

.fact-card {
  background: var(--white);
  padding: 1.25rem 1.5rem;
}

.fact-label {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 0.35rem;
}

.fact-value {
  font-size: 0.92rem;
  color: var(--ink);
  font-weight: 500;
  line-height: 1.4;
}

/* ---- PROFILE BODY ---- */
.plant-info-section {
  margin-bottom: 2.5rem;
}

.plant-info-section h2 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 400;
  margin-bottom: 0.85rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--cream-dark);
}

.plant-info-section p {
  font-size: 1rem;
  color: var(--ink-light);
  line-height: 1.8;
}

.plant-info-section ul {
  padding-left: 1.25rem;
}

.plant-info-section li {
  font-size: 0.95rem;
  color: var(--ink-light);
  line-height: 1.7;
  margin-bottom: 0.4rem;
}

/* ---- DEL'S NOTES ---- */
.plant-my-notes {
  background: #f0ede4;
  border-left: 3px solid var(--amber);
  padding: 1.75rem 2rem;
  margin-bottom: 2.5rem;
}

.my-notes-label {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 1rem;
  font-weight: 500;
}

.my-notes-body p {
  font-size: 0.97rem;
  color: var(--ink);
  line-height: 1.8;
  margin-bottom: 0.85rem;
  font-family: var(--font-display);
  font-style: italic;
}

.my-notes-body p:last-child { margin-bottom: 0; }

/* ---- PLANT LOG ---- */
.plant-log {
  margin-bottom: 3rem;
}

.plant-log h3 {
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 1.25rem;
}

.log-entries {
  border-left: 1px solid var(--cream-dark);
  padding-left: 1.5rem;
}

.log-entry {
  position: relative;
  padding-bottom: 1.5rem;
}

.log-entry::before {
  content: '';
  position: absolute;
  left: -1.6rem;
  top: 6px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--sage);
}

.log-date {
  font-size: 0.75rem;
  color: var(--ink-faint);
  letter-spacing: 0.05em;
  margin-bottom: 0.3rem;
}

.log-text {
  font-size: 0.95rem;
  color: var(--ink-light);
  line-height: 1.65;
}

/* ---- ADMIN PLANT FORM ---- */
.plant-admin-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 600px) {
  .plant-profile-header { flex-direction: column; gap: 1rem; }
  .plant-profile-emoji { font-size: 3.5rem; }
  .plant-admin-grid { grid-template-columns: 1fr; }
  .plant-hero { flex-direction: column; gap: 1rem; }
  .leaf-svg { width: 70px; height: 100px; }
}

/* ---- PLANT PHOTO GALLERY ---- */
.plant-photos {
  margin-bottom: 3rem;
}

.plant-photos-label {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--cream-dark);
}

.plant-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.75rem;
}

.plant-photo-item {
  cursor: pointer;
  overflow: hidden;
  background: var(--cream-dark);
  border: 1px solid var(--cream-dark);
  transition: opacity 0.2s;
}

.plant-photo-item:hover { opacity: 0.88; }

.plant-photo-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.plant-photo-caption {
  padding: 0.5rem 0.75rem;
  font-size: 0.78rem;
  color: var(--ink-faint);
  line-height: 1.4;
  font-style: italic;
}

/* ---- LOG PHOTOS ---- */
.log-photo {
  display: block;
  max-width: 100%;
  max-height: 240px;
  object-fit: cover;
  margin-top: 0.75rem;
  border: 1px solid var(--cream-dark);
  cursor: pointer;
  transition: opacity 0.2s;
}

.log-photo:hover { opacity: 0.85; }

/* ---- LIGHTBOX ---- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(20, 18, 14, 0.92);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
  padding: 2rem;
}

.lightbox.active {
  opacity: 1;
  pointer-events: all;
}

.lightbox img {
  max-width: 90vw;
  max-height: 80vh;
  object-fit: contain;
  border: none;
}

.lightbox-caption {
  margin-top: 1rem;
  font-size: 0.85rem;
  color: rgba(245,240,232,0.65);
  font-style: italic;
  text-align: center;
  max-width: 500px;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.75rem;
  background: none;
  border: none;
  color: rgba(245,240,232,0.7);
  font-size: 1.4rem;
  cursor: pointer;
  transition: color 0.2s;
  line-height: 1;
}

.lightbox-close:hover { color: white; }

/* ---- ADMIN PHOTO PREVIEW GRID ---- */
.photo-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}

.photo-preview-item {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.photo-preview-img {
  width: 100%;
  padding-top: 100%;
  background-size: cover;
  background-position: center;
  border: 1px solid var(--cream-dark);
  position: relative;
}

.photo-remove-btn {
  position: absolute;
  top: 4px;
  right: 4px;
  background: rgba(20,18,14,0.75);
  color: white;
  border: none;
  width: 22px;
  height: 22px;
  font-size: 0.7rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background 0.2s;
}

.photo-remove-btn:hover { background: var(--rust); }

.photo-caption-input {
  width: 100%;
  font-size: 0.75rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid var(--cream-dark);
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  outline: none;
}

.photo-caption-input:focus { border-color: var(--sage); }
