/* ==========================================================================
   星空入口官网 style.css
   Sustainable Entertainment Operations Center + Carbon Intelligence Lab + ESG Data Platform
   ========================================================================== */

:root {
  --navy-950: #060f1f;
  --navy-900: #0a1a33;
  --navy-800: #102542;
  --navy-700: #17335a;
  --navy-600: #1f4576;
  --green-600: #146348;
  --green-500: #1a8f63;
  --green-400: #2fb47f;
  --cyan-600: #0f6b78;
  --cyan-500: #159cae;
  --cyan-400: #4dc2d3;
  --orange-500: #d98a3d;
  --orange-400: #e8a866;
  --white: #ffffff;
  --gray-50: #f6f8fa;
  --gray-100: #edf1f5;
  --gray-200: #dde3ea;
  --gray-300: #c3ccd6;
  --gray-500: #6c7787;
  --gray-600: #4c5666;
  --gray-700: #333d4c;
  --gray-900: #171e29;
  --text: #182231;
  --text-muted: #566170;
  --text-on-dark: #eaf1fb;
  --text-on-dark-muted: #a9bbd4;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow-card: 0 1px 2px rgba(10, 26, 51, 0.06), 0 8px 24px rgba(10, 26, 51, 0.06);
  --shadow-pop: 0 12px 40px rgba(10, 26, 51, 0.18);
  --maxw: 1160px;
  --font-sans: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Courier New", monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--white);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; }
li { list-style: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
button { font-family: inherit; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  min-width: 0;
}

/* Prevent grid/flex children's intrinsic min-content width from forcing
   horizontal overflow on narrow viewports (classic 1fr / flex min-width:auto issue). */
.hero-grid, .card-grid, .card-grid.cols-2, .observe-grid, .console-grid,
.feature-grid, .footer-grid, .two-col, .matrix {
  min-width: 0;
}
.hero-grid > *, .card-grid > *, .observe-grid > *, .console-grid > *,
.feature-grid > *, .footer-grid > *, .two-col > * {
  min-width: 0;
}
.console-tile { min-width: 0; }
.console-tile .k, .console-tile .v { min-width: 0; overflow-wrap: break-word; }
.console-tile.console-wide { flex-wrap: wrap; row-gap: 4px; }

/* ---------------- Header / Nav ---------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 26, 51, 0.96);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.nav {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-on-dark);
  font-weight: 700;
  font-size: 17px;
  flex-shrink: 0;
}
.brand img { width: 30px; height: 30px; }
.brand .brand-sub {
  display: block;
  font-size: 11px;
  font-weight: 400;
  color: var(--text-on-dark-muted);
  letter-spacing: 0.02em;
}
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius-sm);
  width: 40px;
  height: 40px;
  color: var(--text-on-dark);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.nav-list a {
  display: inline-block;
  padding: 8px 11px;
  font-size: 13.5px;
  color: var(--text-on-dark-muted);
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: color .15s, background .15s;
}
.nav-list a:hover,
.nav-list a[aria-current="page"] {
  color: var(--white);
  background: rgba(47, 180, 127, 0.16);
}

@media (max-width: 1024px) {
  .nav-toggle { display: inline-flex; }
  .nav-list {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: var(--navy-900);
    flex-direction: column;
    align-items: stretch;
    padding: 8px 16px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: none;
  }
  .nav-list.is-open { display: flex; }
  .nav-list a { padding: 12px 10px; font-size: 15px; }
}

/* ---------------- Hero ---------------- */
.hero {
  background:
    radial-gradient(1100px 480px at 82% -10%, rgba(47, 180, 127, 0.20), transparent 60%),
    radial-gradient(900px 460px at 5% 110%, rgba(21, 156, 174, 0.20), transparent 60%),
    linear-gradient(160deg, var(--navy-950), var(--navy-800));
  color: var(--text-on-dark);
  padding: 64px 0 56px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  letter-spacing: 0.06em;
  color: var(--green-400);
  background: rgba(47, 180, 127, 0.12);
  border: 1px solid rgba(47, 180, 127, 0.3);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.hero h1 {
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.28;
  margin-bottom: 18px;
}
.hero-lead {
  font-size: 17px;
  color: var(--text-on-dark);
  margin-bottom: 14px;
  max-width: 56ch;
}
.hero-sub {
  font-size: 14.5px;
  color: var(--text-on-dark-muted);
  max-width: 62ch;
  margin-bottom: 26px;
}
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 11px 20px;
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .12s, box-shadow .12s, background .12s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: linear-gradient(135deg, var(--green-500), var(--cyan-500));
  color: var(--white);
  box-shadow: 0 10px 24px rgba(21, 156, 174, 0.28);
}
.btn-ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-on-dark);
  border-color: rgba(255, 255, 255, 0.22);
}
.hero-visual {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: 18px;
}
.hero-visual figcaption {
  font-size: 11.5px;
  color: var(--text-on-dark-muted);
  margin-top: 10px;
  text-align: center;
}
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
}

/* ---------------- Section scaffolding ---------------- */
.section { padding: 56px 0; }
.section-alt { background: var(--gray-50); }
.section-dark {
  background: linear-gradient(160deg, var(--navy-900), var(--navy-700));
  color: var(--text-on-dark);
}
.section-head { max-width: 760px; margin-bottom: 34px; }
.section-tag {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--green-600);
  text-transform: uppercase;
  margin-bottom: 10px;
}
.section-dark .section-tag { color: var(--green-400); }
.section h2 {
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.35;
  margin-bottom: 12px;
}
.section-desc { color: var(--text-muted); font-size: 15px; }
.section-dark .section-desc { color: var(--text-on-dark-muted); }

/* ---------------- Article blocks (primary SEO content) ---------------- */
.article-list { display: flex; flex-direction: column; gap: 40px; min-width: 0; }
.article-list > * { min-width: 0; }
.article {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 32px clamp(20px, 4vw, 40px);
  box-shadow: var(--shadow-card);
}
.article-meta {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 12.5px;
  color: var(--green-600);
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.article-meta .dot { width: 4px; height: 4px; border-radius: 50%; background: var(--gray-300); }
.article-meta .len { color: var(--gray-500); font-weight: 500; text-transform: none; }
.article h3 {
  font-size: clamp(19px, 2.4vw, 24px);
  line-height: 1.45;
  margin-bottom: 16px;
  color: var(--navy-900);
}
.article .figure { margin: 20px 0; border-radius: var(--radius-md); overflow: hidden; border: 1px solid var(--gray-200); background: var(--gray-50); }
.article .figure img { width: 100%; }
.article .figure figcaption { font-size: 12.5px; color: var(--text-muted); padding: 10px 14px; border-top: 1px solid var(--gray-200); }
.article-body p { color: var(--text); font-size: 15.5px; }
.article-body strong { color: var(--navy-900); }
.article-body h4 { font-size: 15.5px; margin: 20px 0 8px; color: var(--navy-800); }
.sim-note {
  font-size: 12.5px;
  color: var(--gray-500);
  background: var(--gray-50);
  border-left: 3px solid var(--orange-500);
  padding: 8px 12px;
  border-radius: 4px;
  margin: 14px 0;
}
.inline-links { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--gray-200); font-size: 14px; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.inline-links a { color: var(--cyan-600); font-weight: 600; }
.inline-links a:hover { text-decoration: underline; }

/* ---------------- Observation column ---------------- */
.observe-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.observe-card {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 22px;
}
.observe-card h3 { font-size: 16.5px; color: var(--navy-900); margin-bottom: 10px; line-height: 1.5; }
.observe-card p { font-size: 14px; color: var(--text-muted); }
@media (max-width: 900px) { .observe-grid { grid-template-columns: 1fr; } }

/* ---------------- Card grid (summaries / topic回流) ---------------- */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.summary-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 22px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.summary-card .cat { font-size: 11.5px; font-weight: 700; color: var(--cyan-600); text-transform: uppercase; letter-spacing: 0.04em; }
.summary-card h4 { font-size: 15.5px; line-height: 1.5; color: var(--navy-900); }
.summary-card p { font-size: 13.5px; color: var(--text-muted); flex: 1; }
.summary-card .read-more { font-size: 13px; font-weight: 600; color: var(--green-600); }
@media (max-width: 900px) { .card-grid, .card-grid.cols-2 { grid-template-columns: 1fr; } }

/* ---------------- Section-flow diagram (text pipeline) ---------------- */
.flow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 18px 0;
}
.flow .step {
  background: var(--navy-800);
  color: var(--text-on-dark);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
}
.flow .arrow { color: var(--gray-400); font-size: 15px; }
.section-dark .flow .step { background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.14); }

/* ---------------- Tabs (Scope 1/2/3, Ex-ante/Ex-post, Cinema zones, App views) ---------------- */
.tabs { margin: 20px 0; }
.tab-list { display: flex; gap: 8px; flex-wrap: wrap; border-bottom: 1px solid var(--gray-200); margin-bottom: 18px; }
.tab-btn {
  background: none;
  border: none;
  padding: 10px 4px;
  margin-right: 18px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--gray-500);
  border-bottom: 2px solid transparent;
  cursor: pointer;
}
.tab-btn.is-active { color: var(--navy-900); border-bottom-color: var(--green-500); }
.tab-panel { display: none; }
.tab-panel.is-active { display: block; }

/* ---------------- Tables ---------------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--gray-200); border-radius: var(--radius-md); min-width: 0; }
table { width: 100%; border-collapse: collapse; min-width: 560px; font-size: 13.5px; }
th, td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--gray-200); vertical-align: top; }
th { background: var(--gray-50); font-size: 12px; text-transform: uppercase; letter-spacing: 0.03em; color: var(--gray-600); }
tr:last-child td { border-bottom: none; }

/* ---------------- Badges (data quality) ---------------- */
.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; letter-spacing: 0.02em; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; }
.badge-measured { background: rgba(26,143,99,0.12); color: var(--green-600); }
.badge-measured::before { background: var(--green-500); }
.badge-calculated { background: rgba(21,156,174,0.12); color: var(--cyan-600); }
.badge-calculated::before { background: var(--cyan-500); }
.badge-estimated { background: rgba(217,138,61,0.14); color: #a3611f; }
.badge-estimated::before { background: var(--orange-500); }
.badge-sampled { background: rgba(108,119,135,0.14); color: var(--gray-600); }
.badge-sampled::before { background: var(--gray-500); }
.badge-missing { background: rgba(200,60,60,0.1); color: #b23a3a; }
.badge-missing::before { background: #c83c3c; }

/* ---------------- Lineage chain ---------------- */
.lineage { border: 1px solid var(--gray-200); border-radius: var(--radius-md); overflow: hidden; }
.lineage-row { border-bottom: 1px solid var(--gray-200); }
.lineage-row:last-child { border-bottom: none; }
.lineage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  background: var(--white);
  border: none;
  padding: 14px 18px;
  cursor: pointer;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--navy-900);
  text-align: left;
}
.lineage-head:hover { background: var(--gray-50); }
.lineage-head .chev { transition: transform .15s; color: var(--gray-500); }
.lineage-row.is-open .chev { transform: rotate(180deg); }
.lineage-body { display: none; padding: 0 18px 16px; }
.lineage-row.is-open .lineage-body { display: block; }
.lineage-chain-steps { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 13px; color: var(--text-muted); }
.lineage-chain-steps b { color: var(--navy-800); }

/* ---------------- Materiality matrix ---------------- */
.matrix-wrap { display: grid; grid-template-columns: 40px 1fr; gap: 0; }
.matrix-yaxis { display: flex; align-items: center; justify-content: center; writing-mode: vertical-rl; transform: rotate(180deg); font-size: 12px; color: var(--gray-600); font-weight: 700; }
.matrix { display: grid; grid-template-columns: repeat(4, 1fr); grid-template-rows: repeat(3, 90px); gap: 6px; }
.matrix-cell { background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: 8px; padding: 8px; font-size: 11.5px; display: flex; flex-wrap: wrap; align-content: flex-start; gap: 4px; }
.matrix-cell.hot { background: rgba(217,138,61,0.10); border-color: rgba(217,138,61,0.3); }
.matrix-tag { background: var(--white); border: 1px solid var(--gray-200); padding: 2px 7px; border-radius: 999px; font-size: 11px; color: var(--navy-800); }
.matrix-xaxis { grid-column: 2; text-align: center; font-size: 12px; color: var(--gray-600); font-weight: 700; margin-top: 6px; }

/* ---------------- FAQ ---------------- */
.faq-list { border-top: 1px solid var(--gray-200); }
.faq-item { border-bottom: 1px solid var(--gray-200); }
.faq-q {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 16px 4px;
  font-size: 15px;
  font-weight: 600;
  color: var(--navy-900);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
}
.faq-q .plus { flex-shrink: 0; color: var(--green-600); font-size: 18px; transition: transform .15s; }
.faq-item.is-open .plus { transform: rotate(45deg); }
.faq-a { display: none; padding: 0 4px 18px; font-size: 14px; color: var(--text-muted); max-width: 74ch; }
.faq-item.is-open .faq-a { display: block; }

/* ---------------- Simulated device / dashboard console ---------------- */
.console {
  background: var(--navy-950);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255,255,255,0.08);
  padding: 20px;
  color: var(--text-on-dark);
}
.console-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.console-tile { background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); border-radius: 10px; padding: 12px; }
.console-tile .k { font-size: 10.5px; color: var(--text-on-dark-muted); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 6px; }
.console-tile .v { font-size: 15px; font-weight: 700; }
.console-tile .v.green { color: var(--green-400); }
.console-tile .v.cyan { color: var(--cyan-400); }
.console-tile .v.orange { color: var(--orange-400); }
.console-tile.console-wide { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.console-note { font-size: 11.5px; color: var(--text-on-dark-muted); margin-top: 12px; }
@media (max-width: 700px) { .console-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 420px) { .console-grid { grid-template-columns: 1fr; } }

/* ---------------- Zone / scenario switcher (cinema, app) ---------------- */
.switcher { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.switcher button {
  background: var(--white);
  border: 1px solid var(--gray-300);
  border-radius: 999px;
  padding: 7px 15px;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-600);
  cursor: pointer;
}
.switcher button.is-active { background: var(--navy-900); border-color: var(--navy-900); color: var(--white); }
.scenario-panel { display: none; }
.scenario-panel.is-active { display: block; }

/* ---------------- App feature grid ---------------- */
.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.feature-tile { background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius-md); padding: 18px; box-shadow: var(--shadow-card); }
.feature-tile .num { font-size: 12px; font-weight: 700; color: var(--cyan-600); margin-bottom: 6px; }
.feature-tile h4 { font-size: 14.5px; color: var(--navy-900); margin-bottom: 6px; }
.feature-tile p { font-size: 12.5px; color: var(--text-muted); }
@media (max-width: 900px) { .feature-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .feature-grid { grid-template-columns: 1fr; } }

/* ---------------- About / company ---------------- */
.about-box {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 30px clamp(20px, 4vw, 40px);
}
.about-box h2 { font-size: 20px; margin-bottom: 14px; color: var(--navy-900); }
.about-box p { font-size: 14.5px; color: var(--text-muted); }

/* ---------------- Notice / disclaimer strip ---------------- */
.notice {
  background: rgba(217,138,61,0.08);
  border: 1px solid rgba(217,138,61,0.28);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  font-size: 13.5px;
  color: #7a4c1c;
}
.notice strong { color: #5c3813; }

/* ---------------- Breadcrumb ---------------- */
.breadcrumb { font-size: 12.5px; color: var(--gray-500); padding: 16px 0 0; }
.breadcrumb a { color: var(--gray-600); }
.breadcrumb a:hover { color: var(--green-600); }
.breadcrumb span { margin: 0 6px; color: var(--gray-300); }

/* ---------------- Footer ---------------- */
.site-footer {
  background: var(--navy-950);
  color: var(--text-on-dark-muted);
  padding: 48px 0 26px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 28px;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-brand { display: flex; align-items: center; gap: 10px; color: var(--white); font-weight: 700; font-size: 16px; margin-bottom: 10px; }
.footer-brand img { width: 26px; height: 26px; }
.footer-col h5 { color: var(--white); font-size: 13px; margin-bottom: 12px; letter-spacing: 0.02em; }
.footer-col ul { display: flex; flex-direction: column; gap: 8px; }
.footer-col a { font-size: 13px; }
.footer-col a:hover { color: var(--white); }
.footer-desc { font-size: 13px; max-width: 46ch; line-height: 1.7; }
.footer-bottom {
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  justify-content: space-between;
  font-size: 12px;
  color: var(--gray-500);
}
.icp-slot { color: var(--gray-500); }
@media (max-width: 900px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------------- Back to top ---------------- */
.back-top {
  position: fixed;
  right: 20px;
  bottom: 22px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--navy-900);
  color: var(--white);
  border: none;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-pop);
  z-index: 90;
}
.back-top.is-visible { display: flex; }

/* ---------------- Misc utility ---------------- */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }
.pill-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.pill { background: var(--gray-100); color: var(--gray-700); font-size: 12px; padding: 5px 11px; border-radius: 999px; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 800px) { .two-col { grid-template-columns: 1fr; } }
.divider { height: 1px; background: var(--gray-200); margin: 40px 0; border: none; }
