/* 基础样式、页面组件及响应式布局；保持原有层叠顺序。 */
:root {
  --ink: #14253a;
  --muted: #657184;
  --accent: #e82159;
  --pink: #fff0f3;
  --line: #eadfe4;
  --paper: #fff;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #fbf7f8;
  font: 15px/1.75 system-ui, "Microsoft YaHei", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--accent);
}

button, input {
  font: inherit;
}

button {
  cursor: pointer;
}

button, a, input {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid #527cbd;
  outline-offset: 3px;
}

.wrap {
  width: min(1320px, calc(100% - 64px));
  margin-inline: auto;
}

.header {
  background: white;
  border-bottom: 1px solid var(--line);
}

.top, .foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  line-height: 1.35;
}

.brand strong {
  font-size: 22px;
}

.brand small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .04em;
}

.accent {
  color: var(--accent);
}

nav {
  display: flex;
  gap: 26px;
  font-weight: 650;
}

.pill, button[type=submit] {
  border: 0;
  background: var(--accent);
  color: white;
  border-radius: 8px;
  padding: 10px 20px;
  font-weight: 700;
}

.pill:hover {
  color: white;
  background: #bc1644;
}

.hero {
  background: linear-gradient(105deg, #fff1f3, #ffe0e9);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  align-items: center;
  gap: 24px;
  min-height: 400px;
}

.hero-copy {
  padding-block: 32px;
  min-width: 0;
}

.eyebrow {
  color: #9e3459;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .13em;
}

h1 {
  margin: 12px 0 14px;
  font-size: clamp(25px, 3vw, 43px);
  line-height: 1.3;
  letter-spacing: -.045em;
  overflow-wrap: anywhere;
}

.subhead {
  font-size: .82em;
  letter-spacing: -.035em;
}

.hero-copy p {
  max-width: 740px;
  margin: 0 0 22px;
}

.portrait {
  width: 100%;
  height: 100%;
  max-height: 440px;
  object-fit: cover;
  object-position: center;
  border-radius: 120px 0 0 0;
  align-self: end;
}

.search {
  display: flex;
  max-width: 520px;
  background: white;
  border: 1px solid #edc9d4;
  padding: 4px;
  border-radius: 12px;
}

input {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  padding: 9px 12px;
  border-radius: 8px;
  background: white;
  color: var(--ink);
}

.search input {
  border: 0;
}

.search button {
  flex-shrink: 0;
}

.hero-notes {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  color: #84465c;
  font-size: 12px;
  margin-top: 15px;
}

.content {
  padding-block: 24px 48px;
}

.section {
  margin-bottom: 24px;
  scroll-margin-top: 20px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

h2 {
  font-size: 24px;
  line-height: 1.4;
  margin: 3px 0;
}

h3 {
  margin: 8px 0;
  font-size: 18px;
}

p {
  margin: 8px 0 12px;
}

.muted, small {
  color: var(--muted);
  font-size: 13px;
}

.filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.filters button {
  padding: 7px 15px;
  border-radius: 7px;
  background: white;
  border: 1px solid var(--line);
  color: var(--ink);
}

.filters .active {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.asset-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.asset, .guide-grid article, .panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
}

.asset[hidden] {
  display: none;
}

.asset {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.asset p {
  font-size: 13px;
  flex: 1;
}

.asset a, .insight a {
  color: var(--accent);
  font-weight: 650;
  font-size: 13px;
}

.tag {
  display: inline-block;
  align-self: flex-start;
  background: var(--pink);
  color: #a5224b;
  padding: 3px 9px;
  font-size: 12px;
  border-radius: 6px;
  white-space: nowrap;
}

.analysis-grid {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr;
  gap: 18px;
}

.analysis-grid > * {
  min-width: 0;
}

.temperature, .insight {
  background: #fff5f7;
  padding: 18px;
  border-radius: 12px;
}

label {
  display: block;
  font-size: 13px;
  margin-top: 8px;
}

.meter {
  height: 10px;
  background: #e8dce3;
  border-radius: 10px;
  overflow: hidden;
  margin-top: 20px;
}

#meter-fill {
  height: 100%;
  width: 60%;
  background: var(--accent);
}

#breadth {
  display: block;
  font-size: 30px;
  font-weight: 800;
  color: var(--accent);
}

.chart {
  padding: 8px;
}

.chart svg {
  display: block;
  width: 100%;
  height: auto;
}

.legend {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--accent);
}

.legend span + span {
  color: #527cbd;
}

.insight img {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

.calc-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 18px;
}

fieldset {
  border: 1px solid var(--line);
  border-radius: 10px;
  min-width: 0;
  padding: 14px;
}

legend {
  font-weight: 700;
}

.result {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  padding: 16px;
  background: var(--pink);
  border-radius: 12px;
}

#result {
  font-size: 19px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.guide-grid b {
  font-size: 30px;
  color: var(--accent);
}

.faq details {
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.faq details:last-child {
  border: 0;
}

summary {
  cursor: pointer;
  font-weight: 650;
}

footer {
  background: #ffe9ee;
  border-top: 1px solid var(--line);
}

.foot p {
  font-size: 13px;
}

.skip, .sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}

.skip:focus {
  position: fixed;
  width: auto;
  height: auto;
  clip-path: none;
  background: white;
  z-index: 5;
}

@media (max-width: 1050px) {
  .asset-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .analysis-grid {
    grid-template-columns: 1fr 2fr;
  }

  .insight {
    grid-column: 1 / -1;
  }

  .insight img {
    float: left;
    width: 150px;
    margin-right: 18px;
  }

  nav {
    gap: 12px;
  }

  .top > .pill {
    display: none;
  }

}

@media (max-width: 650px) {
  .wrap {
    width: calc(100% - 30px);
  }

  .top, .foot {
    flex-wrap: wrap;
    gap: 10px;
  }

  nav {
    width: 100%;
    justify-content: space-between;
    font-size: 13px;
    gap: 8px;
  }

  .hero-grid, .analysis-grid, .calc-grid, .guide-grid {
    grid-template-columns: 1fr;
  }

  .hero-grid {
    gap: 0;
  }

  .hero-copy {
    padding-block: 24px 10px;
  }

  .portrait {
    height: 270px;
    width: 100%;
    object-position: center 36%;
    border-radius: 55px 0 0 0;
  }

  .hero-notes {
    gap: 8px;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
  }

  .asset-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .asset, .panel, .guide-grid article {
    padding: 14px;
  }

  .asset h3 {
    font-size: 17px;
  }

  h2 {
    font-size: 21px;
  }

  .insight img {
    float: none;
    width: 100%;
    max-width: 230px;
  }

  .foot p {
    width: 100%;
    overflow-wrap: anywhere;
  }

}

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

}


/* 实际价格记录工具 */
.quote-form, .quote-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.quote-form label, .import-label {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.quote-form input, .import-label input {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}
.quote-form button { align-self: end; }
.quote-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-block: 18px;
}
.quote-actions > * { max-width: 100%; }
.quote-record {
  border: 1px solid #ecdde4;
  border-radius: 12px;
  padding: 14px;
  overflow-wrap: anywhere;
  min-width: 0;
}
.quote-record p { margin-block: 6px; }
@media (max-width: 900px) {
  .quote-form, .quote-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  nav { flex-wrap: wrap; }
}
@media (max-width: 650px) {
  .quote-form, .quote-list { grid-template-columns: minmax(0, 1fr); }
}
