/* REDSUN FASTENER HONGRUI METAL - Static Site Styles */
:root {
  --primary: #c0392b;
  --primary-dark: #962d22;
  --dark: #2c2c2c;
  --gray: #666;
  --light-gray: #f5f5f5;
  --border: #ddd;
  --white: #fff;
}

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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--dark);
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }

img { max-width: 100%; height: auto; display: block; }

/* Header */
.site-header {
  background: var(--white);
  border-bottom: 3px solid var(--primary);
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}

.site-logo {
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.site-logo span {
  color: var(--dark);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  gap: 5px;
}

.mobile-menu-toggle span {
  display: block;
  width: 100%;
  height: 3px;
  background: var(--dark);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Navigation */
.main-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.main-nav a {
  display: block;
  padding: 8px 15px;
  color: var(--dark);
  font-size: 14px;
  font-weight: 500;
  border-radius: 3px;
  transition: all 0.2s;
}

.main-nav a:hover,
.main-nav a.active {
  background: var(--primary);
  color: var(--white);
}

/* Dropdown */
.main-nav li {
  position: relative;
}

.main-nav .dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--white);
  min-width: 180px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  border-radius: 0 0 3px 3px;
  z-index: 100;
}

.main-nav li:hover .dropdown {
  display: block;
}

.main-nav .dropdown a {
  padding: 10px 15px;
  font-size: 13px;
  border-bottom: 1px solid var(--light-gray);
}

.main-nav .dropdown a:hover {
  background: var(--primary);
  color: var(--white);
}

/* Hero */
.hero {
  background: url('images/factory-redsunfa.jpg') center top no-repeat;
  background-size: 100% auto;
  color: var(--dark);
  text-align: center;
  padding: 80px 20px 120px;
  min-height: 600px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
}

.hero-text-box {
  background: rgba(255,255,255,0.48);
  padding: 40px 50px;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  max-width: 800px;
  margin-top: 40px;
}

.hero h1 {
  font-size: 36px;
  margin-bottom: 15px;
  color: var(--dark);
}

.hero h3 {
  font-size: 20px;
  font-weight: 400;
  color: var(--gray);
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Section */
.section {
  padding: 50px 0;
}

.section-title {
  font-size: 28px;
  color: var(--dark);
  margin-bottom: 30px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--primary);
  display: inline-block;
}

/* Factory Tour - Scroll from right to left */
.factory-scroll-wrapper {
  width: 100%;
  overflow: hidden;
  position: relative;
}

.factory-scroll {
  width: 100%;
  overflow: hidden;
}

.factory-scroll-inner {
  display: flex;
  gap: 20px;
  width: max-content;
  animation: scrollRightToLeft 30s linear infinite;
}

.factory-scroll-inner:hover {
  animation-play-state: paused;
}

.factory-scroll-inner img {
  width: 360px;
  height: 200px;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  flex-shrink: 0;
}

@keyframes scrollRightToLeft {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Products Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 25px;
}

.product-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  transition: box-shadow 0.3s;
}

.product-card:hover {
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

.product-card a {
  display: block;
  color: inherit;
}

.product-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.product-card h3 {
  padding: 15px;
  font-size: 18px;
  text-align: center;
  color: var(--dark);
}

.product-card:hover h3 {
  color: var(--primary);
}

/* Footer - All info in gradient area */
.site-footer {
  color: var(--white);
}

.footer-gradient {
  padding: 50px 20px;
  text-align: center;
  background: linear-gradient(270deg, #c0392b, #e74c3c, #f39c12, #27ae60, #2980b9, #8e44ad, #c0392b);
  background-size: 1400% 1400%;
  animation: gradientShift 30s ease infinite;
}

.footer-gradient-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-logo a {
  color: var(--white);
  font-size: 22px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.footer-logo a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-info {
  margin-top: 20px;
  font-size: 15px;
  line-height: 2.2;
}

.footer-line {
  color: rgba(255,255,255,0.95);
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.footer-label {
  color: #fff;
  font-weight: 700;
}

.footer-sep {
  margin: 0 12px;
  color: rgba(255,255,255,0.5);
}

.footer-info a {
  color: rgba(255,255,255,0.95);
  text-decoration: underline;
}

.footer-info a:hover {
  color: #fff;
}

.footer-sitemap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  text-align: left;
  margin-top: 30px;
  padding-top: 30px;
  border-top: 1px solid rgba(255,255,255,0.25);
}

.footer-col h4 {
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col ul li a {
  color: rgba(255,255,255,0.85);
  font-size: 14px;
  text-decoration: none;
  transition: color 0.2s;
}

.footer-col ul li a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-copyright {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.25);
  color: rgba(255,255,255,0.9);
  font-size: 14px;
  font-weight: 500;
}

@media (max-width: 768px) {
  .footer-sitemap {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
}

@media (max-width: 480px) {
  .footer-sitemap {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Page Banner */
.page-banner {
  background: var(--primary);
  color: var(--white);
  padding: 40px 20px;
  text-align: center;
}

.page-banner h1 {
  font-size: 32px;
}

/* Content */
.page-content {
  padding: 40px 0;
}

.page-content h2 {
  font-size: 24px;
  color: var(--primary);
  margin: 25px 0 15px;
}

.page-content h3 {
  font-size: 20px;
  color: var(--dark);
  margin: 20px 0 10px;
}

.page-content p {
  margin-bottom: 15px;
  color: var(--gray);
}

.page-content ul {
  margin: 10px 0 15px 25px;
  color: var(--gray);
}

.page-content li {
  margin-bottom: 5px;
}

/* Sub Products */
.sub-products {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.sub-product-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  transition: box-shadow 0.3s;
}

.sub-product-item:hover {
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

.sub-product-item img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.sub-product-item h3 {
  padding: 12px;
  font-size: 16px;
  text-align: center;
}

.sub-product-item h3 a {
  color: var(--dark);
}

.sub-product-item h3 a:hover {
  color: var(--primary);
}

/* Products Gallery */
.product-category {
  margin-bottom: 50px;
}

.product-category .section-title a {
  color: var(--primary);
  text-decoration: none;
}

.product-category .section-title a:hover {
  text-decoration: underline;
}

.product-gallery {
  display: grid;
  gap: 15px;
}

.product-gallery.gallery-4 {
  grid-template-columns: repeat(4, 1fr);
}

.product-gallery.gallery-5 {
  grid-template-columns: repeat(5, 1fr);
}

.gallery-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  text-align: center;
  transition: box-shadow 0.3s, transform 0.3s;
}

.gallery-item:hover {
  box-shadow: 0 6px 20px rgba(0,0,0,0.12);
  transform: translateY(-4px);
}

.gallery-item img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
}

.gallery-item span {
  display: block;
  padding: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--dark);
  background: var(--light-gray);
}

/* Placeholder for coming soon items */
.gallery-item.placeholder {
  cursor: default;
}

.gallery-item.placeholder .placeholder-box {
  width: 100%;
  height: 160px;
  background: var(--light-gray);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
}

.gallery-item.placeholder .placeholder-box span {
  background: transparent;
  color: var(--gray);
  font-size: 13px;
  font-weight: 500;
}

/* Corporate Structure Image */
.corporate-img {
  width: 100%;
  max-width: 978px;
  margin: 20px auto;
  display: block;
}

/* Quality Assurance */
.qa-content {
  max-width: 800px;
  margin: 0 auto;
}

/* About Us - Elegant & Premium */
.about-hero {
  text-align: center;
  margin-bottom: 60px;
  padding: 30px 0;
}

.about-hero-title {
  font-size: 38px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 12px;
  letter-spacing: 1px;
}

.about-hero-subtitle {
  font-size: 20px;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 25px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.about-hero-desc {
  font-size: 20px;
  color: var(--gray);
  max-width: 850px;
  margin: 0 auto;
  line-height: 1.9;
}

.about-hero-desc strong {
  color: var(--primary);
  font-size: 22px;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 35px;
  margin-bottom: 70px;
}

.about-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 45px 30px;
  text-align: center;
  transition: box-shadow 0.3s, transform 0.3s;
}

.about-card:hover {
  box-shadow: 0 12px 40px rgba(0,0,0,0.12);
  transform: translateY(-6px);
}

.about-icon {
  font-size: 44px;
  color: var(--primary);
  margin-bottom: 20px;
}

.about-card h2 {
  font-size: 26px;
  margin: 0 0 18px;
  color: var(--dark);
}

.about-card p {
  font-size: 17px;
  line-height: 1.8;
  color: var(--gray);
}

.about-card ul {
  text-align: left;
  margin: 15px 0 0;
  padding-left: 20px;
}

.about-card li {
  margin-bottom: 10px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--gray);
}

.about-factory {
  margin-bottom: 50px;
}

/* Quality Assurance - Elegant */
.qa-intro {
  text-align: center;
  margin-bottom: 50px;
}

.qa-intro .lead {
  font-size: 22px;
  color: var(--dark);
  max-width: 800px;
  margin: 0 auto;
  line-height: 1.8;
}

.qa-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 25px;
  margin-bottom: 60px;
}

.qa-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 30px 25px;
  text-align: center;
  transition: box-shadow 0.3s, transform 0.3s;
}

.qa-card:hover {
  box-shadow: 0 8px 30px rgba(0,0,0,0.1);
  transform: translateY(-5px);
}

.qa-icon {
  font-size: 32px;
  color: var(--primary);
  margin-bottom: 15px;
}

.qa-card h3 {
  font-size: 18px;
  margin: 0 0 12px;
  color: var(--dark);
}

.qa-card p {
  font-size: 14px;
  line-height: 1.7;
  color: var(--gray);
}

.cert-section {
  margin-bottom: 50px;
}

.cert-grid {
  display: flex;
  justify-content: center;
  gap: 60px;
  flex-wrap: wrap;
}

.cert-item {
  text-align: center;
}

.cert-item img {
  max-width: 220px;
  max-height: 160px;
  object-fit: contain;
  margin-bottom: 10px;
}

.cert-item p {
  font-weight: 700;
  color: var(--dark);
}

.qa-gallery {
  margin-bottom: 40px;
}

.qa-images {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.qa-images img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* ========================
   RESPONSIVE - Mobile
   ======================== */
@media (max-width: 768px) {
  .header-inner {
    flex-wrap: nowrap;
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .main-nav {
    display: none;
    width: 100%;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--white);
    border-top: 1px solid var(--border);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  }

  .main-nav.active {
    display: block;
  }

  .main-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 10px 0;
  }

  .main-nav a {
    padding: 12px 20px;
    border-bottom: 1px solid var(--light-gray);
  }

  .main-nav .dropdown {
    display: block;
    position: static;
    box-shadow: none;
    padding-left: 20px;
    background: var(--light-gray);
  }

  .main-nav .dropdown a {
    border-bottom: none;
    padding: 8px 20px;
  }

  .hero {
    padding: 40px 15px 60px;
    min-height: 400px;
  }

  .hero-text-box {
    padding: 25px 20px;
    margin-top: 20px;
  }

  .hero h1 {
    font-size: 22px;
  }

  .hero h3 {
    font-size: 15px;
  }

  .section {
    padding: 30px 0;
  }

  .section-title {
    font-size: 22px;
  }

  .factory-scroll-inner img {
    width: 280px;
    height: 155px;
  }

  .products-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .product-card img {
    height: 200px;
  }

  .footer-gradient {
    padding: 35px 20px;
  }

  .footer-logo a {
    font-size: 18px;
  }

  .footer-info {
    font-size: 13px;
    margin-top: 15px;
  }

  .footer-line {
    margin-bottom: 6px;
  }

  .footer-sep {
    display: none;
  }

  .footer-copyright {
    margin-top: 18px;
    padding-top: 15px;
  }

  .page-banner h1 {
    font-size: 24px;
  }

  .sub-products {
    grid-template-columns: 1fr;
  }

  .product-gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-item img {
    height: 140px;
  }

  .about-grid,
  .qa-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .about-hero-title {
    font-size: 28px;
  }

  .about-hero-subtitle {
    font-size: 16px;
  }

  .about-hero-desc {
    font-size: 17px;
  }

  .about-card {
    padding: 35px 25px;
  }

  .about-card h2 {
    font-size: 22px;
  }

  .about-card p,
  .about-card li {
    font-size: 15px;
  }

  .about-intro .lead,
  .qa-intro .lead {
    font-size: 18px;
  }

  .qa-images {
    grid-template-columns: 1fr;
  }

  .cert-grid {
    gap: 30px;
  }

  .cert-item img {
    max-width: 140px;
    max-height: 100px;
  }
}

@media (max-width: 480px) {
  .site-logo {
    font-size: 16px;
  }

  .hero h1 {
    font-size: 20px;
  }

  .factory-scroll-inner img {
    width: 240px;
    height: 133px;
  }

  .product-card img {
    height: 180px;
  }
}

/* Product Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 20px;
}

.modal-overlay.active {
  display: flex;
}

.modal-box {
  background: var(--white);
  border-radius: 10px;
  max-width: 800px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  animation: modalIn 0.25s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 14px;
  font-size: 28px;
  color: var(--gray);
  cursor: pointer;
  line-height: 1;
  z-index: 10;
}

.modal-close:hover {
  color: var(--primary);
}

.modal-img {
  width: 100%;
  max-height: 320px;
  object-fit: contain;
  background: #f8f8f8;
  border-radius: 10px 10px 0 0;
}

.modal-body {
  padding: 24px 28px 28px;
}

.modal-body h2 {
  font-size: 22px;
  color: var(--primary);
  margin-bottom: 12px;
}

.modal-body p {
  font-size: 15px;
  color: var(--dark);
  line-height: 1.7;
  margin-bottom: 10px;
}

.modal-body strong {
  color: var(--primary-dark);
}

@media (max-width: 768px) {
  .modal-box {
    max-height: 80vh;
  }
  .modal-img {
    height: 160px;
  }
  .modal-body {
    padding: 18px 20px 22px;
  }
  .modal-body h2 {
    font-size: 18px;
  }
  .modal-body p {
    font-size: 14px;
  }
}
