:host { --header-height: 4em; --footer-height: 9em; --header-height-landscape: 3em; --footer-height-landscape: 6em; --shutter-size: 6em; --icon-size-header: 1.5em; --icon-size-footer: 2.5em; --margin-size-header: 1.5em; --margin-size-footer: 2.0em; font-family: -apple-system, BlinkMacSystemFont, “Segoe UI”, “Roboto”, “Droid Sans”, “Helvetica Neue”, sans-serif; display: block; width: 100%; height: 100%; } .items { box-sizing: border-box; display: flex; width: 100%; height: 100%; align-items: center; justify-content: center; } .items .item { flex: 1; text-align: center; } .items .item:first-child { text-align: left; } .items .item:last-child { text-align: right; } .camera-wrapper { position: relative; display: flex; flex-direction: column; width: 100%; height: 100%; } .camera-header { color: white; background-color: black; height: var(--header-height); } .camera-header .items { padding: var(--margin-size-header); } .camera-footer { position: relative; color: white; background-color: black; height: var(--footer-height); } .camera-footer .items { padding: var(--margin-size-footer); } @media (max-height: 375px) { .camera-header { --header-height: var(--header-height-landscape); } .camera-footer { --footer-height: var(--footer-height-landscape); } .camera-footer .shutter { --shutter-size: 4em; } } .camera-video { position: relative; flex: 1; overflow: hidden; background-color: black; } video { width: 100%; height: 100%; max-height: 100%; min-height: 100%; object-fit: cover; background-color: black; } .pick-image { display: flex; align-items: center; position: absolute; left: var(--margin-size-footer); top: 0; height: 100%; width: var(--icon-size-footer); color: white; } .pick-image input { visibility: hidden; } .pick-image svg { cursor: pointer; fill: white; width: var(--icon-size-footer); height: var(--icon-size-footer); } .shutter { position: absolute; left: 50%; top: 50%; width: var(--shutter-size); height: var(--shutter-size); margin-top: calc(var(--shutter-size) / -2); margin-left: calc(var(--shutter-size) / -2); border-radius: 100%; background-color: #c6cdd8; padding: 12px; box-sizing: border-box; } .shutter:active .shutter-button { background-color: #9da9bb; } .shutter-button { background-color: white; border-radius: 100%; width: 100%; height: 100%; } .rotate { display: flex; align-items: center; position: absolute; right: var(--margin-size-footer); top: 0; height: 100%; width: var(--icon-size-footer); color: white; } .rotate img { width: var(--icon-size-footer); height: var(--icon-size-footer); } .shutter-overlay { z-index: 5; position: absolute; width: 100%; height: 100%; background-color: black; } .error { width: 100%; height: 100%; color: white; display: flex; justify-content: center; align-items: center; } .no-device { background-color: black; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; color: white; } .no-device label { cursor: pointer; background: #fff; border-radius: 6px; padding: 6px 8px; color: black; } .no-device input { visibility: hidden; height: 0; margin-top: 16px; } .accept { background-color: black; flex: 1; overflow: hidden; } .accept .accept-image { width: 100%; height: 100%; max-height: 100%; background-position: center center; background-size: cover; background-repeat: no-repeat; } .close img { cursor: pointer; width: var(--icon-size-header); height: var(--icon-size-header); } .flash img { width: var(--icon-size-header); height: var(--icon-size-header); } .accept-use img { width: var(--icon-size-footer); height: var(--icon-size-footer); } .accept-cancel img { width: var(--icon-size-footer); height: var(--icon-size-footer); } .offscreen-image-render { top: 0; left: 0; visibility: hidden; pointer-events: none; width: 100%; height: 100%; }