/* pages/index/index.wxss */
.home-container {
  min-height: 100vh;
  background: linear-gradient(180deg, #f8fffe 0%, #f0f9ff 100%);
  padding-bottom: 120rpx;
}

/* 标题栏 */
.header {
  background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
  padding: 20rpx 30rpx;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 4rpx 12rpx rgba(76, 175, 80, 0.15);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 20rpx;
}

.title {
  color: #ffffff;
  font-size: 36rpx;
  font-weight: 600;
}

.header-right {
  display: flex;
  align-items: center;
}

/* 区域样式 */
.section {
  margin: 25rpx 30rpx;
  background: #ffffff;
  border-radius: 20rpx;
  padding: 35rpx 30rpx;
  box-shadow: 0 8rpx 25rpx rgba(0, 0, 0, 0.08);
  border: 1rpx solid rgba(76, 175, 80, 0.1);
}

.section-title {
  font-size: 34rpx;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 35rpx;
  position: relative;
  padding-left: 20rpx;
}

.section-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6rpx;
  height: 28rpx;
  background: linear-gradient(135deg, #4CAF50, #45a049);
  border-radius: 3rpx;
}

/* 智能硬件设备网格 */
.hardware-grid {
  display: flex;
  justify-content: space-between;
  gap: 25rpx;
}

.hardware-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 25rpx 15rpx;
  border-radius: 16rpx;
  background: linear-gradient(145deg, #f8f9fa, #ffffff);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.hardware-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.05), rgba(69, 160, 73, 0.05));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hardware-item:active::before {
  opacity: 1;
}

.hardware-icon {
  width: 110rpx;
  height: 110rpx;
  border-radius: 55rpx;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20rpx;
  box-shadow: 0 8rpx 20rpx rgba(0, 0, 0, 0.12);
  position: relative;
  z-index: 2;
}

.hardware-name {
  font-size: 28rpx;
  color: #2c3e50;
  text-align: center;
  line-height: 1.4;
  font-weight: 600;
  position: relative;
  z-index: 2;
}

.icon-image {
  width: 56rpx;
  height: 56rpx;
}

/* 其它功能网格 */
.other-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 35rpx 25rpx;
}

.other-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 25rpx 15rpx;
  border-radius: 16rpx;
  background: linear-gradient(145deg, #f8f9fa, #ffffff);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.other-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(76, 175, 80, 0.05), rgba(69, 160, 73, 0.05));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.other-item:active::before {
  opacity: 1;
}

.other-icon {
  width: 88rpx;
  height: 88rpx;
  border-radius: 44rpx;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18rpx;
  box-shadow: 0 6rpx 16rpx rgba(0, 0, 0, 0.12);
  position: relative;
  z-index: 2;
}

.other-name {
  font-size: 26rpx;
  color: #2c3e50;
  text-align: center;
  line-height: 1.3;
  font-weight: 600;
  position: relative;
  z-index: 2;
}



.icon-image {
  width: 60rpx;
  height: 60rpx;
}

/* 底部标签栏 */
.tab-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 120rpx;
  background: white;
  display: flex;
  align-items: center;
  justify-content: space-around;
  border-top: 1rpx solid #e8e8e8;
  padding-bottom: env(safe-area-inset-bottom);
}

.tab-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  height: 100%;
}

.tab-icon {
  width: 48rpx;
  height: 48rpx;
  margin-bottom: 8rpx;
}

.tab-text {
  font-size: 20rpx;
  color: #999;
}

.tab-item.active .tab-text {
  color: #7CB342;
}

/* 点击效果 */
.hardware-item:active,
.other-item:active {
  transform: scale(0.95);
  transition: transform 0.1s;
}

.tab-item:active {
  background: rgba(0, 0, 0, 0.05);
}
