/* ============================================================
   TEMA: SAGE
   Sereno, natural, confiable — verde salvia + piedra caliza + oliva suave
   Para notarías en ciudades con arraigo regional, imagen acogedora
   ============================================================ */

body.theme-sage {
    --theme-sans-family: "Archivo", "Segoe UI Variable Text", "Segoe UI", sans-serif;
    --theme-serif-family: "Lora", "Georgia", serif;
    --ink: #1a2416;
    --ink-soft: #526047;
    --line: #d0dac8;
    --line-strong: #beccb4;
    --paper: #f2f6ee;
    --paper-deep: #e6eee0;
    --panel: #fafdfa;
    --panel-soft: #f4f8f0;
    --brand: #3a6644;
    --brand-deep: #264530;
    --brand-soft: #deeedd;
    --accent: #7a9a50;
    --accent-soft: #e8f0d8;
    --sage-stone: #7a8a72;
    --sage-warm: #a08060;
    --shadow-soft: 0 20px 48px rgba(26, 36, 22, 0.09);
    --shadow-card: 0 12px 28px rgba(26, 36, 22, 0.07);
    --radius-lg: 1.1rem;
    --radius-md: 0.8rem;
    --radius-sm: 0.6rem;
    background:
        radial-gradient(ellipse at top left, rgba(58, 102, 68, 0.06), transparent 30%),
        radial-gradient(ellipse at bottom right, rgba(122, 154, 80, 0.05), transparent 30%),
        linear-gradient(180deg, #f6faf2 0%, var(--paper) 52%, #e2ecda 100%);
}

/* ── Topbar ── */
body.theme-sage .public-topbar {
    background: linear-gradient(90deg, var(--brand-deep), var(--brand) 70%, #4a7a55);
}

/* ── Navbar ── */
body.theme-sage .sage-header {
    background: rgba(250, 253, 250, 0.96);
    border-bottom: 2px solid var(--brand-soft);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 16px rgba(26, 36, 22, 0.07);
}

body.theme-sage .sage-nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 0;
    gap: 1.5rem;
}

body.theme-sage .sage-brand {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    text-decoration: none;
    color: inherit;
}

body.theme-sage .sage-brand-leaf {
    width: 46px;
    height: 46px;
    border-radius: 0.8rem;
    background: linear-gradient(140deg, var(--brand), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--theme-serif-family);
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(58, 102, 68, 0.25);
}

body.theme-sage .sage-brand-leaf img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 0.6rem;
}

body.theme-sage .sage-brand-text {
    display: flex;
    flex-direction: column;
    gap: 0.05rem;
}

body.theme-sage .sage-brand-text strong {
    font-family: var(--theme-serif-family);
    font-size: 1.05rem;
    color: var(--brand-deep);
    line-height: 1.2;
}

body.theme-sage .sage-brand-text small {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--sage-stone);
    text-transform: uppercase;
    letter-spacing: 0.09em;
}

body.theme-sage .sage-nav-list {
    display: flex;
    align-items: center;
    gap: 0.15rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

body.theme-sage .sage-nav-list .nav-link {
    font-size: 0.87rem;
    font-weight: 700;
    color: var(--ink-soft);
    padding: 0.4rem 0.75rem;
    border-radius: 0.55rem;
    transition: background 0.15s, color 0.15s;
}

body.theme-sage .sage-nav-list .nav-link:hover {
    background: var(--brand-soft);
    color: var(--brand-deep);
}

body.theme-sage .sage-nav-list .nav-link.active {
    background: var(--brand);
    color: #fff;
}

/* ── Hero sage ── */
body.theme-sage .sage-hero {
    padding: 1.5rem 0 1rem;
}

body.theme-sage .sage-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1.1rem;
    align-items: stretch;
}

body.theme-sage .sage-hero-content {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 1.1rem;
    padding: 2rem 1.8rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    box-shadow: var(--shadow-card);
    border-left: 4px solid var(--brand);
}

body.theme-sage .sage-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.2rem 0.7rem;
    background: var(--brand-soft);
    border-radius: 0.5rem;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--brand-deep);
    width: fit-content;
}

body.theme-sage .sage-hero-content h1 {
    margin: 0;
    font-family: var(--theme-serif-family);
    font-size: clamp(2rem, 3.5vw, 3.2rem);
    line-height: 1.06;
    color: var(--brand-deep);
}

body.theme-sage .sage-hero-subtitle {
    margin: 0;
    color: var(--accent);
    font-weight: 700;
}

body.theme-sage .sage-hero-desc {
    margin: 0;
    color: var(--ink-soft);
    font-size: 0.95rem;
    line-height: 1.72;
    flex: 1;
}

body.theme-sage .sage-hero-actions {
    display: flex;
    gap: 0.65rem;
    flex-wrap: wrap;
}

body.theme-sage .sage-hero-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
    padding-top: 1rem;
    border-top: 1px solid var(--line);
}

body.theme-sage .sage-hero-meta dt {
    font-size: 0.67rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--sage-stone);
    margin-bottom: 0.2rem;
}

body.theme-sage .sage-hero-meta dd {
    margin: 0;
    font-size: 0.88rem;
    color: var(--ink);
    line-height: 1.4;
    font-weight: 600;
}

body.theme-sage .sage-hero-media-col {
    display: grid;
    grid-template-rows: 1fr auto;
    gap: 1rem;
}

body.theme-sage .sage-hero-image {
    border-radius: 1.1rem;
    overflow: hidden;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-card);
}

body.theme-sage .sage-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

body.theme-sage .sage-hero-image-fallback {
    min-height: 280px;
    background: linear-gradient(145deg, #c8dfbe 0%, #a8c89a 45%, #80aa70 100%);
}

body.theme-sage .sage-hero-links {
    background: var(--brand-soft);
    border: 1px solid var(--line);
    border-radius: 0.9rem;
    padding: 1rem 1.2rem;
}

body.theme-sage .sage-hero-links-title {
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--brand-deep);
    margin-bottom: 0.6rem;
}

body.theme-sage .sage-hero-links ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

body.theme-sage .sage-hero-links a {
    color: var(--brand-deep);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 0.25rem 0.65rem;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 0.45rem;
    transition: background 0.15s;
}

body.theme-sage .sage-hero-links a:hover {
    background: var(--brand-soft);
}

/* ── Footer sage ── */
body.theme-sage .site-footer {
    background:
        radial-gradient(circle at bottom left, rgba(58, 102, 68, 0.1), transparent 28%),
        linear-gradient(180deg, #f4f8f0 0%, #e2ecda 100%);
    border-top: 3px solid var(--brand);
}

body.theme-sage .sage-footer {
    padding-top: 2.5rem;
}

body.theme-sage .sage-footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) repeat(3, minmax(0, 1fr));
    gap: 2rem;
    padding-bottom: 1.8rem;
    border-bottom: 1px solid var(--line-strong);
}

body.theme-sage .sage-footer-leaf {
    width: 48px;
    height: 48px;
    border-radius: 0.8rem;
    background: linear-gradient(140deg, var(--brand), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--theme-serif-family);
    font-size: 1.4rem;
    color: #fff;
    margin-bottom: 0.9rem;
}

body.theme-sage .sage-footer-leaf img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 0.6rem;
}

body.theme-sage .sage-footer h2 {
    font-family: var(--theme-serif-family);
    font-size: 1.3rem;
    color: var(--brand-deep);
    margin: 0 0 0.4rem;
}

body.theme-sage .sage-footer-desc {
    font-size: 0.9rem;
    color: var(--ink-soft);
    margin: 0;
    line-height: 1.65;
}

body.theme-sage .sage-footer-col h3 {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--brand);
    margin: 0 0 0.8rem;
}

body.theme-sage .sage-footer-col ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 0.5rem;
}

body.theme-sage .sage-footer-col a {
    color: var(--ink-soft);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 600;
    transition: color 0.15s;
}

body.theme-sage .sage-footer-col a:hover {
    color: var(--brand-deep);
}

body.theme-sage .sage-footer-col li {
    font-size: 0.88rem;
    color: var(--ink-soft);
}

body.theme-sage .sage-footer-bottom {
    padding: 1rem 0;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    font-size: 0.8rem;
    color: var(--sage-stone);
    flex-wrap: wrap;
}

/* ── Responsive ── */
@media (max-width: 991px) {
    body.theme-sage .sage-hero-grid {
        grid-template-columns: 1fr;
    }
    body.theme-sage .sage-footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 767px) {
    body.theme-sage .sage-hero-meta {
        grid-template-columns: 1fr;
    }
    body.theme-sage .sage-footer-grid {
        grid-template-columns: 1fr;
    }
}
