/* 御鑫纤美官网 · 双主题：健康绿 / 美护玫瑰 */

:root,
[data-theme="green"] {
  --ink: #14241c;
  --ink-soft: #3d5248;
  --muted: #6b7f74;
  --paper: #f3f6f2;
  --paper-deep: #e4ebe5;
  --accent: #2f6b4f;
  --accent-deep: #1e4a36;
  --accent-soft: #a8c9b5;
  --wash: rgba(47, 107, 79, 0.12);
  --hero-veil: linear-gradient(
    105deg,
    rgba(20, 36, 28, 0.78) 0%,
    rgba(20, 36, 28, 0.45) 48%,
    rgba(30, 74, 54, 0.25) 100%
  );
  --glow: rgba(47, 107, 79, 0.35);
  --nav-bg: rgba(243, 246, 242, 0.82);
  --line: rgba(20, 36, 28, 0.1);
  --footer-bg: #14241c;
  --footer-fg: #d5e3db;
  --footer-muted: #8aa396;
}

[data-theme="rose"] {
  --ink: #1c1416;
  --ink-soft: #5a4548;
  --muted: #8a7376;
  --paper: #faf6f5;
  --paper-deep: #f0e6e4;
  --accent: #a65d6c;
  --accent-deep: #7a3f4c;
  --accent-soft: #e4b8c0;
  --wash: rgba(166, 93, 108, 0.12);
  --hero-veil: linear-gradient(
    105deg,
    rgba(28, 20, 22, 0.78) 0%,
    rgba(28, 20, 22, 0.42) 48%,
    rgba(122, 63, 76, 0.28) 100%
  );
  --glow: rgba(166, 93, 108, 0.35);
  --nav-bg: rgba(250, 246, 245, 0.84);
  --line: rgba(28, 20, 22, 0.1);
  --footer-bg: #1c1416;
  --footer-fg: #f0e4e6;
  --footer-muted: #b89aa0;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-weight: 400;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.45s ease, color 0.45s ease;
}

img {
  max-width: 100%;
  display: block;
}

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

button {
  font: inherit;
  cursor: pointer;
  border: 0;
  background: none;
}

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

/* —— Nav —— */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: var(--nav-bg);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease, background 0.45s ease;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
}

.header-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0.95rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
}

.brand-mark {
  font-family: "Noto Serif SC", "Songti SC", serif;
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--ink);
}

.brand-en {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-link {
  display: none;
  padding: 0.4rem 0.75rem;
  font-size: 0.9rem;
  color: var(--ink-soft);
  transition: color 0.2s ease;
}

.nav-link:hover {
  color: var(--accent-deep);
}

@media (min-width: 720px) {
  .nav-link {
    display: inline-block;
  }
}

.theme-switch {
  display: inline-flex;
  padding: 0.2rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--paper) 70%, white);
}

.theme-switch button {
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  font-size: 0.78rem;
  color: var(--muted);
  transition: background 0.25s ease, color 0.25s ease;
}

.theme-switch button[aria-pressed="true"] {
  background: var(--accent);
  color: #fff;
}

/* —— Hero —— */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
  color: #f7faf8;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
  transform: scale(1.04);
  animation: hero-drift 18s ease-in-out infinite alternate;
}

.hero-veil {
  position: absolute;
  inset: 0;
  background: var(--hero-veil);
  transition: background 0.5s ease;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 1120px;
  width: 100%;
  margin: 0 auto;
  padding: 7.5rem 1.5rem 4.5rem;
}

.hero-brand {
  font-family: "Noto Serif SC", "Songti SC", serif;
  font-size: clamp(2.8rem, 8vw, 5.2rem);
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.05;
  margin: 0 0 1.1rem;
  opacity: 0;
  transform: translateY(18px);
  animation: rise 0.9s 0.15s ease forwards;
}

.hero-lead {
  max-width: 28rem;
  margin: 0 0 2rem;
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  font-weight: 300;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.88);
  opacity: 0;
  transform: translateY(18px);
  animation: rise 0.9s 0.35s ease forwards;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  opacity: 0;
  transform: translateY(18px);
  animation: rise 0.9s 0.55s ease forwards;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.85rem;
  padding: 0.65rem 1.35rem;
  border-radius: 2px;
  font-size: 0.92rem;
  letter-spacing: 0.06em;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease,
    border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: #fff;
  color: var(--accent-deep);
}

.btn-primary:hover {
  background: var(--paper);
}

.btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: #fff;
}

.btn-ghost:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.hero-scroll {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  z-index: 1;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  writing-mode: vertical-rl;
  opacity: 0;
  animation: fade 1s 1s ease forwards;
}

/* —— Sections —— */
.section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 5.5rem 1.5rem;
}

.section-label {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.85rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 0.85rem;
}

.section-title {
  font-family: "Noto Serif SC", "Songti SC", serif;
  font-size: clamp(1.7rem, 3.5vw, 2.35rem);
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.3;
  margin: 0 0 0.85rem;
  color: var(--ink);
}

.section-desc {
  max-width: 36rem;
  margin: 0;
  color: var(--ink-soft);
  font-size: 1rem;
}

.capabilities {
  background: linear-gradient(
    180deg,
    var(--paper) 0%,
    var(--paper-deep) 48%,
    var(--paper) 100%
  );
  transition: background 0.45s ease;
}

.cap-grid {
  display: grid;
  gap: 0;
  margin-top: 3rem;
  border-top: 1px solid var(--line);
}

.cap-item {
  display: grid;
  gap: 0.75rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--line);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.cap-item.is-in {
  opacity: 1;
  transform: none;
}

@media (min-width: 800px) {
  .cap-item {
    grid-template-columns: 4.5rem 1fr 1.4fr;
    align-items: baseline;
    gap: 1.5rem;
    padding: 1.9rem 0;
  }
}

.cap-index {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.35rem;
  letter-spacing: 0.08em;
  color: var(--accent);
}

.cap-name {
  font-family: "Noto Serif SC", serif;
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  margin: 0;
}

.cap-text {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

/* —— Experience / single-phone carousel —— */
.experience {
  background: linear-gradient(
    180deg,
    var(--paper) 0%,
    var(--paper-deep) 55%,
    var(--paper) 100%
  );
  overflow: hidden;
  transition: background 0.45s ease;
}

.experience-inner {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 880px) {
  .experience-inner {
    grid-template-columns: 1fr minmax(14rem, 17.5rem);
    gap: 3.5rem;
    padding-top: 4.5rem;
    padding-bottom: 4.5rem;
  }
}

.experience-copy .section-desc {
  margin-bottom: 1.5rem;
}

.experience-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.experience-tab {
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  background: color-mix(in srgb, var(--paper) 80%, white);
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.experience-tab:hover {
  color: var(--accent-deep);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
}

.experience-tab[aria-selected="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.experience-stage {
  display: flex;
  justify-content: center;
}

.phone-showcase {
  width: min(13.25rem, 56vw);
}

.phone-frame--stage {
  position: relative;
  border-radius: 1.35rem;
  padding: 0.42rem;
  background: linear-gradient(
    160deg,
    color-mix(in srgb, var(--ink) 88%, #fff) 0%,
    color-mix(in srgb, var(--ink) 72%, var(--accent)) 100%
  );
  box-shadow:
    0 24px 48px -20px rgba(0, 0, 0, 0.38),
    0 0 0 1px color-mix(in srgb, var(--ink) 10%, transparent);
}

.phone-frame--stage::before {
  content: "";
  position: absolute;
  top: 0.5rem;
  left: 50%;
  width: 26%;
  height: 0.26rem;
  transform: translateX(-50%);
  border-radius: 999px;
  background: color-mix(in srgb, var(--ink) 55%, #000);
  z-index: 2;
  opacity: 0.45;
  pointer-events: none;
}

.phone-slides {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  /* 与预览图 1024×1536 一致，避免 9/19.5 把机身拉成竹竿 */
  aspect-ratio: 2 / 3;
  background: #f4f4f6;
}

.phone-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: top center;
  opacity: 0;
  transition: opacity 0.45s ease;
  pointer-events: none;
}

.phone-slide.is-active {
  opacity: 1;
  z-index: 1;
}

.experience-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  margin-top: 1.15rem;
}

.experience-nav {
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 1.25rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.experience-nav:hover {
  color: var(--accent-deep);
  border-color: var(--accent);
  background: var(--wash);
}

.experience-dots {
  display: flex;
  gap: 0.4rem;
  align-items: center;
}

.experience-dot {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 999px;
  padding: 0;
  background: color-mix(in srgb, var(--muted) 45%, transparent);
  transition: width 0.25s ease, background 0.25s ease;
}

.experience-dot[aria-current="true"] {
  width: 1.15rem;
  background: var(--accent);
}

/* —— About —— */
.about-layout {
  display: grid;
  gap: 2.5rem;
  margin-top: 2.5rem;
}

@media (min-width: 860px) {
  .about-layout {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 4rem;
    align-items: start;
  }
}

.about-copy p {
  margin: 0 0 1.1rem;
  color: var(--ink-soft);
}

.about-copy p:last-child {
  margin-bottom: 0;
}

.about-panel {
  padding: 1.75rem 1.5rem;
  background: var(--wash);
  border-left: 3px solid var(--accent);
  transition: background 0.45s ease, border-color 0.45s ease;
}

.about-panel h3 {
  font-family: "Noto Serif SC", serif;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  margin: 0 0 1rem;
}

.about-meta {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.85rem;
}

.about-meta li {
  display: grid;
  gap: 0.15rem;
}

.about-meta span {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.about-meta strong {
  font-weight: 500;
  color: var(--ink);
  font-size: 0.95rem;
}

.about-meta a:hover {
  color: var(--accent-deep);
}

/* —— Contact strip —— */
.contact-strip {
  max-width: 1120px;
  margin: 0 auto 4rem;
  padding: 0 1.5rem;
}

.contact-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.75rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.contact-inner p {
  margin: 0;
  color: var(--ink-soft);
  max-width: 28rem;
}

.contact-phone {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.85rem;
  letter-spacing: 0.06em;
  color: var(--accent-deep);
}

.contact-phone:hover {
  color: var(--accent);
}

/* —— Footer —— */
.site-footer {
  background: var(--footer-bg);
  color: var(--footer-fg);
  padding: 3rem 1.5rem 2rem;
  transition: background 0.45s ease;
}

.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  gap: 2rem;
}

@media (min-width: 800px) {
  .footer-inner {
    grid-template-columns: 1.2fr 1fr;
  }
}

.footer-brand {
  font-family: "Noto Serif SC", serif;
  font-size: 1.35rem;
  letter-spacing: 0.12em;
  margin: 0 0 0.5rem;
}

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

.footer-links {
  display: grid;
  gap: 0.55rem;
  font-size: 0.9rem;
  color: var(--footer-muted);
}

.footer-links a:hover {
  color: #fff;
}

.footer-bottom {
  max-width: 1120px;
  margin: 2.25rem auto 0;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--footer-muted);
}

.footer-bottom a:hover {
  color: #fff;
}

/* —— Motion —— */
@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes fade {
  to {
    opacity: 1;
  }
}

@keyframes hero-drift {
  from {
    transform: scale(1.04) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.08) translate3d(-1.2%, -0.8%, 0);
  }
}

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

  .hero-media img,
  .hero-brand,
  .hero-lead,
  .hero-ctas,
  .hero-scroll,
  .cap-item,
  .phone-slide {
    animation: none !important;
    transform: none;
  }

  .phone-slide.is-active {
    opacity: 1;
  }

  .phone-slide:not(.is-active) {
    opacity: 0;
  }
}
