/* 陕西智码界科技有限公司 — 官网样式 */

:root {
  --color-bg: #070b14;
  --color-bg-elevated: #0d1321;
  --color-bg-card: #111827;
  --color-border: rgba(148, 163, 184, 0.12);
  --color-text: #e2e8f0;
  --color-text-muted: #94a3b8;
  --color-primary: #0ea5e9;
  --color-primary-light: #38bdf8;
  --color-accent: #06b6d4;
  --color-accent-glow: rgba(6, 182, 212, 0.25);
  --font-sans: "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --radius: 12px;
  --radius-lg: 20px;
  --header-h: 72px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
}

body {
  font-family: var(--font-sans);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: var(--color-primary-light);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--color-accent);
}

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

.container {
  width: min(1120px, calc(100% - 48px));
  margin-inline: auto;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(7, 11, 20, 0.82);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--color-border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--color-text);
  font-weight: 600;
  font-size: 1.05rem;
}

.logo:hover {
  color: var(--color-text);
}

.logo-img {
  width: 36px;
  height: 36px;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
  display: block;
}

.logo-img-footer {
  width: 40px;
  height: 40px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  padding: 8px 14px;
  border-radius: 8px;
  transition: color var(--transition), background var(--transition);
}

.nav-links a:hover {
  color: var(--color-text);
  background: rgba(255, 255, 255, 0.05);
}

.nav-cta {
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent)) !important;
  color: #fff !important;
  font-weight: 500;
}

.nav-cta:hover {
  opacity: 0.92;
  color: #fff !important;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: var(--transition);
}

.nav-end {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lang-select-wrap {
  display: flex;
  align-items: center;
}

.lang-select {
  appearance: none;
  -webkit-appearance: none;
  padding: 8px 36px 8px 14px;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text);
  background-color: rgba(255, 255, 255, 0.06);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  cursor: pointer;
  transition: border-color var(--transition), background-color var(--transition);
}

.lang-select:hover {
  border-color: rgba(14, 165, 233, 0.4);
  background-color: rgba(255, 255, 255, 0.08);
}

.lang-select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
}

.lang-select option {
  background: var(--color-bg-card);
  color: var(--color-text);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body.lang-en {
  font-family: "Inter", var(--font-sans);
}

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 48px) 0 80px;
  overflow: hidden;
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(14, 165, 233, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(14, 165, 233, 0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, black 20%, transparent 75%);
}

.hero-glow {
  position: absolute;
  top: -20%;
  right: -10%;
  width: 60%;
  height: 70%;
  background: radial-gradient(ellipse, var(--color-accent-glow) 0%, transparent 65%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--color-accent);
  border: 1px solid rgba(6, 182, 212, 0.35);
  background: rgba(6, 182, 212, 0.08);
  padding: 6px 14px;
  border-radius: 100px;
  margin-bottom: 24px;
}

.hero-title {
  font-size: clamp(2.2rem, 5.5vw, 3.5rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}

.hero-title-line {
  display: block;
}

.hero-title-accent {
  background: linear-gradient(135deg, var(--color-primary-light) 0%, var(--color-accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--color-text-muted);
  max-width: 560px;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 56px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 0.95rem;
  font-weight: 500;
  font-family: inherit;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), opacity var(--transition);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary), #0284c7);
  color: #fff;
  box-shadow: 0 4px 24px rgba(14, 165, 233, 0.35);
}

.btn-primary:hover {
  color: #fff;
  box-shadow: 0 6px 32px rgba(14, 165, 233, 0.45);
}

.btn-outline {
  background: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

.btn-outline:hover {
  color: var(--color-text);
  border-color: rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.04);
}

.btn-full {
  width: 100%;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  max-width: 520px;
}

.stat {
  padding: 16px;
  background: rgba(17, 24, 39, 0.6);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  text-align: center;
}

.stat-value {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-primary-light);
  margin-bottom: 4px;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

/* Sections */
.section {
  padding: 100px 0;
}

.section-header {
  margin-bottom: 48px;
  max-width: 640px;
}

.section-header-center {
  margin-inline: auto;
  text-align: center;
}

.section-tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.75rem, 3.5vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.section-desc {
  color: var(--color-text-muted);
  font-size: 1.05rem;
}

/* About */
.about {
  background: var(--color-bg-elevated);
}

.about-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 20px;
}

.about-card-main {
  grid-row: span 2;
}

.about-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: border-color var(--transition), transform var(--transition);
}

.about-card:hover {
  border-color: rgba(14, 165, 233, 0.25);
  transform: translateY(-2px);
}

.about-card h3 {
  font-size: 1.1rem;
  margin-bottom: 12px;
}

.about-card p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
  margin-bottom: 12px;
}

.about-card p:last-child {
  margin-bottom: 0;
}

.about-legal {
  font-size: 0.85rem !important;
  opacity: 0.75;
  margin-top: 16px !important;
  padding-top: 16px;
  border-top: 1px solid var(--color-border);
}

.about-icon {
  font-size: 1.5rem;
  color: var(--color-accent);
  margin-bottom: 12px;
}

/* Services */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.service-card {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}

.service-card:hover {
  border-color: rgba(14, 165, 233, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.service-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(14, 165, 233, 0.12);
  border-radius: 12px;
  color: var(--color-primary-light);
  margin-bottom: 20px;
}

.service-icon svg {
  width: 26px;
  height: 26px;
}

.service-card h3 {
  font-size: 1.15rem;
  margin-bottom: 10px;
}

.service-card > p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}

.service-tags li {
  font-size: 0.75rem;
  padding: 4px 10px;
  background: rgba(6, 182, 212, 0.1);
  color: var(--color-accent);
  border-radius: 6px;
}

/* Advantages */
.advantages {
  background: var(--color-bg-elevated);
}

.advantages-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.advantages-list {
  list-style: none;
  margin-top: 32px;
}

.advantages-list li {
  display: flex;
  gap: 20px;
  padding: 24px 0;
  border-bottom: 1px solid var(--color-border);
}

.advantages-list li:last-child {
  border-bottom: none;
}

.advantage-num {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-primary);
  opacity: 0.6;
  flex-shrink: 0;
}

.advantages-list strong {
  display: block;
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.advantages-list p {
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

.code-window {
  background: #0a0f1a;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.4);
}

.code-window-bar {
  display: flex;
  gap: 8px;
  padding: 14px 16px;
  background: rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid var(--color-border);
}

.code-window-bar span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.3);
}

.code-window-bar span:nth-child(1) { background: #ef4444; }
.code-window-bar span:nth-child(2) { background: #eab308; }
.code-window-bar span:nth-child(3) { background: #22c55e; }

.code-window-content {
  padding: 24px;
  font-family: "SF Mono", "Fira Code", "Consolas", monospace;
  font-size: 0.85rem;
  line-height: 1.8;
  overflow-x: auto;
}

.code-comment { color: #64748b; }
.code-keyword { color: #c084fc; }
.code-var { color: #38bdf8; }
.code-prop { color: #94a3b8; }
.code-string { color: #4ade80; }

/* Contact */
.contact-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 48px;
}

.contact-details {
  list-style: none;
  margin-top: 28px;
}

.contact-details li {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 0;
  border-bottom: 1px solid var(--color-border);
}

.contact-details li:last-child {
  border-bottom: none;
}

.contact-label {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.contact-placeholder {
  color: var(--color-text-muted);
  font-style: italic;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.form-row label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 6px;
  color: var(--color-text-muted);
}

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 12px 16px;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--color-text);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
}

.form-row textarea {
  resize: vertical;
  min-height: 100px;
}

.form-note {
  font-size: 0.9rem;
  color: var(--color-accent);
  text-align: center;
}

.form-note[hidden] {
  display: none;
}

/* Footer */
.footer {
  padding: 48px 0;
  border-top: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--color-text);
  margin-bottom: 6px;
}

.footer-logo:hover {
  color: var(--color-text);
}

.footer-brand .logo-text {
  font-weight: 600;
  font-size: 1rem;
}

.footer-brand p {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: 0;
}

.footer-nav {
  display: flex;
  gap: 24px;
}

.footer-nav a {
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.footer-nav a:hover {
  color: var(--color-text);
}

.footer-copy {
  width: 100%;
  text-align: center;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
  margin-top: 8px;
}

/* Animations */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-badge,
.hero-title,
.hero-subtitle,
.hero-actions,
.hero-stats .stat {
  animation: fadeUp 0.7s ease backwards;
}

.hero-title { animation-delay: 0.1s; }
.hero-subtitle { animation-delay: 0.2s; }
.hero-actions { animation-delay: 0.3s; }
.hero-stats .stat:nth-child(1) { animation-delay: 0.4s; }
.hero-stats .stat:nth-child(2) { animation-delay: 0.45s; }
.hero-stats .stat:nth-child(3) { animation-delay: 0.5s; }
.hero-stats .stat:nth-child(4) { animation-delay: 0.55s; }

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 1024px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
  }

  .about-card-main {
    grid-column: span 2;
    grid-row: span 1;
  }

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

  .advantages-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    padding: 24px;
    background: var(--color-bg-elevated);
    border-bottom: 1px solid var(--color-border);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform var(--transition), opacity var(--transition);
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links a {
    display: block;
    padding: 14px;
    text-align: center;
  }

  .nav-end {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 16px;
  }

  .lang-select-wrap {
    width: 100%;
  }

  .lang-select {
    width: 100%;
  }

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

  .about-grid {
    grid-template-columns: 1fr;
  }

  .about-card-main {
    grid-column: span 1;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .contact-card {
    grid-template-columns: 1fr;
    padding: 28px;
  }

  .section {
    padding: 72px 0;
  }
}

@media (max-width: 480px) {
  .container {
    width: calc(100% - 32px);
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }
}
