@font-face {
  font-family: Typewriter;
  src: url('assets/HellenicTypewriter-Regular.woff') format('woff');
  font-display: swap;
}
@font-face {
  font-family: Sans;
  src: url('assets/Chromatica-Regular.woff') format('woff');
  font-display: swap;
}
@font-face {
  font-family: Sans;
  src: url('assets/Chromatica-Medium.woff') format('woff');
  font-weight: 600;
  font-display: swap;
}

:root {
  --paper: #f9f5f1;
  --sand: #ece5df;
  --ink: #222222;
  --muted: #55514a;
  --green: #114b43;
  --lime: #bdb846;
  --coral: #ee7853;
  --lilac: #e5dae8;
  --sage: #cbd8c5;
  --aqua: #5ab4ac;
  --line: 1.5px solid var(--ink);
  --shadow: 4px 4px 0 var(--ink);
  --shadow-sm: 2px 2px 0 var(--ink);
  --shadow-lg: 7px 7px 0 var(--ink);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.6 Sans, Arial, sans-serif;
  padding-bottom: 76px;
}

button, a, input, select, textarea {
  font: inherit;
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

img {
  max-width: 100%;
  display: block;
}

h1, h2, h3, h4, .eyebrow, .brand, .seal, .ticker, .pill-mono, .tab-btn, .card-num, .stat-num {
  font-family: Typewriter, Georgia, serif;
  font-weight: 400;
}

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

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

.wrap {
  max-width: 1260px;
  width: calc(100% - 64px);
  margin-inline: auto;
}

/* Top Banner & Header */
.top-banner {
  background: var(--green);
  color: var(--paper);
  border-bottom: var(--line);
  padding: 9px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 12px;
}

.top-banner-left {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: Typewriter, serif;
  letter-spacing: 0.6px;
}

.mode-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--paper);
  color: var(--ink);
  border: var(--line);
  padding: 4px 10px;
  font-family: Typewriter, serif;
  font-size: 11px;
  cursor: pointer;
  box-shadow: 2px 2px 0 var(--lime);
}

.header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--paper);
  border-bottom: var(--line);
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 36px;
  gap: 24px;
}

.brand {
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 19px;
  line-height: 1.1;
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
  text-align: left;
}

.brand svg {
  width: 32px;
  height: 40px;
  fill: var(--lime);
  stroke: var(--ink);
  stroke-width: 1.5;
  flex-shrink: 0;
}

.brand small {
  display: block;
  font-family: Sans, sans-serif;
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
}

.main-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.nav-btn {
  background: transparent;
  border: 1.5px solid transparent;
  padding: 9px 15px;
  font-family: Typewriter, serif;
  font-size: 13px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.12s, background 0.12s;
}

.nav-btn:hover {
  background: var(--sand);
  border-color: var(--ink);
}

.nav-btn.active {
  background: var(--lime);
  border-color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.nav-badge {
  background: var(--green);
  color: var(--paper);
  font-size: 10px;
  padding: 1px 6px;
  border: 1px solid var(--ink);
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: var(--lime);
  border: var(--line);
  box-shadow: var(--shadow);
  padding: 13px 20px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.12s, box-shadow 0.12s;
}

.button:hover {
  transform: translate(2px, 2px);
  box-shadow: var(--shadow-sm);
}

.button-secondary {
  background: var(--paper);
}

.button-coral {
  background: var(--coral);
}

.button-green {
  background: var(--green);
  color: var(--paper);
}

.button-sm {
  padding: 8px 13px;
  font-size: 12px;
  box-shadow: var(--shadow-sm);
}

.eyebrow {
  font-size: 11px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  background: var(--green);
  border-radius: 50%;
}

/* Home Hero */
.hero-app {
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: 44px;
  padding-block: 44px 52px;
  align-items: center;
}

.hero-app h1 {
  font-size: clamp(34px, 3.9vw, 56px);
  line-height: 1.12;
  margin-bottom: 20px;
}

.highlight {
  background: linear-gradient(transparent 66%, var(--lime) 66%, var(--lime) 94%, transparent 94%);
}

.hero-lead {
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink);
  max-width: 540px;
  margin-bottom: 24px;
}

.hero-search-bar {
  display: flex;
  gap: 10px;
  max-width: 540px;
  margin-bottom: 18px;
}

.hero-search-bar input {
  flex: 1;
  padding: 14px 16px;
  background: var(--paper);
  border: var(--line);
  box-shadow: var(--shadow-sm);
  font-size: 15px;
}

.quick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 12px;
}

.chip {
  background: var(--sand);
  border: var(--line);
  padding: 5px 11px;
  font-family: Typewriter, serif;
  font-size: 11px;
  cursor: pointer;
  transition: background 0.15s;
}

.chip:hover, .chip.active {
  background: var(--lime);
}

.hero-stage {
  position: relative;
  height: 490px;
  background: var(--lilac);
  border: var(--line);
  border-radius: 48% 48% 0 0;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero-stage img {
  position: absolute;
  width: 88%;
  height: 88%;
  object-fit: contain;
  left: 6%;
  bottom: 0;
  mix-blend-mode: multiply;
}

.seal {
  position: absolute;
  right: 18px;
  top: 86px;
  width: 112px;
  height: 112px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: var(--coral);
  clip-path: polygon(50% 0%,57% 7%,66% 3%,70% 13%,81% 10%,83% 21%,94% 23%,91% 34%,100% 40%,94% 49%,100% 59%,90% 64%,94% 75%,82% 78%,80% 90%,69% 87%,64% 98%,54% 93%,45% 100%,38% 92%,26% 96%,23% 84%,12% 84%,13% 71%,3% 67%,8% 56%,0% 48%,8% 39%,4% 29%,15% 25%,16% 14%,28% 16%,33% 5%,42% 9%);
  font-size: 10px;
  text-align: center;
  line-height: 1.3;
  transform: rotate(8deg);
  z-index: 2;
  color: var(--ink);
}

.seal strong {
  font-size: 28px;
  line-height: 1.05;
  font-weight: 400;
}

.ticker {
  display: flex;
  align-items: center;
  justify-content: space-around;
  gap: 20px;
  flex-wrap: wrap;
  border-block: var(--line);
  background: var(--lime);
  padding: 16px 24px;
  font-size: 12px;
  letter-spacing: 0.7px;
  text-transform: uppercase;
}

/* Surface Sections */
.section-block {
  padding-block: 56px;
}

.section-sand {
  background: var(--sand);
  border-block: var(--line);
}

.section-lilac {
  background: var(--lilac);
  border-block: var(--line);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.section-head h2 {
  font-size: clamp(26px, 2.8vw, 40px);
  line-height: 1.15;
  margin-bottom: 6px;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  max-width: 520px;
}

/* Feature Shortcuts Grid on Home */
.shortcut-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: var(--line);
  background: var(--paper);
  box-shadow: var(--shadow);
}

.shortcut-card {
  padding: 26px 22px;
  border-right: var(--line);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  cursor: pointer;
  text-align: left;
  background: var(--paper);
  transition: background 0.15s;
}

.shortcut-card:last-child {
  border-right: 0;
}

.shortcut-card:nth-child(2) {
  background: var(--lilac);
}

.shortcut-card:nth-child(3) {
  background: var(--sage);
}

.shortcut-card:nth-child(4) {
  background: var(--sand);
}

.shortcut-card:hover {
  background: var(--lime);
}

.shortcut-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.shortcut-icon {
  width: 44px;
  height: 44px;
  border: var(--line);
  background: var(--paper);
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-sm);
}

.shortcut-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--ink);
  stroke-width: 1.6;
  fill: none;
}

.shortcut-card h3 {
  font-size: 20px;
  margin-bottom: 6px;
}

.shortcut-card p {
  font-size: 14px;
  margin: 0;
  color: var(--ink);
}

/* Explorer & Filter Panel */
.explorer-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 32px;
  align-items: start;
  padding-block: 36px 64px;
}

.filter-panel {
  background: var(--sand);
  border: var(--line);
  box-shadow: var(--shadow);
  padding: 22px;
  position: sticky;
  top: 100px;
}

.filter-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: var(--line);
  padding-bottom: 12px;
  margin-bottom: 16px;
}

.filter-panel-head h3 {
  font-size: 17px;
  margin: 0;
}

.filter-reset {
  background: var(--paper);
  border: var(--line);
  padding: 4px 9px;
  font-family: Typewriter, serif;
  font-size: 11px;
  cursor: pointer;
}

.filter-group {
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid #22222233;
}

.filter-group:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: 0;
}

.filter-group-title {
  font-family: Typewriter, serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 10px;
  display: block;
}

.filter-options {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.filter-pill {
  background: var(--paper);
  border: var(--line);
  padding: 5px 10px;
  font-size: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.filter-pill.active {
  background: var(--green);
  color: var(--paper);
}

.search-toolbar {
  display: flex;
  gap: 12px;
  margin-bottom: 22px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
}

.search-input-wrap {
  flex: 1;
  min-width: 240px;
  position: relative;
}

.search-input-wrap input {
  width: 100%;
  padding: 12px 16px;
  background: var(--paper);
  border: var(--line);
  box-shadow: var(--shadow-sm);
  font-size: 15px;
}

.scope-tabs {
  display: flex;
  border: var(--line);
  background: var(--sand);
}

.scope-tab {
  border: 0;
  border-right: var(--line);
  background: transparent;
  padding: 10px 14px;
  font-family: Typewriter, serif;
  font-size: 12px;
  cursor: pointer;
}

.scope-tab:last-child {
  border-right: 0;
}

.scope-tab.active {
  background: var(--lime);
  font-weight: 600;
}

/* Plant Cards Grid (HMP Arched Card Style) */
.plants-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.plant-card {
  background: var(--paper);
  border: var(--line);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.14s, box-shadow 0.14s;
  cursor: pointer;
  position: relative;
}

.plant-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: var(--shadow-lg);
}

.plant-card-arch {
  height: 250px;
  margin: 14px 14px 0;
  border: var(--line);
  border-radius: 46% 46% 0 0;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.bg-lilac { background: var(--lilac); }
.bg-sand { background: var(--sand); }
.bg-sage { background: var(--sage); }
.bg-coral { background: #f5bfb0; }
.bg-lime { background: #e2df9b; }

.plant-card-arch img {
  width: 86%;
  height: 88%;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.monogram-study {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
}

.monogram-study svg {
  width: 68px;
  height: 68px;
  stroke: var(--ink);
  stroke-width: 1.4;
  fill: var(--paper);
  margin-bottom: 10px;
}

.monogram-study span {
  font-family: Typewriter, serif;
  font-size: 11px;
  background: var(--paper);
  border: 1px solid var(--ink);
  padding: 3px 8px;
}

.card-badge-top {
  position: absolute;
  top: 24px;
  right: 22px;
  background: var(--paper);
  border: var(--line);
  padding: 3px 8px;
  font-family: Typewriter, serif;
  font-size: 10px;
  z-index: 2;
}

.card-badge-top.book-badge {
  background: var(--lime);
}

.plant-card-body {
  padding: 16px 18px 18px;
}

.plant-card-body h3 {
  font-size: 22px;
  margin-bottom: 3px;
}

.plant-card-latin {
  font-size: 13px;
  font-style: italic;
  color: var(--muted);
  margin-bottom: 12px;
  display: block;
}

.plant-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  border-top: var(--line);
  padding-top: 12px;
}

.mini-tag {
  font-family: Typewriter, serif;
  font-size: 10px;
  padding: 3px 7px;
  border: 1px solid var(--ink);
  background: var(--sand);
}

.mini-tag.pet-ok {
  background: var(--sage);
}

/* Single Plant Full View (HMP Guide Layout) */
.plant-detail-view {
  padding-block: 28px 80px;
}

.back-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
  padding-bottom: 14px;
  border-bottom: var(--line);
  flex-wrap: wrap;
}

.plant-hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 44px;
  align-items: start;
  margin-bottom: 48px;
}

.plant-title-xl {
  font-size: clamp(36px, 4.3vw, 62px);
  line-height: 1.06;
  margin-bottom: 18px;
}

.meta-table {
  border-top: var(--line);
  margin-bottom: 22px;
}

.meta-row {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 16px;
  padding: 11px 0;
  border-bottom: var(--line);
  font-size: 14px;
}

.meta-label {
  font-family: Typewriter, serif;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.9px;
  color: var(--muted);
}

.thumbs-meter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.thumb-dot {
  width: 14px;
  height: 14px;
  border: var(--line);
  background: var(--paper);
  display: inline-block;
}

.thumb-dot.filled {
  background: var(--green);
}

.plant-about-box {
  background: var(--sand);
  border: var(--line);
  padding: 20px 22px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 22px;
}

.plant-about-box h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.plant-about-box p {
  margin: 0;
  font-size: 16px;
}

.plant-stage-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.plant-main-arch {
  height: 490px;
  border: var(--line);
  border-radius: 48% 48% 0 0;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  display: grid;
  place-items: center;
}

.plant-main-arch img {
  width: 88%;
  height: 88%;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
}

.gallery-thumb {
  border: var(--line);
  background: var(--paper);
  padding: 6px;
  cursor: pointer;
  height: 76px;
  display: grid;
  place-items: center;
}

.gallery-thumb.active {
  background: var(--lime);
  box-shadow: var(--shadow-sm);
}

.gallery-thumb img {
  max-height: 60px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

/* HMP "The Basics" 10-Card Grid */
.basics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 52px;
}

.basic-card {
  background: var(--paper);
  border: var(--line);
  box-shadow: var(--shadow-sm);
  padding: 22px 24px;
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 18px;
  align-items: start;
}

.basic-card.highlight-card {
  background: var(--lilac);
}

.basic-card.fact-card {
  background: var(--sage);
}

.basic-icon {
  width: 52px;
  height: 52px;
  border: var(--line);
  background: var(--sand);
  display: grid;
  place-items: center;
  box-shadow: 2px 2px 0 var(--ink);
}

.basic-icon svg {
  width: 26px;
  height: 26px;
  stroke: var(--ink);
  stroke-width: 1.6;
  fill: none;
}

.basic-meta {
  font-family: Typewriter, serif;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.9px;
  color: var(--green);
  margin-bottom: 4px;
}

.basic-card h3 {
  font-size: 20px;
  margin-bottom: 8px;
}

.basic-summary {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px dashed #22222255;
}

.basic-detail {
  font-size: 14.5px;
  margin: 0;
  color: var(--ink);
}

/* Beyond The Basics (6 Deep-Dive Sections) */
.beyond-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: var(--line);
  background: var(--paper);
  box-shadow: var(--shadow);
  margin-bottom: 52px;
}

.beyond-item {
  padding: 26px 24px;
  border-right: var(--line);
  border-bottom: var(--line);
}

.beyond-item:nth-child(3n) {
  border-right: 0;
}

.beyond-item:nth-child(n+4) {
  border-bottom: 0;
}

.beyond-num {
  font-family: Typewriter, serif;
  font-size: 11px;
  background: var(--lime);
  border: 1px solid var(--ink);
  padding: 2px 7px;
  display: inline-block;
  margin-bottom: 10px;
}

.beyond-item h3 {
  font-size: 21px;
  margin-bottom: 10px;
}

.beyond-item p {
  font-size: 14.5px;
  margin: 0;
}

/* Troubleshooting Cards (Symptom -> Cause -> Solution) */
.trouble-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.trouble-card {
  background: var(--paper);
  border: var(--line);
  box-shadow: var(--shadow);
  padding: 24px;
}

.trouble-q {
  font-size: 20px;
  line-height: 1.3;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: var(--line);
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.trouble-step {
  margin-bottom: 12px;
  font-size: 14.5px;
}

.trouble-step:last-child {
  margin-bottom: 0;
}

.trouble-tag {
  font-family: Typewriter, serif;
  font-size: 11px;
  text-transform: uppercase;
  padding: 2px 7px;
  border: 1px solid var(--ink);
  margin-right: 6px;
  display: inline-block;
}

.tag-symptom { background: var(--lilac); }
.tag-cause { background: var(--coral); }
.tag-solution { background: var(--lime); }

/* Guides / Manual da Casa Verde */
.guides-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.guide-card {
  background: var(--paper);
  border: var(--line);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  transition: transform 0.12s;
}

.guide-card:hover {
  transform: translate(-2px, -2px);
}

.guide-img-box {
  height: 210px;
  background: var(--sand);
  border-bottom: var(--line);
  padding: 16px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.guide-img-box img {
  max-height: 180px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.guide-body {
  padding: 20px;
}

.guide-body h3 {
  font-size: 21px;
  margin-bottom: 8px;
}

.guide-body p {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 16px;
}

/* Minha Casa Verde (Personal Collection & Soil Check Tracker) */
.my-plants-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.my-plant-card {
  background: var(--paper);
  border: var(--line);
  box-shadow: var(--shadow);
  padding: 20px;
}

.my-plant-top {
  display: flex;
  gap: 14px;
  align-items: center;
  border-bottom: var(--line);
  padding-bottom: 14px;
  margin-bottom: 14px;
}

.my-plant-thumb {
  width: 68px;
  height: 68px;
  border: var(--line);
  border-radius: 45% 45% 0 0;
  background: var(--lilac);
  display: grid;
  place-items: center;
  overflow: hidden;
  flex-shrink: 0;
}

.my-plant-thumb img {
  width: 85%;
  height: 85%;
  object-fit: contain;
  mix-blend-mode: multiply;
}

/* Modal / Paywall Dialog */
dialog {
  padding: 0;
  border: var(--line);
  background: var(--paper);
  box-shadow: var(--shadow-lg);
  width: min(760px, 94vw);
  max-height: 90vh;
}

dialog::backdrop {
  background: #114b43cc;
}

.dialog-head {
  position: sticky;
  top: 0;
  background: var(--lime);
  border-bottom: var(--line);
  padding: 14px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 5;
}

.dialog-body {
  padding: 28px;
}

/* Identificador com Camera (IA Gemini) */
.ident-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 32px;
  align-items: start;
}

.camera-box {
  background: var(--sand);
  border: var(--line);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.camera-viewport {
  width: 100%;
  aspect-ratio: 4/3;
  background: var(--paper);
  border: 2px dashed var(--ink);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 18px;
}

.camera-viewport img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
}

.camera-reticle {
  position: absolute;
  width: 70%;
  height: 70%;
  border: 2px solid var(--green);
  pointer-events: none;
  box-shadow: 0 0 0 9999px rgba(17, 75, 67, 0.12);
}

.camera-reticle::before, .camera-reticle::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  border-color: var(--green);
  border-style: solid;
}
.camera-reticle::before {
  top: -2px; left: -2px; border-width: 3px 0 0 3px;
}
.camera-reticle::after {
  bottom: -2px; right: -2px; border-width: 0 3px 3px 0;
}

.api-key-config {
  background: var(--paper);
  border: 1px solid var(--ink);
  padding: 14px;
  font-family: Typewriter, serif;
  font-size: 12px;
}

.api-key-config input {
  width: 100%;
  padding: 8px;
  font-family: inherit;
  font-size: 13px;
  border: 1px solid var(--ink);
  margin-top: 6px;
}

.ident-result-box {
  background: var(--paper);
  border: var(--line);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.scan-pulse {
  animation: scanAnim 1.6s ease-in-out infinite alternate;
}

@keyframes scanAnim {
  0% { transform: translateY(-40px); opacity: 0.3; }
  100% { transform: translateY(40px); opacity: 0.9; }
}

@media (max-width: 1024px) {
  .ident-grid {
    grid-template-columns: 1fr;
  }
}

/* Mobile Bottom Bar */
.mobile-tabbar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--paper);
  border-top: var(--line);
  z-index: 50;
  grid-template-columns: repeat(6, 1fr);
}

.mobile-tabbar button {
  background: none;
  border: 0;
  border-right: 1px solid #22222233;
  padding: 10px 4px;
  font-family: Typewriter, serif;
  font-size: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.mobile-tabbar button.active {
  background: var(--lime);
}

.mobile-tabbar svg {
  width: 18px;
  height: 18px;
  stroke: var(--ink);
  stroke-width: 1.6;
  fill: none;
}

@media (max-width: 1024px) {
  .wrap { width: calc(100% - 40px); }
  .hero-app, .plant-hero-grid, .explorer-layout { grid-template-columns: 1fr; }
  .filter-panel { position: static; }
  .shortcut-grid, .plants-grid, .guides-grid, .my-plants-grid, .beyond-grid { grid-template-columns: repeat(2, 1fr); }
  .shortcut-card { border-bottom: var(--line); }
}

@media (max-width: 720px) {
  .wrap { width: calc(100% - 28px); }
  .header { padding: 12px 16px; min-height: 68px; }
  .main-nav { display: none; }
  .mobile-tabbar { display: grid; }
  .shortcut-grid, .plants-grid, .basics-grid, .beyond-grid, .trouble-list, .guides-grid, .my-plants-grid {
    grid-template-columns: 1fr;
  }
  .hero-stage, .plant-main-arch { height: 360px; }
  .meta-row { grid-template-columns: 1fr; gap: 4px; }
  .top-banner { flex-direction: column; align-items: flex-start; padding: 8px 14px; }
}

