/* LifeVed Devotional — TIER 5: Visual Polish & Devotional Identity
   Adds: decorative patterns, deity-specific styling, enhanced hub */

/* === DECORATIVE BACKGROUND PATTERN (subtle Mandala) === */
body {
    background-image:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'%3E%3Cpath d='M40 0C18 0 0 18 0 40s18 40 40 40 40-18 40-40S62 0 40 0zm0 72c-17.7 0-32-14.3-32-32S22.3 8 40 8s32 14.3 32 32-14.3 32-32 32z' fill='%23c6993e' fill-opacity='0.015'/%3E%3C/svg%3E");
}

/* === ENHANCED HUB HERO === */
.hub-hero {
    background: linear-gradient(180deg, #fef8ee 0%, var(--bg-primary) 100%);
    position: relative;
}
.hub-hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--temple-gold), var(--accent), var(--temple-gold), transparent);
    opacity: 0.3;
}

/* === HUB TITLE — Premium Serif Look === */
.hub-title {
    font-family: Georgia, 'Times New Roman', serif;
    font-weight: 700;
    letter-spacing: -0.5px;
}

/* === TODAY'S SPECIAL CARD === */
.todays-special {
    margin: 24px 0;
    padding: 20px;
    background: linear-gradient(135deg, #fff5e6, #ffecd2, #fff5e6);
    border: 1.5px solid rgba(198,153,62,0.25);
    border-radius: var(--radius-xl);
    position: relative;
    overflow: hidden;
}
.todays-special::before {
    content: '🪔';
    position: absolute;
    top: -10px;
    right: -5px;
    font-size: 4rem;
    opacity: 0.08;
}
.todays-special-label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent);
    margin-bottom: 8px;
}
.todays-special-text {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-hindi);
    line-height: 1.8;
    margin-bottom: 8px;
}
.todays-special-sub {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* === CATEGORY CARDS — Devotional Enhanced === */
.category-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.category-card:active {
    transform: scale(0.95);
}
/* Different subtle tint per deity color */
.category-card[data-access="free"] {
    background: linear-gradient(160deg, #ffffff, #f9fdf9);
}
.category-card[data-access="premium"] {
    background: linear-gradient(160deg, #ffffff, #fffaf5);
}

/* === CONTENT LIST ITEMS — Enhanced === */
.content-item {
    position: relative;
    transition: all 0.25s ease;
}
.content-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 12px;
    bottom: 12px;
    width: 3px;
    background: var(--accent);
    border-radius: 2px;
    opacity: 0;
    transition: opacity 0.2s;
}
.content-item:hover::before { opacity: 1; }

/* === SECTION DIVIDER (Decorative) === */
.section-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 32px 0;
    color: var(--temple-gold);
    opacity: 0.5;
    font-size: 0.85rem;
}
.section-divider::before,
.section-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--temple-gold), transparent);
}

/* === SCROLL TO TOP BUTTON === */
.scroll-top {
    position: fixed;
    bottom: calc(var(--nav-height) + 20px);
    right: 16px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    border: none;
    box-shadow: 0 4px 16px rgba(230,81,0,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 90;
}
.scroll-top.visible { opacity: 1; visibility: visible; }
.scroll-top:active { transform: scale(0.9); }

/* === LISTING PAGE HEADER with count badge === */
.listing-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}
.listing-count {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    background: var(--accent-glow);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
}

/* === FEATURED CONTENT TAG === */
.featured-tag {
    position: absolute;
    top: 0;
    left: 16px;
    background: var(--accent);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 10px;
    border-radius: 0 0 8px 8px;
}

/* === QUICK STATS (deity hub) === */
.deity-quick-stats {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin: 12px 0;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-radius: var(--radius);
}
.deity-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}
.deity-stat-icon { font-size: 1rem; }

/* === VERSE NUMBER INDICATOR === */
.verse-num-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--accent-glow);
    color: var(--accent);
    font-size: 0.7rem;
    font-weight: 700;
    border-radius: 50%;
    margin-right: 8px;
    flex-shrink: 0;
}

/* === MOBILE BOTTOM SAFE AREA === */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .bottom-nav { padding-bottom: env(safe-area-inset-bottom); }
}

/* === PRINT-SPECIFIC FOR DEVOTIONAL === */
@media print {
    .reader-toolbar, .share-bar, .cross-links, .video-section, .premium-gate-card, .vrat-checklist-wrap { display: none !important; }
    .reader-verse-block { break-inside: avoid; border: 1px solid #ddd; }
    .reader-line { font-size: 14pt; line-height: 2.2; }
    body { font-size: 12pt; }
}

/* === LOCK BADGE (premium items in listings) === */
.lock-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    margin-left: 6px;
    opacity: 0.7;
    flex-shrink: 0;
}
.content-item .lock-badge { margin-left: auto; margin-right: 4px; }
.content-item.is-locked { opacity: 0.82; }
.content-item.is-locked .content-item-icon { filter: grayscale(0.3); }

/* === MANTRA FINDER (problem-based) === */
.finder-hero {
    text-align: center;
    padding: 22px 18px 18px;
    background: linear-gradient(160deg, #fff6e9, #fdeccf);
    border: 1px solid rgba(198,153,62,0.25);
    border-radius: var(--radius-xl, 22px);
    margin: 8px 0 18px;
    position: relative;
    overflow: hidden;
}
.finder-hero-om { font-size: 2rem; color: var(--accent); opacity: 0.9; }
.finder-hero h2 { font-family: Georgia, serif; font-size: 1.35rem; margin: 4px 0 6px; color: var(--text-primary); }
.finder-hero p { font-size: 0.85rem; color: var(--text-secondary); max-width: 460px; margin: 0 auto; }

.problem-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 8px;
}
.problem-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 4px;
    padding: 18px 12px 16px;
    background: linear-gradient(160deg, #ffffff, #fff7ee);
    border: 1px solid var(--border, rgba(198,153,62,0.2));
    border-radius: var(--radius, 16px);
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.25s cubic-bezier(0.4,0,0.2,1);
    box-shadow: 0 2px 10px rgba(120,70,0,0.04);
    min-height: 110px;
    justify-content: center;
}
.problem-card:active { transform: scale(0.96); }
.problem-card:hover { border-color: var(--accent); transform: translateY(-3px); box-shadow: 0 10px 24px rgba(230,81,0,0.12); }
.problem-icon { font-size: 1.9rem; line-height: 1; }
.problem-title { font-weight: 700; font-size: 0.92rem; line-height: 1.25; }
.problem-sub { font-size: 0.72rem; color: var(--text-muted); }
.problem-lock { position: absolute; top: 8px; right: 8px; }

/* Mantra tiles (foundational / suktas) */
.mantra-tiles { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }
.mantra-tile {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    background: var(--bg-card, #fff);
    border: 1px solid var(--border, rgba(198,153,62,0.2));
    border-radius: var(--radius, 16px);
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.2s;
}
.mantra-tile:hover { border-color: var(--accent); transform: translateX(4px); }
.mantra-tile-icon {
    width: 48px; height: 48px;
    flex-shrink: 0;
    border-radius: 50%;
    overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    background: var(--accent-glow, rgba(230,81,0,0.08));
    color: var(--accent);
    font-size: 1.3rem;
    font-weight: 700;
}
.mantra-tile-icon img { width: 100%; height: 100%; object-fit: cover; }
.mantra-tile-body { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.mantra-tile-title { font-weight: 600; font-size: 0.95rem; }
.mantra-tile-sub { font-size: 0.78rem; color: var(--text-muted); }

/* === DAILY PANCHANG === */
.panchang-hero {
    position: relative;
    text-align: center;
    padding: 26px 18px;
    border-radius: var(--radius-xl, 22px);
    color: #fff;
    background: linear-gradient(150deg, var(--day-color, #e8743b), #2d1b0e);
    margin: 8px 0 8px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(80,40,0,0.2);
}
.panchang-hero::after { content:'ॐ'; position:absolute; right:14px; top:6px; font-size:3.4rem; opacity:0.12; }
.ph-date { font-size: 0.82rem; opacity: 0.9; }
.ph-day { font-family: Georgia, serif; font-size: 1.8rem; font-weight: 700; margin: 4px 0; }
.ph-planet { font-size: 0.95rem; opacity: 0.95; }
.ph-color { font-size: 0.8rem; margin-top: 10px; display: inline-flex; align-items: center; gap: 6px; background: rgba(255,255,255,0.15); padding: 5px 12px; border-radius: 50px; }
.ph-swatch { width: 14px; height: 14px; border-radius: 50%; background: var(--day-color, #e8743b); border: 2px solid #fff; }

.panchang-mantra-card {
    text-align: center;
    padding: 20px;
    background: linear-gradient(160deg, #fff7ee, #fdeccf);
    border: 1px solid rgba(198,153,62,0.25);
    border-radius: var(--radius, 16px);
    margin-bottom: 16px;
}
.pmc-label { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 1.5px; color: var(--accent); font-weight: 700; }
.pmc-mantra { font-size: 1.25rem; font-weight: 700; color: var(--text-hindi, #2d1b0e); margin: 8px 0 14px; line-height: 1.8; }
.pmc-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.pmc-btn { background: #fff; border: 1px solid var(--border); border-radius: 50px; padding: 9px 16px; font-size: 0.82rem; font-weight: 600; color: var(--text-primary); text-decoration: none; transition: all 0.2s; min-height: 40px; display: inline-flex; align-items: center; }
.pmc-btn:hover { border-color: var(--accent); background: var(--accent-glow); }

.panchang-good { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; margin-bottom: 8px; }
.panchang-good h3 { font-size: 0.95rem; margin-bottom: 10px; }
.good-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.good-chip { background: rgba(46,125,50,0.08); color: #2e7d32; border: 1px solid rgba(46,125,50,0.2); border-radius: 50px; padding: 6px 12px; font-size: 0.8rem; font-weight: 500; }
.panchang-fast { margin-top: 12px; font-size: 0.85rem; color: var(--text-secondary); }

.timing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.timing-card { padding: 14px; border-radius: var(--radius); text-align: center; border: 1px solid var(--border); background: var(--bg-card); }
.timing-card.good { background: linear-gradient(160deg,#f1faf1,#e8f6e9); border-color: rgba(46,125,50,0.25); }
.timing-card.bad { background: linear-gradient(160deg,#fef4f2,#fdeae6); border-color: rgba(214,69,69,0.2); }
.tc-name { font-size: 0.85rem; font-weight: 700; }
.tc-time { font-size: 1.05rem; font-weight: 700; color: var(--text-primary); margin: 4px 0; }
.tc-note { font-size: 0.72rem; color: var(--text-muted); }
.panchang-disclaimer { font-size: 0.75rem; color: var(--text-muted); margin: 14px 0; text-align: center; line-height: 1.5; }
.panchang-detail-link { display: block; text-align: center; padding: 14px; background: var(--spiritual, #7b1fa2); color: #fff; border-radius: var(--radius); font-weight: 600; font-size: 0.9rem; text-decoration: none; margin-bottom: 8px; }
.panchang-detail-link:hover { opacity: 0.92; color:#fff; }

/* === DEITY HUB CARD GRID === */
.deity-search-box {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--bg-card, #fff);
    border: 1px solid var(--border, rgba(198,153,62,0.2));
    border-radius: 50px;
    margin-bottom: 12px;
}
.deity-search-box input {
    border: none; background: transparent; width: 100%; font-size: 0.92rem;
    color: var(--text-primary); outline: none; font-family: inherit;
}
.deity-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 14px;
}
.deity-card {
    display: flex;
    flex-direction: column;
    border-radius: var(--radius, 16px);
    overflow: hidden;
    background: var(--bg-card, #fff);
    border: 1px solid var(--border, rgba(198,153,62,0.2));
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
    box-shadow: 0 2px 8px rgba(80,40,0,0.04);
}
.deity-card:hover { border-color: var(--accent); transform: translateY(-4px); box-shadow: 0 12px 28px rgba(230,81,0,0.12); }
.deity-card:active { transform: scale(0.97); }
.deity-card-img {
    width: 100%; aspect-ratio: 1/1; overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(160deg, #fff7ee, #fef0db);
}
.deity-card-img img { width: 100%; height: 100%; object-fit: cover; }
.deity-card-placeholder { font-size: 2.5rem; opacity: 0.6; }
.deity-card-body { padding: 10px 12px 12px; text-align: center; }
.deity-card-title { font-weight: 700; font-size: 0.88rem; line-height: 1.3; margin-bottom: 2px; }
.deity-card-sub { font-size: 0.72rem; color: var(--text-muted); }

@media (max-width: 400px) {
    .deity-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* === SCRIPTURES GROUPED LISTING === */
.scripture-group { margin-bottom: 24px; }
.scripture-group-title {
    display: flex; align-items: center; gap: 10px;
    font-family: Georgia, serif; font-size: 1.15rem; font-weight: 700;
    color: var(--text-primary); margin-bottom: 12px; padding-left: 4px;
}
.scripture-group-icon { font-size: 1.4rem; }

/* === SCRIPTURE HERO CARDS (top grid with thumbnails) === */
.scripture-hero-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 14px;
    margin-bottom: var(--space-xl);
}
.scripture-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    background: var(--bg-card);
    border: 1.5px solid var(--border-card);
    border-radius: var(--radius-lg);
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s var(--ease-out);
    box-shadow: var(--shadow-sm);
}
.scripture-card:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-lg);
    transform: translateY(-3px);
}
.scripture-card:active { transform: scale(0.97); }
.sc-img {
    width: 72px; height: 72px;
    border-radius: var(--radius);
    overflow: hidden;
    flex-shrink: 0;
    background: linear-gradient(135deg, var(--bg-secondary), #fef3e0);
    display: flex; align-items: center; justify-content: center;
}
.sc-img img { width: 100%; height: 100%; object-fit: cover; }
.sc-img-fallback { font-size: 2rem; }
.sc-body { flex: 1; min-width: 0; }
.sc-title { font-weight: 700; font-size: var(--fs-base); margin-bottom: 2px; }
.sc-desc { font-size: var(--fs-xs); color: var(--text-muted); line-height: 1.4; margin-bottom: 4px; }
.sc-meta { font-size: var(--fs-xs); font-weight: 600; color: var(--accent); }

@media (max-width: 600px) {
    .scripture-hero-grid { grid-template-columns: 1fr; gap: 10px; }
    .sc-img { width: 60px; height: 60px; }
}

/* === SCRIPTURE SECTION (per-group) === */
.scripture-section { margin-bottom: var(--space-xl); }
.scripture-section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 2px solid var(--border);
    margin-bottom: var(--space-md);
}
.ssh-icon { font-size: 1.8rem; }
.ssh-text h2 { font-family: var(--font-heading); font-size: var(--fs-lg); margin: 0; }
.ssh-text p { font-size: var(--fs-xs); color: var(--text-muted); margin: 2px 0 0; }

/* === DEITY PROFILE HERO === */
.deity-profile-hero {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #fff9ee, #fef3e0);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-xl);
    margin-bottom: var(--space-lg);
    box-shadow: var(--shadow);
}
.dph-img {
    width: 100px; height: 100px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    border: 3px solid var(--temple-gold);
    box-shadow: var(--shadow-gold);
}
.dph-img img { width: 100%; height: 100%; object-fit: cover; }
.dph-body { flex: 1; }
.dph-name { font-family: var(--font-heading); font-size: var(--fs-xl); margin-bottom: 4px; }
.dph-english { font-size: var(--fs-sm); color: var(--text-secondary); margin-bottom: 8px; }

.deity-desc { margin-bottom: var(--space-lg); }
.deity-section { margin-bottom: var(--space-xl); }
.deity-section .section-header { padding-top: 0; }
.deity-section .section-header h3 { font-size: var(--fs-md); }

@media (max-width: 480px) {
    .deity-profile-hero { flex-direction: column; text-align: center; }
    .dph-img { width: 80px; height: 80px; }
}

/* === BROWSE BY DEITY (listing component) === */
.browse-back-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: var(--fs-sm);
    font-weight: 600;
    color: var(--accent);
    text-decoration: none;
    padding: 8px 0;
    margin-bottom: 4px;
}
.browse-back-link:hover { color: var(--accent-hover); }
.browse-deity-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 0 8px;
}
.bdh-img {
    width: 64px; height: 64px;
    border-radius: 50%;
    overflow: hidden;
    border: 2.5px solid var(--temple-gold);
    flex-shrink: 0;
}
.bdh-img img { width: 100%; height: 100%; object-fit: cover; }
.bdh-icon {
    width: 64px; height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--bg-secondary), #fff5e6);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.8rem; flex-shrink: 0;
    border: 1px solid var(--border);
}
.browse-deity-header h2 { font-family: var(--font-heading); font-size: var(--fs-xl); margin: 0; }
.browse-deity-header p { font-size: var(--fs-sm); color: var(--text-muted); margin: 2px 0 0; }

/* View More */
.lv-more-hidden { display: none !important; }
.lv-viewmore-btn {
    display: block;
    width: 100%;
    max-width: 320px;
    margin: var(--space-lg) auto 0;
    padding: 14px 24px;
    background: var(--bg-card);
    border: 1.5px solid var(--accent);
    color: var(--accent);
    border-radius: var(--radius-full);
    font-size: var(--fs-sm);
    font-weight: 700;
    cursor: pointer;
    transition: all var(--duration);
    min-height: 48px;
}
.lv-viewmore-btn:hover { background: var(--accent); color: #fff; box-shadow: var(--shadow-glow); }

/* === DEITY INFO GRID === */
.deity-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    margin-bottom: var(--space-lg);
}
