/* ==========================================================
   SURAH SHOW PAGE (AYAH READING) — MOSQUE-ARCH STYLE
   Quran Project — matches surah-index.css palette
========================================================== */

.surah-show-page {
    padding: 50px 0 100px;
}

/*==============================
Header Panel
==============================*/

.surah-header {
    position: relative;
    background: linear-gradient(180deg, #FFFDF6 0%, #F6EEDA 100%);
    border: 1.5px solid #145C42;
    border-radius: 14px;
    padding: 38px 40px 30px;
    margin-bottom: 34px;
    text-align: center;

    box-shadow:
        0 1px 0 rgba(255,255,255,.9) inset,
        0 22px 40px -18px rgba(20,45,35,.35),
        0 8px 16px -8px rgba(20,45,35,.25);
}

.surah-panel-corner {
    position: absolute;
    width: 24px;
    height: 24px;
    border: 1.5px solid #C9A227;
}

.surah-panel-corner.tl { top: 8px; right: 8px; border-left: none; border-bottom: none; }
.surah-panel-corner.tr { top: 8px; left: 8px;  border-right: none; border-bottom: none; }
.surah-panel-corner.bl { bottom: 8px; right: 8px; border-left: none; border-top: none; }
.surah-panel-corner.br { bottom: 8px; left: 8px;  border-right: none; border-top: none; }

.back-surah {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: #145C42;
    font-size: 13.5px;
    font-weight: 600;
    background: #fff;
    border: 1px solid rgba(20,92,66,.3);
    border-radius: 30px;
    padding: 8px 16px;
    margin-bottom: 22px;
    transition: .2s;
}

.back-surah:hover {
    border-color: #C9A227;
    color: #0F4A32;
}

.back-surah svg {
    width: 15px;
    height: 15px;
    transform: rotate(180deg);
}

.surah-header h1 {
    font-family: 'Amiri', serif;
    font-size: 34px;
    font-weight: 700;
    color: #0F4A32;
    margin-bottom: 14px;
}

.surah-header .surah-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    color: #7A8A84;
}

.surah-header .type-pill {
    font-size: 11px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
}

.surah-header .type-pill.makki {
    background: rgba(201,162,39,.15);
    color: #9C7A15;
}

.surah-header .type-pill.madani {
    background: rgba(20,92,66,.12);
    color: #145C42;
}

.surah-header .dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #C4CEC8;
}

/* حالت آخرین محل مطالعه */
.surah-header.last-read-surah {
    border-color: #C9A227;
}

/*==============================
Bismillah
==============================*/

.surah-bismillah {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    font-family: 'Amiri', serif;
    font-size: 36px;
    font-weight: 700;
    color: #0F4A32;
    text-align: center;
    margin-bottom: 36px;
}

.bismillah-flourish {
    width: 70px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #C9A227, transparent);
}

/*==============================
Ayah List
==============================*/

.ayah-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.ayah {
    position: relative;
    background: linear-gradient(180deg, #FFFDF7 0%, #F5EDD9 100%);
    border: 1px solid rgba(20,92,66,.25);
    border-radius: 14px;
    padding: 26px 28px;

    box-shadow:
        0 1px 0 rgba(255,255,255,.85) inset,
        0 12px 20px -14px rgba(20,45,35,.25),
        0 4px 8px -4px rgba(20,45,35,.15);

    transition: box-shadow .3s ease, border-color .3s ease, background .4s ease;
}

.ayah-arabic {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    text-align: center;
}

.ayah-number {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1.3px solid #C9A227;
    background: rgba(201,162,39,.08);
    color: #9C7A15;
    font-family: 'Vazirmatn', sans-serif;
    font-size: 13px;
    font-weight: 700;
}

.ayah-text {
    width: 100%;
    font-family: 'Amiri', serif;
    font-size: 38px;
    line-height: 2.1;
    color: #16241D;
    text-align: center;
}

.ayah-persian {
    font-family: 'Vazirmatn', sans-serif;
    font-size: 16px;
    line-height: 2;
    color: #5C6B62;
    text-align: center;
    margin-bottom: 18px;
}

/*==============================
Actions Toolbar
==============================*/

.ayah-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 16px;
    border-top: 1px solid rgba(20,92,66,.12);
}

.ayah-audio-group {
    display: flex;
    gap: 6px;
}

.ayah-tool {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'Vazirmatn', sans-serif;
    font-size: 12.5px;
    font-weight: 600;
    color: #145C42;
    background: #fff;
    border: 1px solid rgba(20,92,66,.25);
    border-radius: 30px;
    padding: 7px 14px;
    cursor: pointer;
    transition: .2s;
}

.ayah-tool svg {
    width: 14px;
    height: 14px;
}

.ayah-tool:hover {
    border-color: #C9A227;
    color: #0F4A32;
}

.ayah-tool.playing {
    background: #145C42;
    border-color: #145C42;
    color: #F3DA9A;
}

.action-divider {
    width: 1px;
    height: 20px;
    background: rgba(20,92,66,.18);
    margin: 0 4px;
}

.font-minus,
.font-plus {
    padding: 7px 12px;
    font-weight: 800;
}

/*==============================
States: last-read / preview-focus
==============================*/

.ayah.last-read {
    border-color: #C9A227;
    background: linear-gradient(180deg, #FFF9E9 0%, #FBEFC9 100%);
    box-shadow:
        0 1px 0 rgba(255,255,255,.9) inset,
        0 14px 24px -14px rgba(180,140,20,.3);
}

.ayah.preview-focus {
    animation: previewPulse 1.4s ease-in-out;
}

@keyframes previewPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(201,162,39,0); }
    30% { box-shadow: 0 0 0 6px rgba(201,162,39,.25); }
}

/*==========================================================
Responsive
==========================================================*/

@media (max-width: 640px) {

    .surah-header {
        padding: 28px 20px 24px;
    }

    .surah-header h1 {
        font-size: 26px;
    }

    .surah-bismillah {
        font-size: 28px;
        gap: 10px;
    }

    .bismillah-flourish {
        width: 36px;
    }

    .ayah {
        padding: 20px 16px;
    }

    .ayah-text {
        font-size: 28px !important;
    }

    .ayah-persian {
        padding-right: 0;
        margin-top: 10px;
    }

    .ayah-arabic {
        flex-wrap: wrap;
    }

}
