/* Reset أساسي */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }
  
  /* خطوط ولون عام */
  body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f7f9fc;
    color: #333;
    line-height: 1.6;
    padding: 0;
  }
  
  /* رأس الموقع */
  header {
    background-color: #fff;
    padding: 20px 40px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
  }
  
  header h1 {
    font-size: 28px;
    color: #0056b3;
  }
  
  nav a {
    margin-left: 20px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s;
  }
  
  nav a:hover {
    color: #007bff;
  }
  
  /* المحتوى الرئيسي */
  h2 {
    text-align: center;
    margin: 40px 0 20px;
    color: #333;
  }
  
  section {
    max-width: 1200px;
    margin: auto;
    padding: 20px;
  }
  
  /* البطاقات */
  .product-list, .post-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
  }
  
  .product, .post {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.3s;
  }
  
  .product:hover, .post:hover {
    transform: translateY(-5px);
  }
  
  .product img, .post img {
    width: 100%;
    height: 300px;               /* ارتفاع موحد */
    object-fit: fill;           /* يملأ الإطار مع اقتصاص الزائد */
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    margin-bottom: 10px;
  }
  
  .product h4, .post h4 {
    font-size: 18px;
    color: #0056b3;
    margin-bottom: 10px;
  }
  
  .product p, .post p {
    color: #555;
  }
  
  /* نموذج الاشتراك */
  .subscribe {
    background-color: #eaf0f6;
    text-align: center;
    padding: 30px;
    border-radius: 10px;
    margin-top: 40px;
  }
  
  .subscribe input {
    padding: 10px;
    width: 300px;
    border: 1px solid #ccc;
    border-radius: 6px;
    margin-right: 10px;
  }
  
  .subscribe button {
    padding: 10px 20px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s;
  }
  
  .subscribe button:hover {
    background-color: #0056b3;
  }
  
  /* الفوتر */
  footer {
    background-color: #111;
    color: #fff;
    padding: 20px;
    text-align: center;
    margin-top: 40px;
  }
  
  /* الأزرار */
  button {
    background-color: #007bff;
    color: white;
    padding: 10px 20px;
    font-weight: bold;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s;
  }
  
  button:hover {
    background-color: #0056b3;
  }
  
  /* جدول الإدارة */
  table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
  }
  
  th, td {
    border: 1px solid #ccc;
    padding: 12px;
    text-align: center;
  }
  
  th {
    background-color: #f1f1f1;
    color: #333;
  }
  
  /* استجابة الهاتف */
  @media (max-width: 768px) {
    header {
      flex-direction: column;
      text-align: center;
    }
  
    nav a {
      margin: 10px 5px;
    }
  
    .subscribe input {
      width: 100%;
      margin: 10px 0;
    }
  
    .product-list, .post-list {
      grid-template-columns: 1fr;
    }
  }
