/* 帕莎眼镜官网 - 全局样式 */

/* CSS Variables */
:root {
  --primary-black: #000000;
  --primary-white: #FFFFFF;
  --secondary-light: #F5F5F5;
  --secondary-dark: #333333;
  --accent-gold: #C9A962;
  --section-margin: 120px;
  --section-margin-mobile: 60px;
}

/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  color: var(--primary-black);
  background-color: var(--primary-white);
  line-height: 1.8;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
}

.hero-title {
  font-size: clamp(48px, 8vw, 96px);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.section-title {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 700;
  margin-bottom: 40px;
}

.section-subtitle {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--secondary-dark);
  margin-bottom: 16px;
}

.body-text {
  font-size: 16px;
  line-height: 1.8;
  color: var(--secondary-dark);
}

/* Layout */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

.section {
  padding: var(--section-margin) 0;
}

.full-width {
  width: 100vw;
  margin-left: calc(-50vw + 50%);
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  transition: all 0.4s ease;
  padding: 20px 0;
}

.header-transparent {
  background: transparent;
  color: var(--primary-white);
}

.header-solid {
  background: var(--primary-white);
  color: var(--primary-black);
  box-shadow: 0 2px 20px rgba(0,0,0,0.05);
}

.header-white-static {
  background: var(--primary-white);
  color: var(--primary-black);
  box-shadow: 0 2px 20px rgba(0,0,0,0.05);
  position: relative;
}

.header-white-static .nav-link:hover {
  color: var(--secondary-dark) !important;
}

.header-white-static .mobile-menu-btn span {
  background: var(--primary-black);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

.logo {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

.nav {
  display: flex;
  gap: 40px;
}

.nav-link {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.05em;
  position: relative;
  transition: opacity 0.3s;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: currentColor;
  transition: width 0.3s;
}

.nav-link:hover::after {
  width: 100%;
}

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
  padding: 10px;
}

.mobile-menu-btn span {
  width: 24px;
  height: 2px;
  background: currentColor;
  transition: all 0.3s;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 40px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  border-radius: 0;
}

.btn-primary {
  background: var(--primary-black);
  color: var(--primary-white);
}

.btn-primary:hover {
  background: var(--secondary-dark);
}

.btn-secondary {
  background: transparent;
  color: var(--primary-black);
  border: 1px solid var(--primary-black);
}

.btn-secondary:hover {
  background: var(--primary-black);
  color: var(--primary-white);
}

.btn-white {
  background: var(--primary-white);
  color: var(--primary-black);
}

.btn-white:hover {
  background: var(--secondary-light);
}

/* Banner */
.banner {
  position: relative;
  height: 100vh;
  min-height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.banner-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
}

.banner-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.3);
}

.banner-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: var(--primary-white);
  padding: 0 40px;
}

.banner-subtitle {
  font-size: 14px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  margin-bottom: 24px;
  opacity: 0.9;
}

.banner-title {
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 700;
  margin-bottom: 32px;
  letter-spacing: -0.02em;
}

.banner-desc {
  font-size: 18px;
  max-width: 600px;
  margin: 0 auto 40px;
  opacity: 0.9;
}

/* Scroll Reveal Animation */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Card Grid */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.card {
  background: var(--primary-white);
  transition: all 0.3s;
  cursor: pointer;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.card-image {
  aspect-ratio: 4/3;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s;
}

.card:hover .card-image img {
  transform: scale(1.05);
}

.card-content {
  padding: 24px;
}

.card-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.card-desc {
  font-size: 14px;
  color: var(--secondary-dark);
}

/* Product Card */
.product-card {
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.product-card-image {
  aspect-ratio: 3/4;
  background: var(--secondary-light);
  overflow: hidden;
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s;
}

.product-card:hover .product-card-image img {
  transform: scale(1.05);
}

.product-card-info {
  padding: 20px 0;
  text-align: center;
}

.product-card-name {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}

.product-card-category {
  font-size: 14px;
  color: var(--secondary-dark);
}

/* News Ticker */
.news-ticker {
  background: var(--primary-black);
  color: var(--primary-white);
  padding: 16px 0;
  overflow: hidden;
}

.news-ticker-inner {
  display: flex;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

.news-ticker-label {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-right: 40px;
  white-space: nowrap;
  opacity: 0.7;
}

.news-ticker-content {
  flex: 1;
  overflow: hidden;
}

.news-ticker-track {
  display: flex;
  width: fit-content;
  animation: ticker 40s linear infinite;
}

.news-ticker-item {
  white-space: nowrap;
  padding-right: 60px;
  font-size: 14px;
}

@keyframes ticker {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Timeline */
.timeline {
  position: relative;
  padding-left: 40px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--secondary-light);
}

.timeline-item {
  position: relative;
  padding-bottom: 60px;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -44px;
  top: 8px;
  width: 9px;
  height: 9px;
  background: var(--primary-black);
  border-radius: 50%;
}

.timeline-year {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 8px;
}

.timeline-content {
  font-size: 16px;
  color: var(--secondary-dark);
}

/* New Timeline Layout - Desktop */
.timeline-container {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
}

.timeline-center-line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--secondary-light);
  transform: translateX(-50%);
}

.timeline-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 40px;
  align-items: center;
  margin-bottom: 80px;
  position: relative;
}

.timeline-row:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  width: 16px;
  height: 16px;
  background: var(--primary-black);
  border-radius: 50%;
  position: relative;
  z-index: 2;
}

.timeline-content-left {
  text-align: right;
  padding-right: 20px;
}

.timeline-content-right {
  text-align: left;
  padding-left: 20px;
}

.timeline-image-left {
  padding-right: 20px;
}

.timeline-image-right {
  padding-left: 20px;
}

.timeline-year {
  font-size: 48px;
  font-weight: 700;
  color: var(--primary-black);
  margin-bottom: 8px;
  line-height: 1;
}

.timeline-title {
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 12px;
}

.timeline-desc {
  font-size: 16px;
  color: var(--secondary-dark);
  line-height: 1.8;
}

.timeline-img {
  aspect-ratio: 4/3;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.timeline-img span {
  color: rgba(255,255,255,0.9);
  font-size: 14px;
}

/* Form Styles */
.form-group {
  margin-bottom: 32px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 12px;
  letter-spacing: 0.05em;
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 12px 0;
  font-size: 16px;
  border: none;
  border-bottom: 1px solid #ddd;
  background: transparent;
  transition: border-color 0.3s;
  font-family: inherit;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-bottom-color: var(--primary-black);
  border-bottom-width: 2px;
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

/* Footer */
.footer {
  background: var(--primary-black);
  color: var(--primary-white);
  padding: 80px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 60px;
  margin-bottom: 60px;
}

.footer-brand {
  max-width: 300px;
}

.footer-logo {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.1em;
  margin-bottom: 16px;
}

.footer-tagline {
  font-size: 14px;
  opacity: 0.7;
  line-height: 1.8;
}

.footer-column h4 {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 24px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-link {
  font-size: 14px;
  opacity: 0.7;
  transition: opacity 0.3s;
}

.footer-link:hover {
  opacity: 1;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 40px;
  text-align: center;
  font-size: 12px;
  opacity: 0.5;
}

/* Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
}

.modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.8);
  backdrop-filter: blur(20px);
}

.modal-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  width: 90%;
  background: var(--primary-black);
}

.modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: var(--primary-white);
  font-size: 32px;
  cursor: pointer;
  line-height: 1;
}

/* Category Filter */
.category-filter {
  display: flex;
  gap: 40px;
  justify-content: center;
  margin-bottom: 60px;
}

.category-btn {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 8px 0;
  border: none;
  background: none;
  cursor: pointer;
  position: relative;
  color: var(--secondary-dark);
  transition: color 0.3s;
}

.category-btn::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-black);
  transition: width 0.3s;
}

.category-btn:hover,
.category-btn.active {
  color: var(--primary-black);
}

.category-btn.active::after {
  width: 100%;
}

/* Responsive */
@media (max-width: 1024px) {
  .nav {
    display: none;
  }
  
  .mobile-menu-btn {
    display: flex;
  }
  
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }
  
  .footer-brand {
    grid-column: 1 / -1;
    max-width: none;
  }
}

@media (max-width: 768px) {
  :root {
    --section-margin: 60px;
  }
  
  .container {
    padding: 0 20px;
  }
  
  .header-inner {
    padding: 0 20px;
  }
  
  .banner {
    min-height: 600px;
  }
  
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }
  
  .footer-brand {
    text-align: center;
    margin: 0 auto;
  }
  
  .footer-column {
    text-align: center;
  }
  
  .footer-links {
    align-items: center;
  }
  
  .category-filter {
    flex-wrap: wrap;
    gap: 20px;
  }
  
  .card-grid {
    grid-template-columns: 1fr;
  }
}

/* Mobile Product Grid - 2 columns */
@media (max-width: 768px) {
  .product-grid-mobile {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 16px !important;
  }
  
  .product-grid-mobile .product-card-info {
    padding: 12px 0;
  }
  
  .product-grid-mobile .product-card-name {
    font-size: 14px;
  }
  
  .product-grid-mobile .product-card-category {
    font-size: 12px;
  }
}

/* Mobile News/Video Grid - 1 column */
@media (max-width: 768px) {
  .news-grid-mobile {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }
  
  .video-grid-mobile {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }
}

/* Mobile Layout - Text and Image Stack */
@media (max-width: 768px) {
  .mobile-stack-layout {
    display: flex !important;
    flex-direction: column !important;
    gap: 40px !important;
    align-items: center !important;
    text-align: center !important;
  }
  
  .mobile-stack-layout > div {
    width: 100% !important;
    max-width: 100% !important;
  }
  
  .mobile-stack-layout .mobile-image-wrapper {
    aspect-ratio: auto !important;
    height: auto !important;
    order: -1;
  }
  
  .mobile-stack-layout .mobile-image-wrapper img,
  .mobile-stack-layout .mobile-image-wrapper > span {
    position: relative !important;
    top: auto !important;
    left: auto !important;
    transform: none !important;
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 4/3;
    object-fit: cover;
  }
  
  /* Center align text content */
  .mobile-stack-layout .section-title,
  .mobile-stack-layout .section-subtitle {
    text-align: center !important;
  }
  
  .mobile-stack-layout .body-text {
    text-align: center !important;
  }
  
  /* Center buttons */
  .mobile-stack-layout .btn {
    margin: 0 auto;
    display: inline-flex;
  }
  
  /* Center lists */
  .mobile-stack-layout ul {
    display: inline-block;
    text-align: left;
  }
  
  /* Center form elements */
  .mobile-stack-layout form {
    text-align: left;
  }
  
  /* History section mobile layout */
  .history-item {
    grid-template-columns: 1fr !important;
    gap: 30px !important;
    text-align: center !important;
  }
  
  .history-item > div {
    text-align: center !important;
  }
  
  .history-item > div:first-child {
    order: -1;
  }
  
  /* Timeline mobile layout */
  .timeline-container {
    position: relative;
    padding-left: 40px;
  }
  
  .timeline-center-line {
    display: none;
  }
  
  .timeline-container::before {
    content: '';
    position: absolute;
    left: 12px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--secondary-light);
  }
  
  .timeline-row {
    display: flex;
    flex-direction: column;
    gap: 0 !important;
    margin-bottom: 40px;
    position: relative;
  }
  
  .timeline-dot {
    position: absolute;
    left: -34px;
    top: 0;
    width: 12px;
    height: 12px;
    background: var(--primary-black);
    border-radius: 50%;
    z-index: 2;
  }
  
  .timeline-content-left,
  .timeline-content-right,
  .timeline-image-left,
  .timeline-image-right {
    width: 100%;
    text-align: left;
    padding: 0;
  }
  
  .timeline-content-left {
    order: 1;
  }
  
  .timeline-image-right,
  .timeline-image-left {
    order: 3;
    margin-top: 8px;
  }
  
  .timeline-year {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
  }
  
  .timeline-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
  }
  
  .timeline-desc {
    font-size: 14px;
    color: var(--secondary-dark);
    line-height: 1.6;
    margin-bottom: 8px;
  }
  
  .timeline-img {
    aspect-ratio: 16/9;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .timeline-img span {
    color: rgba(255,255,255,0.8);
    font-size: 14px;
  }
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--primary-white);
  z-index: 1500;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 30px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
}

.mobile-menu.active {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-link {
  font-size: 24px;
  font-weight: 600;
}

.mobile-menu-close {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 32px;
  cursor: pointer;
}

/* Footer Toggle - Mobile Only */
.footer-toggle {
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.toggle-icon {
  display: none;
  font-size: 18px;
  font-weight: 400;
  transition: transform 0.3s;
}

.footer-links {
  transition: max-height 0.3s ease, opacity 0.3s ease;
}

@media (max-width: 768px) {
  .footer-grid {
    gap: 0;
    margin-bottom: 40px;
  }
  
  .footer-toggle {
    padding: 16px 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 0;
    font-size: 14px;
  }
  
  .toggle-icon {
    display: inline-block;
    font-size: 16px;
  }

  .footer {
    padding: 40px 0 40px;
  }

  .footer-bottom {
    padding-top: 0px;
  }
  
  .footer-links {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    margin-top: 0;
    gap: 0;
  }
  
  .footer-links.active {
    max-height: 300px;
    opacity: 1;
    margin-top: 12px;
    margin-bottom: 20px;
  }
  
  .footer-links .footer-link {
    padding: 10px 0;
    font-size: 13px;
    opacity: 0.8;
  }
  
  .footer-toggle.active .toggle-icon {
    transform: rotate(45deg);
  }
  
  .footer-column {
    width: 100%;
    margin-bottom: 0;
  }
  
  .footer-brand {
    margin-bottom: 24px;
  }
  
  .footer-brand .footer-logo {
    margin-bottom: 12px;
  }
  
  .footer-brand .footer-tagline {
    font-size: 13px;
    line-height: 1.6;
    opacity: 0.8;
  }
}

/* Mobile News Ticker - Faster animation */
@media (max-width: 768px) {
  .news-ticker-track {
    animation: ticker 20s linear infinite;
  }
}
