/* Climate Engine v2 visual refresh.
 * Style-only overrides scoped to the ce-theme-v2 body class.
 */

.ce-theme-v2 {
  --ce-bg: #e7ecf2;
  --ce-surface: #ffffff;
  --ce-primary: #0a4d95;
  --ce-primary-strong: #083d79;
  --ce-primary-hover: #0f6fd6;
  --ce-accent: #35c59c;
  --ce-text: #1f2a37;
  --ce-text-muted: #5d6a79;
  --ce-border: #d8e0e8;
  --ce-radius-md: 10px;
  --ce-radius-lg: 14px;
  --ce-shadow-sm: 0 6px 14px rgba(8, 61, 121, 0.08);
  --ce-shadow-md: 0 10px 24px rgba(8, 61, 121, 0.12);
  --ce-sidebar-width: 500px;
  --ce-sidebar-width-md: 500px;
  background: radial-gradient(circle at top right, #f5f8fb 0%, #e7ecf2 60%);
  color: var(--ce-text);
  font-family: "Poppins", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

.ce-theme-v2,
.ce-theme-v2 input,
.ce-theme-v2 select,
.ce-theme-v2 textarea,
.ce-theme-v2 button {
  font-family: "Poppins", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

.ce-theme-v2 a {
  color: var(--ce-primary);
}

.ce-theme-v2 a:hover,
.ce-theme-v2 a:focus {
  color: var(--ce-primary-hover);
}

.ce-theme-v2 #wrapper {
  width: 100%;
  min-height: 100%;
}

.ce-theme-v2 #wrapper.toggled {
  padding-left: var(--ce-sidebar-width);
}

.ce-theme-v2 #sidebar-wrapper {
  left: var(--ce-sidebar-width);
  margin-left: calc(-1 * var(--ce-sidebar-width));
  background: transparent;
  border-right: 0;
  height: calc(100vh - 84px);
  overflow-y: auto;
  overflow-x: hidden;
  padding: 14px 10px 22px;
}

.ce-theme-v2 #wrapper.toggled #sidebar-wrapper {
  width: var(--ce-sidebar-width);
}

.ce-theme-v2 .sidebar-nav {
  position: relative;
  width: 100%;
  padding-right: 10px;
  box-sizing: border-box;
}

.ce-theme-v2 #page-content-wrapper {
  padding: 16px 18px 92px;
}

@media (min-width: 900px) {
  .ce-theme-v2 #wrapper {
    padding-left: var(--ce-sidebar-width);
  }

  .ce-theme-v2 #wrapper.toggled {
    padding-left: 0;
  }

  .ce-theme-v2 #sidebar-wrapper {
    width: var(--ce-sidebar-width);
  }

  .ce-theme-v2 #wrapper.toggled #sidebar-wrapper {
    width: 0;
  }
}

.ce-theme-v2 .tabbable > br:first-child,
.ce-theme-v2 #tabmapoptions > br:first-child,
.ce-theme-v2 #tabtimeseriesoptions > br:first-child {
  display: none;
}

.ce-theme-v2 #sidebar-wrapper .tabbable {
  margin-top: 0;
}

.ce-theme-v2 #dataTab {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  border: 1px solid var(--ce-border);
  border-radius: var(--ce-radius-md);
  background: #eff4fb;
  margin: 0 0 14px;
  padding: 0;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(8, 61, 121, 0.06);
}

.ce-theme-v2 #dataTab::before,
.ce-theme-v2 #dataTab::after {
  display: none;
  content: none;
}

.ce-theme-v2 #dataTab > li {
  float: none;
  margin: 0;
  flex: 1 1 0;
  min-width: 0;
  border-right: 1px solid var(--ce-border);
}

.ce-theme-v2 #dataTab > li:last-child {
  flex: 0 0 72px;
  border-right: 0;
}

.ce-theme-v2 #dataTab li a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  border: 0;
  margin: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ce-primary) !important;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.15;
  min-height: 72px;
  height: 72px;
  padding: 10px 10px;
  text-align: center;
  white-space: nowrap;
}

.ce-theme-v2 #dataTab > li:last-child > a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100% !important;
  max-width: none !important;
  padding: 0 !important;
  min-height: 72px;
  height: 72px !important;
  background: #f9fbff;
}

.ce-theme-v2 #dataTab > li:last-child > a[data-toggle="popover"] {
  width: 100% !important;
  height: 72px !important;
}

.ce-theme-v2 #dataTab li.active a,
.ce-theme-v2 #dataTab li.active a:hover,
.ce-theme-v2 #dataTab li.active a:focus {
  background: linear-gradient(180deg, #0f6fd6 0%, #0a4d95 100%);
  color: #ffffff !important;
}

.ce-theme-v2 #dataTab li a:hover,
.ce-theme-v2 #dataTab li a:focus {
  background: rgba(10, 77, 149, 0.1);
}

.ce-theme-v2 #dataTab img[src*="Info-Button1.jpg"],
.ce-theme-v2 #dataTab img[src*="/static/img/info.png"] {
  height: 22px;
  width: 22px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.4);
}

.ce-theme-v2 .mapgraph-info-trigger {
  display: flex !important;
  align-items: center;
  justify-content: center;
  outline: 0;
}

.ce-theme-v2 #dataFigTab {
  display: flex;
  align-items: center;
  gap: 4px;
  border-radius: var(--ce-radius-md);
  border: 1px solid #0a4688;
  background: linear-gradient(110deg, #083d79 0%, #0a4d95 70%, #0f6fd6 100%);
  box-shadow: var(--ce-shadow-md);
  margin: 0 0 14px;
  padding: 6px 10px;
  min-height: 58px;
}

.ce-theme-v2 #dataFigTab::before,
.ce-theme-v2 #dataFigTab::after {
  display: none;
  content: none;
}

.ce-theme-v2 #dataFigTab > li {
  float: none;
  margin: 0;
  align-self: center;
}

.ce-theme-v2 #dataFigTab > li.pull-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  padding: 0 8px 0 0 !important;
}

.ce-theme-v2 #dataFigTab > li:not(.pull-right) {
  display: flex;
  align-items: center;
  min-height: 44px;
}

.ce-theme-v2 #dataFigTab > li.menu-toggle-item {
  margin-right: 6px;
}

.ce-theme-v2 #dataFigTab li br {
  display: none;
}

.ce-theme-v2 #dataFigTab > li:not(.pull-right) > a {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0 !important;
  border-radius: 8px;
  margin: 0;
  color: #e6efff;
  background: transparent;
  font-weight: 600;
  font-size: 17px;
  line-height: 1.1;
  min-height: 44px;
  height: 44px;
  padding: 0 14px;
  box-shadow: none;
}

.ce-theme-v2 #dataFigTab > li:not(.pull-right).active > a,
.ce-theme-v2 #dataFigTab > li:not(.pull-right).active > a:hover,
.ce-theme-v2 #dataFigTab > li:not(.pull-right).active > a:focus {
  border: 0 !important;
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.ce-theme-v2 #dataFigTab > li:not(.pull-right) > a:hover,
.ce-theme-v2 #dataFigTab > li:not(.pull-right) > a:focus {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

.ce-theme-v2 #menu-toggle-display {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border: 0 !important;
  border-radius: 8px;
  color: var(--ce-primary);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.1;
  min-height: 44px;
  height: 44px;
  padding: 0 14px;
  box-shadow: none;
}

.ce-theme-v2 #menu-toggle-display:hover,
.ce-theme-v2 #menu-toggle-display:focus {
  color: var(--ce-primary);
  background: #eef4ff;
}

.ce-theme-v2 #climateEngineHomeLink {
  display: flex;
  align-items: center;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  box-shadow: none !important;
}

.ce-theme-v2 #climateEngineHomeLink img {
  display: block;
  filter:
    drop-shadow(0 0 10px rgba(255, 255, 255, 0.95))
    drop-shadow(0 0 22px rgba(255, 255, 255, 0.6));
}

.ce-theme-v2 .panel.panel-default {
  border: 1px solid var(--ce-border);
  border-radius: var(--ce-radius-md);
  box-shadow: var(--ce-shadow-sm);
  background: var(--ce-surface);
  margin-bottom: 14px;
  overflow: hidden;
}

.ce-theme-v2 .panel.panel-default > .panel-body {
  padding: 14px 18px;
}

.ce-theme-v2 .panel-forms {
  background: var(--ce-surface) !important;
}

.ce-theme-v2 #sidebar-wrapper b,
.ce-theme-v2 #sidebar-wrapper .panel-title {
  color: var(--ce-text);
  font-weight: 600;
}

.ce-theme-v2 #sidebar-wrapper b > span,
.ce-theme-v2 #sidebar-wrapper span[style*="color:blue"] {
  color: var(--ce-primary) !important;
  font-weight: 700;
}

.ce-theme-v2 img[src*="questionmark.png"] {
  height: 18px;
  width: 18px;
  vertical-align: text-bottom;
}

.ce-theme-v2 #form-button-submit-map,
.ce-theme-v2 #form-button-submit-map2,
.ce-theme-v2 #form-button-submit-timeseries,
.ce-theme-v2 #form-button-submit-timeseries2,
.ce-theme-v2 #form-button-submit-timeseries3 {
  display: block;
  float: none !important;
  height: 52px;
  border: 0;
  border-radius: var(--ce-radius-md);
  background: linear-gradient(180deg, #0f6fd6 0%, #0a4d95 100%) !important;
  color: #ffffff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: 0 10px 20px rgba(8, 61, 121, 0.24);
}

.ce-theme-v2 #tour_timeseries_submit {
  display: flow-root;
  margin-bottom: 14px;
}

.ce-theme-v2 #tour_map_submit {
  display: flow-root;
  margin: 0 0 14px;
}

.ce-theme-v2 #tour_map_vizlayer_intro {
  margin-top: 14px;
}

.ce-theme-v2 #tour_timeseries_submit br {
  display: none;
}

.ce-theme-v2 #tour_map_submit br {
  display: none;
}

.ce-theme-v2 #form-button-submit-map:hover,
.ce-theme-v2 #form-button-submit-map2:hover,
.ce-theme-v2 #form-button-submit-timeseries:hover,
.ce-theme-v2 #form-button-submit-timeseries2:hover,
.ce-theme-v2 #form-button-submit-timeseries3:hover {
  background: linear-gradient(180deg, #1784e8 0%, #0f6fd6 100%) !important;
}

.ce-theme-v2 .btn {
  border-radius: 8px;
  font-weight: 600;
}

.ce-theme-v2 .btn-default {
  border: 1px solid var(--ce-border);
  background: #ffffff;
  color: var(--ce-primary);
}

.ce-theme-v2 .btn-default:hover,
.ce-theme-v2 .btn-default:focus {
  background: #f4f8ff;
  color: var(--ce-primary-hover);
}

.ce-theme-v2 select,
.ce-theme-v2 input[type="text"],
.ce-theme-v2 textarea {
  min-height: 38px;
  border: 1px solid var(--ce-border);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ce-text);
  padding: 6px 10px;
  box-shadow: none;
}

.ce-theme-v2 #productTS,
.ce-theme-v2 #product2TS,
.ce-theme-v2 #variableTS,
.ce-theme-v2 #variable2TS,
.ce-theme-v2 #product,
.ce-theme-v2 #variable {
  padding-left: 10px !important;
  text-indent: 0 !important;
}

.ce-theme-v2 #productTab {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid var(--ce-border);
  margin: 0;
  padding: 0 0 0 2px;
}

.ce-theme-v2 #productTab::before,
.ce-theme-v2 #productTab::after {
  display: none;
  content: none;
}

.ce-theme-v2 #productTab > li {
  float: none;
  margin: 0 0 -1px;
}

.ce-theme-v2 #productTab > li > a {
  margin: 0;
  border-radius: 10px 10px 0 0;
  border: 1px solid transparent;
  border-bottom: 0;
  color: var(--ce-primary);
  background: #eaf2fb;
  font-size: 18px;
  font-weight: 600;
  padding: 10px 20px;
}

.ce-theme-v2 #productTab > li.active > a,
.ce-theme-v2 #productTab > li.active > a:hover,
.ce-theme-v2 #productTab > li.active > a:focus {
  color: var(--ce-primary);
  background: #ffffff;
  border-color: var(--ce-border);
  border-bottom-color: #ffffff;
}

.ce-theme-v2 #productTab > li > a:hover,
.ce-theme-v2 #productTab > li > a:focus {
  background: #dfeefe;
}

.ce-theme-v2 #productTab + .tab-content {
  border-top: 0;
  margin-top: 0;
  padding-top: 0;
}

.ce-theme-v2 #product1tab > br:first-child,
.ce-theme-v2 #product2tab > br:first-child {
  display: none;
}

.ce-theme-v2 #product1tab .panel.panel-default:first-child,
.ce-theme-v2 #product2tab .panel.panel-default:first-child {
  margin-top: 0;
  border-top-left-radius: 0;
}

.ce-theme-v2 select:focus,
.ce-theme-v2 input[type="text"]:focus,
.ce-theme-v2 textarea:focus {
  border-color: var(--ce-primary-hover);
  box-shadow: 0 0 0 3px rgba(53, 197, 156, 0.2);
  outline: 0;
}

.ce-theme-v2 #navbar_map,
.ce-theme-v2 #above-ts-nav {
  border: 0;
  border-radius: var(--ce-radius-md);
  background: linear-gradient(110deg, #083d79 0%, #0a4d95 78%, #0f6fd6 100%) !important;
  box-shadow: var(--ce-shadow-sm);
  margin-bottom: 14px !important;
}

.ce-theme-v2 #navbar_map .container-fluid,
.ce-theme-v2 #above-ts-nav .container-fluid {
  padding-left: 16px;
  padding-right: 16px;
}

.ce-theme-v2 #mapoptionscollapse,
.ce-theme-v2 #timeseriesoptionscollapse {
  background: transparent !important;
  text-align: left !important;
}

.ce-theme-v2 #navbar_map .navbar-nav > li > a,
.ce-theme-v2 #above-ts-nav .navbar-nav > li > a {
  color: #edf3ff !important;
  font-size: 17px;
  font-weight: 600;
  padding-top: 13px;
  padding-bottom: 13px;
}

.ce-theme-v2 #navbar_map .navbar-nav > li > a:hover,
.ce-theme-v2 #above-ts-nav .navbar-nav > li > a:hover,
.ce-theme-v2 #navbar_map .navbar-nav > li > a:focus,
.ce-theme-v2 #above-ts-nav .navbar-nav > li > a:focus {
  color: #ffffff !important;
  background: rgba(255, 255, 255, 0.12);
}

.ce-theme-v2 #navbar_map .navbar-nav.navbar-right > li,
.ce-theme-v2 #above-ts-nav .navbar-nav.navbar-right > li {
  position: relative;
  display: flex;
  align-items: center;
}

.ce-theme-v2 #navbar_map .navbar-nav.navbar-right,
.ce-theme-v2 #above-ts-nav .navbar-nav.navbar-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: nowrap;
  margin-top: 0;
  margin-bottom: 0;
}

.ce-theme-v2 #navbar_map .navbar-nav.navbar-right > li > a,
.ce-theme-v2 #above-ts-nav .navbar-nav.navbar-right > li > a {
  display: flex;
  align-items: center;
  line-height: 1.1;
  min-height: 46px;
  white-space: nowrap;
  padding-left: 10px;
  padding-right: 10px;
}

.ce-theme-v2 #navbar_map .navbar-nav.navbar-right > li + li::before,
.ce-theme-v2 #above-ts-nav .navbar-nav.navbar-right > li + li::before {
  content: "";
  display: inline-block;
  vertical-align: middle;
  width: 1px;
  height: 20px;
  margin-right: 8px;
  background: rgba(237, 243, 255, 0.35);
}

.ce-theme-v2 #navbar_map .caret,
.ce-theme-v2 #above-ts-nav .caret {
  border-top-color: #edf3ff;
  border-bottom-color: #edf3ff;
}

.ce-theme-v2 .dropdown-menu {
  border: 1px solid var(--ce-border);
  border-radius: var(--ce-radius-md);
  box-shadow: var(--ce-shadow-md);
  background: var(--ce-surface);
  padding: 12px !important;
}

.ce-theme-v2 .dropdown-menu .panel.panel-default {
  border: 0;
  box-shadow: none;
}

.ce-theme-v2 .dropdown-menu p,
.ce-theme-v2 .dropdown-menu label,
.ce-theme-v2 .dropdown-menu small {
  color: var(--ce-text);
}

.ce-theme-v2 .popover {
  border-radius: var(--ce-radius-md);
  border: 1px solid var(--ce-border);
  box-shadow: var(--ce-shadow-md);
}

.ce-theme-v2 #taboutmap .printableMap {
  padding: 0 !important;
}

.ce-theme-v2 #taboutmap > br {
  display: none;
}

.ce-theme-v2 #map-wrapper {
  border: 1px solid var(--ce-border);
  border-radius: var(--ce-radius-lg);
  box-shadow: var(--ce-shadow-md);
  background: #ffffff;
  overflow: hidden;
}

.ce-theme-v2 .map-wrapper-sm {
  height: calc(100vh - 300px);
}

.ce-theme-v2 .map-wrapper-md,
.ce-theme-v2 .map-wrapper-lg {
  height: calc(100vh - 272px);
}

.ce-theme-v2 .map-wrapper-xlg {
  height: calc(100vh - 252px);
}

.ce-theme-v2 #map {
  border-radius: 0;
}

.ce-theme-v2 #dataSourceRegion {
  color: var(--ce-text-muted);
  font-size: 12px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 8px;
  margin: 8px;
}

.ce-theme-v2 #displayWindow {
  background: transparent;
  overflow-y: auto !important;
}

.ce-theme-v2 .colorbarHTML,
.ce-theme-v2 #titleRegion {
  background: transparent;
}

.ce-theme-v2 #myFooter {
  border-top: 1px solid #0f6fd6 !important;
  background: linear-gradient(100deg, #083d79 0%, #0a4d95 100%) !important;
  box-shadow: 0 -8px 20px rgba(8, 61, 121, 0.2);
}

.ce-theme-v2 #myFooter .container-fluid,
.ce-theme-v2 #myFooter .navbar-collapse,
.ce-theme-v2 #myFooter .navbar-header {
  background: transparent !important;
}

.ce-theme-v2 #myFooter span,
.ce-theme-v2 #myFooter a {
  color: #edf3ff !important;
}

.ce-theme-v2 #myFooter a:hover,
.ce-theme-v2 #myFooter a:focus {
  color: #ffffff !important;
}

.ce-theme-v2 #myFooter .caret {
  border-top-color: #edf3ff !important;
  border-bottom-color: #edf3ff !important;
}

.ce-theme-v2 #myFooter .dropdown-menu {
  border-radius: var(--ce-radius-md);
  background: #ffffff !important;
}

.ce-theme-v2 #myFooter .dropdown-menu a,
.ce-theme-v2 #myFooter .dropdown-menu span {
  color: var(--ce-text) !important;
}

.ce-theme-v2 #myFooter .dropdown-menu a:hover,
.ce-theme-v2 #myFooter .dropdown-menu a:focus {
  color: var(--ce-primary-hover) !important;
}

.ce-theme-v2 .ts_data_tab {
  border: 1px solid var(--ce-border);
  border-radius: var(--ce-radius-md);
  box-shadow: var(--ce-shadow-sm);
}

@media (max-width: 1200px) {
  .ce-theme-v2 #sidebar-wrapper,
  .ce-theme-v2 .sidebar-nav,
  .ce-theme-v2 #wrapper.toggled #sidebar-wrapper {
    width: var(--ce-sidebar-width-md);
  }

  .ce-theme-v2 #sidebar-wrapper {
    left: var(--ce-sidebar-width-md);
    margin-left: calc(-1 * var(--ce-sidebar-width-md));
    height: calc(100vh - 84px);
  }

  .ce-theme-v2 #wrapper.toggled {
    padding-left: var(--ce-sidebar-width-md);
  }

  .ce-theme-v2 #form-button-submit-map,
  .ce-theme-v2 #form-button-submit-map2,
  .ce-theme-v2 #form-button-submit-timeseries,
  .ce-theme-v2 #form-button-submit-timeseries2,
  .ce-theme-v2 #form-button-submit-timeseries3 {
    font-size: 15px;
  }

  .ce-theme-v2 .map-wrapper-sm {
    height: calc(100vh - 320px);
  }

  .ce-theme-v2 .map-wrapper-md,
  .ce-theme-v2 .map-wrapper-lg {
    height: calc(100vh - 292px);
  }

  .ce-theme-v2 .map-wrapper-xlg {
    height: calc(100vh - 272px);
  }
}

@media (max-width: 767px) {
  .ce-theme-v2 #navbar_map .navbar-nav.navbar-right,
  .ce-theme-v2 #above-ts-nav .navbar-nav.navbar-right {
    display: block;
  }

  .ce-theme-v2 #sidebar-wrapper {
    height: auto;
    padding-bottom: 80px;
  }

  .ce-theme-v2 #myFooter {
    position: relative;
  }

  .ce-theme-v2 #page-content-wrapper {
    padding: 10px 10px 80px;
  }
}
