:root {
  --gold: #e2ae38;
  --ink: #050505;
  --line: rgba(0, 180, 238, 0.34);
  --panel: rgba(245, 248, 252, 0.94);
  --muted: #dce6ee;
  --blue: #00a9e2;
  --red: #dc143c;
  --green: #d9a63a;
  --shadow: 0 18px 44px rgba(0, 0, 0, 0.36);
  --night-1: #04090e;
  --night-2: #081a29;
  --night-3: #18232d;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 92% 88%, rgba(226, 174, 56, 0.35), transparent 34%),
    radial-gradient(circle at 8% 6%, rgba(0, 180, 238, 0.28), transparent 30%),
    linear-gradient(135deg, var(--night-1), var(--night-2) 56%, var(--night-3));
  background-attachment: fixed;
  background-repeat: no-repeat;
  background-size: cover;
}

body {
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  overflow-y: auto;
  background: transparent;
  color: var(--ink);
  font-family: "Segoe UI", Arial, sans-serif;
  letter-spacing: 0;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

.app-shell {
  min-height: 100vh;
  min-height: 100dvh;
  padding: 14px;
  display: grid;
  place-items: center;
}

html.native-shell,
html.native-shell body {
  min-height: 100%;
}

html.native-shell .app-shell {
  min-height: 100vh;
  min-height: 100dvh;
  place-items: center;
  align-items: center;
}

.home-screen {
  width: min(100%, 720px);
  display: grid;
  gap: 14px;
  align-content: start;
  align-items: start;
  justify-items: center;
  padding-top: clamp(12px, 5dvh, 54px);
}

.brand-icon {
  width: 122px;
  height: 122px;
  object-fit: contain;
  justify-self: center;
  border: 0;
  border-radius: 28px;
  background: transparent;
  box-shadow: var(--shadow);
  display: block;
}

.module-grid {
  display: grid;
  gap: 12px;
}

.module-card {
  position: relative;
  min-width: 0;
  min-height: 132px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  color: var(--ink);
  display: grid;
  grid-template-rows: 18px minmax(42px, auto) minmax(0, auto) 38px;
  align-content: center;
  gap: 8px;
  text-align: left;
  box-shadow: var(--shadow);
}

.module-card:disabled {
  cursor: progress;
  opacity: 0.82;
}

.module-action {
  justify-self: start;
  width: 168px;
  max-width: 100%;
  min-height: 38px;
  padding: 6px 10px;
  border-radius: 7px;
  background: rgba(0, 169, 226, 0.14);
  border: 1px solid var(--line);
  color: var(--ink);
  display: grid;
  place-items: center;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.08;
  text-align: center;
}

.module-status {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.module-expiry {
  font-size: 12px;
  color: rgba(0, 0, 0, 0.68);
  font-weight: 800;
}

.module-card.is-open .module-status {
  color: var(--green);
}

.module-card.is-locked .module-status {
  color: #7a0000;
}

.module-card.is-requested .module-status {
  color: var(--gold);
}

.module-card.is-requested .module-action {
  background: rgba(226, 174, 56, 0.16);
  border-color: rgba(226, 174, 56, 0.58);
}

.module-card.is-denied .module-status {
  color: var(--red);
}

.module-card.is-denied .module-action {
  background: rgba(194, 0, 44, 0.08);
  border-color: rgba(194, 0, 44, 0.34);
}

.support-row {
  display: grid;
  justify-items: center;
}

.support-popover-anchor {
  position: relative;
  display: grid;
  justify-items: center;
}

.notice-list,
.support-status-list {
  display: grid;
  gap: 8px;
}

.support-status-list {
  border: 1px solid rgba(0, 180, 238, 0.28);
  background: rgba(255, 255, 255, 0.66);
  padding: 10px;
  font-size: 13px;
}

.notice-list {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.notice-card {
  display: flex;
  gap: 8px;
  align-items: center;
  min-height: 36px;
  padding: 8px 10px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  line-height: 1.25;
}

.notice-card.is-warning {
  border-color: rgba(226, 174, 56, 0.58);
  background: rgba(226, 174, 56, 0.14);
}

.notice-card strong,
.support-status-list strong {
  font-size: 12px;
  text-transform: uppercase;
  white-space: nowrap;
}

.notice-card span {
  overflow-wrap: anywhere;
}

.support-status-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid rgba(0, 0, 0, 0.12);
  padding-top: 7px;
  font-size: 12px;
}

.customer-portal {
  position: absolute;
  top: 54px;
  right: 12px;
  z-index: 5;
  width: min(540px, calc(100% - 24px));
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 8px;
  background: #f5f8fc;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.24);
}

.home-panel > .account-info-button {
  position: static;
  justify-self: end;
  z-index: 4;
  margin: -2px 0 2px;
}

.home-panel > .notice-list {
  padding-right: 0;
}

.home-panel > .notice-list .notice-card {
  min-width: 0;
}

.customer-portal.is-collapsed {
  width: auto;
  padding: 0;
  border: 0;
  background: transparent;
}

.account-info-button {
  justify-self: end;
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 38px;
  border: 1px solid rgba(0, 180, 238, 0.68);
  border-radius: 9px;
  background: linear-gradient(135deg, #f8fbfe, #cfefff);
  color: #06121d;
  padding: 0;
  font: inherit;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
}

.account-info-icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.account-info-button:hover,
.account-info-button:focus-visible {
  background: #ffffff;
  outline: 2px solid rgba(0, 180, 238, 0.42);
  outline-offset: 2px;
}

.customer-portal-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  font-size: 12px;
}

.customer-portal-head strong {
  text-transform: uppercase;
}

.customer-portal-head span {
  overflow-wrap: anywhere;
  text-align: right;
}

.customer-portal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.customer-portal-grid div {
  display: grid;
  gap: 3px;
  min-height: 52px;
  padding: 7px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 0.72);
}

.customer-portal-grid span {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.customer-portal-grid strong {
  font-size: 12px;
  overflow-wrap: anywhere;
}

.danger-link {
  justify-self: center;
  min-width: 230px;
  max-width: 100%;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(0, 169, 226, 0.13);
  color: var(--ink);
  display: inline-grid;
  place-items: center;
  font-weight: 800;
}

.topbar-icon {
  display: block;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  max-width: 32px;
  max-height: 32px;
  border-radius: 9px;
  object-fit: contain;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.24));
}

.paypal-panel {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
}

.paypal-panel > strong {
  text-align: center;
  text-transform: uppercase;
  font-size: 12px;
}

.paypal-panel form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(120px, 170px) minmax(150px, 210px);
  gap: 8px;
}

.paypal-panel select,
.paypal-panel input {
  min-height: 48px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0 8px;
  font: inherit;
}

.module-title {
  font-size: clamp(30px, 7vw, 46px);
  font-weight: 700;
  line-height: 1;
}

.copyright {
  margin: 0;
  color: rgba(0, 0, 0, 0.62);
  font-size: 12px;
  line-height: 1.25;
  text-align: center;
}

.footer-links {
  margin: 0;
  display: flex;
  justify-content: center;
  gap: 12px;
  font-size: 12px;
}

.footer-links a {
  color: #005b86;
  font-weight: 800;
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}

.account-panel > .copyright {
  grid-column: 1 / -1;
}

html.ios-shell {
  -webkit-text-size-adjust: 100%;
}

html.ios-shell,
html.ios-shell body {
  touch-action: manipulation;
}

html.ios-shell input,
html.ios-shell textarea,
html.ios-shell select {
  font-size: 16px;
}

html.ios-shell .footer-links {
  display: none;
}

html.ios-shell .copyright {
  color: rgba(0, 0, 0, 0.58);
  font-size: 11px;
  line-height: 1.25;
}

.support-link {
  min-width: 160px;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(0, 169, 226, 0.13);
  color: var(--ink);
  display: inline-grid;
  place-items: center;
  font-weight: 800;
  text-decoration: none;
  justify-self: center;
}

.support-link:hover {
  background: rgba(0, 169, 226, 0.22);
}

.support-case-panel {
  position: absolute;
  bottom: calc(100% + 12px);
  left: 50%;
  z-index: 6;
  width: min(640px, calc(100vw - 32px));
  max-height: min(64dvh, 560px);
  overflow: auto;
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 8px;
  background: #f5f8fc;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.24);
}

.support-case-panel .field-block:nth-child(3),
.support-case-panel .field-block:nth-child(5),
.support-case-panel .field-block:nth-child(6),
.support-case-panel .action,
.support-case-panel .message {
  grid-column: 1 / -1;
}

.support-case-panel .action {
  width: min(100%, 360px);
  justify-self: center;
}

.support-textarea {
  width: 100%;
  min-height: 96px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  padding: 8px;
  resize: vertical;
}

.crane-request-panel {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  background: rgba(255, 255, 255, 0.64);
}

.crane-request-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.tool-screen {
  width: min(100%, 920px);
  display: grid;
  gap: 10px;
}

.centered-screen {
  width: min(100%, 390px);
}

.topbar {
  min-height: 44px;
  display: grid;
  grid-template-columns: minmax(76px, 96px) minmax(0, 1fr) minmax(76px, 96px);
  align-items: center;
  gap: 8px;
}

.topbar-title {
  grid-column: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
  line-height: 1;
}

.topbar-title strong,
.topbar > strong {
  color: #f5f8fc;
  text-shadow: 0 2px 14px rgba(0, 180, 238, 0.42);
  text-align: center;
  font-size: 22px;
}

.topbar-spacer {
  grid-column: 3;
}

.nav-button {
  min-height: 38px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(245, 248, 252, 0.92);
  color: var(--ink);
  font-weight: 700;
  white-space: nowrap;
}

.nav-button:last-child {
  grid-column: 3;
}

.activation-panel,
.home-panel,
.day-tool,
.lec-tool {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  box-shadow: var(--shadow);
}

.activation-panel {
  display: grid;
  gap: 12px;
}

.home-panel {
  position: relative;
  display: grid;
  gap: 12px;
  width: 100%;
  padding-bottom: 14px;
}

.activation-box {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  background: rgba(255, 255, 255, 0.5);
}

.home-panel .activation-box {
  padding: 0;
  border: 0;
  background: transparent;
}

.home-panel .module-grid {
  padding: 0;
  border: 0;
}

.activation-panel h1,
.home-panel h1 {
  margin: 0;
  font-size: 28px;
  text-align: center;
}

.field-block,
.number-block {
  display: grid;
  gap: 6px;
}

.field-block span,
.number-block span {
  font-size: 15px;
  font-weight: 700;
}

.text-output,
.text-input,
.big-input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #fff;
  color: var(--ink);
}

.text-output {
  min-height: 48px;
  padding: 12px 8px;
  text-align: center;
  user-select: all;
}

.text-input {
  height: 48px;
  padding: 0 8px;
}

.mono-input,
.text-output,
.big-input,
.value-content,
.code-column output,
.text-box pre {
  font-family: Consolas, "SFMono-Regular", monospace;
}

.action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.action {
  min-height: 48px;
  border: 1px solid rgba(0, 0, 0, 0.25);
  border-radius: 7px;
  font-weight: 800;
}

.action.dark {
  background: #0d1b28;
  color: #fff;
}

.action.blue {
  background: linear-gradient(135deg, #0077b8, var(--blue));
  color: #fff;
}

.action.gold {
  background: linear-gradient(135deg, #c9901d, var(--gold));
  color: #000;
}

.action.light {
  background: #eaf0f5;
}

.action.primary {
  color: var(--blue);
  font-size: 22px;
}

.action.danger {
  color: var(--red);
  font-size: 18px;
}

.message,
.status-line {
  min-height: 20px;
  margin: 0;
  text-align: center;
  color: #7a0000;
}

.message.ok {
  color: var(--ink);
}

.tool-meta {
  margin: -2px 0 0;
  text-align: center;
  color: rgba(0, 0, 0, 0.64);
  font-size: 12px;
  font-weight: 700;
}

.day-tool,
.lec-tool {
  display: grid;
  gap: 12px;
}

.input-stack {
  display: grid;
  gap: 12px;
  justify-items: center;
}

.crane-input-row {
  display: grid;
  grid-template-columns: 38px auto 38px;
  gap: 7px;
  align-items: end;
  justify-content: center;
}

.crane-input-row .number-block {
  grid-column: 2;
}

.number-block {
  justify-items: center;
}

.big-input {
  height: 54px;
  padding: 0 8px;
  font-size: 25px;
  text-align: center;
}

.number-block:first-child .big-input {
  width: 170px;
}

.favorite-icon-button,
.history-icon-button {
  grid-column: 3;
  width: 38px;
  height: 38px;
  margin-bottom: 8px;
  border: 1px solid rgba(0, 180, 238, 0.5);
  border-radius: 8px;
  background: #eaf0f5;
  color: var(--gold);
  display: grid;
  place-items: center;
  padding: 0;
  font-size: 24px;
  font-weight: 900;
  line-height: 1;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.history-icon-button {
  grid-column: 1;
  color: var(--blue);
  font-size: 20px;
}

.favorite-icon-button.is-saved {
  border-color: rgba(226, 174, 56, 0.78);
  background: linear-gradient(135deg, #fff8e6, #eaf0f5);
}

.favorite-icon-button:disabled {
  opacity: 0.45;
}

.date-input {
  width: 142px;
}

.code-input {
  width: 190px;
  text-transform: uppercase;
}

.code-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  align-items: start;
  justify-items: center;
}

.code-column {
  display: grid;
  justify-items: center;
  gap: 5px;
}

.code-column output {
  width: 92px;
  height: 42px;
  display: grid;
  place-items: center;
  font-size: 30px;
  font-weight: 700;
}

.code-column.green output {
  color: var(--green);
}

.code-column.blue output {
  color: var(--blue);
}

.code-column.red output {
  color: #ef1e1a;
}

.smilies {
  width: 92px;
  min-height: 26px;
  display: flex;
  justify-content: center;
  gap: 4px;
}

.smilies img {
  width: 26px;
  height: 26px;
}

.wide-actions {
  max-width: 360px;
  width: 100%;
  justify-self: center;
}

.crane-type {
  min-height: 26px;
  display: block;
  color: var(--green);
  font-family: Consolas, "SFMono-Regular", monospace;
  font-size: 17px;
  font-weight: 700;
  text-align: center;
}

.update-panel {
  display: grid;
  gap: 8px;
  width: 100%;
}

.lec-favorites {
  display: grid;
  gap: 6px;
  width: 100%;
  padding: 8px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.52);
}

.lec-favorites-title {
  font-size: 12px;
  font-weight: 900;
  text-align: center;
  text-transform: uppercase;
  color: rgba(0, 0, 0, 0.72);
}

.lec-favorite-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 6px;
}

.lec-favorite-chip {
  position: relative;
  min-height: 44px;
  border: 1px solid rgba(0, 180, 238, 0.46);
  border-radius: 7px;
  background: linear-gradient(135deg, #f8fbfe, #d8f1fb);
  color: var(--ink);
  display: grid;
  gap: 1px;
  place-items: center;
  padding: 5px;
  text-align: center;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
}

.lec-favorite-open {
  width: 100%;
  min-height: 34px;
  border: 0;
  background: transparent;
  color: inherit;
  display: grid;
  gap: 1px;
  place-items: center;
  padding: 0 18px 0 4px;
  text-align: center;
}

.lec-favorite-remove {
  position: absolute;
  top: -7px;
  right: -7px;
  width: 22px;
  height: 22px;
  border: 1px solid rgba(0, 0, 0, 0.24);
  border-radius: 999px;
  background: #eaf0f5;
  color: var(--red);
  display: grid;
  place-items: center;
  padding: 0;
  font-size: 16px;
  font-weight: 900;
  line-height: 1;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.16);
}

.lec-favorite-chip.is-active {
  border-color: rgba(226, 174, 56, 0.78);
  background: linear-gradient(135deg, #fff8e6, #d8f1fb);
}

.lec-favorite-chip strong {
  font-family: Consolas, "SFMono-Regular", monospace;
  font-size: 14px;
  line-height: 1;
}

.lec-favorite-chip span {
  max-width: 100%;
  overflow: hidden;
  color: rgba(0, 0, 0, 0.68);
  font-size: 10px;
  font-weight: 800;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-panel {
  width: min(100%, 280px);
  display: grid;
  gap: 6px;
  padding: 8px;
  border: 1px solid rgba(0, 180, 238, 0.35);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
}

.recent-panel button {
  min-height: 42px;
  border: 1px solid rgba(0, 180, 238, 0.35);
  border-radius: 7px;
  background: linear-gradient(135deg, #fff, #e7f6fc);
  color: var(--ink);
  display: grid;
  gap: 2px;
  padding: 6px;
  text-align: left;
}

.recent-panel strong {
  font-family: Consolas, "SFMono-Regular", monospace;
}

.recent-panel span {
  font-size: 11px;
  font-weight: 800;
  color: rgba(0, 0, 0, 0.62);
}

.docs-list {
  min-height: 120px;
  display: grid;
  gap: 8px;
  padding: 10px;
  background: #fff;
}

.docs-list p {
  margin: 0;
  font-family: Consolas, "SFMono-Regular", monospace;
}

.docs-link {
  border: 1px solid rgba(0, 0, 0, 0.18);
  border-radius: 7px;
  padding: 10px;
  background: linear-gradient(135deg, #ffffff, #e9f6fc);
  color: var(--ink);
  display: grid;
  gap: 3px;
  text-decoration: none;
}

.docs-link strong {
  overflow-wrap: anywhere;
}

.docs-link span {
  font-size: 11px;
  font-weight: 800;
  color: rgba(0, 0, 0, 0.62);
}

.update-panel label {
  display: grid;
  gap: 4px;
}

.update-panel span {
  font-size: 12px;
  font-weight: 800;
}

.update-input {
  width: 100%;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #fff;
  color: var(--ink);
  padding: 0 8px;
  font-size: 13px;
}

.lec-result {
  background: #fff;
  border: 1px solid var(--line);
  padding: 8px;
  overflow: hidden;
}

.value-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.value-box {
  display: grid;
  grid-template-rows: 34px 42px;
  min-width: 0;
}

.value-title,
.value-content {
  border: 1px solid rgba(0, 0, 0, 0.52);
  display: grid;
  place-items: center;
  text-align: center;
}

.value-title {
  background: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.value-content {
  background: #fff;
  font-size: 14px;
}

.text-box {
  margin-top: 8px;
}

.text-box .value-title {
  height: 32px;
  justify-content: start;
  padding: 0 8px;
}

.text-box pre {
  min-height: 104px;
  margin: 0;
  padding: 10px;
  border: 1px solid rgba(0, 0, 0, 0.52);
  border-top: 0;
  background: #fff;
  white-space: pre-wrap;
  font-size: 13px;
}

.lec-result .wide-actions {
  max-width: 100%;
  margin-top: 8px;
}

.hidden-file {
  display: none;
}

.home-auth-actions {
  order: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 170px));
  justify-content: center;
  gap: 10px;
}

.home-auth-panel {
  order: 2;
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.68);
}

.home-auth-panel > strong,
.portal-login-box > strong {
  font-size: 12px;
  text-transform: uppercase;
}

.home-auth-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) minmax(130px, 170px);
  gap: 8px;
  align-items: end;
}

.portal-login-box {
  order: 2;
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.58);
}

.portal-login-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) repeat(2, minmax(130px, 170px));
  gap: 8px;
}

.portal-login-box .login-message {
  margin: 0;
  text-align: left;
}

.activation-box > .module-grid {
  order: 3;
}

.activation-box > .support-popover-anchor {
  order: 4;
}

.activation-box > .message {
  order: 5;
}

.password-request-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(140px, 180px);
  gap: 8px;
  align-items: end;
  padding: 10px;
  border: 1px solid rgba(0, 180, 238, 0.32);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
}

.account-screen {
  width: min(100%, 980px);
}

.account-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.account-tabs {
  grid-column: 1 / -1;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 6px;
  border: 1px solid rgba(0, 180, 238, 0.26);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.52);
}

.account-tab {
  min-width: 132px;
  min-height: 42px;
  border: 1px solid rgba(0, 180, 238, 0.42);
  border-radius: 8px;
  background: linear-gradient(180deg, #f4fbff, #d9f4ff);
  color: var(--ink);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.account-tab.active {
  border-color: rgba(0, 153, 214, 0.75);
  background: linear-gradient(180deg, #09aee0, #087eb8);
  color: #fff;
  box-shadow: 0 10px 22px rgba(0, 140, 196, 0.24);
}

.account-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(0, 180, 238, 0.28);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.68);
}

.account-card h2 {
  margin: 0;
  font-size: 18px;
}

.account-grid,
.account-list {
  display: grid;
  gap: 8px;
}

.account-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.account-grid div,
.account-list div {
  display: grid;
  gap: 4px;
  padding: 9px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 0.72);
}

.account-grid span,
.account-list span {
  font-size: 12px;
  color: rgba(0, 0, 0, 0.68);
}

.account-grid strong,
.account-list strong {
  overflow-wrap: anywhere;
}

.account-actions {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.company-seat-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
}

.company-seat-form label {
  display: grid;
  gap: 4px;
  font-weight: 800;
}

.company-seat-form .text-input {
  min-width: 0;
}

.company-seat-form select {
  width: 100%;
  min-width: 0;
  height: 48px;
  border: 1px solid rgba(0, 180, 238, 0.42);
  border-radius: 6px;
  background-color: #fff;
  color: var(--ink);
  padding: 0 34px 0 8px;
  font: inherit;
  box-shadow: inset 0 1px 0 rgba(0, 0, 0, 0.04);
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #06121d 50%),
    linear-gradient(135deg, #06121d 50%, transparent 50%);
  background-position: calc(100% - 18px) 20px, calc(100% - 12px) 20px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.company-day-levels,
.company-app-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  min-width: 0;
  margin: 0;
  padding: 9px;
  border: 1px solid rgba(0, 180, 238, 0.42);
  border-radius: 6px;
  background: #fff;
}

.company-day-levels legend,
.company-app-options legend {
  padding: 0 4px;
  font-weight: 800;
  font-size: 12px;
}

.company-day-levels label,
.company-app-options label {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  white-space: nowrap;
}

.company-day-levels input,
.company-app-options input {
  width: auto;
  height: auto;
}

.company-seat-form .action {
  grid-column: 1 / -1;
}

.employee-license-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.employee-license-row .mini-action {
  min-width: 92px;
  min-height: 36px;
  height: 36px;
  padding: 0 10px;
  font-size: 13px;
}

.company-license-card {
  align-self: start;
}

.company-employee-list {
  max-height: 360px;
  overflow: auto;
  padding-right: 4px;
}

.account-contact-anchor {
  width: 100%;
  justify-self: stretch;
}

.account-contact-anchor > .action {
  width: 100%;
}

/* Premium visual layer */
html {
  background:
    radial-gradient(circle at 52% -8%, rgba(0, 180, 238, 0.26), transparent 30%),
    radial-gradient(circle at 92% 88%, rgba(226, 174, 56, 0.35), transparent 34%),
    radial-gradient(circle at 8% 6%, rgba(0, 180, 238, 0.28), transparent 30%),
    linear-gradient(135deg, #02070c, #071827 56%, #1d2427);
  background-attachment: fixed;
  background-repeat: no-repeat;
  background-size: cover;
}

body {
  background: transparent;
}

.app-shell {
  padding: clamp(10px, 3vw, 28px);
}

.home-screen {
  width: min(100%, 780px);
  gap: 16px;
}

.brand-icon {
  filter: drop-shadow(0 18px 34px rgba(0, 0, 0, 0.36));
  box-shadow: none;
}

.activation-panel,
.home-panel,
.day-tool,
.lec-tool {
  border: 1px solid rgba(124, 219, 255, 0.48);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(234, 241, 247, 0.96)),
    var(--panel);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.38),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.home-panel {
  padding: clamp(16px, 3vw, 28px);
  border-radius: 12px;
}

.module-grid {
  gap: 14px;
}

.module-card {
  overflow: hidden;
  border-radius: 12px;
  border-color: rgba(124, 219, 255, 0.55);
  background:
    radial-gradient(circle at 100% 0%, rgba(0, 169, 226, 0.13), transparent 42%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(242, 246, 250, 0.98));
  box-shadow:
    0 24px 44px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.86);
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.module-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--blue), var(--gold));
  opacity: 0.9;
}

.module-card:hover,
.module-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(0, 180, 238, 0.86);
  box-shadow:
    0 30px 58px rgba(0, 0, 0, 0.24),
    0 0 0 3px rgba(0, 180, 238, 0.12);
  outline: 0;
}

.module-status {
  letter-spacing: 0.02em;
}

.module-title {
  font-weight: 800;
}

.module-action,
.support-link,
.danger-link,
.nav-button,
.action {
  border-radius: 9px;
  border-color: rgba(0, 180, 238, 0.42);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.module-action,
.support-link,
.danger-link {
  background: linear-gradient(135deg, rgba(224, 245, 253, 0.95), rgba(194, 234, 248, 0.95));
}

.action.blue {
  background: linear-gradient(135deg, #0078b8, #04a9dc);
  border-color: rgba(0, 180, 238, 0.62);
  box-shadow: 0 12px 22px rgba(0, 128, 190, 0.24);
}

.action.light,
.nav-button {
  background: linear-gradient(135deg, #f8fbfe, #e7f1f8);
}

.notice-card,
.support-status-list,
.paypal-panel,
.crane-request-panel,
.support-case-panel,
.customer-portal {
  border-radius: 10px;
  border-color: rgba(124, 219, 255, 0.4);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.1);
}

.support-case-panel {
  background: #f5f8fc;
}

.account-info-button {
  background: linear-gradient(135deg, #f8fbfe, #cfefff);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.18);
}

.text-input,
.big-input,
.update-input,
.paypal-panel select,
.paypal-panel input,
.support-textarea {
  border-color: rgba(0, 180, 238, 0.42);
  border-radius: 6px;
  box-shadow: inset 0 1px 0 rgba(0, 0, 0, 0.04);
}

.lec-result {
  border-radius: 10px;
  border-color: rgba(124, 219, 255, 0.42);
  background: rgba(255, 255, 255, 0.82);
}

.value-title {
  background: linear-gradient(135deg, #e8f1f7, #d7e5ee);
}

.text-box pre,
.value-content {
  border-color: rgba(0, 0, 0, 0.34);
}

@media (max-width: 559px) {
  input,
  textarea,
  select {
    font-size: 16px;
  }

  .paypal-panel form {
    grid-template-columns: 1fr;
  }

  .customer-portal {
    top: 50px;
    right: 8px;
    width: calc(100% - 16px);
  }

  .customer-portal-grid,
  .support-case-panel,
  .home-auth-actions,
  .home-auth-grid,
  .portal-login-grid,
  .password-request-panel,
  .account-panel,
  .account-grid,
  .company-seat-form,
  .employee-license-row,
  .account-actions {
    grid-template-columns: 1fr;
  }

  .account-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-tab {
    min-width: 0;
  }

  .app-shell {
    min-height: 100dvh;
    height: auto;
    padding: 8px 6px;
    place-items: start center;
    align-items: start;
    overflow: visible;
  }

  html.native-shell .app-shell {
    place-items: stretch center;
    align-items: stretch;
    height: 100vh;
    height: 100dvh;
    min-height: 100vh;
    min-height: 100dvh;
    padding-top: calc(8px + env(safe-area-inset-top, 0px));
    padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
    overflow: hidden;
  }

  html.native-shell .home-screen {
    align-content: center;
    align-self: center;
    padding-top: 0;
  }

  html.android-shell .app-shell[data-route="home"] {
    display: flex;
    min-height: 100vh;
    min-height: 100dvh;
    height: 100vh;
    height: 100dvh;
    align-items: center;
    justify-content: center;
    overflow: auto;
  }

  html.android-shell .app-shell[data-route="home"] .home-screen {
    margin: auto 0;
    align-self: center;
    align-content: center;
    justify-content: center;
    padding-top: 0;
  }

  html.native-shell .account-screen {
    align-self: stretch;
    height: 100%;
    min-height: 0;
    max-height: 100%;
    grid-template-rows: auto minmax(0, 1fr) auto;
    align-content: stretch;
    overflow: hidden;
  }

  .home-screen {
    padding-top: clamp(8px, 4dvh, 34px);
    gap: 8px;
    max-height: none;
    overflow: visible;
  }

  .brand-icon {
    width: 76px;
    height: 76px;
    border-radius: 18px;
  }

  .home-panel {
    gap: 8px;
    padding: 10px;
    box-shadow: none;
  }

  .home-panel > .notice-list {
    padding-right: 0;
  }

  .home-panel > .notice-list .notice-card {
    align-items: flex-start;
  }

  .home-panel h1 {
    font-size: 24px;
  }

  .home-panel .text-output,
  .home-panel .text-input,
  .home-panel .action {
    min-height: 40px;
    height: 40px;
  }

  .home-panel .module-grid {
    gap: 6px;
  }

  .home-panel .module-card {
    min-height: 104px;
    padding: 10px;
    grid-template-rows: 14px 26px minmax(0, auto) 32px;
    gap: 3px;
    box-shadow: none;
  }

  .home-panel .module-title {
    font-size: 22px;
  }

  .home-panel .module-status {
    font-size: 11px;
  }

  .home-panel .module-action {
    width: 146px;
    min-height: 32px;
    padding: 4px 8px;
    font-size: 12px;
  }

  .tool-screen {
    width: 100%;
    max-height: none;
    gap: 6px;
    overflow: visible;
  }

  .account-screen,
  .day-layout,
  .lec-layout {
    max-height: none;
    align-content: start;
    overflow: visible;
  }

  html.native-shell .account-screen {
    align-content: stretch;
  }

  html.native-shell .account-screen .topbar {
    position: sticky;
    top: 0;
    z-index: 5;
  }

  html.native-shell .account-panel {
    min-height: 0;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }

  .topbar {
    min-height: 34px;
    grid-template-columns: minmax(66px, 74px) 1fr minmax(66px, 74px);
    gap: 6px;
  }

  .topbar strong {
    font-size: 20px;
  }

  .nav-button {
    min-height: 34px;
    padding: 0 6px;
    border-radius: 6px;
  }

  .lec-tool {
    gap: 6px;
    padding: 6px;
    box-shadow: none;
  }

  .lec-tool .input-stack {
    gap: 6px;
  }

  .crane-input-row {
    grid-template-columns: 34px auto 34px;
    gap: 6px;
  }

  .number-block,
  .field-block {
    gap: 4px;
  }

  .crane-request-grid {
    grid-template-columns: 1fr;
  }

  .number-block span,
  .field-block span {
    font-size: 14px;
  }

  .big-input {
    height: 42px;
    font-size: 22px;
  }

  .number-block:first-child .big-input {
    width: 170px;
  }

  .favorite-icon-button,
  .history-icon-button {
    width: 34px;
    height: 34px;
    margin-bottom: 4px;
    font-size: 21px;
  }

  .code-input {
    width: 170px;
  }

  .crane-type {
    min-height: 18px;
    font-size: 14px;
  }

  .lec-favorites {
    gap: 4px;
    padding: 6px;
  }

  .lec-favorite-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lec-favorite-chip {
    min-height: 36px;
  }

  .update-panel {
    gap: 0;
  }

  .update-panel .action {
    min-height: 38px;
  }

  .lec-result {
    padding: 6px;
  }

  .value-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
  }

  .value-box {
    grid-template-rows: 28px 34px;
  }

  .value-box:nth-child(4) {
    grid-column: auto;
  }

  .value-title {
    padding: 0 2px;
    font-size: 9px;
    line-height: 1.05;
  }

  .value-content {
    padding: 0 2px;
    overflow: hidden;
    font-size: 12px;
    line-height: 1.1;
    text-overflow: ellipsis;
  }

  .text-box {
    margin-top: 6px;
  }

  .text-box .value-title {
    height: 26px;
  }

  .text-box pre {
    min-height: 92px;
    max-height: none;
    overflow: visible;
    padding: 7px;
    font-size: 11px;
    line-height: 1.18;
  }

  .action-row {
    gap: 6px;
  }

  .lec-result .wide-actions {
    margin-top: 6px;
  }

  .lec-tool .action-row .action {
    min-height: 40px;
  }

  .action.primary {
    font-size: 24px;
  }

  .action.danger {
    font-size: 17px;
  }

  .lec-tool .copyright {
    font-size: 10px;
  }
}

@media (min-width: 560px) {
  .module-grid {
    grid-template-columns: 1fr 1fr;
  }

  .value-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .value-box:nth-child(4) {
    grid-column: span 2;
  }
}

@media (min-width: 800px) {
  .app-shell {
    padding: 24px;
  }

  .home-screen {
    grid-template-columns: 1fr;
    width: min(100%, 720px);
    justify-items: center;
  }

  .brand-icon {
    width: 148px;
    height: 148px;
    border-radius: 32px;
  }

  .module-card {
    min-height: 188px;
    padding: 24px;
  }

  .day-tool {
    grid-template-columns: 260px 1fr;
    align-items: center;
  }

  .day-tool .input-stack {
    grid-row: span 2;
  }

  .day-tool .wide-actions,
  .day-tool .status-line {
    grid-column: 2;
  }

  .lec-tool {
    grid-template-columns: 250px 1fr;
    align-items: start;
  }

  .lec-tool .input-stack,
  .lec-tool .crane-type,
  .lec-tool .lec-favorites,
  .lec-tool .update-panel,
  .lec-tool .wide-actions,
  .lec-tool .status-line {
    grid-column: 1;
  }

  .lec-tool .lec-result {
    grid-column: 2;
    grid-row: 1 / span 5;
  }

  .value-grid {
    grid-template-columns: repeat(5, minmax(110px, 1fr));
  }

  .value-box:nth-child(4) {
    grid-column: auto;
  }
}
