:root {
  --yellow-primary: #F5CB1B;
  --grey-bg: #F3F2EE;
  --grey-surface: #FFFFFF;
  --grey-muted: #7B7F86;
  --grey-dark: #2F353B;
  --border: rgba(0,0,0,0.08);
  --radius: 20px;
  --ff-body: 'Noto Sans TC', sans-serif;
  --ff-display: 'Noto Serif TC', serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--ff-body);
  background: var(--grey-bg);
  color: var(--grey-dark);
  overflow-x: hidden;
}

nav {
  position: fixed;
  top: 0;
  width: 100%;
  display: flex;
  justify-content: flex-end;
  gap: 30px;
  padding: 24px 50px;
  z-index: 100;
  background: transparent;
  transition: background 0.3s ease, backdrop-filter 0.3s ease;
}

nav.scrolled {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  box-shadow: 0 18px 40px rgba(0,0,0,0.06);
}

nav a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  letter-spacing: 1px;
  font-size: 0.95rem;
  position: relative;
}

nav.scrolled a {
  color: var(--grey-dark);
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--yellow-primary);
  transition: width 0.25s ease;
}

nav a:hover::after {
  width: 100%;
}

main {
  padding-top: 110px;
}

section {
  padding: 120px 10%;
}

.section-header h2 {
  font-family: var(--ff-display);
  font-size: clamp(2.4rem, 3.6vw, 3.8rem);
  letter-spacing: 1px;
  margin-bottom: 18px;
}

.hero-left,
.hero-right,
.about-grid,
.product-grid,
.contact-layout {
  display: grid;
}

#hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  min-height: calc(100vh - 110px);
}

.hero-left img {
  max-width: 340px;
  width: 100%;
}

.hero-right {
  justify-items: end;
  text-align: right;
}

.hero-since {
  color: var(--yellow-primary);
  font-size: 0.95rem;
  letter-spacing: 2px;
  font-weight: 700;
}

.hero-desc h1 {
  font-family: var(--ff-display);
  font-size: clamp(3rem, 5vw, 4.6rem);
  line-height: 1.05;
  margin: 24px 0 16px;
}

.hero-desc p {
  max-width: 520px;
  font-size: 1.05rem;
  line-height: 1.95;
  color: var(--grey-muted);
}

#about .about-grid {
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.about-copy p {
  font-size: 1.05rem;
  line-height: 2;
  margin-bottom: 28px;
}

.about-copy strong {
  color: var(--grey-dark);
  font-size: 1.05rem;
}

.about-image {
  background: var(--grey-surface);
  padding: 40px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 24px 60px rgba(0,0,0,0.06);
}

.image-box {
  min-height: 300px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(245,203,27,0.14), rgba(255,255,255,0.8));
  border-radius: 18px;
  color: var(--grey-muted);
  margin-bottom: 28px;
}

.about-image h3 {
  font-family: var(--ff-display);
  font-size: 1.15rem;
  letter-spacing: 0.8px;
  line-height: 1.8;
}

#timeline {
  background: #fff;
}

.timeline-container {
  position: relative;
  padding: 80px 0;
}

.timeline-line {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--yellow-primary);
  transform: translateY(-50%);
  z-index: 1;
}

.timeline-items {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  position: relative;
  z-index: 2;
}

.timeline-item {
  position: relative;
  text-align: center;
  padding: 0 14px;
}

.timeline-item::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 18px;
  height: 18px;
  background: #fff;
  border: 3px solid var(--yellow-primary);
  border-radius: 50%;
  z-index: 2;
}

.timeline-item.top {
  padding-bottom: 120px;
}

.timeline-item.bottom {
  padding-top: 120px;
}

.timeline-year {
  font-family: var(--ff-display);
  font-size: 2.1rem;
  color: var(--yellow-primary);
  margin-bottom: 16px;
}

.timeline-desc {
  font-size: 0.96rem;
  line-height: 1.85;
  color: var(--grey-muted);
}

#products .products-intro {
  max-width: 620px;
  color: var(--grey-muted);
  margin-bottom: 50px;
  letter-spacing: 0.4px;
}

.product-grid {
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.product-card {
  background: var(--grey-surface);
  border-radius: var(--radius);
  padding: 30px;
  border: 1px solid var(--border);
  box-shadow: 0 18px 40px rgba(0,0,0,0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 28px 60px rgba(0,0,0,0.08);
}

.product-img {
  min-height: 220px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(245,203,27,0.12), rgba(255,255,255,0.9));
  border-radius: 18px;
  margin-bottom: 26px;
  color: var(--grey-muted);
}

.product-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--yellow-primary);
  border-radius: 999px;
  padding: 8px 22px;
  font-size: 0.88rem;
  color: var(--grey-dark);
  letter-spacing: 0.6px;
  margin-bottom: 18px;
}

.product-name {
  font-size: 1rem;
  color: var(--grey-dark);
  font-weight: 600;
}

#contact .contact-layout {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 30px;
}

.contact-info-box {
  background: var(--grey-surface);
  padding: 34px 30px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: 0 18px 40px rgba(0,0,0,0.05);
}

.contact-info-box p {
  font-size: 1rem;
  margin-bottom: 12px;
  color: var(--grey-dark);
  font-weight: 700;
}

.contact-info-box span {
  display: block;
  color: var(--grey-muted);
  font-size: 0.95rem;
  line-height: 1.8;
}

@media (max-width: 1024px) {
  nav {
    padding: 20px 32px;
  }
  section {
    padding: 90px 6%;
  }
  #hero,
  #about .about-grid,
  .product-grid,
  #contact .contact-layout {
    grid-template-columns: 1fr;
  }
  .hero-right {
    justify-items: start;
    text-align: left;
  }
}

@media (max-width: 768px) {
  nav {
    justify-content: center;
    gap: 22px;
  }
  #hero {
    min-height: auto;
    gap: 40px;
  }
  .timeline-container {
    padding: 80px 0;
  }
  .timeline-items {
    display: grid;
    gap: 32px;
  }
  .timeline-item.top,
  .timeline-item.bottom {
    padding: 0;
  }
  .timeline-item::before {
    left: 12px;
    top: 12px;
  }
  .timeline-item {
    text-align: left;
    padding-left: 32px;
  }
  .timeline-line {
    top: 20px;
    height: 2px;
  }
}
