/* 全局样式 - IoT物联网特色配色方案 */
:root {
    /* IoT行业特色配色：科技蓝+紫色+绿色 - 简化配色 */
    --primary-color: #0EA5E9;          /* 科技蓝 - 代表连接和科技 */
    --primary-light: rgba(14, 165, 233, 0.9);
    --secondary-color: #6366F1;        /* 靛蓝 - 代表数据和智能 */
    --accent-color: #10B981;          /* 绿色 - 代表环保和可持续 */
    --light-bg: #F8FAFC;              /* 更浅的背景色 - 简洁感 */
    --border-color: #E2E8F0;
    --white-translucent: rgba(255, 255, 255, 0.95);
    --text-primary: #1F2937;          /* 深灰色文字 - 易读性 */
    --text-secondary: #6B7280;        /* 中灰色文字 - 次要信息 */
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: #fff;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;
}

/* 导航栏样式 */
.navbar {
    backdrop-filter: blur(12px);
    background: linear-gradient(135deg, rgba(56, 139, 237, 1) 0%, rgba(99, 102, 241, 0.98) 100%) !important;
    box-shadow: 0 2px 4px rgba(14, 165, 233, 0.1); /* 更淡的阴影 */
    transition: all 0.3s ease;
    padding: 0.5rem 1rem; /* 调整内边距 */
}

.navbar-brand {
    font-size: 1.4rem;
    font-weight: 600;
    letter-spacing: -0.025em;
    transition: all 0.3s ease;
    margin: 0;
}

.navbar-brand img {
    max-height: 36px;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.1));
}

.nav-link {
    font-weight: 500;
    margin: 0 0.25rem; /* 减小间距 */
    padding: 0.5rem 0.75rem !important;
    color: rgba(255, 255, 255, 0.95) !important;
    border-radius: 6px; /* 更小的圆角 */
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: rgba(255, 255, 255, 1) !important;
    background-color: rgba(255, 255, 255, 0.12);
    transform: translateY(-1px);
}

.nav-link.active {
    font-weight: 600;
    background-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.25);
    padding: 0.375rem 0.75rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.navbar-toggler:hover {
    background-color: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.35);
}

.navbar-collapse {
    background: linear-gradient(135deg, rgba(56, 139, 237, 1) 0%, rgba(99, 102, 241, 0.98) 100%);
    border-radius: 8px; /* 更小的圆角 */
    margin-top: 0.25rem;
    padding: 0.5rem;
    box-shadow: 0 2px 6px rgba(14, 165, 233, 0.1);
}

@media (min-width: 992px) {
    .navbar-collapse {
        background-color: transparent;
        margin-top: 0;
        padding: 0;
        box-shadow: none;
    }
}

/* Hero Section - IoT科技蓝紫色渐变 */
.hero-section {
    background: linear-gradient(135deg,
        rgba(14, 165, 233, 0.9) 0%,      /* 科技蓝 */
        rgba(99, 102, 241, 0.85) 100%);   /* 靛蓝 - 简化渐变 */
    backdrop-filter: blur(10px);
    min-height: 450px; /* 减小高度 */
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding: 4rem 0;
}

.hero-section > .container {
    position: relative;
    z-index: 1;
}

.hero-section h1 {
    font-size: clamp(2rem, 5vw, 3rem); /* 减小最大字体大小 */
    line-height: 1.25;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.hero-section p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    max-width: 500px;
}

/* 卡片样式 */
.card {
    border-radius: 8px; /* 更小的圆角 */
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border-color);
    background-color: #fff;
}

.card:hover {
    transform: translateY(-3px); /* 更小的悬浮效果 */
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08); /* 更淡的阴影 */
}

.card-img-top {
    height: 180px; /* 减小图片高度 */
    object-fit: cover;
    object-position: center;
}

.card-img-placeholder {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 按钮样式 */
.btn {
    border-radius: 6px; /* 更小的圆角 */
    font-weight: 500;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
    border: 1px solid transparent;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.btn-lg {
    padding: 0.75rem 2rem;
    font-size: 1.125rem;
    letter-spacing: -0.025em;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0284C7, #4F46E5);
    border-color: var(--primary-color);
}

.btn-light {
    background-color: var(--white-translucent);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--primary-color);
}

.btn-light:hover {
    background-color: #fff;
    border-color: rgba(255, 255, 255, 0.4);
}

.btn-outline-light {
    border-color: rgba(255, 255, 255, 0.4);
    color: #fff;
}

.btn-outline-light:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.btn-outline-primary {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* Section 样式 */
section {
    transition: transform 0.3s ease;
    position: relative;
}

section.bg-light {
    background-color: var(--light-bg);
}

/* CTA Section - 简化渐变 */
.bg-primary {
    background: linear-gradient(135deg,
        rgba(14, 165, 233, 0.9) 0%,      /* 科技蓝 */
        rgba(99, 102, 241, 0.85) 100%);   /* 靛蓝 - 简化渐变 */
    backdrop-filter: blur(10px);
}

.bg-primary > .container {
    position: relative;
    z-index: 1;
}

/* 页脚样式 */
footer {
    /* 移除自定义背景和颜色，使用Bootstrap的bg-dark和text-light类 */
}

footer a {
    transition: color 0.3s ease;
    color: rgba(255, 255, 255, 0.7);
}

footer a:hover {
    color: #fff !important;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .hero-section {
        min-height: 400px;
    }

    .hero-section h1 {
        font-size: 2rem;
    }

    .card-img-top {
        height: 150px;
    }

    .card-img-placeholder {
        height: 150px;
    }
}

@media (max-width: 576px) {
    .navbar-brand {
        font-size: 1.2rem;
    }

    .navbar-brand img {
        height: 30px;
    }
}

/* 实用类 - IoT三色渐变文字 */
.text-gradient {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.icon-box {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--light-bg);
    border-radius: 10px;
    margin-bottom: 1rem;
}

/* 加载动画 */
.fade-in {
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 滚动条样式 - IoT主题色 */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--light-bg);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--primary-color), var(--secondary-color));
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #0284C7, #4F46E5);
}
