/* ============================================================
   云创业 页面（理财项目列表）
   设计稿尺寸：375 × 1827（PC 端居中宽 480）
   响应式：1rem = min(100vw, 480px) / 37.5
   ============================================================ */

html {
    font-size: calc(min(100vw, 480px) / 37.5);
}

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

html,
body {
    margin: 0;
    padding: 0;
    background: #f4f4f4;
}

body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    font-family: "PingFang SC", "Noto Sans SC", "Microsoft YaHei", Arial, sans-serif;
    color: #333;
}

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

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

/* ===== Phone 容器：纯红底，由 hero 图自身完成顶部装饰
       （原 bg-yc.jpg 顶部带一条棕红色色带，跟新版 hero 不匹配，会被肉眼看成"黑边"） ===== */
.phone {
    position: relative;
    width: 37.5rem;
    min-height: 182.7rem;
    padding-bottom: 6.5rem;          /* 底部 tabbar 高度 */
    background-color: #c10408;       /* 取自新 hero 图的纯红色 */
}

/* ===== 顶部 Hero：清晰版 PNG（盖在背景图的 hero 之上） ===== */
.yc-hero {
    position: relative;
    width: 100%;
    line-height: 0;
    z-index: 1;
}

.yc-hero__img {
    display: block;
    width: 100%;
    height: auto;            /* 1024:603 ≈ 1.70 */
    user-select: none;
    -webkit-user-drag: none;
}

/* ===== 创业投资金余额卡：Figma 1:1 模板（已抹掉 ¥0.00）+ 动态金额叠加 ===== */
.yc-balance {
    position: relative;
    margin: 1.4rem 1.2rem 0;
    border-radius: 1rem;
    overflow: hidden;
    line-height: 0;
    box-shadow: 0 0.6rem 1.4rem rgba(120, 0, 0, 0.22),
                0 0.2rem 0.4rem rgba(80, 0, 0, 0.12);
}

.yc-balance__img {
    display: block;
    width: 100%;
    height: auto;            /* 新版图片自然比例 605:231 ≈ 2.62 */
    user-select: none;
    -webkit-user-drag: none;
}

/* balance.png 自带左上角“创业金”字样，这里用同色渐变遮罩后改为“创业投资金” */
.yc-balance__title {
    position: absolute;
    left: 0;
    top: 0;
    width: 11.5rem;
    height: 3.4rem;
    display: flex;
    align-items: center;
    padding: 0.25rem 0 0 0.4rem;
    box-sizing: border-box;
    background: linear-gradient(90deg, #fff 0%, #fff7f7 55%, rgba(255, 247, 247, 0) 100%);
    color: #d8131c;
    font-size: 1.55rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.02rem;
    z-index: 2;
}

/* ¥XXXX 金额文字（与"余额"左对齐：像素扫描确认 x=41, y=143） */
.yc-balance__amount {
    position: absolute;
    left: 6.8%;             /* 41/605 ≈ 6.8% */
    top: 60.5%;             /* 140/231 ≈ 60.5%（略上移 3px 让 ¥ 顶部对齐） */
    color: #fff;
    font-size: 1.9rem;      /* 字符高 28px / 231 * 实际高度 → ≈ 1.9rem */
    font-weight: 700;
    letter-spacing: 0;
    line-height: 1;
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    text-shadow: 0 0.1rem 0.2rem rgba(80, 0, 0, 0.35);
    white-space: nowrap;
    pointer-events: none;
}

/* ===== 创业投资金说明 + 流水入口（独立于余额卡的浅色信息条） ===== */
.yc-info {
    margin: 0.8rem 1.2rem 0;
    padding: 0.9rem 1.1rem 0.9rem 1rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 250, 240, 0.95));
    border: 0.05rem solid rgba(255, 200, 130, 0.7);
    border-radius: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    box-shadow: 0 0.3rem 0.7rem rgba(120, 0, 0, 0.1);
}
.yc-info__icon {
    flex: 0 0 2.4rem;
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 50%;
    background: linear-gradient(135deg, #ffb13a, #e58410);
    color: #fff;
    font-size: 1.4rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: serif;
}
.yc-info__text {
    flex: 1;
    min-width: 0;
    color: #6b3a0d;
    font-size: 1.15rem;
    line-height: 1.5;
    letter-spacing: 0.02rem;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.3rem;
}
.yc-info__text b {
    color: #d8131c;
    font-weight: 800;
    font-size: 1.25rem;
    margin: 0 0.1rem;
}
.yc-info__sep {
    color: #c9a96a;
    margin: 0 0.4rem;
}
.yc-info__count {
    color: #b14406;
    font-size: 1.05rem;
    margin-left: 0.4rem;
    padding: 0.05rem 0.5rem;
    background: #fff7e6;
    border-radius: 0.8rem;
    border: 0.05rem solid #f3d8a5;
}
.yc-info__count b {
    font-size: 1.1rem;
    color: #d8131c;
}
.yc-info__link {
    flex: 0 0 auto;
    height: 2.6rem;
    padding: 0 1rem;
    border-radius: 1.3rem;
    background: linear-gradient(180deg, #ea1c25, #ad0810);
    color: #fff;
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.05rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 0.2rem 0.5rem rgba(180, 10, 16, 0.3);
    white-space: nowrap;
}
.yc-info__link:active {
    transform: translateY(0.05rem);
}

/* 累计分红行（绿色风格区分） */
.yc-info--dividend {
    margin-top: 0.6rem;
    border-color: rgba(108, 188, 105, 0.55);
    background: linear-gradient(180deg, #f3fbef 0%, #ffffff 100%);
}
.yc-info__icon--green {
    background: linear-gradient(135deg, #4ec47b, #1f9c50);
}
.yc-info__count--green {
    background: #ecf8ec;
    border-color: #b5dcb6;
    color: #1f7a2c;
}
.yc-info__count--green b {
    color: #1f7a2c;
}
.yc-info--dividend .yc-info__text { color: #235b2c; }
.yc-info--dividend .yc-info__text b { color: #1f7a2c; }
.yc-info__link--green {
    background: linear-gradient(180deg, #36b364, #1d7a3a);
}

/* ===== 项目卡片 ===== */
.yc-card {
    position: relative;
    margin: 1.6rem 1.2rem 0;
    background: #fff;
    border-radius: 1.2rem;
    overflow: hidden;
    box-shadow: 0 0.8rem 1.8rem rgba(110, 0, 0, 0.18),
                0 0.2rem 0.4rem rgba(0, 0, 0, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.yc-card:hover {
    transform: translateY(-0.2rem);
    box-shadow: 0 1.1rem 2.2rem rgba(110, 0, 0, 0.22),
                0 0.2rem 0.4rem rgba(0, 0, 0, 0.08);
}

.yc-card:active {
    transform: translateY(0);
    box-shadow: 0 0.5rem 1.2rem rgba(110, 0, 0, 0.18),
                0 0.2rem 0.4rem rgba(0, 0, 0, 0.06);
}

.yc-card:last-of-type {
    margin-bottom: 2rem;
}

.yc-card__cover {
    position: relative;
    width: 100%;
    aspect-ratio: 351 / 130;
    background: linear-gradient(135deg, #f4c987 0%, #d68b30 60%, #8a4d0e 100%);
    /* 不开 overflow:hidden，让 badge 能跨越 cover/body 边界 */
}

.yc-card__cover > svg,
.yc-card__cover > img:not(.yc-card__badge-img) {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 1rem 1rem 0 0;
}

.yc-card__cover-title {
    position: absolute;
    left: 1.2rem;
    right: 1.2rem;
    top: 1rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.65rem 0.9rem;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(92, 37, 0, 0.78), rgba(176, 86, 8, 0.35));
    color: #fff;
    box-shadow: 0 0.35rem 0.8rem rgba(75, 20, 0, 0.24);
    backdrop-filter: blur(0.3rem);
    z-index: 2;
}

.yc-card__cover-title--energy {
    background: linear-gradient(90deg, rgba(15, 91, 54, 0.86), rgba(53, 174, 86, 0.34));
}

.yc-card__cover-title--cloud {
    background: linear-gradient(90deg, rgba(24, 60, 139, 0.86), rgba(70, 154, 255, 0.34));
}

.yc-card__cover-title--ai {
    background: linear-gradient(90deg, rgba(72, 35, 129, 0.86), rgba(200, 92, 255, 0.34));
}

.yc-card__cover-title--aviation {
    background: linear-gradient(90deg, rgba(91, 60, 10, 0.88), rgba(229, 160, 45, 0.34));
}

.yc-card__cover-title--upcoming {
    background: linear-gradient(90deg, rgba(132, 13, 19, 0.88), rgba(255, 183, 64, 0.3));
}

.yc-card__logo-mark {
    flex: 0 0 3rem;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #fff4bd, #e89b26);
    color: #9b1b08;
    font-size: 1.15rem;
    font-weight: 900;
    letter-spacing: 0;
    box-shadow: inset 0 0.1rem 0.25rem rgba(255, 255, 255, 0.65),
                0 0.2rem 0.5rem rgba(75, 20, 0, 0.22);
}

.yc-card__cover-title--energy .yc-card__logo-mark {
    background: linear-gradient(135deg, #e8fff1, #74e08d);
    color: #0e6b37;
}

.yc-card__cover-title--cloud .yc-card__logo-mark {
    background: linear-gradient(135deg, #eef7ff, #76c8ff);
    color: #174f9f;
}

.yc-card__cover-title--ai .yc-card__logo-mark {
    background: linear-gradient(135deg, #fff2ff, #d99aff);
    color: #6f23a6;
}

.yc-card__cover-title--aviation .yc-card__logo-mark {
    background: linear-gradient(135deg, #fff7d1, #f1ba44);
    color: #8b4b08;
}

.yc-card__cover-title--upcoming .yc-card__logo-mark {
    background: linear-gradient(135deg, #fff1cf, #ffb84a);
    color: #b70f19;
}

.yc-card__cover-text {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
}

.yc-card__logo-label {
    color: rgba(255, 246, 211, 0.9);
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.14rem;
}

.yc-card__cover-name {
    min-width: 0;
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: 0.04rem;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-shadow: 0 0.12rem 0.24rem rgba(80, 20, 0, 0.35);
}

/* "精选理财" 徽章（图片版） */
.yc-card__badge-img {
    position: absolute;
    left: 0;
    bottom: -1.8rem;
    width: 9.8rem;                 /* 198:43 ≈ 4.6:1 比例，宽 9.8rem → 高 ≈ 2.1rem */
    height: auto;
    z-index: 3;
    filter: drop-shadow(0 0.2rem 0.4rem rgba(160, 0, 0, 0.25));
    user-select: none;
    -webkit-user-drag: none;
}

.yc-card__body {
    padding: 1.8rem 1.4rem 1.4rem;
}

.yc-card__title {
    margin: 0 0 1.1rem;
    font-size: 1.55rem;
    font-weight: 700;
    color: #222;
    letter-spacing: 0.05rem;
    line-height: 1.3;
}

.yc-card__meta {
    display: flex;
    gap: 1.4rem 1.6rem;
    flex-wrap: wrap;
    align-items: baseline;
    font-size: 1.25rem;
    color: #444;
}

.yc-card__meta-item {
    display: inline-flex;
    align-items: baseline;
    gap: 0.3rem;
}

.yc-card__meta-label {
    color: #222;
}

.yc-card__meta-value {
    color: #d8131c;
    font-weight: 700;
}

.yc-card__desc {
    margin: 1.1rem 0 1.4rem;
    font-size: 1.15rem;
    color: #666;
    line-height: 1.65;
    letter-spacing: 0.02rem;
}

.yc-card__copy {
    margin: 1.1rem 0 1.4rem;
    padding: 0.85rem 1rem;
    border-radius: 0.8rem;
    background: linear-gradient(180deg, #fff8e6, #fff0c8);
    border: 0.05rem solid #f3d8a5;
    color: #8a4d0e;
    font-size: 1.15rem;
    line-height: 1.55;
    letter-spacing: 0.02rem;
}

.yc-card__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 3.8rem;
    border: 0;
    border-radius: 1.9rem;
    background: linear-gradient(180deg, #ef343c 0%, #c20911 100%);
    color: #fff;
    font-size: 1.55rem;
    font-weight: 600;
    letter-spacing: 0.5rem;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 0.4rem 1rem rgba(180, 0, 0, 0.32),
                inset 0 0.1rem 0 rgba(255, 255, 255, 0.25);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.yc-card__btn:hover {
    box-shadow: 0 0.6rem 1.2rem rgba(180, 0, 0, 0.38),
                inset 0 0.1rem 0 rgba(255, 255, 255, 0.3);
}

.yc-card__btn:active {
    transform: translateY(0.15rem);
    box-shadow: 0 0.1rem 0.3rem rgba(180, 0, 0, 0.25);
}

.yc-card__btn--owned {
    background: linear-gradient(180deg, #16a34a, #15803d);
    letter-spacing: 0.2rem;
    box-shadow: 0 0.35rem 0.9rem rgba(22, 128, 61, 0.26),
                inset 0 0.1rem 0 rgba(255, 255, 255, 0.22);
    position: relative;
}
.yc-card__btn--owned::before {
    content: "";
    position: absolute;
    top: 0.4rem;
    right: 0.6rem;
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background: #ffe24a;
    box-shadow: 0 0 0.4rem rgba(255, 226, 74, 0.85);
    animation: yc-owned-pulse 1.8s ease-in-out infinite;
}
@keyframes yc-owned-pulse {
    0%, 100% { opacity: 0.35; transform: scale(0.9); }
    50%      { opacity: 1;    transform: scale(1.15); }
}

.yc-coming {
    margin: 1.8rem 1.2rem 2.2rem;
    padding: 1.1rem 1.4rem;
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.9);
    border: 0.05rem solid rgba(255, 200, 130, 0.75);
    color: #8a4d0e;
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.5;
    text-align: center;
    box-shadow: 0 0.3rem 0.8rem rgba(120, 0, 0, 0.08);
}

/* ===== 底部 Tabbar（贴合页面 phone 容器同宽） ===== */
.tabbar {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    bottom: 0;
    width: 100%;
    max-width: 37.5rem;          /* 与 .phone 同宽 */
    height: 5.8rem;
    display: flex;
    background: #fff;
    border-top: 0.05rem solid #ececec;
    box-shadow: 0 -0.2rem 0.8rem rgba(0, 0, 0, 0.06);
    z-index: 10;
    padding-bottom: env(safe-area-inset-bottom, 0);
}

.tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    color: #777;
    font-size: 1.05rem;
    cursor: pointer;
    border: 0;
    background: transparent;
}

.tab__icon {
    width: 2.4rem;
    height: 2.4rem;
    color: inherit;
}

/* PNG 图标在未选中态做灰阶 + 半透明，模拟 SVG 跟随选中态变色的效果 */
.tab:not(.tab--active) .tab__icon--img {
    filter: grayscale(1) opacity(0.55);
}
.tab__icon--img { transition: filter 0.15s ease; }

.tab--active {
    color: #d8131c;
    font-weight: 700;
}
