/* Garden Girl Tracker — light garden theme */

:root {
    --garden-cream: #faf7f2;
    --garden-mist: #f0f4ec;
    --garden-sage: #6b8f71;
    --garden-sage-dark: #4a6b50;
    --garden-sage-light: #e4efe6;
    --garden-rose: #c97b84;
    --garden-rose-light: #f5e8ea;
    --garden-leaf: #7ba05b;
    --garden-earth: #a67c52;
    --garden-soil: #3d4035;
    --garden-muted: #6b7280;
    --garden-border: #e5e7df;
    --garden-shadow: rgba(61, 64, 53, 0.08);
}

[x-cloak] { display: none !important; }

body {
    font-family: "Source Sans 3", system-ui, sans-serif;
}

h1, h2, h3, .brand-text {
    font-family: "DM Sans", system-ui, sans-serif;
}

code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.875em;
}

/* Brand */
.version-text {
    color: var(--garden-earth);
    font-weight: 600;
}

.brand-text {
    color: var(--garden-sage-dark);
    font-weight: 600;
}

.brand-text:hover {
    color: var(--garden-sage);
}

/* Subtle botanical backdrop */
.app-shell {
    background-color: var(--garden-cream);
    background-image:
        radial-gradient(ellipse 80% 50% at 50% -10%, rgba(107, 143, 113, 0.12), transparent),
        radial-gradient(ellipse 60% 40% at 100% 100%, rgba(201, 123, 132, 0.08), transparent);
}

/* Cards & panels */
.app-card {
    background: #fff;
    border: 1px solid var(--garden-border);
    border-radius: 0.875rem;
    box-shadow: 0 1px 3px var(--garden-shadow);
}

.app-card-hover {
    transition: background-color 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.app-card-hover:hover {
    background: var(--garden-sage-light);
    border-color: rgba(107, 143, 113, 0.35);
    box-shadow: 0 4px 14px rgba(107, 143, 113, 0.12);
}

.dashboard-stat-card-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
}

.dashboard-stat-card-body::after {
    content: "";
    flex: 1 1 auto;
    min-height: 1.25rem;
}

.dashboard-stat-card-footer {
    flex-shrink: 0;
    margin-top: auto;
    padding-top: 1.125rem;
    border-top: 1px solid var(--garden-border);
}

.group:hover .dashboard-stat-card-footer {
    border-top-color: rgba(107, 143, 113, 0.25);
}

/* Forms */
.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--garden-soil);
}

.form-input {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    border-radius: 0.5rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.5rem 0.75rem;
    color: var(--garden-soil);
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.form-input::placeholder {
    color: #a8a29e;
}

.form-input:focus {
    outline: none;
    border-color: var(--garden-sage);
    box-shadow: 0 0 0 3px rgba(107, 143, 113, 0.18);
}

.form-select {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    border-radius: 0.5rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.5rem 0.75rem;
    color: var(--garden-soil);
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.form-select:focus {
    outline: none;
    border-color: var(--garden-sage);
    box-shadow: 0 0 0 3px rgba(107, 143, 113, 0.18);
}

.form-textarea {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    min-height: 6rem;
    border-radius: 0.5rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.5rem 0.75rem;
    color: var(--garden-soil);
    resize: vertical;
    transition: border-color 150ms ease, box-shadow 150ms ease;
}

.form-textarea:focus {
    outline: none;
    border-color: var(--garden-sage);
    box-shadow: 0 0 0 3px rgba(107, 143, 113, 0.18);
}

.tag-pill {
    display: inline-flex;
    align-items: center;
    border-radius: 9999px;
    background: var(--garden-sage-light);
    padding: 0.125rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--garden-sage-dark);
}

.table-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.375rem;
}

.table-actions form {
    display: block;
    margin: 0;
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    background: var(--garden-sage);
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #fff;
    transition: background-color 150ms ease;
}

.btn-primary:hover {
    background: var(--garden-sage-dark);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--garden-soil);
    transition: background-color 150ms ease, border-color 150ms ease;
}

.btn-secondary:hover {
    background: var(--garden-mist);
    border-color: rgba(107, 143, 113, 0.35);
}

.btn-visual-layout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    border: 1px solid #67e8f9;
    background: #a5f3fc;
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #0e7490;
    transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}

.btn-visual-layout:hover {
    background: #67e8f9;
    border-color: #22d3ee;
    color: #155e75;
}

.btn-plant-crop {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    border: 1px solid #fde047;
    background: #fef9c3;
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #854d0e;
    transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}

.btn-plant-crop:hover {
    background: #fef08a;
    border-color: #facc15;
    color: #713f12;
}

.btn-harvest-crop {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    border: 1px solid #fb923c;
    background: #fdba74;
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #9a3412;
    transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}

.btn-harvest-crop:hover {
    background: #fb923c;
    border-color: #f97316;
    color: #7c2d12;
}

/* Avatar badge */
.avatar-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    background: var(--garden-rose-light);
    color: var(--garden-rose);
    font-weight: 600;
    box-shadow: inset 0 0 0 1px rgba(201, 123, 132, 0.25);
}

/* Main navigation */
.nav-pill-group {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.4rem 0.35rem;
    border-radius: 0.875rem;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--garden-border);
    box-shadow: 0 1px 2px var(--garden-shadow);
    overflow: visible;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: 0.625rem;
    padding: 0.5rem 0.875rem;
    font-size: 0.8125rem;
    font-weight: 500;
    line-height: 1.25rem;
    color: var(--garden-muted);
    border: 1px solid transparent;
    transition: color 150ms ease, background-color 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}

.nav-link:hover:not(.nav-link-active) {
    color: var(--garden-sage-dark);
    background: var(--garden-sage-light);
}

.nav-link-active,
.nav-link-active:hover {
    color: var(--garden-sage-dark);
    background: var(--garden-sage-light);
    border-color: rgba(107, 143, 113, 0.35);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.nav-link-active svg {
    color: var(--garden-sage);
}

.nav-link-mobile {
    width: 100%;
    justify-content: flex-start;
    padding: 0.75rem 0.875rem;
}

.nav-dropdown {
    overflow: hidden;
    border-radius: 0.875rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.375rem;
    box-shadow: 0 12px 32px var(--garden-shadow);
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    border-radius: 0.625rem;
    padding: 0.625rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--garden-soil);
    transition: background-color 150ms ease, color 150ms ease;
}

.nav-dropdown-item:hover {
    background: var(--garden-mist);
    color: var(--garden-sage-dark);
}

.nav-dropdown-item-active {
    background: var(--garden-sage-light);
    color: var(--garden-sage-dark);
}

/* Main nav — mobile drawer (Classic + New View) */
body.ggt-nav-open {
    overflow: hidden;
}

.ggt-nav-icon-slot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.ggt-nav-link-label {
    white-space: nowrap;
}

.ggt-nav-menu-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.65rem;
    padding: 0.5rem;
    color: var(--garden-muted);
    border: 1px solid var(--garden-border);
    background: #fff;
    transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease;
}

.ggt-nav-menu-btn:hover {
    color: var(--garden-sage-dark);
    background: var(--garden-mist);
    border-color: rgba(107, 143, 113, 0.25);
}

.ggt-nav-mobile-shell {
    position: relative;
}

.ggt-nav-mobile-backdrop {
    position: fixed;
    inset: 0;
    top: 3.5rem;
    z-index: 45;
    background: rgba(61, 64, 53, 0.35);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

@media (min-width: 640px) {
    .ggt-nav-mobile-backdrop {
        top: 4rem;
    }
}

.ggt-nav-mobile-drawer {
    position: fixed;
    top: 3.5rem;
    right: 0;
    bottom: 0;
    z-index: 50;
    display: flex;
    flex-direction: column;
    width: min(100%, 22rem);
    border-left: 1px solid var(--garden-border);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: -12px 0 40px rgba(61, 64, 53, 0.12);
}

@media (min-width: 640px) {
    .ggt-nav-mobile-drawer {
        top: 4rem;
    }
}

.ggt-nav-mobile-drawer-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 1rem 1rem 0.75rem;
    border-bottom: 1px solid var(--garden-border);
}

.ggt-nav-mobile-drawer-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--garden-soil);
}

.ggt-nav-mobile-drawer-sub {
    margin-top: 0.15rem;
    font-size: 0.75rem;
    color: var(--garden-muted);
}

.ggt-nav-mobile-drawer-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 0.85rem 1rem 1.25rem;
}

.ggt-nav-mobile-view-toggle {
    margin-bottom: 1rem;
}

.ggt-nav-mobile-section + .ggt-nav-mobile-section {
    margin-top: 1.15rem;
}

.ggt-nav-mobile-section-label {
    margin-bottom: 0.45rem;
    padding-inline: 0.15rem;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #a8a29e;
}

.ggt-nav-mobile-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.ggt-nav-mobile-link {
    width: 100%;
    justify-content: flex-start;
    padding: 0.72rem 0.85rem;
}

.ggt-nav-mobile-arrow {
    margin-left: auto;
    width: 1rem;
    height: 1rem;
    color: #d6d3d1;
    flex-shrink: 0;
}

.ggt-nav-chevron-wrap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.ggt-nav-chevron.is-open,
.ggt-nav-chevron-wrap svg.rotate-180 {
    transform: rotate(180deg);
}

.ggt-nav-chevron,
.ggt-nav-chevron-wrap svg {
    transition: transform 160ms ease;
}

.ggt-nav-lucide,
.ggt-nav-icon-slot svg {
    width: 1rem;
    height: 1rem;
}

/* Plugin status badges */
.badge-enabled {
    background: var(--garden-sage-light);
    color: var(--garden-sage-dark);
}

.badge-disabled {
    background: #f5f5f4;
    color: #78716c;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

/* Loading overlay */
.loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(250, 247, 242, 0.82);
    backdrop-filter: blur(4px);
}

.loading-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 2rem 2.5rem;
    box-shadow: 0 12px 40px var(--garden-shadow);
    border-radius: 0.875rem;
}

.loading-spinner {
    width: 2.5rem;
    height: 2.5rem;
    border: 3px solid var(--garden-sage-light);
    border-top-color: var(--garden-sage);
    border-radius: 9999px;
    animation: loading-spin 0.75s linear infinite;
}

.loading-text {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--garden-soil);
}

@keyframes loading-spin {
    to {
        transform: rotate(360deg);
    }
}

/* App section tabs (forms and detail views) */
.app-section-tabs,
.plot-detail-tabs {
    display: flex;
    flex-direction: column;
    position: relative;
}

.app-section-tab-input,
.plot-detail-tab-input {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.app-section-tablist,
.plot-detail-tablist {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
    border-bottom: 1px solid var(--garden-border);
    background: linear-gradient(180deg, #fff 0%, var(--garden-mist) 100%);
    padding: 0.75rem 1rem 0;
}

.app-section-tab,
.plot-detail-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: -1px;
    border: 1px solid transparent;
    border-bottom: none;
    border-radius: 0.625rem 0.625rem 0 0;
    background: transparent;
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--garden-muted);
    cursor: pointer;
    transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.app-section-tab:hover,
.plot-detail-tab:hover {
    color: var(--garden-sage-dark);
    background: rgba(255, 255, 255, 0.72);
}

.app-section-tab-icon,
.plot-detail-tab-icon {
    display: inline-flex;
    height: 1.75rem;
    width: 1.75rem;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    background: var(--garden-sage-light);
    color: var(--garden-sage-dark);
    transition: background-color 150ms ease, color 150ms ease;
}

.app-section-tab-text {
    line-height: 1.2;
}

.app-section-tab-count,
.plot-detail-tab-count {
    display: inline-flex;
    min-width: 1.25rem;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    background: rgba(107, 143, 113, 0.14);
    padding: 0.125rem 0.4375rem;
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--garden-sage-dark);
}

.app-section-tab-count-alert {
    background: #dc2626;
    color: #fff;
}

.nav-badge {
    display: inline-flex;
    min-width: 1.125rem;
    height: 1.125rem;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    padding: 0 0.3125rem;
    font-size: 0.625rem;
    font-weight: 700;
    line-height: 1;
}

.nav-badge-alert {
    background: #dc2626;
    color: #fff;
}

.nav-badge-dot {
    min-width: 0.5rem;
    width: 0.5rem;
    height: 0.5rem;
    padding: 0;
}

.app-section-tab-count-dot {
    min-width: 0.5rem;
    width: 0.5rem;
    height: 0.5rem;
    padding: 0;
    font-size: 0;
    line-height: 0;
}

.app-section-panel,
.plot-detail-panel {
    display: none;
    padding: 1.5rem;
}

.app-section-panel-flex {
    flex-direction: column;
    gap: 1rem;
}

#plot-tab-beds:checked ~ .plot-detail-tablist label[for="plot-tab-beds"] .plot-detail-tab-count,
#plot-detail-tab-beds:checked ~ .plot-detail-tablist label[for="plot-detail-tab-beds"] .plot-detail-tab-count {
    background: var(--garden-sage-light);
}

#plot-tab-location:checked ~ .plot-detail-tablist label[for="plot-tab-location"],
#plot-tab-beds:checked ~ .plot-detail-tablist label[for="plot-tab-beds"] {
    border-color: var(--garden-border);
    background: #fff;
    color: var(--garden-soil);
    box-shadow: 0 -1px 0 #fff;
}

#plot-tab-location:checked ~ .plot-detail-tablist label[for="plot-tab-location"] .plot-detail-tab-icon,
#plot-tab-beds:checked ~ .plot-detail-tablist label[for="plot-tab-beds"] .plot-detail-tab-icon {
    background: var(--garden-sage);
    color: #fff;
}

#plot-tab-location:checked ~ #plot-panel-location {
    display: block;
}

#plot-tab-beds:checked ~ #plot-panel-beds {
    display: flex;
}

#plot-detail-panel-beds.plot-detail-panel-beds,
.plot-detail-panel-beds {
    flex-direction: column;
    gap: 1rem;
    max-height: min(32rem, calc(100vh - 13.5rem));
    min-height: 12rem;
    overflow: hidden;
}

/* Plot detail beds tab — explicit scroll viewport (avoids flex collapse) */
#plot-detail-panel-beds.plot-detail-panel-beds {
    max-height: none;
    min-height: 0;
}

#plot-detail-panel-beds .plot-detail-beds-root {
    min-height: 0;
}

#plot-detail-panel-beds .plot-detail-beds-scroll,
#plot-detail-panel-beds .plots-v2-bed-list-scroll {
    flex: none;
    height: clamp(16rem, calc(100vh - 20rem), 28rem);
    max-height: clamp(16rem, calc(100vh - 20rem), 28rem);
    min-height: 16rem;
    overflow-x: auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 0.75rem;
}

.plot-detail-beds-scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow-x: auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 0.75rem;
}

[data-garden-beds-page="list"] .garden-beds-v2-scroll {
    flex: none;
    height: clamp(16rem, calc(100vh - 18rem), 32rem);
    max-height: clamp(16rem, calc(100vh - 18rem), 32rem);
    min-height: 16rem;
    overflow-x: auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

/* Plot map (Leaflet) */
.plot-map {
    height: 20rem;
    width: 100%;
    border-radius: 0.75rem;
    border: 1px solid var(--garden-border);
    overflow: hidden;
    z-index: 0;
}

.plot-map .leaflet-control-attribution {
    font-size: 0.625rem;
}

.plot-country-flag {
    display: inline-block;
    flex-shrink: 0;
    border-radius: 2px;
    box-shadow: 0 0 0 1px rgb(28 25 23 / 0.12);
    object-fit: cover;
    vertical-align: middle;
}

.plot-country-flag-card {
    width: 1.75rem;
    height: auto;
    box-shadow: none;
    border-radius: 0.25rem;
}

.plot-country-flag-inline {
    margin-top: 0.125rem;
}

.plot-country-flag-title {
    margin-top: 0.125rem;
}

.plot-hardiness-range {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.875rem;
    padding: 0.5rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.8125rem;
    color: var(--garden-soil);
    background: rgba(255, 255, 255, 0.65);
    border: 1px solid rgba(107, 143, 113, 0.15);
}

.plot-hardiness-range-icon {
    font-size: 0.9375rem;
    line-height: 1;
}

.plot-hardiness-range strong {
    font-weight: 600;
    color: var(--garden-sage-dark);
}

.plot-hardiness {
    position: relative;
    margin-top: 1rem;
    overflow: hidden;
    border-radius: 1rem;
    border: 1px solid rgba(107, 143, 113, 0.22);
    background: linear-gradient(
        145deg,
        rgba(250, 247, 242, 0.98) 0%,
        rgba(240, 244, 236, 0.95) 50%,
        rgba(245, 232, 234, 0.4) 100%
    );
    box-shadow:
        0 4px 20px rgba(107, 143, 113, 0.08),
        0 1px 3px rgba(61, 64, 53, 0.04);
}

.plot-hardiness-glow {
    position: absolute;
    top: -3rem;
    right: -2rem;
    width: 9rem;
    height: 9rem;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(201, 123, 132, 0.14) 0%, transparent 68%);
    pointer-events: none;
}

.plot-hardiness-inner {
    position: relative;
    padding: 1.25rem;
}

.plot-hardiness-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.plot-hardiness-intro {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    min-width: 0;
}

.plot-hardiness-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.875rem;
    font-size: 1.25rem;
    line-height: 1;
    background: linear-gradient(135deg, var(--garden-sage-light) 0%, rgba(255, 255, 255, 0.9) 100%);
    box-shadow: inset 0 0 0 1px rgba(107, 143, 113, 0.2);
}

.plot-hardiness-eyebrow {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--garden-sage-dark);
}

.plot-hardiness-title {
    margin-top: 0.125rem;
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--garden-soil);
}

.plot-hardiness-subtitle {
    margin-top: 0.125rem;
    font-size: 0.8125rem;
    line-height: 1.4;
    color: var(--garden-muted);
}

.plot-hardiness-zone-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 1rem;
    background: linear-gradient(145deg, var(--garden-sage) 0%, var(--garden-sage-dark) 100%);
    box-shadow:
        0 4px 12px rgba(74, 107, 80, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.plot-hardiness-zone-letter {
    font-size: 0.875rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    color: #fff;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
}

.plot-hardiness-tips-section {
    margin-top: 1.125rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(107, 143, 113, 0.14);
}

.plot-hardiness-tips-heading {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--garden-sage-dark);
}

.plot-hardiness-tips-lede {
    margin-top: 0.25rem;
    font-size: 0.75rem;
    line-height: 1.45;
    color: var(--garden-muted);
    font-style: italic;
}

.plot-hardiness-tips {
    margin-top: 0.625rem;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 0.5rem;
}

.plot-hardiness-tip {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem 0.875rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 1px 2px rgba(61, 64, 53, 0.04);
}

.plot-hardiness-tip-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 1.75rem;
    height: 1.75rem;
    font-size: 0.9375rem;
    line-height: 1;
    border-radius: 0.5rem;
    background: var(--garden-sage-light);
    box-shadow: inset 0 0 0 1px rgba(107, 143, 113, 0.12);
}

.plot-hardiness-tip-text {
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--garden-soil);
}

.plot-hardiness-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    margin-top: 1rem;
    padding-top: 0.875rem;
    border-top: 1px solid rgba(107, 143, 113, 0.12);
    font-size: 0.75rem;
    color: var(--garden-muted);
}

.plot-hardiness-footer a {
    color: var(--garden-sage-dark);
    font-weight: 600;
    text-decoration: none;
}

.plot-hardiness-footer a:hover {
    text-decoration: underline;
}

.plot-hardiness-footer-dot {
    opacity: 0.5;
}

/* Legacy aliases — admin tester may reference these */
.plot-hardiness-source {
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--garden-muted);
}

.plot-hardiness-source a {
    color: var(--garden-sage-dark);
    font-weight: 600;
    text-decoration: none;
}

.plot-hardiness-badge {
    flex-shrink: 0;
    padding: 0.375rem 0.75rem;
    border-radius: 9999px;
    background: var(--garden-sage-light);
    color: var(--garden-sage-dark);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.hardiness-test-result .hardiness-test-zone {
    margin-top: 0;
}

.hardiness-test-result .plot-hardiness {
    margin-top: 0;
}

/* Address autocomplete (Photon / OSM) and plant picker */
.address-autocomplete,
.plant-autocomplete {
    position: relative;
}

.address-autocomplete-menu,
.plant-autocomplete-menu {
    position: absolute;
    z-index: 30;
    margin-top: 0.25rem;
    width: 100%;
    max-height: 16rem;
    overflow-y: auto;
    list-style: none;
    border-radius: 0.75rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.375rem;
    box-shadow: 0 12px 32px var(--garden-shadow);
}

.address-autocomplete-item,
.address-autocomplete-status,
.plant-autocomplete-item,
.plant-autocomplete-status {
    border-radius: 0.5rem;
    padding: 0.625rem 0.75rem;
    font-size: 0.875rem;
    line-height: 1.35;
}

.address-autocomplete-item,
.plant-autocomplete-item {
    cursor: pointer;
    color: var(--garden-soil);
    transition: background-color 150ms ease;
}

.plant-autocomplete-item {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.plant-autocomplete-name {
    font-weight: 500;
}

.plant-autocomplete-detail {
    font-size: 0.8125rem;
    font-style: italic;
    color: var(--garden-muted);
}

.address-autocomplete-item:hover,
.address-autocomplete-item-active,
.plant-autocomplete-item:hover,
.plant-autocomplete-item-active {
    background: var(--garden-sage-light);
    color: var(--garden-sage-dark);
}

.plant-autocomplete-item-active .plant-autocomplete-detail,
.plant-autocomplete-item:hover .plant-autocomplete-detail {
    color: var(--garden-sage-dark);
}

.address-autocomplete-status,
.plant-autocomplete-status {
    color: var(--garden-muted);
}

/* Plant inventory row highlight (request acknowledgment deep link) */
@keyframes plant-row-flash {
    0%,
    100% {
        background-color: transparent;
    }

    20%,
    80% {
        background-color: rgba(107, 143, 113, 0.28);
    }

    50% {
        background-color: rgba(107, 143, 113, 0.48);
    }
}

.plant-row-highlight-flash {
    animation: plant-row-flash 2.8s ease-in-out;
    outline: 2px solid var(--garden-sage);
    outline-offset: -2px;
}

/* Plot context highlight (garden bed form) */
.plot-context-highlight {
    display: inline-flex;
    align-items: center;
    gap: 0.875rem;
    max-width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 0.875rem;
    border: 1px solid rgba(107, 143, 113, 0.35);
    background: linear-gradient(135deg, var(--garden-sage-light) 0%, rgba(240, 244, 236, 0.95) 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
    transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.plot-context-highlight:hover {
    border-color: rgba(107, 143, 113, 0.55);
    box-shadow: 0 4px 14px rgba(107, 143, 113, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.plot-context-highlight-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.625rem;
    background: rgba(255, 255, 255, 0.72);
    color: var(--garden-sage-dark);
    box-shadow: inset 0 0 0 1px rgba(107, 143, 113, 0.18);
}

.plot-context-highlight-body {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
    min-width: 0;
}

.plot-context-highlight-label {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--garden-sage-dark);
}

.plot-context-highlight-name {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--garden-soil);
}

.plot-context-highlight-inline {
    margin-top: 0;
    padding: 0.625rem 0.875rem;
    max-width: min(100%, 16rem);
}

.plot-context-highlight-inline .plot-context-highlight-icon {
    width: 2rem;
    height: 2rem;
}

.plot-context-highlight-inline .plot-context-highlight-name {
    font-size: 0.9375rem;
}

.title-separator {
    width: 1px;
    flex-shrink: 0;
    background: linear-gradient(
        180deg,
        rgba(107, 143, 113, 0) 0%,
        rgba(107, 143, 113, 0.45) 18%,
        rgba(107, 143, 113, 0.45) 82%,
        rgba(107, 143, 113, 0) 100%
    );
}

.title-separator-sm {
    height: 1.75rem;
}

.title-separator-stretch {
    align-self: stretch;
    min-height: 2.75rem;
}

.title-separator-lg {
    height: 2rem;
}

/* Dashboard — Did you know */
.did-you-know {
    background: linear-gradient(135deg, rgba(240, 244, 236, 0.95) 0%, rgba(255, 255, 255, 0.98) 100%);
    border-color: rgba(107, 143, 113, 0.22);
}

.did-you-know-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    background: var(--garden-sage-light);
    color: var(--garden-sage-dark);
    box-shadow: inset 0 0 0 1px rgba(107, 143, 113, 0.18);
}

.did-you-know-label {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--garden-sage-dark);
}

.did-you-know-text {
    margin-top: 0.375rem;
    font-size: 0.9375rem;
    line-height: 1.55;
    color: var(--garden-soil);
}

.did-you-know-nav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 0.5rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    color: var(--garden-muted);
    transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease;
}

.did-you-know-nav:hover {
    background: var(--garden-sage-light);
    border-color: rgba(107, 143, 113, 0.35);
    color: var(--garden-sage-dark);
}

/* Plot weather widget (Open-Meteo) */
.plot-weather {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    min-height: 12rem;
}

.plot-weather-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.plot-weather-header h2 {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--garden-muted);
}

.plot-weather-source {
    margin-top: 0.25rem;
    font-size: 0.6875rem;
    color: #a8a29e;
}

.plot-weather-unit-toggle {
    display: inline-flex;
    flex-shrink: 0;
    border-radius: 0.625rem;
    border: 1px solid var(--garden-border);
    background: var(--garden-mist);
    padding: 0.125rem;
}

.plot-weather-unit-btn {
    min-width: 2.25rem;
    border: none;
    border-radius: 0.5rem;
    background: transparent;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--garden-muted);
    cursor: pointer;
    transition: background-color 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.plot-weather-unit-btn:hover {
    color: var(--garden-soil);
}

.plot-weather-unit-btn.is-active {
    background: #fff;
    color: var(--garden-sage-dark);
    box-shadow: 0 1px 2px rgba(61, 46, 36, 0.08);
}

.plot-weather-body {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.plot-weather-body-is-loading {
    min-height: 10rem;
}

.plot-weather-loading,
.plot-weather-error {
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 2rem 1rem;
    text-align: center;
    color: var(--garden-muted);
}

.plot-weather-loading p,
.plot-weather-error p {
    font-size: 0.875rem;
    line-height: 1.5;
}

.plot-weather-spinner {
    width: 2rem;
    height: 2rem;
    border: 2px solid var(--garden-border);
    border-top-color: var(--garden-sage);
    border-radius: 9999px;
    animation: loading-spin 0.8s linear infinite;
}

.plot-weather-error-icon {
    font-size: 1.75rem;
}

.plot-weather-current {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.plot-weather-current-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1rem;
    background: linear-gradient(135deg, var(--garden-mist) 0%, var(--garden-sage-light) 100%);
    font-size: 1.75rem;
}

.plot-weather-temp {
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1;
    color: var(--garden-soil);
    font-variant-numeric: tabular-nums;
}

.plot-weather-desc {
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: var(--garden-muted);
}

.plot-weather-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    padding-top: 0.25rem;
    border-top: 1px solid var(--garden-border);
}

.plot-weather-stats div {
    border-radius: 0.75rem;
    background: var(--garden-mist);
    padding: 0.625rem 0.75rem;
}

.plot-weather-stats dt {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #a8a29e;
}

.plot-weather-stats dd {
    margin-top: 0.125rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--garden-soil);
    font-variant-numeric: tabular-nums;
}

.plot-weather-forecast h3 {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #a8a29e;
}

.plot-weather-days {
    margin-top: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    list-style: none;
}

.plot-weather-day {
    display: grid;
    grid-template-columns: 4.5rem 2rem 1fr auto;
    align-items: center;
    gap: 0.5rem;
    border-radius: 0.625rem;
    background: #fff;
    border: 1px solid var(--garden-border);
    padding: 0.5rem 0.625rem;
    font-size: 0.8125rem;
}

.plot-weather-day-name {
    font-weight: 600;
    color: var(--garden-soil);
}

.plot-weather-day-icon {
    font-size: 1.125rem;
    text-align: center;
}

.plot-weather-day-label {
    color: var(--garden-muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.plot-weather-day-temps {
    font-weight: 600;
    color: var(--garden-soil);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.plot-weather-prompt {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
}

.plot-weather-prompt-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    background: var(--garden-mist);
    font-size: 1.25rem;
}

.plot-weather-prompt h2 {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--garden-muted);
}

.plot-weather-prompt p {
    font-size: 0.875rem;
    line-height: 1.6;
    color: var(--garden-muted);
}

@media (max-width: 640px) {
    .plot-weather-day {
        grid-template-columns: 4rem 1.75rem 1fr auto;
        font-size: 0.75rem;
    }
}

/* Visual plot layout editor */
.plot-layout-page {
    max-width: none;
}

.plot-layout-workspace {
    display: grid;
    gap: 1rem;
    min-height: 32rem;
}

@media (min-width: 1024px) {
    .plot-layout-workspace {
        grid-template-columns: 16rem minmax(0, 1fr);
        min-height: calc(100vh - 16rem);
    }
}

.plot-layout-tray {
    display: flex;
    flex-direction: column;
    min-height: 12rem;
    max-height: calc(100vh - 14rem);
    overflow: hidden;
}

.plot-layout-tray-header {
    padding: 1rem 1rem 0.75rem;
    border-bottom: 1px solid var(--garden-border);
}

.plot-layout-tray-header h2 {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--garden-muted);
}

.plot-layout-tray-header p {
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: #a8a29e;
}

.plot-layout-tray-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.plot-layout-tray.is-drop-target {
    outline: 2px dashed var(--garden-sage);
    outline-offset: -4px;
    background: var(--garden-sage-light);
}

.plot-layout-tray-item {
    border: 1px solid var(--garden-border);
    border-radius: 0.75rem;
    background: #fff;
    padding: 0.625rem 0.75rem;
    cursor: grab;
    transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.plot-layout-tray-item:hover {
    border-color: rgba(107, 143, 113, 0.45);
    box-shadow: 0 4px 12px var(--garden-shadow);
}

.plot-layout-tray-item:active {
    cursor: grabbing;
}

.plot-layout-tray-item.is-inactive {
    border-style: dashed;
    border-color: var(--garden-rose);
    background: var(--garden-rose-light);
}

.plot-layout-tray-item.is-inactive .plot-layout-tray-item-name {
    color: #9f4d56;
}

.plot-layout-tray-item-inactive {
    margin-top: 0.125rem;
    font-size: 0.6875rem;
    font-weight: 500;
    color: var(--garden-rose);
}

.plot-layout-tray-item-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--garden-soil);
}

.plot-layout-tray-item-meta {
    margin-top: 0.125rem;
    font-size: 0.6875rem;
    color: var(--garden-muted);
}

.plot-layout-tray-empty {
    padding: 1rem;
    font-size: 0.8125rem;
    text-align: center;
    color: var(--garden-muted);
}

.plot-layout-canvas-panel {
    display: flex;
    flex-direction: column;
    min-height: 24rem;
    overflow: hidden;
}

.plot-layout-canvas-scroll {
    flex: 1;
    overflow: auto;
    padding: 1rem;
    background: linear-gradient(180deg, #f8faf5 0%, #eef3e8 100%);
}

.plot-layout-canvas {
    position: relative;
    margin: 0 auto;
    border: 2px solid #94a3b8;
    border-radius: 0.25rem;
    background-color: #dce8d0;
    background-image:
        linear-gradient(rgba(107, 143, 113, 0.12) 1px, transparent 1px),
        linear-gradient(90deg, rgba(107, 143, 113, 0.12) 1px, transparent 1px);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35), 0 8px 24px var(--garden-shadow);
    touch-action: none;
    user-select: none;
}

.plot-layout-canvas.is-drop-target {
    outline: 3px solid var(--garden-sage);
    outline-offset: 2px;
}

.plot-layout-marquee {
    position: absolute;
    z-index: 40;
    border: 1px dashed var(--garden-sage-dark);
    background: rgba(107, 143, 113, 0.15);
    pointer-events: none;
}

.plot-layout-building,
.plot-layout-bed {
    position: absolute;
    top: 0;
    left: 0;
    box-sizing: border-box;
    cursor: grab;
    transform-origin: 0 0;
}

.plot-layout-building.is-selected,
.plot-layout-bed.is-selected {
    outline: 2px solid var(--garden-sage-dark);
    outline-offset: 2px;
    z-index: 20;
}

.plot-layout-building.is-dragging,
.plot-layout-bed.is-dragging {
    cursor: grabbing;
    z-index: 30;
    opacity: 0.92;
}

.plot-layout-building {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #64748b;
    border-radius: 0.25rem;
    background: linear-gradient(145deg, #e2e8f0 0%, #cbd5e1 100%);
    color: #475569;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.plot-layout-building-label {
    pointer-events: none;
}

.plot-layout-bed {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--garden-sage-dark);
    border-radius: 0.25rem;
    background: rgba(228, 239, 230, 0.92);
    color: var(--garden-soil);
    font-size: 0.6875rem;
    font-weight: 600;
    text-align: center;
    padding: 0.25rem;
    line-height: 1.2;
}

.plot-layout-bed.is-round {
    border-radius: 9999px;
    background: rgba(228, 239, 230, 0.95);
}

.plot-layout-bed.is-inactive {
    flex-direction: column;
    gap: 0.125rem;
    border-color: var(--garden-rose);
    border-style: dashed;
    background: rgba(245, 232, 234, 0.95);
    color: #9f4d56;
}

.plot-layout-bed.is-round.is-inactive {
    background: rgba(245, 232, 234, 0.97);
}

.plot-layout-bed-inactive-label {
    pointer-events: none;
    font-size: 0.5625rem;
    font-weight: 500;
    color: var(--garden-rose);
    line-height: 1;
}

.plot-layout-bed-crops {
    pointer-events: none;
    font-size: 0.5625rem;
    font-weight: 500;
    color: var(--garden-leaf);
    line-height: 1.2;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.plot-layout-tray-item-crops {
    margin-top: 0.125rem;
    font-size: 0.6875rem;
    font-weight: 500;
    color: var(--garden-leaf);
}

.plot-layout-hover-caption {
    position: fixed;
    z-index: 60;
    max-width: min(18rem, calc(100vw - 1.5rem));
    border-radius: 0.625rem;
    border: 1px solid var(--garden-border);
    background: rgba(255, 255, 255, 0.98);
    padding: 0.625rem 0.75rem;
    box-shadow: 0 10px 24px rgba(28, 25, 23, 0.12);
    pointer-events: none;
}

.plot-layout-hover-caption-title {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--garden-soil);
}

.plot-layout-hover-caption-list {
    margin: 0.375rem 0 0;
    padding: 0;
    list-style: none;
}

.plot-layout-hover-caption-list li {
    margin-top: 0.25rem;
    font-size: 0.75rem;
    color: var(--garden-soil);
}

.plot-layout-hover-caption-status {
    font-weight: 600;
    color: var(--garden-leaf);
}

.plot-layout-hover-caption-empty {
    margin-top: 0.375rem;
    font-size: 0.75rem;
    color: var(--garden-muted);
}

.plot-layout-hover-caption-season {
    margin-top: 0.5rem;
    padding-top: 0.375rem;
    border-top: 1px solid var(--garden-border);
    font-size: 0.6875rem;
    font-weight: 500;
    color: var(--garden-muted);
}

.batch-status-pill {
    display: inline-flex;
    border-radius: 9999px;
    padding: 0.125rem 0.5rem;
    font-size: 0.6875rem;
    font-weight: 600;
}

.batch-status-planned {
    background: #eef2ff;
    color: #4338ca;
}

.batch-status-seedling {
    background: #ecfccb;
    color: #3f6212;
}

.batch-status-growing {
    background: var(--garden-sage-light);
    color: var(--garden-sage-dark);
}

.batch-status-producing {
    background: #fef3c7;
    color: #b45309;
}

.batch-status-harvested {
    background: #ffedd5;
    color: #c2410c;
}

.batch-status-cleared {
    background: #f5f5f4;
    color: #78716c;
}

.star-rating-display,
.star-rating-picker {
    display: inline-flex;
    align-items: center;
    gap: 0.125rem;
}

.star-rating-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.625rem;
}

.star-rating-score {
    min-width: 2.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--garden-soil);
}

.star-rating-clear {
    border: none;
    background: transparent;
    padding: 0;
    font-size: 0.75rem;
    font-weight: 500;
    color: #78716c;
    cursor: pointer;
}

.star-rating-clear:hover {
    color: var(--garden-soil);
}

.star-rating-star {
    line-height: 1;
}

.star-rating-star-btn {
    border: none;
    background: transparent;
    padding: 0.125rem;
    font-size: 1.375rem;
    line-height: 1;
    cursor: pointer;
    transition: transform 0.1s ease, color 0.1s ease, -webkit-text-stroke 0.1s ease;
}

.star-rating-star-btn:hover {
    transform: scale(1.08);
}

.star-rating-input .star-rating-star-btn.star-rating-star-empty {
    color: #ffffff;
    -webkit-text-stroke: 1px #d1d5db;
    paint-order: stroke fill;
}

.star-rating-input .star-rating-star-btn.star-rating-star-filled {
    color: #facc15;
    -webkit-text-stroke: 0 transparent;
}

.star-rating-display .star-rating-star-filled {
    color: #facc15;
}

.star-rating-display .star-rating-star-empty {
    color: #d6d3d1;
}

.star-rating-sm .star-rating-star {
    font-size: 0.875rem;
}

/* Wizard & quick-action modals */
.wizard-root {
    position: relative;
    z-index: 60;
}

.wizard-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(61, 64, 53, 0.45);
    padding: 1rem;
}

.plant-ack-dialog {
    width: min(100%, 32rem);
    max-height: min(90vh, 720px);
    margin: auto;
    border: none;
    padding: 0;
    overflow: visible;
    background: transparent;
}

.plant-ack-dialog::backdrop {
    background: rgba(61, 64, 53, 0.45);
}

.plant-ack-dialog .wizard-modal {
    width: 100%;
    max-height: min(90vh, 720px);
    overflow: auto;
}

.wizard-modal {
    width: min(100%, 42rem);
    max-height: min(90vh, 720px);
    overflow: auto;
    border-radius: 1rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    box-shadow: 0 24px 48px rgba(61, 64, 53, 0.18);
}

.wizard-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    border-bottom: 1px solid var(--garden-border);
    padding: 1.25rem 1.5rem;
}

.wizard-modal-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--garden-soil);
}

.wizard-modal-subtitle {
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #78716c;
}

.wizard-modal-close {
    border: none;
    background: transparent;
    font-size: 1.5rem;
    line-height: 1;
    color: #78716c;
    cursor: pointer;
}

.wizard-modal-close:hover {
    color: var(--garden-soil);
}

.wizard-modal-body {
    padding: 1.5rem;
}

.wizard-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2.5rem 1.5rem;
}

.wizard-empty-icon {
    font-size: 2rem;
    line-height: 1;
}

.wizard-stepper-list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.wizard-step {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.wizard-step-body {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-radius: 9999px;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.375rem 0.75rem 0.375rem 0.375rem;
}

.wizard-step-current .wizard-step-body {
    border-color: var(--garden-sage);
    background: var(--garden-sage-light);
}

.wizard-step-complete .wizard-step-body {
    border-color: var(--garden-sage);
    background: #fff;
}

.wizard-step-marker {
    display: inline-flex;
    height: 1.5rem;
    width: 1.5rem;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    background: var(--garden-mist);
    font-size: 0.75rem;
    font-weight: 700;
    color: #78716c;
}

.wizard-step-current .wizard-step-marker,
.wizard-step-complete .wizard-step-marker {
    background: var(--garden-sage);
    color: #fff;
}

.wizard-step-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--garden-soil);
}

.wizard-step-arrow {
    color: #a8a29e;
}

.wizard-inline-steps {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    font-weight: 600;
}

.wizard-inline-step {
    color: #a8a29e;
}

.wizard-inline-step.is-current {
    color: var(--garden-sage-dark);
}

.wizard-inline-step.is-complete {
    color: var(--garden-soil);
}

.wizard-inline-arrow {
    color: #d6d3d1;
}

.wizard-select-card {
    display: block;
    cursor: pointer;
    border-radius: 0.75rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    padding: 0.875rem 1rem;
    transition: border-color 150ms ease, background-color 150ms ease;
}

.wizard-select-card:hover {
    border-color: rgba(107, 143, 113, 0.45);
    background: var(--garden-cream);
}

.wizard-select-card.is-selected {
    border-color: var(--garden-sage);
    background: var(--garden-sage-light);
}

.plot-layout-hover-caption-yield {
    margin-top: 0.5rem;
    padding-top: 0.375rem;
    border-top: 1px solid var(--garden-border);
    font-size: 0.6875rem;
    font-weight: 600;
    color: #b45309;
}

.plot-layout-bed-label {
    pointer-events: none;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.plot-layout-resize-handle {
    position: absolute;
    right: -0.375rem;
    bottom: -0.375rem;
    width: 0.75rem;
    height: 0.75rem;
    border: 2px solid #64748b;
    border-radius: 0.125rem;
    background: #fff;
    cursor: nwse-resize;
    z-index: 5;
}

.plot-layout-canvas-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    border-top: 1px solid var(--garden-border);
    padding: 0.625rem 1rem;
    font-size: 0.75rem;
    color: var(--garden-muted);
}

.plot-layout-compass {
    font-weight: 600;
    color: var(--garden-sage-dark);
}

.plot-layout-actions-hidden {
    display: none !important;
}

#plot-layout-selection-actions {
    display: flex;
}

@media (max-width: 639px) {
    #plot-layout-selection-actions:not(.plot-layout-actions-hidden) {
        width: 100%;
    }
}

/* Admin impersonation banner */
.impersonation-banner {
    border-bottom: 1px solid #fbbf24;
    background: linear-gradient(90deg, #fef3c7 0%, #fde68a 100%);
}

.impersonation-banner-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    border: 1px solid #d97706;
    background: #fff;
    padding: 0.5rem 0.875rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #92400e;
    transition: background-color 150ms ease, color 150ms ease;
}

.impersonation-banner-btn:hover {
    background: #fffbeb;
    color: #78350f;
}

/* Plot layout minimap (wizard bed location preview) */
.plot-minimap-popover {
    position: fixed;
    z-index: 80;
    width: min(18rem, calc(100vw - 2rem));
    pointer-events: auto;
}

.plot-minimap-popover-card {
    overflow: hidden;
    border-radius: 0.75rem;
    border: 1px solid var(--garden-border);
    background: #fff;
    box-shadow: 0 16px 40px rgba(61, 64, 53, 0.18);
}

.plot-minimap-popover-header {
    border-bottom: 1px solid var(--garden-border);
    background: var(--garden-mist);
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--garden-soil);
}

.plot-minimap-host {
    padding: 0.625rem;
    background: linear-gradient(180deg, #f8faf5 0%, #eef3e8 100%);
}

.plot-minimap-svg {
    display: block;
    width: 100%;
    height: auto;
}

.plot-minimap-canvas {
    fill: #dce8d0;
    stroke: #94a3b8;
    stroke-width: 0.15;
}

.plot-minimap-grid {
    stroke: rgba(107, 143, 113, 0.18);
    stroke-width: 0.05;
}

.plot-minimap-building rect {
    fill: rgba(148, 163, 184, 0.55);
    stroke: #64748b;
    stroke-width: 0.12;
}

.plot-minimap-building-label {
    fill: #475569;
    font-size: 1.4px;
    font-weight: 600;
    pointer-events: none;
}

.plot-minimap-bed rect,
.plot-minimap-bed circle {
    fill: rgba(123, 160, 91, 0.55);
    stroke: #4a6b50;
    stroke-width: 0.12;
}

.plot-minimap-bed.is-highlight rect,
.plot-minimap-bed.is-highlight circle {
    fill: rgba(201, 123, 132, 0.72);
    stroke: #9f4f59;
    stroke-width: 0.22;
}

.plot-minimap-marker line {
    stroke: #9f4f59;
    stroke-width: 0.16;
}

.plot-minimap-marker path {
    fill: #c97b84;
    stroke: #9f4f59;
    stroke-width: 0.08;
}

.plot-minimap-marker-dot {
    fill: #fff;
    stroke: #9f4f59;
    stroke-width: 0.12;
}

.plot-minimap-caption {
    margin: 0;
    padding: 0.5rem 0.75rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--garden-soil);
    text-align: center;
}

.plot-minimap-empty {
    margin: 0;
    padding: 1rem 0.75rem;
    font-size: 0.75rem;
    color: #78716c;
    text-align: center;
}

.bed-location-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.125rem;
    height: 2.125rem;
    flex-shrink: 0;
    border-radius: 9999px;
    border: 1px solid #fda4af;
    background: #ffe4e6;
    color: #e11d48;
    box-shadow: 0 1px 2px rgba(190, 18, 60, 0.12);
    transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.bed-location-trigger:hover,
.bed-location-trigger:focus-visible {
    border-color: #fb7185;
    background: #fecdd3;
    color: #be123c;
    box-shadow: 0 2px 6px rgba(190, 18, 60, 0.18);
    outline: none;
}

.bed-location-unplaced {
    flex-shrink: 0;
    font-size: 0.6875rem;
    color: #a8a29e;
    white-space: nowrap;
}

.bed-location-place-link {
    font-weight: 600;
    color: var(--garden-sage);
    text-decoration: none;
}

.bed-location-place-link:hover {
    color: var(--garden-sage-dark);
    text-decoration: underline;
}

.plots-v2-bed-location-pin {
    display: inline-flex;
    align-items: center;
}

.wizard-select-card.has-location {
    display: flex;
    align-items: stretch;
    gap: 0.75rem;
}

.wizard-select-card.has-location .bed-location-trigger,
.wizard-select-card.has-location .bed-location-unplaced {
    align-self: center;
}

.wizard-select-card.has-location .wizard-select-card-body {
    min-width: 0;
    flex: 1;
}

.wizard-bed-crop-summary {
    display: flex;
    align-items: stretch;
    gap: 0.625rem;
    min-width: 0;
    height: 100%;
}

.wizard-bed-name-col {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.125rem;
    flex-shrink: 0;
}

.wizard-bed-name {
    font-weight: 600;
    color: var(--garden-soil);
    line-height: 1.35;
}

.wizard-bed-meta {
    font-size: 0.75rem;
    line-height: 1.25;
    color: #78716c;
}

.wizard-bed-meta-link {
    font-weight: 500;
    color: var(--garden-sage);
    text-decoration: none;
}

.wizard-bed-meta-link:hover {
    color: var(--garden-sage-dark);
}

.wizard-bed-crop-divider {
    flex-shrink: 0;
    align-self: stretch;
    width: 1px;
    background: #d6d3d1;
}

.wizard-bed-crop-list {
    min-width: 0;
    margin: 0;
    padding: 0;
    list-style: disc;
    padding-left: 1rem;
    font-size: 0.8125rem;
    line-height: 1.35;
    color: #57534e;
}

.wizard-bed-crop-list li + li {
    margin-top: 0.375rem;
}

.wizard-bed-crop-name {
    font-weight: 600;
    color: var(--garden-soil);
}

.wizard-bed-crop-mode {
    color: #78716c;
    font-size: 0.75rem;
}

.wizard-bed-crop-stock {
    display: block;
    margin-top: 0.125rem;
    font-size: 0.6875rem;
    line-height: 1.35;
    color: #92400e;
}
