/* 
 * Modern Men's Fashion - Custom Styles
 * 极简现代主义风格设计
 * 包含动画关键帧、响应式辅助与微交互效果
 */

/* 基础重置与字体设置 */
:root {
    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --color-text: #1a1a1a;
    --color-bg: #ffffff;
    --color-selection: #e5e5e5;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Noto Sans SC', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    color: var(--color-text);
    background-color: var(--color-bg);
    overflow-x: hidden;
}

/* 文本选中样式 - 匹配中性色调 */
::selection {
    background-color: var(--color-selection);
    color: #000;
}

/* -------------------------------------------
   动画系统
------------------------------------------- */

/* 向上淡入动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    opacity: 0; /* 初始隐藏 */
    animation: fadeInUp 1s var(--ease-out-expo) forwards;
}

/* 动画延迟类 */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-500 { animation-delay: 0.5s; }
.delay-700 { animation-delay: 0.7s; }

/* -------------------------------------------
   组件与交互
------------------------------------------- */

/* 导航链接下划线动画 */
.nav-item {
    position: relative;
    display: inline-block;
    padding-bottom: 2px;
}

.nav-item::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: 0;
    left: 0;
    background-color: currentColor;
    transition: width 0.4s var(--ease-out-expo);
}

.nav-item:hover::after,
.nav-item.active::after {
    width: 100%;
}

/* 图片容器与悬停缩放 */
.img-overflow-hidden {
    overflow: hidden;
    position: relative;
    background-color: #f4f4f5; /* 占位背景色 */
}

.hover-zoom-img {
    transition: transform 1.2s var(--ease-out-expo), opacity 0.5s ease;
    will-change: transform;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.img-overflow-hidden:hover .hover-zoom-img {
    transform: scale(1.06);
}

/* 图片懒加载过渡 */
.lazy-load {
    opacity: 0;
    filter: blur(10px);
    transition: opacity 0.8s ease-out, filter 0.8s ease-out;
}

.lazy-load.loaded {
    opacity: 1;
    filter: blur(0);
}

/* -------------------------------------------
   辅助工具类
------------------------------------------- */

/* 保持宽高比容器 (Fallback for aspect-ratio) */
.aspect-3-4 {
    position: relative;
    padding-bottom: 133.33%;
}

.aspect-16-9 {
    position: relative;
    padding-bottom: 56.25%;
}

.aspect-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* 极简滚动条 */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #d4d4d4;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a3a3a3;
}

/* 隐藏元素但保留布局空间（用于加载前） */
.invisible-hold {
    visibility: hidden;
}