html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {

}

a {
    text-decoration: none;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* 英雄区域背景渐变 */
.hero-section {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%) !important;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    z-index: -1;
}

/* 确保背景渐变显示 */
.bg-gradient {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%) !important;
}

/* 产品卡片样式 */
.product-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.product-card-horizontal {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card-horizontal:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

/* 分类卡片样式 */
.category-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e9ecef;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* VIP区域背景渐变 */
.vip-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

/* 统计卡片样式 */
.stat-card {
    background: rgba(255, 255, 255, 0.1) !important;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* 搜索框样式 */
.search-container .form-control {
    border-right: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.search-container .btn {
    border-left: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* 网站底部样式修复 */
footer {
    background-color: #343a40 !important;
    color: #ffffff !important;
}

footer h5, footer h6 {
    color: #ffffff !important;
}

footer p, footer small {
    color: #adb5bd !important;
}

footer a {
    color: #adb5bd !important;
    text-decoration: none;
}

footer a:hover {
    color: #ffffff !important;
    text-decoration: none;
}

footer .text-muted {
    color: #adb5bd !important;
}

footer .social-links a {
    color: #adb5bd !important;
    transition: color 0.3s ease;
}

footer .social-links a:hover {
    color: #ffffff !important;
}

/* 三级导航菜单样式 */
.dropdown-hover .dropdown-menu {
    display: none;
}

.dropdown-submenu {
    position: relative;
}

.dropdown-submenu > .dropdown-menu {
    position: absolute;
    top: 0;
    left: 100%;
    margin-left: 0;
    margin-top: -1px;
    display: none;
    min-width: 200px;
}

/* 只有包含子菜单的项目才显示三角图标 */
.dropdown-submenu:has(.dropdown-menu) .dropdown-toggle::after {
    border-top: 0.3em solid transparent;
    border-bottom: 0.3em solid transparent;
    border-left: 0.3em solid;
    margin-left: auto;
    margin-top: 0.5rem;
}

.dropdown-submenu:has(.dropdown-menu) .dropdown-toggle {
    position: relative;
    padding-right: 2rem;
}

/* 备用方案：如果不支持 :has() 选择器，使用类名控制 */
.dropdown-submenu.has-submenu .dropdown-toggle::after {
    border-top: 0.3em solid transparent;
    border-bottom: 0.3em solid transparent;
    border-left: 0.3em solid;
    margin-left: auto;
    margin-top: 0.5rem;
}

.dropdown-submenu.has-submenu .dropdown-toggle {
    position: relative;
    padding-right: 2rem;
}

/* 确保子菜单不会超出屏幕 */
@media (max-width: 991.98px) {
    .dropdown-submenu > .dropdown-menu {
        position: static;
        float: none;
        width: auto;
        margin-left: 1rem;
        box-shadow: none;
        border: none;
        border-left: 2px solid #dee2e6;
        display: none;
    }
}

/* 改善菜单视觉效果 */
.dropdown-menu {
    border: none;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    padding: 0.5rem 0;
}

.dropdown-item {
    padding: 0.75rem 1.5rem;
    transition: all 0.2s ease;
    border: none;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    color: #495057;
    transform: translateX(5px);
}

.dropdown-submenu .dropdown-item {
    padding: 0.5rem 1.25rem;
}

/* 导航栏链接样式统一 */
.navbar-nav .nav-link {
    color: #dee2e6 !important; /* 浅灰色，在深色背景上可读性更好 */
    transition: color 0.2s ease;
}

.navbar-nav .nav-link:hover {
    color: #ffffff !important;
}

.navbar-nav .nav-link.active {
    color: #6ea8fe !important; /* 活跃状态使用浅蓝色 */
}