/* --- Container and Text Animation --- */

.body {
    padding-left: 3vw;
    padding-right: 3vw;
    box-sizing: border-box; /* يجعل الـ padding محسوبًا ضمن الحجم الفعلي */
}

.container {
    width: 100%;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
  }
  
  .text {
    font-size: 5vw; /* يجعل الحجم ديناميكي بناءً على عرض الشاشة */
    max-width: 75vw; /* يضمن عدم تجاوز 75% من الشاشة */
    white-space: nowrap; /* يمنع انقسام النص */
    position: absolute;
    top: -50px; /* يبدأ خارج الشاشة */
    left: 50%; /* يجعله يبدأ من المنتصف */
    transform: translateX(-50%); /* يعيده للوسط تمامًا */
    color: white;
    font-weight: bolder;
    opacity: 0;
    text-align: center; /* يضمن أن النص متوازن */
    transition: top 1.5s ease-out, opacity 1.5s ease-out;
}

/* عندما تكون الشاشة صغيرة جدًا (مثلاً جوال) */
@media (max-width: 500px) {
    .text {
        font-size: 7vw; /* تكبير النص قليلاً ليظل مقروءًا */
        max-width: 90vw; /* يوسع المساحة قليلًا على الهواتف */
    }
}

  
  .text.show {
    top: 50px; /* موقع النص النهائي */
    opacity: 1;
  }
  
  /* --- Global Styles --- */
  body {
    background-color: black;
    margin: 0;
    padding: 0;
    font-family: Arial, Helvetica, sans-serif;
  }
  
  /* --- Heading and Paragraph Styles --- */
  h1.test1 {
    color: blue;
    font-size: 30px;
    font-weight: 500; /* استخدام قيمة رقمية للوزن */
  }
  
  p.test1 {
    color: red;
  }
  
  p.test2 {
    color: darkgreen;
  }
  
  p.test3 {
    color: olivedrab;
    line-height: 30px; /* المسافة بين النصوص */
  }
  
  p.test4 {
    color: red;
    text-align: left;
    direction: rtl;
  }
  
  /* --- Box and Image --- */
  div.box {
    background: aquamarine;
    width: 200px;
    padding: 20px;
    border: 5px solid black;
    border-radius: 15px;
    color: blue;
    text-align: center;
    margin: 20px auto;
  }
  
  div.photo1 { 
    background-image: url('https://i.ibb.co/XZMH8NHC/toji1.jpg');
    background-size: contain; /* استخدم cover لتعبئة العنصر بالكامل إذا رغبت */
    background-position: center;
    background-repeat: no-repeat;
    width: 300px;
    height: 300px;
    background-color: black;
    border-radius: 10px;
    margin: 20px auto;
  }
  
  /* --- Link Styles --- */
  a.link1 {
    color: blue;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease-in-out;
  }
  
  a.link1:hover {
    color: red;
    text-decoration: underline;
  }
  
  /* --- Additional Improvements --- */
  /* يمكنك إضافة تأثيرات عند تمرير الماوس على العناصر أو تعديل المسافات حسب الحاجة */
  