:root {
  --ot-bg: #08111f;
  --ot-bg-2: #0d1b2c;
  --ot-panel: #111827;
  --ot-panel-2: #151f2e;
  --ot-surface: rgba(17, 24, 39, 0.86);
  --ot-border: rgba(255, 255, 255, 0.12);
  --ot-text: #f8fafc;
  --ot-muted: #94a3b8;
  --ot-blue: #38bdf8;
  --ot-green: #34d399;
  --ot-amber: #fbbf24;
  --ot-red: #fb7185;
  --ot-shadow: 0 20px 70px rgba(0, 0, 0, 0.38);
  --ot-radius: 16px;
  --ot-font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

body.ot-app-body,
body.ot-auth-body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.035), transparent 190px),
    linear-gradient(160deg, #08111f 0%, #0b1424 46%, #101827 100%);
  color: var(--ot-text);
  font-family: var(--ot-font);
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

body.ot-auth-body {
  display: grid;
  place-items: center;
  padding: 24px;
  overflow-x: hidden;
}

.ot-lang-selector {
  position: fixed;
  top: max(16px, env(safe-area-inset-top));
  right: max(16px, env(safe-area-inset-right));
  z-index: 30;
}

.ot-lang-selector select,
.ot-select-control {
  height: 38px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 8px;
  background: rgba(255,255,255,0.075);
  color: var(--ot-text);
  padding: 0 12px;
  outline: none;
  font-family: var(--ot-font);
}

.ot-lang-selector option,
.ot-select-control option {
  background: #141c2a;
  color: var(--ot-text);
}

.ot-auth-card {
  width: 100%;
  max-width: 430px;
  border: 1px solid rgba(255,255,255,0.11);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255,255,255,0.072), rgba(255,255,255,0.034));
  box-shadow: 0 24px 80px rgba(0,0,0,0.42);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  padding: 32px 28px 28px;
}

.ot-brand-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.ot-brand-mark {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  border: 1px solid rgba(125,211,252,0.32);
  background: rgba(125,211,252,0.10);
  color: #7dd3fc;
  display: grid;
  place-items: center;
  font-weight: 900;
}

.ot-brand-title {
  margin: 0;
  font-size: 22px;
  font-weight: 850;
  letter-spacing: 0;
  line-height: 1.15;
}

.ot-brand-subtitle {
  margin-top: 5px;
  color: var(--ot-muted);
  font-size: 13px;
  line-height: 1.45;
}

.ot-section-label {
  margin: 18px 0 10px;
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0;
}

.ot-field {
  margin-bottom: 14px;
}

.ot-field label {
  display: block;
  margin-bottom: 6px;
  color: var(--ot-muted);
  font-size: 12px;
  font-weight: 750;
}

.ot-field-icon {
  position: relative;
}

.ot-field-icon i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(255,255,255,0.38);
  font-size: 13px;
  pointer-events: none;
}

.ot-field-icon .ot-input {
  padding-left: 40px;
}

.ot-hint {
  margin: -5px 0 12px;
  color: rgba(255,255,255,0.50);
  font-size: 12px;
  line-height: 1.45;
}

.ot-auth-link {
  margin-top: 18px;
  color: var(--ot-muted);
  font-size: 13px;
  text-align: center;
}

.ot-auth-link a {
  color: #7dd3fc;
  text-decoration: none;
  font-weight: 800;
}

.ot-message {
  display: none;
  margin-top: 10px;
  text-align: center;
  font-size: 12px;
  line-height: 1.5;
}

.ot-message.show {
  display: block;
}

.ot-message.error {
  color: #fb7185;
}

.ot-message.success {
  color: #34d399;
}

.ot-admin-page {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 16px 92px;
}

.ot-page-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 8px;
  background: rgba(255,255,255,0.042);
  box-shadow: 0 14px 48px rgba(0,0,0,0.24);
}

.ot-header-copy {
  flex: 1;
  min-width: 0;
}

.ot-page-kicker {
  margin-bottom: 4px;
  color: #7dd3fc;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.ot-page-heading {
  margin: 0;
  font-size: 24px;
  font-weight: 850;
  letter-spacing: 0;
  line-height: 1.15;
}

.ot-page-subtitle {
  margin-top: 5px;
  color: var(--ot-muted);
  font-size: 13px;
  line-height: 1.45;
}

.ot-icon-btn {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.07);
  color: var(--ot-text);
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}

.ot-admin-layout {
  display: grid;
  grid-template-columns: minmax(300px, 360px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.ot-admin-panel {
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255,255,255,.062), rgba(255,255,255,.032));
  box-shadow: 0 18px 58px rgba(0,0,0,0.28);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  padding: 18px;
}

.ot-panel-title {
  margin: 0 0 14px;
  font-size: 16px;
  font-weight: 850;
  letter-spacing: 0;
}

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

.ot-list-card {
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.028));
  box-shadow: 0 12px 36px rgba(0,0,0,0.18);
}

.ot-empty {
  border: 1px dashed rgba(255,255,255,0.13);
  border-radius: 8px;
  background: rgba(255,255,255,0.035);
  color: var(--ot-muted);
  text-align: center;
  padding: 44px 18px;
  font-size: 13px;
}

.ot-badge {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(125,211,252,0.13);
  color: #7dd3fc;
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.ot-badge.green {
  background: rgba(52,211,153,0.13);
  color: #34d399;
}

.ot-badge.red {
  background: rgba(251,113,133,0.13);
  color: #fb7185;
}

.ot-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.ot-toast {
  position: fixed;
  top: max(20px, env(safe-area-inset-top));
  left: 50%;
  z-index: 1000;
  transform: translateX(-50%) translateY(-8px);
  max-width: min(90vw, 520px);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 999px;
  background: rgba(20, 26, 44, 0.96);
  color: var(--ot-text);
  box-shadow: 0 12px 34px rgba(0,0,0,0.35);
  opacity: 0;
  pointer-events: none;
  padding: 10px 18px;
  font-size: 13px;
  line-height: 1.35;
  transition: opacity .2s, transform .2s;
}

.ot-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.ot-modal {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0,0,0,0.72);
}

.ot-modal.show {
  display: flex;
}

.ot-modal-card {
  width: 100%;
  max-width: 420px;
  border: 1px solid rgba(255,255,255,0.11);
  border-radius: 8px;
  background: #141c2a;
  box-shadow: 0 22px 70px rgba(0,0,0,0.45);
  padding: 18px;
}

.ot-modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.ot-modal-actions .ot-btn {
  flex: 1;
}

.ot-shell-bg {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.035), transparent 180px),
    linear-gradient(150deg, #08111f 0%, #0b1424 48%, #101827 100%);
}

html {
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

.ot-page {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 22px 16px 92px;
  color: var(--ot-text);
  font-family: var(--ot-font);
}

.ot-topbar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.ot-back {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--ot-border);
  background: rgba(255, 255, 255, 0.07);
  color: var(--ot-text);
  cursor: pointer;
}

.ot-title {
  margin: 0;
  font-size: 25px;
  font-weight: 850;
  letter-spacing: 0;
}

.ot-subtitle {
  margin-top: 5px;
  color: var(--ot-muted);
  font-size: 13px;
  line-height: 1.45;
}

.ot-card {
  border: 1px solid var(--ot-border);
  border-radius: var(--ot-radius);
  background: linear-gradient(180deg, rgba(255,255,255,0.055), rgba(255,255,255,0.032));
  box-shadow: var(--ot-shadow);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.ot-btn {
  height: 42px;
  border: 0;
  border-radius: 12px;
  padding: 0 15px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.ot-btn:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.ot-btn.danger {
  color: #fb7185;
  background: rgba(251,113,133,0.12);
  border: 1px solid rgba(251,113,133,0.28);
}

.ot-btn.primary {
  color: #06111f;
  background: linear-gradient(135deg, #7dd3fc, #34d399);
}

.ot-btn.secondary {
  color: var(--ot-text);
  background: rgba(255,255,255,0.075);
  border: 1px solid var(--ot-border);
}

.ot-input,
.ot-select,
.ot-textarea {
  width: 100%;
  border: 1px solid rgba(255,255,255,0.11);
  border-radius: 12px;
  background: rgba(255,255,255,0.055);
  color: var(--ot-text);
  outline: none;
  font-family: var(--ot-font);
}

.ot-input::placeholder,
.ot-textarea::placeholder {
  color: rgba(255,255,255,0.34);
}

.ot-select option {
  background: #141c2a;
  color: var(--ot-text);
}

.ot-input,
.ot-select {
  height: 44px;
  padding: 0 12px;
}

.ot-textarea {
  min-height: 90px;
  padding: 11px 12px;
}

.ot-input:focus,
.ot-select:focus,
.ot-textarea:focus {
  border-color: rgba(125, 211, 252, 0.78);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12);
}


.mvp-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.72);
}

.mvp-modal.show {
  display: flex;
}

.mvp-modal__card {
  width: 100%;
  max-width: 360px;
  border: 1px solid var(--ot-border);
  border-radius: 16px;
  background: #141924;
  color: var(--ot-text);
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.45);
  padding: 18px;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
}

.mvp-modal__title {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 14px;
}

.mvp-modal__field {
  margin-bottom: 12px;
}

.mvp-modal__field label {
  display: block;
  margin-bottom: 5px;
  color: var(--ot-muted);
  font-size: 12px;
  font-weight: 700;
}

.mvp-modal__field input {
  width: 100%;
  height: 42px;
  border: 1px solid var(--ot-border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--ot-text);
  padding: 0 12px;
  outline: none;
}

.mvp-modal__error {
  display: none;
  margin: 6px 0 10px;
  color: #ff7b7b;
  font-size: 12px;
}

.mvp-modal__error.show {
  display: block;
}

.mvp-modal__actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}

.mvp-modal__btn {
  flex: 1;
  height: 40px;
  border: 0;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.mvp-modal__btn.secondary {
  background: rgba(255, 255, 255, 0.07);
  color: var(--ot-text);
  border: 1px solid var(--ot-border);
}

.mvp-modal__btn.primary {
  background: var(--ot-blue);
  color: #fff;
}

@media (max-width: 560px) {
  body.ot-auth-body {
    display: block;
    padding: 0;
  }

  .ot-auth-card {
    min-height: 100dvh;
    max-width: none;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 80px 22px 34px;
  }

  .ot-admin-page {
    padding: 14px 12px 92px;
  }

  .ot-page-header {
    padding: 12px;
  }

  .ot-page-heading {
    font-size: 21px;
  }

  .ot-admin-layout {
    grid-template-columns: 1fr;
  }

  .ot-modal-actions {
    flex-direction: column-reverse;
  }
}
