*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial,
    sans-serif;
  scrollbar-width: none;
  overscroll-behavior-x: none;
  scrollbar-gutter: stable;
  overflow-y: scroll;
}


.layout {
  display: flex;
  min-height: 100dvh;
  width: 100%;
}

.cantainer,
.container {
  flex: 1 1 auto;
  min-width: 0;
  background: #f6f7f8;
}

.main {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  width: 100%;
  min-width: 0;
}

.detail-content {
  flex: 1 1 auto;
  width: 100%;
  max-width: 1920px;
  margin: 0 auto;
  padding: 32px 24px;
  min-width: 0;
}

.sidebar {
  width: 232px;
  flex: 0 0 232px;
  background-color: #2a3647;
  color: #fff;
  display: flex;
  flex-direction: column;
  padding: 64px 0;
}

.logo {
  width: 100%;
  height: 121.97px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.logo img {
  width: 100.03px;
  height: 121.97px;
  object-fit: contain;
  display: block;
}

.menu {
  margin-top: 80px;
  flex: 1 1 auto;
  display: flex;
  min-width: 0;
}

.menu ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
}

.menu a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0 12px 56px;
  width: 100%;
  color: #a8a8a8;
  text-decoration: none;
  position: relative;
}

.menu-button {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.menu img {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  filter: brightness(0.6);
  transition: filter 0.3s ease;
}

.menu a:hover {
  background-color: #384b6692;
  color: #fff;
}

.menu a:hover img {
  filter: brightness(0) invert(1);
}

.menu a.active {
  background-color: #091931;
  color: #fff;
}

.menu a.active img {
  filter: brightness(0) invert(1);
}

.menu a.active::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 4px;
  background-color: #091931;
}

.sidebar-footer {
  margin-top: auto;
  margin-left: 52px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sidebar-footer a {
  font-size: 16px;
  line-height: 120%;
  color: #a8a8a8;
  text-decoration: none;
}

.sidebar-footer a:hover {
  transform: translate(0.95px);
  color: #29abe2;
}

.header {
  height: 96px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  box-shadow: 0 4px 4px rgba(0, 0, 0, 0.08);
  padding: 20px 40px 20px 116px;
  z-index: 100;
}

.content-wrepper-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 1920px;
  z-index: 2001;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.header-logo {
  display: none;
  height: 42px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  flex-shrink: 0;
}

.header-title {
  font-size: 20px;
  font-weight: 400;
  line-height: 120%;
  color: #000;
  white-space: nowrap;
  max-width: 900px;
  min-width: 0;
  margin: 0;
  position: relative;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 0 0 auto;
  position: relative;
  z-index: 9999;
}

.header-help {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid #d1d1d1;
  color: #a8a8a8;
  text-decoration: none;
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  user-select: none;
}

.header-help:hover {
  color: #a8a8a8;
  border-color: #a8a8a8;
  background: transparent;
}

.header-user,
.header-guest {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 2px solid #2a3647;
  display: grid;
  place-items: center;
  font: inherit;
  font-size: 20px;
  font-weight: 700;
  color: #29abe2;
  background: #ffffff;
  cursor: pointer;
  padding: 0;
  appearance: none;
  -webkit-appearance: none;
  user-select: none;
}

.header-user:hover,
.header-guest:hover {
  background-color: #e4e2e2;
}

.header-guest:focus {
  outline: none;
}
.header-guest:focus-visible {
  outline: 2px solid rgba(41, 171, 226, 0.6);
  outline-offset: 3px;
}

.header-user-area {
  position: relative;
}

.user-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 170px;
  background: #2a3647;
  border-radius: 16px;
  padding: 8px 0;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  gap: 0;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s ease;
  z-index: 20;
}

.user-menu.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  visibility: visible;
}

.user-menu-item {
  padding: 10px 20px;
  color: #ffffff;
  text-decoration: none;
  font-size: 16px;
  line-height: 1.2;
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
}

.user-menu-item:hover {
  background: rgba(255, 255, 255, 0.12);
}
@media (max-width: 1023px) {
  .layout {
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
  }

  .cantainer,
  .container,
  .main {
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .header-title,
  .header-help {
    display: none !important;
  }

  .header-logo {
    display: block !important;
    width: 56px;
    height: 64px;
  }

  .sidebar {
    width: 100vw;
    max-width: 100vw;
    height: 80px;
    padding: 2px 16px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    position: fixed;
    left: 0;
    right: 0;
    transform: none;
    bottom: 0;
    z-index: 999;
    min-height: unset;
    background: #2a3647;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.1);
    border-radius: 0;
  }

  .sidebar-footer,
  .sidebar .logo {
    display: none;
  }

  .menu {
    margin-top: 0;
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .menu ul {
    display: flex;
    flex-direction: row;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    padding: 0 10px;
    margin: 0;
  }

  .menu ul {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: 100%;
    padding: 2px 8px;
    margin: 0;
    gap: 0;
  }

  .menu ul > li {
    flex: 1 1 0;
    display: flex;
    justify-content: center;
    min-width: 0;
  }

  .menu a {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    padding: 0;
    width: 100%;
    height: auto;
    color: #a8a8a8;
  }

  .menu-button {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 15px 0;
    gap: 4px;
    width: 76px;
    height: 76px;
    line-height: 120%;
    border-radius: 8px;
  }

  .menu a.active {
    background-color: transparent;
  }

  .menu a.active .menu-button {
    background: #091931;
    border-radius: 16px;
  }

  .menu a:hover::before,
  .menu a.active::before {
    display: none !important;
  }

  .menu img {
    width: 24px;
    height: 24px;
  }

  #login-btn {
    display: none;
  }

  .detail-content {
    padding: 20px 16px 110px 16px;
  }

  .header-dropdown {
    right: 8px;
    top: calc(100% + 10px);
    border-radius: 18px;
  }

  .header-dropdown::after {
    right: 22px;
  }

  .header-dropdown .userMenuItem:first-child {
    display: flex;
  }

  .header-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    background: #2a3647;
    border-radius: 20px;
    padding: 8px;
    min-width: 190px;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
    z-index: 100000;
    transform-origin: top right;
  }

  .header-dropdown::after {
    display: none;
  }

  .userMenuItem {
    display: block;
    width: 100%;
    text-align: left;
    background: transparent;
    border: 0;
    color: #fff;
    text-decoration: none;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 16px;
    cursor: pointer;
  }
}

@media (max-width: 768px) {
  .header-logo {
    width: 56px;
    height: 64px;
  }
}
@media (max-width: 425px) {
  .header {
    height: 80px;
  }

  .header-logo {
    width: 32px;
    height: 39.2px;
  }

  .header-guest,
  .header-user {
    width: 40px;
    height: 40px;
    font-size: 16px;
  }
}

@media (max-width: 340px) {
  .sidebar {
    padding: 2px 8px;
  }

  .menu ul {
    padding: 0;
    gap: 0;
  }
}
@media (max-width: 360px) {
  .sidebar {
    padding: 2px 8px;
  }

  .menu a {
    flex: 1 1 0;
    min-width: 0;
    font-size: 16px;
  }
  .menu ul {
    padding: 0;
  }
  .menu ul > li {
    flex: 1 1 0;
    display: flex;
    justify-content: center;
    min-width: 0;
  }
  .menu a {
    padding: 0;
    gap: 4px;
  }
}

@media (max-width: 320px) {
  .sidebar {
    padding: 2px 4px;
  }

  .menu ul {
    padding: 0;
  }
}
