*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  background: #ffffff;
  color: #111111;
  font-family: 'Manrope', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  letter-spacing: -0.01em;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

#page {
  width: 100%;
  max-width: 760px;
  min-height: 100dvh;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  background: #ffffff;
}

#topbar,
#main {
  width: 100%;
}

#topbar {
  background: #ffffff;
  border-bottom: 1px solid #ececec;
}

.topbar-inner {
  min-height: 50px;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.open-logo {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
  text-align: center;
}

.open-logo-top {
  margin: 0 0 4px;
  padding: 0;
  color: #9b9b9b;
  font-size: 10px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.45em;
  text-indent: 0.45em;
  white-space: nowrap;
}

.open-logo-main {
  display: inline-block;
  padding: 5px 7px 4px;
  background: #e6e6e6;
  color: #ffffff;
  font-size: 20px;
  font-weight: 900;
  line-height: 0.86;
  letter-spacing: 0.05em;
  text-align: center;
  white-space: nowrap;
}

#main {
  flex: 1;
  padding: 0 16px;
  background: #ffffff;
}

.cabinet {
  min-height: calc(100dvh - 51px);
  display: flex;
  flex-direction: column;
}

.cabinet-main {
  flex: 1;
  min-height: 430px;
  padding: 19px 0 36px;
}

.cabinet-label {
  margin: 0 0 24px;
  text-align: center;
  font-size: 12px;
  line-height: 1.35;
  font-weight: 800;
}

.products {
  width: 100%;
  max-width: 620px;
  margin: 0 auto;
  display: grid;
  gap: 14px;
}


.empty-cabinet {
  width: 100%;
  max-width: 620px;
  margin: 0 auto;
  padding: 42px 18px;
  border: 1px solid #e2e2e2;
  border-radius: 8px;
  text-align: center;
}

.empty-cabinet p {
  margin: 0;
  color: #666666;
  font-size: 13px;
  line-height: 1.5;
}

.product-card {
  padding: 18px;
  border: 1px solid #e2e2e2;
  border-radius: 8px;
  background: #ffffff;
}

.product-card h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.2;
}

.product-description {
  margin: 6px 0 0;
  color: #666666;
  font-size: 13px;
  line-height: 1.45;
}

.product-summary {
  margin: 10px 0 0;
  color: #555555;
  font-size: 12px;
  line-height: 1.55;
}

.steps {
  margin-top: 13px;
  display: grid;
  gap: 8px;
}

.step {
  padding: 10px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid #f0f0f0;
}

.step-title {
  min-width: 0;
}

.step-number {
  color: #777777;
  font-size: 10px;
  font-weight: 700;
}

.step h3 {
  margin: 3px 0 0;
  font-size: 14px;
  line-height: 1.3;
}

.step p {
  margin: 4px 0 0;
  color: #777777;
  font-size: 12px;
  line-height: 1.4;
}

.step-link {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}

.step-open {
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 700;
  text-decoration: underline;
}

.cabinet-menu {
  padding: 16px 8px;
  border-top: 1px solid #d9d9d9;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 5px;
  text-align: center;
  font-size: 11px;
  line-height: 1.6;
  font-weight: 700;
}

.cabinet-menu a,
.cabinet-menu button {
  text-decoration: underline;
}

.cabinet-menu button {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.technical-block {
  padding: 14px 8px 28px;
  border-top: 1px solid #d9d9d9;
  text-align: center;
}

.technical-title {
  margin-bottom: 8px;
  font-size: 12px;
  line-height: 1.4;
  font-weight: 800;
}

.technical-data {
  max-width: 660px;
  margin: 0 auto;
  font-size: 11px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.tech-group + .tech-group {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #eeeeee;
}

.tech-group-title {
  margin-bottom: 4px;
  font-weight: 800;
  text-transform: uppercase;
}

.tech-row {
  display: grid;
  grid-template-columns: minmax(120px, 0.8fr) minmax(0, 1.8fr);
  gap: 8px;
  text-align: left;
}

.tech-key {
  color: #777777;
}

.tech-value {
  color: #111111;
}

.page-state {
  padding: 24px 0;
  text-align: center;
  font-size: 13px;
}

.error {
  color: #a52828;
}

.me-login {
  min-height: calc(100dvh - 51px);
  padding: 48px 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.me-login-card {
  width: min(100%, 520px);
  padding: 0;
  border: 0;
  background: transparent;
}

.hidden {
  display: none !important;
}

@media (max-width: 600px) {
  #main {
    padding: 0 10px;
  }

  .topbar-inner {
    padding: 0 10px;
  }

  .open-logo-main {
    font-size: 18px;
  }

  .cabinet-main {
    min-height: 360px;
  }

  .products {
    max-width: 100%;
  }

  .product-card {
    padding: 14px 10px;
  }

  .step {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .tech-row {
    display: block;
    text-align: center;
  }

  .tech-key,
  .tech-value {
    display: block;
  }

  .tech-value {
    margin-top: 1px;
  }

  .me-login {
    min-height: calc(100dvh - 51px);
    padding: 28px 0;
  }

  .me-login-card {
    width: 100%;
    padding: 0;
  }
}

/* CABINET shell navigation */
.topbar-inner {
  position: relative;
}

.cabinet-menu-button {
  position: absolute;
  left: 10px;
  top: 50%;
  width: 34px;
  height: 34px;
  padding: 0;
  transform: translateY(-50%);
  border: 1px solid #dddddd;
  border-radius: 7px;
  background: #ffffff;
  color: #111111;
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
}

.cabinet-drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(0, 0, 0, .16);
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease;
}

.cabinet-drawer-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.cabinet-drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
  width: min(320px, 86vw);
  padding: 64px 20px 24px;
  background: #ffffff;
  border-right: 1px solid #e2e2e2;
  transform: translateX(-102%);
  transition: transform .18s ease;
}

.cabinet-drawer.is-open {
  transform: translateX(0);
}

.cabinet-drawer-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #dddddd;
  border-radius: 7px;
  background: #ffffff;
  color: #111111;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.cabinet-drawer-menu {
  display: grid;
  gap: 2px;
}

.cabinet-drawer-link {
  width: 100%;
  min-height: 42px;
  padding: 11px 8px;
  border: 0;
  background: transparent;
  color: #111111;
  text-align: left;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.cabinet-drawer-link[aria-current="page"] {
  color: #777777;
  cursor: default;
}

.cabinet-menu-separator {
  user-select: none;
}
