/* GuangDong ShenYing Packing Co., Ltd - Main Stylesheet */

:root {
  --color-primary: #0c3d5c;
  --color-primary-dark: #082a40;
  --color-accent: #00a896;
  --color-accent-light: #4dd4c4;
  --color-text: #1a2b3c;
  --color-text-muted: #5a6b7d;
  --color-bg: #f7f9fb;
  --color-white: #ffffff;
  --color-border: #e2e8f0;
  --shadow-sm: 0 1px 3px rgba(12, 61, 92, 0.08);
  --shadow-md: 0 4px 20px rgba(12, 61, 92, 0.12);
  --shadow-lg: 0 12px 40px rgba(12, 61, 92, 0.15);
  --radius: 8px;
  --radius-lg: 12px;
  --font-sans: "Segoe UI", system-ui, -apple-system, sans-serif;
  --header-height: 72px;
  --max-width: 1200px;
  --transition: 0.25s ease;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--color-primary);
}

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Header & Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--color-white);
  box-shadow: var(--shadow-sm);
  height: var(--header-height);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--color-primary);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.2;
}

.logo:hover {
  color: var(--color-primary);
}

.logo-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.25rem;
  font-weight: 800;
  flex-shrink: 0;
}

.logo-text span {
  display: block;
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--color-text-muted);
}

.main-nav ul {
  display: flex;
  gap: 0.25rem;
}

.main-nav a {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--color-text);
  font-weight: 500;
  font-size: 0.95rem;
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
}

.main-nav a:hover,
.main-nav a.active {
  background: rgba(0, 168, 150, 0.1);
  color: var(--color-accent);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-primary);
  transition: var(--transition);
}

.nav-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Hero */
.hero {
  position: relative;
  min-height: 520px;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--color-primary-dark) 0%, var(--color-primary) 50%, #0e5a6e 100%);
  color: var(--color-white);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.5;
}

.hero .container {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  padding-top: 3rem;
  padding-bottom: 3rem;
}

.hero-content h1 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.hero-content p {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 1.75rem;
  max-width: 520px;
}

.hero-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-white);
  border-color: var(--color-accent);
}

.btn-primary:hover {
  background: #008f7f;
  border-color: #008f7f;
  color: var(--color-white);
}

.btn-outline {
  background: transparent;
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.6);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  color: var(--color-white);
  border-color: var(--color-white);
}

.btn-dark {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
}

.btn-dark:hover {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
  color: var(--color-white);
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Image Placeholder */
.img-placeholder {
  width: 100%;
  aspect-ratio: 16 / 10;
  background: linear-gradient(145deg, #dce4ec 0%, #c5d0dc 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  text-align: center;
  padding: 1rem;
  border: 2px dashed #a8b8c8;
  border-radius: var(--radius);
}

.img-placeholder::before {
  content: "";
  width: 48px;
  height: 48px;
  margin-bottom: 0.5rem;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%235a6b7d' viewBox='0 0 24 24'%3E%3Cpath d='M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z'/%3E%3C/svg%3E") center/contain no-repeat;
  opacity: 0.6;
}

.img-placeholder.square {
  aspect-ratio: 1;
}

.img-placeholder.wide {
  aspect-ratio: 21 / 9;
}

.img-placeholder span {
  font-weight: 600;
  color: var(--color-primary);
  margin-top: 0.25rem;
}

/* Real site images */
.site-img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius);
  object-fit: cover;
}

.site-img--wide {
  aspect-ratio: 21 / 9;
}

.site-img--card {
  aspect-ratio: 16 / 10;
}

.site-img--square {
  aspect-ratio: 1;
}

.site-img--content {
  aspect-ratio: 16 / 10;
}

.site-img--product {
  aspect-ratio: 4 / 3;
}

.hero-image .site-img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.card > .site-img {
  border-radius: 0;
}

.news-item > .site-img {
  height: 100%;
  min-height: 200px;
  border-radius: 0;
}

.product-detail .site-img--product {
  border: 1px solid var(--color-border);
}

.article-detail .article-image .site-img--wide {
  border: 1px solid var(--color-border);
}

/* Sections */
main {
  flex: 1;
}

.section {
  padding: 4rem 0;
}

.section-alt {
  background: var(--color-white);
}

.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 3rem;
}

.section-header h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--color-primary);
  margin-bottom: 0.75rem;
}

.section-header p {
  color: var(--color-text-muted);
}

/* Page Banner */
.page-banner {
  background: linear-gradient(135deg, var(--color-primary) 0%, #0e5a6e 100%);
  color: var(--color-white);
  padding: 3rem 0;
  text-align: center;
}

.page-banner h1 {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  margin-bottom: 0.5rem;
}

.page-banner p {
  opacity: 0.9;
  font-size: 1.05rem;
}

.breadcrumb {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
  font-size: 0.9rem;
}

.breadcrumb a {
  color: rgba(255, 255, 255, 0.85);
}

.breadcrumb a:hover {
  color: var(--color-white);
}

.breadcrumb span {
  opacity: 0.6;
}

/* Cards Grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.card-body {
  padding: 1.25rem;
}

.card-body h3 {
  font-size: 1.1rem;
  color: var(--color-primary);
  margin-bottom: 0.5rem;
}

.card-body h3 a {
  color: inherit;
}

.card-body h3 a:hover {
  color: var(--color-accent);
}

.card-body p {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
}

.card-link {
  font-size: 0.9rem;
  font-weight: 600;
}

/* Features */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
}

.feature-item {
  text-align: center;
  padding: 1.5rem;
}

.feature-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 1rem;
  background: rgba(0, 168, 150, 0.12);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
}

.feature-item h3 {
  color: var(--color-primary);
  margin-bottom: 0.5rem;
  font-size: 1.05rem;
}

.feature-item p {
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

/* Two Column Layout */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.two-col h2 {
  color: var(--color-primary);
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.two-col p {
  color: var(--color-text-muted);
  margin-bottom: 1rem;
}

/* Stats */
.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.stat-item {
  text-align: center;
  padding: 1.5rem;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.stat-item strong {
  display: block;
  font-size: 2rem;
  color: var(--color-accent);
  margin-bottom: 0.25rem;
}

.stat-item span {
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

/* Product Detail */
.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.product-detail h1 {
  color: var(--color-primary);
  font-size: 1.75rem;
  margin-bottom: 0.5rem;
}

.product-subtitle {
  color: var(--color-accent);
  font-weight: 600;
  margin-bottom: 1rem;
}

.product-detail p {
  color: var(--color-text-muted);
  margin-bottom: 1rem;
}

.spec-list {
  margin: 1.5rem 0;
}

.spec-list li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--color-border);
  display: flex;
  gap: 0.5rem;
}

.spec-list li::before {
  content: "✓";
  color: var(--color-accent);
  font-weight: bold;
}

/* News List */
.news-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.news-item {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 1.5rem;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition);
}

.news-item:hover {
  box-shadow: var(--shadow-md);
}

.news-item-content {
  padding: 1.25rem 1.25rem 1.25rem 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.news-meta {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-bottom: 0.5rem;
}

.news-item h2 {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.news-item h2 a {
  color: var(--color-primary);
}

.news-item h2 a:hover {
  color: var(--color-accent);
}

.news-excerpt {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
}

/* Article Detail */
.article-detail {
  max-width: 800px;
  margin: 0 auto;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

.article-detail .article-meta {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--color-border);
}

.article-detail h1 {
  color: var(--color-primary);
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

.article-detail .article-image {
  margin: 1.5rem 0;
}

.article-detail p {
  margin-bottom: 1rem;
  color: var(--color-text);
  line-height: 1.8;
}

.article-detail h2 {
  color: var(--color-primary);
  font-size: 1.25rem;
  margin: 2rem 0 1rem;
}

.article-nav {
  display: flex;
  justify-content: space-between;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-border);
  gap: 1rem;
  flex-wrap: wrap;
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.contact-info-block h3 {
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.contact-info-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.contact-info-item .icon {
  width: 40px;
  height: 40px;
  background: rgba(0, 168, 150, 0.12);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-form {
  background: var(--color-white);
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  color: var(--color-text);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-accent);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-note {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-top: 0.75rem;
}

/* CTA */
.cta-section {
  background: linear-gradient(135deg, var(--color-primary) 0%, #0e5a6e 100%);
  color: var(--color-white);
  text-align: center;
  padding: 3rem 0;
}

.cta-section h2 {
  margin-bottom: 0.75rem;
}

.cta-section p {
  opacity: 0.9;
  margin-bottom: 1.5rem;
}

/* Footer */
.site-footer {
  background: var(--color-primary-dark);
  color: rgba(255, 255, 255, 0.85);
  padding: 3rem 0 0;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  padding-bottom: 2rem;
}

.footer-brand p {
  font-size: 0.9rem;
  margin-top: 0.75rem;
  opacity: 0.8;
  line-height: 1.6;
}

.footer-col h4 {
  color: var(--color-white);
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.footer-col ul li {
  margin-bottom: 0.5rem;
}

.footer-col a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.9rem;
}

.footer-col a:hover {
  color: var(--color-accent-light);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1.25rem 0;
  text-align: center;
  font-size: 0.85rem;
  opacity: 0.7;
}

/* Responsive */
@media (max-width: 992px) {
  .hero .container,
  .two-col,
  .product-detail,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .stats-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .news-item {
    grid-template-columns: 1fr;
  }

  .news-item-content {
    padding: 0 1.25rem 1.25rem;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .main-nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--color-white);
    box-shadow: var(--shadow-md);
    padding: 1rem;
    transform: translateY(-120%);
    opacity: 0;
    visibility: hidden;
    transition: transform var(--transition), opacity var(--transition), visibility var(--transition);
  }

  .main-nav.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .main-nav ul {
    flex-direction: column;
  }

  .main-nav a {
    padding: 0.75rem 1rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .stats-row {
    grid-template-columns: 1fr;
  }
}
