:root {
  /* LoveGuide brand — 浅粉主色 / 浅紫副色 */
  --primary: #f5a8c2;
  --primary-dark: #e887a8;
  --secondary: #c4b0e8;
  --secondary-dark: #a894d4;

  --bg: #fffbfc;
  --surface: #ffffff;
  --surface-alt: #fff5f9;
  --text: #3a3340;
  --muted: #7a7082;
  --accent: var(--primary-dark);
  --border: #f0e4ec;
  --max: 1100px;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  line-height: 1.6;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--secondary-dark);
  text-decoration: underline;
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* —— Header —— */
.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.875rem 0;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  color: var(--text);
  text-decoration: none;
}

.logo:hover {
  text-decoration: none;
  opacity: 0.92;
}

.logo-img {
  display: block;
  height: 36px;
  width: auto;
}

.logo-tagline {
  display: none;
  font-size: 0.8rem;
  font-weight: 500;
  font-style: italic;
  color: var(--muted);
  white-space: nowrap;
  line-height: 1.3;
}

@media (min-width: 900px) {
  .logo-tagline {
    display: block;
  }
}

.nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 2.75rem;
}

.nav-item {
  position: relative;
}

.nav-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}

.nav-trigger:hover,
.nav-item:focus-within .nav-trigger {
  color: var(--primary-dark);
  text-decoration: none;
}

.nav-chevron {
  display: inline-block;
  width: 0;
  height: 0;
  margin-top: 2px;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  opacity: 0.65;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.nav-item:hover .nav-chevron,
.nav-item:focus-within .nav-chevron {
  transform: rotate(180deg);
  opacity: 1;
}

.nav-menu {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 50%;
  z-index: 50;
  min-width: 13.5rem;
  max-width: 18rem;
  margin: 0;
  padding: 0.5rem 0;
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 28px rgba(58, 51, 64, 0.1);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%) translateY(6px);
  transition:
    opacity 0.15s ease,
    transform 0.15s ease,
    visibility 0.15s ease;
}

.nav-item:hover .nav-menu,
.nav-item:focus-within .nav-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.nav-menu li {
  margin: 0;
}

.nav-menu a {
  display: block;
  padding: 0.55rem 1rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  line-height: 1.35;
}

.nav-menu a:hover {
  background: var(--surface-alt);
  color: var(--primary-dark);
  text-decoration: none;
}

.nav-menu-footer {
  margin-top: 0.25rem;
  padding-top: 0.25rem;
  border-top: 1px solid var(--border);
}

.nav-menu-footer a {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--secondary-dark);
}

.nav-menu--compact {
  min-width: 11rem;
}

@media (max-width: 900px) {
  .nav {
    gap: 0.5rem 1.5rem;
  }

  .nav-menu {
    left: 0;
    transform: translateY(6px);
  }

  .nav-item:hover .nav-menu,
  .nav-item:focus-within .nav-menu {
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .header-inner {
    flex-direction: column;
    align-items: stretch;
  }

  .nav {
    justify-content: space-between;
    gap: 0.25rem 1rem;
  }

  .nav-trigger {
    font-size: 0.95rem;
  }

  .nav-menu {
    min-width: 10rem;
  }
}

/* —— Page —— */
.page-main {
  min-height: 55vh;
  padding: 2rem 0 3rem;
}

.page-header h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--text);
}

.page-desc {
  color: var(--muted);
  margin: 0;
}

.page-body--blank {
  margin-top: 2rem;
  padding: 2rem;
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-alt);
  color: var(--muted);
  text-align: center;
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.breadcrumb li:not(:last-child)::after {
  content: '/';
  margin-left: 0.5rem;
  color: var(--border);
}

.list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.card {
  display: block;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 16px rgba(245, 168, 194, 0.2);
  text-decoration: none;
}

/* —— Footer —— */
.site-footer {
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, var(--surface-alt) 0%, var(--surface) 100%);
  padding: 2rem 0;
  margin-top: 3rem;
}

.footer-inner {
  display: grid;
  gap: 0.5rem;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  margin: 0;
  color: var(--text);
}

.footer-brand img {
  height: 28px;
  width: auto;
}

.footer-tagline {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0;
}

.footer-note,
.footer-copy {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-nav a {
  color: var(--secondary-dark);
  font-weight: 500;
}

.footer-nav a:hover {
  color: var(--primary-dark);
}

/* —— Homepage —— */
.home-main {
  padding: 1.5rem 0 0;
}

.home-section {
  margin-bottom: 2.5rem;
}

.home-section__head {
  margin-bottom: 1rem;
}

.home-section__title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
}

.home-empty {
  margin: 0;
  padding: 2rem;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-alt);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Bento grid */
.home-bento {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(3, minmax(7rem, auto));
  gap: 0.875rem;
}

.bento-tile {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.35rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  overflow: hidden;
  position: relative;
  min-height: 7rem;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}

.bento-tile::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.55;
  pointer-events: none;
}

.bento-tile--review::before {
  background: linear-gradient(145deg, rgba(245, 168, 194, 0.35) 0%, rgba(255, 251, 252, 0.9) 70%);
}

.bento-tile--compare::before {
  background: linear-gradient(145deg, rgba(196, 176, 232, 0.4) 0%, rgba(255, 251, 252, 0.9) 70%);
}

.bento-tile--guide::before {
  background: linear-gradient(145deg, rgba(232, 135, 168, 0.22) 0%, rgba(196, 176, 232, 0.25) 55%, rgba(255, 251, 252, 0.92) 100%);
}

.bento-tile--question::before {
  background: linear-gradient(145deg, rgba(168, 148, 212, 0.28) 0%, rgba(255, 251, 252, 0.9) 70%);
}

.bento-tile:hover {
  border-color: var(--primary);
  box-shadow: 0 8px 24px rgba(245, 168, 194, 0.22);
  text-decoration: none;
  transform: translateY(-2px);
}

.bento-tile__kind,
.bento-tile__title,
.bento-tile__date {
  position: relative;
  z-index: 1;
}

.bento-tile__kind {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--secondary-dark);
}

.bento-tile__title {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text);
}

.bento-tile__date {
  font-size: 0.78rem;
  color: var(--muted);
}

.bento-tile--hero {
  grid-column: 1 / 3;
  grid-row: 1 / 3;
  min-height: 16rem;
  padding: 1.35rem 1.5rem;
}

.bento-tile--hero .bento-tile__title {
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
}

.bento-tile--hero .bento-tile__kind {
  font-size: 0.78rem;
}

.bento-tile:nth-child(2) {
  grid-column: 3 / 5;
  grid-row: 1 / 2;
}

.bento-tile:nth-child(3) {
  grid-column: 3 / 4;
  grid-row: 2 / 3;
}

.bento-tile:nth-child(4) {
  grid-column: 4 / 5;
  grid-row: 2 / 3;
}

.bento-tile:nth-child(5) {
  grid-column: 1 / 5;
  grid-row: 3 / 4;
}

@media (max-width: 768px) {
  .home-bento {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: none;
  }

  .bento-tile,
  .bento-tile--hero,
  .bento-tile:nth-child(n) {
    grid-column: auto;
    grid-row: auto;
  }

  .bento-tile--hero {
    grid-column: 1 / -1;
    min-height: 12rem;
  }
}

@media (max-width: 480px) {
  .home-bento {
    grid-template-columns: 1fr;
  }
}

/* Path cards */
.home-path-grid {
  margin-top: 0;
}

.path-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-height: 6.5rem;
}

.path-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
}

.path-card__desc {
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.45;
}

/* Segai featured */
.segai-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 0.875rem;
}

.segai-card {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1.15rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, rgba(245, 168, 194, 0.12) 0%, var(--surface) 55%);
  color: var(--text);
  text-decoration: none;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

.segai-card:hover {
  border-color: var(--primary);
  box-shadow: 0 6px 20px rgba(245, 168, 194, 0.18);
  text-decoration: none;
}

.segai-card--lead {
  min-height: 11rem;
  justify-content: flex-end;
}

.segai-card__badge {
  align-self: flex-start;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: var(--primary);
  color: var(--text);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.segai-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
}

.segai-card--lead .segai-card__title {
  font-size: 1.35rem;
}

.segai-card__desc {
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 1.45;
}

.segai-side {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.segai-card--compact {
  flex: 1;
  justify-content: center;
}

@media (max-width: 768px) {
  .segai-layout {
    grid-template-columns: 1fr;
  }
}

/* Subscribe */
.home-subscribe {
  margin-bottom: 1rem;
}

.subscribe-box {
  padding: 1.5rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.subscribe-box__title {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
  font-weight: 700;
}

.subscribe-box__desc {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.subscribe-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.subscribe-form__input {
  flex: 1 1 12rem;
  min-width: 0;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

.subscribe-form__input:focus {
  outline: 2px solid rgba(245, 168, 194, 0.55);
  outline-offset: 1px;
  border-color: var(--primary);
}

.subscribe-form__btn {
  padding: 0.65rem 1.25rem;
  border: none;
  border-radius: var(--radius-sm);
  background: var(--primary);
  color: var(--text);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.subscribe-form__btn:hover {
  background: var(--primary-dark);
}

.subscribe-box__fine {
  margin: 0.75rem 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}
