@charset "utf-8";

@font-face {
	font-family: 'apple-ii';
	src: url('../assets/fonts/apple-ii.otf') format('opentype');
	font-weight: normal;
	font-style: normal;
	font-display: swap;
}

.lost-timer {
	font-family: Helvetica, sans-serif;
	-webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    margin: 0 auto;
}

.lost-timer-side {
	text-align: center;
	padding-top: 10px;
	padding-bottom: 10px;
	padding-left: 10px;
	background: rgba(95, 95, 95, 0.7);
	font-weight: bold;
	/* light from above and slightly in front of the timer casts the shadow down and back */
	box-shadow: 0 16px 26px -6px rgba( 0, 0, 0, 0.7 );
}

.lost-timer-side-left {
	float: left;
	color: #ffffff;
}

.lost-timer-side-right {
	display: inline-block;
	color: #000000;
}

.lost-timer-number {
	float: left;
	margin-right: 10px;
}

.lost-timer-number-inner {
	position: relative;
}

.lost-timer-number-center-bar {
	position: absolute;
	height: 2px;
	background: #000000;
	width: 100%;
	left: 0;
	top: calc( 50% - 1px );
	z-index: 5;
	box-shadow: 0 0 8px 2px rgba( 0, 0, 0, 0.4 );
}

.lost-timer-glyph-red-bg {
	background: #000000;
}

.lost-timer-glyph-black-bg {
	background: #ad363c;
}

.lost-flipper {
	position: relative;
	z-index: 0;
}

.lost-flipper-number {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
  	z-index: 3;
	/* gives the flip 3d depth so the leading edge swells toward the viewer then shrinks */
	perspective: 400px;
}

.lost-flipper-number-before,
.lost-flipper-number-after {
	height: 100%;
	width: 100%;
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	box-sizing: border-box;
	transition: 0.4s all linear;
	transform-style: preserve-3d;
	-webkit-mask: linear-gradient( #fff,#fff ) top/100% 50% no-repeat;
	mask: linear-gradient( #fff,#fff ) top/100% 50% no-repeat;
}

.lost-flipper-number-before {
	/* shadow gathers along the top edge so the top flap reads as bent inward (tipping away from the light) */
	box-shadow: inset 0 9px 11px -7px rgba( 0, 0, 0, 0.6 ), inset 0 0 5px rgba( 0, 0, 0, 0.13 );
}

.lost-flipper-number-after {
	-webkit-mask-position: bottom;
	mask-position: bottom;
	/* light gathers along the bottom edge so the bottom flap reads as bent outward (toward the light) */
	box-shadow: inset 0 -9px 11px -7px rgba( 255, 255, 255, 0.18 ), inset 0 0 5px rgba( 0, 0, 0, 0.15 );
}

.lost-flipper-bg-white .lost-flipper-number-before {
	color: #1a1a1a;
	background: #e2e2e2;
	/* border: 1px solid #908f8f; */
}

.lost-flipper-bg-white .lost-flipper-number-after {
	color: #1a1a1a;
	background: #cccccc;
	/* border: 1px solid #a29f96; */
}

.lost-flipper-bg-black .lost-flipper-number-before {
	color: #f0f0ef;
	background: #2d2d2b;
	/* border: 1px solid #44434177; */
}

.lost-flipper-bg-black .lost-flipper-number-after {
	color: #f0f0ef;
	background: #1c1c1b;
	/* border: 1px solid #34332f7e; */
}

/* glyph "red" cards: a red glyph sits on a black card (number slots 1-3) */
.lost-flipper-bg-glyph-red .lost-flipper-number-before {
	color: #ffffff;
	background: #000000;
	/* border: 1px solid #4f4f4f85; */
}

.lost-flipper-bg-glyph-red .lost-flipper-number-after {
	color: #ffffff;
	background: #1f1f1f;
	/* border: 1px solid #3c3c3c7e; */
}

/* glyph "black" cards: a black glyph sits on a red card (number slots 4-5) */
.lost-flipper-bg-glyph-black .lost-flipper-number-before {
	color: #000000;
	background: #8e2c31;
	border: 1px solid #6a2024;
}

.lost-flipper-bg-glyph-black .lost-flipper-number-after {
	color: #000000;
	background: #ad363c;
	border: 1px solid #c84a50;
}

.lost-flipper-next {
	z-index: 2;
  	transition: 0s 0.25s all linear;
}

/* fast split-flap flip used while the glyphs roll after 0:00; the folds chain back to
   back so this duration is the full cadence ( each fold animates the whole time, no idle ) */
.lost-flipper-spin .lost-flipper-number-before,
.lost-flipper-spin .lost-flipper-number-after {
	transition-duration: 0.07s;
}

.lost-flipper-spin .lost-flipper-next {
	transition-delay: 0.035s;
}

/* blur only the printed number/glyph (not the card itself) so it isn't legible until it locks */
.lost-flipper-blur .lost-flipper-number-table-cell {
	-webkit-filter: blur( 8px );
	filter: blur( 8px );
}

.lost-flipper-number-table {
	display: table;
	height: inherit;
	width: inherit;
}

.lost-flipper-number-table-cell {
	display: table-cell;
	height: inherit;
	width: inherit;
	vertical-align: middle;
}

.lost-flipper-next-after-number {
	transform: rotateX( -180deg );
}

.lost-flipper-prev-before {
	transform: rotateX( 0deg );
}

.lost-flipper-next-active {
	z-index: 4 !important;
}

.lost-flipper-next-after-active {
    transform: rotateX( 0deg );
}

.lost-flipper-prev-before-active {
    transform: rotateX( -180deg );
}

.lost-flipper-hg-img {
	/* size off the casing height (like the digits) so the glyph fills the card
	   without distorting or overflowing the bottom when the card is wider than tall */
	height: 37cqh;
	width: auto;
	max-width: 100%;
	display: block;
	margin: 0 auto;
}

.lost-timer-dev {
	margin-top: 15px;
	font-weight: bold;
	font-size: 16px;
}

.lost-timer-dev-main-text {
	color: #ffffff;
	margin-bottom: 10px;
}

.lost-timer-dev-action {
	color: #43b047;
	cursor: pointer;
	margin-top: 5px;
}

.lost-timer-shake {
  	animation: shake 0.5s;
  	animation-iteration-count: infinite; 
}

@keyframes shake {
	0% { transform: translate(1px, 1px) rotate(0deg); }
	10% { transform: translate(-1px, -2px) rotate(-1deg); }
	20% { transform: translate(-3px, 0px) rotate(1deg); }
	30% { transform: translate(3px, 2px) rotate(0deg); }
	40% { transform: translate(1px, -1px) rotate(1deg); }
	50% { transform: translate(-1px, 2px) rotate(-1deg); }
	60% { transform: translate(-3px, 1px) rotate(0deg); }
	70% { transform: translate(3px, 1px) rotate(-1deg); }
	80% { transform: translate(-1px, -1px) rotate(1deg); }
	90% { transform: translate(1px, 2px) rotate(0deg); }
	100% { transform: translate(1px, -2px) rotate(-1deg); }
}

.lost-timer-end-screen {
	opacity: 0;
	background: white;
	height: 100%;
	width: 100%;
	position: absolute;
	z-index: 1;
	opacity: 0;
	top: 0;
	display: none;
}