/* Stitch 风格首页（#page-home）— 与 前端2 设计对齐，纯 CSS */

#page-home.home-stitch {
  --st-primary: #005eb8;
  --st-primary-dim: #004489;
  --st-tertiary: #9c4600;
  --st-tertiary-dim: #6b2e00;
  --st-on-surface: #2a3439;
  --st-on-variant: #576067;
  --st-surface: #f6fafe;
  --st-container-low: #eff4f9;
  --st-outline: #a9b3ba;
  --st-font-head: "Plus Jakarta Sans", "PingFang SC", "Microsoft YaHei", sans-serif;
  --st-font-body: Inter, "PingFang SC", "Microsoft YaHei", sans-serif;
  --st-radius: 1rem;
  --st-radius-lg: 1.25rem;
  background: var(--st-surface);
  font-family: var(--st-font-body);
  color: var(--st-on-surface);
}

#page-home.home-stitch .st-h2 {
  font-family: var(--st-font-head);
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--st-on-surface);
}

#page-home.home-stitch .st-eyebrow {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--st-primary);
  margin-bottom: 0.35rem;
}

#page-home.home-stitch .st-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* —— Hero —— */
#page-home.home-stitch .st-hero {
  position: relative;
  min-height: min(92vh, 880px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

#page-home.home-stitch .st-hero__media {
  position: absolute;
  inset: 0;
}

#page-home.home-stitch .st-hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#page-home.home-stitch .st-hero__shade {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(2px);
}

#page-home.home-stitch .st-hero__gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, 0.2) 45%, rgba(246, 250, 254, 0.92) 100%);
}

#page-home.home-stitch .st-hero__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 56rem;
  padding: 4rem 1.5rem 3rem;
  text-align: center;
}

#page-home.home-stitch .st-kicker {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 0.75rem;
}

#page-home.home-stitch .st-hero__title {
  font-family: var(--st-font-head);
  font-size: clamp(2.25rem, 6vw, 3.75rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.04em;
  color: #fff;
  text-shadow: 0 4px 24px rgba(0, 0, 0, 0.35);
  margin-bottom: 0.75rem;
}

#page-home.home-stitch .st-hero__lead {
  font-size: clamp(1rem, 2.4vw, 1.35rem);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.92);
  max-width: 36rem;
  margin: 0 auto 2rem;
  line-height: 1.55;
}

/* 首页搜索：参考图 — 单条浅灰胶囊，字段与橙色「智能搜索」同属一条形容器，内边距留白 */
#page-home.home-stitch .st-glass--search {
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  text-align: left;
}

#page-home.home-stitch .st-search-track {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
  width: 100%;
  max-width: 100%;
  padding: 0.4rem 0.75rem 0.4rem 0.85rem;
  min-height: 3.5rem;
  background: rgba(248, 250, 252, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 9999px;
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

#page-home.home-stitch .st-search-track .st-field {
  position: relative;
  flex: 1 1 100px;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.65rem;
  min-height: 0;
  border-right: 1px solid rgba(148, 163, 184, 0.45);
  background: transparent;
}

/* 日期与橙色按钮之间不再画竖线，留白即可（贴近参考图） */
#page-home.home-stitch .st-search-track .st-field:last-of-type {
  border-right: none;
  padding-right: 0.35rem;
}

#page-home.home-stitch .st-search-track .st-field > i {
  color: var(--st-primary);
  font-size: 1.15rem;
  flex-shrink: 0;
}

#page-home.home-stitch .st-search-track .st-field label.st-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

#page-home.home-stitch .st-search-track .st-field input[type="text"],
#page-home.home-stitch .st-search-track .st-field input[type="date"] {
  flex: 1;
  min-width: 0;
  border: none;
  background: transparent;
  font-size: 1rem;
  font-weight: 500;
  color: var(--st-on-surface);
  outline: none;
}

/* 出发地 / 目的地字号略大 */
#page-home.home-stitch #heroFrom,
#page-home.home-stitch #heroTo {
  font-size: 1.125rem;
  font-weight: 600;
}

#page-home.home-stitch .st-search-track .st-field input::placeholder {
  color: #64748b;
}

#page-home.home-stitch .st-search-track .st-swap {
  flex: 0 0 auto;
  width: 2.5rem;
  height: 2.5rem;
  align-self: center;
  margin: 0 0.15rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: rgba(255, 255, 255, 0.85);
  color: var(--st-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

#page-home.home-stitch .st-search-track .st-swap:hover {
  transform: rotate(90deg);
  box-shadow: var(--shadow-sm, 0 2px 8px rgba(0, 0, 0, 0.08));
}

/* 橙色按钮：嵌在浅灰条内部右侧，四周留白由 .st-search-track 的 padding 体现 */
#page-home.home-stitch .st-search-track .st-search-btn {
  flex: 0 0 auto;
  order: 0;
  margin: 0.1rem 0 0.1rem auto;
  padding: 0.55rem 1.35rem;
  min-height: 2.65rem;
  border: none;
  border-radius: 9999px;
  background: linear-gradient(135deg, #ff8d44 0%, var(--st-tertiary) 100%);
  color: #fffaf8;
  font-weight: 700;
  font-size: 0.98rem;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(156, 70, 0, 0.28);
  transition: filter 0.2s, transform 0.15s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  align-self: center;
  min-width: 7.5rem;
}

@media (max-width: 899px) {
  #page-home.home-stitch .st-search-track .st-search-btn {
    flex: 1 1 auto;
    order: 10;
    min-width: 0;
    width: calc(100% - 0.2rem);
    margin: 0.5rem 0.2rem 0.15rem;
    border-radius: 9999px;
    border-top: 0;
  }

  #page-home.home-stitch .st-search-track {
    border-radius: 1.35rem;
    padding: 0.5rem 0.7rem 0.45rem 0.75rem;
  }
}

@media (min-width: 900px) {
  #page-home.home-stitch .st-search-track {
    flex-wrap: nowrap;
  }
}

#page-home.home-stitch .st-search-track .st-search-btn:hover {
  filter: brightness(1.05);
}

/* —— 区块通用 —— */
#page-home.home-stitch .st-block {
  padding: 4rem 0;
}

#page-home.home-stitch .st-block--muted {
  background: var(--st-container-low);
}

#page-home.home-stitch .st-block__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

#page-home.home-stitch .st-flash-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.9rem;
  color: var(--st-on-variant);
}

#page-home.home-stitch .st-flash-meta .timer-digits {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: var(--st-tertiary);
}

#page-home.home-stitch .st-link-all {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  color: var(--st-primary);
  cursor: pointer;
  transition: gap 0.2s;
}

#page-home.home-stitch .st-link-all:hover {
  gap: 0.5rem;
}

/* 限时闪购卡片网格 */
#page-home.home-stitch #flashCards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.5rem;
}

#page-home.home-stitch #flashCards .flash-card {
  background: #fff;
  border-radius: var(--st-radius-lg);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(0, 94, 184, 0.08);
  padding: 1.25rem;
  transition: transform 0.35s, box-shadow 0.35s;
}

#page-home.home-stitch #flashCards .flash-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.1);
}

#page-home.home-stitch #flashCards .flash-route {
  font-family: var(--st-font-head);
  font-weight: 700;
  font-size: 1.05rem;
}

/* 爆款网格 */
#page-home.home-stitch .st-deal-grid.deal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.25rem;
}

#page-home.home-stitch .deal-card {
  border-radius: var(--st-radius-lg);
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

/* 航线 tab */
#page-home.home-stitch .tab-switch {
  background: #fff;
  padding: 0.25rem;
  border-radius: 999px;
  border: 1px solid var(--st-outline);
}

#page-home.home-stitch .tab-switch .tab-btn {
  border-radius: 999px;
  padding: 0.45rem 1rem;
}

#page-home.home-stitch .tab-switch .tab-btn.active {
  background: var(--st-primary);
  color: #fff;
}

#page-home.home-stitch #popularRoutes.route-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
}

#page-home.home-stitch .route-card {
  border-radius: var(--st-radius);
  background: #fff;
  border: 1px solid rgba(0, 94, 184, 0.1);
  transition: transform 0.2s, box-shadow 0.2s;
}

#page-home.home-stitch .route-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 94, 184, 0.12);
}

/* 主题标签 */
#page-home.home-stitch .theme-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

#page-home.home-stitch .theme-tab {
  border-radius: 999px;
  border: 1px solid var(--st-outline);
  background: #fff;
}

#page-home.home-stitch .theme-tab.active {
  background: rgba(0, 94, 184, 0.12);
  border-color: var(--st-primary);
  color: var(--st-primary-dim);
  font-weight: 600;
}

#page-home.home-stitch #themeFlights.theme-flight-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

#page-home.home-stitch .theme-flight-card {
  border-radius: var(--st-radius);
  background: var(--st-surface);
  border: 1px solid rgba(0, 0, 0, 0.06);
}

/* 洞察分栏 */
#page-home.home-stitch .st-insight-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: start;
}

@media (min-width: 1024px) {
  #page-home.home-stitch .st-insight-split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr);
    gap: 3rem;
  }
}

#page-home.home-stitch .st-insight-copy p {
  color: var(--st-on-variant);
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

#page-home.home-stitch .st-feat-row {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

#page-home.home-stitch .st-feat-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  background: rgba(0, 94, 184, 0.1);
  color: var(--st-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1.25rem;
}

#page-home.home-stitch .st-feat-row:nth-child(2) .st-feat-icon {
  background: rgba(156, 70, 0, 0.1);
  color: var(--st-tertiary);
}

#page-home.home-stitch .st-feat-row h4 {
  font-family: var(--st-font-head);
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

#page-home.home-stitch .st-feat-row p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--st-on-variant);
}

#page-home.home-stitch .st-insight-grid.insight-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 768px) {
  #page-home.home-stitch .st-insight-grid.insight-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1100px) {
  #page-home.home-stitch .st-insight-grid.insight-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

#page-home.home-stitch .st-insight-grid .insight-card {
  border-radius: var(--st-radius-lg);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
}

#page-home.home-stitch .st-bento-intro {
  text-align: center;
  margin-bottom: 2.5rem;
}

#page-home.home-stitch .st-bento-intro .st-h2 {
  margin-top: 0.5rem;
}

#page-home.home-stitch .st-bento-lead {
  color: var(--st-on-variant);
  max-width: 36rem;
  margin: 0.75rem auto 0;
  line-height: 1.6;
}

/* Bento 热门目的地 */
#page-home.home-stitch .st-bento-grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: auto;
  gap: 1rem;
  min-height: 520px;
}

@media (min-width: 768px) {
  #page-home.home-stitch .st-bento-grid {
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: 1fr 1fr;
    gap: 1.25rem;
    min-height: 560px;
  }
  #page-home.home-stitch .st-bento__main {
    grid-column: span 8;
    grid-row: span 2;
  }
  #page-home.home-stitch .st-bento__sub {
    grid-column: span 4;
  }
}

#page-home.home-stitch .st-bento-card {
  position: relative;
  border-radius: var(--st-radius-lg);
  overflow: hidden;
  min-height: 220px;
}

#page-home.home-stitch .st-bento-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s ease;
}

#page-home.home-stitch .st-bento-card:hover img {
  transform: scale(1.05);
}

#page-home.home-stitch .st-bento-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.65), transparent 55%);
}

#page-home.home-stitch .st-bento-cap {
  position: absolute;
  left: 1.5rem;
  bottom: 1.25rem;
  z-index: 1;
  color: #fff;
}

#page-home.home-stitch .st-bento-cap h3 {
  font-family: var(--st-font-head);
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 0.25rem;
}

#page-home.home-stitch .st-bento__main .st-bento-cap h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

#page-home.home-stitch .st-bento-cap p {
  font-size: 0.9rem;
  opacity: 0.9;
}

/* 订阅 CTA */
#page-home.home-stitch .st-newsletter {
  background: linear-gradient(135deg, var(--st-primary) 0%, #003c79 100%);
  color: #fff;
  padding: 4rem 1.5rem;
  text-align: center;
}

#page-home.home-stitch .st-newsletter h2 {
  font-family: var(--st-font-head);
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 0.75rem;
}

#page-home.home-stitch .st-newsletter > .st-container > p {
  opacity: 0.88;
  margin-bottom: 1.5rem;
  max-width: 32rem;
  margin-left: auto;
  margin-right: auto;
}

#page-home.home-stitch .st-news-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 40rem;
  margin: 0 auto;
}

@media (min-width: 640px) {
  #page-home.home-stitch .st-news-form {
    flex-direction: row;
  }
}

#page-home.home-stitch .st-news-form input[type="email"] {
  flex: 1;
  padding: 1rem 1.25rem;
  border-radius: var(--st-radius);
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 1rem;
  outline: none;
}

#page-home.home-stitch .st-news-form input::placeholder {
  color: rgba(255, 255, 255, 0.55);
}

#page-home.home-stitch .st-news-form button {
  padding: 1rem 1.75rem;
  border-radius: var(--st-radius);
  border: none;
  background: #fff;
  color: var(--st-primary);
  font-weight: 700;
  cursor: pointer;
  transition: filter 0.2s;
}

#page-home.home-stitch .st-news-form button:hover {
  filter: brightness(0.97);
}
