/*
Theme Name: 中国旅居康养产业研究院 Neve Production
Theme URI: https://www.lvju.org.cn/
Description: 中国旅居康养产业研究院生产子主题；按 Neve 4.2.8 验证，强调城市样本、生活方式与非医疗边界。
Author: OpenLX
Version: 1.0.1
Template: neve
Text Domain: lvju-neve-production
*/

:root {
  --lvju-primary: #31524a;
  --lvju-terracotta: #c27654;
  --lvju-gold: #c4a16c;
  --lvju-surface: #fbf8ef;
  --lvju-paper: #fffdf8;
  --lvju-ink: #283431;
  --lvju-muted: #65716c;
  --lvju-mist: #e8eee9;
  --lvju-line: #d5ded7;
  --lvju-white: #ffffff;
  --lvju-wide: 1180px;
  --lvju-content: 780px;
  --lvju-radius: 6px;
  --lvju-shadow: 0 18px 48px rgba(40, 52, 49, 0.08);
  --lvju-heading: "Noto Serif SC", "Source Han Serif SC", "Songti SC", serif;
  --lvju-body: "PingFang SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
}

html {
  scroll-behavior: smooth;
}

body.lvju-neve-production {
  background: var(--lvju-surface);
  color: var(--lvju-ink);
  font-family: var(--lvju-body);
  font-size: 17px;
  line-height: 1.78;
  margin: 0;
  text-rendering: optimizeLegibility;
}

body.lvju-neve-production * {
  box-sizing: border-box;
}

body.lvju-neve-production :where(h1, h2, h3, h4, h5, h6) {
  color: var(--lvju-primary);
  font-family: var(--lvju-heading);
  font-weight: 650;
  letter-spacing: -0.012em;
}

body.lvju-neve-production a {
  color: var(--lvju-primary);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

body.lvju-neve-production a:hover,
body.lvju-neve-production a:focus-visible {
  color: var(--lvju-terracotta);
}

.lvju-neve-production .skip-link:focus {
  background: var(--lvju-paper);
  color: var(--lvju-primary);
  clip: auto !important;
  clip-path: none;
  display: block;
  height: auto;
  left: 12px;
  padding: 10px 14px;
  position: fixed;
  top: 12px;
  width: auto;
  z-index: 1000;
}

.lvju-site-header {
  background: rgba(251, 248, 239, 0.97);
  border-bottom: 1px solid var(--lvju-line);
  position: relative;
  z-index: 50;
}

.lvju-header-inner,
.lvju-footer-inner,
.lvju-listing-shell,
.lvju-reading-shell,
.lvju-error-shell {
  margin-inline: auto;
  max-width: var(--lvju-wide);
  width: min(100% - 40px, var(--lvju-wide));
}

.lvju-header-inner {
  align-items: center;
  display: flex;
  gap: 30px;
  justify-content: space-between;
  min-height: 82px;
  padding-block: 14px;
}

.lvju-brand {
  flex: 0 1 280px;
}

.lvju-brand-name {
  color: var(--lvju-primary);
  display: inline-block;
  font-family: var(--lvju-heading);
  font-size: clamp(1rem, 1.8vw, 1.3rem);
  font-weight: 700;
  line-height: 1.25;
  text-decoration: none;
}

.lvju-brand-note {
  color: var(--lvju-muted);
  font-size: 0.73rem;
  letter-spacing: 0.05em;
  margin: 4px 0 0;
}

.lvju-desktop-nav {
  min-width: 0;
}

.lvju-menu {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0 18px;
  justify-content: flex-end;
  list-style: none;
  margin: 0;
  padding: 0;
}

.lvju-menu > li {
  position: relative;
}

.lvju-menu a {
  align-items: center;
  color: var(--lvju-primary);
  display: inline-flex;
  font-size: 0.9rem;
  font-weight: 650;
  min-height: 44px;
  text-decoration: none;
}

.lvju-menu > .current-menu-item > a,
.lvju-menu > .current-menu-ancestor > a,
.lvju-menu > li > a:hover,
.lvju-menu > li > a:focus-visible {
  color: var(--lvju-terracotta);
  text-decoration: underline;
  text-decoration-color: var(--lvju-gold);
  text-underline-offset: 7px;
}

.lvju-menu .sub-menu {
  background: var(--lvju-paper);
  border: 1px solid var(--lvju-line);
  box-shadow: var(--lvju-shadow);
  display: none;
  left: -16px;
  list-style: none;
  margin: 0;
  min-width: 210px;
  padding: 10px;
  position: absolute;
  top: calc(100% - 2px);
}

.lvju-menu li:hover > .sub-menu,
.lvju-menu li:focus-within > .sub-menu {
  display: block;
}

.lvju-menu .sub-menu a {
  min-height: 40px;
  padding-inline: 10px;
  width: 100%;
}

.lvju-mobile-nav {
  display: none;
}

.lvju-mobile-nav summary {
  align-items: center;
  border: 1px solid var(--lvju-primary);
  border-radius: var(--lvju-radius);
  color: var(--lvju-primary);
  cursor: pointer;
  display: inline-flex;
  font-weight: 700;
  justify-content: center;
  min-height: 44px;
  padding: 8px 16px;
}

.lvju-page-shell {
  margin: 0;
  max-width: none;
  padding: 0;
  width: 100%;
}

.lvju-page-content,
.lvju-page-content > .entry-content {
  margin: 0;
  max-width: none;
  padding: 0;
}

.lvju-reading-shell,
.lvju-listing-shell,
.lvju-error-shell {
  padding-block: clamp(48px, 7vw, 92px);
}

.lvju-article {
  margin-inline: auto;
  max-width: 880px;
}

.lvju-article-header h1,
.lvju-listing-header h1,
.lvju-error-shell h1 {
  font-size: clamp(2.3rem, 5vw, 4.3rem);
  line-height: 1.14;
  margin: 0;
  max-width: 930px;
}

.lvju-article-meta {
  align-items: center;
  border-bottom: 1px solid var(--lvju-line);
  color: var(--lvju-muted);
  display: flex;
  flex-wrap: wrap;
  font-size: 0.82rem;
  gap: 10px 22px;
  margin-block: 22px 34px;
  padding-bottom: 18px;
}

.lvju-featured-image {
  margin: 0 0 36px;
}

.lvju-featured-image img {
  aspect-ratio: 16 / 9;
  border: 1px solid var(--lvju-line);
  display: block;
  height: auto;
  object-fit: cover;
  width: 100%;
}

.lvju-article-body {
  margin-inline: auto;
  max-width: var(--lvju-content);
}

.lvju-article-body > :where(p, ul, ol, blockquote) {
  max-width: var(--lvju-content);
}

.lvju-article-body h2 {
  border-top: 1px solid var(--lvju-line);
  margin-top: 2.4em;
  padding-top: 1.2em;
}

.lvju-article-body :where(blockquote, .wp-block-quote) {
  background: var(--lvju-mist);
  border-left: 4px solid var(--lvju-gold);
  margin-inline: 0;
  padding: 20px 24px;
}

.lvju-article-body :where(table, .wp-block-table table) {
  border-collapse: collapse;
  display: block;
  max-width: 100%;
  overflow-x: auto;
}

.lvju-article-body :where(th, td) {
  border: 1px solid var(--lvju-line);
  padding: 12px 14px;
  text-align: left;
}

.lvju-article-body th {
  background: var(--lvju-mist);
}

.lvju-listing-header {
  margin-bottom: 38px;
  max-width: 820px;
}

.lvju-listing-header > p,
.lvju-archive-description {
  color: var(--lvju-muted);
  font-size: 1.04rem;
  margin-top: 18px;
}

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

.lvju-post-card {
  background: var(--lvju-paper);
  border: 1px solid var(--lvju-line);
  border-radius: var(--lvju-radius);
  overflow: hidden;
}

.lvju-card-image {
  display: block;
}

.lvju-card-image img {
  aspect-ratio: 4 / 3;
  display: block;
  height: auto;
  object-fit: cover;
  width: 100%;
}

.lvju-card-body {
  padding: 24px;
}

.lvju-card-meta {
  color: var(--lvju-terracotta);
  font-size: 0.76rem;
  font-weight: 700;
  margin: 0 0 10px;
}

.lvju-post-card h2 {
  font-size: 1.35rem;
  line-height: 1.42;
  margin: 0 0 12px;
}

.lvju-post-card h2 a {
  color: inherit;
  text-decoration: none;
}

.lvju-card-excerpt {
  color: var(--lvju-muted);
  font-size: 0.94rem;
}

.lvju-card-excerpt p {
  margin: 0;
}

.lvju-card-link {
  display: inline-block;
  font-weight: 700;
  margin-top: 16px;
  text-decoration: none;
}

.navigation.pagination {
  border-top: 1px solid var(--lvju-line);
  margin-top: 34px;
  padding-top: 24px;
}

.nav-links {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.nav-links .page-numbers {
  align-items: center;
  border: 1px solid var(--lvju-line);
  border-radius: var(--lvju-radius);
  display: inline-flex;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
  padding-inline: 12px;
  text-decoration: none;
}

.nav-links .current {
  background: var(--lvju-primary);
  border-color: var(--lvju-primary);
  color: var(--lvju-white);
}

.lvju-empty-state {
  background: var(--lvju-mist);
  border-left: 4px solid var(--lvju-gold);
  padding: 20px 24px;
}

.lvju-error-shell {
  min-height: 52vh;
}

.lvju-error-shell p {
  color: var(--lvju-muted);
  font-size: 1.06rem;
  max-width: 680px;
}

.search-form {
  display: flex;
  gap: 10px;
  margin-top: 24px;
  max-width: 680px;
}

.search-form label {
  flex: 1;
}

.search-form .search-field {
  background: var(--lvju-white);
  border: 1px solid var(--lvju-line);
  border-radius: var(--lvju-radius);
  color: var(--lvju-ink);
  font: inherit;
  min-height: 46px;
  padding: 10px 14px;
  width: 100%;
}

.search-form .search-submit,
body.lvju-neve-production :where(button, input[type="submit"], .wp-element-button, .wp-block-button__link) {
  background: var(--lvju-primary);
  border: 1px solid var(--lvju-primary);
  border-radius: var(--lvju-radius);
  color: var(--lvju-white);
  cursor: pointer;
  font-weight: 700;
  min-height: 46px;
  padding: 10px 18px;
}

.search-form .search-submit:hover,
.search-form .search-submit:focus-visible,
body.lvju-neve-production :where(button, input[type="submit"], .wp-element-button, .wp-block-button__link):hover {
  background: var(--lvju-terracotta);
  border-color: var(--lvju-terracotta);
  color: var(--lvju-white);
}

.lvju-site-footer {
  background: var(--lvju-primary);
  border-top: 4px solid var(--lvju-gold);
  color: rgba(255, 255, 255, 0.78);
}

.lvju-footer-inner {
  display: grid;
  gap: 22px;
  padding-block: 42px;
}

.lvju-footer-brand {
  color: var(--lvju-white);
  font-family: var(--lvju-heading);
  font-size: 1.22rem;
  font-weight: 700;
  margin: 0 0 8px;
}

.lvju-footer-inner p {
  font-size: 0.88rem;
  margin: 0;
  max-width: 880px;
}

.lvju-footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
}

.lvju-footer-nav a {
  color: var(--lvju-white);
  font-size: 0.88rem;
}

.lvju-footer-meta {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 18px;
}

/* Existing verified lvju.org.cn page system. */
.openlx-home,
.openlx-page {
  --brand-primary: var(--lvju-primary);
  --brand-secondary: var(--lvju-terracotta);
  --brand-accent: var(--lvju-gold);
  --brand-surface: var(--lvju-surface);
  --brand-ink: var(--lvju-ink);
  background: var(--lvju-surface);
  color: var(--lvju-ink);
  overflow-wrap: anywhere;
}

.openlx-wrap {
  margin-inline: auto;
  max-width: var(--lvju-wide);
  padding-inline: 20px;
  width: 100%;
}

.openlx-hero {
  background: var(--lvju-primary);
  color: var(--lvju-white);
  padding-block: clamp(68px, 10vw, 124px);
}

.openlx-hero-grid {
  align-items: start;
  display: grid;
  gap: clamp(30px, 5vw, 72px);
  grid-template-columns: minmax(0, 1.3fr) minmax(260px, 0.7fr);
}

.openlx-hero :where(h1, h2, h3, p) {
  color: inherit;
}

.openlx-hero h1,
.openlx-hero h2.openlx-hero-title {
  font-size: clamp(2.45rem, 5vw, 4rem);
  line-height: 1.18;
  margin: 0;
  max-width: 820px;
}

.openlx-kicker {
  color: var(--lvju-terracotta);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  margin: 0 0 14px;
  text-transform: uppercase;
}

.openlx-hero .openlx-kicker {
  color: #e7c49e;
}

.openlx-lead {
  font-size: clamp(1.04rem, 1.8vw, 1.24rem);
  line-height: 1.8;
  margin-top: 22px;
  max-width: 660px;
}

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

.openlx-btn {
  align-items: center;
  background: var(--lvju-terracotta);
  border: 1px solid var(--lvju-terracotta);
  border-radius: var(--lvju-radius);
  color: var(--lvju-white);
  display: inline-flex;
  font-weight: 700;
  justify-content: center;
  min-height: 46px;
  padding: 10px 18px;
  text-decoration: none;
}

.openlx-btn:hover,
.openlx-btn:focus-visible {
  background: var(--lvju-white);
  border-color: var(--lvju-white);
  color: var(--lvju-primary);
}

.openlx-btn-secondary {
  background: transparent;
  border-color: currentcolor;
  color: inherit;
}

.openlx-card,
.openlx-topic-card,
.openlx-doc-card,
.openlx-step,
.openlx-faq-card {
  background: var(--lvju-paper);
  border: 1px solid var(--lvju-line);
  border-radius: var(--lvju-radius);
  padding: 24px;
}

.openlx-hero .openlx-doc-card,
.openlx-hero .openlx-card {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.26);
}

/*
 * The migrated page system gives .openlx-visual a light paper background.
 * Inside this dark hero that made the inherited white card text unreadable.
 * Keep the visual shell in the hero palette so text and surface retain AA
 * contrast without changing the verified page content.
 */
.openlx-hero .openlx-visual {
  background: rgba(20, 43, 37, 0.72);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 18px 48px rgba(20, 35, 31, 0.24);
}

.openlx-hero .openlx-visual .openlx-doc-card {
  background: rgba(255, 255, 255, 0.08);
  color: var(--lvju-white);
}

.openlx-hero .openlx-doc-card :where(h2, h3, p, li),
.openlx-hero .openlx-card :where(h2, h3, p, li) {
  color: inherit;
}

.openlx-list {
  margin: 0;
  padding-left: 1.2em;
}

.openlx-list li + li {
  margin-top: 0.62em;
}

.openlx-trust-strip {
  background: var(--lvju-ink);
  color: var(--lvju-white);
  padding-block: 17px;
}

.openlx-trust-strip .openlx-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  justify-content: space-between;
}

.openlx-band {
  padding-block: clamp(56px, 7vw, 90px);
}

.openlx-band:nth-of-type(even) {
  background: var(--lvju-mist);
}

.openlx-section-head {
  margin-bottom: 34px;
  max-width: var(--lvju-content);
}

.openlx-section-head h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.65rem);
  margin: 0 0 12px;
}

.openlx-section-head p:last-child {
  color: var(--lvju-muted);
}

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

.openlx-card p,
.openlx-topic-card p,
.openlx-doc-card p,
.openlx-step p,
.openlx-faq-card p {
  color: var(--lvju-muted);
}

.openlx-card a,
.openlx-topic-card a,
.openlx-doc-card a {
  display: inline-block;
  font-weight: 700;
  margin-top: 14px;
}

.openlx-step::before {
  color: var(--lvju-terracotta);
  content: "样本边界";
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin-bottom: 14px;
}

.openlx-faq-card summary {
  color: var(--lvju-primary);
  cursor: pointer;
  font-family: var(--lvju-heading);
  font-size: 1.12rem;
  font-weight: 650;
}

.openlx-cta {
  background: var(--lvju-terracotta);
  color: var(--lvju-ink);
  padding-block: clamp(58px, 8vw, 92px);
}

.openlx-cta :where(h2, p) {
  color: inherit;
  max-width: 720px;
}

.openlx-cta .openlx-btn {
  background: var(--lvju-primary);
  border-color: var(--lvju-primary);
  color: var(--lvju-white);
}

.openlx-page > .openlx-hero + .openlx-band,
.openlx-home > .openlx-hero + .openlx-trust-strip {
  margin-top: 0;
}

.lvju-page-content :where(img) {
  height: auto;
  max-width: 100%;
}

.lvju-page-content :where(input, select, textarea) {
  background: var(--lvju-white);
  border: 1px solid var(--lvju-line);
  border-radius: var(--lvju-radius);
  color: var(--lvju-ink);
  font: inherit;
  min-height: 44px;
  padding: 10px 13px;
  width: 100%;
}

body.lvju-neve-production :focus-visible {
  outline: 3px solid var(--lvju-terracotta);
  outline-offset: 3px;
}

@media (max-width: 1080px) {
  .lvju-desktop-nav {
    display: none;
  }

  .lvju-mobile-nav {
    display: block;
    position: relative;
  }

  .lvju-mobile-nav[open] nav {
    background: var(--lvju-paper);
    border: 1px solid var(--lvju-line);
    box-shadow: var(--lvju-shadow);
    min-width: min(86vw, 360px);
    padding: 14px;
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
  }

  .lvju-menu-mobile {
    align-items: stretch;
    display: grid;
    gap: 2px;
    justify-content: stretch;
  }

  .lvju-menu-mobile a {
    min-height: 44px;
    width: 100%;
  }

  .lvju-menu-mobile .sub-menu {
    background: var(--lvju-mist);
    border: 0;
    box-shadow: none;
    display: block;
    margin: 0 0 8px 12px;
    min-width: 0;
    padding: 6px 10px;
    position: static;
  }
}

@media (max-width: 782px) {
  body.lvju-neve-production {
    font-size: 16px;
  }

  .lvju-header-inner,
  .lvju-footer-inner,
  .lvju-listing-shell,
  .lvju-reading-shell,
  .lvju-error-shell {
    width: min(100% - 28px, var(--lvju-wide));
  }

  .lvju-header-inner {
    min-height: 70px;
  }

  .lvju-brand-note {
    display: none;
  }

  .lvju-post-grid,
  .openlx-grid,
  .openlx-flow,
  .openlx-hero-grid {
    grid-template-columns: 1fr;
  }

  .openlx-wrap {
    padding-inline: 14px;
  }

  .openlx-card,
  .openlx-topic-card,
  .openlx-doc-card,
  .openlx-step,
  .openlx-faq-card {
    padding: 20px;
  }

  .search-form {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
