:root {
  --color-dark: #333;
  --color-medium: #666;
  --color-light: #aaa;
  --shadow-medium: 0 2px 4px rgba(0, 0, 0, 0.25);
  --font-1: "Arial, Helvetica, sans-serif";
  --font-2: "Arial, Helvetica, sans-serif";
  --pad: 2em;
}

html {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-1);
  overflow: hidden;
}

.player-title__wrapper {
  position: absolute;
  width: calc(100% - 4em);
  z-index: 1;
  padding: var(--pad);
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
}

.player-title,
.player-subtitle {
  display: block;
  margin: 0;
}

.player-title {
  font-family: var(--font-1);
  font-size: clamp(2rem, 8vw, 4rem);
  color: var(--color-dark);
}

.player-subtitle {
  font-family: var(--font-2);
  font-size: clamp(1.8rem, 6vw, 3.5rem);
  color: var(--color-medium);
}

@media screen and (min-width: 1320px) {
  .player-title {
    font-size: clamp(2.65rem, 4vw, 3.5rem);
  }

  .player-subtitle {
    font-size: clamp(2rem, 3vw, 3rem);
    color: var(--color-medium);
  }
}

model-viewer {
  position: absolute;
  width: 100%;
  height: 100%;
  background-color: white;
}

#fullscreen-viewer {
  position: absolute;
  width: 100%;
  height: 100%;
  left: 0;
  top: 0;
  display: none;
}

:host([data-js-focus-visible]:focus:not(.focus-visible)),
:host([data-js-focus-visible]) :focus:not(.focus-visible) {
  outline: none;
}

.Hotspot {
  background: var(--color-dark);
  border-radius: 24px;
  border: 2px solid #fff;
  box-shadow: var(--shadow-medium);
  box-sizing: border-box;
  cursor: pointer;
  height: 24px;
  position: relative;
  transition: opacity 0.3s;
  width: 24px;
  min-width: 0px;
  min-height: 0px;
  font-size: 2px;
}

.Hotspot:not([data-visible]) {
  background: transparent;
  border: 2px solid #fff;
  box-shadow: none;
  pointer-events: none;
}

.Hotspot:focus {
  border: 2px solid #fff;
  outline: none;
}

.Hotspot > * {
  opacity: 1;
  transform: translateY(-50%);
}

.HotspotAnnotation {
  background: #fff;
  border: 1px solid var(--color-medium);
  box-shadow: var(--shadow-medium);
  left: calc(100% + 10px);
  top: 50%;
  max-width: 300px;
  position: absolute;
  width: -webkit-max-content;
  width: -moz-max-content;
  width: max-content;
  display: none;
}

.annotationText {
  margin: 1em 4em 1em 2em;
  color: rgba(0, 0, 0, 0.8);
  font-family: Montserrat, Roboto, sans-serif;
  font-size: 14px;
  font-weight: normal;
  text-transform: none;
  text-align: left;
}

.Hotspot:not([data-visible]) > * {
  opacity: 0;
  pointer-events: none;
  transform: translateY(calc(-50% + 4px));
  transition: transform 0.3s, opacity 0.3s;
}

#closeAnnotation {
  position: absolute;
  right: 10px;
  top: 10px;
  width: 25px;
  height: 25px;
  background: var(--color-dark);
  border: 3px solid transparent;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
}

#closeAnnotation:hover {
  background: white;
}

#closeAnnotation:hover * {
  stroke: var(--color-dark);
}

#surfaceView {
  position: absolute;
  width: 100%;
  height: 100%;
  left: 0;
  top: 0;
  opacity: 0;
  display: none;
  z-index: 1;
  transition: opacity 0.5s;
}

#surfaceView:-webkit-full-screen {
  display: block;
}

#surfaceView:fullscreen {
  display: block;
}

#surfaceView:-webkit-full-screen ~ #model-viewer {
  /* Hide model-viewer when surfaceView is fullscreen */
  display: none;
}

#surfaceView:fullscreen ~ #model-viewer {
  /* Hide model-viewer when surfaceView is fullscreen */
  display: none;
}

/* Polyfill for iOS */
#surfaceView.iosFullscreen {
  display: block;
  position: fixed;
  z-index: 2147483647;
}

#surfaceView.iosFullscreen ~ #model-viewer {
  display: none;
}

#openAnnotation::before {
  content: "i";
  color: white;
  font-size: 17px;
  font-family: "Times New Roman", Times, serif;
  font-weight: bold;
  font-style: italic;
}

surface-view::part(bottomButtons) {
  position: absolute;
  top: 0;
  right: 0;
  width: calc(100% - 2em);
  display: flex;
  padding: 1em;
  justify-content: space-between;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: flex-end;
}

.toolbar__wrapper {
  position: absolute;
  bottom: 0;
  width: calc(100% - 2em);
  display: flex;
  padding: 1em;
  justify-content: space-between;
  flex-wrap: wrap;
}

.view-toggle,
.fullscreen-toggle {
  display: flex;
}

.view-toggle {
  z-index: 2;
  border: 2px solid var(--color-light);
  margin-right: 60px;
}

.fullscreen-toggle {
  z-index: 3;
  border: 2px solid transparent;
  flex-direction: row-reverse;
  align-self: flex-end;
}

surface-view::part(toggleSensorsButton),
surface-view::part(toggleFullPanelButton),
.fullscreen-toggle button {
  min-width: 155px;
}

surface-view::part(toggleFullPanelButton) {
  margin-left: 1em;
}

@media screen and (max-width: 390px) {
  surface-view::part(bottomButtons),
  .toolbar__wrapper {
    justify-content: space-around;
  }

  surface-view::part(toggleFullPanelButton),
  .fullscreen-toggle,
  .view-toggle {
    margin-top: 1em;
  }

  surface-view::part(toggleFullPanelButton) {
    margin-left: 0;
  }
}

surface-view::part(sensorsInstructions) {
  border: 2px solid var(--color-dark);
}

surface-view::part(toggleSensorsButton),
surface-view::part(toggleFullPanelButton),
.button-bar button {
  outline: none;
  border: none;
  height: 40px;
  box-sizing: border-box;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0.625rem 0.2em 0.625rem 0.9em;
  transition: all 100ms ease-in-out;
  background: white;
  border: 2px solid transparent;
  font-family: var(--font-2);
  text-transform: uppercase;
  font-size: 0.8em;
  color: var(--color-dark);
  vertical-align: text-top;
  line-height: 0;
}

.button-bar button {
  display: flex;
  margin: 0;
}

surface-view::part(toggleSensorsButton):hover,
surface-view::part(toggleFullPanelButton):hover,
.button-bar button:hover {
  border: 2px solid var(--color-dark);
}

surface-view::part(toggleSensorsSvg),
.button-bar button img,
.button-bar button svg {
  padding: 1em;
}

button.fullscreen-btn__close {
  display: none;
}

surface-view::part(toggleSensorsIcon),
.icon--fill path {
  fill: var(--color-dark);
}

.icon--stroke line {
  stroke: var(--color-dark);
}

.button-bar button.enabled {
  background-color: var(--color-light);
  color: #222;
}

.button-bar button.enabled:hover {
  cursor: initial;
  border-color: transparent;
}

.button-bar button.enabled .icon--fill path {
  fill: #222;
}

.button-bar button.enabled .icon--stroke line {
  stroke: #222;
}

@media screen and (hover: none) and (max-device-width: 480px) {
  .fullscreen-toggle {
    display: none;
  }
  .button-bar button {
    outline: none;
    border: none;
    box-sizing: border-box;
  }
}

.paintings-toolbar {
  display: none;
  z-index: 2;
  padding: 1.5em;
}

main {
  will-change: auto;
}

header {
  position: absolute;
  top: 0;
  left: 0;
  display: flex;
  width: 100vw;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  flex-grow: 1;
}

.logo {
  display: none;
  padding: 0.5em 0 0.25em 0.75em;
  width: 200px;
  z-index: 1;
}

main {
  background: white !important;
}

