/* إعداد عام للصفحة */
body {
  margin: 0;
  padding-bottom: 100px; /* مساحة للأزرار السفلية */
  font-family: 'Segoe UI', Arial, sans-serif;
  background: #fff9ec;
  color: #333;
}

/* الحاوية الأساسية */
.container {
  max-width: 100%;
  margin: auto;
  background: #fff;
  border-radius: 0px;
  overflow: hidden;
  box-shadow: 0 0 10px #551665;
  padding: 1p;
  position: relative;
}

.inner-border {
  border: 3px solid #551665;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 0 10px #551665;
  overflow: hidden;
}

/* الشريط العلوي */
.header {
  background: #551665;
  color: white;
  padding: 8px 1%; /* تم تقليل الحشو لتصغير الفواصل */
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  margin-bottom: 10px;
  position: relative;
  overflow: hidden;
  min-height: 60px;
  font-size: 12px; /* تصغير حجم النص داخل الهيدر */
}

/* أنيميشن الشعار والنص */
.logo-img,
.logo-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  animation-duration: 25s;
  animation-iteration-count: infinite;
  animation-timing-function: ease-in-out;
  text-align: center;
  max-width: 90%;
}

.logo-img {
  animation-name: show-logo;
}

.logo-text {
  animation-name: show-text;
}

@keyframes show-logo {
  0%, 20% {
    opacity: 1;
  }
  21%, 100% {
    opacity: 0;
  }
}

@keyframes show-text {
  0%, 20% {
    opacity: 0;
  }
  21%, 100% {
    opacity: 1;
  }
}

/* الشعار المصغر */
.location-img {
  height: 40px;
  width: auto;
}

.header .location {
  font-weight: bold;
  font-size: 14px;
}

.header .icons {
  display: flex;
  gap: 10px;
}

/* شريط البحث */
.search-bar {
  margin: 15px;
  display: flex;
  background: #e6e3da;
  border-radius: 12px;
  overflow: hidden;
  align-items: center;
  padding: 0px 0px;
}

.search-bar input {
  flex: 1;
  border: none;
  background: transparent;
  outline: none;
  font-size: 14px;
}

.search-bar button {
  background: #344ec0;
  border: none;
  color: white;
  padding: 8px;
  border-radius: 50%;
  cursor: pointer;
}

/* القائمة الأفقية */
.category-scroll {
  overflow-x: auto;
  white-space: nowrap;
  margin: 10px 8px;
  padding-left: 5px;
}

.categories {
  display: inline-flex;
  gap: 10px;
  padding-bottom: 10px;
}

.category {
  flex: 0 0 auto;
  background: #e6e3da;
  color: #333;
  border: none;
  padding: 10px;
  border-radius: 15px;
  text-align: center;
  font-size: 12px;
  width: 88px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.category.selected {
  background: linear-gradient(135deg,#8E44AD,#551665);
  color: white;
  border: none;
}
.category:hover {
  transform: scale(1.05);
}

/* أزرار أسفل الشاشة */
.bottom-nav {
  display: flex;
  justify-content: space-around;
  align-items: center;
  background: #551665; /* نفس اللون الذي تستخدمه */
  padding: 8px 0;
  border-radius: 20px;
  position: fixed;
  bottom: 10px;
  width: 90%;
  max-width: 500px;
  left: 50%;
  transform: translateX(-50%);
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

/* الأيقونات */
.bottom-nav a {
  color: white;
  font-size: 28px;
  text-decoration: none;
  transition: transform 0.3s, color 0.3s;
}

/* عند التمرير */
.bottom-nav a:hover {
  color: #ffffff; /* وردي ناعم عند المرور */
  transform: scale(1.2);
}

/* العنصر النشط */
.bottom-nav a.active {
  color: #ffffff;
}


/* إطار الصفحة */
.page-frame {
  border: 5px solid #551665;
  border-radius: 20px;
  margin: 10px;
  padding: 0;
  box-sizing: border-box;
  min-height: calc(100vh - 20px);
}

.location {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
}

/* أيقونات التواصل */
.social-icons {
  display: flex;
  justify-content: center;
  gap: 15px;
  align-items: center;
}

/* تحسينات للموبايل */
@media (max-width: 600px) {
  .food-info {
    padding: 15px;
  }

  .food-info h4 {
    font-size: 14px;
  }

  .food-info p {
    font-size: 12px;
  }



  .search-bar {
    margin: 10px;
    padding: 6px 10px;
  }
}
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 8px;
  padding: 10px;
  justify-items: center;
  background: #fff9ec;
  border-radius: 12px;
}

@media (max-width: 480px) {
  .categories-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
  }

  .category {
    font-size: 14px;
    width: 100%;
    padding: 8px;
  }

  .logo-text {
    font-size: 12px;
  }
}

/* بطاقات الطعام */
.food-card {
  margin: 15px;
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.food-card img {
  width: 100%;
  height: auto;
  display: block;
}

.food-info {
  padding: 25px;
}

.food-info h4 {
  margin: 0;
  font-size: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  direction: rtl;
  flex-direction: row-reverse;
}

.food-info p {
  font-size: 12px;
  color: #777;
  margin-top: 5px;
  direction: rtl;
  text-align: right;
}
