:root {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  color: #f7f7f4;
  background: #08090a;
  font-synthesis: none;
  --orange: #ff6900;
  --muted: #9b9da2;
  --line: rgba(255, 255, 255, 0.11);
  --safe-top: max(24px, env(safe-area-inset-top));
  --safe-bottom: max(20px, env(safe-area-inset-bottom));
}
[hidden] {
  display: none !important;
}
* {
  box-sizing: border-box;
}
html {
  background: #08090a;
}
body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background: radial-gradient(
    circle at 72% 5%,
    #1d2023 0,
    #0b0c0e 35%,
    #050607 78%
  );
  color: #f7f7f4;
}
.app-shell {
  width: min(100%, 760px);
  min-height: 100vh;
  margin: auto;
}
.hero {
  padding: var(--safe-top) clamp(20px, 5vw, 42px) 34px;
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 52px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}
.brand-mark {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border: 1px solid #303237;
  border-radius: 17px;
  background: #030405;
  font-size: 24px;
  font-weight: 850;
  letter-spacing: -2px;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.05);
}
.brand-copy b {
  display: block;
  font-size: 16px;
  letter-spacing: 0.27em;
}
.brand-copy small {
  display: block;
  margin-top: 6px;
  color: #a3a5aa;
  font-size: 10px;
  letter-spacing: 0.31em;
}
.profile {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
}
.profile svg {
  width: 25px;
  fill: none;
  stroke: #f5f5f3;
  stroke-width: 1.8;
  stroke-linecap: round;
}
.status-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.045);
}
.status-card strong,
.status-card small {
  display: block;
}
.status-card small {
  margin-top: 4px;
  color: var(--muted);
}
.spinner {
  width: 25px;
  height: 25px;
  border: 2px solid #42454a;
  border-top-color: var(--orange);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.message-state {
  max-width: 570px;
  padding: 12px 0 42px;
}
.state-symbol {
  width: 62px;
  height: 62px;
  display: grid;
  place-items: center;
  margin-bottom: 28px;
  border: 1px solid #33363a;
  border-radius: 20px;
  background: #030405;
  font-size: 22px;
  font-weight: 850;
}
.message-state h1 {
  max-width: 520px;
  margin: 13px 0 16px;
  font-size: clamp(42px, 12vw, 72px);
  line-height: 0.95;
  letter-spacing: -0.04em;
}
.message-state p:not(.eyebrow) {
  max-width: 510px;
  margin: 0;
  color: #a1a3a8;
  font-size: 16px;
  line-height: 1.55;
}
.primary-button {
  min-height: 56px;
  margin-top: 28px;
  padding: 0 22px;
  border: 0;
  border-radius: 17px;
  background: #f6f6f3;
  color: #08090a;
  font: inherit;
  font-weight: 760;
  cursor: pointer;
}
.primary-button:active {
  transform: scale(0.97);
}
.primary-button:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
}
::selection {
  background: var(--orange);
  color: #111;
}
.welcome {
  margin: 0 0 3px;
  color: #b8b9bd;
  font-size: 15px;
}
.phone {
  margin: 0 0 37px;
  color: #74767b;
  font-size: 13px;
}
.balance-label {
  margin: 0 0 10px;
  color: #a1a2a7;
  font-size: 17px;
}
.balance {
  display: flex;
  align-items: center;
  gap: clamp(10px, 2.4vw, 16px);
  font-size: clamp(66px, 19vw, 105px);
  font-weight: 770;
  line-height: 0.94;
  letter-spacing: -0.04em;
}
.bonus-mark {
  width: clamp(48px, 11vw, 68px);
  height: clamp(48px, 11vw, 68px);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 4px solid var(--orange);
  border-radius: 50%;
  color: var(--orange);
  font-size: clamp(27px, 6.5vw, 40px);
  font-weight: 780;
  line-height: 1;
  letter-spacing: 0;
}
.balance-details {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 17px;
  color: #9c9ea3;
  font-size: 14px;
}
.balance-details span + span {
  position: relative;
}
.balance-details span + span:before {
  content: "";
  position: absolute;
  left: -10px;
  top: 50%;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #555;
}
.howto {
  margin-top: 30px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(
    110deg,
    rgba(255, 255, 255, 0.085),
    rgba(255, 255, 255, 0.025)
  );
  overflow: hidden;
}
.howto summary {
  min-height: 108px;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 16px;
  align-items: center;
  gap: 16px;
  padding: 17px 20px;
  cursor: pointer;
  list-style: none;
}
.howto summary::-webkit-details-marker,
.rules summary::-webkit-details-marker {
  display: none;
}
.howto summary small {
  display: block;
  margin-top: 6px;
  color: #a2a4a9;
  font-size: 14px;
  line-height: 1.4;
}
.howto summary > i {
  font-size: 35px;
  color: #aaa;
  font-style: normal;
}
.info-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  font-weight: 800;
}
.howto p {
  margin: 0;
  padding: 0 20px 20px 92px;
  color: #aaa;
  line-height: 1.5;
}
.history-sheet {
  position: relative;
  min-height: 44vh;
  padding: 35px clamp(20px, 5vw, 40px) var(--safe-bottom);
  background: #f4f4f1;
  color: #111;
  border-radius: 34px 34px 0 0;
  box-shadow: 0 -18px 64px rgba(0, 0, 0, 0.24);
}
.sheet-handle {
  position: absolute;
  top: 14px;
  left: 50%;
  width: 66px;
  height: 5px;
  transform: translateX(-50%);
  border-radius: 9px;
  background: #d1d1d0;
}
.sheet-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 15px;
  margin: 8px 0 7px;
}
.sheet-title h2 {
  margin: 0;
  font-size: clamp(29px, 8vw, 39px);
  letter-spacing: -0.045em;
}
.sheet-title > span {
  min-width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: #e7e7e4;
  color: #686a6f;
  font-size: 13px;
}
.operation {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr) auto;
  align-items: center;
  gap: 15px;
  min-height: 86px;
  border-bottom: 1px solid #dcdcd9;
}
.operation-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #101112;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}
.operation:nth-child(3n + 2) .operation-icon {
  background: var(--orange);
}
.operation:nth-child(3n) .operation-icon {
  background: #919397;
}
.operation-name {
  font-size: 16px;
  font-weight: 700;
}
.operation-meta {
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  text-align: right;
}
.operation-points {
  font-size: 18px;
  font-weight: 760;
}
.operation-points.positive {
  color: #0a9e55;
}
.operation-date {
  margin-top: 5px;
  color: #73757a;
  font-size: 12px;
}
.empty {
  text-align: center;
  padding: 54px 20px;
}
.empty > span {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  margin: auto;
  border-radius: 50%;
  background: #111;
  color: #fff;
  font-weight: 800;
}
.empty h3 {
  margin: 17px 0 6px;
}
.empty p {
  margin: 0;
  color: #616369;
}
.rules {
  margin: 22px 0 0;
  border-top: 1px solid #d9d9d6;
}
.rules summary {
  display: flex;
  justify-content: space-between;
  padding: 21px 0;
  font-weight: 700;
  cursor: pointer;
}
.rules p {
  margin: 0 0 20px;
  color: #686a6f;
  line-height: 1.5;
}
.history-sheet footer {
  text-align: center;
  color: #686a6f;
  font-size: 11px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
@media (min-width: 720px) {
  body {
    padding: 28px;
  }
  .app-shell {
    min-height: calc(100vh - 56px);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 32px;
    box-shadow: 0 28px 100px rgba(0, 0, 0, 0.38);
  }
  .hero {
    padding-bottom: 48px;
  }
  .history-sheet {
    border-radius: 34px;
  }
  .topbar {
    margin-bottom: 64px;
  }
}
@media (max-width: 370px) {
  .brand-copy b {
    font-size: 14px;
  }
  .brand-mark {
    width: 50px;
    height: 50px;
  }
  .profile {
    width: 44px;
    height: 44px;
  }
  .hero {
    padding-left: 17px;
    padding-right: 17px;
  }
  .history-sheet {
    padding-left: 17px;
    padding-right: 17px;
  }
  .balance {
    font-size: 62px;
  }
  .operation {
    grid-template-columns: 44px minmax(0, 1fr) auto;
    gap: 11px;
  }
  .operation-icon {
    width: 42px;
    height: 42px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    scroll-behavior: auto !important;
  }
}
