navbar.css

mail@pastecode.io avatar
unknown
plain_text
5 months ago
3.6 kB
1
Indexable
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.search-text input[type=text]::placeholder {
  color: #CAE9EB;
}


body {
  font-family: Arial, sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: #1A2D31;
  color: #83aeac;
}

.navbar {
  position: fixed;
  top: 0;
  left: 230px;
  width: calc(100% - 230px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #1a2d31;
  padding: 10px 20px;
  z-index: 1000;
  transition: margin-left 0.3s ease;
}


.nav-left ul {
  list-style-type: none;
  margin: 0;
  display: flex;
  gap: 20px;
}

.nav-left ul li {
  font-size: 20px;
  padding-right: 30px;
  position: relative;
  transition: color 0.3s;
}

.nav-left ul li a {
  text-decoration: none;
  color: inherit;
  padding: 10px 0;
  position: relative;
}

.nav-left ul li a:hover,
.nav-left ul li a.active {
  color: #d2f0f0;
}

.nav-left ul li a::before {
  content: "";
  position: absolute;
  bottom: 35px;
  left: 50%;
  transform: translateX(-50%);
  height: 4px;
  background-color: transparent;
  width: 0;
  border-radius: 2px;
  transition: width 0.3s ease, background-color 0.3s ease;
}

.nav-left ul li a:hover::before,
.nav-left ul li a.active::before {
  width: 30px;
  background-color: #cdecef;
}


.search-text {
  display: flex;
  align-items: center;
  width: 250px;
  position: relative;
  margin-left: 20px;
}

.search-text input[type='text'] {
  padding: 8px 15px;
  border: 1px solid #83aeac;
  border-radius: 20px;
  font-size: 16px;
  width: 100%;
  background-color: #243F46;
  color: inherit;
  outline: none;
  height: 35px;
}

input[type='text']::placeholder {
  color: #83aeac;
}

.search-text .search-icon {
  color: #CAE9EB;
  cursor: pointer;
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
}

.search-text .search-icon:hover {
  color: #cdecef;
}


.list-item {
  list-style-type: none;
  display: flex;
  gap: 20px;
}

.list-item .item a {
  text-decoration: none;
  font-size: 1.2em;
  transition: color 0.3s;
  color: #83aeac;
}

.list-item .item a:hover {
  color: #cdecef;
}

*/ .avatar {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar .user-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar .user-info span {
  color: #ffd36a;
  font-weight: bold;
}

.avatar img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid #ffd36a;
}


.login-button {
  padding: 8px 15px;
  background-color: #ffd36a;
  color: #1a2d31;
  border: none;
  border-radius: 20px;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.3s, color 0.3s;
}

.login-button:hover {
  background-color: #ffc857;
  color: #1a2d31;
}

.login-button:focus {
  outline: none;
}

.login-button:active {
  transform: translateY(1px);
}


.icon-wrapper .badge {
  position: absolute;
  top: -10px; /* Điều chỉnh để căn chỉnh chính xác với biểu tượng trái tim */
  right: -20px; /* Điều chỉnh để căn chỉnh chính xác với biểu tượng trái tim */
  background-color: #ffc857;
  color: #1a2d31;
  border-radius: 50%;
  padding: 2px 6px;
  font-size: 12px;
  font-weight: bold;
  border: 2px solid #ffc857; /* Thay đổi border nếu cần */
}

.list-item .item {
  position: relative; /* Tạo ngữ cảnh cho badge */
}

.icon-wrapper {
  position: relative; /* Tạo ngữ cảnh cho badge */
}
Leave a Comment