:root {
  --bg: #f5efe3;
  --surface: rgba(255, 250, 241, 0.9);
  --surface-strong: #fffaf2;
  --ink: #1d2a3a;
  --muted: #5d6673;
  --line: rgba(29, 42, 58, 0.12);
  --primary: #0f5e8c;
  --primary-deep: #083653;
  --accent: #d78d2d;
  --accent-soft: rgba(215, 141, 45, 0.16);
  --shadow: 0 20px 50px rgba(28, 38, 53, 0.12);
  --radius-lg: 30px;
  --radius-md: 20px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Outfit", "PingFang SC", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(15, 94, 140, 0.16), transparent 26%),
    radial-gradient(circle at top right, rgba(215, 141, 45, 0.18), transparent 22%),
    linear-gradient(180deg, #f0e7d7 0%, #f8f4eb 45%, #f5efe3 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(29, 42, 58, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(29, 42, 58, 0.03) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.35), transparent 90%);
}

.page-shell {
  width: min(1240px, calc(100% - 32px));
  margin: 24px auto 48px;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: calc(var(--radius-lg) + 8px);
  background:
    linear-gradient(135deg, rgba(7, 50, 78, 0.96), rgba(18, 93, 133, 0.9) 48%, rgba(215, 141, 45, 0.76)),
    #0b3d5c;
  color: #fcf8f2;
  box-shadow: var(--shadow);
}

.hero::after {
  content: "";
  position: absolute;
  right: -80px;
  top: -40px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  filter: blur(2px);
}

.topbar,
.hero-content {
  position: relative;
  z-index: 1;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

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

.brand p,
.brand span {
  margin: 0;
}

.brand p {
  font-weight: 700;
  font-size: 1rem;
}

.brand span {
  color: rgba(252, 248, 242, 0.8);
  font-size: 0.9rem;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.12);
  font-family: "Noto Serif SC", serif;
  font-size: 1.15rem;
  letter-spacing: 0.08em;
}

.hero-link,
.primary-btn,
.secondary-btn,
.consult-toggle,
.consult-actions button,
.consult-form button {
  transition: transform 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.hero-link,
.secondary-btn {
  color: #fcf8f2;
  text-decoration: none;
}

.hero-link {
  padding: 12px 18px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.hero-content {
  display: grid;
  grid-template-columns: 1.5fr 0.95fr;
  gap: 28px;
  padding-top: 46px;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 14px;
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(252, 248, 242, 0.8);
}

.hero-copy h1,
.filter-head h2 {
  margin: 0;
  font-family: "Noto Serif SC", serif;
}

.hero-copy h1 {
  max-width: 12ch;
  font-size: clamp(2.4rem, 5vw, 4.6rem);
  line-height: 1.08;
}

.hero-copy p {
  max-width: 62ch;
  margin: 18px 0 0;
  color: rgba(252, 248, 242, 0.88);
  font-size: 1rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.primary-btn,
.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 600;
}

.primary-btn {
  background: #fcf8f2;
  color: var(--primary-deep);
  text-decoration: none;
}

.secondary-btn {
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
  text-decoration: none;
}

.hero-panel,
.notice,
.filters,
.school-card {
  backdrop-filter: blur(8px);
}

.hero-panel {
  align-self: end;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.08);
}

.panel-title {
  margin: 0 0 12px;
  font-size: 0.92rem;
  color: rgba(252, 248, 242, 0.72);
}

.hero-panel ul {
  margin: 0;
  padding-left: 18px;
  line-height: 1.9;
  color: rgba(252, 248, 242, 0.88);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.hero-stat {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.12);
}

.hero-stat strong,
.hero-stat span {
  display: block;
}

.hero-stat strong {
  font-size: 1.3rem;
}

.hero-stat span {
  margin-top: 6px;
  color: rgba(252, 248, 242, 0.72);
  font-size: 0.85rem;
}

.notice,
.filters {
  margin-top: 22px;
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.notice-title {
  margin: 0 0 8px;
  font-weight: 700;
}

.notice p:last-child {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.filter-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.filter-head h2 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
}

.filter-head p {
  margin: 0;
  color: var(--muted);
}

.toolbar {
  display: grid;
  grid-template-columns: 180px 220px minmax(240px, 1fr);
  gap: 14px;
  margin-top: 20px;
}

.toolbar-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toolbar-group label {
  font-size: 0.92rem;
  font-weight: 600;
}

.toolbar-group select,
.toolbar-group input,
.consult-form input {
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid rgba(29, 42, 58, 0.12);
  border-radius: 16px;
  background: #fffef9;
  color: var(--ink);
  font: inherit;
}

.toolbar-group input::placeholder,
.consult-form input::placeholder {
  color: #8891a0;
}

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

.school-card {
  position: relative;
  overflow: hidden;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 250, 241, 0.96)),
    var(--surface-strong);
  box-shadow: var(--shadow);
}

.school-card::before {
  content: "";
  position: absolute;
  inset: auto -20px -30px auto;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--accent-soft);
}

.card-top {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.stage-badge,
.district-pill,
.tag,
.consult-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
}

.stage-badge {
  min-height: 32px;
  padding: 0 12px;
  background: rgba(15, 94, 140, 0.1);
  color: var(--primary);
}

.district-pill {
  min-height: 34px;
  padding: 0 14px;
  background: rgba(29, 42, 58, 0.07);
  color: var(--muted);
  white-space: nowrap;
}

.school-name {
  margin: 10px 0 0;
  font-family: "Noto Serif SC", serif;
  font-size: 1.42rem;
}

.school-summary {
  position: relative;
  z-index: 1;
  min-height: 88px;
  margin: 16px 0 18px;
  color: var(--muted);
  line-height: 1.8;
}

.tag-row {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  min-height: 32px;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(29, 42, 58, 0.08);
}

.consult-box {
  position: relative;
  z-index: 1;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid rgba(29, 42, 58, 0.08);
}

.consult-label {
  min-height: 30px;
  padding: 0 12px;
  background: rgba(215, 141, 45, 0.12);
  color: #995b08;
}

.consult-toggle,
.consult-actions button,
.consult-form button {
  cursor: pointer;
  border: 0;
  font: inherit;
}

.consult-toggle {
  width: 100%;
  min-height: 48px;
  margin-top: 12px;
  border-radius: 16px;
  background: var(--primary-deep);
  color: #fcf8f2;
  font-weight: 600;
}

.consult-menu {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.consult-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.consult-actions button {
  min-height: 44px;
  padding: 0 12px;
  border-radius: 14px;
  border: 1px solid rgba(15, 94, 140, 0.14);
  background: rgba(15, 94, 140, 0.06);
  color: var(--primary-deep);
}

.consult-form {
  display: grid;
  gap: 10px;
}

.consult-form button {
  min-height: 48px;
  border-radius: 16px;
  background: var(--accent);
  color: #fff8ec;
  font-weight: 700;
}

.consult-tip {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.7;
}

.empty-state {
  grid-column: 1 / -1;
  padding: 38px 24px;
  border: 1px dashed rgba(29, 42, 58, 0.16);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.65);
  text-align: center;
  color: var(--muted);
}

.hero-link:hover,
.primary-btn:hover,
.secondary-btn:hover,
.consult-toggle:hover,
.consult-actions button:hover,
.consult-form button:hover {
  transform: translateY(-1px);
}

@media (max-width: 1080px) {
  .hero-content,
  .school-grid {
    grid-template-columns: 1fr 1fr;
  }

  .toolbar {
    grid-template-columns: 1fr 1fr;
  }

  .toolbar-search {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .page-shell {
    width: min(100% - 20px, 100%);
    margin: 10px auto 28px;
  }

  .hero,
  .notice,
  .filters,
  .school-card {
    border-radius: 24px;
  }

  .topbar,
  .filter-head,
  .hero-content,
  .school-grid,
  .toolbar,
  .consult-actions,
  .hero-stats {
    grid-template-columns: 1fr;
  }

  .topbar,
  .filter-head {
    display: grid;
  }

  .hero-content {
    padding-top: 28px;
  }

  .hero-copy h1 {
    max-width: 100%;
    font-size: 2.4rem;
  }

  .card-top {
    flex-direction: column;
  }
}
