/* ========================================
   创亿 · 品牌IP页专属样式
   参考 LINE FRIENDS：明亮角色舞台 + 黑底导航（与主站统一） + 底部快捷条
   限定在 .ip-page 作用域内，不污染全局
   ======================================== */

.ip-page {
  /* 清新绿色系（与首页统一）：以品牌玩具绿为基调，用明度做层次 */
  --ip-green-wash: #EDFBF2;   /* 大区块浅绿背景，替代原奶油黄 */
  --ip-green-soft: #E2F8EC;
  --ip-green-mid:  #C9F2DA;
  --ip-green-deep: #A9E8C5;
  --ip-heading: #1A1A24;
  --ip-body: #4A4A5A;
}

/* ---- IP 页导航覆盖：黑底白字，与主站统一 ---- */
.ip-page .site-header {
  background: #000000;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.ip-page .site-header.is-scrolled {
  background: #000000;
  box-shadow: 0 4px 20px rgba(0,0,0,0.25);
  border-bottom-color: rgba(255,255,255,0.08);
}

.ip-page .main-nav a {
  color: #FFFFFF;
  font-weight: 500;
}
.ip-page .main-nav a::after {
  background: #FFFFFF;
}
.ip-page .main-nav a:hover {
  opacity: 0.7;
  color: #FFFFFF;
}
.ip-page .main-nav a.active {
  color: #FFFFFF;
}
.ip-page .main-nav a.active::after {
  background: #FFFFFF;
}

.ip-page .mobile-menu-toggle span {
  background: #FFFFFF;
}
.ip-page .site-header.is-scrolled .mobile-menu-toggle span {
  background: #FFFFFF;
}

.ip-page .nav-cta {
  color: #FFFFFF !important;
  background: var(--brand);
  border-color: var(--brand-deep);
}
.ip-page .nav-cta:hover {
  background: var(--brand-hover);
  border-color: var(--brand-hover);
  color: #FFFFFF !important;
}

/* 移动端菜单在 IP 页保持黑底白字，与主站一致 */
@media (max-width: 768px) {
  .ip-page .main-nav {
    background: #000000;
  }
  .ip-page .main-nav a {
    color: #FFFFFF;
  }
}

/* ---- HERO：角色舞台 ---- */
.ip-hero {
  position: relative;
  min-height: 92vh;
  padding: 140px 24px 80px;
  background: var(--ip-green-wash);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ip-hero-decorations {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.ip-hero-decorations svg,
.ip-hero-blob {
  position: absolute;
}

.ip-hero-decorations svg {
  opacity: 0.85;
}

/* 背景柔光 blob：低饱和角色色，营造丰富但不乱的氛围 */
.ip-hero-blob {
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  animation: blob-drift 18s ease-in-out infinite alternate;
}
.blob-1 {
  width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(93,189,246,0.35) 0%, transparent 70%);
  top: 10%; left: -4%;
}
.blob-2 {
  width: 380px; height: 380px;
  background: radial-gradient(circle, rgba(255,217,61,0.30) 0%, transparent 70%);
  top: 28%; right: -6%;
  animation-delay: -6s;
}
.blob-3 {
  width: 260px; height: 260px;
  background: radial-gradient(circle, rgba(255,143,163,0.32) 0%, transparent 70%);
  bottom: 8%; left: 18%;
  animation-delay: -12s;
}

@keyframes blob-drift {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(24px, -18px) scale(1.08); }
}

/* 彩带方块 */
.confetti-1 { top: 18%; left: 10%; animation: float 6s ease-in-out infinite; }
.confetti-2 { top: 28%; right: 12%; animation: float 7s ease-in-out infinite 0.5s; }
.confetti-3 { bottom: 22%; left: 14%; animation: float 5.5s ease-in-out infinite 1s; }
.confetti-4 { top: 14%; left: 42%; animation: float 6.5s ease-in-out infinite 0.3s; }
.confetti-5 { bottom: 26%; right: 18%; animation: float 5.8s ease-in-out infinite 0.7s; }

/* 四角大星 */
.star-1 { top: 12%; right: 22%; animation: twinkle 4s ease-in-out infinite; }
.star-2 { bottom: 30%; right: 18%; animation: twinkle 5s ease-in-out infinite 0.8s; }
.star-3 { top: 34%; left: 18%; animation: twinkle 4.5s ease-in-out infinite 1.2s; }
.star-4 { top: 22%; left: 26%; animation: twinkle 4.2s ease-in-out infinite 0.4s; }
.star-5 { bottom: 36%; left: 10%; animation: twinkle 4.8s ease-in-out infinite 1.5s; }

/* 空心圆环 */
.ring-1 { top: 16%; left: 5%; animation: rotate-slow 22s linear infinite; }
.ring-2 { bottom: 20%; right: 10%; animation: rotate-slow 26s linear infinite reverse; }
.ring-3 { top: 46%; right: 6%; animation: rotate-slow 20s linear infinite; }

/* 螺旋线 */
.spiral-1 { top: 20%; left: 6%; animation: rotate-slow 20s linear infinite; }
.spiral-2 { bottom: 24%; right: 8%; animation: rotate-slow 24s linear infinite reverse; }
.spiral-3 { top: 40%; left: 2%; animation: rotate-slow 28s linear infinite reverse; }

/* 十字星 / 加号 */
.plus-1 { top: 24%; right: 34%; animation: twinkle 5s ease-in-out infinite 0.2s; }
.plus-2 { bottom: 32%; left: 30%; animation: twinkle 4.6s ease-in-out infinite 0.9s; }
.plus-3 { top: 44%; right: 14%; animation: twinkle 5.2s ease-in-out infinite 1.1s; }

/* 实心圆点 */
.dot-1 { top: 42%; left: 8%; animation: float 5s ease-in-out infinite; }
.dot-2 { top: 16%; left: 34%; animation: float 6s ease-in-out infinite 0.4s; }
.dot-3 { bottom: 18%; right: 28%; animation: float 5.5s ease-in-out infinite 0.8s; }
.dot-4 { top: 50%; right: 38%; animation: float 5.2s ease-in-out infinite 0.2s; }
.dot-5 { bottom: 30%; left: 22%; animation: float 6.2s ease-in-out infinite 1.1s; }

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-16px) rotate(4deg); }
}

@keyframes twinkle {
  0%, 100% { opacity: 0.6; transform: scale(0.95); }
  50% { opacity: 1; transform: scale(1.08); }
}

@keyframes rotate-slow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.ip-hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1200px;
  text-align: center;
}

.ip-hero-eyebrow {
  display: inline-block;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--brand-deep);
  margin-bottom: 16px;
}

.ip-hero h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: clamp(2.2rem, 6vw, 4.5rem);
  font-weight: 800;
  color: var(--ip-heading);
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 18px;
}

.ip-hero-lede {
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  color: var(--ip-body);
  max-width: 620px;
  margin: 0 auto 40px;
  line-height: 1.6;
}

.ip-hero-media {
  max-width: 980px;
  margin: 0 auto;
  position: relative;
}

.ip-hero-media img {
  width: 100%;
  height: auto;
  object-fit: contain;
  filter: brightness(1.08) saturate(1.05) drop-shadow(0 30px 60px rgba(0,0,0,0.08));
}

/* ---- 快捷导航条（清新绿色系，与首页统一） ---- */
.ip-quickbar {
  position: sticky;
  top: var(--header-h);
  z-index: 100;
  background: var(--brand);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.ip-quickbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.quickbar-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 16px 20px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #FFFFFF;
  transition: background 0.2s, color 0.2s;
}

.quickbar-link:hover {
  background: rgba(255,255,255,0.14);
  color: #FFFFFF;
}

.quickbar-icon {
  font-size: 1.1rem;
  line-height: 1;
}

@media (max-width: 768px) {
  .ip-quickbar-inner {
    gap: 0;
    padding: 0 12px;
  }
  .quickbar-link {
    padding: 12px 10px;
    font-size: 0.72rem;
    letter-spacing: 0;
  }
  .quickbar-icon { display: none; }
}

/* ---- 通用 IP 区块 ---- */
.ip-section {
  padding: 110px 24px;
}

.ip-section .brand-container {
  max-width: 1200px;
  margin: 0 auto;
}

.ip-eyebrow {
  display: inline-block;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--brand-deep);
  margin-bottom: 14px;
}

.ip-section h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: clamp(2rem, 4.5vw, 2.8rem);
  font-weight: 800;
  color: var(--ip-heading);
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin-bottom: 20px;
}

.ip-section p {
  font-size: 1.05rem;
  color: var(--ip-body);
  line-height: 1.75;
  margin-bottom: 18px;
}

.ip-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  background: var(--brand);
  color: #FFFFFF;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: 999px;
  transition: transform 0.2s, background 0.2s, box-shadow 0.2s;
  box-shadow: 0 8px 24px rgba(46,204,113,0.25);
}

.ip-btn-primary:hover {
  background: var(--brand-hover);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(46,204,113,0.32);
  color: #FFFFFF;
}

/* ---- 世界观区 ---- */
.ip-story {
  background: #FFFFFF;
}

.ip-story-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 80px;
  align-items: center;
}

.ip-story-text {
  max-width: 560px;
}

.ip-story-visual {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.ip-story-card {
  aspect-ratio: 1 / 1.1;
  border-radius: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  min-width: 0;
  box-shadow: 0 12px 32px rgba(0,0,0,0.06);
  transition: transform 0.3s ease;
}

.ip-story-card:hover {
  transform: translateY(-6px);
}

.ip-story-card-green { background: linear-gradient(145deg, #E8F9EF 0%, #D4F5E0 100%); }
.ip-story-card-yellow { background: linear-gradient(145deg, #E2F8EC 0%, #C9F2DA 100%); }
.ip-story-card-pink { background: linear-gradient(145deg, #C9F2DA 0%, #A9E8C5 100%); }

.story-number {
  font-family: 'Montserrat', sans-serif;
  font-size: 3.2rem;
  font-weight: 800;
  color: var(--ip-heading);
  line-height: 1;
  margin-bottom: 10px;
}

.story-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ip-body);
  letter-spacing: 0.5px;
}

@media (max-width: 1024px) {
  .ip-story-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .ip-story-visual {
    max-width: 480px;
    margin: 0 auto;
  }
}

/* ---- 角色介绍区 ---- */
.ip-characters {
  background: var(--ip-green-wash);
  /* 角色图真实像素比例（1920×1103）：容器必须与之完全一致，
     否则 object-fit:contain 会在图片上下留出透明空白，导致图片与右侧文字块视觉上错位 */
  --character-img-ratio: 1920 / 1103;
}

/* 标题段与下方角色行共享父容器中线：标题块最大宽 720px + 居中 */
.ip-characters .section-header {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 48px;
}

/* 副标题必须与标题共用同一条中线：
   style.css 的 .section-header p 是 margin:0（为首页左对齐版块而设），
   在 720px 的 header 内会贴左，导致小字中心比大标题左偏 (720-540)/2 = 90px */
.ip-characters .section-header p {
  margin-left: auto;
  margin-right: auto;
}

.ip-character-list {
  display: flex;
  flex-direction: column;
  gap: 72px;
}

.ip-character-row {
  --character-color: var(--brand-deep);
}

.ip-character-row-inner {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 64px;
  align-items: center;
}

/* 偶数行：图文左右翻转 */
.ip-character-row:nth-child(even) .ip-character-row-inner {
  direction: rtl;
}
.ip-character-row:nth-child(even) .ip-character-row-inner > * {
  direction: ltr;
}

.ip-character-visual {
  position: relative;
  /* 容器退为透明承载块：图片本身就是完整卡片（自带标题/角色立绘/胶囊/信息面板），无需 CSS 容器背景/圆角/padding */
  display: flex;
  align-items: center;
  justify-content: center;
  /* 与图片真实比例一致 → 图片填满容器、上下零留白，与右侧文字块等高对齐 */
  aspect-ratio: var(--character-img-ratio);
}

.ip-character-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  /* 图片本身就是完整卡片素材：轻浮起阴影让白底图片与浅绿区背景之间有"成型感"，避免硬接 */
  filter: drop-shadow(0 14px 36px rgba(15, 50, 30, 0.10));
  transition: transform 0.5s ease;
}

.ip-character-row:hover .ip-character-visual img {
  transform: scale(1.03);
}

.ip-character-profile {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.ip-character-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 6px;
}

.ip-character-number {
  font-family: 'Montserrat', sans-serif;
  font-size: 4.5rem;
  font-weight: 800;
  line-height: 1;
  color: rgba(0,0,0,0.08);
  letter-spacing: -2px;
}

.ip-character-badge {
  padding: 7px 16px;
  border-radius: 999px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #FFFFFF;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.ip-character-name {
  font-family: 'Montserrat', sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--ip-heading);
  line-height: 1.15;
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 14px;
}

.ip-character-name .ip-character-en {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--body-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

.ip-character-desc {
  font-size: 1.05rem;
  color: var(--ip-body);
  line-height: 1.8;
  margin: 0;
  max-width: 520px;
}

.ip-character-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 8px;
}

.ip-character-info-box {
  background: rgba(255,255,255,0.52);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.03);
  border: 1px solid rgba(255,255,255,0.7);
  border-top: 3px solid var(--character-color);
}

.info-box-label {
  display: block;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--character-color);
  margin-bottom: 10px;
}

.ip-character-info-box p {
  font-size: 0.95rem;
  color: var(--ip-body);
  line-height: 1.65;
  margin: 0;
}

@media (max-width: 1024px) {
  .ip-character-row-inner {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .ip-character-row:nth-child(even) .ip-character-row-inner {
    direction: ltr;
  }
  .ip-character-visual {
    aspect-ratio: var(--character-img-ratio);
    max-width: 720px;
    margin: 0 auto;
    width: 100%;
  }
  .ip-character-profile {
    max-width: 720px;
    margin: 0 auto;
    width: 100%;
  }
  .ip-character-number {
    font-size: 3.4rem;
  }
  .ip-character-name {
    font-size: 1.8rem;
  }
}

@media (max-width: 480px) {
  .ip-character-list {
    gap: 56px;
  }
  .ip-character-info-grid {
    grid-template-columns: 1fr;
  }
  .ip-character-visual {
    aspect-ratio: var(--character-img-ratio);
    max-width: 720px;
    margin: 0 auto;
    width: 100%;
  }
  .ip-character-name {
    font-size: 1.5rem;
    flex-wrap: wrap;
    gap: 8px;
  }
  .ip-character-desc {
    font-size: 0.98rem;
  }
  .ip-story-visual { grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .ip-story-card { padding: 14px 6px; }
  .story-number { font-size: 1.8rem; }
  .story-label { font-size: 0.62rem; letter-spacing: 0; }
}

/* ---- IP 产品联动区 ---- */
.ip-products {
  background: var(--ip-green-wash);
}

.ip-products-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 80px;
  align-items: center;
}

.ip-products-text {
  max-width: 520px;
}

.ip-products-showcase {
  position: relative;
  border-radius: 28px;
  overflow: hidden;
  background: #FFFFFF;
  padding: 16px;
  box-shadow: 0 24px 70px rgba(0,0,0,0.10);
  border: 1px solid var(--ip-border);
}

.ip-products-showcase img {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 18px;
  display: block;
}

.ip-products-badge {
  position: absolute;
  bottom: 36px;
  left: 40px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  background: #FFFFFF;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ip-heading);
  box-shadow: 0 8px 24px rgba(0,0,0,0.10);
}

.badge-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

/* ---- 底部角色带（参考 LINE FRIENDS） ---- */
.ip-footer-band {
  position: relative;
  background: var(--ip-green-wash);
  padding: 72px 24px 0;
  overflow: hidden;
}

.ip-footer-band-decorations {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.ip-footer-band-decorations svg {
  position: absolute;
  opacity: 0.55;
}

.band-star-1 { top: 18%; left: 8%; animation: twinkle 4s ease-in-out infinite; }
.band-star-2 { top: 24%; right: 10%; animation: twinkle 5s ease-in-out infinite 0.8s; }
.band-star-3 { bottom: 34%; left: 14%; animation: twinkle 4.5s ease-in-out infinite 1.2s; }
.band-confetti-1 { top: 16%; right: 18%; animation: float 6s ease-in-out infinite; }
.band-confetti-2 { bottom: 38%; right: 22%; animation: float 5.5s ease-in-out infinite 0.6s; }
.band-ring { bottom: 28%; left: 6%; animation: rotate-slow 24s linear infinite; }
.band-dot-1 { top: 30%; left: 26%; animation: float 5.5s ease-in-out infinite 0.3s; }
.band-dot-2 { top: 20%; right: 30%; animation: float 6s ease-in-out infinite 0.9s; }
.band-dot-3 { bottom: 42%; left: 34%; animation: float 5s ease-in-out infinite 1.1s; }

.ip-footer-band-inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.ip-footer-band-inner img {
  width: 100%;
  max-width: 1080px;
  height: auto;
  display: block;
  margin-bottom: -2px; /* 与深色页脚无缝衔接 */
  filter: brightness(1.08) saturate(1.05);
}

@media (max-width: 1024px) {
  .ip-products-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .ip-footer-band {
    padding-top: 48px;
  }
  .ip-footer-band-decorations svg {
    transform: scale(0.75);
  }
}

/* ---- 滚动揭示动画 ---- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .ip-hero-decorations svg {
    animation: none;
  }
  .ip-character-row:hover,
  .ip-story-card:hover,
  .ip-btn-primary:hover {
    transform: none;
  }
}
