/*
Theme Name: VamshaVaani
Theme URI: http://vamshavaani.local
Author: VamshaVaani
Description: A warm family-legacy theme. Image-based hero with overlaid editable text, leaf watermark background, high-contrast warm palette. Logo tagline, About text and feature cards are editable via the Customizer; tabs are a WordPress menu; header shows Login/Register or Logout depending on auth state.
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: vamshavaani
*/

/* ========== Design tokens (deeper, higher-contrast warm palette) ========== */
:root {
    --vv-page:        #efd9b6;   /* page background cream (a touch deeper) */
    --vv-hero-cream:  #f2ddb4;   /* matches hero image left area */
    --vv-section:     #efd5a8;   /* features band behind the cards */
    --vv-card:        #fdd5af;   /* card surface: soft peach */
    --vv-card-2:      #f8c99e;   /* card gradient bottom (subtle) */
    --vv-card-border: #eab886;   /* soft peach edge */
    --vv-header:      #fbf4e6;
    --vv-brown:       #5e3a1c;
    --vv-brown-dark:  #3f2712;
    --vv-brown-soft:  #7a4a23;
    --vv-text:        #4a3a26;
    --vv-text-soft:   #5a4327;
    --vv-green:       #4f7a30;
    --vv-orange:      #cf6f1f;
    --vv-blue:        #2f6f96;
    --vv-line:        #ddc193;
    --vv-line-soft:   #e7d2ac;
    --vv-serif:       Georgia, 'Times New Roman', serif;
    --vv-sans:        -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --vv-radius:      12px;
    --vv-shadow:      0 8px 22px rgba(63, 39, 18, 0.14);
    --vv-shadow-sm:   0 3px 10px rgba(63, 39, 18, 0.10);
}

/* ========== Base ========== */
* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--vv-sans);
    color: var(--vv-text);
    background-color: var(--vv-page);
    background-image: url(assets/images/leaf-pattern.svg);
    background-size: 240px auto;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--vv-brown-soft); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; }

.vv-container {
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 28px;
}

/* ========== Header ========== */
.vv-header {
    background: var(--vv-header);
    border-bottom: 1px solid var(--vv-line);
    box-shadow: var(--vv-shadow-sm);
    position: relative;
    z-index: 5;
}
.vv-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
}
.vv-brand { display: inline-flex; align-items: center; }
.vv-brand:hover { text-decoration: none; }
.vv-brand__img { height: 52px; width: auto; display: block; }

/* Auth buttons */
.vv-auth { display: flex; align-items: center; gap: 10px; }

/* Notification bell (unread Vamsha Vaani posts) */
.vv-notif {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: var(--vv-brown);
    transition: background-color .2s, color .2s;
}
.vv-notif:hover { background: var(--vv-hero-cream); color: var(--vv-brown-dark); }
.vv-notif__icon { width: 22px; height: 22px; display: block; }
.vv-notif__badge {
    position: absolute;
    top: 2px;
    right: 0;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    background: #c0392b;
    color: #fff;
    font-size: .7rem;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    box-shadow: 0 0 0 2px var(--vv-bg, #fff);
}
.vv-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 0.9rem;
    font-weight: 600;
    padding: 9px 18px;
    border-radius: 8px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
    line-height: 1;
}
.vv-btn:hover { text-decoration: none; transform: translateY(-1px); }
.vv-btn--ghost {
    background: #fff;
    border-color: var(--vv-line);
    color: var(--vv-brown-dark);
    box-shadow: var(--vv-shadow-sm);
}
.vv-btn--ghost:hover { background: var(--vv-hero-cream); }
.vv-btn--primary {
    background: var(--vv-brown-soft);
    color: #fff;
    box-shadow: 0 4px 12px rgba(94, 58, 28, 0.32);
}
.vv-btn--primary:hover { background: var(--vv-brown); color: #fff; }
.vv-btn--danger {
    background: #c0392b;
    color: #fff;
    box-shadow: 0 4px 12px rgba(192, 57, 43, 0.32);
}
.vv-btn--danger:hover { background: #a93226; color: #fff; }
.vv-btn__icon { width: 15px; height: 15px; }

/* ----- Delete node panel ----- */
.vv-delete__search { display: flex; gap: 8px; margin: 12px 0 10px; }
.vv-delete__search .vv-input { flex: 1; }
.vv-delete__msg { font-size: .9rem; color: var(--vv-text-soft); margin: 8px 0 0; font-style: italic; }
.vv-delete__list { margin-top: 10px; }
.vv-delete__confirm { margin-top: 12px; padding: 14px 16px; background: #fff8f6; border: 1.5px solid #e8b4a0; border-radius: 8px; }
.vv-delete__who { margin: 0 0 12px; font-size: .95rem; }
.vv-delete__form { margin-top: 4px; }

/* ========== Nav tabs ========== */
.vv-nav {
    background: var(--vv-header);
    border-bottom: 1px solid var(--vv-line);
    position: relative;
    z-index: 5;
}
.vv-nav__inner { display: flex; justify-content: center; }
.vv-menu {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0;
    padding: 0;
}
.vv-menu li { margin: 0; }
.vv-menu a {
    display: block;
    padding: 15px 20px;
    color: var(--vv-text);
    font-weight: 600;
    font-size: 0.95rem;
    border-bottom: 3px solid transparent;
}
.vv-menu a:hover { color: var(--vv-brown-dark); text-decoration: none; }
.vv-menu .current-menu-item > a,
.vv-menu .current_page_item > a {
    color: var(--vv-brown-dark);
    border-bottom-color: var(--vv-brown-soft);
}

/* ========== Hero (image background + overlaid text) ========== */
.vv-hero {
    position: relative;
    background-color: var(--vv-hero-cream);
    background-image:
        linear-gradient(101deg,
            rgba(238, 213, 168, 0.97) 0%,
            rgba(238, 213, 168, 0.92) 26%,
            rgba(240, 216, 170, 0.45) 46%,
            rgba(240, 216, 170, 0.05) 58%,
            rgba(240, 216, 170, 0) 64%),
        url(assets/images/hero.png);
    background-repeat: no-repeat, no-repeat;
    background-position: center, right center;
    background-size: cover, cover;
    aspect-ratio: 2149 / 732;
    min-height: 360px;
    display: flex;
    align-items: center;
    box-shadow: inset 0 -40px 60px -40px rgba(63, 39, 18, 0.25);
}
.vv-hero__row { width: 100%; }
.vv-hero__copy { width: 50%; max-width: 540px; }
.vv-hero__title {
    font-family: var(--vv-serif);
    font-size: clamp(1.9rem, 4.4vw, 3.2rem);
    line-height: 1.08;
    color: var(--vv-brown-dark);
    margin: 0 0 16px;
    font-weight: 700;
    text-shadow: 0 1px 0 rgba(255, 250, 240, 0.6);
}
.vv-hero__divider {
    width: clamp(120px, 22vw, 220px);
    height: 14px;
    margin: 0 0 18px;
    color: var(--vv-brown-soft);
    display: block;
}
.vv-hero__text {
    color: var(--vv-brown);
    font-size: clamp(0.84rem, 1.4vw, 1.02rem);
}
.vv-hero__text p { margin: 0 0 12px; }
.vv-hero__art-mobile { display: none; }

/* ========== Feature cards ========== */
.vv-features {
    padding: 44px 0;
    background: var(--vv-section);
    border-top: 1px solid rgba(255,255,255,0.25);
}
.vv-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}
.vv-card {
    background: linear-gradient(165deg, var(--vv-card) 0%, var(--vv-card-2) 100%);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 26px 24px;
    box-shadow: var(--vv-shadow);
    display: flex;
    flex-direction: column;
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.vv-card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(63, 39, 18, 0.20); }
.vv-card__icon {
    width: 52px; height: 52px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 16px;
    color: #fff;
    box-shadow: 0 4px 12px rgba(63, 39, 18, 0.22);
}
.vv-card__icon svg { width: 26px; height: 26px; }
.vv-card--green  .vv-card__icon { background: var(--vv-green); }
.vv-card--orange .vv-card__icon { background: var(--vv-orange); }
.vv-card--blue   .vv-card__icon { background: var(--vv-blue); }
.vv-card__title {
    font-family: var(--vv-serif);
    font-size: 1.3rem;
    color: var(--vv-brown-dark);
    margin: 0 0 9px;
}
.vv-card__desc { font-size: 0.94rem; color: var(--vv-text-soft); margin: 0 0 20px; flex: 1; }
.vv-card__link {
    align-self: flex-start;
    color: #fff;
    font-size: 0.86rem;
    font-weight: 700;
    padding: 9px 16px;
    border-radius: 7px;
    box-shadow: var(--vv-shadow-sm);
}
.vv-card__link:hover { text-decoration: none; filter: brightness(0.93); color: #fff; }
.vv-card--green  .vv-card__link { background: var(--vv-green); }
.vv-card--orange .vv-card__link { background: var(--vv-orange); }
.vv-card--blue   .vv-card__link { background: var(--vv-blue); }

/* ========== Public notice ========== */
.vv-notice { background: var(--vv-section); padding: 0 0 44px; }
.vv-notice__inner {
    background: var(--vv-card);
    border: 1px solid var(--vv-line);
    border-radius: var(--vv-radius);
    padding: 15px;
    text-align: center;
    font-size: 0.92rem;
    color: var(--vv-text-soft);
    box-shadow: var(--vv-shadow-sm);
}
.vv-notice__lock { margin-right: 6px; }

/* ========== Interior pages ========== */
.vv-page { padding: 52px 0 70px; min-height: 46vh; }
.vv-page__title {
    font-family: var(--vv-serif);
    color: var(--vv-brown-dark);
    font-size: 2.3rem;
    margin: 0 0 22px;
}
.vv-page__content { max-width: 800px; }
.vv-page__content h2 { font-family: var(--vv-serif); color: var(--vv-brown-dark); }
.vv-page__content img { border-radius: var(--vv-radius); }

/* ========== My Detail (token lookup) ========== */
.vv-detail-form {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 14px;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 20px 22px;
    box-shadow: var(--vv-shadow-sm);
    margin-bottom: 26px;
}
.vv-detail-form label {
    display: block;
    font-weight: 700;
    color: var(--vv-brown-dark);
    margin-bottom: 7px;
    font-size: 0.95rem;
}
.vv-detail-form input[type="number"] {
    padding: 11px 14px;
    border: 1px solid var(--vv-line);
    border-radius: 8px;
    font-size: 1rem;
    background: #fff;
    color: var(--vv-text);
    width: 200px;
    max-width: 100%;
}
.vv-detail-form input:focus {
    outline: none;
    border-color: var(--vv-brown-soft);
    box-shadow: 0 0 0 3px rgba(122, 74, 35, 0.15);
}
.vv-detail-form .vv-btn { padding: 11px 24px; font-size: 0.95rem; }

/* Search (basic) */
.vv-search {
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 18px 20px;
    box-shadow: var(--vv-shadow-sm);
    margin-bottom: 14px;
}
.vv-search__row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; }
.vv-search__sel { display: block; }
.vv-search__cap {
    display: block;
    font-weight: 700;
    color: var(--vv-brown-dark);
    font-size: 0.85rem;
    margin-bottom: 6px;
}
.vv-search select,
.vv-adv__form select,
.vv-search input[type="text"],
.vv-adv__form input {
    padding: 10px 12px;
    border: 1px solid var(--vv-line);
    border-radius: 8px;
    font-size: 0.96rem;
    background: #fff;
    color: var(--vv-text);
}
.vv-search input[type="text"] { flex: 1; min-width: 200px; }
.vv-search select { min-width: 150px; }
.vv-search :focus,
.vv-adv__form :focus { outline: none; border-color: var(--vv-brown-soft); box-shadow: 0 0 0 3px rgba(122,74,35,0.15); }

/* Advanced search */
.vv-adv {
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    box-shadow: var(--vv-shadow-sm);
    margin-bottom: 26px;
    overflow: hidden;
}
.vv-adv > summary {
    cursor: pointer;
    padding: 14px 20px;
    font-weight: 700;
    color: var(--vv-brown-dark);
    list-style: none;
    user-select: none;
}
.vv-adv > summary::-webkit-details-marker { display: none; }
.vv-adv > summary::before { content: "▸ "; color: var(--vv-brown-soft); }
.vv-adv[open] > summary::before { content: "▾ "; }
.vv-adv__form { padding: 4px 20px 20px; }
.vv-adv__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 14px;
}
.vv-adv__grid label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--vv-brown-dark);
}
.vv-adv__grid input,
.vv-adv__grid select { font-weight: 400; }
.vv-adv__actions { display: flex; align-items: center; gap: 16px; margin-top: 18px; }
.vv-adv__clear { color: var(--vv-brown-soft); font-weight: 600; font-size: 0.9rem; }

/* Results list */
.vv-results-count { font-weight: 700; color: var(--vv-brown-dark); margin: 10px 0; }
.vv-results {
    width: 100%;
    border-collapse: collapse;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    overflow: hidden;
    box-shadow: var(--vv-shadow-sm);
}
.vv-results th,
.vv-results td { text-align: left; padding: 11px 14px; border-bottom: 1px solid rgba(122,74,35,0.16); font-size: 0.93rem; }
.vv-results thead th { background: rgba(122,74,35,0.10); color: var(--vv-brown-dark); font-family: var(--vv-serif); }
.vv-results tbody tr:last-child td { border-bottom: 0; }
.vv-results tbody tr:hover { background: rgba(255,255,255,0.35); }
.vv-results__view { color: var(--vv-blue); font-weight: 700; white-space: nowrap; }

/* Wide results/pending-request tables scroll horizontally within their own
   box on narrow screens instead of overflowing the page or getting clipped. */
.vv-table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
@media (max-width: 768px) {
    .vv-table-scroll .vv-results { min-width: 600px; }
}

/* Update notices */
.vv-notice-ok,
.vv-notice-err {
    border-radius: var(--vv-radius);
    padding: 13px 18px;
    margin-bottom: 18px;
    font-weight: 600;
}
.vv-notice-ok  { background: #e6f0d8; border: 1px solid #a9c47e; color: #3f5d22; }
.vv-notice-err { background: #f6dcd0; border: 1px solid #d99a78; color: #7a3b1c; }

/* Edit (Update Details & Photo) */
.vv-detail__actions { margin-top: 18px; }
.vv-edit {
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 26px;
    box-shadow: var(--vv-shadow);
    margin-bottom: 24px;
}
.vv-edit .vv-detail__name { margin-top: 0; }
.vv-edit__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}
.vv-edit__grid label,
.vv-edit__photo label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-weight: 600;
    font-size: 0.85rem;
    color: var(--vv-brown-dark);
}
.vv-edit__grid input,
.vv-edit__grid select,
.vv-edit__photo input[type="file"] {
    padding: 10px 12px;
    border: 1px solid var(--vv-line);
    border-radius: 8px;
    font-size: 0.96rem;
    background: #fff;
    color: var(--vv-text);
    font-weight: 400;
}
.vv-edit__grid :focus { outline: none; border-color: var(--vv-brown-soft); box-shadow: 0 0 0 3px rgba(122,74,35,0.15); }
.vv-edit__photo {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 280px;
    margin-bottom: 20px;
}
.vv-edit__photo img {
    width: 160px;
    height: 160px;
    object-fit: cover;
    border-radius: var(--vv-radius);
    border: 4px solid #fff;
    box-shadow: var(--vv-shadow-sm);
    background: var(--vv-hero-cream);
}
.vv-edit__hint { color: var(--vv-text-soft); font-size: 0.82rem; }
.vv-edit__hint code { background: rgba(122,74,35,0.10); padding: 1px 6px; border-radius: 4px; }
.vv-photo-cam {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: max-content;
    background: var(--vv-brown-soft);
    color: #fff;
    padding: 9px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.88rem;
    cursor: pointer;
    box-shadow: var(--vv-shadow-sm);
    transition: background 0.15s ease;
}
.vv-photo-cam:hover { background: var(--vv-brown); }
.vv-photo-cam svg { width: 18px; height: 18px; }
.vv-photo-cam input { display: none; }
.vv-photo-note { color: #3f5d22; font-weight: 600; font-size: 0.82rem; }

/* "Use my current location" (GPS) button */
.vv-geo__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    width: max-content;
    max-width: 100%;
    margin-top: 4px;
    padding: 7px 12px;
    border-radius: 7px;
    background: #fff;
    border: 1px solid var(--vv-line);
    color: var(--vv-brown-dark);
    font-weight: 600;
    font-size: 0.8rem;
    cursor: pointer;
    transition: background 0.15s ease;
}
.vv-geo__btn:hover { background: var(--vv-hero-cream); }
.vv-geo__btn:disabled { opacity: 0.6; cursor: default; }
.vv-geo__btn svg { width: 15px; height: 15px; flex: 0 0 auto; }
.vv-geo__status { display: block; margin-top: 4px; font-size: 0.78rem; color: var(--vv-text-soft); }
.vv-detail__empty { color: var(--vv-text-soft); font-style: italic; }
.vv-edit__actions { display: flex; align-items: center; gap: 16px; }
.vv-edit__note { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 0.85rem; color: var(--vv-brown-dark); margin-bottom: 20px; }
.vv-edit__note textarea {
    padding: 10px 12px;
    border: 1px solid var(--vv-line);
    border-radius: 8px;
    font: inherit;
    font-weight: 400;
    background: #fff;
    color: var(--vv-text);
    resize: vertical;
}

/* Update requests (member request hint + editor review) */
.vv-req__hint {
    background: #fff6e6;
    border: 1px solid var(--vv-card-border);
    border-radius: 8px;
    padding: 10px 14px;
    color: var(--vv-text-soft);
    font-size: 0.9rem;
}
.vv-req__title { font-family: var(--vv-serif); color: var(--vv-brown-dark); margin: 26px 0 12px; }
.vv-req {
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 20px 22px;
    box-shadow: var(--vv-shadow-sm);
    margin-bottom: 18px;
}
.vv-req__head { color: var(--vv-brown-dark); margin-bottom: 8px; }
.vv-req__date { color: var(--vv-text-soft); font-size: 0.85rem; margin-left: 8px; }
.vv-req__note { font-style: italic; color: var(--vv-text-soft); margin: 0 0 12px; }
.vv-req__diff { width: 100%; border-collapse: collapse; margin-bottom: 14px; }
.vv-req__diff th, .vv-req__diff td { text-align: left; padding: 8px 12px; border-bottom: 1px solid rgba(122,74,35,0.16); font-size: 0.92rem; vertical-align: top; }
.vv-req__diff thead th { background: rgba(122,74,35,0.10); color: var(--vv-brown-dark); font-family: var(--vv-serif); }
.vv-req__old { color: #7a3b1c; text-decoration: line-through; }
.vv-req__new { color: #3f5d22; font-weight: 600; }
.vv-req__nochange { color: var(--vv-text-soft); font-style: italic; }
.vv-req__photo { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.vv-req__photo img { width: 130px; height: 130px; object-fit: cover; border-radius: var(--vv-radius); border: 4px solid #fff; box-shadow: var(--vv-shadow-sm); }
.vv-req__actions { display: flex; gap: 12px; }
.vv-req__actions form { margin: 0; }
.vv-pending .vv-results { box-shadow: none; }
.vv-badge {
    display: inline-block;
    padding: 2px 9px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    background: rgba( 122, 74, 35, 0.12 );
    color: var(--vv-brown-dark);
}
.vv-badge--add { background: #e6f0d8; color: #3f5d22; }

/* Node Name autocomplete dropdown */
.vv-ac {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 40;
    background: #fff;
    border: 1px solid var(--vv-line);
    border-radius: 8px;
    box-shadow: var(--vv-shadow);
    max-height: 230px;
    overflow-y: auto;
    margin-top: 2px;
}
.vv-ac__item {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 10px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--vv-text);
}
.vv-ac__item:hover { background: var(--vv-hero-cream); }
.vv-ac__item em { color: var(--vv-text-soft); font-size: 0.78rem; font-style: normal; white-space: nowrap; }

.vv-detail-empty,
.vv-detail-note {
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 14px 18px;
    color: var(--vv-text);
}
.vv-detail-note { color: var(--vv-text-soft); font-size: 0.92rem; }

.vv-detail {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 28px;
    align-items: start;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 26px;
    box-shadow: var(--vv-shadow);
    margin-bottom: 24px;
}
.vv-detail__name {
    font-family: var(--vv-serif);
    color: var(--vv-brown-dark);
    font-size: 1.6rem;
    margin: 0 0 16px;
    border-bottom: 2px solid var(--vv-card-border);
    padding-bottom: 10px;
}
.vv-detail__list { margin: 0; }
.vv-detail__row {
    display: grid;
    grid-template-columns: 190px 1fr;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px dashed rgba(122, 74, 35, 0.18);
}
.vv-detail__row:last-child { border-bottom: 0; }
.vv-detail__label { margin: 0; font-weight: 700; color: var(--vv-brown-soft); font-size: 0.92rem; }
.vv-detail__value { margin: 0; color: var(--vv-text); word-break: break-word; }

.vv-detail__photo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}
.vv-detail__photo img {
    width: 100%;
    max-width: 300px;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: var(--vv-radius);
    border: 4px solid #fff;
    box-shadow: var(--vv-shadow);
    background: var(--vv-hero-cream);
}
.vv-detail__photo-cap {
    font-family: var(--vv-serif);
    color: var(--vv-brown-dark);
    font-weight: 700;
    text-align: center;
}

@media (max-width: 720px) {
    .vv-detail { grid-template-columns: 1fr; }
    .vv-detail__photo { order: -1; }
    .vv-detail__photo img { max-width: 220px; }
    .vv-detail__row { grid-template-columns: 1fr; gap: 2px; }
}

/* ========== Family Tree lineage graph ========== */
.vv-tree-page { padding-bottom: 40px; }

.vv-tree-layout {
    display: flex;
    align-items: flex-start;
    gap: 20px;
}
.vv-tree-tabs-sidebar {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 0 0 220px;
    width: 220px;
}
.vv-tree-tab {
    display: block;
    font-size: 0.85rem;
    text-align: left;
    padding: 10px 14px;
    border-radius: var(--vv-radius);
    border: 1px solid var(--vv-line);
    background: #fff;
    color: var(--vv-brown-dark);
    cursor: pointer;
    box-shadow: var(--vv-shadow-sm);
    text-decoration: none;
}
.vv-tree-tab:hover { background: var(--vv-hero-cream); text-decoration: none; }
.vv-tree-main { flex: 1 1 auto; min-width: 0; }

/* Mobile tab row (below the title/tagline) — hidden on desktop, where the
   left sidebar above is used instead. */
.vv-tree-tabs-row { display: none; }

@media (max-width: 768px) {
    /* Portrait phones: drop the left sidebar and show the tabs as a single
       row of 8 columns right under the title/tagline instead. The row
       scrolls horizontally if the 8 labels don't all fit at once. */
    .vv-tree-tabs-sidebar { display: none; }
    .vv-tree-tabs-row {
        display: grid;
        grid-auto-flow: column;
        grid-auto-columns: minmax(96px, 1fr);
        grid-template-rows: 1fr;
        gap: 6px;
        overflow-x: auto;
        margin: 12px 0 16px;
        padding-bottom: 4px;
    }
    .vv-tree-tabs-row .vv-tree-tab {
        text-align: center;
        font-size: 0.72rem;
        padding: 8px 6px;
        white-space: normal;
        line-height: 1.25;
    }
}

.vv-tree-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
}
.vv-tree-toolbar .vv-btn { padding: 7px 14px; font-size: 0.85rem; }
.vv-tree-hint { color: var(--vv-text-soft); font-size: 0.8rem; margin-left: auto; }

.vv-tree-viewport {
    position: relative;
    overflow: auto;
    width: 100%;
    height: 78vh;
    min-height: 440px;
    background-color: var(--vv-section);
    background-image: url(assets/images/leaf-pattern.svg);
    background-size: 240px auto;
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    box-shadow: var(--vv-shadow);
    cursor: grab;
    -webkit-overflow-scrolling: touch;
}
.vv-tree-viewport.is-panning { cursor: grabbing; }
.vv-tree-viewport.is-panning .vv-node { pointer-events: none; }

.vv-tree {
    display: inline-block;
    box-sizing: border-box;
    min-width: 100%;
    padding: 36px 80px 60px;
    zoom: var(--vv-zoom, 1);
}
.vv-tree[hidden] { display: none; }

/* Connectors (top-down org-chart technique) */
.vv-tree ul {
    position: relative;
    display: flex;
    justify-content: center;
    padding: 30px 0 0;
    margin: 0;
    list-style: none;
}
.vv-tree > ul { padding-top: 0; }
.vv-tree li {
    position: relative;
    padding: 30px 16px 0;
    list-style: none;
}
.vv-tree li::before,
.vv-tree li::after {
    content: '';
    position: absolute;
    top: 0;
    right: 50%;
    width: 50%;
    height: 30px;
    border-top: 2px solid var(--vv-brown-soft);
}
.vv-tree li::after {
    right: auto;
    left: 50%;
    border-left: 2px solid var(--vv-brown-soft);
}
.vv-tree li:only-child::before,
.vv-tree li:only-child::after { display: none; }
.vv-tree li:only-child { padding-top: 0; }
.vv-tree li:first-child::before,
.vv-tree li:last-child::after { border: 0; }
.vv-tree li:last-child::before { border-right: 2px solid var(--vv-brown-soft); border-radius: 0 6px 0 0; }
.vv-tree li:first-child::after { border-radius: 6px 0 0 0; }
.vv-tree ul ul::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    width: 0;
    height: 30px;
    border-left: 2px solid var(--vv-brown-soft);
}
/* Collapsed node: hide its descendants and the connector above them */
.vv-tree li.is-collapsed > ul { display: none; }

/* Node card */
.vv-node {
    cursor: pointer;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    position: relative;
    width: 104px;
    padding: 10px 8px 9px;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: 12px;
    box-shadow: var(--vv-shadow-sm);
    text-align: center;
}
.vv-node:hover { box-shadow: 0 8px 18px rgba(63,39,18,0.20); }
.vv-node__photo {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid #fff;
    box-shadow: var(--vv-shadow-sm);
    background: var(--vv-hero-cream);
}
.vv-node__photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.vv-node__name { font-weight: 700; font-size: 0.78rem; color: var(--vv-brown-dark); line-height: 1.15; word-break: break-word; }
.vv-node__meta { font-size: 0.66rem; color: var(--vv-text-soft); }
.vv-node__toggle {
    position: absolute;
    bottom: -11px;
    left: 50%;
    transform: translateX(-50%);
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1px solid var(--vv-card-border);
    background: #fff;
    color: var(--vv-brown-dark);
    font-weight: 700;
    font-size: 0.95rem;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    z-index: 2;
}
.vv-node__toggle:hover { background: var(--vv-hero-cream); }

/* Couple wrapper: node + spouses shown side-by-side in the focused mini-tree */
.vv-couple {
    position: relative;          /* anchor for .vv-node__toggle inside */
    display: inline-flex;
    align-items: flex-start;
    gap: 6px;
    padding-bottom: 0;
}
.vv-couple__heart {
    display: flex;
    align-items: center;
    align-self: center;
    font-size: 1rem;
    color: #c0392b;
    flex-shrink: 0;
    line-height: 1;
    padding: 0 2px;
    pointer-events: none;
}
/* When a couple has children, the toggle sits below the whole group */
.vv-couple > .vv-node__toggle {
    position: absolute;
    bottom: -11px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
}

/* ========== Family tree search bar (always visible) ========== */
.vv-focus-bar {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-top: .6rem;
    padding: .6rem .75rem;
    background: var(--vv-section);
    border-radius: var(--vv-radius);
    border: 1px solid var(--vv-card-border);
    flex-wrap: wrap;
}
.vv-focus-search { position: relative; flex: 1 1 260px; }
.vv-input {
    width: 100%;
    padding: .45rem .75rem;
    border: 1.5px solid var(--vv-card-border);
    border-radius: 6px;
    background: #fff;
    font-size: .9rem;
    color: var(--vv-text);
    font-family: var(--vv-sans);
}
.vv-input:focus { outline: none; border-color: var(--vv-brown-soft); }
/* Autocomplete dropdown (shared by node-autocomplete.js and focus search) */
.vv-ac {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1.5px solid var(--vv-card-border);
    border-radius: 6px;
    box-shadow: var(--vv-shadow-sm);
    z-index: 900;
    max-height: 220px;
    overflow-y: auto;
}
.vv-ac__item {
    padding: .45rem .75rem;
    font-size: .88rem;
    cursor: pointer;
    color: var(--vv-text);
}
.vv-ac__item:hover { background: var(--vv-section); }

/* ========== Node detail modal ========== */
.vv-modal { position: fixed; inset: 0; z-index: 2000; display: flex; align-items: center; justify-content: center; }
.vv-modal[hidden] { display: none; }
.vv-modal__backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.55); }
.vv-modal__box {
    position: relative;
    z-index: 1;
    background: var(--vv-card);
    border-radius: var(--vv-radius);
    box-shadow: 0 12px 40px rgba(63,39,18,.40);
    border: 1.5px solid var(--vv-card-border);
    display: flex;
    gap: 1.5rem;
    padding: 1.75rem;
    max-width: 540px;
    width: calc(100% - 2rem);
    max-height: 88vh;
    overflow-y: auto;
}
.vv-modal__close {
    position: absolute;
    top: .55rem;
    right: .75rem;
    background: none;
    border: none;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    color: var(--vv-brown-soft);
    padding: 0 .3rem;
}
.vv-modal__close:hover { color: var(--vv-brown-dark); }
.vv-modal__photo { flex: 0 0 110px; }
.vv-modal__photo img {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--vv-section);
    display: block;
}
.vv-modal__body { flex: 1 1 auto; min-width: 0; }
.vv-modal__name {
    font-family: var(--vv-serif);
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0 1.8rem .75rem 0;
    color: var(--vv-brown-dark);
}
.vv-modal__details {
    margin: 0;
    display: grid;
    grid-template-columns: auto 1fr;
    gap: .3rem .8rem;
    font-size: .875rem;
}
.vv-modal__details dt { font-weight: 600; color: var(--vv-brown-soft); white-space: nowrap; }
.vv-modal__details dd { margin: 0; color: var(--vv-text); word-break: break-word; }
/* "Update My Detail" / "Add Child" actions inside the modal */
.vv-modal__actions {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}
.vv-modal__actions .vv-btn { display: inline-block; }
.vv-modal__actions .vv-btn[hidden] { display: none; }
/* Family photo section inside the modal */
.vv-modal__family {
    margin-top: .9rem;
    padding-top: .75rem;
    border-top: 1px solid var(--vv-line);
}
.vv-modal__family-title {
    font-size: .75rem;
    font-weight: 700;
    color: var(--vv-brown-soft);
    text-transform: uppercase;
    letter-spacing: .06em;
    margin-bottom: .5rem;
}
.vv-modal__family-content { min-height: 1.5rem; }
.vv-modal__family-img {
    display: block;
    width: 100%;
    max-width: 380px;
    border-radius: 8px;
    border: 1.5px solid var(--vv-card-border);
}
.vv-modal__family-none { font-size: .85rem; color: var(--vv-text-soft); font-style: italic; margin: 0; }
@media (max-width: 480px) {
    .vv-modal__box { flex-direction: column; gap: 1rem; }
    .vv-modal__photo { flex: none; text-align: center; }
    .vv-modal__photo img { margin: 0 auto; }
}

/* ========== Footer ========== */
.vv-footer { background: var(--vv-brown-dark); color: #ecdcc4; font-size: 0.86rem; }
.vv-footer__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 20px 0;
    flex-wrap: wrap;
}
.vv-footer a { color: #f3e6d0; }
.vv-footer__links { display: flex; gap: 20px; flex-wrap: wrap; }

/* ========== Responsive ========== */
@media (max-width: 860px) {
    .vv-hero {
        aspect-ratio: auto;
        min-height: 0;
        background-image: url(assets/images/leaf-pattern.svg);
        background-position: center;
        background-size: 240px auto;
        display: block;
        padding: 30px 0 8px;
    }
    .vv-hero__copy { width: 100%; max-width: none; }
    .vv-hero__art-mobile {
        display: block;
        margin: 18px auto 6px;
        max-width: 460px;
    }
    .vv-cards { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
    .vv-header__inner { flex-direction: column; align-items: flex-start; }
    .vv-brand__img { height: 44px; }
    .vv-footer__inner { flex-direction: column; text-align: center; }
}

/* ========== Photo Gallery page ========== */
.vv-gallery-page .vv-container { padding-bottom: 60px; }

/* 75 / 25 row layout */
.vv-gallery-row {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 24px;
    align-items: start;
}

/* --- Add-image panel --- */
.vv-gallery-add { margin: 24px 0; }
.vv-gallery-add__form { margin-top: 16px; }

/* Upload area */
.vv-gallery-upload {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 320px;
    border: 2px dashed var(--vv-card-border);
    border-radius: var(--vv-radius);
    background: var(--vv-hero-cream);
    cursor: pointer;
    overflow: hidden;
    position: relative;
    transition: border-color .2s;
}
.vv-gallery-upload:hover { border-color: var(--vv-brown-soft); }
.vv-gallery-upload__input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    width: 100%;
    height: 100%;
}
.vv-gallery-upload__placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--vv-text-soft);
    padding: 24px;
    pointer-events: none;
}
.vv-gallery-upload__icon {
    width: 48px;
    height: 48px;
    color: var(--vv-card-border);
}
.vv-gallery-upload__text { font-size: 1rem; font-weight: 600; }
.vv-gallery-upload__sub  { font-size: .8rem; opacity: .75; }
.vv-gallery-upload__preview {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    max-height: 420px;
    pointer-events: none;
}

/* Detail fields (right column of add form) */
.vv-gallery-fields { display: flex; flex-direction: column; gap: 12px; }
.vv-gallery-fields__label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: .88rem;
    font-weight: 600;
    color: var(--vv-text);
}
.vv-gallery-fields__label .vv-input { font-size: .9rem; }
.vv-gallery-fields__actions { margin-top: 8px; }

/* Success notice add-another link */
.vv-gallery-notice__add {
    margin-left: 12px;
    font-weight: 600;
    color: var(--vv-brown-soft);
    text-decoration: underline;
}

/* --- Gallery list --- */
.vv-gallery-list { display: flex; flex-direction: column; gap: 28px; margin-top: 32px; }

.vv-gallery-row--item {
    padding: 20px 24px;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    box-shadow: var(--vv-shadow-sm);
}

.vv-gallery-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
    object-fit: cover;
}
.vv-gallery-img--empty {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    background: var(--vv-hero-cream);
    border-radius: 8px;
    color: var(--vv-text-soft);
    font-style: italic;
}

/* Detail text (right 25%) */
.vv-gallery-detail__title {
    margin: 0 0 6px;
    font-size: 1.1rem;
    font-family: var(--vv-serif);
    color: var(--vv-brown);
}
.vv-gallery-detail__caption {
    margin: 0 0 10px;
    font-size: .95rem;
    font-style: italic;
    color: var(--vv-text-soft);
}
.vv-gallery-detail__desc {
    margin: 0 0 12px;
    font-size: .88rem;
    line-height: 1.6;
    color: var(--vv-text);
}
.vv-gallery-detail__meta {
    margin: 0 0 6px;
    font-size: .83rem;
    color: var(--vv-text-soft);
}
.vv-gallery-detail__label { font-weight: 700; color: var(--vv-brown-soft); }

/* Delete button */
.vv-gallery-delete__form { margin-top: 18px; }
.vv-gallery-delete__btn  { padding: 7px 16px; font-size: .85rem; }

/* Responsive */
@media (max-width: 768px) {
    .vv-gallery-row { grid-template-columns: 1fr; }
    .vv-gallery-upload { min-height: 220px; }
}

/* ========== Vamsha Vaani posts page ========== */
/* 75 / 25 row layout (image | text). */
.vv-posts-row {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 24px;
    align-items: start;
}
/* No image → text uses the full width. */
.vv-posts-row--noimg { grid-template-columns: 1fr; }

/* --- Add-post panel --- */
.vv-posts-add { margin: 24px 0; }
.vv-posts-add__form { margin-top: 16px; }

/* Upload area (left 75%) */
.vv-posts-upload {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 320px;
    border: 2px dashed var(--vv-card-border);
    border-radius: var(--vv-radius);
    background: var(--vv-hero-cream);
    cursor: pointer;
    overflow: hidden;
    position: relative;
    transition: border-color .2s;
}
.vv-posts-upload:hover { border-color: var(--vv-brown-soft); }
.vv-posts-upload__input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    width: 100%;
    height: 100%;
}
.vv-posts-upload__placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--vv-text-soft);
    padding: 24px;
    pointer-events: none;
}
.vv-posts-upload__icon { width: 48px; height: 48px; color: var(--vv-card-border); }
.vv-posts-upload__text { font-size: 1rem; font-weight: 600; }
.vv-posts-upload__sub  { font-size: .8rem; opacity: .75; }
.vv-posts-upload__preview {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    max-height: 420px;
    pointer-events: none;
}

/* Detail fields (right 25% of add form) */
.vv-posts-row__detail { display: flex; flex-direction: column; gap: 12px; }
.vv-posts-fields__label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: .88rem;
    font-weight: 600;
    color: var(--vv-text);
}
.vv-posts-fields__label .vv-input { font-size: .9rem; }
.vv-posts-fields__label textarea.vv-input { resize: vertical; }
.vv-posts-fields__actions { margin-top: 8px; }

.vv-posts-notice__add {
    margin-left: 12px;
    font-weight: 600;
    color: var(--vv-brown-soft);
    text-decoration: underline;
}

/* --- Posts feed --- */
.vv-posts-list { display: flex; flex-direction: column; gap: 28px; margin-top: 32px; }
.vv-posts-row--item {
    padding: 20px 24px;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    box-shadow: var(--vv-shadow-sm);
}
.vv-posts-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 8px;
    object-fit: cover;
}
.vv-posts-detail__title {
    margin: 0 0 8px;
    font-size: 1.2rem;
    font-family: var(--vv-serif);
    color: var(--vv-brown);
}
.vv-posts-detail__content {
    font-size: .95rem;
    line-height: 1.7;
    color: var(--vv-text);
    white-space: pre-wrap;
    word-wrap: break-word;
}
.vv-posts-detail__meta {
    margin: 12px 0 0;
    font-size: .82rem;
    color: var(--vv-text-soft);
}
.vv-posts-delete__form { margin-top: 14px; }
.vv-posts-delete__btn  { padding: 7px 16px; font-size: .85rem; }

@media (max-width: 768px) {
    .vv-posts-row { grid-template-columns: 1fr; }
    .vv-posts-upload { min-height: 220px; }
}

/* ========== Family post pages (per Family Tree tab) ========== */
/* Each post is its own row: image on top, detail below. New posts stack
   below the previous one (not side by side). */
.vv-family-posts-add { margin: 24px 0; }
.vv-family-posts-add__form { margin-top: 16px; }

.vv-family-posts-grid {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-top: 32px;
}
.vv-family-post-card {
    width: 100%;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    box-shadow: var(--vv-shadow-sm);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
/* Original size, centered — never stretched to fill the card width.
   Only rendered at all when the post actually has an image. */
.vv-family-post-card__img {
    display: flex;
    justify-content: center;
}
.vv-family-post-card__photo {
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
}
.vv-family-post-card--add .vv-posts-upload { min-height: 220px; }
.vv-family-post-card__body {
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
/* Only the block right after the image gets a divider above it. */
.vv-family-post-card__body--divider { border-top: 1px solid var(--vv-card-border); }
.vv-family-post-card--add .vv-family-post-card__body { gap: 12px; }
.vv-family-post-card__title {
    margin: 0;
    font-size: 1.1rem;
    font-family: var(--vv-serif);
    color: var(--vv-brown);
}
.vv-family-post-card__content {
    font-size: .9rem;
    line-height: 1.6;
    color: var(--vv-text);
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Edit + Delete side by side; the edit form drops to its own full-width
   line underneath once opened. */
.vv-family-post-card__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 10px;
    margin-top: 8px;
}
.vv-family-post-card__actions .vv-posts-delete__form { margin-top: 0; }

.vv-family-post-edit { flex: 0 0 auto; }
.vv-family-post-edit[open] { flex-basis: 100%; }
.vv-family-post-edit__btn { padding: 7px 16px; font-size: .85rem; }
.vv-family-post-edit__btn::-webkit-details-marker { display: none; }
.vv-family-post-edit__btn::marker { content: ''; }

.vv-family-post-edit__form {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px;
    max-width: 420px;
    background: var(--vv-hero-cream);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
}
.vv-family-post-edit__current { display: flex; align-items: center; gap: 10px; }
.vv-family-post-edit__thumb {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid var(--vv-card-border);
}
.vv-family-post-edit__remove {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: .82rem;
    color: var(--vv-text-soft);
}

/* ========== Contact Us page ========== */
.vv-contact-add { margin: 24px 0; }
.vv-contact-add__form {
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    max-width: 480px;
}

/* Read-only list: 2 columns, as many rows as needed. */
.vv-contact-grid {
    margin-top: 28px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}
.vv-contact-card {
    padding: 20px 24px;
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    box-shadow: var(--vv-shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.vv-contact-card__name {
    margin: 0;
    font-size: 1.15rem;
    font-family: var(--vv-serif);
    color: var(--vv-brown);
}
.vv-contact-card__row {
    margin: 0;
    font-size: .92rem;
    line-height: 1.6;
    color: var(--vv-text);
}
.vv-contact-card__label {
    display: block;
    font-size: .76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: var(--vv-brown-soft);
    margin-bottom: 2px;
}

.vv-contact-card__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 10px;
    margin-top: 4px;
}
.vv-contact-card__actions .vv-posts-delete__form { margin-top: 0; }
.vv-contact-edit { flex: 0 0 auto; }
.vv-contact-edit[open] { flex-basis: 100%; }
.vv-contact-edit__btn { padding: 7px 16px; font-size: .85rem; }
.vv-contact-edit__btn::-webkit-details-marker { display: none; }
.vv-contact-edit__btn::marker { content: ''; }
.vv-contact-edit__form {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px;
    background: var(--vv-hero-cream);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
}

@media (max-width: 640px) {
    .vv-contact-grid { grid-template-columns: 1fr; }
}

/* ========== Events page — ದಿನವಾಣಿ / ನಿತ್ಯ ಪಂಚಾಂಗ ========== */
.vv-dinavani,
.vv-panchanga__row,
.vv-panchanga__cell,
.vv-panchanga__label,
.vv-panchanga__value,
.vv-panchanga__unavail {
    font-family: 'Noto Sans Kannada', 'Nirmala UI', 'Tunga', sans-serif;
}
.vv-dinavani__title,
.vv-dinavani__sub {
    font-family: 'Noto Serif Kannada', 'Nirmala UI', serif;
}

.vv-dinavani {
    margin: 36px 0 48px;
    text-align: center;
}

.vv-dinavani__title {
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--vv-brown);
    margin: 0 0 10px;
    letter-spacing: .03em;
}

.vv-dinavani__divider {
    width: 180px;
    color: var(--vv-orange);
    display: block;
    margin: 0 auto 10px;
}

.vv-dinavani__sub {
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--vv-brown-soft);
    margin: 0 0 16px;
    letter-spacing: .02em;
    text-align: left;         /* left-justified as requested */
}

/* ---- Admin: sync CSV button ---- */
.vv-sync-form  { display: inline-block; margin: 16px 0; }
.vv-sync-btn   { padding: 10px 28px; }


/* ---- Two-column dinavani layout ---- */
.vv-dinavani__cols {
    display: flex;
    gap: 52px;
    align-items: flex-start;
}
.vv-dinavani__left  { flex-shrink: 0; }
.vv-dinavani__right { flex-shrink: 0; }

/* ---- ಮುಂದಿನ ಏಕಾದಶಿ ---- */
.vv-dinavani__ekadashi-title {
    font-family: 'Noto Serif Kannada', 'Nirmala UI', serif;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--vv-brown-soft);
    margin: 0 0 10px;
    letter-spacing: .02em;
}
.vv-dinavani__ekadashi-vaara {
    font-family: 'Noto Sans Kannada', 'Nirmala UI', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    color: var(--vv-brown);
    margin: 0 0 4px;
}
.vv-dinavani__ekadashi-date {
    font-family: 'Noto Sans Kannada', 'Nirmala UI', sans-serif;
    font-size: .95rem;
    color: var(--vv-text);
    margin: 0;
}
.vv-dinavani__ekadashi-na {
    font-size: .9rem;
    color: var(--vv-text-soft);
    font-style: italic;
    margin: 0;
}

@media (max-width: 600px) {
    .vv-dinavani__cols { flex-direction: column; gap: 28px; }
}

/* ---- Birthday section ---- */
.vv-bday {
    margin-top: 48px;
    padding-top: 36px;
    border-top: 2px solid #f0e0c8;
}
.vv-bday__header {
    text-align: center;
    margin-bottom: 32px;
}
.vv-bday__cake {
    font-size: 1.25rem;
    font-weight: 700;
    color: #b5451b;
    margin: 0 0 6px;
    letter-spacing: .03em;
}
.vv-bday__title {
    font-family: 'Noto Serif Kannada', serif;
    font-size: 1.85rem;
    font-weight: 700;
    color: #2c2c2c;
    margin: 0 0 10px;
}
.vv-bday__shloka {
    font-style: italic;
    font-size: .98rem;
    color: #666;
    margin: 0;
    line-height: 1.7;
}
.vv-bday__card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    background: #fdf8f2;
    border: 1px solid #f0e0c8;
    border-radius: 10px;
    padding: 28px 32px;
    margin-bottom: 24px;
}
.vv-bday__left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    text-align: center;
}
.vv-bday__photo {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid #e8a04e;
    box-shadow: 0 2px 10px rgba(0,0,0,.12);
}
.vv-bday__name {
    font-family: 'Noto Serif Kannada', serif;
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0;
    color: #2c2c2c;
}
.vv-bday__relation {
    font-size: .92rem;
    color: #555;
    margin: 0;
}
.vv-bday__address {
    font-size: .88rem;
    color: #888;
    margin: 0;
}
.vv-bday__right {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.vv-bday__tagline {
    font-family: 'Noto Serif Kannada', serif;
    font-size: 1.1rem;
    color: #7a3b10;
    text-align: center;
    line-height: 1.8;
    margin: 0;
}
@media (max-width: 640px) {
    .vv-bday__card { grid-template-columns: 1fr; gap: 24px; padding: 20px; }
    .vv-bday__right { padding: 0; }
}

/* ---- CSV Import / Export panel ---- */
.vv-csv__layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    margin-top: 18px;
}
.vv-csv__box {
    background: #f8f8f8;
    border: 1px solid #e0e0e0;
    border-radius: 7px;
    padding: 20px 22px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.vv-csv__box-title {
    font-size: 1rem;
    font-weight: 700;
    margin: 0;
    color: #2c2c2c;
}
.vv-csv__box-desc {
    font-size: .87rem;
    color: #666;
    margin: 0;
    line-height: 1.55;
}
.vv-csv__export-form,
.vv-csv__import-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.vv-csv__fname-label {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.vv-csv__fname-text {
    font-size: .82rem;
    font-weight: 600;
    color: #555;
}
.vv-csv__fname-input {
    font-family: monospace;
    font-size: .9rem;
}
.vv-csv__file-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.vv-csv__file-input {
    font-size: .88rem;
    max-width: 100%;
}
@media (max-width: 600px) {
    .vv-csv__layout { grid-template-columns: 1fr; }
}

/* ---- Panchanga vertical list (plain text, no box) ---- */
.vv-panchanga { max-width: 400px; }

.vv-panchanga__row { display: block; }

.vv-panchanga__cell {
    display: flex;
    flex-direction: row;
    align-items: baseline;
    padding: 5px 0;
    gap: 8px;
    text-align: left;
}

.vv-panchanga__label {
    font-size: .95rem;
    font-weight: 700;
    color: var(--vv-brown-soft);
    min-width: 120px;
    flex-shrink: 0;
}
.vv-panchanga__label::after { content: ' -'; font-weight: 400; }

.vv-panchanga__value {
    font-size: .95rem;
    font-weight: 400;
    color: var(--vv-text);
}

.vv-panchanga__unavail {
    font-size: .95rem;
    color: var(--vv-text-soft);
    font-style: italic;
    text-align: left;
}

@media (max-width: 480px) {
    .vv-dinavani__title { font-size: 1.8rem; }
    .vv-dinavani__sub   { font-size: 1.1rem; }
}

/* Login History (admin only) */
.vv-badge--danger { background: #f6dcd0; color: #7a3b1c; }

.vv-lh-section__title { font-family: var(--vv-serif); color: var(--vv-brown-dark); font-size: 1.2rem; margin: 28px 0 12px; }

.vv-lh-stats { display: flex; gap: 16px; margin: 20px 0; flex-wrap: wrap; }
.vv-lh-stat {
    background: var(--vv-card);
    border: 1px solid var(--vv-card-border);
    border-radius: var(--vv-radius);
    padding: 14px 22px;
    box-shadow: var(--vv-shadow-sm);
    display: flex;
    flex-direction: column;
    min-width: 160px;
}
.vv-lh-stat__num { font-family: var(--vv-serif); font-size: 1.8rem; color: var(--vv-brown-dark); line-height: 1.2; }
.vv-lh-stat__label { color: var(--vv-text-soft); font-size: 0.85rem; }
.vv-lh-stat--danger .vv-lh-stat__num { color: #a83e1b; }

.vv-lh-alert {
    background: #f6dcd0;
    border: 1px solid #d99a78;
    border-radius: var(--vv-radius);
    padding: 16px 20px;
    color: #7a3b1c;
    margin-bottom: 20px;
}
.vv-lh-alert p { margin: 6px 0; }
.vv-lh-alert ul { margin: 8px 0 0; padding-left: 20px; }
.vv-lh-alert code { background: rgba(0,0,0,0.06); padding: 1px 6px; border-radius: 4px; }

.vv-lh-filters { display: flex; gap: 8px; margin-bottom: 16px; }
.vv-lh-filter {
    padding: 6px 16px;
    border-radius: 999px;
    border: 1px solid var(--vv-card-border);
    color: var(--vv-brown-soft);
    font-size: 0.9rem;
    text-decoration: none;
}
.vv-lh-filter.is-active { background: var(--vv-brown-dark); border-color: var(--vv-brown-dark); color: #fff; }

.vv-lh-table-wrap { overflow-x: auto; background: var(--vv-card); border: 1px solid var(--vv-card-border); border-radius: var(--vv-radius); box-shadow: var(--vv-shadow-sm); }
.vv-lh-table { width: 100%; border-collapse: collapse; }
.vv-lh-table th, .vv-lh-table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid rgba(122,74,35,0.16); font-size: 0.9rem; vertical-align: top; white-space: nowrap; }
.vv-lh-table thead th { background: rgba(122,74,35,0.10); color: var(--vv-brown-dark); font-family: var(--vv-serif); }
.vv-lh-table tbody tr:last-child td { border-bottom: none; }
.vv-lh-uid { color: var(--vv-text-soft); font-size: 0.8rem; }
.vv-lh-reason { color: var(--vv-text-soft); font-size: 0.78rem; font-style: italic; white-space: normal; max-width: 260px; margin-top: 2px; }

.vv-lh-pager { display: flex; align-items: center; gap: 16px; justify-content: center; margin: 20px 0; }
.vv-lh-pager a { color: var(--vv-brown-soft); font-weight: 600; text-decoration: none; }
.vv-lh-pager__pos { color: var(--vv-text-soft); font-size: 0.9rem; }

@media (max-width: 640px) {
    .vv-lh-table th, .vv-lh-table td { white-space: normal; }
}
