:root {
    --dartboard-pannel-width: 90%;
    --dartboard-coef: 1.53846154;
}

body {
    display: flex;
    width: 100vw;
    height: var(--app-height);
    overflow: hidden;
}


.is-hidden { display: none; }


.dashboard {
    display: flex;
    flex-flow: row wrap;
    align-items: center;
    justify-content: center;
    width: 90%;
    margin: 0 auto;
}
@media (orientation: portrait) {
    .dashboard {
        flex-flow: column nowrap;
        width: 100%;
    }
}

.pannel {
    width: 100%;
    text-align: center;
}

.pannel--left {
    width: 50%;
}
.pannel--right {
    display: flex;
    flex-flow: column;
    justify-content: center;
    align-items: center;
    width: 50%;
}
@media (max-width: 768px) {
    .pannel--left,
    .pannel--right {
        width: 100%;
    }
}

.pannel--dartboard {
    position: relative;
    width: 100%;
    max-width: var(--dartboard-pannel-width);
    margin: 0 auto;
}
.pannel--dartboard::before {
    content: "";
    display: block;
    padding-top: 100%;
}

.dartboard {
    position: absolute;
    top: 50%;
    left: 50%;
    width: calc(var(--dartboard-pannel-width) / var(--dartboard-coef));
    height: auto;
    overflow: visible;
    transform: translate(-50%, -50%);
}

.dartboard__background {
    fill: #111111;
}

.dartboard__sector {
    stroke: #222222;
    stroke-width: 1;
}
.dartboard__sector--single.dartboard__sector--even { fill: #e8e2d0; }
.dartboard__sector--single.dartboard__sector--odd { fill: #1c1c1c; }
.dartboard__sector--triple.dartboard__sector--even,
.dartboard__sector--double.dartboard__sector--even { fill: #1f8a4c; }
.dartboard__sector--triple.dartboard__sector--odd,
.dartboard__sector--double.dartboard__sector--odd { fill: #c0392b; }

.dartboard__bull {
    stroke: #222222;
    stroke-width: 1;
}
.dartboard__bull--outer { fill: #1f8a4c; }
.dartboard__bull--inner { fill: #c0392b; }

.dartboard__label {
    fill: #cccccc;
    font-size: 1.6rem;
    font-weight: bold;
}

.dartboard__dart-point {
    fill: #ffcc00;
    stroke: #333333;
    stroke-width: 2;
}
.dartboard__dart-label {
    fill: #333333;
    font-size: 1.1rem;
    font-weight: bold;
}
.dartboard__dart--2 .dartboard__dart-point { fill: #ff8800; }
.dartboard__dart--3 .dartboard__dart-point { fill: #ff3333; }

.dartboard__dart-anim {
    animation: dartboard-dart-land 0.25s ease-out;
    transform-box: fill-box;
    transform-origin: center;
}
@keyframes dartboard-dart-land {
    from { transform: scale(2.4); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}



.pannel--current-turn {
    position: absolute;
    top: 1rem;
    left: 0;
    margin: 0;
    padding: 2rem;
}
.current-turn__list {
    list-style: none;
}
.current-turn__item {
    display: inline-block;
    font-weight: bold;
    font-size: 4rem;
    text-shadow: 0 0 10px red;
}
.current-turn__item + .current-turn__item {
    margin-left: 1rem;
}
@media (min-width: 768px) {
    .current-turn__item {
        font-size: 7rem;
    }
    .current-turn__item + .current-turn__item {
        margin-left: 3rem;
    }
}



.pannel--players {
    display: flex;
    flex-flow: row nowrap;
    align-items: flex-start;
    justify-content: center;
}
.player {
    width: 50%;
    padding: 1rem;
    border-top : 0.3rem solid transparent;
    opacity: 0.5;
}
.player.is-active {
    border-color: red;
    opacity: 1;
}
.player__name {
    margin-bottom: 2rem;
    font-size: 2rem;
}
.player.is-active .player__name:before {
    content: "🎯 ";
}
.player__score {
    font-weight: bold;
    font-size: 2.6rem;
}



.history {
    display: flex;
    flex-flow: row nowrap;
    align-items: flex-start;
    justify-content: center;
    overflow-x : auto;
    -ms-overflow-style: none;
    scrollbar-width: none;
}
.history::-webkit-scrollbar {
    display: none;
}
.history__title {
    width: 100%;
    margin-bottom: 2rem;
}
.history__list {
    text-align: left;
    font-size: 1.6rem;
    opacity: 0.75;
}
.history__list:last-child {
    opacity: 1;
}
.history__list + .history__list {
    margin-left: 1.5rem;
    padding-left: 1.5rem;
    border-left: 1px solid #555;
}
.history__item {
    text-align: center;
}

.cricket .history { display: none; }



.cricket-list__title {
    font-size: 1.6rem;
}
.cricket-list__list {
    margin-top: 1rem;
    list-style: none;
}
.cricket-list__item {
    display: inline-block;
    margin-right: 0.5rem;
    padding-left: 0.5rem;
    font-size: 1.2rem;
}
.cricket-list__item.item--1::before { content: '🟢'; }
.cricket-list__item.item--2::before { content: '🟠'; }
.cricket-list__item.item--3::before { content: '🔴'; }



.cricket-locked-numbers {
    display: flex;
    flex-flow: row nowrap;
    justify-content: center;
    align-items: center;
    margin: 2rem 0;
}
.cricket-locked-numbers__title {
    font-size: 1.8rem;
}
.cricket-locked-numbers__title::before { content: '🔒'; }
.cricket-locked-numbers__list {
    list-style: none;
}
.cricket-locked-numbers__item {
    display: inline-block;
    margin-left: 0.5rem;
    font-size: 1.8rem;
}
.cricket-locked-numbers__item::before {
    content: '❌';
}
.cricket-locked-numbers__item + .cricket-locked-numbers__item {
    margin-left: 1rem;
}



.pannel--inputs {
    display: flex;
    flex-flow: row wrap;
    align-items: center;
    justify-content: flex-end;
    margin-top: auto;
}
.pannel--inputs .button {
    width: 14.28571429%;
    margin: 0;
    aspect-ratio: 1 / 1;
}
.pannel--inputs .button--0 {
    margin: 0 auto 0 0;
}
.pannel--inputs .button--double,
.pannel--inputs .button--triple {
    width: 50%;
    aspect-ratio: 3.5 / 1;
}
.pannel--inputs .button--delete {
    width: 33%;
    aspect-ratio: 3.333 / 1;
    font-size: 1.8rem;
}

.button {
    text-transform: uppercase;
    font-weight: bold;
    font-size: 2.4rem;
}


.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
}
.modal {
    position: absolute;
    top: 50%;
    left: 50%;
    display: flex;
    flex-flow: column;
    align-items: center;
    justify-content: center;
    width: 90%;
    max-width: 500px;
    padding: 2rem;
    text-transform: uppercase;
    font-size: 1.8rem;
    background-color: #333;
    border-radius: 0.5rem;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    transform: translate(-50%, -50%);
}
.modal div {
    margin: 2rem 0;
    text-align: center;
}
.modal__title {
    text-align: center;
    font-size: 2.4rem;
}
.modal .button {
    min-height: 50px;
    width: 100%;
    padding: 0.5rem 1.5rem;
    margin: 0.5rem 0;
}
.modal .modal__submit {
    font-size: 1.8rem;
}
.modal .input {
    width: 100%;
    padding: 0.5rem;
    text-align: center;
    font-size: 2.4rem;
    color: #fff;
    background-color: transparent;
    border: 1px solid #555;
}
.modal .button.is-selected {
    background: green;
}