/* Explain: Styling for the poems page, including hero and unified poem cards. */
/* ---------- صفحة القصائد والأشعار ---------- */
.poems-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    min-height: 46vh;
    padding-block: 3.5rem;
    border-bottom: 1px solid var(--border-soft);
}

.poems-hero-media {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.35;
    pointer-events: none;
}

.poems-hero-scrim {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        radial-gradient(700px 320px at 92% -12%, rgba(212, 175, 55, 0.16), transparent 62%),
        linear-gradient(180deg, rgba(11, 18, 32, 0.72), rgba(11, 18, 32, 0.94));
}

.poems-hero-inner {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    max-width: 680px;
}

.poems-hero-title {
    font-family: var(--font-heading);
    font-weight: 900;
    font-size: clamp(1.7rem, 5.4vw, 2.9rem);
    line-height: 1.35;
    color: var(--text-color);
}

.poems-hero-sub {
    font-size: 1rem;
    line-height: 2;
    color: var(--text-muted);
}

.poems-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.35rem;
}

/* شبكة القصائد */
.poems-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 768px) {
    .poems-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
}

@media (min-width: 1280px) {
    .poems-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.poem-card {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
    height: 100%;
    padding: 1.5rem 1.4rem 1.35rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(160deg, var(--surface-2), var(--surface-color));
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-card);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.poem-card:hover {
    transform: translateY(-4px);
    border-color: rgba(212, 175, 55, 0.4);
}

.poem-head {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.poem-cover {
    flex-shrink: 0;
    width: 72px;
    height: 72px;
    border-radius: 12px;
    overflow: hidden;
    background: radial-gradient(circle at 32% 24%, #1d2a48, var(--surface-color));
    border: 1px solid var(--border-soft);
}

.poem-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.poem-head-text { flex: 1 1 auto; min-width: 0; }

.poem-title {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-color);
    overflow-wrap: anywhere;
}

.poem-poet {
    margin-top: 0.3rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
    overflow-wrap: anywhere;
}

.poem-poet i {
    color: var(--primary-color);
    font-size: 0.78rem;
    flex-shrink: 0;
}

.poem-badge {
    flex-shrink: 0;
    align-self: flex-start;
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    background: rgba(212, 175, 55, 0.12);
    border: 1px solid rgba(212, 175, 55, 0.34);
    color: var(--gold-soft);
    font-size: 0.74rem;
    font-weight: 700;
    white-space: nowrap;
}

.poem-text {
    flex: 1 1 auto;
    white-space: pre-line;
    font-size: 0.98rem;
    line-height: 2.15;
    color: var(--text-color);
    overflow-wrap: anywhere;
}

/* نص القصيدة داخل بطاقة العرض الموحّدة zafat-box */
.poem-body {
    margin-top: 0.95rem;
    padding: 0.9rem 1rem;
    border-radius: var(--radius-md);
    background: var(--surface-2);
    border: 1px solid var(--border-soft);
    white-space: pre-line;
    font-size: 0.98rem;
    line-height: 2.15;
    color: var(--text-color);
    overflow-wrap: anywhere;
}

.poem-foot {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--border-soft);
}

@media (max-width: 480px) {
    .poem-card { padding: 1.25rem 1.1rem; }
    .poem-cover { width: 60px; height: 60px; }
    .poem-foot .btn-order { width: 100%; }
}