@use "../../theme";
@use "../../theme-color";
@use "../../shadow";
@use "../../gnome-shell/sass/drawing";
@use "../../gnome-shell/sass/typography";
@use "extends";

// defines font family and standard font size across the whole theme
// em is preferred for better support for text scaling
stage {
  @include typography.body2;

  font-family: typography.$font-family;
  color: theme-color.$on-surface;
}
.cinnamon-link {
  color: theme-color.$primary;
  font-style: italic;
  &:hover {
    color: theme-color.$primary;
  }
}
.label-shadow {
  color: transparent;
}
// themeing for various standard elements
StScrollBar {
  padding: 0px;
  StButton {
    &#vhandle, &#hhandle {
      background-color: theme-color.disabled(theme-color.$on-surface);
      border-radius: 100px;
      margin: 4px;
      &:hover {
        background-color: theme-color.hint(theme-color.$on-surface);
      }
    }
  }
  StBin#trough {
    margin: 4px;
    border-radius: 100px;
    background-color: theme-color.divider(theme-color.$on-surface);
  }
}
StScrollView {
  &.vfade {
    -st-vfade-offset: 32px;
  }
  &.hfade {
    -st-hfade-offset: 32px;
  }
  StScrollBar {
    min-width: 16px;
    min-height: 16px;
  }
}
.separator {
  @extend %separator-shared;
}
.slider {
  @extend %slider-shared;
}
#Tooltip {
  @include typography.caption;

  padding: 6px 8px;
  color: theme-color.$on-tooltip;
  text-align: center;
  border-radius: theme.$corner-radius;
  background-color: theme-color.$tooltip;
}
// applet menus. Note that cinnamon versions before 3.2 uses deprecated styles
// .popup-menu and .popup-menu-boxpointer. These are excluded as it is not possible
// due to other upstream changes to create a universal cinnamon theme that supports pre and post cinnamon 3.2
.menu {
  @extend %menu-shared;
  min-width: 100px;
  margin: 4px;
}
// new style-classes for alternative stock menu
.menu-top-box {
  spacing: 5px;
}
.menu-systembuttons-box {
  padding: 10px;
}
.popup-sub-menu {
  background-color: theme-color.entry-fill(theme-color.$on-surface);
}
.popup-menu-arrow {
  icon-size: 1.14em;
}
// scale view right click menu
.popup-combo-menu {
  @extend %menu-shared;
  padding: 8px 0;
}
.popup-menu-content{
  padding: 8px 0;
}

// individual menu entries are themed here
.popup-menu-item {
  padding: 0.4em 16px;
  spacing: 8px;
  transition-duration: theme.$state-duration;
  &:active {
    background-color: theme-color.hover-overlay(theme-color.$on-surface);
    color: theme-color.$on-surface;
    transition-duration: 0ms;
  }
  &:insensitive {
    color: theme-color.disabled(theme-color.$on-surface);
  }
}
.popup-image-menu-item {
  color: theme-color.hint(theme-color.$on-surface);
}
.popup-combobox-item {
  padding: 0.4em 16px;
}
// sliders and separators in menus
.popup-separator-menu-item {
  @extend %separator-shared;
}
.popup-slider-menu-item {
  @extend %slider-shared;
}
.popup-device-menu-item {
  spacing: .5em;
}
.popup-inactive-menu-item {
  color: theme-color.$on-surface;
  &:insensitive {
    color: theme-color.disabled(theme-color.$on-surface);
  }
}
.popup-subtitle-menu-item {
  @include typography.subtitle2;
}
.popup-menu-icon {
  icon-size: 1.14em;
}
.popup-menu-item-dot {
}
.popup-submenu-menu-item:open {
}
.popup-alternating-menu-item:alternate {
  @include typography.subtitle2;
}
// toggles in menus
.toggle-switch {
   width: 40px;
   height: 20px;
}
.toggle-switch-us, .toggle-switch-intl {
  background-image: url(assets/toggle-off.svg);
  &:checked {
    background-image: url(assets/toggle-on.svg);
  }
}
.nm-menu-item-icons {
  spacing: .5em;
  icon-size: 1.14em;
}
// panels can be on any side of the screen
// some panel item theming is specific to panel orientation and is included in this section
// each panel is also split into three zones
// dnd is for panel edit mode
// dummy is for adding or moving panels
#panel {
  color: theme-color.hint(theme-color.$on-titlebar);
  background-color: theme-color.$scrim;
  height: 2.5em;
  width: 3.2em;
  &:highlight {
    background-color: theme-color.stroke(theme-color.$on-titlebar);
  }
}
.panel-dummy {
  background-color: rgba(255, 0, 0, 0.6);
  &:entered {
    background-color: rgba(0, 255, 0, 0.6);
  }
}
.panelLeft {
  spacing: 4px;
  &:dnd {
    background-color: rgba(255, 0, 0, 0.6);
  }
  &:ltr {
    padding-right: 4px;
  }
  &:rtl {
    padding-left: 4px;
  }
  &.vertical {
    padding: 0;
    &:dnd {
    }
  }
}
.panelCenter {
  spacing: 4px;
  &:dnd {
    background-color: rgba(0, 255, 0, 0.6);
  }
  &.vertical {
    padding-left: 0;
    padding-right: 0;
    &:dnd {
    }
  }
}
.panelRight {
  spacing: 4px;
  &:dnd {
    background-color: rgba(0, 0, 255, 0.6);
  }
  &:ltr {
    padding-left: 0;
    spacing: 0;
  }
  &:rtl {
    padding-right: 0;
    spacing: 0;
  }
  &.vertical {
    padding: 0;
    &:dnd {
    }
  }
}
// orientation specific panel-item theming is defined here
// non orientation specific theming for panel-items is defined later in the stylesheet
.panel-top {
  .window-list-item-box {
    &:hover {
      box-shadow: 0 3px 0 0 theme-color.$primary inset;
    }
    &:active, &:checked, &:focus {
      &:hover {
        box-shadow: 0 3px 0 0 theme-color.$primary inset;
      }
    }
  }
  .grouped-window-list-item-box {
    &:hover {
      box-shadow: 0 3px 0 0 theme-color.$primary inset;
    }
    &:active, &:checked {
      &:hover {
        box-shadow: 0 3px 0 0 theme-color.$primary inset;
      }
    }
    &:focus {
      &:hover {
        box-shadow: 0 3px 0 0 theme-color.$primary inset;
      }
    }
  }
  .grouped-window-list-badge {
    margin-top: 2px;
  }
  .workspace-switcher, .workspace-graph, .workspace-button {
    padding: 1px 4px;
  }
  .workspace-graph, .workspace-button {
    &:hover {
      box-shadow: 0 3px 0 0 theme-color.$primary inset;
    }
  }
  .applet-box {
    padding: 0 4px;
    &:hover {
      box-shadow: 0 3px 0 0 theme-color.$primary inset;
    }
  }
  .applet-label {
  }
  .panel-launchers .launcher:hover {
    box-shadow: 0 3px 0 0 theme-color.$primary inset;
  }
  .applet-separator {
    padding: 3px 4px;
  }
  .systray:hover {
    box-shadow: 0 4px 0 0 theme-color.$primary inset;
  }
}
.panel-bottom {
  .window-list-item-box {
    &:hover {
      box-shadow: 0 -3px 0 0 theme-color.$primary inset;
    }
    &:active, &:checked, &:focus {
      &:hover {
        box-shadow: 0 -3px 0 0 theme-color.$primary inset;
      }
    }
  }
  .grouped-window-list-item-box {
    &:hover {
      box-shadow: 0 -3px 0 0 theme-color.$primary inset;
    }
    &:active, &:checked {
      &:hover {
        box-shadow: 0 -3px 0 0 theme-color.$primary inset;
      }
    }
    &:focus {
      &:hover {
        box-shadow: 0 -3px 0 0 theme-color.$primary inset;
      }
    }
  }
  .workspace-switcher, .workspace-graph, .workspace-button {
    padding: 1px 4px;
  }
  .workspace-graph, .workspace-button {
    &:hover {
      box-shadow: 0 -3px 0 0 theme-color.$primary inset;
    }
  }
  .applet-box {
    padding: 0 4px;
    &:hover {
      box-shadow: 0 -3px 0 0 theme-color.$primary inset;
    }
  }
  .applet-label {
  }
  .panel-launchers .launcher:hover {
    box-shadow: 0 -3px 0 0 theme-color.$primary inset;
  }
  .applet-separator {
    padding: 3px 4px;
  }
  .systray:hover {
    box-shadow: 0 4px 0 0 theme-color.$primary inset;
  }
}
.panel-left {
  .window-list-item-box {
    &:hover {
      box-shadow: 3px 0 0 0 theme-color.$primary inset;
    }
    &:active, &:checked, &:focus {
      &:hover {
        box-shadow: 3px 0 0 0 theme-color.$primary inset;
      }
    }
  }
  .grouped-window-list-item-box {
    &:hover {
      box-shadow: 3px 0 0 0 theme-color.$primary inset;
    }
    &:active, &:checked {
      &:hover {
        box-shadow: 3px 0 0 0 theme-color.$primary inset;
      }
    }
    &:focus {
      &:hover {
        box-shadow: 3px 0 0 0 theme-color.$primary inset;
      }
    }
  }
  .grouped-window-list-badge {
    margin-left: 2px;
  }
  .workspace-switcher, .workspace-graph, .workspace-button {
    padding: 4px 1px;
    min-height: 1.2em;
  }
  .workspace-graph, .workspace-button {
    &:hover {
      box-shadow: 3px 0 0 0 theme-color.$primary inset;
    }
  }
  .applet-box {
    padding: 4px 0;
    &:hover {
      box-shadow: 3px 0 0 0 theme-color.$primary inset;
    }
  }
  .applet-label {
  }
  .panel-launchers .launcher:hover {
    box-shadow: 3px 0 0 0 theme-color.$primary inset;
  }
  .applet-separator {
    padding: 4px 3px;
  }
  .systray:hover {
    box-shadow: 4px 0 0 0 theme-color.$primary inset;
  }
}
.panel-right {
    .window-list-item-box {
    &:hover {
      box-shadow: -3px 0 0 0 theme-color.$primary inset;
    }
    &:active, &:checked, &:focus {
      &:hover {
        box-shadow: -3px 0 0 0 theme-color.$primary inset;
      }
    }
  }
  .grouped-window-list-item-box {
    &:hover {
      box-shadow: -3px 0 0 0 theme-color.$primary inset;
    }
    &:active, &:checked {
      &:hover {
        box-shadow: -3px 0 0 0 theme-color.$primary inset;
      }
    }
    &:focus {
      &:hover {
        box-shadow: -3px 0 0 0 theme-color.$primary inset;
      }
    }
  }
  .workspace-switcher, .workspace-graph, .workspace-button {
    padding: 4px 1px;
    min-height: 1.2em;
  }
  .workspace-graph, .workspace-button {
    &:hover {
      box-shadow: -3px 0 0 0 theme-color.$primary inset;
    }
  }
  .applet-box {
    padding: 4px 0;
    &:hover {
      box-shadow: -3px 0 0 0 theme-color.$primary inset;
    }
  }
  .applet-label {
  }
  .panel-launchers .launcher:hover {
    box-shadow: -3px 0 0 0 theme-color.$primary inset;
  }
  .applet-separator {
    padding: 4px 3px;
  }
  .systray:hover {
    box-shadow: -4px 0 0 0 theme-color.$primary inset;
  }
}
// keyboard layout applet
.panel-status-button {
  @include typography.subtitle2;
  -natural-hpadding: 4px;
  -minimum-hpadding: 4px;
  color: theme-color.hint(theme-color.$on-titlebar);
  &:hover {
    color: theme-color.$on-titlebar;
  }
}
// used by power applet to warn of low battery
.system-status-icon {
  icon-size: 1.14em;
  padding: 0;
  spacing: 0;
  &.warning {
    color: theme-color.$warning;
  }
  &.error {
    color: theme-color.$error;
  }
}
// a non feature - not worth themeing
.panel-corner {
  &:active {
  }
  &:overview {
  }
  &:focus {
  }
}
// expo & scale view section
#overview {
  spacing: 12px;
}
.overview-empty-placeholder {
    @extend %osd-info-workspace-shared;

}
.window-caption {
  @include typography.caption;

  background-color: rgba(0, 0, 0, 0.01);
  color: theme-color.hint(theme-color.$on-titlebar);
  padding: 4px 6px;
  text-align: center;
  height: 1.5em;
  -cinnamon-caption-spacing: 12px;
  &#selected, &:focus {
    color: theme-color.$on-titlebar;
    box-shadow: 0 -3px 0 0 theme-color.$primary inset;
  }
}
.workspace-controls {
  visible-height: 32px;
}
.workspace-thumbnails-background {
  color: theme-color.hint(theme-color.$on-titlebar);
  background-color: theme-color.fill(theme-color.$on-dark);
  border: none;
  padding: 8px;
  border-radius: theme.$corner-radius 0 0 theme.$corner-radius;
  &:rtl {
    border-radius: 0 theme.$corner-radius theme.$corner-radius 0;
  }
}
.workspace-thumbnails {
  spacing: 32px;
}
.workspace-add-button {
  background-image: url(assets/add-workspace.svg);
  height: 200px;
  width: 35px;
  transition-duration: theme.$state-duration;
  &:hover {
    background-image: url(assets/add-workspace-hover.svg);
  }
  &:active {
    background-image: url(assets/add-workspace-active.svg);
  }
}
.workspace-close-button, .window-close {
  background-image: url(assets/window-close.svg);
  height: 32px;
  width: 32px;
  -cinnamon-close-overlap: 20px;
  &:hover {
    background-image: url(assets/window-close-hover.svg);
  }
  &:active {
    background-image: url(assets/window-close-active.svg);
  }
  &:rtl {
    -st-background-image-shadow: 2px 2px 6px rgba(0,0,0,0.5);
  }
}
.window-border {
    border: 1px solid theme-color.divider(theme-color.$on-surface);
}
.window-close-area {
  background-image: url(assets/trash-icon.png);
  background-size: 100px;
  background-color: theme-color.$scrim-alt;
  border: 1px solid theme-color.divider(theme-color.$on-surface);
  border-bottom-width: 0;
  border-radius: 20px 20px 0 0;
  height: 120px;
  width: 400px;
}
// this is OK with solid or transparent backgrounds
.expo-background {
  background-color: theme-color.$scrim;
}
// this always looks better semi transparent
.workspace-overview-background-shade {
  background-color: theme-color.$scrim;
}
.expo-workspace-thumbnail-frame {
  border: 1px solid theme-color.divider(theme-color.$on-surface);
  &#active {
    border: 1px solid theme-color.$primary;
  }
}
// dialog box for the cinnamon debug utility
#LookingGlassDialog {
  @extend %osd-panel-shared;

  spacing: 4px;
  padding: 8px;
}
// the calendar displayed by the calendar applet is a heavily modified menu and inherits from the .menu selectosr
// indivudual elements within the menu can be themed seperately with these selectors
.calendar {
  padding: 4px 8px;
  spacing-rows: 2px;
  spacing-columns: 4px;
}
// also covers the year label
.datemenu-date-label {
    @include typography.headline6;

    height: theme.$menu-item-height - 2px * 2;
    margin: 2px;
    padding: 6px 16px;
    border-radius: theme.$corner-radius;
    color: theme-color.$on-surface;
    text-align: center;
    &:focus {
      background-color: theme-color.divider(theme-color.$on-surface);
    }
}
.calendar-month-label {
    @include typography.subtitle2;

    height: theme.$menu-item-height - 6px * 2;
    margin: 2px;
    padding: 6px 16px;
    border-radius: theme.$corner-radius;
    color: theme-color.$on-surface;
    text-align: center;
    &:focus {
      background-color: theme-color.divider(theme-color.$on-surface);
    }
}
.calendar-change-month-back {
  @extend %calendar-shared;

  background-image: url(assets/calendar-arrow-left.svg);
  &:rtl {
    background-image: url(assets/calendar-arrow-right.svg);
  }
}
.calendar-change-month-forward {
  @extend %calendar-shared;

  background-image: url(assets/calendar-arrow-right.svg);
  &:rtl {
    background-image: url(assets/calendar-arrow-left.svg);
  }
}
.calendar-day-base {
  @include typography.caption;

  text-align: center;
  width: theme.$menu-item-height;
  height: theme.$menu-item-height;
  padding: 0;
  margin: 2px;
  border-radius: 100px;
  &:hover,
  &:focus {
    background-color: theme-color.stroke(theme-color.$on-titlebar);
  }
  &:active {
    color: theme-color.$on-primary;
    background-color: theme-color.$primary;
    border-color: transparent;
  }
}
.calendar-week-number {
  @include typography.caption;

  width: theme.$menu-item-height - 7px;
  height: theme.$menu-item-height;
  margin: 2px;
  padding: 0;
  border-radius: 100px;
  background-color: transparent;
  color: theme-color.disabled(theme-color.$on-surface);
  text-align: center;
}
.calendar-day-heading  {
  @include typography.caption;

  width: theme.$menu-item-height;
  height: theme.$menu-item-height - 7px;
  margin: 2px;
  padding: 0;
  border-radius: 100px;
  background-color: transparent;
  color: theme-color.disabled(theme-color.$on-surface);
  text-align: center;
}
.calendar-day {
  border-width: 0;
}
.calendar-day-top {
  border-top-width: 0;
}
.calendar-day-left {
  border-left-width: 0;
}
.calendar-work-day {
}
.calendar-nonwork-day {
  color: theme-color.$on-surface;
}
.calendar-today {
  font-weight: bold;
  border: none;
}
.calendar-day-with-events {
  color: theme-color.$primary;
  font-weight: normal;
  text-decoration: underline;
  background-image: none;
}
.calendar-other-month-day {
  color: theme-color.disabled-hint(theme-color.$on-surface);
  opacity: 0.5;
}
.calendar-week-number {
  width: theme.$menu-item-height;
  height: theme.$menu-item-height - 7px;
  margin: 2px;
  padding: 7px 0 0;
  border-radius: 100px;
  background-color: transparent;
  color: theme-color.disabled(theme-color.$on-surface);
  font-size: inherit;
  font-weight: bold;
  text-align: center;
}
// notification system
#notification {
  background-color: theme-color.$surface-z8;
  border-radius: theme.$corner-radius;
  border: 1px solid theme-color.divider(theme-color.$on-surface);
  padding: 8px;
  spacing-rows: 4px;
  spacing-columns: 8px;
  margin-from-right-edge-of-screen: 20px;
  width: 34em;
  color: theme-color.$on-surface;
  box-shadow: shadow.$z4;
  &.multi-line-notification {
    padding-bottom: 8px;
  }
  StEntry {
    @extend %dialog-entry-shared;
  }
  .url-highlighter {
    link-color: theme-color.$primary;
  }
}
// min height 159px is required to avoid stretching/distortion of notification image
.notification-with-image {
  min-height: 159px;
  color: theme-color.$on-surface;
}
#notification-scrollview {
  max-height: 10em;
  > {
    .top-shadow {
      height: 1em;
    }
    .bottom-shadow {
      height: 1em;
    }
  }
  &:ltr > StScrollBar {
    padding-left: 6px;
  }
  &:rtl > StScrollBar {
    padding-right: 6px;
  }
}
#notification-body {
  spacing: 4px;
}
#notification-actions {
  spacing: 8px;
}
.notification-button {
  @extend %button-shared;
}
.notification-icon-button {
  @extend %icon-button-shared;

  > StIcon {
    icon-size: 1.5em;
  }
}
// non 3D alt-tab options
#altTabPopup {
  padding: 8px;
  spacing: 16px;
}
.switcher-list {
  @extend %osd-panel-shared;

  transition-duration: theme.$state-duration;
  .item-box {
    padding: 8px;
    border-radius: theme.$corner-radius;
    &:selected {
      background-color: theme-color.divider(theme-color.$on-surface);
    }
  }
  .thumbnail-box {
    padding: 2px;
    spacing: 4px;
  }
  .thumbnail {
    width:  256px
  }
  .separator {
    width: 1px;
    background: theme-color.divider(theme-color.$on-surface);
  }
}
.switcher-list-item-container {
  spacing: 8px;
}
.thumbnail-scroll-gradient-left {
  background-gradient-direction: horizontal;
  background-gradient-start: rgba(51, 51, 51, 1.0);
  background-gradient-end: rgba(51, 51, 51, 0);
  border-radius: theme.$corner-radius;
  border-radius-topright: 0;
  border-radius-bottomright: 0;
  width: 60px;
}
.thumbnail-scroll-gradient-right {
  background-gradient-direction: horizontal;
  background-gradient-start: rgba(51, 51, 51, 0);
  background-gradient-end: rgba(51, 51, 51, 1.0);
  border-radius: theme.$corner-radius;
  border-radius-topleft: 0;
  border-radius-bottomleft: 0;
  width: 60px;
}
.switcher-arrow {
  border-color: rgba(0,0,0,0);
  color: theme-color.hint(theme-color.$on-surface);
  &:highlighted {
    color: theme-color.$on-surface;
  }
}
.switcher-preview-backdrop {
  background-color: theme-color.$scrim;
}
// hot corners animation
.ripple-box {
  width: 104px;
  height: 104px;
  background-image: url(assets/corner-ripple.png);
  background-color: theme-color.$primary;
  border-radius: 52px;
}
// on screen messages and input boxes
.modal-dialog {
	@extend %osd-panel-shared;

  padding: 16px 20px;
}
.modal-dialog-button-box {
  spacing: 16px;
}
.modal-dialog-button {
  @extend %button-shared;
}
.info-osd {
  @extend %osd-info-workspace-shared;
}
// run dialog (ALT-F2)
.run-dialog-label {
  color: theme-color.hint(theme-color.$on-surface);
  padding-bottom: .4em;
}
.run-dialog-error-label {
  color: theme-color.$error;
}
.run-dialog-error-box {
  padding-top: 16px;
  spacing: 6px;
}
.run-dialog-completion-box {
  padding-left: 15px;
}
.run-dialog-entry {
    @extend %dialog-entry-shared;
}
.run-dialog {
  border-radius: theme.$corner-radius;
  padding: 16px 20px;
}
// this is an full screen overlay that is displayed with any cinnamon OSD or modal dialog which needs to always be semi transparent
.lightbox {
  background-color: theme-color.$scrim-alt;
}
// removable media dialogs
.cinnamon-mount-operation-icon {
  icon-size: 4.8em;
}
.mount-password-reask {
  color: theme-color.$warning;
}
.show-processes-dialog {
  spacing: 24px;
}
.mount-question-dialog {
  spacing: 24px;
}
.show-processes-dialog-subject {
  @extend %dialogs-subject-shared;

  &:rtl {
    @extend %dialogs-subject-rtl-shared;
  }
}
.mount-question-dialog-subject {
  @extend %dialogs-subject-shared;

  &:rtl {
    @extend %dialogs-subject-rtl-shared;
  }
}
.show-processes-dialog-description {
  @extend %dialogs-description-shared;

  &:rtl {
    padding-right: 17px;
  }
}
.mount-question-dialog-description {
  @extend %dialogs-description-shared;

  &:rtl {
    padding-right: 17px;
  }
}
.show-processes-dialog-app-list {
  max-height: 200px;
  padding-top: 24px;
  padding-left: 49px;
  padding-right: 32px;
  &:rtl {
    padding-right: 49px;
    padding-left: 32px;
  }
}
.show-processes-dialog-app-list-item {
  color: theme-color.$on-surface;
  &:hover {
    color: theme-color.$on-surface;
  }
  &:ltr {
    padding-right: 1em;
  }
  &:rtl {
    padding-left: 1em;
  }
}
.show-processes-dialog-app-list-item-icon {
  &:ltr {
    padding-right: 17px;
  }
  &:rtl {
    padding-left: 17px;
  }
}
.show-processes-dialog-app-list-item-name {
}
// desktop zoom feature
.magnifier-zoom-region {
  border: 3px solid theme-color.divider(theme-color.$on-surface);
  &.full-screen {
    border-width: 0;
  }
}
// on screen keyboard
#keyboard {
  background-color: theme-color.$scrim;
}
.keyboard-key {
  @extend %icon-button-shared;
  @include typography.button;
}
.keyboard-layout {
  spacing: 8px;
  padding: 8px;
}
.keyboard-row {
  spacing: 16px;
}
.keyboard-subkeys { //long press on a key popup
  color: inherit;
  padding: 5px;
  -arrow-border-radius: 0;
  -arrow-background-color: transparent;
  -arrow-border-width: 0;
  -arrow-border-color: transparent;
  -arrow-base: 0;
  -arrow-rise: 0;
  -boxpointer-gap: 5px;
  background-color: theme-color.$surface-z8;
  border-radius: theme.$corner-radius;
  box-shadow: shadow.$z4;
}
// main menu applet
.menu-favorites-box {
  padding: 8px;
}
.menu-favorites-button {
  padding: 0.4em 4px;
  &:hover {
     background-color: theme-color.divider(theme-color.$on-surface);
     border-radius: theme.$corner-radius;
     color: theme-color.$on-surface;
  }
}
.menu-categories-box {
  padding: 8px;
}
.menu-applications-inner-box {
  padding: 8px;
}
.menu-applications-outer-box {
  padding: 8px;
  border-radius: theme.$corner-radius;
}
.menu-application-button {
  padding: 0.4em 4px;
  &:highlighted {
    font-weight: bold;
  }
}
.menu-application-button-selected {
  padding: 0.4em 4px;
  background-color: theme-color.divider(theme-color.$on-surface);
  border-radius: theme.$corner-radius;
  color: theme-color.$on-surface;
  &:highlighted {
    font-weight: bold;
  }
}
.menu-application-button-label {
  @extend %menu-button-label-shared;
}
.menu-category-button {
	padding: 0.4em 4px;
}
.menu-category-button-greyed {
  padding: 0.4em 4px;
  color: theme-color.hint(theme-color.$on-surface);
  font-style: italic;
}
.menu-category-button-selected {
  padding: 0.4em 4px;
  background-color: theme-color.divider(theme-color.$on-surface);
  border-radius: theme.$corner-radius;
  color: theme-color.$on-surface;
  &:hover {
  }
}
.menu-category-button-label {
  @extend %menu-button-label-shared;
}
// in the stock menu app descriptions are shown at the base of the menu
.menu-selected-app-box {
  padding: 8px;
  margin-bottom: 4px;
  text-align: right;
  &:rtl {
    text-align: left;
  }
}
.menu-selected-app-title {
  @include typography.caption;
}
.menu-selected-app-description {
  @include typography.caption;

  max-width: 150px;
}
// the menus search box
.menu-search-box {
  &:ltr {
    padding-left: 30px;
    padding-bottom: 5px;
    padding-top: 5px;
  }
  &:rtl {
    padding-right: 30px;
    padding-bottom: 5px;
    padding-top: 5px;
  }
}
#menu-search-entry {
  @extend %dialog-entry-shared;
}
.menu-search-entry-icon {
  icon-size: 1em;
  padding: 0 0;
  color: theme-color.disabled(theme-color.$on-surface);
}
// the window list applet. Some third party applets inherit some of this theming.
.window-list-box {
  @include typography.caption;

  spacing: 4px;
  padding: 0 3px;
  &.vertical {
    spacing: 4px;
    padding: 3px 0;
  }
  #appMenuIcon {
  }
  &:highlight {
    background: theme-color.stroke(theme-color.$on-titlebar);
    color: theme-color.$on-titlebar;
    }
}
.window-list-item-label {
}
// progress was added with cinnamon 3.6 and allows compatible applications to use the window list as a progress bar
.window-list-item-box {
  background-color: rgba(0, 0, 0, 0.01);
  transition-duration: theme.$state-duration;
  &:hover {
    color: theme-color.$on-titlebar;
  }
  &:active, &:checked, &:focus {
    background-color: theme-color.stroke(theme-color.$on-titlebar);
    color: theme-color.$on-titlebar;
    &:hover {
      color: theme-color.$on-titlebar;
    }
  }
  .progress {
    background-color: theme-color.$success;
  }
}
.window-list-item-box.top StLabel, .window-list-item-box.bottom StLabel {
  padding-left: 3px;
}
.window-list-item-demands-attention {
  background-color: theme-color.$titlebar;
  color: theme-color.hint(theme-color.$on-titlebar);
}
// cinnamon 3.8 will support an improved window-list-thumbnail preview which now has it's own selector
.window-list-preview {
  background-color: theme-color.$surface-z8;
  border-radius: theme.$corner-radius;
  padding: 10px 15px;
  spacing: 1em;
  color: theme-color.$on-surface;
  box-shadow: shadow.$z8;
}
// Cinnamon 4.0 has a new grouped window list applet with it's own selectors.
// Initial theme support is defined here. Some theming is defined in the panel orientation specific section above.
.grouped-window-list {
  &-thumbnail-label {
    padding-left: 3px;
    padding-bottom: 6px;
  }
  &-number-label {
    @include typography.caption;

    z-index: 99;
  }
  &-list-button-label {
    padding-left: 3px;
  }
  &-badge {
    border-radius: theme.$circular-radius;
    background-color: theme-color.$panel-solid;
  }
  &-thumbnail-alert {
    background: theme-color.$warning;
  }
  &-item-box {
    background-color: rgba(0, 0, 0, 0.01);
    transition-duration: theme.$state-duration;
    &:hover {
      color: theme-color.$on-titlebar;
    }
    &:active, &:checked {
      background-color: theme-color.divider(theme-color.$on-titlebar);
      &:hover {
        color: theme-color.$on-titlebar;
      }
    }
    &:focus {
      background-color: theme-color.stroke(theme-color.$on-titlebar);
      color: theme-color.$on-titlebar;
      &:hover {
        color: theme-color.$on-titlebar;
      }
    }
    .progress {
      background-color: theme-color.$success;
    }
  }
  &-item-demands-attention {
    background-color: theme-color.$titlebar;
    color: theme-color.hint(theme-color.$on-titlebar);
  }
  &-thumbnail-menu {
    padding: 20px;
    border: none;
    border-radius: theme.$corner-radius;
    color: theme-color.hint(theme-color.$on-titlebar);
    background: none;
    .item-box {
      padding: 8px;
      spacing: 2px;
      border-radius: theme.$corner-radius;
       &:outlined {
         border: 2px solid theme-color.divider(theme-color.$on-surface);
         color: theme-color.$on-titlebar;
       }
       &:selected {
         background: theme-color.divider(theme-color.$on-titlebar);
         color: theme-color.$on-titlebar;
       }
       > StBoxLayout { // icon and title
        &:ltr { margin: 1px 0 0 6px; }
        &:rtl { margin: 1px 6px 0 0; }

        StLabel { padding-bottom: 2px; }
      }

      > StButton { // close button
        &:ltr { margin: 1px 6px 0 0; }
        &:rtl { margin: 1px 0 0 6px; }
      }
    }
    .thumbnail-box {
      padding: 2px;
    }
    .thumbnail {
      width: 256px;
    }
    .separator {
      width: 1px;
      background: theme-color.divider(theme-color.$on-surface);
    }
  }
}
// the sound player applet
.sound-player {
  StButton {
    @extend %icon-button-shared;

    &:small {
      min-width: theme.$small-size;
      min-height: theme.$small-size;
      padding: 4px;
      StIcon {
        icon-size: 1em;
      }
    }
    StIcon {
      icon-size: 1.5em;
    }
  }
  .slider {
    @extend %slider-shared;

    height: 5px;
  }
  StBoxLayout {
    spacing: 0.5em;
  }
  > StBoxLayout {
    padding: 5px;
  }
}
.sound-player-generic-coverart {
  background: rgba(0,0,0,0.2);
}
.sound-player-overlay {
  background-color: theme-color.$surface-z8;
  min-width: 300px;
  padding: 12px 16px;
  spacing: 0.5em;
  color: theme-color.hint(theme-color.$on-surface);
}
// workspace switcher applet simple button view
.workspace-button {
  background-color: theme-color.$panel-solid;
  width: 2em;
  height: 1em;
  color: theme-color.hint(theme-color.$on-titlebar);
  margin: 2px;
  &:outlined {
    background-color: theme-color.stroke(theme-color.$on-titlebar);
    color: theme-color.$on-titlebar;
  }
}
// workspace switcher applet graph view
.workspace-graph {
   background-color: theme-color.$scrim;
  .workspace {
    background-color: theme-color.$panel-solid;
    border: 1px solid theme-color.divider(theme-color.$on-surface);
    &:active {
      background-color: theme-color.stroke(theme-color.$on-titlebar);

      border: 1px solid theme-color.divider(theme-color.$on-surface);
      .windows {
        -active-window-background: rgba(255, 255, 255, 0.8);
        -active-window-border: rgba(0, 0, 0, 0.9);
        -inactive-window-background: rgba(140, 140, 140, 0.8);
        -inactive-window-border: rgba(0, 0, 0, 0.7);
      }
    }
    .windows {
      -active-window-background: rgba(140, 140, 140, 0.8);
      -active-window-border: rgba(0, 0, 0, 0.7);
      -inactive-window-background: rgba(140, 140, 140, 0.8);
      -inactive-window-border: rgba(0, 0, 0, 0.7);
    }
  }
}
// most panel launcher themeing is orientation specific
.panel-launchers {
  padding: 0 4px;
  spacing: 4px;
  transition-duration: theme.$state-duration;
  .launcher {
    background-color:rgba(0, 0, 0, 0.01);
  }
  &.vertical {
    padding: 4px 0;
    spacing: 4px;
    .launcher .icon-box {
      padding-top: 0;
    }
  }
}
// applets in general
.applet-separator-line, .applet-separator-line-vertical {
  width: 2px;
  background: theme-color.divider(theme-color.$on-titlebar);
}
.applet-spacer:highlight {
  background: theme-color.highlight(theme-color.$surface-z8);
}
.applet-box {
  background-color: rgba(0, 0, 0, 0.01);
  color: theme-color.hint(theme-color.$on-titlebar);
  transition-duration: theme.$state-duration;
  &:checked {
    color: theme-color.$on-titlebar;
    .applet-label {
      color: theme-color.$on-titlebar;
    }
  }
  &:hover {
    color: theme-color.$on-titlebar;
    .applet-label {
      color: theme-color.$on-titlebar;
    }
  }
  &:highlight {
    background: theme-color.stroke(theme-color.$on-titlebar);
    color: theme-color.$on-titlebar;
    .applet-label {
      color: theme-color.$on-titlebar;
    }
  }
}
.applet-label {
  @include typography.subtitle2;

  color: theme-color.hint(theme-color.$on-titlebar);
}
// icon-size set to 22 to match hard-coded menu icon size - applet-icon style is used for search provider results in menu
.applet-icon {
  color: theme-color.hint(theme-color.$on-titlebar);
  padding: 0;
  spacing: 0;
  icon-size: 22px;
}
// desklets - the base .desklet selector is for 'undecorated' desklets however some subtle background themeing is desirable
// to maintain visibility irrespctive of wallpaper and to allow for the highlighting scheme to work
.desklet {
  @include typography.caption;

  color: theme-color.$on-titlebar;
  border: none;
  box-shadow: shadow.$z8;
  padding: 12px;
  background-color: theme-color.$scrim-alt;
  border-radius: theme.$corner-radius
}
// these do not inherit from .desklet
.desklet-with-borders {
  @extend %desklet-shared;
  @include typography.caption;

  background-color: theme-color.$surface-z8;
  border-radius: theme.$corner-radius;
  &:highlight {
    background-color: theme-color.highlight(theme-color.$surface-z8);
  }
}
.desklet-with-borders-and-header {
  @extend %desklet-shared;
  @include typography.caption;

  background-color: theme-color.$surface-z8;
  border-radius-bottomleft: 2px;
  border-radius-bottomright: 2px;
  &:highlight {
    background-color: theme-color.highlight(theme-color.$surface-z8);
  }
}
.desklet-header {
  @include typography.headline6;
  @extend %desklet-shared;

  background-color: theme-color.$surface-z8;
  border-radius-topleft: 2px;
  border-radius-topright: 2px;
  &:highlight {
    background-color: theme-color.highlight(theme-color.$surface-z8);
  }
}
.photoframe-box {
  @extend %desklet-shared;

  background-color: theme-color.$surface-z8;
  border-radius: theme.$corner-radius;
  &:highlight {
    background-color: theme-color.highlight(theme-color.$surface-z8);
  }
}
.desklet-drag-placeholder {
  border: 2px solid theme-color.$primary;
  background-color: theme-color.$scrim-alt;
  border-radius: theme.$corner-radius;
}
.launcher {
  padding: 1px;
  .icon-box {
    padding-top: 2px;
  }
}
// applet 'about' OSDs - inherits from modal dialogs
.about-content {
  min-width: 250px;
  min-height: 150px;
  spacing: 8px;
  padding-bottom: 16px;
}
.about-title {
  @include typography.headline6;
}
.about-uuid {
  @include typography.caption;
}
.about-icon {
  padding-right: 20px;
}
.about-scrollBox {
  border: 1px solid theme-color.divider(theme-color.$on-surface);
  border-radius: theme.$corner-radius;
}
.about-scrollBox-innerBox {
  padding: 1.2em;
  spacing: 1.2em;
}
.about-description {
  padding-top: 4px;
}
.about-version {
  padding-left: 7px;
}
.workspace-osd {
  @extend %osd-info-workspace-shared;
}
.expo-workspaces-name-entry {
  @include typography.body1;

  background-color: theme-color.entry-fill(theme-color.$on-dark);
  color: theme-color.$on-dark;
  padding: 0 8px;
  selection-background-color: theme-color.stroke(theme-color.$on-dark);
  selected-color: theme-color.$on-dark;
  caret-color: theme-color.$on-dark;
  text-align: center;
  height: theme.$medium-size;
  border-radius: theme.$corner-radius theme.$corner-radius 0 0;
  -cinnamon-caption-spacing: 12px;
  &#selected {
    color: theme-color.$on-dark;
    background-color: theme-color.stroke(theme-color.$on-dark);
  }
  &:focus {
    color: theme-color.$on-dark;
    box-shadow: inset 0 -2px theme-color.$on-dark;
  }
  &:hover {
    background-color: theme-color.divider(theme-color.$on-dark);
  }
}
.notification-applet-padding {
  padding: .5em 1em;
}
.notification-applet-container {
  max-height: 100px;
}
.check-box {
  CinnamonGenericContainer {
    spacing: 8px;
  }
  StBin {
    @extend %check-box-shared;
  }
  &:focus {
    StBin {
      @extend %check-box-shared;
    }
    &:checked StBin {
      background-image: url(assets/checkbox.svg);
    }
  }
  StLabel {
  }
  &:checked StBin {
    background-image: url(assets/checkbox.svg);
  }
}
.radiobutton {
  CinnamonGenericContainer {
    spacing: 8px;
  }
  StBin {
    @extend %radiobutton-shared;
  }
  &:focus {
    StBin {
      @extend %radiobutton-shared;
    }
    &:checked StBin {
      background-image: url(assets/radiobutton.svg);
    }
  }
  StLabel {
  }
  &:checked StBin {
    background-image: url(assets/radiobutton.svg);
  }
}
.flashspot {
  background-color: theme-color.$primary;
}
// displayed when media keys are pressed.
.osd-window {
  @extend %osd-panel-shared;

  spacing: 1em;
  padding: 16px;
  .level {
    height: 0.7em;
    border-radius: 0.3em;
    background-color: theme-color.stroke(theme-color.$on-surface);
  }
  .level-bar {
    border-radius: 0.3em;
    background-color: theme-color.$primary;
  }
}
// on screen preview of windows tiling placement
.tile-preview {
  @extend %tile-shared;

  &.snap {
    @extend %tile-shared-snap;
  }
}
.tile-hud {
  @extend %tile-shared;

  &.snap {
    @extend %tile-shared-snap;
  }
  &:top {
    border-top-width: 0;

    border-radius: 0 0 10px 10px;
  }
  &:bottom {
    border-bottom-width: 0;

    border-radius: theme.$corner-radius theme.$corner-radius 0 0;
  }
  &:left {
    border-left-width: 0;

    border-radius: 0 10px 10px 0;
  }
  &:right {
    border-right-width: 0;

    border-radius: 10px 0 0 10px;
  }
  &:top-left {
    border-top-width: 0;
    border-left-width: 0;

    border-radius: 0 0 10px 0;
  }
  &:top-right {
    border-top-width: 0;
    border-right-width: 0;

    border-radius: 0 0 0 10px;
  }
  &:bottom-left {
    border-bottom-width: 0;
    border-left-width: 0;

    border-radius: 0 10px 0 0;
  }
  &:bottom-right {
    border-bottom-width: 0;
    border-right-width: 0;

    border-radius: 10px 0 0 0;
  }
}
.systray {
  spacing: 4px;
}
// user-applet specific themeing - overrides applet stylesheet
.user-box {
  padding: 0.4em 1.3em;
  spacing: 10px;
}
.user-icon {
  padding: 4px;
  border: none;
}
.user-label {
  @include typography.subtitle2;

  color: theme-color.$on-surface;
}
