/* 全局样式 */
@font-face {
  font-family: "BaskervilleOldFace";
  src: url("Fronts/baskerville-old-face.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: "RageItalic";
  src: url("Fronts/rage-italic.ttf") format("truetype");
  font-weight: normal;
  font-style: italic;
}

@font-face {
  font-family: "Dubai";
  src: url("Fronts/Dubai-Regular.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

body {
  margin: 0;
  font-family: "BaskervilleOldFace", serif;
  color: #222;
}

a {
  text-decoration: none;
  color: #5a77a3;
}

a:hover {
  text-decoration: underline;
}

/* 顶部黑色提示栏 */
.top-bar {
  background: #000;
  color: white;
  text-align: center;
  font-family: "Dubai", serif;
  font-size: 14px;
  padding: 5px;
}

.top-bar a {
  color: #fff;
  font-weight: normal;
  text-decoration: underline;
}

/* Header */
.header {
  display: flex;
  justify-content: center;   /* 让中间内容居中 */
  align-items: center;
  padding: 15px 50px;
  position: relative;        /* 为右边 contact 定位做准备 */
  height: 110px;
}

/* Logo 区域（居中） */
.logo {
  display: flex;
  align-items: center;
  gap: 15px;
  text-align: center;
}

.logo img {
  width: 50px;
  height: 50px;
}

.logo h1 {
  margin: 0;
  font-family: "BaskervilleOldFace", serif;
  font-size: 32px;
}

.logo p {
  margin: 0;
  margin-left: 40px;
  font-size: 14px;
  font-family: "RageItalic", cursive;
  font-style:italic;
}

/* Contact us 放在右边 */
.contact {
  position: absolute;   /* 绝对定位 */
  right: 50px;          /* 距离右边 50px */
  font-family: "BaskervilleOldFace", serif;
  font-size: 14px;
}


/* 导航栏 */
.navbar {
  display: flex;
  justify-content: space-around;
  padding: 10px;
  border-bottom: 2px solid #d0d8e6;
  background: #fff;
}

.navbar a, .dropbtn {
  font-size: 18px;
  font-family: "BaskervilleOldFace", serif;
  color: #5a77a3;
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
}

/* 下拉菜单容器 */
.dropdown {
  position: relative;
  display: inline-block;
}

/* 下拉内容 */
.dropdown-content {
  display: none;
  position: absolute;
  background-color: #fff;
  min-width: 180px;
  box-shadow: 0px 8px 16px rgba(0,0,0,0.2);
  z-index: 1000;
  border-radius: 6px;
  padding: 10px 0;
}

/* 下拉菜单里的链接 */
.dropdown-content a {
  color: #5a77a3;
  padding: 10px 16px;
  text-decoration: none;
  display: block;
  text-align: left;
}

.dropdown-content a:hover {
  background-color: #f0f4f9;
}

/* 鼠标移到 Our Products 时显示下拉 */
.dropdown:hover .dropdown-content {
  display: block;
}

/* ===== Hero 区域 ===== */
.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 30px 10%;
  background: white;
  gap: 40px;
}

.hero-text {
  flex: 1;
}

.hero-text h2 {
  font-family: "BaskervilleOldFace", serif;
  font-size: 2.2rem;
  margin-bottom: 20px;
  line-height: 1.4;
}

.hero-text p {
  font-family: "BaskervilleOldFace", serif;
  font-size: 1.1rem;
  margin-bottom: 20px;
  color: #444;
}

.hero-text .icons {
  display: flex;
  gap: 20px;
  font-size: 0.9rem;
  color: #666;
}

.hero-image {
  flex: 1;
  text-align: right;
}

.hero-image img {
  width: 100%;
  max-width: 500px;
  border-radius: 10px;
}

/* ===== 双列介绍部分 ===== */
.two-column {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 10%;
  background: #93abc9;
  gap: 40px;
  flex-wrap: nowrap;
}

.two-column .col-image img {
  width: 100%;
  max-width: 650px;
  border-radius: 10px;
}

.two-column .col-text {
  font-family: "BaskervilleOldFace", serif;
  margin: 0 auto;
  font-size: 24px;
  color: white;
  line-height: 1.6;
  text-align: left;
  padding:0 20px
}

.two-column .col-text p {
font-family: "BaskervilleOldFace", serif;
  color: white;
  font-size: 32px;
}

@media (max-width: 768px) {
  .two-column {
    flex-direction: column;
    text-align: center;      /* 图片和文字在小屏幕整体居中 */
  }

  .two-column .col-text {
    text-align: left;        /* 保持文字左对齐 */
    max-width: 90%;          /* 小屏幕时不要太宽 */
    padding: 0 10px;
  }
}

/* ===== What We Offer 部分 ===== */
.offer .whatweoffer img {
  width: 100%;
  max-width: 1200px;
}

/* ===== 产品分类 ===== */
/* ========== categories 样式 ========== */
.categories h2 {
  text-align: center;
  padding: 10px 60px 30px;
  font-family: "BaskervilleOldFace", serif;
  font-size: 2rem;
  margin-bottom: 50px;
}

.categories {
  padding: 30px 5%;
  background: #fff;
  box-sizing: border-box;
}

/* 每个大类容器：左侧标题 + 右侧网格（标题占固定宽度） */
.category-group {
  display: flex;
  align-items: center;        /* 标题上下居中 */
  gap: 24px;
  margin-bottom: 5px;
}

/* 标题固定宽度放左边 */
.category-title {
  width: 160px;              /* 可调，控制标题列宽 */
  margin: 0;
  padding-top: 12px;
  font-family: "BaskervilleOldFace", serif;
  font-size: 1.8rem;
  color: #4a5a82;
  text-align: left;
  flex: 0 0 auto;
}

/* 图片网格：默认 5 列，占剩余空间，列宽自动缩放 */
.items-grid {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: repeat(5, 1fr);  /* 大屏显示 5 列 */
  gap: 20px;
  align-items: start;
}

/* 单个项：图片（上）+ 标签（下） */
.item {
  text-align: center;
}

/* 六边形容器，宽度由网格列宽决定，自动缩放 */
/* 图片网格：默认 5 列 */
.items-grid {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr)); /* 关键：防止撑满整行 */
  gap: 20px;
  align-items: start;
}

/* 单个项：图片（上）+ 标签（下） */
.item {
  text-align: center;
  width: 100%;          /* 不再固定 max-width */
}

/* 六边形容器：用 aspect-ratio 控制高度 */
.hexagon {
  width: 100%;
  aspect-ratio: 1;      /* 保持正方形比例，再裁成六边形 */
  clip-path: polygon(25% 5%, 75% 5%, 100% 50%, 75% 95%, 25% 95%, 0% 50%);
  overflow: hidden;
  background: #eee;
}

.hexagon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* 响应式断点 */
@media (max-width: 1200px) {
  .items-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 800px) {
  .items-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 480px) {
  .items-grid { grid-template-columns: repeat(1, minmax(0, 1fr)); }
}

/* ===== What We Offer 部分 ===== */
.offer { 
  text-align: center; 
  padding: 10px 10px; 
  background: #fff; 
}

.offer .whatweoffer img {
  width: 100%;
  max-width: 1200px;
}


/* ===== quotes部分 ===== */
.quotes {
  text-align: center;
  padding: 20px;
  background: #fff;
}

.quotes p {
  font-family: "BaskervilleOldFace", serif;
  font-size: 1.8rem;
  margin-bottom: 40px;
}

/* ===== 成就部分 ===== */
.grid-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.left-column, .right-column {
  display: flex;
  flex-direction: column;
}

.box, .image-box {
  min-height: 200px;        /* 🔥 固定高度 */
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}

/* 白色背景 box */
.white-bg {
  background: white;
  color: #333;
}

/* 紫色背景 box */
.purple-bg {
  background: #93ABC9;
  color: white;
}

/* 图片 box */
.image-box {
  position: relative;
  min-height: 200px;
  overflow: hidden;
  padding: 0;
  margin: 0;
}

.image-box img {
  position: absolute;  /* 🔥 强制填满父容器 */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;             /* 🔥 填满整个 box */
  object-fit: cover;        /* 保持比例裁切 */
  display:block
}

/* 数字部分 */
.number {
  font-size: 2rem;          /* 普通文字大小 */
  font-weight: 400;
  color: #333;
}

.number .big {
  font-size: 3.5rem;        /* 🔥 数字更大 */
  font-weight: 700;
  color: #93ABC9;           /* 紫色 */
}

/* 描述文字 */
.description {
  font-size: 1.1rem;
  line-height: 1.6;
  color: inherit;
}

.bold-text {
  font-weight: 700;         /* 加粗关键字 */
}

/* ===== 工厂展示 ===== */
.factory {
  text-align: center;
  padding: 20px;
  background: #f9f9f9;
}

.factory h2 {
  font-family: "BaskervilleOldFace", serif;
  font-size: 2rem;
  margin-bottom: 30px;
}

.factory-list {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
}

.factory-list div {
  flex: 1 ;
  max-width: 350px;  /* 每张图片最大宽度 */
  text-align: center;
}

.factory-list img {
  width: 100%;
  height: 250px;     /* 🔥 固定高度，三张图一样高 */
  object-fit: cover; /* 保持比例，超出部分裁掉 */
  border-radius: 10px;
  display: block;
}

.factory-list p {
  margin-top: 10px;
  font-size: 0.9rem;
}
