:root {
  color-scheme: light;
  --wm-bg: #f6f8fb;
  --wm-surface: #ffffff;
  --wm-surface-soft: #eef4f8;
  --wm-text: #18212d;
  --wm-muted: #5c6d7f;
  --wm-line: #d9e2ea;
  --wm-brand: #0f7b8f;
  --wm-brand-dark: #0b5969;
  --wm-accent: #2f8f5b;
  --wm-code-bg: #111827;
  --wm-code-text: #e8edf4;
  --wm-shadow: 0 18px 42px rgba(24, 33, 45, 0.11);
}

html {
  scroll-behavior: smooth;
}

body:not(.modern-page) {
  background:
    radial-gradient(circle at top left, rgba(15, 123, 143, 0.08), transparent 34rem),
    linear-gradient(180deg, #fbfcfe 0%, var(--wm-bg) 42%, #eef3f7 100%) !important;
  color: var(--wm-text) !important;
  font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif !important;
  line-height: 1.72 !important;
  margin: 0 !important;
  text-rendering: optimizeLegibility;
}

body:not(.modern-page)::before {
  background: linear-gradient(90deg, var(--wm-brand), var(--wm-accent));
  content: "";
  display: block;
  height: 5px;
  left: 0;
  position: fixed;
  right: 0;
  top: 0;
  z-index: 10001;
}

.wm-global-brandbar {
  align-items: center;
  background: rgba(246, 248, 251, 0.94);
  border-bottom: 1px solid var(--wm-line);
  display: flex;
  justify-content: center;
  min-height: 70px;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.wm-global-brand {
  color: var(--wm-text) !important;
  font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif !important;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0 !important;
  text-decoration: none !important;
}

.wm-global-brand span {
  color: var(--wm-brand) !important;
}

body:not(.modern-page) header,
body:not(.modern-page) .header,
body:not(.modern-page) .dashboard {
  background: rgba(255, 255, 255, 0.92) !important;
  border: 1px solid var(--wm-line) !important;
  border-radius: 8px !important;
  box-shadow: var(--wm-shadow) !important;
  color: var(--wm-text) !important;
}

body:not(.modern-page) header,
body:not(.modern-page) .header {
  margin: 18px auto !important;
  max-width: 1120px !important;
  padding: 24px !important;
}

body:not(.modern-page) .content {
  margin-left: clamp(0px, 20vw, 260px) !important;
  max-width: 1160px !important;
  padding: 28px !important;
}

body:not(.modern-page) .container,
body:not(.modern-page) main,
body:not(.modern-page) article {
  background: rgba(255, 255, 255, 0.95) !important;
  border: 1px solid var(--wm-line) !important;
  border-radius: 8px !important;
  box-shadow: var(--wm-shadow) !important;
  color: var(--wm-text) !important;
}

body:not(.modern-page) .container {
  margin: 18px auto 32px !important;
  max-width: 980px !important;
  padding: clamp(18px, 4vw, 36px) !important;
}

body:not(.modern-page) main,
body:not(.modern-page) article {
  margin: 24px auto !important;
  max-width: 980px !important;
  padding: clamp(18px, 4vw, 36px) !important;
}

body:not(.modern-page) h1,
body:not(.modern-page) h2,
body:not(.modern-page) h3,
body:not(.modern-page) h4 {
  color: var(--wm-text) !important;
  font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif !important;
  letter-spacing: 0 !important;
  line-height: 1.18 !important;
}

body:not(.modern-page) h1 {
  font-size: clamp(2rem, 5vw, 3.6rem) !important;
  margin: 0 0 18px !important;
}

body:not(.modern-page) h2 {
  border-top: 1px solid var(--wm-line);
  font-size: clamp(1.45rem, 3vw, 2.1rem) !important;
  margin: 34px 0 14px !important;
  padding-top: 26px;
}

body:not(.modern-page) h2:first-child {
  border-top: 0;
  margin-top: 0 !important;
  padding-top: 0;
}

body:not(.modern-page) h3 {
  color: var(--wm-brand-dark) !important;
  font-size: clamp(1.14rem, 2vw, 1.45rem) !important;
  margin: 24px 0 10px !important;
}

body:not(.modern-page) p,
body:not(.modern-page) li,
body:not(.modern-page) td,
body:not(.modern-page) th {
  font-size: 1rem !important;
}

body:not(.modern-page) p {
  margin: 0 0 16px !important;
}

body:not(.modern-page) a {
  color: var(--wm-brand-dark) !important;
  text-underline-offset: 3px;
}

body:not(.modern-page) a:hover {
  color: var(--wm-accent) !important;
}

body:not(.modern-page) ul,
body:not(.modern-page) ol {
  padding-left: 1.35rem !important;
}

body:not(.modern-page) li {
  margin: 7px 0 !important;
}

body:not(.modern-page) pre {
  background: var(--wm-code-bg) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 8px !important;
  color: var(--wm-code-text) !important;
  line-height: 1.55 !important;
  overflow: auto !important;
  padding: 18px !important;
  white-space: pre !important;
}

body:not(.modern-page) code {
  background: rgba(15, 123, 143, 0.09);
  border-radius: 5px;
  color: #0b4f5f;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace !important;
  padding: 0.12em 0.32em;
}

body:not(.modern-page) pre code {
  background: transparent !important;
  color: inherit !important;
  padding: 0 !important;
}

body:not(.modern-page) table {
  background: var(--wm-surface) !important;
  border-collapse: collapse !important;
  border-radius: 8px !important;
  display: block;
  max-width: 100%;
  overflow-x: auto;
  width: 100% !important;
}

body:not(.modern-page) th,
body:not(.modern-page) td {
  border: 1px solid var(--wm-line) !important;
  padding: 11px 12px !important;
  text-align: left !important;
}

body:not(.modern-page) th {
  background: var(--wm-surface-soft) !important;
  color: var(--wm-text) !important;
}

body:not(.modern-page) img,
body:not(.modern-page) video,
body:not(.modern-page) iframe {
  border-radius: 8px;
  max-width: 100%;
}

body:not(.modern-page) input,
body:not(.modern-page) textarea,
body:not(.modern-page) select,
body:not(.modern-page) button {
  border-radius: 7px !important;
  font: inherit !important;
}

body:not(.modern-page) button,
body:not(.modern-page) input[type="button"],
body:not(.modern-page) input[type="submit"] {
  background: var(--wm-brand) !important;
  border: 1px solid var(--wm-brand) !important;
  color: #fff !important;
  cursor: pointer;
  font-weight: 700 !important;
  padding: 9px 13px !important;
}

body:not(.modern-page) button:hover,
body:not(.modern-page) input[type="button"]:hover,
body:not(.modern-page) input[type="submit"]:hover {
  background: var(--wm-brand-dark) !important;
}

body:not(.modern-page) .menu-container {
  background: #14212c !important;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 12px 0 32px rgba(17, 24, 39, 0.22);
  box-sizing: border-box !important;
  color: #fff !important;
  height: 100vh !important;
  max-height: 100vh !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  padding-bottom: 32px !important;
  padding-top: 82px !important;
  scrollbar-color: rgba(255, 255, 255, 0.32) transparent;
  scrollbar-width: thin;
  top: 0 !important;
}

body:not(.modern-page) .menu-container[style*="250px"] {
  width: min(82vw, 280px) !important;
}

body:not(.modern-page) .menu-container a {
  border-radius: 6px !important;
  color: rgba(255, 255, 255, 0.88) !important;
  font-size: 15px !important;
  line-height: 1.25 !important;
  margin: 3px 10px !important;
  padding: 9px 12px !important;
  white-space: normal !important;
}

body:not(.modern-page) .menu-container::-webkit-scrollbar {
  width: 10px;
}

body:not(.modern-page) .menu-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.32);
  border: 3px solid #14212c;
  border-radius: 999px;
}

body:not(.modern-page) .menu-container a:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #fff !important;
}

body:not(.modern-page) .menu-btn {
  background: var(--wm-brand) !important;
  border-radius: 8px !important;
  box-shadow: var(--wm-shadow) !important;
  color: #fff !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  height: 42px;
  left: 18px !important;
  line-height: 42px;
  min-width: 42px;
  padding: 0 14px !important;
  position: fixed !important;
  text-align: center;
  top: 18px !important;
  width: auto !important;
  z-index: 1003 !important;
}

body:not(.modern-page) .menu {
  align-items: stretch !important;
  display: grid !important;
  gap: 14px !important;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)) !important;
  list-style: none !important;
  padding: 0 !important;
}

body:not(.modern-page) .menu a {
  background: var(--wm-surface) !important;
  border: 1px solid var(--wm-line) !important;
  border-radius: 8px !important;
  box-shadow: var(--wm-shadow) !important;
  color: var(--wm-text) !important;
  display: block !important;
  margin: 0 !important;
  padding: 18px !important;
  text-decoration: none !important;
  width: auto !important;
}

body:not(.modern-page) .menu a:hover {
  background: #e9f6f4 !important;
  border-color: #b7dcd6 !important;
}

.wm-reading-progress {
  background: linear-gradient(90deg, var(--wm-brand), var(--wm-accent));
  height: 5px;
  left: 0;
  position: fixed;
  top: 0;
  transform-origin: left;
  width: 100%;
  z-index: 10002;
}

.wm-liveclass,
.wm-liveclass * {
  box-sizing: border-box;
}

.wm-liveclass {
  background: #ffffff;
  border: 1px solid rgba(203, 213, 225, 0.95);
  border-radius: 8px;
  bottom: 22px;
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.22);
  color: #17212f;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  max-width: min(410px, calc(100vw - 28px));
  padding: 18px;
  position: fixed;
  right: 22px;
  text-align: left;
  width: 410px;
  z-index: 10020;
}

.wm-liveclass [hidden] {
  display: none !important;
}

.wm-liveclass-close {
  align-items: center !important;
  background: transparent !important;
  border: 0 !important;
  color: #64748b !important;
  cursor: pointer;
  display: inline-flex;
  font-size: 24px !important;
  font-weight: 500 !important;
  height: 32px;
  justify-content: center;
  line-height: 1 !important;
  padding: 0 !important;
  position: absolute;
  right: 10px;
  top: 8px;
  width: 32px;
}

.wm-liveclass-close:hover {
  background: #eef6f5 !important;
  color: #0f7b8f !important;
}

.wm-liveclass-kicker {
  color: #0f7b8f !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  letter-spacing: 0.06em !important;
  margin: 0 0 8px !important;
  text-transform: uppercase;
}

.wm-liveclass h2 {
  color: #111827 !important;
  font-size: 21px !important;
  font-weight: 850 !important;
  letter-spacing: 0 !important;
  line-height: 1.2 !important;
  margin: 0 34px 8px 0 !important;
  padding: 0 !important;
}

.wm-liveclass p {
  color: #526173 !important;
  font-size: 15px !important;
  line-height: 1.55 !important;
  margin: 0 0 14px !important;
}

.wm-liveclass-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.wm-liveclass button {
  border-radius: 7px !important;
  cursor: pointer;
  font-family: inherit !important;
  font-size: 14px !important;
  font-weight: 800 !important;
  line-height: 1.2 !important;
  min-height: 42px;
  padding: 10px 14px !important;
}

.wm-liveclass-yes,
.wm-liveclass-submit {
  background: #0f7b8f !important;
  border: 1px solid #0f7b8f !important;
  color: #ffffff !important;
}

.wm-liveclass-yes:hover,
.wm-liveclass-submit:hover {
  background: #0b5f70 !important;
  border-color: #0b5f70 !important;
}

.wm-liveclass-no,
.wm-liveclass-back {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #334155 !important;
}

.wm-liveclass-no:hover,
.wm-liveclass-back:hover {
  background: #f8fafc !important;
  border-color: #94a3b8 !important;
  color: #17212f !important;
}

.wm-liveclass-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr 1fr;
}

.wm-liveclass label {
  color: #334155 !important;
  display: grid;
  font-size: 13px !important;
  font-weight: 750 !important;
  gap: 6px;
  line-height: 1.3 !important;
  margin: 0 0 10px !important;
}

.wm-liveclass input,
.wm-liveclass select,
.wm-liveclass textarea {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 7px !important;
  color: #111827 !important;
  font-family: inherit !important;
  font-size: 14px !important;
  line-height: 1.35 !important;
  min-height: 40px;
  outline: 0;
  padding: 9px 10px !important;
  width: 100% !important;
}

.wm-liveclass textarea {
  min-height: 84px;
  resize: vertical;
}

.wm-liveclass input:focus,
.wm-liveclass select:focus,
.wm-liveclass textarea:focus {
  border-color: #0f7b8f !important;
  box-shadow: 0 0 0 3px rgba(15, 123, 143, 0.16);
}

.wm-liveclass-honey {
  display: none !important;
}

.wm-liveclass-note {
  background: #eef6f5;
  border: 1px solid #cce8e4;
  border-radius: 7px;
  color: #37515a !important;
  font-size: 13px !important;
  margin: 2px 0 0 !important;
  padding: 9px 10px;
}

.wm-liveclass-status {
  color: #0f7b8f !important;
  font-size: 13px !important;
  font-weight: 750 !important;
  margin: 10px 0 0 !important;
}

.wm-liveclass-status a {
  color: #0f7b8f !important;
  font-weight: 800 !important;
}

@media (max-width: 900px) {
  body:not(.modern-page) .content {
    margin-left: 0 !important;
    padding: 18px !important;
  }

  body:not(.modern-page) .container,
  body:not(.modern-page) main,
  body:not(.modern-page) article {
    border-radius: 8px !important;
    margin: 14px auto 24px !important;
    padding: 20px !important;
  }

  body:not(.modern-page) header,
  body:not(.modern-page) .header,
  body:not(.modern-page) .dashboard {
    margin: 14px !important;
  }

  body:not(.modern-page) .menu-container {
    width: 0 !important;
  }

  body:not(.modern-page) .menu-container[style*="250px"] {
    width: min(82vw, 280px) !important;
  }
}

@media (max-width: 640px) {
  .wm-liveclass {
    bottom: 12px;
    left: 12px;
    max-height: calc(100vh - 24px);
    overflow-y: auto;
    padding: 16px;
    right: 12px;
    width: auto;
  }

  .wm-liveclass-grid {
    grid-template-columns: 1fr;
  }

  .wm-liveclass-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .wm-liveclass button {
    width: 100%;
  }
}
