/* Qasedak Phase 3 — Poetry & History reading experience. Load after Phase 1. */
:root,[data-theme="dark"]{--read-bg:#071710;--read-card:#103322;--read-text:#f3fff6;--read-sub:#b8d7c4;--read-line:#28543d;--read-accent:#83c9a2;--read-tint:#16442c;--read-shadow:0 18px 48px rgba(0,0,0,.24)}
[data-theme="light"]{--read-bg:#f5faf6;--read-card:#fff;--read-text:#123d29;--read-sub:#42624f;--read-line:#c7dfd0;--read-accent:#176a43;--read-tint:#e9f5ed;--read-shadow:0 16px 44px rgba(21,72,44,.09)}
body:has(.protected-content),body:has(.poem-container),body:has(.section-container){background:var(--read-bg)!important;color:var(--read-text)}
body:has(.protected-content) .hero,body:has(.poem-container) .hero,body:has(.section-container) .hero{background:radial-gradient(ellipse at 80% 0%,#23865755,transparent 58%),linear-gradient(135deg,#071710,#123c29)!important;border-bottom:1px solid #28543d;padding:55px 18px!important;text-align:center;color:#f3fff6!important}
.hero h1,.hero p{color:#f3fff6!important}.hero .highlight{color:#83c9a2!important}.hero h1{font-size:clamp(1.8rem,4vw,3rem)!important;line-height:1.65!important}.hero p{opacity:.88}
.protected-content,.container:has(>.poem-container),.container:has(>.section-container){padding-top:24px;padding-bottom:36px}
.poetry-category-grid,.featured-grid{gap:20px!important}
.poetry-category-card,.featured-grid>.box,.poem-container,.section-container,.category-header-box,.content-box,.poet-profile{background:var(--read-card)!important;border:1px solid var(--read-line)!important;border-radius:18px!important;box-shadow:var(--read-shadow)!important;color:var(--read-text)!important;overflow:hidden}
.poetry-category-card,.featured-grid>.box{transition:transform .18s ease,border-color .18s ease}
.poetry-category-card:hover,.featured-grid>.box:hover{transform:translateY(-4px);border-color:#238657!important}
.poetry-category-card :is(h2,h3,p),.featured-grid>.box :is(.title,.content,p,h3),.content-box :is(h2,h3,p),.category-header-box :is(h2,h3,p){color:var(--read-text)!important}
.poetry-category-title,.featured-grid>.box>.title{background:var(--read-tint)!important;color:var(--read-text)!important;border-bottom:1px solid var(--read-line)!important}
.poetry-category-content,.featured-grid>.box>.content{background:var(--read-card)!important;color:var(--read-sub)!important}
.poetry-category-card img{object-fit:cover}.poetry-category-card a{color:var(--read-accent)}
.poetry-login-notice,.protected-content>div[style*="background:#eef4ff"]{background:var(--read-tint)!important;border:1px solid var(--read-line)!important;border-radius:14px!important;color:var(--read-text)!important;padding:16px!important}
.protected-content>div[style*="background:#eef4ff"] p,.poetry-login-notice p{color:var(--read-text)!important}
.poetry-login-notice a,.protected-content>div[style*="background:#eef4ff"] a{color:var(--read-accent)!important}
.poem-container{margin-bottom:22px!important}.poem-title-bar,.section-title-bar{background:linear-gradient(100deg,#145235,#238657)!important;color:white!important;padding:15px 20px!important;border:0!important}
.poem-title-bar *, .section-title-bar *{color:white!important}
.poem-body-flex,.poem-content-area,.poem-lines,.section-content-area,.section-content{background-color:var(--read-card)!important;color:var(--read-text)!important}
.poem-lines{padding:16px!important}.poem-lines .line{color:var(--read-text)!important;line-height:2.25!important;font-size:clamp(1rem,2vw,1.15rem)!important}
.poem-bg-image{opacity:.28!important}.poem-side-image img{border-radius:12px}
.section-content{line-height:2.2!important;font-size:1.05rem!important}.section-content p,.section-content-area p{color:var(--read-text)!important}
.category-header-box{padding:14px!important}.category-header-box>div{background:var(--read-card)!important;color:var(--read-text)!important}
.left-column .content-box{padding:22px!important;border-right:3px solid #238657!important}.left-column .content-box p{line-height:2.05}
:where(.protected-content,.poem-container,.section-container) a{color:var(--read-accent)}
@media(max-width:760px){.featured-grid{grid-template-columns:1fr!important}.poetry-category-grid{grid-template-columns:1fr!important}.poem-body-flex{flex-direction:column!important}.poem-side-image{max-width:100%!important}.hero{padding:36px 14px!important}.poem-lines{padding:12px!important}}
@media(prefers-reduced-motion:reduce){.poetry-category-card,.featured-grid>.box{transition:none!important}}
