:root {
  --surface: rgba(255, 255, 255, 0.94);
  --surface-strong: #ffffff;
  --line: rgba(15, 23, 42, 0.08);
  --line-strong: rgba(15, 23, 42, 0.16);
  --text: #111827;
  --muted: #5f6b7a;
  --accent: #1d4ed8;
  --accent-2: #0f172a;
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
  --shadow-hover: 0 22px 48px rgba(15, 23, 42, 0.14);
  --content-width: min(1220px, calc(100% - 220px));
  --nav-height: 58px;
  --edge-gap: 28px;
  --brand-slot-width: 220px;
  --brand-image-height: 58px;
  --side-logo-size: 42px;
  --brand-text-offset: 38px;
  --sidebar-width-expanded: 232px;
  --sidebar-width-collapsed: 96px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  position: relative;
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  isolation: isolate;
  background:
    radial-gradient(circle at top left, rgba(59, 130, 246, 0.08), transparent 24%),
    linear-gradient(180deg, #fbfcff 0%, #f5f7fb 100%);
  color: var(--text);
  font-family: "Manrope", "Noto Sans SC", sans-serif;
}

.page-backdrop {
  position: fixed;
  top: -42px;
  left: -38px;
  width: min(80vw, 1360px);
  aspect-ratio: 1 / 1;
  pointer-events: none;
  z-index: 0;
  opacity: 0.18;
}

.page-backdrop img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: saturate(1.02) brightness(1.03);
  transform-origin: center center;
  animation: backdropSpin 72s linear infinite;
}

body.backdrop-paused .page-backdrop img {
  animation-play-state: paused;
}

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

button,
input {
  font: inherit;
}

.site-header {
  position: fixed;
  z-index: 2;
  top: 0;
  left: 0;
  right: 0;
  background: transparent;
  pointer-events: none;
}

.header-shell {
  position: relative;
  min-height: 88px;
  pointer-events: none;
}

.header-shell::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
  pointer-events: auto;
}

.header-core {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--brand-slot-width) minmax(0, 1fr);
  align-items: center;
  gap: 34px;
  width: var(--content-width);
  margin: 0 auto;
  height: var(--nav-height);
  padding-top: 0;
  pointer-events: none;
}

.nav-cluster {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-evenly;
  gap: 10px;
  min-height: var(--nav-height);
  height: var(--nav-height);
  pointer-events: auto;
}

.nav-item {
  position: relative;
  flex: 1 1 0;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
}

.nav-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: var(--nav-height);
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: #111827;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.01em;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.2s ease;
}

.nav-label-full {
  display: inline;
}

.nav-label-short {
  display: none;
}

.nav-trigger:hover,
.nav-item:hover > .nav-trigger,
.nav-item.is-open > .nav-trigger {
  color: var(--accent);
}

.nav-caret {
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid currentColor;
  transition: transform 0.2s ease;
}

.nav-item:hover .nav-caret,
.nav-item.is-open .nav-caret {
  transform: rotate(180deg);
}

.nav-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: var(--dropdown-left, 0px);
  min-width: 148px;
  width: max-content;
  max-width: 220px;
  padding: 12px 0;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.14);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
}

.nav-dropdown a {
  display: block;
  padding: 12px 14px;
  color: #1f2937;
  font-size: 15px;
  white-space: nowrap;
  transition: background-color 0.18s ease, color 0.18s ease;
}

.nav-dropdown a:hover {
  background: #f2f6ff;
  color: var(--accent);
}

.nav-item:hover .nav-dropdown,
.nav-item.is-open .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.brand-notch {
  z-index: 3;
  display: flex;
  justify-content: center;
  align-items: center;
  width: auto;
  margin-top: 0;
  pointer-events: auto;
}

.brand-badge {
  position: relative;
  width: 100%;
  height: var(--nav-height);
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  transform: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-badge-text-only {
  width: var(--brand-slot-width);
  overflow: hidden;
}

.brand-badge-full {
  width: var(--brand-slot-width);
}

.brand-badge img {
  position: relative;
  z-index: 1;
  display: block;
  width: auto;
  max-width: none;
  height: var(--brand-image-height);
  object-fit: contain;
  filter:
    saturate(1.18)
    contrast(1.04)
    brightness(1.03)
    drop-shadow(0 0 12px rgba(125, 211, 252, 0.18));
  animation: logoChromatic 16s linear infinite;
}

.brand-badge-text-only img {
  transform: translateX(calc(var(--brand-text-offset) * -1));
  transform-origin: center;
}

.edge-icon-button {
  position: absolute;
  top: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
  color: #4b5563;
  cursor: pointer;
  transition: background-color 0.22s ease, color 0.22s ease, transform 0.22s ease;
  pointer-events: auto;
}

.edge-icon-button:hover {
  background: rgba(29, 78, 216, 0.08);
  color: var(--accent);
  transform: translateY(-1px);
}

.edge-icon-button svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

.edge-left {
  left: var(--edge-gap);
}

.edge-right {
  right: var(--edge-gap);
}

.header-side-logo {
  position: absolute;
  top: calc((var(--nav-height) - var(--side-logo-size)) / 2);
  right: calc(var(--edge-gap) + 44px + 12px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--side-logo-size);
  height: var(--side-logo-size);
  padding: 0;
  border: 0;
  border-radius: 14px;
  background: transparent;
  cursor: pointer;
  pointer-events: auto;
  z-index: 2;
  transition: transform 0.18s ease, background-color 0.18s ease, box-shadow 0.18s ease;
}

.header-side-logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

.header-side-logo:hover {
  background: rgba(29, 78, 216, 0.06);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.header-side-logo:active,
.header-side-logo.is-pressed {
  transform: scale(0.93);
}

.header-side-logo.is-paused {
  background: rgba(15, 23, 42, 0.06);
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.search-row {
  position: absolute;
  top: calc(var(--nav-height) + 8px);
  left: var(--edge-gap);
  width: min(500px, calc(100vw - 56px));
  padding-top: 8px;
  background: transparent;
  pointer-events: none;
  z-index: 4;
}

.search-row-inner {
  width: 100%;
  pointer-events: auto;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--shadow);
}

.search-box input {
  flex: 1;
  min-width: 0;
  height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 12px;
  outline: none;
  font-size: 16px;
}

.search-box input:focus {
  border-color: rgba(29, 78, 216, 0.38);
  box-shadow: 0 0 0 4px rgba(29, 78, 216, 0.08);
}

.search-box button {
  min-width: 82px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: #0b0f17;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

.search-results {
  width: 100%;
  margin-top: 10px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.search-hint,
.search-empty {
  margin: 0;
  padding: 14px 16px;
  color: var(--muted);
  font-size: 14px;
}

.search-result-item {
  display: block;
  padding: 14px 16px;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
  transition: background-color 0.18s ease;
}

.search-result-item:hover {
  background: #f5f8ff;
}

.search-result-item strong {
  display: block;
  font-size: 15px;
}

.search-result-item span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.responsive-sidebar {
  display: none;
}

.responsive-sidebar {
  position: fixed;
  top: var(--nav-height);
  left: 0;
  bottom: 0;
  width: var(--sidebar-width-expanded);
  padding: 18px 14px 20px;
  border-right: 1px solid rgba(15, 23, 42, 0.08);
  background: linear-gradient(180deg, rgba(250, 252, 255, 0.98) 0%, rgba(241, 246, 255, 0.96) 100%);
  box-shadow: 10px 0 32px rgba(15, 23, 42, 0.06);
  overflow-y: auto;
  z-index: 1;
  transition: width 0.24s ease, padding 0.24s ease;
}

.responsive-sidebar-inner {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.responsive-sidebar-menu {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.sidebar-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 4px;
}

.sidebar-rail-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  color: #334155;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.sidebar-rail-toggle:hover {
  background: rgba(29, 78, 216, 0.08);
  color: var(--accent);
}

.sidebar-rail-toggle svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  transition: transform 0.24s ease;
}

.side-nav-group {
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(15, 23, 42, 0.06);
  overflow: hidden;
}

.side-nav-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border: 0;
  background: transparent;
  color: #111827;
  font-size: 15px;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.side-nav-trigger:hover,
.side-nav-group.is-open .side-nav-trigger {
  color: var(--accent);
  background: rgba(29, 78, 216, 0.06);
}

.side-nav-label-short {
  display: none;
}

.side-nav-caret {
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid currentColor;
  transition: transform 0.2s ease;
}

.side-nav-group.is-open .side-nav-caret {
  transform: rotate(180deg);
}

.side-nav-links {
  display: none;
  padding: 4px 10px 12px;
}

.side-nav-group.is-open .side-nav-links {
  display: grid;
  gap: 4px;
}

.side-nav-link {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  color: #334155;
  font-size: 14px;
  line-height: 1.45;
  transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.side-nav-link:hover {
  background: rgba(29, 78, 216, 0.08);
  color: var(--accent);
  transform: translateX(2px);
}

.page-main {
  position: relative;
  z-index: 1;
  width: var(--content-width);
  margin: 0 auto;
  padding-top: 92px;
  padding-bottom: 60px;
}

.hero-strip {
  padding-top: 24px;
}

.hero-banner {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 28px;
  padding: 34px 38px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(245, 249, 255, 0.92)),
    var(--surface);
  box-shadow: var(--shadow);
}

.hero-tag,
.section-label,
.panel-tag {
  display: inline-flex;
  width: fit-content;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(29, 78, 216, 0.08);
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
}

.hero-copy h1 {
  max-width: 12ch;
  margin: 18px 0 0;
  font-size: clamp(2.2rem, 4vw, 4.3rem);
  line-height: 1.08;
}

.hero-copy p {
  max-width: 56rem;
  margin: 18px 0 0;
  color: var(--muted);
  line-height: 1.9;
  font-size: 16px;
}

.hero-orbital {
  position: relative;
  min-height: 250px;
  border-radius: 26px;
  background:
    radial-gradient(circle at center, rgba(59, 130, 246, 0.16), transparent 45%),
    linear-gradient(180deg, #f8fbff, #eef3fb);
  overflow: hidden;
}

.ring,
.glow-point {
  position: absolute;
  border-radius: 999px;
}

.ring {
  border: 1px solid rgba(29, 78, 216, 0.16);
  animation: spin 16s linear infinite;
}

.ring-a {
  width: 210px;
  height: 210px;
  top: 18px;
  left: calc(50% - 105px);
}

.ring-b {
  width: 150px;
  height: 150px;
  top: 48px;
  left: calc(50% - 75px);
  animation-duration: 12s;
  animation-direction: reverse;
}

.ring-c {
  width: 84px;
  height: 84px;
  top: 81px;
  left: calc(50% - 42px);
  animation-duration: 9s;
}

.glow-point {
  width: 18px;
  height: 18px;
  top: calc(50% - 9px);
  left: calc(50% - 9px);
  background: linear-gradient(135deg, #60a5fa 0%, #1d4ed8 100%);
  box-shadow: 0 0 25px rgba(37, 99, 235, 0.42);
}

.module-section {
  margin-top: 34px;
}

.page-main > .module-section:first-child {
  margin-top: 12px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.section-head h2 {
  margin: 10px 0 0;
  font-size: 30px;
  line-height: 1.15;
}

.section-action {
  color: var(--accent);
  font-weight: 700;
}

.portal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 26px;
}

.portal-card,
.content-card,
.feature-panel {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
}

.portal-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 12px;
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.portal-card:hover,
.content-card:hover,
.feature-panel:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.portal-card:hover {
  border-color: rgba(111, 133, 255, 0.26);
}

.portal-media {
  position: relative;
  height: 206px;
  overflow: hidden;
  background: linear-gradient(135deg, #dbe8ff 0%, #eef4ff 100%);
}

.portal-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1);
  transition: transform 0.3s ease;
}

.portal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0);
  transition: background 0.3s ease-in-out;
  pointer-events: none;
}

.portal-card:hover .portal-media img {
  transform: scale(1.1);
}

.portal-card:hover .portal-overlay {
  background: rgba(15, 23, 42, 0.46);
}

.card-body {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "title title"
    "desc action";
  column-gap: 14px;
  row-gap: 10px;
  align-items: start;
  min-height: 120px;
  padding: 14px 16px 14px 16px;
  background: #ffffff;
  overflow: hidden;
}

.card-body::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 0;
  background: linear-gradient(180deg, #5f84ff 0%, #4b74ff 46%, #3f68f0 100%);
  transition: height 0.3s ease-in-out;
  z-index: 1;
}

.portal-card:hover .card-body::before {
  height: 100%;
}

.card-body h3,
.content-info h3,
.feature-panel h3 {
  margin: 0;
  font-size: 17px;
  line-height: 1.4;
  grid-area: title;
  position: relative;
  z-index: 2;
  transition: color 0.3s ease;
}

.card-body p,
.content-info p,
.feature-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  grid-area: desc;
  position: relative;
  z-index: 2;
  transition: color 0.3s ease;
}

.portal-card:hover .card-body h3,
.portal-card:hover .card-body p {
  color: #ffffff;
}

.card-actions {
  grid-area: action;
  position: relative;
  align-self: center;
  z-index: 2;
}

.card-link,
.content-info a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  height: 34px;
  margin-top: 0;
  padding: 0 14px;
  border-radius: 6px;
  background: #1677ff;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  box-shadow: none;
  transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.card-link:hover,
.content-info a:hover {
  transform: translateY(-1px);
}

.portal-card:hover .card-link {
  background: #0f172a;
  color: #ffffff;
}

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

.content-card {
  overflow: hidden;
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.content-cover {
  position: relative;
  height: 222px;
}

.cover-grid {
  background:
    linear-gradient(rgba(255,255,255,0.14) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.14) 1px, transparent 1px),
    linear-gradient(135deg, #1d4ed8 0%, #7db6ff 100%);
  background-size: 28px 28px, 28px 28px, auto;
}

.cover-code {
  background:
    radial-gradient(circle at 20% 22%, rgba(255,255,255,0.14), transparent 16%),
    linear-gradient(135deg, #0f172a 0%, #1d4ed8 52%, #8ec5ff 100%);
}

.cover-paper {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.04)),
    linear-gradient(135deg, #faf7ef 0%, #ece7dc 54%, #d8d0c3 100%);
}

.cover-light {
  background:
    radial-gradient(circle at 70% 24%, rgba(255,255,255,0.6), transparent 18%),
    linear-gradient(135deg, #e3edff 0%, #b1c8ff 55%, #f3f8ff 100%);
}

.cover-wave {
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,0.18), transparent 15%),
    linear-gradient(135deg, #09192f 0%, #0b4d7a 48%, #54c1f7 100%);
}

.cover-office {
  background:
    linear-gradient(135deg, rgba(255,255,255,0.15), rgba(255,255,255,0)),
    linear-gradient(135deg, #eef2f7 0%, #cad7e7 45%, #adbdd4 100%);
}

.content-info {
  padding: 22px;
}

.feature-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) repeat(2, minmax(0, 0.8fr));
  gap: 22px;
}

.feature-panel {
  position: relative;
  overflow: hidden;
  padding: 28px;
}

.wide-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 18px;
  align-items: center;
}

.signal-group {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  height: 128px;
}

.signal-group span {
  border-radius: 999px 999px 14px 14px;
  background: linear-gradient(180deg, #1677ff 0%, rgba(22, 119, 255, 0.15) 100%);
  animation: pulseBars 1.8s ease-in-out infinite;
}

.signal-group span:nth-child(1) { height: 44%; animation-delay: 0s; }
.signal-group span:nth-child(2) { height: 82%; animation-delay: 0.12s; }
.signal-group span:nth-child(3) { height: 62%; animation-delay: 0.24s; }
.signal-group span:nth-child(4) { height: 94%; animation-delay: 0.36s; }
.signal-group span:nth-child(5) { height: 54%; animation-delay: 0.48s; }

.lift-card {
  transform-origin: center bottom;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes pulseBars {
  0%, 100% {
    opacity: 0.65;
    transform: scaleY(0.94);
  }

  50% {
    opacity: 1;
    transform: scaleY(1);
  }
}

@keyframes logoChromatic {
  0% {
    filter:
      hue-rotate(0deg)
      saturate(1.12)
      contrast(1.03)
      brightness(1.02)
      drop-shadow(0 0 10px rgba(167, 243, 208, 0.14));
  }

  20% {
    filter:
      hue-rotate(72deg)
      saturate(1.2)
      contrast(1.04)
      brightness(1.04)
      drop-shadow(0 0 12px rgba(125, 211, 252, 0.18));
  }

  40% {
    filter:
      hue-rotate(144deg)
      saturate(1.18)
      contrast(1.04)
      brightness(1.05)
      drop-shadow(0 0 12px rgba(196, 181, 253, 0.18));
  }

  60% {
    filter:
      hue-rotate(216deg)
      saturate(1.22)
      contrast(1.05)
      brightness(1.03)
      drop-shadow(0 0 12px rgba(251, 191, 36, 0.16));
  }

  80% {
    filter:
      hue-rotate(288deg)
      saturate(1.16)
      contrast(1.04)
      brightness(1.04)
      drop-shadow(0 0 12px rgba(244, 114, 182, 0.16));
  }

  100% {
    filter:
      hue-rotate(360deg)
      saturate(1.12)
      contrast(1.03)
      brightness(1.02)
      drop-shadow(0 0 10px rgba(167, 243, 208, 0.14));
  }
}

@keyframes backdropSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@media (max-width: 1420px) {
  :root {
    --content-width: min(1180px, calc(100% - 180px));
    --edge-gap: 18px;
  }
}

@media (max-width: 1360px) {
  :root {
    --content-width: min(1140px, calc(100% - 72px));
  }

  .nav-cluster {
    display: none;
  }

  .header-core {
    grid-template-columns: 1fr;
    width: 100%;
    gap: 0;
    justify-items: center;
  }

  .brand-notch {
    width: var(--brand-slot-width);
  }

  .responsive-sidebar {
    display: block;
  }

  .page-main {
    width: auto;
    margin: 0 24px 0 calc(var(--sidebar-width-expanded) + 24px);
    padding-top: 92px;
  }
}

@media (max-width: 1200px) {
  :root {
    --content-width: min(1080px, calc(100% - 40px));
    --brand-slot-width: 170px;
    --brand-image-height: 42px;
    --brand-text-offset: 34px;
  }

  .page-backdrop {
    top: -34px;
    left: -28px;
    width: min(78vw, 1120px);
  }

  .content-grid,
  .portal-grid,
  .feature-layout {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  }

  .page-main {
    margin-left: calc(var(--sidebar-width-expanded) + 16px);
    margin-right: 16px;
  }

  .wide-panel {
    grid-column: 1 / -1;
  }
}

@media (max-width: 1020px) {
  :root {
    --content-width: min(100% - 24px, 1020px);
    --brand-slot-width: 154px;
    --brand-image-height: 38px;
    --brand-text-offset: 26px;
  }

  .page-main {
    margin-left: calc(var(--sidebar-width-expanded) + 12px);
    margin-right: 12px;
    padding-top: 84px;
  }

  .page-backdrop {
    top: -26px;
    left: -18px;
    width: min(82vw, 900px);
    opacity: 0.15;
  }

  .hero-banner {
    grid-template-columns: 1fr;
  }

  .portal-grid,
  .content-grid,
  .feature-layout {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  }
}

@media (max-width: 760px) {
  :root {
    --nav-height: 56px;
    --edge-gap: 12px;
    --brand-slot-width: 144px;
    --brand-image-height: 34px;
    --side-logo-size: 36px;
  }

  .header-side-logo {
    right: calc(var(--edge-gap) + 44px + 8px);
  }

  .page-main {
    width: auto;
    margin-left: calc(var(--sidebar-width-expanded) + 12px);
    margin-right: 12px;
    padding-top: 24px;
  }

  .page-backdrop {
    top: -10px;
    left: -12px;
    width: min(90vw, 640px);
    opacity: 0.13;
  }

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

body.sidebar-collapsed .responsive-sidebar {
  width: var(--sidebar-width-collapsed);
  padding-left: 10px;
  padding-right: 10px;
}

body.sidebar-collapsed .sidebar-toolbar {
  justify-content: center;
}

body.sidebar-collapsed .sidebar-rail-toggle {
  width: 44px;
  height: 44px;
  padding: 0;
  justify-content: center;
}

body.sidebar-collapsed .sidebar-rail-toggle svg {
  transform: rotate(180deg);
}

body.sidebar-collapsed .sidebar-rail-toggle-text,
body.sidebar-collapsed .side-nav-label-full,
body.sidebar-collapsed .side-nav-caret,
body.sidebar-collapsed .side-nav-links {
  display: none !important;
}

body.sidebar-collapsed .side-nav-label-short {
  display: inline;
}

body.sidebar-collapsed .side-nav-trigger {
  justify-content: center;
  padding-left: 10px;
  padding-right: 10px;
}

@media (max-width: 1360px) {
  body.sidebar-collapsed .page-main {
    margin-left: calc(var(--sidebar-width-collapsed) + 24px);
  }
}

@media (max-width: 760px) {
  body.sidebar-collapsed .page-main {
    margin-left: calc(var(--sidebar-width-collapsed) + 16px);
    margin-right: 12px;
  }
}

.page-tech-notes {
  background:
    radial-gradient(circle at 18% 18%, rgba(56, 189, 248, 0.12), transparent 26%),
    radial-gradient(circle at 82% 22%, rgba(99, 102, 241, 0.12), transparent 26%),
    linear-gradient(180deg, #f7faff 0%, #eef4ff 100%);
}

.page-tech-article {
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.14), transparent 28%),
    radial-gradient(circle at bottom right, rgba(14, 165, 233, 0.1), transparent 30%),
    linear-gradient(180deg, #f9fbff 0%, #eef3ff 100%);
}

.notes-page-main,
.article-page-main {
  padding-top: 112px;
  padding-bottom: 72px;
}

.notes-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.7fr);
  gap: 28px;
  align-items: stretch;
  margin-bottom: 26px;
}

.notes-hero-copy,
.notes-hero-panel,
.article-hero,
.article-toc-card,
.article-section {
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.notes-hero-copy {
  padding: 32px 34px;
  border-radius: 30px;
}

.notes-eyebrow,
.article-eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.1);
  color: #2753d7;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.notes-hero-copy h1,
.article-hero-copy h1 {
  margin: 18px 0 14px;
  font-size: clamp(36px, 4vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.notes-hero-copy p,
.article-hero-copy p {
  margin: 0;
  max-width: 760px;
  color: #536173;
  font-size: 16px;
  line-height: 1.9;
}

.notes-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.notes-hero-meta span {
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(15, 23, 42, 0.08);
  color: #334155;
  font-size: 14px;
  font-weight: 600;
}

.notes-hero-panel {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  padding: 24px;
  border-radius: 28px;
  background:
    linear-gradient(160deg, rgba(30, 64, 175, 0.92), rgba(37, 99, 235, 0.74)),
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.18), transparent 40%);
  color: #eff6ff;
}

.notes-hero-stat {
  padding: 16px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.notes-hero-stat strong {
  display: block;
  font-size: 30px;
  line-height: 1;
  font-weight: 800;
}

.notes-hero-stat span {
  display: block;
  margin-top: 8px;
  color: rgba(239, 246, 255, 0.82);
  font-size: 14px;
}

.notes-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 26px;
}

.notes-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.notes-tags a,
.notes-toolbar-link,
.note-card-link,
.article-pagination a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.notes-tags a {
  padding: 10px 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.8);
  color: #475569;
}

.notes-tags a.is-active,
.notes-tags a:hover {
  background: #2850de;
  color: #fff;
  box-shadow: 0 10px 24px rgba(40, 80, 222, 0.24);
}

.notes-toolbar-link,
.note-card-link,
.article-pagination a {
  padding: 11px 16px;
  background: #111827;
  color: #fff;
}

.notes-toolbar-link:hover,
.note-card-link:hover,
.article-pagination a:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.16);
}

.notes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 24px;
}

.note-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 26px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.note-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.14);
  border-color: rgba(59, 130, 246, 0.16);
}

.note-card-featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(0, 1.05fr);
}

.note-card-cover {
  display: block;
  min-height: 230px;
  overflow: hidden;
  background: linear-gradient(135deg, #dbe8ff 0%, #eef4ff 100%);
}

.note-card-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.note-card:hover .note-card-cover img {
  transform: scale(1.04);
}

.note-card-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 24px 26px 26px;
}

.note-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: #5f6b7a;
  font-size: 13px;
  font-weight: 700;
}

.note-card-meta span:first-child {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.1);
  color: #2850de;
}

.note-card-body h2 {
  margin: 0;
  font-size: 26px;
  line-height: 1.3;
  letter-spacing: -0.03em;
}

.note-card:not(.note-card-featured) .note-card-body h2 {
  font-size: 22px;
}

.note-card-body p {
  margin: 0;
  color: #526072;
  font-size: 15px;
  line-height: 1.85;
}

.note-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: auto;
}

.note-card-reading {
  color: #6b7280;
  font-size: 14px;
}

.article-shell {
  display: grid;
  gap: 28px;
}

.article-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.92fr);
  gap: 28px;
  padding: 28px;
  border-radius: 30px;
}

.article-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #2753d7;
  font-weight: 700;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.article-meta span {
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.05);
  color: #475569;
  font-size: 14px;
  font-weight: 600;
}

.article-cover {
  min-height: 320px;
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(135deg, #dbe8ff 0%, #eef4ff 100%);
}

.article-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 24px;
}

.article-content {
  display: grid;
  gap: 22px;
}

.article-toc {
  position: relative;
}

.article-toc-card {
  position: sticky;
  top: 92px;
  display: grid;
  gap: 8px;
  padding: 22px 20px;
  border-radius: 24px;
}

.article-toc-title {
  margin-bottom: 4px;
  color: #111827;
  font-size: 15px;
  font-weight: 800;
}

.article-toc-card a {
  color: #526072;
  font-size: 14px;
  line-height: 1.6;
}

.article-toc-card a:hover {
  color: #2753d7;
}

.article-section {
  padding: 30px 32px;
  border-radius: 28px;
}

.article-section h2 {
  margin: 0 0 16px;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.article-section p {
  margin: 0;
  color: #526072;
  font-size: 16px;
  line-height: 1.95;
}

.article-callout {
  margin-top: 18px;
  padding: 18px 20px;
  border-left: 4px solid #4f74ff;
  border-radius: 18px;
  background: rgba(79, 116, 255, 0.08);
  color: #334155;
  line-height: 1.8;
}

.article-figure {
  margin: 22px 0 0;
}

.article-figure img {
  display: block;
  width: 100%;
  border-radius: 22px;
}

.article-figure figcaption {
  margin-top: 12px;
  color: #64748b;
  font-size: 14px;
  line-height: 1.7;
}

.article-steps {
  margin: 18px 0 0;
  padding-left: 20px;
  color: #334155;
  line-height: 1.95;
}

.article-steps li + li {
  margin-top: 8px;
}

.article-video {
  margin-top: 20px;
}

.article-video-frame {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  min-height: 320px;
  background: #dce8ff;
}

.article-video-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.04);
}

.article-video-play {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 86px;
  height: 86px;
  margin: -43px 0 0 -43px;
  border: 0;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.22);
  cursor: pointer;
}

.article-video-play span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  margin: -14px 0 0 -8px;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  border-left: 22px solid #fff;
}

.article-video-note {
  margin-top: 12px;
  color: #64748b;
  font-size: 14px;
}

.article-code {
  margin-top: 20px;
  overflow: hidden;
  border-radius: 22px;
  background: #0f172a;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.16);
}

.article-code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #dbeafe;
  font-size: 14px;
  font-weight: 700;
}

.article-code-head button {
  padding: 8px 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
}

.article-code pre {
  margin: 0;
  padding: 18px 20px 22px;
  overflow-x: auto;
  color: #dbeafe;
  font-family: "Cascadia Code", "Consolas", monospace;
  font-size: 14px;
  line-height: 1.8;
}

.article-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}

@media (max-width: 1280px) {
  .notes-hero,
  .article-hero,
  .article-layout,
  .note-card-featured {
    grid-template-columns: 1fr;
  }

  .article-toc-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .notes-page-main,
  .article-page-main {
    padding-top: 92px;
    padding-bottom: 48px;
  }

  .notes-hero-copy,
  .notes-hero-panel,
  .article-hero,
  .article-section {
    padding: 22px;
  }

  .notes-hero-copy h1,
  .article-hero-copy h1 {
    font-size: 32px;
  }

  .note-card-body,
  .article-toc-card {
    padding: 20px;
  }

  .note-card-footer,
  .notes-toolbar,
  .article-pagination {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Tech Notes Pages Overrides */
.page-tech-notes {
  background:
    radial-gradient(circle at top left, rgba(42, 103, 255, 0.12), transparent 28%),
    radial-gradient(circle at top right, rgba(103, 80, 255, 0.08), transparent 26%),
    linear-gradient(180deg, #f9fbff 0%, #f3f7ff 100%);
}

.page-tech-article {
  background:
    radial-gradient(circle at top left, rgba(29, 78, 216, 0.12), transparent 26%),
    radial-gradient(circle at bottom right, rgba(99, 102, 241, 0.08), transparent 28%),
    linear-gradient(180deg, #f8fbff 0%, #f2f6ff 100%);
}

.notes-page-main,
.article-page-main {
  width: min(1180px, calc(100% - 80px));
  padding-top: 108px;
  padding-bottom: 64px;
}

.notes-hero,
.article-hero,
.article-reader-card {
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.notes-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
}

.notes-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.notes-tags button,
.notes-toolbar-link,
.note-row-link,
.article-pagination a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.notes-tags button {
  padding: 10px 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.84);
  color: #475569;
  cursor: pointer;
}

.notes-tags button.is-active,
.notes-tags button:hover {
  background: #2850de;
  color: #fff;
  box-shadow: 0 10px 24px rgba(40, 80, 222, 0.2);
}

.notes-toolbar-link,
.note-row-link,
.article-pagination a {
  padding: 11px 16px;
  background: #111827;
  color: #fff;
}

.notes-toolbar-link:hover,
.note-row-link:hover,
.article-pagination a:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.16);
}

.notes-list {
  display: grid;
  gap: 20px;
}

.note-row-card {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 0;
  overflow: hidden;
  border-radius: 26px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.note-row-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(59, 130, 246, 0.16);
}

.note-row-cover {
  position: relative;
  overflow: hidden;
  min-height: 228px;
  background: linear-gradient(135deg, #dbe8ff 0%, #eef4ff 100%);
}

.note-row-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.note-row-card:hover .note-row-cover img {
  transform: scale(1.04);
}

.note-row-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 24px 28px 24px;
}

.note-row-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}

.note-row-meta span:first-child {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(59, 130, 246, 0.1);
  color: #2850de;
}

.note-row-body h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: -0.03em;
}

.note-row-body h2 a {
  color: inherit;
}

.note-row-body p {
  margin: 0;
  color: #526072;
  font-size: 15px;
  line-height: 1.85;
}

.note-row-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: auto;
}

.note-row-reading {
  color: #6b7280;
  font-size: 14px;
}

.notes-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.notes-page-summary {
  color: #475569;
  font-size: 14px;
  font-weight: 700;
}

.notes-page-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.notes-page-button,
.notes-page-number {
  min-width: 42px;
  height: 42px;
  padding: 0 14px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  color: #334155;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.notes-page-button:hover,
.notes-page-number:hover {
  transform: translateY(-1px);
  border-color: rgba(40, 80, 222, 0.22);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.notes-page-button:disabled {
  opacity: 0.44;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.notes-page-number.is-active {
  background: #2850de;
  border-color: #2850de;
  color: #fff;
  box-shadow: 0 10px 24px rgba(40, 80, 222, 0.2);
}

.article-shell {
  display: grid;
  gap: 28px;
}

.article-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  gap: 28px;
  padding: 28px;
  border-radius: 30px;
}

.article-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #2753d7;
  font-weight: 700;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.article-meta span {
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.05);
  color: #475569;
  font-size: 14px;
  font-weight: 600;
}

.article-cover {
  min-height: 320px;
  border-radius: 24px;
  overflow: hidden;
  background: linear-gradient(135deg, #dbe8ff 0%, #eef4ff 100%);
}

.article-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-reader-card {
  border-radius: 28px;
  overflow: hidden;
}

.article-reader-body {
  display: grid;
  gap: 24px;
  padding: 34px 38px 38px;
}

.article-reader-body h2 {
  margin: 10px 0 0;
  font-size: 30px;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.article-reader-body p {
  margin: 0;
  color: #526072;
  font-size: 16px;
  line-height: 1.95;
}

.notes-empty-state,
.article-empty {
  padding: 28px;
  border: 1px dashed rgba(59, 130, 246, 0.22);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.7);
  color: #526072;
}

.notes-empty-state h2 {
  margin: 0 0 10px;
  font-size: 24px;
  line-height: 1.2;
  color: #111827;
}

.notes-empty-state p,
.article-empty {
  margin: 0;
  line-height: 1.8;
}

.article-rich-content > * + * {
  margin-top: 22px;
}

.article-rich-content h3,
.article-rich-content h4 {
  margin: 8px 0 0;
  color: #111827;
  line-height: 1.25;
}

.article-rich-content h3 {
  font-size: 24px;
}

.article-rich-content h4 {
  font-size: 20px;
}

.article-rich-content ul,
.article-rich-content ol {
  margin: 0;
  padding-left: 24px;
  color: #334155;
  line-height: 1.9;
}

.article-rich-content li + li {
  margin-top: 8px;
}

.article-rich-content blockquote {
  margin: 0;
  padding: 18px 20px;
  border-left: 4px solid #4f74ff;
  border-radius: 18px;
  background: rgba(79, 116, 255, 0.08);
  color: #334155;
  line-height: 1.8;
}

.article-rich-content a {
  color: #2753d7;
  text-decoration: underline;
  text-decoration-color: rgba(39, 83, 215, 0.3);
  text-underline-offset: 3px;
}

.article-rich-content code {
  padding: 2px 6px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.06);
  font-family: "Cascadia Code", "Consolas", monospace;
  font-size: 0.92em;
}

.article-callout {
  padding: 18px 20px;
  border-left: 4px solid #4f74ff;
  border-radius: 18px;
  background: rgba(79, 116, 255, 0.08);
  color: #334155;
  line-height: 1.8;
}

.article-figure img {
  display: block;
  width: 100%;
  border-radius: 22px;
}

.article-figure figcaption {
  margin-top: 12px;
  color: #64748b;
  font-size: 14px;
  line-height: 1.7;
}

.article-steps {
  margin: 0;
  padding-left: 20px;
  color: #334155;
  line-height: 1.95;
}

.article-steps li + li {
  margin-top: 8px;
}

.article-video-frame {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  min-height: 320px;
  background: #dce8ff;
}

.article-video-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-video-embed,
.article-video-player {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 320px;
  border: 0;
  background: #0f172a;
}

.article-video-play {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 86px;
  height: 86px;
  margin: -43px 0 0 -43px;
  border: 0;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.78);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.22);
  cursor: pointer;
}

.article-video-play span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  margin: -14px 0 0 -8px;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  border-left: 22px solid #fff;
}

.article-video-note {
  margin-top: 12px;
  color: #64748b;
  font-size: 14px;
}

.article-code {
  overflow: hidden;
  border-radius: 22px;
  background: #0f172a;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.16);
}

.article-code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #dbeafe;
  font-size: 14px;
  font-weight: 700;
}

.article-code-head button {
  padding: 8px 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
}

.article-code pre {
  margin: 0;
  padding: 18px 20px 22px;
  overflow-x: auto;
  color: #dbeafe;
  font-family: "Cascadia Code", "Consolas", monospace;
  font-size: 14px;
  line-height: 1.8;
}

.article-pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 6px;
}

@media (max-width: 1280px) {
  .notes-hero,
  .article-hero,
  .note-row-card {
    grid-template-columns: 1fr;
  }

  .note-row-cover {
    min-height: 240px;
  }
}

@media (max-width: 900px) {
  .notes-page-main,
  .article-page-main {
    width: min(100%, calc(100% - 36px));
  }

  .notes-toolbar,
  .notes-pagination {
    flex-direction: column;
    align-items: stretch;
  }
}

@media (max-width: 760px) {
  .notes-page-main,
  .article-page-main {
    padding-top: 92px;
    padding-bottom: 48px;
  }

  .notes-hero-copy,
  .notes-hero-panel,
  .article-hero,
  .article-reader-body {
    padding: 22px;
  }

  .notes-hero-copy h1,
  .article-hero-copy h1 {
    font-size: 32px;
  }

  .note-row-body {
    padding: 20px;
  }

  .note-row-footer,
  .article-pagination,
  .article-code-head {
    flex-direction: column;
    align-items: stretch;
  }

  .note-row-cover,
  .article-video-frame,
  .article-cover {
    min-height: 220px;
  }
}

/* Notes Hero unified shell */
.notes-hero {
  gap: 0;
  overflow: hidden;
  border-radius: 30px;
}

.notes-hero-copy {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.notes-hero-panel {
  border: 0;
  border-radius: 0;
  min-height: 100%;
  background:
    linear-gradient(160deg, rgba(30, 64, 175, 0.95), rgba(37, 99, 235, 0.78)),
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.18), transparent 40%);
  box-shadow: none;
}

@media (max-width: 1280px) {
  .notes-hero {
    gap: 0;
  }
}
