@font-face {
  font-family: 'AppFont';
  src: url('../../font/font.ttf') format('truetype');
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --blue: #0A67E9;
  --blue-dark: #0a5fe0;
  --blue-deep: #0957d0;
  --card: #ffffff;
  --shadow: 0 10px 24px rgba(7, 25, 64, 0.18);
  --ink: #0a0a0a;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  place-items: start center;
  background: var(--blue);
  color: #fff;
}

html,
body,
body * {
  font-family: 'AppFont' !important;
}

button,
input,
select,
textarea {
  font-family: 'AppFont' !important;
}

.screen {
  width: min(420px, 100%);
  min-height: 100vh;
  background: var(--blue);
  background-image: url("../wallpaper.png");
  background-size: cover;
  background-position: center;
  padding: 28px 20px 40px;
  position: relative;
  overflow: hidden;
}

.screen::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 102, 230, 0.96), rgba(12, 110, 246, 0.84) 40%, rgba(12, 110, 246, 0.35));
  z-index: 0;
}

.screen > * {
  position: relative;
  z-index: 2;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-icon {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.brand-text {
  font-size: 24px;
  letter-spacing: 0.8px;
}

.actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
}

.nav a {
  text-decoration: none;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.7);
  border-radius: 14px;
  padding: 6px 14px;
  font-size: 13px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.08);
}

.nav a.active {
  background: #fff;
  color: var(--blue);
  border-color: #fff;
}

.icon-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  padding: 0;
  background: rgba(255, 255, 255, 0.12);
  display: grid;
  place-items: center;
}

.icon-btn img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.stats {
  display: flex;
  justify-content: space-between;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.stat .label {
  font-size: 18px;
  opacity: 0.9;
}

.stat .value {
  font-size: 20px;
  font-weight: 600;
}

.score-card {
  background: var(--card);
  color: var(--ink);
  border-radius: 20px;
  padding: 26px 18px 16px;
  box-shadow: var(--shadow);
  text-align: center;
  margin-bottom: 20px;
}

.score {
  font-size: 64px;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.update {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 16px;
  letter-spacing: 0.4px;
}

.clock {
  width: 18px;
  height: 18px;
}

.list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.slot {
  background: var(--card);
  color: var(--ink);
  border-radius: 16px;
  display: grid;
  grid-template-columns: 1fr 96px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.time {
  padding: 20px 18px;
  font-size: 20px;
  font-weight: 600;
}

.slot-value {
  background: var(--blue);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 24px;
  font-weight: 600;
}

.dialog-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(7, 20, 52, 0.58);
  display: grid;
  place-items: center;
  padding: 14px;
  z-index: 9999;
}

.dialog-card {
  width: min(420px, 100%);
  background: #fff;
  color: #0a0a0a;
  border-radius: 16px;
  padding: 18px 16px;
  box-shadow: var(--shadow);
  text-align: left;
}

.dialog-title {
  margin: 0 0 8px;
  font-size: 22px;
}

.dialog-message {
  margin: 0 0 14px;
  font-size: 15px;
  line-height: 1.45;
}

.dialog-close {
  border: none;
  border-radius: 10px;
  height: 38px;
  padding: 0 14px;
  color: #fff;
  background: var(--blue);
  cursor: pointer;
}

.confetti-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9998;
}

.ui-fade-5s {
  animation: uiFade5s 5s linear;
}

.ui-fade-1_5s {
  animation: uiFade1_5s 1.5s linear;
}

@keyframes uiFade5s {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

@keyframes uiFade1_5s {
  0% {
    opacity: 0.2;
  }
  100% {
    opacity: 1;
  }
}

@media (max-width: 480px) {
  .screen {
    padding: 22px 16px 32px;
  }

  .score {
    font-size: 56px;
  }

  .time {
    font-size: 18px;
  }
}

