.os-desktop {
  display: block;
  height: 100vh;
  background: url('../../../public/images/sequoia-light.jpg') center/cover;
}

.os-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 24px;
  padding: 0 16px;
  background-color: rgba(255, 255, 255, 0.48);
  backdrop-filter: blur(100px);
  font-size: 13px;
}

.os-menu-group {
  display: flex;
  gap: 12px;
  height: 100%;
}

.os-menu-item {
  position: relative;
  display: inline-flex;
  align-items: center;
  color: rgba(0, 0, 0, 0.8);
  text-decoration: none;
  background: none;
  border: none;
  outline: none;

  svg {
    width: 18px;
    height: 18px;
  }

  &:focus,
  &:active {
    &::after {
      content: '';
      position: absolute;
      left: -8px;
      right: -8px;
      height: 100%;
      background-color: rgba(0, 0, 0, 0.12);
      border-radius: 4px;
    }
  }

  &.main-item {
    font-weight: 700;
  }
}

main {
  position: relative;
  height: calc(100vh - 24px);
}

.os-dock {
  position: absolute;
  left: 50%;
  bottom: 5px;
  z-index: 2000;
  transform: translate(-50%, 0);
  display: flex;
  gap: 10px;
  height: 53px;
  padding: 6px 8px 9px;
  background-color: rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(16px);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  box-shadow: 0 0 10px 4px rgba(0, 0, 0, 0.12);
}

.os-app {
  position: relative;
  width: 36px;
  height: 36px;
  background-color: white;
  border-radius: 8px;
  border: none;
  outline: none;

  .focus-indicator {
    position: absolute;
    inset: 0;
    background-color: transparent;
    border-radius: 8px;
  }

  &:hover {
    .os-dock-tooltip {
      opacity: 1;
    }
  }

  &:focus,
  &:active {
    .focus-indicator {
      background-color: rgba(0, 0, 0, 0.24);
    }
  }

  &.active {
    .active-indicator {
      position: absolute;
      bottom: -8px;
      left: 50%;
      transform: translate(-50%, 0);
      width: 4px;
      height: 4px;
      background-color: black;
      border-radius: 50%;
    }
  }

  .touch-target {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 60px;
  }
}

.os-dock-tooltip {
  --tooltip-bg-color: rgba(255, 255, 255, 0.56);
  --tooltip-backdrop-filter: blur(50px);

  position: absolute;
  padding: 6px 12px;
  top: -48px;
  left: 50%;
  transform: translate(-50%, 0);
  background-color: var(--tooltip-bg-color);
  backdrop-filter: var(--tooltip-backdrop-filter);
  filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.24));
  border-radius: 4px;
  white-space: nowrap;
  line-height: 1;
  pointer-events: none;
  opacity: 0;
  font-weight: 300;

  &::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -14px;
    transform: translate(-50%, 0);
    width: 1px;
    border: 6px solid transparent;
    border-top-color: var(--tooltip-bg-color);
    backdrop-filter: var(--tooltip-backdrop-filter);
    border-top-width: 8px;
  }
}

.os-btn {
  position: relative;
  min-width: 72px;
  padding: 2px 8px;
  border: none;
  background-color: white;
  border-radius: 6px;
  box-shadow:
    inset 0 0 1px rgba(255, 255, 255, 0.32),
    0 0 1px rgba(0, 0, 0, 0.32),
    0 1px 1px 0 rgba(0, 0, 0, 0.24);
  text-decoration: none;
  text-align: center;

  &::after {
    content: '';
    position: absolute;
    inset: 0;
    background-color: transparent;
    pointer-events: none;
    border-radius: 6px;
  }

  &:active {
    &::after {
      background-color: rgba(0, 0, 0, 0.08);
    }
  }

  &.btn-primary {
    color: white;
    background-image: linear-gradient(#2491ff, #037aff);
    box-shadow: 0 1px 1px #0052ae;
  }
}
