
/* ---------- Global page ---------- */
html, body {
    margin: 0;
    height: 100%;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--page-bg);
}

body.lam-page{
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--page-bg);
}

.lam-page-inner{
    flex: 1;                 /* pushes footer down */
    display: block;
}

.page {
    display: flex;
    align-items: flex-start;   /* top-align children instead of centering */
    justify-content: center;   /* still centered horizontally */
    box-sizing: border-box;
    padding: 0px 24px 48px;   /* extra bottom padding so it doesn't hug the bottom */
    position: relative;
    top: 100px;
    gap: 32px;                 /* space between canvas and panel */
}


/* ---------- Main frame (fake browser window) ---------- */
.scene-frame {
    position: relative;
    width: min(1200px);
    aspect-ratio: 16 / 9;
    border-radius: 18px;

    /* use themed color instead of hard-coded yellow */
    background: var(--ui-header-bg);
    border: 4px solid #000000;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25),
    0 0 0 2px rgba(255, 255, 255, 0.4);
    overflow: hidden;
    color: var(--ui-body-text);

    /* NEW: keep it invisible until JS marks it ready */
    transition: opacity 150ms ease-out;
}

#scene-snapshot {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    image-rendering: pixelated;
    z-index: 0;
}

.scene-frame canvas#c {
    position: relative;
    z-index: 1;
    display: block;
    width: 100%;
    height: 100%;
    /* no background so the snapshot can show through if needed */
    background: transparent;
}

/* Canvas fills frame behind UI */
canvas {
    width: 100%;
    height: 100%;
    display: block;
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
    image-rendering: pixelated;
}

/* Debug HUD */
#log {
    position: absolute;
    left: 16px;
    top: 16px;
    padding: 6px 8px;
    font: 12px/1.3 monospace;
    color: #fff;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.6);
    white-space: pre;
    z-index: 2;
}

/* ---------- Top "browser" bar ---------- */
.frame-header {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 30px;
    padding: 14px 32px 10px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    /* header look */
    background: var(--ui-header-bg);
    border-bottom: 4px solid var(--ui-header-border);
    font-weight: 700;
    color: var(--ui-header-text);
    letter-spacing: 0.03em;
}

.frame-nav {
    display: flex;
    gap: 32px;
    font-size: 20px;
}

.frame-nav-item {
    cursor: default;
    position: relative;
    left: 45px;
    top: -5px;
    text-decoration: none;
}

/* Header nav hover = same pill style as footer */
/* Header links = same pill hover style as footer */
.frame-nav-item a{
    color: inherit;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 999px;
    border: 2px solid transparent;
    display: inline-block;
    transition: background 120ms ease, border-color 120ms ease;
    position: relative;
    top: 10px;
}

.frame-nav-item a:hover{
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255,0.18);
}

/* nice keyboard focus */
.frame-nav-item a:focus-visible{
    outline: none;
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255,0.28);
}

.frame-nav-item a:active{
    transform: translateY(0px);
    border-color: rgba(255,255,255);

}

/* Optional: subtle "current page" highlight if you add class="is-active" on the li */
.frame-nav-item.is-active a{
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255);

}

.frame-menu-icon span {
    display: block;
    height: 3px;
    border-radius: 999px;
    background: var(--ui-header-text);
}

/* Header encouragement banner */
.lam-header-banner{
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    padding: 0 18px;
}

.lam-header-banner-pill{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 2px solid rgba(255,255,255,0.18);
    background: rgba(255,255,255,0.08);
    color: var(--ui-header-text);
    font-size: 18px;
    font-weight: 800;
    letter-spacing: 0.02em;
    white-space: nowrap;
    position: relative;
    top: 3px;
}

/* Hide banner on smaller screens so the header doesn't get cramped */
@media (max-width: 900px){
    .lam-header-banner{ display: none; }
}

/* ---------- Right side panel (Today’s tree + recents) ---------- */

.leaf-ui {
    width: 260px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 10px;
    background: var(--ui-panel-bg);
    border: 3px solid var(--ui-panel-border);
    box-shadow: 0 6px 0 rgba(92, 58, 33, 0.3);
    color: var(--ui-body-text);
    align-self: flex-start;  /* stick to the top of the page row */
}

.leaf-ui.view-only {
    opacity: 0.9;
}

.leaf-ui.view-only .message-input,
.leaf-ui.view-only .leaf-ui-button {
    opacity: 0.6;
    cursor: default;
}

.leaf-ui.placing {
    box-shadow: 0 8px 0 rgba(92, 58, 33, 0.35);
}

.panel-section {
    padding-bottom: 8px;
    border-bottom: 2px solid rgba(92, 58, 33, 0.3);
}

.panel-section:last-of-type {
    border-bottom: none;
    padding-bottom: 0;
}

.panel-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 6px;
}

.panel-title.small {
    font-size: 15px;
}

.panel-stat {
    font-size: 14px;
    line-height: 1.4;
}

.panel-stat--my-left {
    margin-top: 6px;
}

#lam-my-leaves-left {
    font-weight: 800;
}

.panel-stat span.label {
    font-weight: 600;
}

.recent-list {
    list-style: none;
    padding: 0;
    margin: -10px 0 0;
    font-size: 14px;
}

.recent-list li + li {
    margin-top: 3px;
}

.leaf-ui-hint {
    font-size: 12px;
    color: var(--ui-muted-text);
    margin-top: 4px;
}

.leaf-ui-hint strong {
    font-weight: 700;
}

.leaf-ui-debug-row {
    margin-top: 6px;
    text-align: right;
}

#randomCanopyBtn {
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 999px;
    border: 1px solid #5c3a21;
    background: var(--ui-input-bg);
    color: var(--ui-body-text);
    cursor: pointer;
}

#randomCanopyBtn:hover {
    background: var(--ui-button-bg);
}

/* ---------- Bottom input bar ---------- */

.bottom-input {
    position: absolute;
    left: 40px;
    right: 40px;
    bottom: 36px;
    display: flex;
    gap: 16px;
    align-items: stretch;
    z-index: 2;
}

.message-input {
    flex: 1;
    box-sizing: border-box;
    padding: 12px 14px;
    border-radius: 10px;
    border: 3px solid var(--ui-input-border);
    background: var(--ui-input-bg);
    font-size: 16px;
    color: var(--ui-body-text);
}

.message-input::placeholder {
    color: var(--ui-placeholder-text);
}

.message-input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(241, 186, 87, 0.7);
}

.leaf-ui-button {
    min-width: 180px;
    padding: 0 24px;
    border-radius: 10px;
    border: 3px solid var(--ui-button-border);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    background: var(--ui-button-bg);
    color: var(--ui-button-text);
    /*
    box-shadow: 0 6px 0 rgba(148, 93, 44, 0.8);
    */
    transition: transform 0.06s ease, box-shadow 0.06s ease, background 0.1s ease;
}

/*        .leaf-ui-button:hover {
            background: #f5a623;
        }*/

.leaf-ui-button:active {
    transform: translateY(2px);
    /*
    box-shadow: 0 3px 0 rgba(148, 93, 44, 0.8);
    */
}

.leaf-ui-button:disabled {
    opacity: 0.6;
    cursor: default;
    box-shadow: none;
}

/* small screens: keep things readable */
@media (max-width: 900px) {
    .site-title {
        font-size: 28px;
        top: 60px;
    }

    .leaf-ui {
        top: 115px;
        right: 16px;
        width: 220px;
    }

    .bottom-input {
        left: 16px;
        right: 16px;
        bottom: 24px;
    }

    .leaf-ui-button {
        min-width: 140px;
        font-size: 16px;
    }


}

/* ---- Toast alerts ------------------------------------------------ */

#lam-alert-stack {
    position: fixed;
    right: 24px;
    top: 70px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 9999;
    pointer-events: none; /* clicks pass through except on alerts */
}

.lam-alert {
    min-width: 260px;
    max-width: 360px;
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
    font-size: 13px;
    line-height: 1.4;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 0, 0, 0.06);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 150ms ease-out, transform 150ms ease-out;
    pointer-events: auto; /* clickable close button */
}

.lam-alert--show {
    opacity: 1;
    transform: translateY(0);
}

.lam-alert__icon {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;
    font-size: 13px;
    flex-shrink: 0;
}

.lam-alert__text {
    flex: 1;
}

.lam-alert__close {
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
    margin-left: 8px;
    font-size: 14px;
    line-height: 1;
    opacity: 0.7;
}

.lam-alert__close:hover {
    opacity: 1;
}

/* Variants – tweak colors to taste */
.lam-alert--info {
    background: rgba(75, 139, 255, 0.14);
    color: #e4f0ff;
    border-color: rgba(75, 139, 255, 0.6);
}

.lam-alert--info .lam-alert__icon {
    background: rgba(75, 139, 255, 0.9);
    color: white;
}

.lam-alert--success {
    background: rgba(34, 197, 94, 0.14);
    color: #e6ffef;
    border-color: rgba(34, 197, 94, 0.6);
}

.lam-alert--success .lam-alert__icon {
    background: rgba(34, 197, 94, 0.9);
    color: white;
}

.lam-alert--warning {
    background: rgba(245, 158, 11, 0.16);
    color: #fff6e1;
    border-color: rgba(245, 158, 11, 0.7);
}

.lam-alert--warning .lam-alert__icon {
    background: rgba(245, 158, 11, 0.9);
    color: white;
}

.lam-alert--danger {
    background: rgba(239, 68, 68, 0.16);
    color: #ffe9ea;
    border-color: rgba(239, 68, 68, 0.7);
}

.lam-alert--danger .lam-alert__icon {
    background: rgba(239, 68, 68, 0.9);
    color: white;
}

/* Time-of-day tones, driven from LAMTheme.weights */

.lam-alert--tone-day {
    background: rgba(255, 255, 255, 0.10); /* light glassy */
    color: #f9fafb;
}

.lam-alert--tone-dusk {
    background: rgba(251, 191, 36, 0.22); /* warm golden */
    color: #fffbeb;
}

.lam-alert--tone-night {
    background: rgba(15, 23, 42, 0.90); /* deep blue */
    color: #e5edff;
    border-color: rgba(148, 163, 184, 0.8);
}

/* Base pill */
#lam-theme-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 999px;
    border: 2px solid rgba(0,0,0,0.15);
    font: 15px/1.2 system-ui, sans-serif;
    cursor: pointer;
    box-shadow: 0 2px 0 rgba(0,0,0,0.18);
    background-color: #70b898 !important; /* default Day-ish */
    color: #fffbe3 !important;
}

#lam-theme-toggle .lam-theme-icon {
    width: 18px;
    height: 18px;
    border-radius: 999px;
    background-color: #ffe870;
}

/* Day mode or Auto-in-daytime */
#lam-theme-toggle[data-mode="day"],
#lam-theme-toggle[data-mode="auto"][data-slot="day"] {
    background-color: #70b898 !important;
    color: #fffbe3 !important;
}
#lam-theme-toggle[data-mode="day"] .lam-theme-icon,
#lam-theme-toggle[data-mode="auto"][data-slot="day"] .lam-theme-icon {
    background-color: #ffe870;
}

/* Night mode or Auto-at-night */
#lam-theme-toggle[data-mode="night"],
#lam-theme-toggle[data-mode="auto"][data-slot="night"] {
    background-color: #1f3248 !important;
    color: #dcefff !important;
}
#lam-theme-toggle[data-mode="night"] .lam-theme-icon,
#lam-theme-toggle[data-mode="auto"][data-slot="night"] .lam-theme-icon {
    background: radial-gradient(circle at 30% 35%, #ffe8a0 0, #ffe8a0 55%, transparent 56%);
    box-shadow: inset -4px 0 0 #1f3248;
}

/* Optional dusk tint for Auto */
#lam-theme-toggle[data-mode="auto"][data-slot="dusk"] {
    background-color: #476a91 !important;
}
#lam-theme-toggle[data-mode="auto"][data-slot="dusk"] .lam-theme-icon {
    background: radial-gradient(circle at 30% 35%, #ffd98c 0, #ffd98c 55%, transparent 56%);
    box-shadow: inset -4px 0 0 #476a91;
}

.grove-intro {
    max-width: 1550px;
    margin: 100px auto 40px;
    padding: 18px 22px;
    border-radius: 14px;
    background: var(--ui-panel-bg);
    border: 3px solid var(--ui-panel-border);
    box-shadow: 0 6px 0 rgba(92, 58, 33, 0.25);
    color: var(--ui-body-text);
    display: flex;
    gap: 200px;
    box-sizing: border-box;
    font-size: 14px;
}

.grove-intro__col {
    flex: 1 1 0;
    min-width: 0;
}

.grove-intro__heading {
    margin: 0 0 8px;
    font-size: 20px;
    font-weight: 700;
    color: var(--ui-header-text);
}

.grove-intro__subheading {
    margin: 12px 0 6px;
    font-size: 15px;
    font-weight: 700;
    color: var(--ui-header-text);
}

.grove-intro p {
    margin: 4px 0 8px;
    line-height: 1.4;
}

.grove-intro ol,
.grove-intro ul {
    margin: 4px 0 8px 18px;
    padding: 0;
}

.grove-intro__note {
    font-size: 13px;
    color: var(--ui-muted-text);
}

/* Stack the columns on narrow screens */
@media (max-width: 900px) {
    .grove-intro {
        flex-direction: column;
        gap: 16px;
    }
}

.lam-footer{
    margin-top: auto;
    margin-left: auto;
    margin-right: auto;
    padding: 14px 18px;
    border-radius: 14px;
    border: 3px solid var(--ui-panel-border);
    background: var(--ui-panel-bg);
    color: var(--ui-body-text);
    box-shadow: 0 6px 0 rgba(0,0,0,0.15);
    width: min(1510px, calc(100% - 40px));
    align-self: center;
}

.lam-footer-inner{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.lam-footer-left{
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.lam-footer-brand{
    font-weight: 800;
}

.lam-footer-tag,
.lam-footer-dot{
    color: var(--ui-muted-text);
}

.lam-footer-links a{
    color: var(--ui-body-text);
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 999px;
    border: 2px solid transparent;
}

.lam-footer-links a:hover{
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255,0.18);
}

.lam-footer-sep{
    margin: 0 6px;
    color: var(--ui-muted-text);
}


/* Mobile */
@media (max-width: 700px){
    .lam-footer-inner{
        flex-direction: column;
        align-items: flex-start;
    }
    .lam-footer-right{
        width: 100%;
        justify-content: flex-start;
    }
}
.lam-footer-meta{
    text-align: center;
    font-size: 16px;
    color: var(--ui-muted-text);
}
/* Replay / Stop buttons (match the panel pill style) */
.leaf-ui-debug-row{
    margin-top: 6px;
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

#replayBtn,
#stopReplayBtn{
    font-size: 16px;
    padding: 3px 10px;
    border-radius: 999px;
    border: 2px solid var(--ui-panel-border);
    background: var(--ui-input-bg);
    color: var(--ui-body-text);
    cursor: pointer;
    box-shadow: 0 2px 0 rgba(92, 58, 33, 0.25);
    transition: transform 0.06s ease, box-shadow 0.06s ease, background 0.1s ease;
}

#replayBtn:hover,
#stopReplayBtn:hover{
    background: var(--ui-button-bg);
}

#replayBtn:active,
#stopReplayBtn:active{
    transform: translateY(1px);
    box-shadow: 0 1px 0 rgba(92, 58, 33, 0.25);
}

#replayBtn:focus-visible,
#stopReplayBtn:focus-visible{
    outline: none;
    box-shadow: 0 0 0 3px rgba(241, 186, 87, 0.7);
}

.lam-header-actions{
    display:flex;
    gap:10px;
    align-items:center;
    margin-left:auto;
}

/* Header action pills (Like + Theme) should follow the time-of-day theme */
.lam-icon-btn{
    display:flex;
    align-items:center;
    gap:8px;
    padding:5px 10px;
    border: 2px solid var(--ui-panel-border);
    border-radius:999px;
    background: var(--ui-panel-bg);
    color: var(--ui-body-text);
    font-weight:700;
    cursor:pointer;
    box-shadow: 0 2px 0 rgba(0,0,0,0.12);
    transition: background 160ms ease, border-color 160ms ease, transform 80ms ease;
}

.lam-icon-btn:hover{
    transform: translateY(-1px);
    border-color: var(--ui-button-border);
}

/* Like counter pill (also theme-aware) */
.lam-like-count{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-width: 22px;
    height: 18px;
    padding: 0 7px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    color: var(--ui-body-text);
    background: rgba(255,255,255,0.18);
    border: 2px solid rgba(255,255,255,0.18);
}

/* Liked state uses the themed button colors */
#lam-like-btn.is-liked{
    background: var(--ui-button-bg);
    border-color: var(--ui-button-border);
    color: var(--ui-button-text);
}


.lam-icon{
    font-size:14px;
    line-height:1;
}

.lam-icon-text{
    font-size:14px;
}

/* Like counter pill */
.lam-like-count{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-width: 22px;
    height: 18px;
    padding: 0 7px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
    line-height: 1;
    background: rgba(255,255,255,0.35);
    border: 2px solid rgba(92, 58, 33, 0.35);
}

/* Optional: liked state */
#lam-like-btn.is-liked{
    background: var(--ui-button-bg);
}
#lam-like-btn.is-liked .lam-icon{
    content: "♥";
}
.lam-like-icon{
    width: 16px;
    height: 16px;
    image-rendering: pixelated; /* looks nice if you later use pixel hearts */
}

/* =======================================================================
   Grove page (grove.php) — grid, cards, sidebar, search, pagination
   (Merged from grove_style.css, cleaned up to avoid duplicates)
   ======================================================================= */

.grove-layout{
    /* keep content below the absolute header */
    margin-top: 100px;

    /* align with .page spacing */
    padding: 0 24px 48px;

    width: min(1550px, calc(100% - 48px));
    margin-left: auto;
    margin-right: auto;

    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 24px;
}

.grove-grid{
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.grove-item{
    display: block;
}

.grove-card{
    background: var(--ui-panel-bg);
    border-radius: 16px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.10);
    padding: 16px;
    text-align: center;
    border: 3px solid var(--ui-panel-border);
    color: var(--ui-body-text);
    text-decoration: none;

    display: flex;
    flex-direction: column;
}

.grove-card-thumb{
    margin-bottom: 10px;
    border-radius: 10px;
    background: linear-gradient(#ffffff, #abb0a7);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    aspect-ratio: 96 / 56; /* matches canvas thumb size */
}

.grove-thumb-img{
    width: 100%;
    height: 100%;
    object-fit: cover;
    image-rendering: pixelated;
    display: block;
}

.grove-thumb-canvas{
    width: 100%;
    height: 100%;
    image-rendering: pixelated;
    display: block;
}

.grove-card-date{
    font-weight: 800;
    margin-bottom: 4px;
}

.grove-card-sub{
    font-size: 14px;
    color: var(--ui-muted-text);
    margin-bottom: 4px;
}

.grove-card-leaves{
    font-size: 14px;
    color: var(--ui-muted-text);
}

/* Sidebar panel */
.grove-sidebar{
    background: var(--ui-panel-bg);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
    border: 3px solid var(--ui-panel-border);
    font-size: 14px;
    color: var(--ui-body-text);
    height: auto;
    align-self: start;
}

.grove-sidebar h2{
    margin: 0 0 10px;
    font-size: 18px;
}

/* Totals block */
.grove-totals{
    margin-top: 12px;
    padding-top: 12px;
    border-top: 2px solid rgba(92, 58, 33, 0.25);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.grove-total-row{
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    color: var(--ui-body-text);
    font-weight: 700;
}

.grove-total-row strong{
    font-weight: 900;
}

/* Filters */
.grove-filters label{
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
}

.grove-sort-links a{
    margin-right: 10px;
    text-decoration: none;
    color: var(--ui-body-text);
    font-weight: 700;
    opacity: 0.85;
}

.grove-sort-links a:hover{
    opacity: 1;
    text-decoration: underline;
}

.grove-sort-links a.is-active{
    opacity: 1;
    text-decoration: underline;
}

/* Search */
.grove-search{
    margin-top: 14px;
}

.grove-search-label{
    display: block;
    font-weight: 800;
    margin-bottom: 6px;
}

.grove-search-row{
    position: relative;
}

.grove-search-input{
    width: 100%;
    box-sizing: border-box;
    padding: 12px 14px;
    border-radius: 10px;
    border: 3px solid var(--ui-input-border);
    background: var(--ui-input-bg);
    font-size: 16px;
    color: var(--ui-body-text);
    font-weight: 500;
}

.grove-search-input::placeholder{
    color: var(--ui-placeholder-text);
    font-weight: 500;
}

.grove-search-input:focus{
    outline: none;
    box-shadow: 0 0 0 3px rgba(250, 204, 107, 0.55);
}

.grove-search-clear{
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border-radius: 10px;
    border: 2px solid var(--ui-panel-border);
    background: rgba(255, 255, 255, 0.65);
    font-weight: 900;
    cursor: pointer;
}

.grove-search-meta{
    margin-top: 6px;
    font-size: 18px;
    opacity: 0.85;
    color: var(--ui-muted-text);
}

/* Pagination */
.grove-pagination{
    margin-top: 24px;
    text-align: center;
}

.grove-pagination a{
    display: inline-block;
    margin: 0 4px;
    padding: 6px 10px;
    border-radius: 999px;
    text-decoration: none;
    border: 2px solid rgba(255,255,255,0.18);
    color: var(--ui-body-text);
    font-size: 14px;
    min-width: 28px;
    background: rgba(255,255,255,0.06);
}

.grove-pagination a:hover{
    background: rgba(255,255,255,0.10);
    border-color: rgba(255,255,255,0.28);
}

.grove-pagination a.is-active{
    background: rgba(255,255,255,0.14);
    border-color: rgba(255,255,255,0.35);
    font-weight: 800;
}

.grove-empty{
    grid-column: 1 / -1;
    text-align: center;
    color: var(--ui-muted-text);
    padding: 40px 0;
    font-size: 25px;
}

/* Header menu icon wrapper (style.css already defines the span bars) */
.frame-menu-icon{
    position: relative;
    top: -5px;
    width: 24px;
    height: 18px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Responsive Grove: keep sidebar on the RIGHT (no stacking) */
@media (max-width: 1100px){
    .grove-sidebar{
        position: sticky;
        top: -70px; /* adjust if your header height differs */
        align-self: start;
    }
}

    .grove-grid{
        grid-template-columns: repeat(3, minmax(0, 1fr)); /* 2 cards per row */
        gap: 18px;
    }

    .grove-card{ padding: 12px; }
    .grove-sidebar{ padding: 12px; }
}

/* Phones: still keep sidebar on the right, but tighter */
@media (max-width: 720px){
    .grove-layout{
        grid-template-columns: minmax(0, 1fr) 240px;
        padding: 0 14px 36px;
        width: calc(100% - 28px);
        gap: 12px;
    }

    .grove-grid{
        grid-template-columns: repeat(2, minmax(0, 1fr)); /* still 2-up */
        gap: 12px;
    }

    .grove-card-date{ font-size: 15px; }
    .grove-card-sub,
    .grove-card-leaves{ font-size: 12px; }

    .grove-search-input{ font-size: 14px; padding: 10px 12px; }
}

/* Super narrow phones: drop to 1 card per row so it stays readable */
@media (max-width: 520px){
    .grove-layout{
        grid-template-columns: minmax(0, 1fr) 210px;
    }

    .grove-grid{
        grid-template-columns: 1fr;
    }

    .grove-sidebar{ font-size: 13px; }
    .grove-sidebar h2{ font-size: 16px; }
}

