﻿:root {
  --page-bg: #eff7ff;
  --panel-bg: rgba(239, 247, 255, 0.78);
  --text: #101828;
  --muted: #5f6f8b;
  --accent: #0b63f6;
  --accent-dark: #084dc5;
  --card-shadow: 0 18px 40px rgba(94, 130, 186, 0.16);
  --soft-shadow: 0 12px 28px rgba(124, 162, 214, 0.14);
  --radius-xl: 30px;
  --radius-lg: 22px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  font-family: 'Microsoft YaHei UI', 'PingFang SC', 'Segoe UI', sans-serif;
  color: var(--text);
  background:
    linear-gradient(180deg, #ffffff 0 64px, #eaf4ff 64px, #edf7ff 100%);
}

body {
  overflow-x: hidden;
}

body::before,
body::after {
  content: '';
  position: fixed;
  inset: auto;
  border-radius: 999px;
  pointer-events: none;
  filter: blur(6px);
}

body::before {
  width: 520px;
  height: 520px;
  left: -180px;
  top: 160px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.7) 0%, rgba(255, 255, 255, 0.16) 42%, transparent 72%);
}

body::after {
  width: 560px;
  height: 560px;
  right: -180px;
  bottom: -180px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0.12) 38%, transparent 70%);
}

.page-shell {
  position: relative;
  width: 100%;
  margin: 0 auto;
  padding: 0 0 44px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  position: relative;
  z-index: 20;
  width: min(1560px, calc(100% - 80px));
  margin: 0 auto;
  padding: 8px 0 6px;
  min-height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  filter: drop-shadow(0 6px 14px rgba(11, 99, 246, 0.16));
}

.brand-mark img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
}

.brand-text {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.user-status {
  position: relative;
  z-index: 30;
}

.user-status__button {
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid rgba(171, 192, 222, 0.6);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 8px 18px rgba(107, 138, 188, 0.12);
  cursor: pointer;
}

.user-status__avatar {
  display: flex;
  width: 100%;
  height: 100%;
  align-items: center;
  justify-content: center;
  color: #4d6d96;
  font-size: 15px;
  font-weight: 700;
}

.user-status__panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 40;
  min-width: 180px;
  padding: 14px;
  border: 1px solid rgba(177, 202, 233, 0.7);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 20px 34px rgba(96, 126, 177, 0.16);
}

.user-status__name {
  font-size: 15px;
  font-weight: 700;
  color: #183050;
}

.user-status__id {
  margin-top: 4px;
  font-size: 13px;
  color: #6781a3;
}

.user-status__logout {
  width: 100%;
  margin-top: 12px;
  height: 36px;
  border: 0;
  border-radius: 12px;
  background: #eef5ff;
  color: #295ea8;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.icon-button {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #5a6d88;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.icon-button svg {
  width: 26px;
  height: 26px;
}

.course-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 86px;
  height: 46px;
  padding: 0 22px;
  border-radius: 18px;
  background: linear-gradient(180deg, #1f8fff 0%, #0b63f6 100%);
  color: #fff;
  text-decoration: none;
  font-size: 19px;
  font-weight: 700;
  box-shadow: 0 10px 22px rgba(11, 99, 246, 0.24);
}

.hero-panel {
  position: relative;
  width: 100%;
  padding: 28px 0 18px;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.course-grid {
  display: grid;
  width: min(1560px, calc(100% - 80px));
  margin: 0 auto;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px 26px;
  align-items: stretch;
}

.course-card {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.9);
  border: 4px solid rgba(255, 255, 255, 0.897);
  box-shadow: var(--card-shadow);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.course-card:hover {
  transform: translateY(-6px);
  border-color: rgba(74, 145, 235, 0.54);
  box-shadow: 0 22px 44px rgba(84, 122, 179, 0.2);
}

.course-art {
  aspect-ratio: 1.68 / 1;
  background: linear-gradient(180deg, #edf8ff, #dfeeff);
  overflow: hidden;
}

.course-art img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transform: scale(1);
  transform-origin: center center;
  transition: transform 280ms ease, filter 280ms ease;
}

.course-card:hover .course-art img {
  transform: scale(1.035);
  filter: saturate(1.03) brightness(1.02);
}

.course-card h2 {
  margin: 0;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px 16px;
  background: rgba(255, 255, 255, 0.97);
  font-size: clamp(24px, 2vw, 28px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0.01em;
}

.course-card--dark h2 {
  letter-spacing: 0;
}

@media (max-width: 1080px) {
  .brand-text {
    font-size: 22px;
  }

  .course-grid {
    gap: 22px;
  }

  .course-card h2 {
    font-size: 22px;
  }
}

@media (max-width: 860px) {
  .page-shell {
    padding-top: 10px;
  }

  .topbar {
    width: min(100%, calc(100% - 28px));
    padding: 6px 0 8px;
    min-height: 58px;
  }

  .hero-panel {
    padding: 24px 0 28px;
    border-radius: 28px;
  }

  .course-grid {
    width: min(100%, calc(100% - 28px));
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .course-button {
    min-width: 84px;
    height: 44px;
    font-size: 18px;
  }
}

@media (max-width: 560px) {
  .topbar {
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    width: min(100%, calc(100% - 20px));
  }

  .brand-text {
    font-size: 20px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
    flex-basis: 34px;
  }

  .topbar-actions {
    gap: 10px;
  }

  .course-grid {
    width: min(100%, calc(100% - 20px));
    grid-template-columns: 1fr;
  }

  .course-card h2 {
    min-height: 66px;
    font-size: 21px;
  }
}
