/* ==========================================================================
   SANATAN VANI LUXE MANTRA DIRECTORY STYLES (Upgraded & Compact)
   ========================================================================== */

/* Main Layout Wrapper Override */
body.sv-premium-v2 .sv-mantra-layout-wrapper {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    margin: 24px auto;
    max-width: 1400px;
    padding: 0 20px;
    align-items: start;
}

@media (max-width: 1100px) {
    body.sv-premium-v2 .sv-mantra-layout-wrapper {
        grid-template-columns: minmax(0, 1fr) 300px;
        gap: 20px;
    }
}

@media (max-width: 991px) {
    body.sv-premium-v2 .sv-mantra-layout-wrapper {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* Banner / Header Card */
body.sv-premium-v2 .sv-mantra-banner-premium {
    background: 
        radial-gradient(circle at 10% 20%, rgba(213, 166, 66, 0.15), transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(123, 36, 24, 0.12), transparent 40%),
        linear-gradient(135deg, #2b110c 0%, #501712 50%, #1e0906 100%) !important;
    border: 1px solid #d4af37 !important;
    border-radius: 12px !important;
    padding: 24px !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 12px 30px rgba(30, 9, 6, 0.15) !important;
    color: #fff8eb !important;
}

body.sv-premium-v2 .sv-mantra-banner-premium::before {
    content: "🕉️";
    position: absolute;
    right: -20px;
    bottom: -30px;
    font-size: 160px;
    opacity: 0.05;
    font-family: 'Noto Sans Devanagari', sans-serif;
    pointer-events: none;
}

body.sv-premium-v2 .sv-mantra-banner-premium h1 {
    color: #ffd88f !important;
    font-size: 28px !important;
    font-weight: 800 !important;
    margin: 8px 0 !important;
    font-family: 'Tiro Devanagari Hindi', serif;
}

body.sv-premium-v2 .sv-mantra-banner-premium .sv-kicker {
    color: #d4af37;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

body.sv-premium-v2 .sv-mantra-banner-premium .sv-article-excerpt {
    color: #e5d1c2 !important;
    font-size: 14.5px !important;
    line-height: 1.6 !important;
    max-width: 820px;
}

/* Control Panel (Search & Deity Chips) */
body.sv-premium-v2 .sv-mantra-control-panel {
    background: #ffffff;
    border: 1px solid rgba(213, 166, 66, 0.25);
    border-radius: 12px;
    padding: 18px;
    margin-top: 20px;
    box-shadow: 0 6px 20px rgba(101, 30, 24, 0.03);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Horizontal Filters Row */
body.sv-premium-v2 .sv-mantra-filter-row {
    display: grid;
    grid-template-columns: 1.8fr 1fr 1fr auto;
    gap: 12px;
    align-items: center;
    width: 100%;
}

body.sv-premium-v2 .sv-mantra-filter-row .filter-item {
    position: relative;
    width: 100%;
}

body.sv-premium-v2 .sv-mantra-filter-row .filter-item input,
body.sv-premium-v2 .sv-mantra-filter-row .filter-item select {
    width: 100%;
    height: 42px;
    padding: 0 12px;
    border: 1px solid #e3d2b9;
    border-radius: 8px;
    background: #fffdfb;
    color: #3b281f;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
}

body.sv-premium-v2 .sv-mantra-filter-row .filter-item input:focus,
body.sv-premium-v2 .sv-mantra-filter-row .filter-item select:focus {
    outline: none;
    border-color: #7b2418;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(123, 36, 24, 0.1);
}

body.sv-premium-v2 .sv-mantra-filter-row .filter-item.search-field input {
    padding-left: 36px;
    border-radius: 21px;
}

body.sv-premium-v2 .sv-mantra-filter-row .filter-item.search-field .search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    color: #9c7b6c;
    pointer-events: none;
}

body.sv-premium-v2 .sv-filter-submit-btn {
    height: 40px;
    padding: 0 20px;
    border-radius: 20px;
    border: 1px solid #7b2418;
    background: #7b2418;
    color: #ffffff;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s ease;
}

body.sv-premium-v2 .sv-filter-submit-btn:hover {
    background: #60150d;
    border-color: #60150d;
}

/* Deity Filter Chips Scroll */
body.sv-premium-v2 .sv-deity-chips-scroll {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    border-top: 1px solid rgba(227, 210, 185, 0.3);
    padding-top: 12px;
}

body.sv-premium-v2 .sv-deity-filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 30px;
    padding: 0 10px 0 5px;
    border-radius: 15px;
    border: 1px solid #e3d2b9;
    background: #fffdfa;
    color: #4a2f26;
    font-size: 12.5px;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

body.sv-premium-v2 .sv-deity-filter-chip .chip-avatar {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7b2418, #4a150f);
    color: #ffd685;
    font-size: 9px;
    font-weight: 900;
}

body.sv-premium-v2 .sv-deity-filter-chip:hover,
body.sv-premium-v2 .sv-deity-filter-chip.active {
    background: linear-gradient(135deg, #60150d 0%, #7b2418 50%, #9a3523 100%);
    border-color: #d4af37;
    color: #fff6e8;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(123,36,24,0.1);
}

body.sv-premium-v2 .sv-deity-filter-chip:hover .chip-avatar,
body.sv-premium-v2 .sv-deity-filter-chip.active .chip-avatar {
    background: #ffd685;
    color: #4a150f;
}

/* Deity Specific Colors */
body.sv-premium-v2 .sv-deity-filter-chip[data-deity="shiv"] .chip-avatar { background: linear-gradient(135deg, #2b5c8f, #142a42); color: #e6f2ff; }
body.sv-premium-v2 .sv-deity-filter-chip[data-deity="ganesh"] .chip-avatar { background: linear-gradient(135deg, #e65c00, #990000); color: #fff; }
body.sv-premium-v2 .sv-deity-filter-chip[data-deity="hanuman"] .chip-avatar { background: linear-gradient(135deg, #e63900, #ff8000); color: #fff; }
body.sv-premium-v2 .sv-deity-filter-chip[data-deity="durga"] .chip-avatar { background: linear-gradient(135deg, #cc0052, #660029); color: #fff; }
body.sv-premium-v2 .sv-deity-filter-chip[data-deity="laxmi"] .chip-avatar { background: linear-gradient(135deg, #d4af37, #996515); color: #fff; }

/* 2-Column Grid (Spacious & Clean) */
body.sv-premium-v2 .sv-mantras-grid-premium {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 20px;
}

@media (max-width: 768px) {
    body.sv-premium-v2 .sv-mantras-grid-premium {
        grid-template-columns: 1fr;
        gap: 16px;
    }
}

/* Premium Plaque Cards */
body.sv-premium-v2 .sv-mantra-card-premium {
    background: linear-gradient(180deg, #ffffff 0%, #fffdf8 100%);
    border: 1px solid #e3d2b9;
    border-radius: 12px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    position: relative;
    box-shadow: 0 4px 15px rgba(101, 30, 24, 0.02);
    transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
    height: 100%;
}

body.sv-premium-v2 .sv-mantra-card-premium:hover {
    transform: translateY(-4px);
    border-color: #d4af37;
    box-shadow: 0 12px 28px rgba(123, 36, 24, 0.08) !important;
}

body.sv-premium-v2 .sv-mantra-card-premium::after {
    content: "";
    position: absolute;
    inset: 4px;
    border: 1px dashed rgba(212, 175, 55, 0.22);
    border-radius: 10px;
    pointer-events: none;
}

/* Card Header */
body.sv-premium-v2 .sv-mcard-header {
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-bottom: 1px solid rgba(227, 210, 185, 0.4);
    padding-bottom: 8px;
}

body.sv-premium-v2 .sv-mcard-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
}

body.sv-premium-v2 .sv-mcard-index {
    color: #9c7b6c;
    font-weight: 800;
}

body.sv-premium-v2 .sv-mcard-deity-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 20px;
    padding: 0 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 900;
    color: #ffffff;
    background: #7b2418;
}

/* Deity Badge Colors */
body.sv-premium-v2 .deity-shiv { background: #2b5c8f; }
body.sv-premium-v2 .deity-ganesh { background: #d35400; }
body.sv-premium-v2 .deity-hanuman { background: #c0392b; }
body.sv-premium-v2 .deity-durga { background: #b01e51; }
body.sv-premium-v2 .deity-laxmi { background: #aa800a; }
body.sv-premium-v2 .deity-saraswati { background: #16a085; }
body.sv-premium-v2 .deity-gayatri { background: #8e44ad; }
body.sv-premium-v2 .deity-surya { background: #d35400; }
body.sv-premium-v2 .deity-shani { background: #2c3e50; }
body.sv-premium-v2 .deity-kuber { background: #27ae60; }
body.sv-premium-v2 .deity-vishnu { background: #2980b9; }

body.sv-premium-v2 .sv-mcard-title {
    color: #4a150f;
    font-family: 'Tiro Devanagari Hindi', 'Noto Sans Devanagari', serif;
    font-size: 18px;
    font-weight: 800;
    margin: 2px 0 0 0;
    line-height: 1.3;
}

body.sv-premium-v2 .sv-mcard-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

body.sv-premium-v2 .sv-mcard-tag {
    font-size: 10px;
    font-weight: 800;
    padding: 1px 6px;
    border-radius: 4px;
    background: #f7ebd7;
    color: #8b5d2a;
    border: 1px solid rgba(213, 166, 66, 0.1);
}

/* Card Body */
body.sv-premium-v2 .sv-mcard-body {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex-grow: 1;
}

/* Devanagari Text Box - Plaque Style */
body.sv-premium-v2 .sv-mcard-sanskrit-wrap {
    background: #fffcf5;
    border: 1px solid rgba(227, 210, 185, 0.6);
    border-radius: 8px;
    padding: 16px;
    position: relative;
    min-height: 70px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: inset 0 1px 3px rgba(64,16,16,0.02);
    transition: all 0.25s ease;
}

body.sv-premium-v2 .sv-mantra-card-premium:hover .sv-mcard-sanskrit-wrap {
    background: #fffcf0;
    border-color: rgba(212,175,55,0.4);
}

body.sv-premium-v2 .sv-mcard-sanskrit {
    font-family: 'Tiro Devanagari Hindi', 'Noto Sans Devanagari', serif;
    font-size: 22px;
    font-weight: 800;
    color: #7b2418;
    line-height: 1.6;
    text-align: center;
    padding: 2px 20px;
    word-break: break-word;
}

/* Inline Floating Copy Button */
body.sv-premium-v2 .sv-mcard-copy-btn {
    position: absolute;
    right: 8px;
    top: 8px;
    background: rgba(247, 235, 215, 0.5);
    border: 1px solid rgba(227, 210, 185, 0.4);
    cursor: pointer;
    color: #8b5d2a;
    font-size: 12px;
    transition: all 0.2s;
    padding: 5px;
    border-radius: 50%;
    width: 26px;
    height: 26px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
}

body.sv-premium-v2 .sv-mcard-copy-btn:hover {
    color: #7b2418;
    background: #ffd685;
    border-color: #ffd685;
}

body.sv-premium-v2 .sv-mcard-copy-btn.copied {
    color: #1e6b0a;
    background: #eef9eb;
    border-color: #1e6b0a;
}

/* Quick Metadata Info */
body.sv-premium-v2 .sv-mcard-quick-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    background: rgba(247, 235, 215, 0.22);
    border-radius: 6px;
    padding: 10px;
    border: 1px solid rgba(227, 210, 185, 0.25);
    font-size: 12px;
}

body.sv-premium-v2 .sv-mcard-stat-item {
    display: flex;
    flex-direction: column;
}

body.sv-premium-v2 .sv-mcard-stat-item strong {
    font-size: 9.5px;
    text-transform: uppercase;
    color: #9c7b6c;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

body.sv-premium-v2 .sv-mcard-stat-item span {
    font-weight: 700;
    color: #4a2f26;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Expand Accordion Button */
body.sv-premium-v2 .sv-mcard-toggle-btn {
    width: 100%;
    height: 34px;
    border: 1px solid #e3d2b9;
    border-radius: 6px;
    background: #fffcf8;
    color: #7b2418;
    font-weight: 800;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
    margin-top: auto;
}

body.sv-premium-v2 .sv-mcard-toggle-btn:hover {
    background: #7b2418;
    color: #ffffff;
    border-color: #7b2418;
}

body.sv-premium-v2 .details-open .sv-mcard-toggle-btn {
    background: #f7ecd7;
    color: #5d251c;
    border-color: #d4af37;
}

/* Collapsible Content */
body.sv-premium-v2 .sv-mcard-collapsible {
    border-top: 1px dashed rgba(227, 210, 185, 0.5);
    margin-top: 4px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

body.sv-premium-v2 .sv-mcard-detail-section {
    padding-top: 10px;
    font-size: 13px;
    line-height: 1.5;
}

body.sv-premium-v2 .sv-mcard-detail-section h3 {
    font-size: 10.5px;
    font-weight: 800;
    color: #8b5d2a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 4px 0;
}

body.sv-premium-v2 .sv-mcard-detail-section p {
    color: #3b281f;
    margin: 0;
}

body.sv-premium-v2 .sv-mcard-detail-section p.roman-translit {
    font-style: italic;
    color: #6e5c54;
    font-size: 12.5px;
}

/* Sidebar Widgets */
body.sv-premium-v2 .sv-mantra-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Benefit Filter Card */
body.sv-premium-v2 .sv-mantra-benefit-card {
    background: #ffffff;
    border: 1px solid rgba(213, 166, 66, 0.25);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 6px 20px rgba(101, 30, 24, 0.02);
}

body.sv-premium-v2 .sv-sidebar-widget-title {
    font-size: 14px;
    font-weight: 800;
    color: #7b2418;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(213, 166, 66, 0.2);
    padding-bottom: 8px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

body.sv-premium-v2 .sv-mantra-benefit-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

body.sv-premium-v2 .sv-mantra-benefit-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 38px;
    padding: 0 12px;
    border-radius: 6px;
    border: 1px solid #ece4d8;
    background: #fffdfb;
    color: #4a2f26;
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
    transition: all 0.2s ease;
}

body.sv-premium-v2 .sv-mantra-benefit-item .benefit-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

body.sv-premium-v2 .sv-mantra-benefit-item .benefit-icon {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 4px;
    background: #f7ebd7;
    color: #8b5d2a;
    font-size: 9px;
    font-weight: 900;
}

body.sv-premium-v2 .sv-mantra-benefit-item .benefit-arrow {
    font-size: 10px;
    color: #9c7b6c;
    transition: transform 0.2s;
}

body.sv-premium-v2 .sv-mantra-benefit-item:hover {
    border-color: #d4af37;
    background: #fffbf4;
    color: #7b2418;
}

body.sv-premium-v2 .sv-mantra-benefit-item:hover .benefit-arrow {
    transform: translateX(3px);
    color: #7b2418;
}

body.sv-premium-v2 .sv-mantra-benefit-item.active {
    background: linear-gradient(135deg, #7b2418 0%, #9a3523 100%);
    border-color: #d4af37;
    color: #ffd685;
}

body.sv-premium-v2 .sv-mantra-benefit-item.active .benefit-icon {
    background: #ffd685;
    color: #7b2418;
}

body.sv-premium-v2 .sv-mantra-benefit-item.active .benefit-arrow {
    color: #ffd685;
}

/* Rules Card */
body.sv-premium-v2 .sv-mantra-rules-card {
    background: #ffffff;
    border: 1px solid rgba(213, 166, 66, 0.25);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 6px 20px rgba(101, 30, 24, 0.02);
}

body.sv-premium-v2 .sv-mantra-rules-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

body.sv-premium-v2 .sv-mantra-rules-list li {
    font-size: 12.5px;
    line-height: 1.45;
    color: #4b3528;
    border-bottom: 1px dashed rgba(213, 166, 66, 0.15);
    padding-bottom: 6px;
}

body.sv-premium-v2 .sv-mantra-rules-list li:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

body.sv-premium-v2 .sv-mantra-rules-list li strong {
    color: #7b2418;
    display: block;
    margin-bottom: 1px;
}

/* Pagination */
body.sv-premium-v2 .sv-mantra-pagination-premium {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 24px 0 8px;
}

body.sv-premium-v2 .sv-mantra-pagination-premium a {
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    padding: 0 14px;
    font-weight: 800;
    text-decoration: none;
    border: 1px solid #e3d2b9;
    background: #ffffff;
    color: #7b2418;
    font-size: 12px;
    transition: all 0.2s;
}

body.sv-premium-v2 .sv-mantra-pagination-premium a:hover {
    background: #7b2418;
    color: #ffffff;
    border-color: #7b2418;
}

body.sv-premium-v2 .sv-mantra-pagination-premium span {
    color: #6a4a38;
    font-size: 12px;
    font-weight: 700;
}

/* Empty State */
body.sv-premium-v2 .sv-mantras-empty-state {
    text-align: center;
    padding: 30px 15px;
    background: #ffffff;
    border: 1px dashed #e3d2b9;
    border-radius: 10px;
    margin-top: 20px;
}

body.sv-premium-v2 .sv-mantras-empty-state .empty-icon {
    font-size: 36px;
    margin-bottom: 10px;
}

body.sv-premium-v2 .sv-mantras-empty-state h3 {
    font-size: 17px;
    color: #7b2418;
    font-weight: 800;
    margin: 0 0 6px 0;
}

body.sv-premium-v2 .sv-mantras-empty-state p {
    font-size: 13px;
    color: #6a4a38;
    max-width: 420px;
    margin: 0 auto 12px auto;
    line-height: 1.45;
}

body.sv-premium-v2 .sv-btn-reset-filters-premium {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 34px;
    padding: 0 16px;
    border-radius: 17px;
    border: none;
    background: linear-gradient(135deg, #7b2418, #9a3523);
    color: #ffd685;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(123,36,24,0.15);
    transition: all 0.2s;
}

body.sv-premium-v2 .sv-btn-reset-filters-premium:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(123,36,24,0.22);
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    body.sv-premium-v2 .sv-mantra-filter-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    body.sv-premium-v2 .sv-filter-submit-btn {
        width: 100%;
        height: 42px;
        border-radius: 21px;
    }
}

@media (max-width: 575px) {
    body.sv-premium-v2 .sv-mcard-title {
        font-size: 15px;
    }
    body.sv-premium-v2 .sv-mcard-sanskrit {
        font-size: 18px;
    }
    body.sv-premium-v2 .sv-mantra-control-panel {
        padding: 12px;
        gap: 12px;
    }
    body.sv-premium-v2 .sv-deity-filter-chip {
        height: 28px;
        padding: 0 8px 0 4px;
        font-size: 11px;
    }
    body.sv-premium-v2 .sv-deity-filter-chip .chip-avatar {
        width: 18px;
        height: 18px;
        font-size: 8px;
    }
}
