
        :root { --accent: #198754; --bg: #f4f7f9; --gray: #495057; }
        body { background-color: var(--bg); font-family: 'Segoe UI', Tahoma, sans-serif; display: flex; flex-direction: column; min-height: 100vh; margin: 0; padding: 15px; box-sizing: border-box; }
        .main-content { flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: center; margin-top: 85px !important;}
        .card { background: white; padding: 40px; border-radius: 25px; box-shadow: 0 10px 40px rgba(0,0,0,0.06); width: 100%; max-width: 950px; text-align: center; border-top: 6px solid var(--accent); box-sizing: border-box; position: relative; }
        .logo { max-width: 100%; width: 500px; height: auto; margin: 0 auto 15px auto; display: block; }
        .page-title { font-family: 'Poppins', 'Tajawal', sans-serif; color: #212529 !important; margin: 0 auto 35px auto; font-weight: 600; font-size: clamp(18px, 4vw, 24px); line-height: 1.5; letter-spacing: -0.2px; opacity: 0.9; text-shadow: 0 1px 2px rgba(0,0,0,0.05); }
        .input-row { display: flex; gap: 10px; margin-bottom: 20px; align-items: center; justify-content: center; flex-wrap: wrap; }
        input, select { padding: 12px 15px; border: 1px solid #ced4da; border-radius: 12px; font-size: 16px; background-color: #f1f3f5; outline: none; box-sizing: border-box; }
        #numIn { flex: 2; min-width: 200px; background-color: white; border: 2px solid var(--accent); font-weight: bold; font-size: 24px; text-align: center; direction: ltr !important; unicode-bidi: bidi-override !important; }
        .btn-convert { background-color: #157347 !important; color: #ffffff !important; border: none; padding: 12px 25px; border-radius: 12px; cursor: pointer; font-weight: 700 !important; font-size: 18px; transition: 0.3s; flex: 1; min-width: 140px; }
        .btn-convert:hover { background-color: #218838; transform: translateY(-2px); }
        .btn-clear { background-color: #e9ecef; color: #2d3748 !important; border: 1px solid #ced4da; padding: 12px 20px; border-radius: 12px; cursor: pointer; font-weight: bold; font-size: 16px; transition: 0.3s; min-width: 100px; }
        .btn-clear:hover { background-color: #dee2e6; color: #333; }
        .result-box { background-color: #f8f9fa; border: 1px solid #dee2e6; border-radius: 15px; padding: 30px 20px; min-height: 100px; display: flex; align-items: center; justify-content: center; font-size: clamp(18px, 4vw, 22px); color: #2c3e50; font-weight: 500; text-align: center; line-height: 1.6; word-wrap: break-word; overflow-wrap: anywhere; }
        .copy-btn { margin-top: 20px; background: #edf2f7; border: none; padding: 10px 25px; border-radius: 8px; cursor: pointer; color: #2d3748 !important; font-weight: bold; }
        footer { text-align: center; padding: 30px 20px; font-size: 14px; color: #4a5568 !important; margin-top: 20px; display: flex; flex-direction: column; gap: 10px; direction: ltr !important; }
        .footer-links { display: flex; justify-content: center; gap: 20px; flex-wrap: wrap; }
        footer a { color: #2d3748 !important; text-decoration: underline; cursor: pointer; font-weight: bold; transition: 0.3s; }
        footer a:hover { color: var(--accent); }
        .modal { display: none; position: fixed; z-index: 1000; left: 0; top: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); overflow-y: auto; }
        .modal-content { background: white; margin: 5% auto; padding: 30px; width: 90%; max-width: 700px; border-radius: 20px; text-align: left; line-height: 1.6; direction: ltr; }
        .modal-content h2 { border-bottom: 2px solid var(--accent); padding-bottom: 10px; }
        .close-btn { float: right; font-size: 28px; font-weight: bold; cursor: pointer; }
        .desc-container { width: 100%; max-width: 850px; margin: 20px auto; padding: 0 20px; box-sizing: border-box; text-align: center; }
        #dynamicDesc { color: #343a40 !important; font-size: clamp(14px, 3.5vw, 16px); line-height: 1.6; font-family: 'Poppins', 'Tajawal', sans-serif; margin: 0; opacity: 0.8; font-weight: 600;}
        @media (max-width: 600px) { .input-row { flex-direction: column; align-items: stretch; } #numIn, select, .btn-convert, .btn-clear { width: 100%; } }
		
		
   .seo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    width: 100%; 
    max-width: 950px; 
    margin: 40px auto;
    padding: 0; 
    box-sizing: border-box;
}

   .seo-card {
    background: white;
    padding: 30px;
    border-radius: 25px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.04);
    border-top: 6px solid var(--accent);
    text-align: inherit; 
    box-sizing: border-box;
}


@media (max-width: 600px) {
    .seo-grid {
        grid-template-columns: 1fr; 
        gap: 15px;
        padding: 0; 
    }
    .seo-card {
        padding: 20px;
        border-radius: 20px;
    }
}
	

#toast {
    visibility: hidden;
    min-width: 250px;
    background-color: #28a745; 
    color: #fff;
    text-align: center;
    border-radius: 12px;
    padding: 16px;
    position: fixed;
    z-index: 10000;
    left: 50%;
    top: -100px; 
    transform: translateX(-50%);
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    transition: top 0.4s, visibility 0.4s, opacity 0.4s;
    opacity: 0;
}

#toast.show {
    visibility: visible;
    top: 30px; 
    opacity: 1;
}



.result-box-container {
    position: relative; 
    width: 100%;
}

.speak-btn {
    position: absolute;
    right: 0px;
    top: -35px;
    background: white;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.speak-btn:hover {
    background-color: var(--accent);
    color: white;
    transform: scale(1.1);
}

.speak-btn svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
    color: var(--gray);
}

.speak-btn:hover svg {
    color: white;
}


@media (max-width: 600px) {
    .speak-btn {
        right: 0px;
        top: -35px;
        padding: 6px;
    }
}


.guide-container { 
    margin-top: 85px; 
    text-align: inherit; 
    padding: 45px !important; 
    background: #fff; 
    border-bottom: 8px solid #eee; 
    border-radius: 25px; 
    box-shadow: 0 10px 40px rgba(0,0,0,0.06);
    border-top: 6px solid var(--accent);
    box-sizing: border-box;
}

.guide-header { border-bottom: 2px solid #f4f4f4; margin-bottom: 30px; padding-bottom: 15px; }
.guide-header h2 { color: var(--accent); font-size: 28px; font-weight: 700; margin: 0; }
.guide-body { 
    color: #4a5568; 
    line-height: 1.9; 
    font-size: 17px; 
   
    overflow-x: auto; 
    width: 100%;
    -webkit-overflow-scrolling: touch;
}

.guide-table { 
    width: 100%; 
    border-collapse: collapse; 
    margin: 20px 0; 
    font-size: 15px; 
    
    min-width: 500px; 
}

.guide-table th, .guide-table td { 
    border: 1px solid #eee; 
    padding: 10px; 
    text-align: center !important; 
    white-space: nowrap;
}


.guide-body h3 { 
    color: #2d3748; 
    margin-top: 35px; 
    font-size: 21px; 
    border-left: 5px solid var(--accent); 
    padding-left: 15px; 
}

.guide-body p { margin-bottom: 20px; }


[style*="direction: rtl"] .guide-container {
    text-align: right !important; 
}

[style*="direction: rtl"] .guide-body h3 { 
    border-left: 0; 
    border-right: 5px solid var(--accent); 
    padding-left: 0; 
    padding-right: 15px; 
}

@media (max-width: 600px) {
    .guide-container { padding: 25px 20px !important; }
    .guide-header h2 { font-size: 22px; }
}
		
		
	.guide-table { 
    width: 100%; 
    border-collapse: collapse; 
    margin: 20px 0; 
    font-size: 15px;
    table-layout: auto; 
}

.guide-table th, .guide-table td { 
    border: 1px solid #eee; 
    padding: 12px 8px; 
    text-align: center !important; 
    word-break: keep-all; 
}

.guide-table th { background-color: #155724 !important; color: #ffffff !important; font-weight: bold; }


@media (max-width: 600px) {
    
    .guide-body {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .guide-table {
        font-size: 12px; 
        min-width: 400px; 
    }

    .guide-table th, .guide-table td {
        padding: 8px 4px; 
    }
}	
	

footer { 
    text-align: center; 
    padding: 30px 20px; 
    font-size: 14px; 
    color: #212529 !important; 
    margin-top: 30px;
    display: flex;
    flex-direction: column; 
    gap: 10px;
    direction: ltr !important; 
    width: 100%;
    box-sizing: border-box;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 25px; 
    flex-wrap: wrap;
}

footer a { 
    color: #155724 !important; 
    text-decoration: underline !important; 
    cursor: pointer; 
    font-weight: 600; 
    transition: 0.3s;
}

footer a:hover { color: #28a745; text-decoration: underline; }

@media (max-width: 600px) {
    .footer-links {
        flex-direction: column; 
        gap: 15px; 
    }
}




.top-navbar {
    width: 100%;
    background-color: #ffffff;
    position: fixed;
    top: 0;
    left: 0;
    height: 60px;
    display: flex;
    align-items: center;
    z-index: 9999;
    border-bottom-left-radius: 17px;  
    border-bottom-right-radius: 17px;
    border-bottom: 2px solid var(--accent) !important; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.nav-container {
    width: 100%;
    padding: 0 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative; /* مهم */
    height: 100%;
}


.nav-center {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}




.nav-right {
    flex: 1;
}


.nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 50px;
}

.nav-links a {
    text-decoration: none;
    color: #4a5568;
    font-weight: 600;
    transition: 0.3s;
    white-space: nowrap;
    font-size: 14px;
}

.nav-links a:hover {
    color: var(--accent);
}


.menu-toggle {
    display: none;
    font-size: 28px;
    cursor: pointer;
}


@media (min-width: 601px) {
.nav-links {
        display: flex !important;
    }
}

.nav-container {
    justify-content: center !important; 
}

.menu-icon {
    display: none; 
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.menu-icon span {
    width: 30px;
    height: 4px;
    background-color: var(--accent);
    border-radius: 2px;
}


@media (max-width: 600px) {
    .menu-icon {
        display: flex; 
    }

    .nav-links {
        display: none; 
        flex-direction: column;
        position: absolute;
        top: 65px; 
        left: 50%;
        transform: translateX(-50%);
        background: white;
        width: column;
        padding: 20px;
        border-radius: 20px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        border: 1px solid #eee;
        z-index: 10000;
        gap: 30px;
		
    }


    .nav-links.active {
        display: flex !important;
    }

    .nav-links a {
        font-size: 16px !important;
        width: 100%;
        text-align: center;
        border-bottom: 1px solid #f1f1f1;
        padding-bottom: 6px;
        color: #2d3748 !important;
    }

}






