@import url("https://fonts.googleapis.com/css2?family=Jost:wght@400;500;600&display=swap");

:root {
  --bg: #d1d1d1;
  --scene-top: #d7d7d7;
  --scene-bottom: #bbbbbb;
  --panel: #efefef;
  --panel-dark: #a0a0a0;
  --panel-light: #f3f3f3;
  --stroke: #111111;
  --font: "Futura PT", "Jost", "Century Gothic", "Tw Cen MT", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg);
  font-family: var(--font);
}

.scene-viewport {
  position: relative;
  width: 100vw;
  height: 100dvh;
  height: var(--app-height, 100dvh);
  overflow: hidden;
  background: var(--bg);
}

.scene {
  position: absolute;
  left: 0;
  top: 0;
  width: 1920px;
  height: 940px;
  overflow: visible;
  transform-origin: top left;
  background: transparent;
}

.panel,
.bg-shape {
  position: absolute;
  overflow: hidden;
}

.panel {
  background: var(--panel);
  border: 6px solid rgba(17, 17, 17, 0.9);
}

.bg-shape {
  background: var(--panel-dark);
  border: 3px solid rgba(17, 17, 17, 0.9);
  pointer-events: none;
}

.desktop-only {
  display: block;
}

.mobile-only {
  display: none;
}

.logo-panel {
  width: 1360px;
  height: 560px;
  left: -398px;
  top: -274px;
  transform: rotate(-45deg);
  background: #f1f1f1;
}

.logo-text {
  position: absolute;
  left: 208px;
  bottom: 22px;
  margin: 0;
  font-size: 180px;
  font-weight: 600;
  line-height: 0.85;
  letter-spacing: -0.08em;
  color: #000;
}

.bg-left-band {
  width: 1180px;
  height: 740px;
  left: -100px;
  top: -800px;
  background: #9c9c9c;
  transform: rotate(-45deg);
}

.bg-right-band {
  width: 1120px;
  height: 220px;
  left: 420px;
  top: 830px;
  background: #9f9f9f;
  transform: rotate(-45deg);
}

.bg-right-light {
  width: 1420px;
  height: 720px;
  left: 1200px;
  top: 520px;
  background: #c7c7c7;
  transform: rotate(-45deg);
}

.bg-bottom-light {
  width: 1820px;
  height: 520px;
  left: -810px;
  bottom: -180px;
  background: #9f9f9f;
  transform: rotate(-45deg);
}

.register-panel {
  width: 1480px;
  height: 610px;
  left: -90px;
  top: 488px;
  transform: rotate(-45deg);
  background: #ececec;
}

.desktop-marquee {
  position: absolute;
  left: -360px;
  top: 5px;
  width: 1650px;
  display: flex;
  gap: 2rem;
  white-space: nowrap;
  color: #111;
  font-size: 84px;
  font-weight: 400;
  letter-spacing: 0.02em;
  user-select: none;
  animation: moveRight 16s linear infinite;
}

.desktop-marquee span {
  flex: 0 0 auto;
}

.register-form-wrap {
  position: absolute;
  right: 36px;
  bottom: 58px;
  width: 620px;
  transform: rotate(45deg);
  transform-origin: right bottom;
}

.register-form {
  width: 100%;
  text-align: right;
  color: var(--stroke);
}

.reg-field {
  display: block;
  position: relative;
  margin-bottom: 34px;
}

.reg-field span {
  position: absolute;
  right: 0;
  top: -0.22em;
  font-size: 28px;
  letter-spacing: 0.01em;
}

.reg-field input {
  width: 410px;
  border: none;
  border-bottom: 3px solid #111;
  background: transparent;
  outline: none;
  font-size: 24px;
  padding: 0 2px 7px;
  color: #111;
}

.reg-field-name {
  margin-right: 20px;
}

.reg-field-email {
  margin-right: 98px;
}

.reg-field-password {
  margin-right: 188px;
  margin-bottom: 56px;
}

.request-btn {
  position: relative;
  display: block;
  width: 420px;
  height: 72px;
  margin-left: -56px;
  margin-bottom: -356px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
}

.request-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  border: 2px solid rgba(17, 17, 17, 0.9);
  background: #d0d0d0;
  transform: skewX(-45deg);
  transform-origin: center;
}

.request-btn span {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  text-transform: uppercase;
  color: #111;
  z-index: 1;
}

.info-panel {
  width: 760px;
  height: 734px;
  right: -44px;
  top: -280px;
  transform: rotate(-45deg);
  background: #f5f5f5;
}

.info-text {
  color: #111;
  font-size: 48px;
  line-height: 1.1;
}

.info-text-desktop {
  position: absolute;
  left: 26px;
  top: 22px;
  width: 690px;
}

.info-text p {
  margin: 0 0 8px;
}

.mobile-logo-panel,
.mobile-info-panel,
.mobile-register-ribbon,
.mobile-bottom-logo {
  display: none;
}

.mobile-logo-text {
  margin: 0;
  font-size: 124px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.06em;
  color: #000;
}

@keyframes moveRight {
  from {
    transform: translateX(-44%);
  }
  to {
    transform: translateX(0%);
  }
}

@media (max-width: 768px) {
  .scene {
    width: 500px;
    height: 980px;
  }

  .bg-shape,
  .desktop-only,
  a.panel.desktop-only,
  a.panel.info-panel,
  a.panel.bg-shape {
    display: none;
  }

  .mobile-only {
    display: block;
  }

  .mobile-info-panel {
    display: block;
    width: 920px;
    height: 452px;
    left: -455px;
    top: -78px;
    transform: rotate(-45deg);
    background: #f5f5f5;
  }

  .info-text-mobile {
    position: absolute;
    left: 18px;
    bottom: 16px;
    font-size: 28px;
  }

  .mobile-register-ribbon {
    display: block;
    width: 630px;
    height: 600px;
    right: -500px;
    top: -50px;
    transform: rotate(45deg);
    background: #f4f4f4;
  }

  .mobile-ribbon-text {
    position: absolute;
    left: 10px;
    bottom: 8px;
    display: flex;
    flex-direction: column;
    gap: 0;
    font-size: 54px;
    font-weight: 400;
    line-height: 0.92;
    color: #111;
  }

  .register-panel {
    width: 770px;
    height: 770px;
    left: -140px;
    top: 410px;
    transform: rotate(-45deg);
    background: #ededed;
  }

  .desktop-marquee {
    display: none;
  }

  .register-form-wrap {
    right: 240px;
    bottom: 254px;
    left: auto;
    top: auto;
    width: 350px;
    transform: rotate(45deg);
    transform-origin: right bottom;
  }

  .register-form {
    text-align: right;
  }

  .reg-field {
    margin-bottom: 40px;
  }

  .reg-field span {
    font-size: 20px;
  }

  .reg-field input {
    width: 310px;
    font-size: 20px;
    border-bottom-width: 2px;
  }

  .reg-field-name,
  .reg-field-email,
  .reg-field-password {
    margin-right: 30px;
  }

  .reg-field-password {
    margin-bottom: 36px;
  }

  .request-btn {
    width: 320px;
    height: 74px;
    margin: 0 auto 0 0;
  }

  .request-btn::before {
    transform: none;
    background: #d3d3d3;
    border: 2px solid rgba(17, 17, 17, 0.9);
  }

  .request-btn span {
    font-size: 22px;
  }

  .mobile-bottom-logo {
    display: block;
    position: absolute;
    left: 120px;
    bottom: 46px;
  }

  .mobile-logo-text {
    font-size: 128px;
  }
}

/* ===== OST app integration ===== */
a.panel,
a.logo-link,
a.register-link,
a.mobile-bottom-logo {
  display: block;
  color: inherit;
  text-decoration: none;
}

button,
input {
  font-family: var(--font);
}

.logo-link,
.register-link,
.route-copy,
.email-ribbon,
.pay-button,
.gb-button,
.request-btn,
.enter-btn,
.forgot,
.mini-btn,
.payment-overlay-confirm,
.account-overlay-confirm,
.account-telegram-link-btn {
  cursor: pointer;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-text-fill-color: #111;
  transition: background-color 9999s ease-in-out 0s;
}

.app-dialog-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.34);
}

.app-dialog-backdrop.open {
  display: flex;
}

.app-dialog {
  width: min(420px, 100%);
  padding: 26px 28px 24px;
  background: #efefef;
  border: 3px solid #111;
  box-shadow: 14px 14px 0 rgba(17, 17, 17, 0.28);
  color: #111;
  text-align: center;
}

.app-dialog h2 {
  margin: 0 0 12px;
  font-size: 34px;
  font-weight: 500;
  line-height: 1;
  text-transform: uppercase;
}

.app-dialog p {
  margin: 0 0 22px;
  font-size: 20px;
  line-height: 1.25;
}

.app-dialog button {
  min-width: 112px;
  min-height: 42px;
  border: 2px solid #111;
  background: #d0d0d0;
  color: #111;
  font-size: 22px;
  cursor: pointer;
}

.app-dialog-backdrop.is-error .app-dialog button {
  background: #f1f1f1;
}

.reset-panel .reset-form-wrap {
  bottom: 8%;
}

.reset-panel .reset-field-password {
  margin-right: -210px;
  margin-bottom: 58px;
}

@media (max-width: 768px) {
  .app-dialog {
    width: min(360px, 100%);
    padding: 22px;
  }

  .app-dialog h2 {
    font-size: 30px;
  }

  .app-dialog p {
    font-size: 18px;
  }
}
