/*
Theme Name:  Dhamma Training Center
Theme URI:   https://dhammatrainingcenter.org
Author:      Dhamma Training Center
Author URI:  https://dhammatrainingcenter.org
Description: A sacred, culturally rich WordPress theme for the Dhamma Training Center — Abhidhamma & Paṭṭhāna studies. Refined editorial design with muted amber palette and contemplative atmosphere.
Version:     1.1.0
Requires at least: 6.0
Tested up to:  6.5
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: dtc
Tags:        buddhism, meditation, spiritual, custom-menu, featured-images, translation-ready
*/

/* ============================================================
   DESIGN TOKENS — Muted, editorial, contemplative
   ============================================================ */
:root {
    /* Surfaces */
    --bg-base:        #0f0d0c;
    --bg-raised:      #151210;
    --bg-card:        #1b1714;
    --bg-card-hover:  #201a16;

    /* Amber — muted, sophisticated */
    --amber:          #b8873a;
    --amber-dim:      #8a6428;
    --amber-bright:   #d4a855;
    --amber-glow:     rgba(184,135,58,0.1);
    --amber-border:   rgba(184,135,58,0.2);
    --amber-strong:   rgba(184,135,58,0.32);

    /* Rose-maroon — subdued */
    --rose:           #7a2e2e;
    --rose-dim:       #4e1e1e;

    /* Neutrals */
    --sand:           #c4b49a;
    --sand-dim:       #7a6c5e;
    --cream:          #f0e8d4;
    --cream-dim:      #e0d4bc;

    /* Text */
    --text-primary:   #e8dccb;
    --text-secondary: rgba(232,220,203,0.58);
    --text-muted:     rgba(196,180,154,0.38);

    /* Borders & shadows */
    --border:         rgba(184,135,58,0.16);
    --border-strong:  rgba(184,135,58,0.28);
    --shadow-sm:      0 2px 12px rgba(0,0,0,0.28);
    --shadow-md:      0 6px 32px rgba(0,0,0,0.44);
    --shadow-lg:      0 16px 60px rgba(0,0,0,0.6);

    /* Typography */
    --font-display:   'Cinzel', 'Palatino Linotype', Georgia, serif;
    --font-editorial: 'IM Fell English', 'Cormorant Garamond', Georgia, serif;
    --font-body:      'Cormorant Garamond', Georgia, 'Times New Roman', serif;
    --font-pali:      'Noto Serif', Georgia, serif;

    /* Motion */
    --ease:     cubic-bezier(0.4,0,0.2,1);
    --ease-out: cubic-bezier(0,0,0.2,1);
    --fast:     0.18s;
    --base:     0.28s;
    --slow:     0.46s;
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--font-body);
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-primary);
    background-color: var(--bg-base);
    overflow-x: hidden;
}

/* Subtle atmospheric background */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(ellipse 100% 45% at 50% 0%,   rgba(184,135,58,0.055) 0%, transparent 60%),
        radial-gradient(ellipse 55%  65% at 0%   100%, rgba(122,46,46,0.16)  0%, transparent 55%),
        var(--bg-base);
    pointer-events: none;
}

img { max-width: 100%; height: auto; display: block; }
a   { color: var(--amber); text-decoration: none; transition: color var(--base) var(--ease); }
a:hover { color: var(--amber-bright); }
p   { margin-bottom: 1.4em; }
ul, ol { padding-left: 1.5em; margin-bottom: 1.4em; }
blockquote {
    border-left: 2px solid var(--amber-border);
    padding-left: 1.4em;
    font-style: italic;
    color: var(--text-secondary);
    margin: 2em 0;
}
hr { border: none; border-top: 1px solid var(--border); margin: 2.5em 0; }

h1,h2,h3,h4,h5,h6 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.2;
    color: var(--cream);
    margin-bottom: 0.75em;
}
h1 { font-size: clamp(2rem,4vw,3.2rem); }
h2 { font-size: clamp(1.5rem,3vw,2.2rem); }
h3 { font-size: 1.4rem; }
h4 { font-size: 1.15rem; }

::-webkit-scrollbar       { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg-base); }
::-webkit-scrollbar-thumb { background: var(--rose-dim); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--amber-dim); }

/* ============================================================
   ACCESSIBILITY
   ============================================================ */
.skip-link {
    position: absolute;
    top: -100%; left: 10px;
    background: var(--amber-bright);
    color: var(--bg-base);
    font-family: var(--font-display);
    font-size: 0.7rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    padding: 10px 20px;
    z-index: 9999;
    transition: top 0.2s;
}
.skip-link:focus { top: 10px; }

/* ============================================================
   HEADER — frosted, minimal
   ============================================================ */
#masthead {
    position: sticky;
    top: 0;
    z-index: 500;
    background: rgba(15,13,12,0.86);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(24px) saturate(1.5);
    -webkit-backdrop-filter: blur(24px) saturate(1.5);
    transition: background var(--slow) var(--ease), box-shadow var(--slow) var(--ease);
}
#masthead.scrolled {
    background: rgba(13,11,10,0.97);
    box-shadow: 0 1px 0 var(--border), 0 4px 40px rgba(0,0,0,0.5);
}

.header-shimmer {
    height: 1px;
    background: linear-gradient(90deg,
        transparent 0%, var(--amber-dim) 25%,
        var(--amber-bright) 50%, var(--amber-dim) 75%, transparent 100%);
    opacity: 0.65;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: 72px;
    padding: 0 48px;
    max-width: 1360px;
    margin: 0 auto;
}

.site-branding {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
    text-decoration: none;
}
.site-logo-emblem { width: 46px; height: 46px; opacity: 0.88; flex-shrink: 0; }
.site-branding-text { display: flex; flex-direction: column; line-height: 1; }
.site-title {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 600;
    color: var(--cream-dim);
    letter-spacing: 0.06em;
    margin: 0;
}
.site-title a { color: inherit; }
.site-title a:hover { color: var(--amber-bright); }
.site-description {
    font-family: var(--font-body);
    font-style: italic;
    font-size: 0.68rem;
    color: var(--sand-dim);
    letter-spacing: 0.1em;
    margin-top: 4px;
}
.site-pali {
    font-family: var(--font-pali);
    font-size: 0.63rem;
    color: var(--amber-dim);
    letter-spacing: 0.04em;
    margin-top: 3px;
}

#site-navigation { display: flex; align-items: center; gap: 12px; }

.lotus-menu {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0; padding: 0; margin: 0;
}
.lotus-menu li { position: relative; }
.lotus-menu li + li::before {
    content: '·';
    position: absolute;
    left: 0; top: 50%;
    transform: translateY(-50%);
    color: var(--sand-dim);
    font-size: 0.85rem;
    opacity: 0.25;
    pointer-events: none;
}
.lotus-menu a {
    display: block;
    padding: 8px 16px;
    font-family: var(--font-display);
    font-size: 0.63rem;
    font-weight: 500;
    color: var(--sand-dim);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    position: relative;
    white-space: nowrap;
    transition: color var(--base) var(--ease);
}
.lotus-menu a::after {
    content: '';
    position: absolute;
    bottom: 3px; left: 16px; right: 16px;
    height: 1px;
    background: var(--amber);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--base) var(--ease);
}
.lotus-menu a:hover { color: var(--cream-dim); }
.lotus-menu a:hover::after { transform: scaleX(1); }
.lotus-menu .current-menu-item > a,
.lotus-menu .current_page_item > a { color: var(--amber-bright); }
.lotus-menu .current-menu-item > a::after,
.lotus-menu .current_page_item > a::after { transform: scaleX(1); }

.lotus-menu .sub-menu {
    position: absolute;
    top: calc(100% + 8px); left: 0;
    min-width: 198px;
    background: rgba(20,16,14,0.97);
    border: 1px solid var(--border);
    border-top: 1px solid var(--amber-dim);
    box-shadow: var(--shadow-md);
    list-style: none;
    padding: 5px 0;
    opacity: 0; visibility: hidden;
    transform: translateY(6px);
    transition: opacity var(--base) var(--ease), transform var(--base) var(--ease), visibility var(--base);
    z-index: 200;
    backdrop-filter: blur(16px);
}
.lotus-menu li:hover > .sub-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.lotus-menu .sub-menu li::before { display: none; }
.lotus-menu .sub-menu a { font-size: 0.62rem; color: var(--sand-dim); padding: 9px 16px; }
.lotus-menu .sub-menu a:hover { color: var(--cream-dim); background: rgba(184,135,58,0.06); }
.lotus-menu .sub-menu a::after { display: none; }

.btn-dana {
    display: inline-block;
    padding: 8px 18px;
    font-family: var(--font-display);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--bg-base) !important;
    background: var(--amber);
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none !important;
    flex-shrink: 0;
    transition: background var(--base) var(--ease);
}
.btn-dana:hover { background: var(--amber-bright); color: var(--bg-base) !important; }

.menu-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--amber-dim);
    padding: 7px 11px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background var(--base) var(--ease);
}
.menu-toggle:hover { background: var(--amber-glow); }

/* ============================================================
   HERO — Spacious, atmospheric, editorial
   ============================================================ */
.hero-banner {
    position: relative;
    min-height: 91vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 75% 65% at 25% 55%, rgba(122,46,46,0.1) 0%, transparent 58%),
        radial-gradient(ellipse 55% 80% at 88% 20%, rgba(184,135,58,0.05) 0%, transparent 52%),
        linear-gradient(180deg, rgba(15,13,12,0.15) 0%, rgba(15,13,12,0.38) 100%);
    z-index: 0;
}

.dhammajak-watermark {
    position: absolute;
    right: -2%; top: 50%;
    transform: translateY(-50%);
    width: min(560px,50vw); height: min(560px,50vw);
    opacity: 0.038;
    animation: slowRotate 120s linear infinite;
    z-index: 0; pointer-events: none;
}
.lotus-bg-watermark {
    position: absolute;
    left: -40px; bottom: -30px;
    width: 340px; height: 340px;
    opacity: 0.03;
    animation: slowRotate 90s linear infinite reverse;
    z-index: 0; pointer-events: none;
}
@keyframes slowRotate {
    from { transform: translateY(-50%) rotate(0deg); }
    to   { transform: translateY(-50%) rotate(360deg); }
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 1360px;
    margin: 0 auto;
    padding: 120px 48px 100px;
    display: grid;
    grid-template-columns: 1fr 410px;
    gap: 72px;
    align-items: center;
    width: 100%;
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}
.hero-kicker    { animation: fadeUp 0.9s var(--ease-out) 0.15s both; }
.hero-title     { animation: fadeUp 0.9s var(--ease-out) 0.28s both; }
.hero-pali-line { animation: fadeUp 0.9s var(--ease-out) 0.42s both; }
.hero-lead      { animation: fadeUp 0.9s var(--ease-out) 0.54s both; }
.hero-actions   { animation: fadeUp 0.9s var(--ease-out) 0.66s both; }
.hero-card      { animation: fadeUp 0.9s var(--ease-out) 0.38s both; }

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-display);
    font-size: 0.59rem;
    font-weight: 500;
    letter-spacing: 0.38em;
    text-transform: uppercase;
    color: var(--amber-dim);
    margin-bottom: 28px;
    opacity: 0.85;
}
.hero-eyebrow::before, .hero-eyebrow::after {
    content: '';
    display: block;
    width: 20px; height: 1px;
    background: var(--amber-dim);
    opacity: 0.55;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.7rem,5vw,4.6rem);
    font-weight: 600;
    color: var(--cream);
    line-height: 1.06;
    letter-spacing: 0.01em;
    margin-bottom: 14px;
}
.hero-title .subtitle-italic {
    display: block;
    font-family: var(--font-editorial);
    font-style: italic;
    font-weight: 400;
    font-size: 0.7em;
    color: var(--amber);
    letter-spacing: 0.03em;
    margin-top: 8px;
    opacity: 0.82;
}

.hero-pali-line {
    font-family: var(--font-pali);
    font-style: italic;
    font-size: 0.86rem;
    color: var(--sand-dim);
    letter-spacing: 0.05em;
    margin-bottom: 26px;
}

.hero-lead {
    font-size: 1.06rem;
    line-height: 1.9;
    color: var(--text-secondary);
    max-width: 520px;
    margin-bottom: 46px;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }

.btn-primary {
    display: inline-block;
    padding: 12px 32px;
    font-family: var(--font-display);
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--bg-base) !important;
    background: var(--amber);
    text-decoration: none !important;
    border: 1px solid transparent;
    transition: background var(--base) var(--ease), box-shadow var(--base) var(--ease), transform var(--fast) var(--ease);
}
.btn-primary:hover {
    background: var(--amber-bright);
    box-shadow: 0 4px 24px rgba(184,135,58,0.22);
    transform: translateY(-1px);
    color: var(--bg-base) !important;
}

.btn-outline {
    display: inline-block;
    padding: 11px 30px;
    font-family: var(--font-display);
    font-size: 0.66rem;
    font-weight: 500;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--amber) !important;
    text-decoration: none !important;
    border: 1px solid var(--border-strong);
    transition: border-color var(--base) var(--ease), background var(--base) var(--ease), color var(--base) var(--ease);
}
.btn-outline:hover {
    background: var(--amber-glow);
    border-color: var(--amber);
    color: var(--amber-bright) !important;
}

.hero-card {
    position: relative;
    background: rgba(27,23,20,0.78);
    border: 1px solid var(--border);
    padding: 30px;
    backdrop-filter: blur(14px);
    box-shadow: var(--shadow-md), inset 0 1px 0 rgba(184,135,58,0.07);
}
.hero-card::before, .hero-card::after {
    content: '';
    position: absolute;
    width: 18px; height: 18px;
    border-color: var(--amber-dim);
    border-style: solid;
    opacity: 0.45;
}
.hero-card::before { top: 8px; left: 8px; border-width: 1px 0 0 1px; }
.hero-card::after  { bottom: 8px; right: 8px; border-width: 0 1px 1px 0; }

.hero-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}
.hero-card-icon {
    width: 36px; height: 36px;
    background: var(--amber-glow);
    border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    font-size: 1rem;
    color: var(--amber);
    flex-shrink: 0;
}
.hero-card-title {
    font-family: var(--font-display);
    font-size: 0.64rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    color: var(--amber);
    text-transform: uppercase;
}
.hero-card-sub { font-style: italic; font-size: 0.7rem; color: var(--sand-dim); margin-top: 2px; }

.hero-card-list { list-style: none; padding: 0; margin: 0; }
.hero-card-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 7px 0;
    border-bottom: 1px solid rgba(184,135,58,0.07);
    font-size: 0.83rem;
    color: var(--text-secondary);
    line-height: 1.55;
}
.hero-card-list li:last-child { border-bottom: none; }
.hero-card-list .bullet { color: var(--amber-dim); font-size: 0.48rem; margin-top: 5px; flex-shrink: 0; }

.hero-card-cta {
    display: block;
    margin-top: 20px;
    padding: 11px;
    text-align: center;
    font-family: var(--font-display);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--bg-base) !important;
    background: var(--amber);
    text-decoration: none !important;
    transition: background var(--base) var(--ease);
}
.hero-card-cta:hover { background: var(--amber-bright); color: var(--bg-base) !important; }

/* ============================================================
   SECTION GLOBALS
   ============================================================ */
.section-wrap { padding: 96px 0; }

.content-area {
    max-width: 1360px;
    margin: 0 auto;
    padding: 0 48px 80px;
}

.section-label {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 40px;
}
.section-label::before {
    content: '';
    flex: 1; height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-strong));
}
.section-label::after {
    content: '';
    flex: 1; height: 1px;
    background: linear-gradient(90deg, var(--border-strong), transparent);
}
.section-label-text {
    font-family: var(--font-display);
    font-size: 0.58rem;
    font-weight: 600;
    letter-spacing: 0.4em;
    text-transform: uppercase;
    color: var(--amber-dim);
    white-space: nowrap;
}

.section-heading {
    font-family: var(--font-editorial);
    font-size: clamp(1.8rem,3.2vw,2.8rem);
    font-weight: 400;
    font-style: italic;
    color: var(--cream);
    text-align: center;
    line-height: 1.25;
    margin-bottom: 14px;
}
.section-heading strong {
    font-style: normal;
    font-family: var(--font-display);
    font-weight: 600;
    color: var(--amber-bright);
}

.section-lead {
    text-align: center;
    font-style: italic;
    font-size: 0.98rem;
    line-height: 1.88;
    color: var(--text-secondary);
    max-width: 520px;
    margin: 0 auto 58px;
}

.ornament-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    padding: 40px 0 24px;
}
.ornament-line {
    flex: 1; max-width: 220px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-strong), transparent);
}
.ornament-icon { color: var(--amber-dim); opacity: 0.65; }

/* ============================================================
   LAYOUT
   ============================================================ */
.has-sidebar {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 52px;
    align-items: start;
}
.main-content-area { min-width: 0; }

/* ============================================================
   SIDEBAR — clean, glassy
   ============================================================ */
.widget-area { display: flex; flex-direction: column; gap: 22px; }

.widget {
    position: relative;
    overflow: hidden;
    background: var(--bg-card);
    border: 1px solid var(--border);
}
.widget::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--amber-dim), transparent);
    opacity: 0.5;
}

.widget-title-wrap {
    padding: 13px 18px;
    border-bottom: 1px solid var(--border);
    background: rgba(184,135,58,0.03);
}
.widget-title {
    font-family: var(--font-display);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    color: var(--amber);
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}
.widget-title::before { content: '—'; font-size: 0.65rem; color: var(--amber-dim); opacity: 0.65; }

.widget-content { padding: 16px 18px; }

.widget ul { list-style: none; padding: 0; margin: 0; }
.widget ul li { border-bottom: 1px solid rgba(184,135,58,0.07); }
.widget ul li:last-child { border-bottom: none; }
.widget ul li a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 0;
    font-size: 0.83rem;
    color: var(--text-secondary);
    font-family: var(--font-body);
    transition: color var(--base) var(--ease), padding-left var(--base) var(--ease);
}
.widget ul li a::before { content: '›'; color: var(--amber-dim); font-size: 0.95rem; flex-shrink: 0; }
.widget ul li a:hover { color: var(--cream); padding-left: 4px; }

.widget_text .textwidget {
    font-family: var(--font-editorial);
    font-style: italic;
    font-size: 0.9rem;
    line-height: 1.78;
    color: var(--text-secondary);
    text-align: center;
}
.widget_text .textwidget::before {
    content: '\201C';
    display: block;
    font-size: 2.2rem;
    line-height: 0.6;
    color: var(--amber-dim);
    margin-bottom: 10px;
    opacity: 0.7;
}

/* ============================================================
   PAṬṬHĀNA SECTION
   ============================================================ */
.patthana-featured {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 34px;
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 26px;
    align-items: flex-start;
    margin-bottom: 20px;
    overflow: hidden;
    transition: border-color var(--base) var(--ease);
}
.patthana-featured:hover { border-color: var(--border-strong); }
.patthana-featured::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--rose-dim), var(--amber-dim) 40%, var(--amber-bright) 55%, var(--amber-dim) 70%, var(--rose-dim));
    opacity: 0.6;
}

.featured-number {
    font-family: var(--font-display);
    font-size: 5.2rem;
    font-weight: 700;
    color: rgba(184,135,58,0.09);
    line-height: 0.85;
    flex-shrink: 0;
    margin-top: -4px;
    letter-spacing: -0.04em;
    user-select: none;
}

.featured-tag {
    font-family: var(--font-display);
    font-size: 0.56rem;
    font-weight: 600;
    letter-spacing: 0.34em;
    text-transform: uppercase;
    color: var(--amber-dim);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.featured-tag::after { content: ''; height: 1px; width: 36px; background: var(--border-strong); }

.featured-title {
    font-family: var(--font-editorial);
    font-style: italic;
    font-size: 1.48rem;
    font-weight: 400;
    color: var(--cream);
    line-height: 1.28;
    margin-bottom: 8px;
}

.featured-pali-name {
    font-family: var(--font-pali);
    font-style: italic;
    font-size: 0.8rem;
    color: var(--amber-dim);
    letter-spacing: 0.05em;
    margin-bottom: 16px;
}

.featured-excerpt {
    font-size: 0.91rem;
    line-height: 1.86;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.read-more-link {
    font-family: var(--font-display);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--amber);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 2px;
    border-bottom: 1px solid var(--border);
    transition: color var(--base) var(--ease), border-color var(--base) var(--ease);
}
.read-more-link:hover { color: var(--amber-bright); border-color: var(--amber-dim); }
.read-more-link::after { content: '→'; transition: transform var(--base) var(--ease); }
.read-more-link:hover::after { transform: translateX(3px); }

.patthana-grid {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 14px;
    margin-bottom: 28px;
}

.patthana-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 24px 20px;
    overflow: hidden;
    transition: background var(--base) var(--ease), border-color var(--base) var(--ease), transform var(--base) var(--ease), box-shadow var(--base) var(--ease);
    cursor: default;
}
.patthana-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-strong);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.patthana-card-number {
    font-family: var(--font-display);
    font-size: 2.8rem;
    font-weight: 700;
    color: rgba(184,135,58,0.07);
    line-height: 1;
    position: absolute;
    top: 10px; right: 12px;
    user-select: none; pointer-events: none;
}

.patthana-card-icon {
    width: 38px; height: 38px;
    background: var(--amber-glow);
    border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.15rem;
    margin-bottom: 13px;
}

.patthana-card-name {
    font-family: var(--font-display);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    color: var(--amber-bright);
    text-transform: uppercase;
    margin-bottom: 5px;
}

.patthana-card-pali {
    font-family: var(--font-pali);
    font-style: italic;
    font-size: 0.72rem;
    color: var(--amber-dim);
    margin-bottom: 11px;
}

.patthana-card-desc {
    font-size: 0.84rem;
    line-height: 1.74;
    color: var(--text-secondary);
}

.enroll-banner {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 26px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 6px;
    position: relative;
    overflow: hidden;
}
.enroll-banner::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--amber-dim), transparent);
    opacity: 0.45;
}
.enroll-banner-eyebrow {
    font-family: var(--font-display);
    font-size: 0.56rem;
    font-weight: 600;
    letter-spacing: 0.34em;
    text-transform: uppercase;
    color: var(--amber-dim);
    margin-bottom: 6px;
}
.enroll-banner-title {
    font-family: var(--font-editorial);
    font-style: italic;
    font-size: 1.18rem;
    color: var(--cream);
    line-height: 1.3;
}

/* ============================================================
   E-BOOKS SECTION
   ============================================================ */
.ebooks-section { background: rgba(20,17,14,0.55); }

.ebooks-grid {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 18px;
}

.ebook-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: transform var(--base) var(--ease), border-color var(--base) var(--ease), box-shadow var(--base) var(--ease);
}
.ebook-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-lg);
}

.ebook-spine {
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    opacity: 0.65;
}

.ebook-cover {
    height: 150px;
    margin-left: 3px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid var(--border);
}

.ebook-cover-inner {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 14px;
}
.ebook-cover-inner .series-label {
    font-family: var(--font-display);
    font-size: 0.53rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--amber-dim);
    display: block;
    margin-bottom: 6px;
}
.ebook-cover-inner .cover-title {
    font-family: var(--font-editorial);
    font-style: italic;
    font-size: 1.02rem;
    color: var(--cream);
    display: block;
    line-height: 1.28;
}
.ebook-cover-inner .cover-pali {
    font-family: var(--font-pali);
    font-style: italic;
    font-size: 0.6rem;
    color: var(--sand-dim);
    display: block;
    margin-top: 5px;
}

.ebook-body { padding: 16px 16px 16px 18px; }
.ebook-book-title {
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--cream);
    line-height: 1.35;
    margin-bottom: 5px;
}
.ebook-author {
    font-family: var(--font-display);
    font-size: 0.55rem;
    font-weight: 500;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--sand-dim);
    margin-bottom: 9px;
}
.ebook-excerpt {
    font-size: 0.79rem;
    line-height: 1.68;
    color: var(--text-muted);
    margin-bottom: 13px;
}
.ebook-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
}

.ebook-badge {
    font-family: var(--font-display);
    font-size: 0.52rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    padding: 3px 7px;
    border: 1px solid;
}
.ebook-badge.free      { color: var(--amber-dim); border-color: var(--border); background: var(--amber-glow); }
.ebook-badge.new       { color: var(--cream-dim); border-color: rgba(122,46,46,0.5); background: rgba(122,46,46,0.18); }
.ebook-badge.essential { color: var(--amber-bright); border-color: var(--amber-border); background: rgba(184,135,58,0.09); }

.ebook-download-link {
    font-family: var(--font-display);
    font-size: 0.57rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--amber);
    transition: color var(--base) var(--ease);
}
.ebook-download-link:hover { color: var(--amber-bright); }

/* ============================================================
   DEFAULT SIDEBAR (template part)
   ============================================================ */
.dtc-sidebar-default { display: flex; flex-direction: column; gap: 20px; }

.dtc-sidebar-widget {
    background: var(--bg-card);
    border: 1px solid var(--border);
    overflow: hidden;
    position: relative;
}
.dtc-sidebar-widget::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--amber-dim), transparent);
    opacity: 0.45;
}
.dtc-widget-header {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    background: rgba(184,135,58,0.03);
}
.dtc-widget-title {
    font-family: var(--font-display);
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    color: var(--amber);
}
.dtc-widget-body { padding: 14px 16px; }
.dtc-quote-text {
    font-family: var(--font-editorial);
    font-style: italic;
    font-size: 0.93rem;
    line-height: 1.78;
    color: var(--text-secondary);
    text-align: center;
}
.dtc-quote-text::before {
    content: '\201C';
    display: block;
    font-size: 2.2rem; line-height: 0.6;
    color: var(--amber-dim);
    margin-bottom: 10px; opacity: 0.65;
}
.dtc-conditions-list { list-style: none; padding: 0; margin: 0; }
.dtc-conditions-list li { border-bottom: 1px solid rgba(184,135,58,0.07); }
.dtc-conditions-list li:last-child { border-bottom: none; }
.dtc-conditions-list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 0.82rem;
    color: var(--text-secondary);
    transition: color var(--base) var(--ease);
}
.dtc-conditions-list a:hover { color: var(--cream); }
.dtc-cond-num {
    font-family: var(--font-display);
    font-size: 0.54rem;
    letter-spacing: 0.1em;
    color: var(--amber-dim);
    opacity: 0.65;
}
.dtc-donate-banner { text-align: center; padding: 4px 0 6px; }
.dtc-donate-banner p { font-style: italic; font-size: 0.82rem; color: var(--text-secondary); line-height: 1.6; margin-bottom: 12px; }
.dtc-dana-btn {
    display: inline-block;
    padding: 8px 22px;
    font-family: var(--font-display);
    font-size: 0.59rem; font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--bg-base) !important;
    background: var(--amber);
    text-decoration: none !important;
    transition: background var(--base) var(--ease);
}
.dtc-dana-btn:hover { background: var(--amber-bright); color: var(--bg-base) !important; }

/* ============================================================
   BLOG / POSTS
   ============================================================ */
.posts-list { display: flex; flex-direction: column; gap: 18px; }
.post-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: border-color var(--base) var(--ease), transform var(--base) var(--ease), box-shadow var(--base) var(--ease);
}
.post-card:hover { border-color: var(--border-strong); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.post-thumb { display: block; overflow: hidden; }
.post-thumb img { width: 100%; height: 196px; object-fit: cover; transition: transform 0.55s var(--ease); }
.post-card:hover .post-thumb img { transform: scale(1.03); }
.post-card-body { padding: 22px 26px; }
.post-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-display);
    font-size: 0.56rem; font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--sand-dim);
    margin-bottom: 10px;
}
.post-category { color: var(--amber-dim); }
.post-card-title { font-size: 1.15rem; margin-bottom: 8px; }
.post-card-title a { color: var(--cream); }
.post-card-title a:hover { color: var(--amber-bright); }
.post-card-excerpt { font-size: 0.87rem; color: var(--text-secondary); margin-bottom: 16px; line-height: 1.75; }

.entry-header { padding: 0 0 26px; border-bottom: 1px solid var(--border); margin-bottom: 34px; }
.entry-content { max-width: 700px; }
.entry-content p { margin-bottom: 1.5em; }
.entry-content h2, .entry-content h3 { margin: 2em 0 0.75em; }
.entry-footer {
    padding: 22px 0 0;
    border-top: 1px solid var(--border);
    margin-top: 38px;
    font-size: 0.78rem;
    color: var(--sand-dim);
}
.entry-footer a { color: var(--amber-dim); }
.entry-footer a:hover { color: var(--amber); }

.page-hero { padding: 80px 0 54px; border-bottom: 1px solid var(--border); }
.page-hero-inner { max-width: 1360px; margin: 0 auto; padding: 0 48px; }
.page-hero-eyebrow {
    font-family: var(--font-display);
    font-size: 0.57rem; font-weight: 600;
    letter-spacing: 0.36em; text-transform: uppercase;
    color: var(--amber-dim);
    margin-bottom: 12px;
    display: flex; align-items: center; gap: 12px;
}
.page-hero-eyebrow::before { content: ''; display: block; width: 18px; height: 1px; background: var(--amber-dim); opacity: 0.55; }
.page-hero .page-title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem,3.2vw,2.8rem);
    font-weight: 600; color: var(--cream); margin: 0;
}

/* ============================================================
   FOOTER
   ============================================================ */
#colophon {
    position: relative;
    background: var(--bg-raised);
    border-top: 1px solid var(--border);
    overflow: hidden;
}
.footer-shimmer {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--amber-dim) 30%, var(--amber-bright) 50%, var(--amber-dim) 70%, transparent);
    opacity: 0.45;
}
.footer-widgets {
    max-width: 1360px;
    margin: 0 auto;
    padding: 62px 48px 42px;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 50px;
}
.footer-widget-area .footer-brand-title { font-family: var(--font-display); font-size: 0.96rem; color: var(--amber); margin-bottom: 4px; }
.footer-tagline { font-style: italic; font-size: 0.83rem; line-height: 1.78; color: var(--text-secondary); margin: 12px 0 18px; }
.footer-social { display: flex; gap: 7px; flex-wrap: wrap; }
.footer-social a {
    width: 30px; height: 30px;
    border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    color: var(--sand-dim); font-size: 0.72rem;
    text-decoration: none;
    transition: border-color var(--base) var(--ease), color var(--base) var(--ease), background var(--base) var(--ease);
}
.footer-social a:hover { border-color: var(--amber-border); color: var(--amber); background: var(--amber-glow); }
.footer-col-title {
    font-family: var(--font-display);
    font-size: 0.6rem; font-weight: 600;
    letter-spacing: 0.3em; text-transform: uppercase;
    color: var(--amber-dim);
    margin-bottom: 14px; padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
}
.footer-nav { list-style: none; padding: 0; margin: 0; }
.footer-nav li { margin-bottom: 8px; }
.footer-nav a {
    font-size: 0.81rem;
    color: var(--text-secondary);
    text-decoration: none;
    display: flex; align-items: center; gap: 7px;
    transition: color var(--base) var(--ease);
}
.footer-nav a::before { content: '—'; font-size: 0.48rem; color: var(--amber-dim); opacity: 0.45; flex-shrink: 0; }
.footer-nav a:hover { color: var(--cream-dim); }
.site-info {
    max-width: 1360px; margin: 0 auto;
    padding: 20px 48px;
    border-top: 1px solid rgba(184,135,58,0.07);
    display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.site-info .copyright { font-size: 0.7rem; color: var(--text-muted); letter-spacing: 0.04em; }
.site-info .pali-motto { font-family: var(--font-pali); font-style: italic; font-size: 0.74rem; color: rgba(184,135,58,0.3); }

/* ============================================================
   FORMS
   ============================================================ */
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea,
.search-form input[type="search"] {
    width: 100%;
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--cream);
    font-family: var(--font-body);
    font-size: 0.95rem;
    padding: 11px 14px;
    outline: none;
    transition: border-color var(--base) var(--ease);
}
.comment-form input:focus,
.comment-form textarea:focus,
.search-form input:focus { border-color: var(--amber); }
input[type="submit"], button[type="submit"], .comment-form .submit {
    font-family: var(--font-display);
    font-size: 0.64rem; font-weight: 600;
    letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--bg-base);
    background: var(--amber);
    border: none; padding: 11px 26px; cursor: pointer;
    transition: background var(--base) var(--ease);
}
input[type="submit"]:hover, button[type="submit"]:hover { background: var(--amber-bright); }

/* ============================================================
   PAGINATION
   ============================================================ */
.pagination, .page-navigation, .posts-navigation {
    display: flex; justify-content: center; gap: 5px; margin: 50px 0; flex-wrap: wrap;
}
.page-numbers, .nav-links a, .nav-links span {
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px;
    font-family: var(--font-display); font-size: 0.66rem; font-weight: 600; letter-spacing: 0.06em;
    color: var(--sand-dim);
    border: 1px solid var(--border);
    background: var(--bg-card);
    text-decoration: none;
    transition: all var(--base) var(--ease);
}
.page-numbers.current,
.page-numbers:hover,
.nav-links a:hover { color: var(--bg-base); background: var(--amber); border-color: transparent; }

/* ============================================================
   SCROLL ANIMATION
   ============================================================ */
.js-fade {
    opacity: 0; transform: translateY(14px);
    transition: opacity 0.55s var(--ease-out), transform 0.55s var(--ease-out);
}
.js-fade.is-visible { opacity: 1; transform: translateY(0); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width:1100px) {
    .hero-content   { grid-template-columns:1fr; gap:48px; }
    .hero-card      { max-width:500px; }
    .ebooks-grid    { grid-template-columns:repeat(2,1fr); }
    .footer-widgets { grid-template-columns:1fr 1fr; gap:36px; }
}
@media (max-width:900px) {
    .has-sidebar        { grid-template-columns:1fr; }
    .patthana-grid      { grid-template-columns:1fr; }
    .patthana-featured  { grid-template-columns:1fr; }
    .featured-number    { display:none; }
}
@media (max-width:768px) {
    .header-inner   { flex-wrap:wrap; min-height:62px; padding:10px 20px; }
    .content-area   { padding:0 20px 60px; }
    .hero-content   { padding:88px 20px 66px; }
    .lotus-menu {
        display:none; flex-direction:column; gap:0;
        position:absolute; top:100%; left:0; right:0;
        background:rgba(13,11,10,0.98);
        border-top:1px solid var(--border);
        border-bottom:1px solid var(--border);
        backdrop-filter:blur(20px); z-index:400;
    }
    .lotus-menu.is-open { display:flex; }
    .lotus-menu li::before { display:none; }
    .lotus-menu a   { padding:13px 20px; border-bottom:1px solid var(--border); font-size:0.7rem; }
    .menu-toggle    { display:block; }
    .ebooks-grid    { grid-template-columns:1fr; }
    .footer-widgets { grid-template-columns:1fr; gap:26px; padding:38px 20px 26px; }
    .site-info      { flex-direction:column; text-align:center; padding:16px 20px; }
    .page-hero-inner { padding:0 20px; }
    .section-wrap   { padding:72px 0; }
}
@media (max-width:480px) {
    .hero-actions   { flex-direction:column; align-items:flex-start; }
    .btn-primary, .btn-outline { width:100%; text-align:center; }
    .section-wrap   { padding:56px 0; }
}

/* ============================================================
   UTILITIES
   ============================================================ */
.text-amber  { color: var(--amber-bright) !important; }
.text-sand   { color: var(--sand) !important; }
.text-cream  { color: var(--cream) !important; }
.text-center { text-align: center; }
.font-display { font-family: var(--font-display); }
.font-pali   { font-family: var(--font-pali); font-style: italic; }
.sr-only     { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

/* ============================================================
   BLOCK EDITOR
   ============================================================ */
.wp-block-image figcaption { font-size:0.79rem; font-style:italic; color:var(--sand-dim); text-align:center; margin-top:7px; }
.wp-block-quote { border-left:2px solid var(--border-strong); padding-left:1.4em; font-style:italic; color:var(--text-secondary); }
.wp-block-separator { border:none; border-top:1px solid var(--border); margin:2em 0; }
.wp-block-button__link {
    font-family:var(--font-display); font-size:0.66rem; font-weight:600;
    letter-spacing:0.18em; text-transform:uppercase;
    background:var(--amber); color:var(--bg-base); padding:12px 26px; border-radius:0;
}
