    
    html, body {
  touch-action: manipulation;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}

        body {
            margin: 0;
            font-family: sans-serif;
            background-color: #e5ddd5;
        }
        .header {
            position: fixed;
            top: 0; left: 0; width: 100vw; z-index: 100;
            background-color: #f0f0f0;
            padding: 10px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            height: 5vh;
            z-index:1000000;
        }
        .chat-c {
            height: calc(100vh - 15vh);
            overflow-y: scroll;
            padding: 50px 10px 10px 10px;
            background-image: url('images/bg.jpg');
            background-size: cover;
        }
        .location {
            margin: 10px 0;
            height: 400px;
            position: relative;
            overflow: hidden;
        }
        .map-cover {
            position: absolute;
            top: 0; left: 0;
            width: 100%; height: 100%;
            background: rgba(255,255,255,0.0);
            z-index: 500;
            cursor: pointer;
        }
        .fullscreen-map {
            position: fixed;
            top: 0; left: 0;
            width: 100vw; height: 100vh;
            background: white;
            z-index: 9999;
        }
        .close-map {
            position: absolute;
            top: 100px; right: 20px;
            z-index: 10000;
            font-size: 2em;
            color: white !important;
            background: rgba(0, 0, 0, 0.5);
            padding: 5px;
            width: 50px;
            height: 50px;
            border-radius: 100px;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .message {
            background-color: #dcf8c6;
            padding: 10px;
            margin: 70px 5%;
            max-width: 90%;
            border-radius: 5px;
            font-size: 20px;
        }
        .images {
            display: flex;
            gap: 5px;
            flex-wrap: wrap;
            margin-top: 10px;
        }
        .images img {
            width: 100%;
            border-radius: 5px;
        }

        .input-bar {
            display: flex;
            flex-direction: column;
            align-items: stretch;
            padding: 10px;
            background-color: #f0f0f0;
            border-top: 1px solid #ccc;
            position: fixed;
            bottom: 0;
            left: 0;
            width: 100vw;
            z-index: 1000;
            transition: height 0.3s ease;
            height: 6vh;
        }

        .input-bar .top-row {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-right:20px;
        }
        
                .input-bar .top-row img {
width:40px;
        }

        .input-bar .plus {
            font-size: 35px;
            color: #075e54;
            padding: 0 10px;
            cursor: pointer;
            flex-shrink: 0;
        }

        .input-bar input {
            flex: 1;
            font-size: 18px;
            padding: 10px 15px;
            border: none;
            border-radius: 50px;
            outline: none;
            width:80%;
        }

        .input-bar .media-icons {
            display: none;
            justify-content: space-around;
            margin-top: 10px;
        }

        .input-bar .media-icons img {
            width: 15%;
            
            cursor: pointer;
        }

        .leaflet-control-attribution {
            display: none !important;
        }
        
       
/* زر القائمة */
#minue {
  font-size: 26px;
  cursor: pointer;
  padding: 10px;
}

/* الشريط الجانبي */
#sidebar {
  position: fixed;
  top: 0;
  left: -100%;
  width: 100vw;
  height: 100%;
  background: #f4f4f4;

  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
  transition: left 0.4s ease;
  z-index: 1000;
  overflow-y: auto;
}

#sidebar.open {
  left: 0;
}

.sidebar-content {
  padding: 20px;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.sidebar-content h2,
.sidebar-content h3 {
  margin-top: 0;
  color: #333;
}

/* الحقول */
form input, form select {
  width: 95%;
  margin: 8px 0;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 15px;
}

form button {
  width: 100%;
  padding: 10px;
  background-color: #0d6efd;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  margin-top: 10px;
  cursor: pointer;
  transition: background 0.3s ease;
}

form button:hover {
  background-color: #084298;
}

.toggle-register {
  font-size: 14px;
  color: #555;
  margin-top: 10px;
}

.toggle-register a {
  color: #0d6efd;
  text-decoration: none;
}



#login-form {
  display: grid; gap: 12px;
  font-family: 'Segoe UI', Tahoma, sans-serif;
}
#login-form input {
  padding: 12px; border:1px solid #d8dbe1; border-radius:10px; font-size:15px;
  transition: border-color .25s, box-shadow .25s;
  background: rgba(255,255,255,.85); backdrop-filter: blur(6px);
}
#login-form input:focus {
  outline: none; border-color:#0d6efd; box-shadow:0 0 0 3px rgba(13,110,253,.15);
}
#login-btn {
  position: relative;
  display: inline-flex; align-items:center; justify-content:center;
  gap:10px; padding:12px; width:100%;
  border:none; border-radius:12px; cursor:pointer; font-size:16px; font-weight:600;
  background: linear-gradient(135deg,#0d6efd,#6f42c1); color:#fff;
  transition: transform .05s ease, filter .25s ease;
}
#login-btn:hover { filter: brightness(1.05); }
#login-btn:active { transform: translateY(1px); }

/* سبنّر داخل الزر – مخفي افتراضيًا */
#login-btn .spinner {
  width:18px; height:18px; border:2px solid transparent; border-top-color:#fff; border-right-color:#fff;
  border-radius:50%; display:none; animation:spin .7s linear infinite;
}
#login-btn.loading .btn-text { opacity:.55; }
#login-btn.loading .spinner { display:inline-block; }

@keyframes spin { to { transform: rotate(360deg); } }

.msg.error {
  background: #fff0f0; color:#b00020; border:1px solid #ffc9c9; border-radius:10px;
  padding:10px 12px; font-size:14px;
}
.welcome-card {
  padding:16px; border:1px solid #e9ecf2; border-radius:14px; background:#ffffffcc; backdrop-filter: blur(6px);
  box-shadow: 0 6px 18px rgba(0,0,0,.06);
}
.welcome-name { font-size:17px; margin-bottom:10px; color:#333; }
.logout-link {
  display:inline-block; padding:10px 14px; border-radius:10px; text-decoration:none; color:#fff;
  background: linear-gradient(135deg,#dc3545,#c1121f);
}
.logout-link:hover { filter: brightness(1.05); }





.login-message {
  font-family: 'Segoe UI', Tahoma, sans-serif;
  font-size: 16px;
  background: #fff4f4;
  border: 1px solid #ffcccc;
  padding: 10px 14px;
  border-radius: 10px;
  display: inline-block; /* التأكد من أن العرض يمكن أن يوسع */
  color: #b02a37;
  box-sizing: border-box; /* التأكد من أن padding ضمن الحجم الكلي */
margin:-5px 15px 0 0;
    
}
.login-message a {
  color: #0d6efd;
  text-decoration: none;
  font-weight: bold;
}
.login-message a:hover {
  text-decoration: underline;
}









#load-more-btn {
    width:80%;
    margin:0 0 100px 0;
    padding: 10px 20px;
    font-size: 16px;
    border: none;
    background: linear-gradient(135deg,#0d6efd,#6f42c1);
    color: white;
    border-radius: 8px;
    cursor: pointer;
    position: relative;
}




@keyframes spin { to { transform: rotate(360deg); } }

.btn-loading { position: relative; }

.btn-loading .btn-spinner {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 22px;
  height: 22px;
  border: 3px solid rgba(255,255,255,.35);
  border-top-color: #fff;
  border-right-color: #fff;
  border-radius: 50%;
  animation: spin .8s linear infinite;
  display: none;
}

.btn-loading.loading .btn-text,
.btn-loading.loading img {
  visibility: hidden;
}

.btn-loading.loading .btn-spinner {
  display: block !important;
}

/* سبنر الإرسال الأخضر */
.send-btn .btn-spinner {
  border: 3px solid rgba(0,128,0,.35); /* أخضر شفاف */
  border-top-color: green;
  border-right-color: green;
}


    