:root {
  /* Variables for icon colors */
  --app-icon-background: #2362a2;
  --app-icon-background-hover: #1d456f;
  --app-icon-background-focus: #1d456f;
  --app-icon-foreground: #ffffff;
  --app-icon-foreground-hover: #ffffff;
  --app-icon-foreground-focus: #ffffff;

  --calcite-action-indicator-color: #c62828;
  /* --calcite-color-brand: #2362a2; */
}

html,
body,
#map-container {
  padding: 0;
  margin: 0;
  height: 100%;
  width: 100%;
  overflow: hidden;
}

#filter-container {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  padding: 12px;
  background-color: var(--calcite-color-foreground-1);
  color: var(--calcite-color-text-1);
  
  /* Large screens (desktop) - matches ArcGIS SDK breakpoints */
  @media (min-width: 1024px) {
    width: 300px;
    max-width: 300px;
    height: auto;
    max-height: 600px;
    overflow-y: auto;
  }
  /* Medium screens (tablet) */
  @media (min-width: 768px) and (max-width: 1023px) {
    width: 300px;
    max-width: 300px;
    height: auto;
    max-height: 500px;
  }
  /* Small screens (mobile) */
  @media (max-width: 767px) {
    width: 100%;
    max-width: 100%;
    height: auto;
    max-height: 400px;
    overflow-y: auto;
  }
  /* Small screens (mobile) with landscape orientation */
  @media (max-width: 767px) and (orientation: landscape) {
    width: 300px;
    max-width: 300px;
    height: auto;
    max-height: 500px;
  }
}

.tooltip {
  position: absolute;
  pointer-events: none;
  transition: opacity 200ms;
  max-width: 300px;
  z-index: 1000;
}

.tooltip>div {
  margin: 0 auto;
  padding: 7px;
  border-radius: 0px;
  box-shadow: 2px 2px 6px rgba(63, 62, 62, 0.5);
  transform: translate3d(-50%, -125%, 0);
  opacity: 0.85;
}

.esri-ui-corner-container .esri-widget--button {
  background-color: var(--app-icon-background);
  color: var(--app-icon-foreground);
  
  --calcite-color-foreground-1: var(--app-icon-background);
  --calcite-color-foreground-2: var(--app-icon-background);
  --calcite-color-text-1: var(--app-icon-foreground);
  --calcite-color-text-3: var(--app-icon-foreground);
}

.esri-ui-corner-container .esri-widget--button:hover {
  background-color: var(--app-icon-background-hover);
  color: var(--app-icon-foreground-hover);
  
  --calcite-color-foreground-1: var(--app-icon-background-hover);
  --calcite-color-foreground-2: var(--app-icon-background-hover);
  --calcite-color-text-1: var(--app-icon-foreground-hover);
  --calcite-color-text-3: var(--app-icon-foreground-hover);
}

.esri-ui-corner-container .esri-widget--button:focus {
  background-color: var(--app-icon-background-focus);
  color: var(--app-icon-foreground-focus);
  
  --calcite-color-foreground-1: var(--app-icon-background-focus);
  --calcite-color-foreground-2: var(--app-icon-background-focus);
  --calcite-color-text-1: var(--app-icon-foreground-focus);
  --calcite-color-text-3: var(--app-icon-foreground-focus);

  outline: var(--esri-view-outline);
  outline-offset: var(--esri-view-outline-offset);
}

.esri-widget input:focus {
  outline: var(--esri-view-outline);
  outline-offset: var(--esri-view-outline-offset);
}

.esri-search__sources-button {
  display: none;
}

.esri-search__container {
  flex-direction: row-reverse;
}

.esri-features__pagination-action-bar {
  flex-direction: row-reverse;
}

.esri-features__header calcite-action, .esri-features__footer calcite-action {
  /* --calcite-action-text-color-pressed: var(--app-icon-foreground-hover); */
  --calcite-action-background-color-hover: var(--app-icon-background-hover);
  --calcite-action-background-color-pressed: var(--app-icon-background-hover);
}

.esri-features__header, .esri-features__footer {
  flex-direction: row-reverse;
  
  --calcite-color-foreground-1: var(--app-icon-background);
  --calcite-color-foreground-2: var(--app-icon-background-focus);
  --calcite-color-text-1: var(--app-icon-foreground-focus);
  --calcite-color-text-3: var(--app-icon-foreground);
}

.esri-menu .esri-menu__header {
  background-color: var(--app-icon-background);
}

.esri-menu__list-item:active {
  background-color: var(--app-icon-background);
  color: var(--app-icon-foreground);
}

.esri-menu__list-item:hover {
  background-color: var(--app-icon-background-hover);
  color: var(--app-icon-foreground-hover);
}

.esri-search__suggestions-menu {
  z-index: 1000;
}

.esri-widget-popup--button {
  background-color: var(--app-icon-background);
  color: var(--app-icon-foreground) !important;
}

.esri-widget-popup--button:hover {
  background-color: var(--app-icon-background-hover);
  color: var(--app-icon-foreground-hover) !important;
}

.esri-widget-popup--button:focus {
  background-color: var(--app-icon-background-hover);
  color: var(--app-icon-foreground-hover) !important;
  outline: var(--esri-view-outline);
  outline-offset: var(--esri-view-outline-offset);
}