/* General Body Styles */
body.page-template-elementor_canvas {
    background: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.4)), url('https://khatma.sadakatalmohbeen.online/wp-content/uploads/2026/01/meka.gif' ) no-repeat center center fixed;
    background-size: cover;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: 'Noto Kufi Arabic', sans-serif;
    color: white;
    text-align: center;
    height: 100vh;
    margin: 0;
    overflow: hidden;
    box-sizing: border-box;
}

/* === التعديل الحاسم: رفع الحاوية بالكامل للأعلى === */
#khatma-container {
    width: 95%;
    max-width: 450px;
    padding: 15px;
    box-sizing: border-box;
    position: relative;
    /* هذه هي القاعدة السحرية التي سترفع المحتوى بالكامل */
    transform: translateY(-5%); 
}

/* Share Button Style */
#khatma-share-button {
    position: absolute;
    top: -10px; /* تعديل بسيط ليتناسب مع الرفع */
    right: 0;
    color: white;
    cursor: pointer;
    z-index: 10;
    padding: 10px;
    opacity: 0.8;
    transition: opacity 0.3s;
}
#khatma-share-button:hover {
    opacity: 1;
}

/* Fixed WhatsApp Button Style */
#khatma-whatsapp-button {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #007bff;
    color: white;
    padding: 10px 20px; /* حجم مناسب للموبايل */
    border-radius: 30px;
    text-decoration: none;
    font-size: 15px; /* خط متوسط */
    font-weight: bold;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    z-index: 100;
    transition: background-color 0.3s, transform 0.3s;
    white-space: nowrap;
}
#khatma-whatsapp-button:hover {
    background-color: #0056b3;
    transform: translateX(-50%) scale(1.05);
}

/* ================= EXISTING STYLES ================= */

.khatma-header #khatma-title {
    font-family: 'Aref Ruqaa', serif;
    font-size: 28px;
    font-weight: 700;
    color: #f0e68c;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
    margin-bottom: 15px;
}

#khatma-image {
    width: 180px; /* تصغير بسيط للصورة لإعطاء مساحة أكبر */
    height: 180px;
    border-radius: 50%;
    border: 4px solid white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
    object-fit: cover;
    margin-bottom: 10px;
    transition: transform 0.5s ease, box-shadow 0.5s ease;
}
#khatma-image.playing {
    transform: scale(1.05);
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.7);
}

.khatma-dedication {
    font-size: 18px;
    margin: 10px 0 5px 0;
}

#khatma-person-name {
    font-family: 'Aref Ruqaa', serif;
    font-size: 34px;
    font-weight: bold;
    color: #98fb98;
    animation: flashingColors 4s infinite;
    margin: 0 0 15px 0;
}

.khatma-player {
    background-color: rgba(0,0,0,0.3);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 10px; /* مسافة بين المشغل والشريط المتحرك */
}

#khatma-time-info {
    font-size: 16px;
    margin-bottom: 10px;
}

#khatma-play-pause-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 10px 25px;
    font-size: 18px;
    border-radius: 25px;
    cursor: pointer;
    margin-bottom: 10px;
    transition: background-color 0.3s;
}
#khatma-play-pause-btn:hover {
    background-color: #218838;
}

#khatma-parts-list {
    width: 100%;
    padding: 8px;
    border-radius: 5px;
    border: 1px solid #ccc;
    background-color: #fff;
    color: #333;
    direction: rtl;
}

#khatma-marquee {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    background-color: rgba(255, 255, 255, 0.8);
    color: #00008B;
    padding: 10px 0;
    border-radius: 5px;
    font-family: 'Aref Ruqaa', serif;
    font-size: 20px;
}
#khatma-marquee div {
    display: inline-block;
    padding-left: 100%;
    animation: marquee-animation 40s linear infinite;
}

@keyframes flashingColors {
    0%, 100% { color: #98fb98; text-shadow: 0 0 10px #98fb98; }
    50% { color: #fff; text-shadow: none; }
}

@keyframes marquee-animation {
    0% { transform: translateX(0%); }
    100% { transform: translateX(-100%); }
}
