.fawasel-hero{
    padding:20px 22px;
    display:grid;
    grid-template-columns:minmax(0,1fr) minmax(420px,680px);
    gap:18px;
    align-items:center;
    margin-bottom:16px;
    background:linear-gradient(135deg,rgba(255,250,240,.96),rgba(255,240,205,.9));
}

.fw-kicker{
    display:inline-flex;
    background:#fff;
    border:1px solid rgba(185,138,47,.32);
    color:#8e5d22;
    border-radius:999px;
    padding:7px 12px;
    font-weight:900;
    margin-bottom:8px;
}

.fawasel-hero h2{
    margin:0;
    color:#5b3a18;
    font-size:34px;
    font-weight:900;
}

.fawasel-hero p{
    margin:8px 0 0;
    color:#746956;
    font-size:16px;
    line-height:1.8;
}

.fw-form{
    display:grid;
    gap:10px;
}

.fw-search-box{
    display:grid;
    grid-template-columns:1fr 1fr auto;
    gap:9px;
    align-items:end;
}

.fw-search-box label{
    display:grid;
    gap:5px;
    background:rgba(255,255,255,.75);
    border:1px solid rgba(91,58,24,.18);
    border-radius:16px;
    padding:10px 12px;
}

.fw-search-box span{
    color:#746956;
    font-size:13px;
    font-weight:900;
}

.fw-search-box select{
    border:0;
    outline:0;
    background:transparent;
    color:#5b3a18;
    font-size:17px;
    font-weight:900;
    font-family:Tajawal,Arial,sans-serif;
}

.fw-search-box button{
    border:0;
    border-radius:16px;
    padding:18px 20px;
    min-width:140px;
    color:#fff;
    background:linear-gradient(135deg,#8e5d22,#c99a3e);
    font-weight:900;
    font-family:Tajawal,Arial,sans-serif;
    cursor:pointer;
}

.fw-options{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
    color:#5b3a18;
    font-weight:900;
}

.fw-options label{
    background:#fff;
    border:1px solid rgba(91,58,24,.15);
    border-radius:999px;
    padding:8px 12px;
}

.fawasel-layout{
    display:grid;
    grid-template-columns:420px minmax(0,1fr) 330px;
    gap:16px;
    align-items:start;
}

.fw-mushaf-panel,
.fw-side-panel{
    position:sticky;
    top:124px;
}

.fw-mushaf-frame{
    background:#f3e5c5;
    padding:14px;
    min-height:620px;
    display:flex;
    align-items:center;
    justify-content:center;
}

.fw-mushaf-img{
    display:block;
    width:100%;
    max-width:100%;
    max-height:760px;
    object-fit:contain;
    background:#fff;
    border-radius:13px;
    box-shadow:0 18px 38px rgba(0,0,0,.16);
    border:1px solid rgba(91,58,24,.14);
}

.fw-placeholder{
    text-align:center;
    font-family:Amiri,serif;
    color:#5b3a18;
    line-height:2;
}

.fw-placeholder span{
    display:block;
    font-size:30px;
    font-weight:900;
}

.fw-mushaf-tools{
    display:flex;
    gap:8px;
    padding:12px 14px 16px;
    border-top:1px solid rgba(91,58,24,.12);
}

.fw-mushaf-tools a{
    flex:1;
    text-align:center;
    background:#fff;
    border:1px solid rgba(91,58,24,.18);
    border-radius:14px;
    padding:10px;
    font-weight:900;
    color:#5b3a18;
}

.fw-summary{
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:10px;
    padding:14px;
}

.fw-summary div{
    background:#fff;
    border:1px solid rgba(91,58,24,.16);
    border-radius:18px;
    padding:14px;
    text-align:center;
}

.fw-summary b{
    display:block;
    color:#b3342c;
    font-size:28px;
    font-weight:900;
}

.fw-summary span{
    color:#746956;
    font-size:13px;
    font-weight:900;
}

.fw-ayat-list{
    padding:0 14px 16px;
    display:grid;
    gap:12px;
    max-height:860px;
    overflow:auto;
}

.fw-ayah-card{
    background:#fffdf7;
    border:1px solid rgba(91,58,24,.16);
    border-radius:20px;
    padding:16px;
    transition:.2s;
    cursor:pointer;
}

.fw-ayah-card:hover,
.fw-ayah-card.active{
    border-color:rgba(179,52,44,.48);
    box-shadow:0 16px 32px rgba(179,52,44,.10);
    background:linear-gradient(135deg,#fffdf7,#fff5df);
}

.fw-card-head{
    display:flex;
    justify-content:space-between;
    gap:10px;
    flex-wrap:wrap;
    margin-bottom:10px;
}

.fw-card-head strong{
    color:#5b3a18;
    font-weight:900;
}

.fw-card-head span{
    color:#746956;
    font-size:13px;
    font-weight:900;
}

.fw-ayah-text{
    font-family:Amiri,serif;
    font-size:28px;
    line-height:2.2;
    color:#1f1a12;
}

.fw-fasela-mark{
    color:#d10000 !important;
    background:rgba(255,0,0,.10) !important;
    border-bottom:2px solid #d10000;
    padding:0 4px;
    border-radius:5px;
    font-weight:900;
}

.fw-meta-row{
    display:flex;
    gap:8px;
    flex-wrap:wrap;
    margin-top:10px;
}

.fw-meta-row span{
    background:#fff8e8;
    border:1px solid rgba(91,58,24,.14);
    color:#5b3a18;
    border-radius:999px;
    padding:6px 10px;
    font-weight:900;
    font-size:13px;
}

.fw-actions{
    display:flex;
    gap:8px;
    flex-wrap:wrap;
    margin-top:12px;
}

.fw-actions a{
    border:1px solid rgba(91,58,24,.18);
    background:#fff8e8;
    color:#5b3a18;
    border-radius:13px;
    padding:9px 12px;
    font-weight:900;
    font-size:13px;
}

.fw-letters-list{
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:8px;
    padding:12px;
    max-height:360px;
    overflow:auto;
}

.fw-letter-item{
    display:grid;
    place-items:center;
    gap:4px;
    background:#fff;
    border:1px solid rgba(91,58,24,.16);
    border-radius:15px;
    padding:10px 6px;
    color:#5b3a18;
}

.fw-letter-item b{
    font-size:24px;
    font-weight:900;
}

.fw-letter-item span{
    color:#746956;
    font-size:12px;
    font-weight:900;
}

.fw-letter-item.active{
    background:linear-gradient(135deg,#8e5d22,#c99a3e);
    color:#fff;
}

.fw-letter-item.active span{
    color:#fff;
}

.fw-surah-box{
    border-top:1px solid rgba(91,58,24,.12);
}

.panel-head.mini{
    min-height:auto;
    padding:12px 14px;
}

.fw-surah-list{
    display:grid;
    gap:7px;
    padding:12px;
    max-height:430px;
    overflow:auto;
}

.fw-surah-item{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:8px;
    background:#fff;
    border:1px solid rgba(91,58,24,.16);
    border-radius:14px;
    padding:10px 12px;
    color:#5b3a18;
    font-weight:900;
}

.fw-surah-item b{
    background:#fff8e8;
    border:1px solid rgba(91,58,24,.12);
    border-radius:999px;
    padding:4px 9px;
}

.fw-surah-item.active{
    background:linear-gradient(135deg,#fff7df,#fff);
    border-color:rgba(179,52,44,.45);
    box-shadow:0 10px 24px rgba(179,52,44,.10);
}

.fw-compact .fw-ayah-card:not(.active){
    padding:10px 14px;
}

.fw-compact .fw-ayah-card:not(.active) .fw-ayah-text{
    max-height:70px;
    overflow:hidden;
}

.fw-hide-segment .fw-meta-row{
    display:none;
}

.fw-hide-part .fw-ayah-text{
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}

@media(max-width:1300px){
    .fawasel-layout{
        grid-template-columns:380px minmax(0,1fr);
    }

    .fw-side-panel{
        grid-column:1/-1;
        position:relative;
        top:auto;
    }

    .fw-letters-list{
        grid-template-columns:repeat(8,1fr);
    }

    .fw-surah-list{
        grid-template-columns:repeat(3,1fr);
        max-height:none;
    }
}

@media(max-width:900px){
    .fawasel-hero{
        grid-template-columns:1fr;
    }

    .fawasel-layout{
        grid-template-columns:1fr;
    }

    .fw-mushaf-panel,
    .fw-side-panel{
        position:relative;
        top:auto;
    }

    .fw-search-box{
        grid-template-columns:1fr;
    }

    .fw-summary{
        grid-template-columns:1fr;
    }

    .fw-letters-list{
        grid-template-columns:repeat(5,1fr);
    }

    .fw-surah-list{
        grid-template-columns:1fr;
    }

    .fw-mushaf-frame{
        min-height:auto;
    }

    .fw-mushaf-img{
        max-width:420px;
    }

    .fw-ayat-list{
        max-height:none;
    }
}

@media(max-width:520px){
    .fawasel-hero{
        padding:14px;
    }

    .fawasel-hero h2{
        font-size:27px;
    }

    .fw-ayah-text{
        font-size:23px;
        line-height:2;
    }

    .fw-letters-list{
        grid-template-columns:repeat(4,1fr);
    }

    .fw-card-head{
        display:grid;
    }

    .fw-actions a{
        width:100%;
        text-align:center;
    }
}