/* ===== 黄子弘凡 · 纯桌面版样式（所有设备统一） ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 背景：纯黄色 + 纹理图片（凌乱平铺） */
body {
    font-family: 'Segoe UI', 'Quicksand', system-ui, sans-serif;
    background-color: #FFD93D;                     /* 纯黄色背景 */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
}

/* 纹理层（半透明笑脸图片平铺） */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../images/smiley.png');
    background-repeat: repeat;
    background-size: 80px 80px;      /* 每个纹理块大小，可调整 */
    opacity: 0.15;                    /* 透明度，让纹理隐约可见 */
    pointer-events: none;
    z-index: 0;
}

/* 主要内容在纹理层之上 */
.top-bar, .cards-container, .site-footer {
    position: relative;
    z-index: 1;
}

/* ===== 顶部栏（使用 Flex 垂直居中） ===== */
.top-bar {
    background: rgba(255, 245, 230, 0.8);
    backdrop-filter: blur(10px);
    color: #2C1810;
    padding: 20px 40px;                /* 上下内边距相等，确保垂直居中 */
    box-shadow: 0 10px 30px rgba(255, 107, 107, 0.15);
    border-radius: 0 0 50px 50px;
    margin-bottom: 20px;
    min-height: 180px;                  /* 保持高度 */
    display: flex;
    flex-direction: column;
    justify-content: center;             /* 垂直居中所有内容 */
}

/* 笑脸行 */
.smiley-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0;                    /* 移除底部间距，由父容器内边距控制 */
}

/* 笑脸图片：90×90，圆形 */
.smiley {
    width: 90px;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(5px);
    box-shadow: 0 15px 25px rgba(255, 138, 92, 0.3);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.smiley img {
    width: 100%;
    height: 100%;
    object-fit: cover;                   /* 覆盖圆形，可能裁剪；若希望完整可改为 contain */
    border-radius: 50%;
}

.smiley:hover {
    transform: scale(1.1) rotate(5deg);
}

/* 右侧标语（像素字体） */
.tagline {
    font-size: 16px;
    color: #2C1810;
    background: rgba(255, 217, 61, 0.7);
    padding: 8px 20px;
    border-radius: 60px;
    border: 2px solid #FF8A5C;
    letter-spacing: 1px;
    line-height: 1.5;
}

/* ===== 导航栏（无图标，3D立体按钮） ===== */
.nav-bar {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding: 5px 0 15px;
    scrollbar-width: thin;
    scrollbar-color: #FF8A5C #FFE8D6;
    -webkit-overflow-scrolling: touch;
    flex-wrap: nowrap;
    white-space: nowrap;
}
.nav-bar::-webkit-scrollbar {
    height: 8px;
}
.nav-bar::-webkit-scrollbar-thumb {
    background: #FF8A5C;
    border-radius: 20px;
}

.nav-btn {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 14px 36px;
    font-size: 16px;
    font-weight: 600;
    background: rgba(255, 217, 61, 0.8);
    border: 2px solid rgba(255, 255, 255, 0.6);
    border-radius: 60px;
    color: #2C1810;
    cursor: pointer;
    box-shadow: 
        0 8px 0 #FF8A5C,
        0 10px 20px rgba(255, 107, 107, 0.3);
    transform: translateY(0);
    transition: all 0.1s ease;
    white-space: nowrap;
    letter-spacing: 1px;
    line-height: 1.2;
}

.nav-btn:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 10px 0 #FF8A5C,
        0 15px 25px rgba(255, 107, 107, 0.4);
}

.nav-btn:active {
    transform: translateY(5px);
    box-shadow: 
        0 3px 0 #FF8A5C,
        0 8px 15px rgba(255, 107, 107, 0.3);
}

.nav-btn.active {
    background: #FF6B6B;
    color: white;
    border-color: #FFD93D;
    box-shadow: 
        0 6px 0 #B34A4A,
        0 10px 20px rgba(255, 107, 107, 0.6);
    transform: translateY(2px);
}

/* 隐藏图标（若HTML中有残留） */
.btn-icon {
    display: none;
}

/* ===== 卡片容器 ===== */
.cards-container {
    display: flex;
    flex: 1;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    background: transparent;
    padding: 0 0 20px 0;
    gap: 0;
    position: relative;
    z-index: 1;
}
.cards-container::-webkit-scrollbar {
    height: 10px;
}
.cards-container::-webkit-scrollbar-thumb {
    background: #FF8A5C;
    border-radius: 20px;
}

.card {
    flex: 0 0 100%;
    scroll-snap-align: start;
    margin: 0 10px;
    overflow-y: auto;
    padding: 25px;
    background: rgba(255, 245, 235, 0.7);
    backdrop-filter: blur(12px);
    border-radius: 48px;
    box-shadow: 0 25px 50px -12px rgba(255, 107, 107, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.7);
}

.page-frame {
    width: 100%;
    border: none;
    height: auto;
    min-height: 400px;
}

/* 标题字号（只定义大小，字体由 emfont 类控制） */
h1 {
    font-size: 28px;
    margin-bottom: 20px;
}
h2 {
    font-size: 22px;
}
h3 {
    font-size: 18px;
}

/* 页脚版权（如需添加） */
.site-footer {
    text-align: center;
    padding: 15px 20px;
    font-size: 12px;
    color: #2C1810;
    background: rgba(255, 245, 235, 0.6);
    backdrop-filter: blur(5px);
    border-top: 1px solid rgba(255, 107, 107, 0.3);
    margin-top: 10px;
    letter-spacing: 1px;
    line-height: 1.5;
    position: relative;
    z-index: 1;
}
